text
stringlengths
2.85k
2.55M
label
class label
11 classes
GENERATION OF SECOND MAXIMAL SUBGROUPS AND THE EXISTENCE OF SPECIAL PRIMES arXiv:1611.06196v1 [math.GR] 18 Nov 2016 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Abstract. Let G be a finite almost simple group. It is well known that G can be generated by 3 elements, and in previous work we showed that 6 generators suffice for all maximal subgroups of G. In this paper we consider subgroups at the next level of the subgroup lattice – the so-called second maximal subgroups. We prove that with the possible exception of some families of rank 1 groups of Lie type, the number of generators of every second maximal subgroup of G is bounded by an absolute constant. We also show that such a bound holds without any exceptions if and only if there are only finitely many primes r for which there is a prime power q such that (q r − 1)/(q − 1) is prime. The latter statement is a formidable open problem in Number Theory. Applications to random generation and polynomial growth are also given. Contents 1. Introduction 2. Preliminaries 3. Symmetric and alternating groups 4. Sporadic groups 5. Classical groups 6. Exceptional groups 7. Parabolic subgroups and Number Theory 8. Random generation and third maximal subgroups References 2 4 7 8 11 20 22 25 29 Date: February 17, 2018. 2010 Mathematics Subject Classification. Primary 20D06; Secondary 20D30, 20P05. The authors are grateful for the support of an EPSRC grant and for the hospitality of the Centre Interfacultaire Bernoulli at EPFL, where this work was completed. The third author acknowledges the support of Advanced ERC Grant 247034, an ISF grant 1117/13, and the Miriam and Julius Vinik Chair in Mathematics which he holds. 1 2 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV 1. Introduction In recent years it has been shown that finite non-abelian simple groups share several fundamental generation properties with their maximal subgroups. For example, both classes can be generated by a small number of elements – the simple groups by 2 elements [3, 31], and their maximal subgroups by 4 elements [8]. Similarly, both simple groups and their maximal subgroups are randomly generated by boundedly many elements [8, 25]. Analogous results also hold for almost simple groups – that is, groups lying between a non-abelian finite simple group and its automorphism group. These groups are generated by 3 elements [13] and their maximal subgroups by 6 elements [8]. In this paper we investigate analogous questions for subgroups lying deeper in the subgroup lattice of an almost simple group – namely, for second maximal subgroups. We show, somewhat surprisingly, that the question of whether these subgroups are generated by a bounded number of elements is equivalent to a formidable open problem in Number r −1 Theory – namely, the existence of primes of the form qq−1 where r is arbitrarily large and q is a prime power (which may depend on r). For a finite group G, let d(G) be the minimal number of generators of G. Define the depth of a subgroup M of G to be the maximal length of a chain of subgroups from M to G. A subgroup is second maximal if it has depth 2. There has been interest in the study of these subgroups and their overgroups in the context of lattice theory; this includes work of Feit [15], Pálfy [30] and Aschbacher [1]. In addition, the PhD thesis of Basile [5] provides a detailed study of second maximal subgroups of symmetric and alternating groups. Our first result concerns the number of generators required for second maximal subgroups of almost simple groups. Theorem 1. Let G be a finite almost simple group with socle G0 , and let M be a second maximal subgroup of G. Then one of the following holds: (i) d(M ) 6 12; (ii) d(M ) 6 70, G0 is exceptional of Lie type, and M is maximal in a parabolic subgroup of G; (iii) G0 = L2 (q), 2 B2 (q) or 2 G2 (q), and M is maximal in a Borel subgroup of G. The bounds 12 and 70 in parts (i) and (ii) are probably not best possible (see Remark 7.5). In part (iii), d(M ) can be enormously large. For example, if G = L2 (2k ) and 2k − 1 is a prime, then the elementary abelian 2-group M = (Z2 )k is a second maximal subgroup of G requiring k generators. Since the largest currently known prime is a Mersenne prime with k = 74207281, we obtain the following. Proposition 2. There exists a second maximal subgroup M of a finite simple group such that d(M ) = 74207281. The question of whether d(M ) can be arbitrarily large for the groups in part (iii) of Theorem 1 turns out to depend on the open problem in Number Theory mentioned above: Are there infinitely many primes r for which there r −1 is prime? exists a prime power q such that qq−1 (?) This would follow, for example, if there exist infinitely many Mersenne primes – but note that in (?), q may be arbitrarily large and may depend on r. It is believed that question (?) has a positive answer. However, existing methods of Number Theory are far from proving this. We establish the following. GENERATION OF SECOND MAXIMAL SUBGROUPS 3 Theorem 3. The following are equivalent. (i) There exists a constant c such that all second maximal subgroups of finite almost simple groups are generated by at most c elements. (ii) There exists a constant c such that all second maximal subgroups of finite simple groups are generated by at most c elements. (iii) There exists a constant c such that all second maximal subgroups of L2 (q) (q a prime power) are generated by at most c elements. (iv) The question (?) has a negative answer. In view of the difficulty of question (?), it seems likely that the validity of part (i) of Theorem 3 will remain open for a long time. However, if we go further down the subgroup lattice and consider third maximal subgroups (i.e. subgroups of depth 3), we can show unconditionally that there is no bound on the number of generators: Proposition 4. For each real number c there is a third maximal subgroup M of an almost simple group such that d(M ) > c. Next we move on to random generation. For a finite group G and a positive integer k let P (G, k) denote the probability that k randomly chosen elements of G generate G. Let ν(G) be the minimal number k such that P (G, k) > 1/e. Up to a small multiplicative constant, it is known that ν(G) is the expected number of random elements generating G (see [29] and [26, Proposition 1.1]). In [8, Theorem 3] it was shown that ν(M ) is bounded by a constant for all maximal subgroups M of almost simple groups. Combining Theorem 1 with results of Jaikin-Zapirain and Pyber [16], we extend this to second maximal subgroups, as follows. Theorem 5. There is a constant c such that ν(M ) 6 c for all second maximal subgroups M of almost simple groups, with the possible exception of those in part (iii) of Theorem 1. More precisely, we show that ν(M ) 6 c for every second maximal subgroup M of an almost simple group if and only if the question (?) has a negative solution. Indeed, this follows by combining Theorem 3 with Corollary 8.2. Our final result concerns the growth of third maximal subgroups. Recall that for a group G and a positive integer n, the number of maximal subgroups of index n in G is denoted by mn (G). The maximal subgroup growth of finite and profinite groups has been widely studied in relation to the notion of positively finitely generated groups – that is, groups G for which, for bounded k, P (G, k) is bounded away from zero (see [27, 28, 26]). For simple groups G, the theory was developed in [17, 25], culminating in [20], where it was proved that mn (G) 6 na for any fixed a > 1 and sufficiently large n. A polynomial bound for second maximal subgroups was obtained in [8, Corollary 6]. This was based on the random generation of maximal subgroups by a bounded number of elements, together with Lubotzky’s inequality mn (H) 6 nν(H)+3.5 for all finite groups H ([26]). Here we show that, despite the fact that second maximal subgroups may not have such a random generation property, the growth of third maximal subgroups is still polynomial. Theorem 6. There is a constant c such that any almost simple group has at most nc third maximal subgroups of index n. Our notation is fairly standard. We adopt the notation of [19] for classical groups, so  − Ln (q) = L+ n (q), Un (q) = Ln (q), PSpn (q) and PΩn (q) denote the simple linear, unitary, symplectic and orthogonal groups of dimension n over the finite field Fq , respectively. In addition, we write Zn (or just n) and Dn for the cyclic and dihedral groups of order n, respectively, and [n] denotes an arbitrary solvable group of order n. 4 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV The paper is organised as follows. In Section 2 we start with some preliminary results that are needed in the proofs of our main theorems. Next, in Sections 3 and 4 we prove Theorem 1 for groups with an alternating group and sporadic socle, respectively. This leaves us to deal with groups of Lie type. In Section 5 we consider the non-parabolic subgroups of classical groups, and we do likewise for the exceptional groups in Section 6. We complete the proof of Theorem 1 in Section 7, where we deal with the maximal subgroups of parabolic subgroups in groups of Lie type. Here we also present connections with Number Theory and the proof of Theorem 3 is completed at the end of the section. Finally, in Section 8 we discuss random generation and growth, and we prove Proposition 4 and Theorems 5 and 6. 2. Preliminaries In this section we record several preliminary results that will be needed in the proofs of our main theorems. We start by recalling two of the main results from [8]. The first is [8, Theorem 2]: Theorem 2.1. ([8]) Let G be a finite almost simple group with socle G0 and let H be a maximal subgroup of G. Then d(H ∩ G0 ) 6 4 and d(H) 6 6. The next result is [8, Theorem 7]. Theorem 2.2. ([8]) Let G be a finite primitive permutation group with point stabilizer H. Then d(G) − 1 6 d(H) 6 d(G) + 4. Recall that if M is a subgroup of a group H, then \ coreH (M ) = Mh h∈H is the H-core of M , which is the largest normal subgroup of H contained in M . The next result, which follows immediately from Theorems 2.1 and 2.2, will play a key role in our analysis of second maximal subgroups. Lemma 2.3. Let G be a finite almost simple group and let M be a second maximal subgroup of G, so that M < H < G with each subgroup maximal in the next. If coreH (M ) = 1, then d(M ) 6 10. Proof. Assume coreH (M ) = 1, so H acts faithfully and primitively on the cosets of M . Then d(M ) 6 d(H) + 4 by Theorem 2.2, and d(H) 6 6 by Theorem 2.1.  Remark 2.4. In general, if N = coreH (M ) then Lemma 2.3 implies that d(M/N ) 6 10, so d(M ) 6 dM (N ) + d(M/N ) 6 dM (N ) + 10 where dM (N ) is the minimal number of generators of N as a normal subgroup of M (that M is, dM (N ) is the minimal d such that N = hxM 1 , . . . , xd i for some xi ∈ N ). Lemma 2.5. Let V be a finite dimensional vector space over Fq , and let G be a group such that SL(V ) 6 G 6 ΓL(V ), Sp(V ) 6 G 6 ΓSp(V ) or Ω(V ) 6 G 6 ΓO(V ). If H is any maximal subgroup of G, then V is a cyclic Fq (H ∩ GL(V ))-module. Proof. Set G̃ = G ∩ GL(V ) and H̃ = H ∩ GL(V ). The result is immediate if H̃ acts irreducibly on V , so let us assume H̃ = G̃U is the stabilizer of a proper subspace U of V . In the linear case, H̃ stabilizes no other proper non-zero subspace, so any vector v ∈ V \ U generates V as an Fq H̃-module. Now assume G is symplectic or orthogonal. If U is totally singular (or a non-singular 1-space when G is orthogonal and q is even) then any vector v ∈ V \ U ⊥ is a generator. Finally, suppose U is non-degenerate. Here U and U ⊥ are the GENERATION OF SECOND MAXIMAL SUBGROUPS 5 only proper non-zero H̃-invariant subspaces of V , so any vector u1 + u2 ∈ U ⊥ U ⊥ with u1 , u2 6= 0 is a generator.  Suppose G = Sn or An and let X = Fnp be the permutation module for G over Fp , where n > 3 and p is a prime. Set X U = {(a1 , . . . , an ) : ai = 0}, W = {(a, . . . , a) : a ∈ Fp } and note that W ⊆ U if p divides n, otherwise X = U ⊕ W . It is easy to check that U and W are the only proper non-zero submodules of X, so the quotient V = U/(U ∩ W ) is irreducible. We call V the fully deleted permutation module for G. Note that dim V = n−2 if p divides n, otherwise dim V = n − 1. Lemma 2.6. Let G = Sn or An , where n > 5, let p be a prime and let V be the fully deleted permutation module for G over Fp . If H is any maximal subgroup of G, then V is a cyclic Fp H-module. Proof. This is an easy exercise if H is an intransitive or imprimitive maximal subgroup (Sk × Sn−k ) ∩ G or (St o Sn/t ) ∩ G. So assume now that H is primitive on I := {1, . . . , n}. Let {e1 , . . . , en } be the standard basis of Fnp and let v = e1 − e2 = (1, −1, 0, . . . , 0) ∈ U . We show that the orbit v H spans U . For a subset J ⊆ I, let V (J) = hei − ej : i, j ∈ Ji. Note that hvi = V ({1, 2}). Define W to be the span of v H . We claim that if V (J) ⊆ W (where 1 < |J| < n) then there is a larger set J 0 containing J such that V (J 0 ) ⊆ W . To see this, note that as H is primitive, J is not a block for H, so there exists h ∈ H such that J ∩ J h is neither empty nor J. Say h sends i 7→ x, j 7→ y, where i, j ∈ J, x ∈ J and y 6∈ J. Then h sends ei − ej 7→ ex − ey , and so hV (J), (ei − ej )h i contains V (J 0 ), where J 0 = J ∪ {y}. Hence the claim, and the lemma follows.  The next result concerns the minimal generation of maximal subgroups of certain wreath products. In the statement of the lemma, we use the notation 1e H for a normal subgroup of index e in H, and we write V4 for the Klein four-group Z2 × Z2 . Lemma 2.7. Let G be one of the following groups, where n > 2 and A = Sn or An . (i) G = 1e (Zd o A), where d > 3, e divides d, and furthermore the natural projection map from G to A is surjective. (ii) G = 1e (Z2 o A) with e = 1 or 2. (iii) G = 1e (V4 o A) with e = 1, 2 or 4. (iv) G = 1e (D8 o A) with e = 1 or 2. (v) G = 1e (Q8 o A) with e = 1 or 2. Then d(H) 6 6 for every maximal subgroup H of G. Proof. The result is trivial for n = 2 and for n = 3, A = A3 , so assume that n > 3 and A 6= A3 . First consider (i) and (ii). Without loss of generality, we may assume that G = BA, where the base group B is the kernel of an A-invariant homomorphism from (Zd )n to Ze . Then using the action of A we see that B = B(e), where X B(e) = {(λ1 , . . . , λn ) ∈ (Zd )n : λi ≡ 0 (mod e)} (writing Zd as the additive group of integers modulo d). Let H be a maximal subgroup of G. Suppose first that B 6 H. Then H = BM where M is a maximal subgroup of A. As in the previous proof we see that there is a vector v ∈ B such that hv M i contains B(0). 6 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Since B(e)/B(0) is cyclic, it follows that dH (B) 6 2 and thus d(H) 6 2 + d(M ) 6 6 since d(M ) 6 4 by [8, Proposition 4.2]. Now suppose that B 66 Q H. Then H/(H ∩ B) ∼ = A and H ∩ B is a maximal A-invariant subgroup of B. Let d = pai i where the pi are distinct primes, and let Pi be a Sylow pi -subgroup of B. Order the pi so that P1 66 H. As each Pi is A-invariant, we have Y H ∩ B = (H ∩ P1 ) Pi . i>2 Write p = p1 , a = a1 and pb = ep for the p-part of e, so that X P1 = {(λ1 , . . . , λn ) ∈ (Zpa )n : λi ≡ 0 (mod pb )}. Let φ : P1 → (Zp )n be the map sending (λ1 , . . . , λn ) 7→ (pa−1 λ1 , . . . , pa−1 λn ). Then φ(H ∩ P1 ) is a non-zero A-invariant subspace of (Zp )n , so is one of U, W or (Zp )n (where U, W are as defined above). If φ(H ∩ P1 ) contains U , then H ∩ P1 has an element h of the form h = (1 + pλ01 , −1 + pλ02 , pλ03 , . . . , pλ0n ), Q and hhA i is a subgroup (Zpa )n−1 of P1 . Thus dH (H ∩P1 ) 6 2, and similarly dH ( i>2 Pi ) 6 2, so d(H) 6 dH (H ∩ B) + d(A) 6 6. Finally, if φ(H ∩ P1 ) = W then H ∩ P1 = φ−1 (W ) by maximality, and again we see that dH (H ∩ P1 ) 6 2, giving the result as above. The remaining cases are similar to but easier than (i) and (ii). Consider for example part (iv). Let B = G ∩ (D8 )n be the base group of G, and let C = G ∩ (Z4 )n < B. The result follows in the usual way if B 6 H, so assume this is not the case. As in the proof of (i) we see that dH (H ∩ C) 6 2. Also B/C = e10 (Z2 )n , and we see in the usual way that dH/H∩C (H ∩ B/H ∩ C) 6 2. Hence d(H) 6 4 + d(A) 6 6.  We will also need some results on the generation of maximal subgroups of certain nonsimple classical groups. Lemma 2.8. Let G be a group such that G0 6 G 6 Aut(G0 ), where G0 = PΩ+ 4 (q), and let H be a maximal subgroup of G. Then d(G) 6 6, d(H) 6 8 and d(H ∩ G0 ) 6 4. Proof. Here G0 = S × S with S = L2 (q) and it is easy to check that the result holds when q ∈ {2, 3}. Now assume q > 4, so S is simple. Write q = pf with p prime and set H0 = H ∩ G0 . Since d(G0 ) = 2 and every subgroup of Out(G0 ) = (Z(2,q−1) × Zf ) o S2 is 4-generator, it suffices to show that d(H0 ) 6 4. Write G = G0 .A. If H contains G0 then H0 = G0 and thus d(H0 ) = 2. Otherwise H = H0 .A and H0 is a maximal A-invariant subgroup of G0 . It follows that H0 is either a diagonal subgroup isomorphic to S, or it is of the form S × B, B × S, B × B, where B = C ∩ S and C is a maximal subgroup of an almost simple group with socle S. By inspecting [7, Table 8.1], we observe that d(B) 6 2 and thus d(H0 ) 6 4 as required.  Lemma 2.9. Let G0 ∈ {L2 (2), L2 (3), U3 (2)} and let H be a maximal subgroup of G, where G0 6 G 6 Aut(G0 ). Then d(H ∩ G0 ) 6 3. Proof. This is a straightforward calculation.  GENERATION OF SECOND MAXIMAL SUBGROUPS 7 3. Symmetric and alternating groups In this section we begin the proof of Theorem 1 by handling the case where G0 is an alternating group. Our main result is the following. Proposition 3.1. Let G be an almost simple group with socle An . Then d(M ) 6 10 for every second maximal subgroup M of G. Proof. If n 6 8 then it is easy to check that d(M ) 6 3, so for the remainder we may assume that G = An or Sn , with n > 9. Write M < H < G, where M is maximal in H, and H is maximal in G. The possibilities for H are given by the O’Nan-Scott theorem and we deduce that one of the following holds: 1. 2. 3. 4. 5. H H H H H is is is is is intransitive: H = (Sk × Sn−k ) ∩ G, 1 6 k < n/2; affine: H = AGLd (p) ∩ G, n = pd , p prime, d > 1; imprimitive or wreath-type: H = (Sk o St ) ∩ G, n = kt or k t ; diagonal: H = (T k .(Out(T ) × Sk )) ∩ G, T non-abelian simple, n = |T |k−1 ; almost simple. If H is almost simple, then d(M ) 6 6 by Theorem 2.1, so we need to deal with the first four cases. Set C = coreH (M ). If C = 1 then d(M ) 6 10 by Lemma 2.3, so we may assume otherwise. Case 1: H is intransitive. First assume k > 5. If C contains Ak × An−k then [8, Proposition 2.8] implies that d(M ) 6 3. Otherwise, C and H/C are 2-generator almost simple groups and thus Theorem 2.2 implies that d(M ) 6 d(M/C) + d(C) 6 d(H/C) + d(C) + 4 6 8. Next suppose k = 4. The result quickly follows if C contains V4 × An−4 , so assume otherwise. Then either C is a subgroup of S4 and H/C has socle An−4 , or vice versa, whence d(M ) 6 8 as before. A very similar argument applies if k 6 3. Case 2: H is affine. Here H = AGL(V ) ∩ G = V.L, where V = Fdp is the unique minimal normal subgroup of H and SL(V ) 6 L = GL(V ) ∩ G. Note that n = pd . Since we may assume C 6= 1 it follows that M = V.J and J < L is maximal. If d = 1 or (d, p) = (2, 3) then it is easy to see that d(M ) 6 2, so we may assume that SL(V ) is quasisimple. Let Z = Z(L) and note that Z is cyclic. Then L/Z is almost simple and thus d(JZ/Z) 6 6 by Theorem 2.1. Therefore d(J) 6 7, and by applying Lemma 2.5 we deduce that d(M ) 6 8. Case 3: H is imprimitive or wreath-type. First assume G = Sn . Write H = Sk o St = N.St , where N = (Sk )t and k, t > 2. If k = 2 then Lemma 2.7 implies that d(M ) 6 6, so we may assume that k > 3. Suppose M contains N , so M = N.J and J < St is maximal. Now J has s 6 2 orbits on {1, . . . , t}, and d(J) 6 4 by [8, Proposition 4.2] (the cases with t 6 4 can be checked directly), so d(M ) 6 d((Sk )s ) + d(J) 6 6 since d(Sk × Sk ) = 2 (see [8, Proposition 2.8]). Now assume M does not contain N , so M = (M ∩ N ).St and M ∩ N is a maximal St -invariant subgroup of N . If k 6= 4 then A = (Ak )t is the unique minimal normal subgroup of H, so we may assume H contains A 8 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV and we can consider M̄ = M/A < H̄ = H/A = S2 o St . By Lemma 2.7 we have d(M̄ ) 6 6 and thus d(M ) 6 d(Ak ) + d(M̄ ) 6 8. Similarly, if k = 4 then A = (V4 )t is the unique minimal normal subgroup of H, so we may assume M contains A. Note that B = (Z3 )t is the unique minimal normal subgroup of H/A = S3 o St . If M/A does not contain B, then Theorem 2.2 implies that d(M/A) 6 d(H/A) + 4 = 6 and thus d(M ) 6 8. Therefore, we may assume that M/A contains B, so M contains (A4 )t and the above argument goes through (via Lemma 2.7). Now assume G = An and H = (Sk o St ) ∩ G. If H = Sk o St (which can happen if n = k t ) then the previous argument applies. Therefore, we may assume that H is an index-two subgroup of Sk o St , so H = ((Ak )t .2t−1 ).St or Sk o At . The latter case is handled as above, so let us assume H = ((Ak )t .2t−1 ).St = N.St . If k = 2 then H = 21 (S2 o St ) and thus d(M ) 6 6 by Lemma 2.7. Now assume k > 3. If M contains N then M = N.J with J < St maximal and it is easy to see that d(M ) 6 (2 + 1)s + d(J) 6 10, where s 6 2 is the number of orbits of J on {1, . . . , t}. If N 66 M then we can reduce to the case where M contains (Ak )t and by applying Lemma 2.7 we deduce that d(M ) 6 8. Case 4: H is diagonal. Write H = (T k .(Out(T ) × Sk )) ∩ G. First assume G = Sn . Here H = T k .(Out(T ) × Sk ) and T k is the unique minimal normal subgroup of H, so M = T k .J for some maximal subgroup J < Out(T ) × Sk . The projection of J to the Sk factor has s 6 2 orbits on {1, . . . , k} and thus d(M ) 6 d(T s ) + d(J) = 2 + d(J). If J is a standard maximal subgroup of Out(T ) × Sk (i.e. J is of the form A × Sk or Out(T ) × B, where A, B are maximal in the respective factors), then d(J) 6 7 since every subgroup of Out(T ) is 3-generator, d(Sk ) 6 2 and every maximal subgroup of Sk is 4-generator. The only other possibility is J = (L × Ak ).2, where |Out(T ) : L| = 2 (see [33, Lemma 1.3], for example). Clearly, d(J) 6 6 in this case. Now suppose G = An . We may as well assume that H is an index-two subgroup of T k .(Out(T ) × Sk ), otherwise the previous argument applies. If k > 3, then H = T k .(L × Sk ), where |Out(T ) : L| = 2 (see the proof of [8, Lemma 4.4]), and T k is the unique minimal normal subgroup of H. In this situation, the above argument goes through unchanged. Finally, assume k = 2. Set ` = 12 (|T | − i2 (T ) − 1), where i2 (T ) denotes the number of involutions in T . As explained in the proof of [8, Lemma 4.4], if ` is even then H = T 2 .(L×S2 ) as above, and the usual argument applies. If ` is odd then H = T 2 .Out(T ), so H has two minimal normal subgroups N1 and N2 (both isomorphic to T ). If M contains T 2 then M = T 2 .J (with J < Out(T ) maximal) and thus d(M ) 6 d(T 2 )+d(J) 6 2+3 = 5. Otherwise we may assume that M contains N1 , but not N2 , in which case M/N1 is a maximal subgroup of H/N1 ∼ = Aut(T ). By Theorem 2.1 we have d(M/N1 ) 6 6 and we conclude that d(M ) 6 8.  4. Sporadic groups Our main result on second maximal subgroups of sporadic groups is the following. Proposition 4.1. Let G be an almost simple group with sporadic socle G0 . Then d(M ) 6 10 for every second maximal subgroup M of G. As before, write M < H < G where H is a maximal subgroup of G. Define sets A and B as follows: A = {M11 , M12 , M22 , M23 , M24 , HS, J1 , J2 , J3 , Co2 , Co3 , McL, Suz, He, Fi22 , Ru} B = {O0 N, J4 , Th, Ly, HN} Lemma 4.2. If G0 ∈ A ∪ B, then d(M ) 6 5. GENERATION OF SECOND MAXIMAL SUBGROUPS 9 Proof. It is convenient to use Magma [6], together with the detailed information on sporadic groups and their maximal subgroups provided in the Web-Atlas [35] . First assume G0 ∈ A. Here we use the Web-Atlas to construct G as a permutation group of degree n 6 6156 (with equality if G0 = J3 ), and we use the Magma command MaximalSubgroups to construct H and M as permutation groups of degree n. In each case it is straightforward to find five generators for M by random search. A similar approach is effective if G0 ∈ B. For example, suppose G = O0 N.2. First we use the Web-Atlas to construct G as a permutation group on 245520 points, and then we construct the maximal subgroups H of G using the generators given in the Web-Atlas. As before, we can use Magma to find the maximal subgroups of H, and the desired result quickly follows. The remaining cases are similar, working with a suitable matrix representation when G = J4 , Th or Ly.  Remark 4.3. The bound d(M ) 6 5 in Lemma 4.2 is sharp. For example, take G = Fi22 .2, H = U4 (3).22 × S3 , M = J.22 × S3 , where J < U4 (3) is a maximal subgroup of type GU2 (3) o S2 . Then M has a normal subgroup N such that M/N is elementary abelian of order 25 , so d(M ) = 5. (More precisely, M = 2.L2 (3)2 .24 × S3 and N = 2.L2 (3)2 × 3.) Lemma 4.4. If G0 ∈ {Fi23 , Fi024 , Co1 }, then d(M ) 6 8. Proof. First observe that Theorem 2.1 implies that d(M ) 6 6 if H is almost simple, so we may assume otherwise. Suppose G = Fi23 . Using the Web-Atlas, we construct G as a permutation group of degree 31671. In all but four cases, generators for H are given in the Web-Atlas, and we can proceed as in the proof of the previous lemma. The exceptions are the following: H ∈ {31+8 .21+6 .31+2 .2S4 , [310 ].(L3 (3) × 2), 26+8 :(A7 × S3 ), Sp6 (2) × S4 }. It is easy to construct H = Sp6 (2) × S4 as a permutation group of degree 67, and the bound d(M ) 6 3 quickly follows. We can obtain H = 26+8 :(A7 × S3 ) as the normalizer in G of a normal subgroup of order 214 in a Sylow 2-subgroup of G. The 3-local subgroups 31+8 .21+6 .31+2 .2S4 and [310 ].(L3 (3) × 2) can be constructed in a similar fashion, using a Sylow 3-subgroup. In all three cases, it is easy to check that d(M ) 6 3. Next suppose G = Fi24 . Here we start with a permutation representation of degree 306936, and we construct the maximal subgroups H of G using the generators given in the Web-Atlas. In all but two cases, we can use Magma to find the maximal subgroups M of H, and verify the bound d(M ) 6 4. The exceptions are the cases H ∈ {S3 × PΩ+ 8 (3):S3 , Fi23 × 2}. If H = Fi23 × 2 then M = Fi23 or J × 2, where J < Fi23 is maximal, so d(M ) 6 4. Suppose H = S3 × PΩ+ 8 (3):S3 . Then [33, Lemma 1.3] implies that + M ∈ {J × PΩ+ 8 (3):S3 , S3 × L, (3 × PΩ8 (3):3).2}, where J < S3 and L < PΩ+ 8 (3):S3 are maximal. Since J is cyclic and d(L) 6 6, it follows that d(M ) 6 8 in the first two cases. In the final case, it is clear that d(M ) 6 4 (note that d(PΩ+ 8 (3):3) = 2). Now assume G = Fi024 . Every maximal subgroup H of G is the intersection with G of a maximal subgroup of G.2 = Fi24 (with the exception of the almost simple maximal subgroups He:2, U3 (3):2 and L2 (13):2), so we can construct H as above, use Magma to obtain the maximal subgroups M of H, and then finally verify the desired bound on d(M ). This approach is effective unless H = (3 × PΩ+ 8 (3):3).2. Let M be a maximal subgroup of H. If M = 3 × PΩ+ (3):3 then clearly d(M ) 6 3, so assume otherwise. Then M = J.2, 8 10 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV + and either M ∼ = PΩ+ 8 (3):S3 is almost simple, or J = 3 × L with L = K ∩ PΩ8 (3):3 for + some maximal subgroup K < PΩ8 (3):S3 . Since d(L) 6 5 by Theorem 2.1, we conclude that d(M ) 6 7. Finally, suppose G = Co1 . Here we work with a permutation representation of degree 98280. Explicit generators for the six largest maximal subgroups are given in the WebAtlas, and in the usual way we deduce that d(M ) 6 3. Representatives of the remaining sixteen conjugacy classes of maximal subgroups H of G can be constructed using the information provided in the Atlas [12] and Web-Atlas, and once again we find that d(M ) 6 3. As before, the p-local maximal subgroups can be constructed by taking normalizers of appropriate normal subgroups of a Sylow p-subgroup of G. We leave the reader to check the details.  Lemma 4.5. If G = B or M, then d(M ) 6 10. Proof. First assume G = B. If H is almost simple then d(M ) 6 6, so we may assume otherwise. Also recall that d(M ) 6 10 if coreH (M ) = 1, so we may also assume that M contains a nontrivial normal subgroup of H. The maximal subgroups of G are listed in the Web-Atlas. Suppose H = 2.2 E6 (2):2. Here Z(H) ∼ = Z2 is the unique minimal normal subgroup of H, so we may assume that M = 2.J, where J < 2 E6 (2):2 is maximal. Since 2 E6 (2):2 is almost simple, Theorem 2.1 implies that d(M ) 6 1 + 6 = 7. If H = 21+22 .Co2 then Z2 is the unique minimal normal subgroup of H, so we can assume that M = Z2 × Co2 or 21+22 .J, where J < Co2 is maximal. If M = Z2 × Co2 then d(M ) = 2, so let us assume M = 21+22 .J. Here Z2 is the unique minimal normal subgroup of M , so d(M ) = d(222 .J) by [8, Proposition 2.1(iii)]. Using Magma, we calculate that J has at most 7 composition factors on the irreducible F2 Co2 -module 222 , and by applying [8, Proposition 3.1] we conclude that d(M ) 6 7 + d(J) 6 10. Next assume H = (22 × F4 (2)):2. If M = 22 × F4 (2) then d(M ) 6 4, otherwise M = (2 × F4 (2)).2 or (22 × J).2, where J = L ∩ F4 (2) for some maximal subgroup L < F4 (2).2. In the first case it is clear that d(M ) 6 4. In the latter, Theorem 2.1 gives d(J) 6 4, so d(M ) 6 7. If H = 22+10+20 .(M22 :2 × S3 ), [235 ].(S5 × L3 (2)) or 53 .L3 (5), then a permutation representation of H of degree 6144 is given in the Web-Atlas, and it is straightforward to show that M is 3-generator. Similarly, we can use a matrix representation of H = 29+16 .Sp8 (2) of dimension 180 over F2 to check that d(M ) 6 4. The Web-Atlas also provides a matrix representation of H = [230 ].L5 (2) of dimension 144 over F2 and one can check that d(M ) = 2 (we thank Eamonn O’Brien for his assistance with this computation). In each of the remaining cases, we can take a suitable permutation representation of H (see the proof of [9, Proposition 3.3], for example), and it is straightforward to check that d(M ) 6 4. The case G = M is similar. Again we may assume that H is not almost simple and coreH (M ) 6= 1, so H belongs to one of the conjugacy classes of maximal subgroups of G listed in the Web-Atlas. If |H| < 5×109 then a permutation representation of H is given in the Web-Atlas, and it is straightforward to check that d(M ) 6 4. The remaining cases can be handled by arguing as above. For example, suppose H = 25+10+20 .(S3 × L5 (2)). Here 25 is the unique minimal normal subgroup of H, so we may assume that M = 25+10+20 .J or 25+10 .(S3 × L5 (2)), where J < S3 × L5 (2) is maximal. In the latter case, [8, Proposition 2.1(iii)] implies that d(M ) = d(S3 × L5 (2)) = 2. Now assume M = 25+10+20 .J. Using Magma, we calculate that J has at most 8 composition factors on 25 , 210 and 220 , in total. Since every maximal subgroup of S3 × L5 (2) is 2-generator, it follows that d(M ) 6 8 + d(J) 6 10. GENERATION OF SECOND MAXIMAL SUBGROUPS 11 8 Another possibility is H = 38 .PΩ− 8 (3).23 . In this case 3 is the unique minimal normal 8 subgroup of H, so we may assume that M = 3 .J, where J < PΩ− 8 (3).23 is maximal. Here − 8 3 is the natural module for PΩ8 (3) and Lemma 2.5 implies that d(M ) 6 1 + d(J) 6 6. The other cases are similar and we omit the details.  5. Classical groups Let G be an almost simple classical group over Fq with socle G0 , where q = pf for a prime p. Let V be the natural G0 -module. Write M < H < G, where M is maximal in H, and H is maximal in G. Let n denote the dimension of V . Due to the existence of exceptional isomorphisms between certain low-dimensional classical groups (see [19, Proposition 2.9.1], for example), we may (and will) assume that n > 3 if G0 = Un (q), n > 4 if G0 = PSp4 (q)0 , and n > 7 if G0 = PΩn (q). We also assume that (n, q) 6= (4, 2) if G0 = PSpn (q)0 , since PSp4 (2)0 ∼ = A6 . The purpose of this section is to prove Theorem 1 in the case where G0 is classical and M is contained in a maximal non-parabolic subgroup H of G. It is convenient to postpone the analysis of maximal subgroups of parabolic subgroups to Section 7, where we also deal with parabolic subgroups of exceptional groups. By Aschbacher’s subgroup structure theorem for finite classical groups (see [2]), with some exceptional cases for G0 = PΩ+ 8 (q) or PSp4 (q) (with q even), the maximal subgroup H of G is either almost simple, or it belongs to one of eight subgroup collections, denoted C1 , . . . , C8 , which are roughly described in Table 1. In order to prove Theorem 1 for classical groups, we will consider each of these subgroup collections in turn. C1 C2 C3 C4 C5 C6 C7 C8 Stabilizers of subspaces of V L Stabilizers of decompositions V = i Vi , where dim Vi = a Stabilizers of prime index extension fields of Fq Stabilizers of decompositions V = V1 ⊗ V2 Stabilizers of prime index subfields of Fq Normalizers of symplectic-type r-groups in absolutely irreducible representations N Stabilizers of decompositions V = i Vi , where dim Vi = a Stabilizers of non-degenerate forms on V Table 1. The Ci subgroup collections The main result of this section is the following. Proposition 5.1. Let M be a second maximal subgroup of an almost simple classical group G with socle G0 , where M < H < G and H is a maximal non-parabolic subgroup of G. Then d(M ) 6 12. ∼ H/H0 . If M contains H0 Set M0 = M ∩ G0 and H0 = H ∩ G0 , and note that G/G0 = then d(M ) 6 d(M0 ) + d(M/H0 ) 6 d(M0 ) + 3 since every subgroup of G/G0 is 3-generator. Otherwise H/H0 ∼ = M/M0 and again we deduce that d(M ) 6 d(M0 ) + 3. Therefore, it suffices to show that d(M0 ) 6 9. This follows from Theorem 2.1 if H is almost simple, so we may assume that H belongs to one of the collections Ci , i = 1, . . . , 8 (or a small additional collection of maximal subgroups that arises when G0 = PΩ+ 8 (q) or PSp4 (q) (with q even)). We begin with a useful preliminary result. Recall that the solvable residual of a finite group is the smallest normal subgroup such that the respective quotient is solvable (equivalently, it is the last term in the derived series). 12 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Lemma 5.2. Let E = H ∞ be the solvable residual of H, and assume that E is quasisimple and acts irreducibly on V . Then d(M ) 6 9. Proof. Set G̃ = G ∩ PGL(V ) and M̃ = M ∩ PGL(V ). If H contains G0 then H is almost simple and thus d(M ) 6 6 by Theorem 2.1, so assume otherwise. Set C = CG (E) and note that C is a normal subgroup of NG (E) = H. The irreducibility of E on V implies that CG̃ (E) is cyclic, so CM̃ (E) is also cyclic, and thus d(M ∩ C) 6 3 since every subgroup of G/G̃ is 2-generator. Therefore, in order to prove the lemma it suffices to show that d(M C/C) 6 6. To see this, first note that H/C is almost simple (with socle EC/C ∼ = E/Z(E)). If M contains C then M C/C = M/C is a maximal subgroup of H/C and thus d(M C/C) 6 6 as required. On the other hand, if M does not contain C then M C = H, so M C/C = H/C is almost simple and thus d(M C/C) 6 3.  Lemma 5.3. Proposition 5.1 holds if H ∈ C1 . Proof. The possibilities for G and H are listed in [19, Table 4.1.A]. Recall that H is non-parabolic. First assume G0 = Ln (q) and H is of type GLm (q) ⊕ GLn−m (q), where 1 6 m < n/2. It is convenient to work in the quasisimple group SLn (q), so [19, Proposition 4.1.4] implies that H = N.A where N = SLm (q) × SLn−m (q) and A 6 (Zq−1 × Zq−1 ).(Zf × Z2 ) with q = pf . Note that d(N ) = 2 (see [8, Proposition 2.5(ii)]) and every subgroup of (Zq−1 × Zq−1 ).(Zf × Z2 ) is 4-generator. In particular, if M contains N then d(M ) 6 6, so assume otherwise. Then M = (M ∩ N ).A and it suffices to show that d(M ∩ N ) 6 8. Since M ∩ N is a maximal A-invariant subgroup of N , it is of the form C × SLn−m (q) or SLm (q) × D, where C = E∩SLm (q) and E is maximal in a group F such that SLm (q) 6 F 6 ΓLm (q).hγi (where γ is a graph automorphism if m > 3, otherwise γ = 1), and similarly for D. Since C and D are 5-generator by Theorem 2.1 (the cases m = 1 and (m, q) = (2, 2) or (2, 3) can be checked directly), we conclude that d(M ∩ N ) 6 7 and the result follows. A very similar argument applies if G0 = Un (q) and H is of type GUm (q) ⊥ GUn−m (q), and also if G0 = PSpn (q) and H is of type Spm (q) ⊥ Spn−m (q). We omit the details. To complete the proof, we may assume that G0 = PΩn (q) and n > 7. If n, q are even and H is of type Spn−2 (q), then H is almost simple and thus d(M ) 6 6. Now assume that H is 1 (q) ⊥ O 2 of type Om n−m (q), where (m, 1 ) 6= (n − m, 2 ). Note that q is odd if m or n − m is odd. Again, it will be convenient to work in the quasisimple group Ωn (q). If m = 1 then H0 = Ωn−1 (q).2 and it is easy to see that d(M0 ) 6 5. Now assume 2 m > 2, so [19, Proposition 4.1.6] implies that H0 = N.A, where N = Ωm1 (q) × Ωn−m (q) i and A = [2 ] with i = 1 or 2. Note that N is 4-generator. If M contains N then d(M0 ) 6 6, so let us assume otherwise. Then M0 = (M ∩ N ).A and it suffices to show that M ∩ N is 72 generator. If Ωm1 (q) and Ωn−m (q) are both quasisimple then we can repeat the argument in the first paragraph of the proof, using Theorem 2.1, to deduce that d(M ∩ N ) 6 7. Therefore, we may assume that + Ωm1 (q) ∈ {Ω± 2 (q), Ω3 (3), Ω4 (q)} 2 and Ωn−m (q) is quasisimple (if G0 = Ω7 (3) and H is of type O4+ (3) ⊥ O3 (3), then it is easy to check that d(M ) 6 4). The first two cases are straightforward since Ω± 2 (q) is cyclic, and every subgroup of Ω3 (3) is 2-generated. Finally, if Ωm1 (q) = Ω+ (q) then the usual 4 argument goes through, using Lemma 2.8 in place of Theorem 2.1.  Lemma 5.4. Proposition 5.1 holds if H ∈ C2 . Proof. The various possibilities for G and H are recorded in [19, Table 4.2.A]. First assume G0 = Un (q) and H is of type GLn/2 (q 2 ). Here n > 4 is even and it is convenient to work GENERATION OF SECOND MAXIMAL SUBGROUPS 13 in the quasisimple group SUn (q), so H0 = N.A where N = SLn/2 (q 2 ) and A = Zq−1 .Z2 . If M contains N then M0 = N.B for some subgroup B 6 A, whence d(M0 ) 6 4 and the result follows. Otherwise, M0 = (M ∩ N ).A and M ∩ N = C ∩ SLn/2 (q 2 ), where C is a maximal subgroup of a group D such that SLn/2 (q 2 ) 6 D 6 ΓLn/2 (q 2 )hγi (here γ is a graph automorphism if n > 6, otherwise γ = 1). Therefore Theorem 2.1 implies that d(M ∩ N ) 6 4 and thus d(M0 ) 6 6. Next suppose G0 = PΩn (q) and H is of type On/2 (q)2 . Here qn/2 is odd, n > 10 and H = N.A, where N = Ωn/2 (q) × Ωn/2 (q) and A 6 [24 ].Zf . Note that d(N ) = 2. If M contains N then M = N.B with B 6 A and thus d(M ) 6 7, so assume otherwise. Then M = (M ∩N ).A and M ∩N is a maximal A-invariant subgroup of N . If M does not contain an element that interchanges the two Ωn/2 (q) factors of N then M ∩ N = C × Ωn/2 (q) or Ωn/2 (q) × C, where C = D ∩ Ωn/2 (q) and D is maximal in an almost simple group with socle Ωn/2 (q). By Theorem 2.1 we have d(C) 6 4, so d(M ∩ N ) 6 6 and thus d(M ) 6 11. Now assume M has an element that interchanges the two Ωn/2 (q) factors. Then either M ∩ N is a diagonal subgroup isomorphic to Ωn/2 (q), or M ∩ N = C × C with C as above. In the former case, d(M ∩ N ) = 2 and therefore d(M ) 6 7. Finally, suppose M ∩ N = C × C. Write M0 = (M ∩ N ).B with B 6 Z2 × Z2 . To obtain a generating set for M , take 4 generators for one of the factors C, take an element in M that swaps the two Ωn/2 (q) factors, and take two generators for B. These 7 elements generate a subgroup M0 .2 6 M and we can obtain a set of generators for M by choosing at most two further elements. We conclude that d(M ) 6 9. Similar arguments apply in each of the remaining cases. For brevity, we only provide details in the two most difficult cases: (a) G0 = Ln (q) and H is of type GLa (q) o St ; 0 (b) G0 = PΩn (q) and H is of type Oa (q) o St , where a > 2 is even and q is odd. Consider case (a). To begin with, let us assume  = + and a > 2 (the special case a = 1 will be handled later). Note that (a, q) 6= (2, 2) (see [7, 19]). Set d = (a, q − 1). By [19, Proposition 4.2.9] we have H0 = N0 .St and H = N.St , where N0 = A0 .B0 , N = A.B such that A0 and A are sections of (Zq−1 )t , B0 = La (q)t . d1 (Zd )t and B = La (q)t .C.2b .Zk where C = 1e (Zd )t for some divisor e of d, b ∈ {0, 1} and k is a divisor of logp q. Write La (q) = hx, yi, where x and y have coprime orders (see [8, Proposition 2.11]), and fix δ × such that PGLa (q) = La (q).hδi. Also write F× q = hλi and fix an element µ ∈ Fq of order d. Suppose M contains N . Then M = N.J with J < St maximal, hence M0 = N0 .J. If J is transitive on {1, . . . , t} then M0 is a quotient of the subgroup of GLa (q) o J generated by the elements (λ, λ−1 , 1, . . . , 1), (µ, 1, . . . , 1), (x, y, 1, . . . , 1) and (δ, δ −1 , 1, . . . , 1) in GLa (q)t , plus at most four generators for J, whence d(M0 ) 6 8 and the result follows. Similarly, if J is intransitive then d(J) 6 2 and once again we deduce that d(M0 ) 6 8. Now assume N 66 M , so M = (M ∩N ).St and M ∩N is a maximal St -invariant subgroup of N . Suppose A is not contained in M . Then M = (M ∩ A).B.St and M ∩ A is a maximal St -invariant subgroup of A. In other words, (M ∩ A).St is a maximal subgroup of A.St . Since A.St is a quotient of a group of the form 1s (Zq−1 o St ) for some divisor s of q − 1, Lemma 2.7 implies that d((M ∩ A).St ) 6 6 and we deduce that d(M ) 6 11. Now assume M contains A. Set M̄ = M/A, H̄ = H/A = B.St and let us assume that (a, q) 6= (2, 3). Here S = La (q)t is the unique minimal normal subgroup of H̄, so we may assume that M̄ contains S (if not, then Theorem 2.2 implies that d(M̄ ) 6 10 and thus d(M ) 6 12 since A is 2-generator as a normal subgroup of M ). We now consider the quotient groups M̃ = M̄ /S and H̃ = H̄/S = C.2b .Zk .St . If M̃ does not contain C = 1e (Zd )t then M̃ = (M̃ ∩ C).2b .Zk .St and (M̃ ∩ C).St < C.St is maximal. Now Lemma 2.7 implies that 14 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV (M̃ ∩ C).St is 6-generator, hence d(M̃ ) 6 8 so d(M̄ ) 6 9 and thus d(M ) 6 11. We have now reduced to the case where C 6 M̃ , hence M0 = H0 and Theorem 2.1 implies that d(M0 ) 6 4. Now assume  = + and (a, q) = (2, 3). As above, we may assume that M = (M ∩ N ).St contains A, but the rest of the argument needs to be slightly modified since L2 (3) = A4 = V4 :3 is not simple. Set M̄ = M/A and H̄ = H/A = B.St , where B = (A4 )t .C.2b . Now D = (V4 )t is the unique minimal normal subgroup of H̄, so we may as well assume it is contained in M̄ . Set M̃ = M̄ /D and H̃ = H̄/D = E.C.2b .St with E = 3t . If M̃ does not contain E then M̃ = (M̃ ∩ E).C.2b .St and (M̃ ∩ E).St < E.St is maximal, so M̃ ∩ E = 3 or 3t−1 and (M̃ ∩E).St is 3-generator. It follows that d(M̃ ) 6 6, so d(M̄ ) 6 8 and d(M ) 6 10. We have now reduced to the case where E 6 M̃ , so S = (A4 )t 6 M and the remainder of the previous argument now goes through. To complete the analysis of the case  = +, we may assume that a = 1. Here q > 5 and H = N.St , where N = A.2b .Zk .St with A, b and k as above. It is easy to reduce to the case where M = (M ∩ N ).St . If M contains A then M0 = H0 is 4-generator, so assume otherwise. Then M = (M ∩ A).2b .Zk .St and (M ∩ A).St < A.St is maximal. This is a situation we considered above, and by applying Lemma 2.7 we deduce that d(M ) 6 8. A similar argument applies when  = −, so we will only give details in the special case (a, q) = (3, 2). Here U3 (2) = 32 :Q8 , H0 = N0 .St and H = N.St , where N0 = A0 .B0 , N = A.B such that A0 and A are sections of (Z3 )t , B0 = U3 (2)t . 31 (Z3 )t and B = U3 (2)t .C.2b where C = 13 (Z3 )t or (Z3 )t and b ∈ {0, 1}. It is straightforward to reduce to the case where M = (M ∩ N ).St , and by arguing as above we may assume that M contains A. Set M̄ = M/A and H̄ = H/A = (32 :Q8 )t .C.2b .St . Now D = (32 )t is the unique minimal normal subgroup of H̄, so we may assume that M̄ contains D. Now set M̃ = M̄ /D and H̃ = H̄/D = (Q8 )t .C.2b .St . Let E = (Q8 )t . If E is not contained in M̃ then M̃ = (M̃ ∩ E).C.2b .St and (M̃ ∩ E).St < E.St is maximal, so Lemma 2.7 implies that (M̃ ∩ E).St is 6-generator and we deduce that d(M̄ ) 6 9 and d(M ) 6 11. On the other hand, if E 6 M̃ then M contains U3 (2)t and we can complete the proof as above. Finally, let us turn to case (b). Let D and D0 denote the discriminants of the quadratic 0 forms corresponding to On (q) and Oa (q) (see [19, p.32], for example). To begin with, we will assume that a > 4 and (a, 0 ) 6= (4, +). 0 First assume D0 = . By [8, Proposition 2.11] we have PΩa (q) = hx, yi, where |x| 0 0 0 and |y| are coprime. Fix involutions r and s such that PSOa (q) = PΩa (q).hsi, POa (q) = 0 PSOa (q).hri and [r, s] = 1, so hr, si = V4 . By [19, Proposition 4.2.11] we have H0 = N0 .St and H = N.St where 0 0 N0 = 2t−1 .PΩa (q)t .22(t−1) , N = 2t−1 .PΩa (q)t .22(t−1) .[2b ].Zk (1) with 0 6 b 6 3 and k a divisor of logp q. Note that [2b ] 6 D8 is 2-generator. Suppose M contains N , so M0 = N0 .J for some maximal subgroup J < St . If J is transitive then M0 is generated by (−1, 1, . . . , 1), (x, y, 1, . . . , 1), (r, r, 1, . . . , 1) and (s, s, 1, . . . , 1), together with at most 4 more for J. This gives d(M0 ) 6 8. Similarly, if J is intransitive then d(J) 6 2 and we need at most 8 generators for M0 . Now assume N 66 M , so M = (M ∩ N ).St and M ∩ N is a maximal St -invariant 0 subgroup of N . Write N = A.B, where A = 2t−1 and B = PΩa (q)t .22(t−1) .[2b ].Zk . If A 66 M then M = (M ∩ A).B.St and M ∩ A is a maximal St -invariant subgroup of A. Therefore M ∩ A = 2v with v ∈ {0, t − 2}, so d((M ∩ A).St ) 6 3 and we deduce that d(M ) 6 9. Now assume M contains A and set M̄ = M/A and H̄ = H/A. Here 0 S = PΩa (q)t is the unique minimal normal subgroup of H̄, so we may assume that GENERATION OF SECOND MAXIMAL SUBGROUPS 15 S 6 M̄ (if not, Theorem 2.2 implies that d(M̄ ) 6 d(H̄) + 4 = 10 and thus d(M ) 6 11). Set M̃ = M̄ /S and H̃ = H̄/S = C.[2b ].Zk .St , where C = 22(t−1) . If M̃ contains C then M0 = H0 and thus d(M0 ) 6 4, so assume otherwise. Then M̃ = (M̃ ∩ C).[2b ].Zk .St and (M̃ ∩ C).St < 41 (V4 o St ) is maximal. Since (M̃ ∩ C).St is 6-generator by Lemma 2.7, we conclude that d(M̃ ) 6 6 + 2 + 1 = 9, so d(M̄ ) 6 10 and thus d(M ) 6 11 as required. 0 0 0 Next suppose that D0 = , so PΩa (q) = Ωa (q) = PSOa (q). We continue to assume that a > 4 and (a, 0 ) 6= (4, +). By [19, Proposition 4.2.11] we have H0 = N0 .St and H = N.St where 0 0 N0 = 2d × Ωa (q)t .2t−1 , N = 2e × Ωa (q)t .2b .2c .Zk with b ∈ {t − 1, t}, c ∈ {0, 1} and k a divisor of logp q. Also, d = e = t − 1 if t is odd, otherwise d = t − 2 and e ∈ {t − 2, t − 1}. Define the elements x, y and r as above. It is straightforward to reduce to the case where M = (M ∩ N ).St . 0 Write N = A×B, where A = 2e and B = Ωa (q)t .2b .2c .Zk . If M contains A then we may 0 assume that M̄ = M/A contains Ωa (q)t , which is the unique minimal normal subgroup of 0 H̄ = H/A. Therefore, M0 = (2d × Ωa (q)t .2v ).St and the St -invariance of M0 ∩ N implies that v ∈ {0, 1, t − 1}, so d(M0 ) 6 5. Now assume A 66 M , so M = (M ∩ A).B.St and M ∩ A is a maximal St -invariant subgroup of A. Therefore M ∩ A = 2v with v ∈ {0, t − 2}, so d((M ∩ A).St ) 6 3 and d(M ) 6 7. To complete the proof, we may assume that (a, 0 ) = (4, +) or a = 2. Suppose (a, 0 ) = (4, +). Define the involutions r and s as above and note that D0 = , PΩ+ 4 (q) = L2 (q) × + (q) = hx, yi, where (q).hri = L (q) o S . If q > 5 then we can still write PΩ L2 (q) and PΩ+ 2 2 4 4 + |x| and |y| are coprime, but this is not possible when q = 3 (note that PΩ4 (3) = A4 × A4 can be generated by x and y, where |x| = 6 and |y| = 3). As above, we have H0 = N0 .St and H = N.St , where N0 and N are given in (1). One now checks that the argument above goes through essentially unchanged. Indeed, the only difference is that if q = 3 then + t t we require two generators for PΩ+ 4 (q) as a normal subgroup of PΩ4 (q) .St , rather than one. However, it is clear that the desired bound d(M ) 6 12 still holds in this case. For example, if q = 3 and M contains N then we get d(M0 ) 6 9 and the result follows. Finally, suppose a = 2. We will assume q ≡ 0 (mod 4) (the other case is very similar), 0 so D0 =  and PΩ2 (q) = Zm is cyclic, where m = (q − 0 )/4. Write H = N.St , where N = A.B, A = 2t−1 and B = (Zm )t .22(t−1) .[2b ].Zk with 0 6 b 6 3 and k a divisor of logp q. In the usual way, we reduce to the case where M = (M ∩ N ).St . If M does not contain A then M = (M ∩ A).B.St , where M ∩ A is a maximal St -invariant subgroup of A, so M ∩A = 2v with v ∈ {0, t−2}. Therefore, d((M ∩A).St ) 6 3 and we deduce that d(M ) 6 9. Now assume M contains A. Set M̄ = M/A and H̄ = H/A = C.22(t−1) .[2b ].Zk .St , where C = (Zm )t . If C 66 M̄ then M̄ = (M̄ ∩ C).22(t−1) .[2b ].Zk .St and (M̄ ∩ C).St < Zm o St is maximal. Therefore Lemma 2.7 implies that d((M̄ ∩ C).St ) 6 6, so d(M̄ ) 6 11 and thus d(M ) 6 12. Now assume C 6 M̄ and set M̃ = M̄ /C and H̃ = H̄/C = D.[2b ].Zk .St , where D = 22(t−1) . If D 66 M̃ then M̃ = (M̃ ∩D).[2b ].Zk .St and (M̃ ∩D).St is a maximal subgroup of D.St = 41 (V4 o St ). By Lemma 2.7 we have d((M̃ ∩ D).St ) 6 6, so d(M̃ ) 6 9, d(M̄ ) 6 10 and thus d(M ) 6 11. Finally, if M̃ contains D then M0 = H0 and d(M0 ) 6 4.  Lemma 5.5. Proposition 5.1 holds if H ∈ C3 . Proof. First assume G0 = Ln (q), so H is of type GLn/k (q k ) for some prime k (note that k is odd if  = −). If n = k then H0 = Za .Zk for some a > 1 (see [19, Proposition 4.3.6]) and thus d(M0 ) 6 2. On the other hand, if n > k then H ∞ is quasisimple and irreducible, so Lemma 5.2 implies that d(M ) 6 9. 16 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Next suppose G0 = PSpn (q). If H is of type Spn/k (q k ), or if n > 6 and H is of type GUn/2 (q), then the result follows from Lemma 5.2. Now assume n = 4 and H is of type GU2 (q), so q > 5 is odd (see [7, Table 8.12]). Here H ∞ is reducible (see [19, Lemma 4.3.2]) so we need to argue differently. According to [19, Proposition 4.3.7] we have H0 = Z(q+1)/2 .(PGU2 (q) × Z2 ). In general, H = N.A where N = Z(q+1)/2 or Zq+1 , A/Z(A) has socle L2 (q) and Z(A) 6 Z2 . If M contains N then M/N is a maximal subgroup of H/N ∼ = A and we deduce that d(M ) 6 8 since every maximal subgroup of A/Z(A) is 6-generator by Theorem 2.1. On the other hand, if N 66 M then M = (M ∩ N ).A and d(M ) 6 d(M ∩ N ) + d(A) 6 5. Finally, suppose G0 = PΩn (q). If n ≡ 2 (mod 4) and H is of type On/2 (q 2 ) (with q odd) then H ∞ is quasisimple and irreducible, so the result follows from Lemma 5.2. The same argument applies if n is even and H is of type GUn/2 (q). Finally, let us assume that H is  (q k ), where k is a prime and n/k > 3. By applying Lemma 5.2 we reduce to of type On/k the case where H is of type O4+ (q k ), so  = + and k k k H0 = PΩ+ 4 (q ).[`] = (L2 (q ) × L2 (q )).[`] = N.[`], where ` = (1 + δ2,k )k (see [19, Proposition 4.3.14]). Then N < H/Z(H) 6 Aut(N ) and Z(H) 6 Z2 . If M contains Z(H) then Lemma 2.8 implies that d(M/Z(H)) 6 8 and thus d(M ) 6 9. Otherwise M ∼  = H/Z(H) and d(M ) 6 6 by Lemma 2.8. Lemma 5.6. Proposition 5.1 holds if H ∈ C4 . Proof. First assume G0 = Ln (q) and H is of type GLa (q) ⊗ GLb (q), where n = ab and 2 6 a < b. By [19, Proposition 4.4.10] we have H = N.A where N = La (q) × Lb (q) and A 6 (Z(a,q−) × Z(b,q−) ).(Zf × Z2 ). Since d(N ) = 2 we deduce that d(M ) 6 6 if M contains N , so assume otherwise. Then M = (M ∩ N ).A and d(A) 6 4, so it suffices to show that d(M ∩ N ) 6 8. Now M ∩ N is a maximal A-invariant subgroup of N , so M ∩ N = C × Lb (q) or La (q) × D, where C = E ∩ La (q) for some maximal subgroup E of a group F with La (q) 6 F 6 Aut(La (q)), and similarly for D. By applying Theorem 2.1 and Lemma 2.9 we deduce that C and D are 4-generator, so d(M ∩ N ) 6 6. Next suppose G0 = PSpn (q) and H is of type Spa (q) ⊗ Ob (q), where n = ab, b > 3 and q is odd. Here H = N.A, where N = PSpa (q) × PΩb (q) and A 6 [23 ].(Zf × Z2 ). In particular, d(M ) 6 9 if M contains N . Otherwise M = (M ∩ N ).A, where M ∩ N is a maximal A-invariant subgroup of N , and it suffices to show that d(M ∩ N ) 6 7. If both factors of N are simple then M ∩ N = C × PΩb (q) or PSpa (q) × D, where C = E ∩ PSpa (q) and E is maximal in an almost simple group with socle PSpa (q), and similarly for D. By applying Theorem 2.1 we deduce that d(M ∩ N ) 6 6. A very similar argument applies if (a, q) = (2, 3), (b, q) = (3, 3) or (b, ) = (4, +), using Lemmas 2.8 and 2.9. Finally, let us assume G0 = PΩn (q). The usual argument applies if H is of type Spa (q) ⊗ Spb (q), so let us take H to be of type Oa1 (q) ⊗ Ob2 (q). Here q is odd, a, b > 3 and (a, 1 ) 6= (b, 2 ). For brevity, we will assume that 1 = 2 = +, so  = + and 4 6 a < b (the other cases are very similar). By [19, Proposition 4.4.14] we have H = N.A, where + N = PΩ+ a (q) × PΩb (q) and A 6 (D8 × D8 ).Zf . Note that d(N ) 6 4 and every subgroup of (D8 × D8 ).Zf is 5-generator. In particular, if M contains N then d(M ) 6 9, so assume otherwise. Then M = (M ∩N ).A and the usual argument (using Theorem 2.1 and Lemma 2.8) shows that d(M ∩ N ) 6 6, whence d(M ) 6 11.  Lemma 5.7. Proposition 5.1 holds if H ∈ C5 . Proof. First assume G0 = Ln (q) and H is of type GLn (q0 ), where q = q0k for a prime k (with k odd if  = −). Note that (n, q0 ) 6= (2, 2) (see [7, Table 8.1]). If (n, q0 ) = (2, 3) then H∼ = A × B, where A ∈ {A4 , S4 } and B 6 Zk , and we deduce that d(M ) 6 3. The same GENERATION OF SECOND MAXIMAL SUBGROUPS 17 conclusion holds if  = − and (n, q0 ) = (3, 2). In every other case, Lemma 5.2 implies that d(M ) 6 9. Similarly, we can apply Lemma 5.2 if G0 is symplectic or orthogonal, and also if G0 = Un (q) and H is of type Spn (q). Finally, let us assume G0 = Un (q) and H is of type On (q) (so q is odd and n > 3). In view of Lemma 5.2 we may assume that (n, ) = (4, +) (note that (n, q) 6= (3, 3); see [7, Table 8.5]). Here q > 5 (see [7, Table 8.10]) and 2 2 H0 = PSO+ 4 (q).2 = (L2 (q) × L2 (q)).[2 ] = N.[2 ]. (2) More precisely, N < H/Z(H) 6 Aut(N ) with Z(H) 6 Z2 , and the result follows by applying Lemma 2.8.  Lemma 5.8. Proposition 5.1 holds if H ∈ C6 . Proof. First assume G0 = Ln (q) and H is of type r1+2m .Sp2m (r), where n = rm and r is an odd prime. If n = 3 then q = p ≡ 1 (mod 3) (see [7, Table 8.3]), 32 :Q8 6 H 6 AGL2 (3) and it is easy to check that d(M ) 6 3. Now assume n > 5, in which case H = W :(Sp2m (r).A) 6 W :GSp2m (r) and A 6 Z2f , where W = r2m and q = pf , with f an odd divisor of r − 1 (see [19, Proposition 4.6.5]). Since W is the unique minimal normal subgroup of H we may assume that M = W.J for some maximal subgroup J < Sp2m (r).A, so Lemma 2.5 implies that d(M ) 6 8. An entirely similar argument applies if G0 = Un (q). If G0 = L2 (q) and H is of − type 21+2 − .O2 (2) then H = A4 or S4 and the result follows. 1+2m + Next assume G0 = PΩ+ .O2m (2), so q = p > 3 and n = 2m n (q) and H is of type 2+ with m > 3. By [19, Proposition 4.6.8] we have H = W.A with W = 22m and A = Ω+ 2m (2) + (2). In particular, W is the unique minimal normal subgroup of H so we may or O2m assume that M = W.J with J maximal in A. By applying Lemma 2.5 we deduce that − (2) is .O2m d(M ) 6 1 + d(J) 6 7. The case where G0 = PSpn (q) and H is of type 21+2m − entirely similar.  Lemma 5.9. Proposition 5.1 holds if H ∈ C7 . Proof. We refer the reader to [19, Table 4.7.A] for the list of cases that we need to consider. First assume G0 = Ln (q) and H is of type GLa (q) o St with a > 3. Here n = at and (a, q, ) 6= (3, 2, −). We will assume  = + since the case  = − is very similar. To begin with, let us assume that at least one of the following three conditions does not hold: t = 2, a ≡ 2 (mod 4), q ≡ −1 (mod 4). (3) Write PGLa (q) = La (q).hδi and La (q) = hx, yi where |x| and |y| are coprime. Set d = (a, q − 1). According to [19, Proposition 4.7.3] we have H0 = N0 .St and H = N.St , where N0 = La (q)t .A0 , N = La (q)t .A.2b .Zk where A0 = 1c (Zd )t 6 1e (Zd )t = A, b ∈ {0, 1} and k divides logp q, for some divisors c, e of d. If M contains N then M0 = N0 .J for some maximal subgroup J < St and the result quickly follows. For example, if J is a transitive subgroup then M0 is generated by (x, y, 1, . . . , 1), (δ, δ −1 , 1, . . . , 1) and (δ ` , 1, . . . , 1) for some ` > 0, together with at most 4 generators for J. Now assume N 66 M , so M = (M ∩N ).St and M ∩N is a maximal St -invariant subgroup of N . Since S = La (q)t is the unique minimal normal subgroup of H, we may assume that M contains S. Set M̄ = M/S and H̄ = H/S = A.2b .Zk .St . If M̄ contains A then M0 = H0 and thus d(M0 ) 6 4, so assume otherwise. Then M̄ = (M̄ ∩ A).2b .Zk .St and (M̄ ∩ A).St < A.St is maximal, so Lemma 2.7 implies that d((M̄ ∩ A).St ) 6 6 and we deduce that d(M̄ ) 6 8 and d(M ) 6 10. 18 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV To complete the analysis of this case, we may assume that all of the conditions in (3) are satisfied. The above argument goes through unchanged if H contains an element that interchanges the two copies of La (q) in the socle of H, so we may assume that H = (N1 × N2 ).A.2b .Zk , where Ni = La (q) and A, b and k are as above. Note that N1 and N2 are the minimal normal subgroups of H. If M contains both of these subgroups then the previous argument goes through, so we may assume that M contains N1 but not N2 . Set M̄ = M/N1 and H̄ = H/N1 = N2 .A.2b .Zk . Since N2 66 M̄ we have M̄ = (M̄ ∩ N2 ).A.2b .Zk and M̄ ∩ N2 = La (q) ∩ B where B is a maximal subgroup of an almost simple group with socle La (q). By Theorem 2.1 we have d(M̄ ∩ N2 ) 6 4, so d(M̄ ) 6 8 and thus d(M ) 6 10. The remaining C7 cases are similar, so we only give details in the situation where + 0 G0 = PΩ+ n (q) and H is of type Oa (q) o St , with a > 6 and q odd. Let D and D be + + the discriminants of the quadratic forms corresponding to On (q) and Oa (q), respectively. Note that n(q − 1)/4 is always even, so D =  (see [19, Proposition 2.5.10]). Write + + + PO+ a (q) = PSOa (q).hri and PGOa (q) = POa (q).hδi for involutions r and δ. Also fix + + x, y ∈ PSOa (q) such that PSOa (q) = hx, yi. Two cases require special attention: (a) t = 2 and a ≡ 2 (mod 4); (b) t = 3, a ≡ 2 (mod 4) and q ≡ 3 (mod 4). For now, we will assume that we are not in one of these cases. By [19, Proposition 4.7.6] we have H0 = N0 .St and H = N.St , where t 2t−1 t i N0 = PSO+ ], N = PSO+ a (q) .[2 a (q) .[2 ].Zk with i ∈ {2t − 1, 2t} and k a divisor of logp q. If M contains N then M0 = N0 .J with J < St maximal and the result quickly follows. For example, if J is transitive then M0 is generated by (x, 1, . . . , 1), (y, 1, . . . , 1), (r, 1, . . . , 1) and (δ, δ −1 , 1, . . . , 1), together with at most 4 generators for J. Now assume M = (M ∩ N ).St . First consider the case where D0 = , so PSO+ a (q) = + t is the unique minimal normal subgroup of H. As usual, we may PΩ+ (q).2 and S = PΩ (q) a a assume that M contains S, so set M̄ = M/S and H̄ = H/S = A.Zk .St , where A = [2t+i ]. If M̄ contains A then M0 = H0 and thus d(M0 ) 6 4. Otherwise, M̄ = (M̄ ∩ A).Zk .St and (M̄ ∩ A).St is a maximal subgroup of A.St = 1b (D8 o St ), where b = 1 or 2. By Lemma 2.7 we have d((M̄ ∩ A).St ) 6 6, so d(M̄ ) 6 7 and thus d(M ) 6 9. A similar argument applies + if D0 = . Here PSO+ a (q) = PΩa (q) and once again we may assume that M contains + t S = PΩa (q) . The rest of the argument goes through, replacing D8 by V4 . It remains to handle the cases described in (a) and (b) above. First consider (a). 2 b+2 ].Z .Z , We will assume D0 =  (the other case is very similar), so H = PΩ+ k c a (q) .[2 where b ∈ {2, 3, 4}, c ∈ {1, 2} and k divides logp q. Note that [2b+2 ] 6 D8 × D8 is 4generator. If c = 2 then the previous argument goes through, so let us assume c = 1. Here H has two minimal normal subgroups N1 and N2 , both isomorphic to PΩ+ a (q). If M contains S = N1 × N2 then M/S < H/S = [2b+2 ].Zk , so d(M/S) 6 5 and thus d(M ) 6 7. Therefore, we may assume that H contains N1 but not N2 . Set M̄ = M/N1 and H̄ = H/N1 = N2 .[2b+2 ].Zk . Then M̄ = (M̄ ∩ N2 ).[2b+2 ].Zk and Theorem 2.1 implies that d(M̄ ∩ N2 ) 6 4, so d(M̄ ) 6 9 and thus d(M ) 6 11. Finally, let us assume that the conditions in (b) hold, so D0 =  and H = S.A.Zk .B, 3 b where S = PΩ+ a (q) , A = [2 ] with b ∈ {5, 6}, k divides logp q and B ∈ {Z3 , S3 }. In the usual way, it is easy to reduce to the case where M = (M ∩ N ).B. Now B acts transitively on the factors of S, so S is the unique minimal normal subgroup of H and we may assume that M contains S. Set M̄ = M/S and H̄ = H/S = A.Zk .B. If M̄ contains A then GENERATION OF SECOND MAXIMAL SUBGROUPS 19 M0 = H0 and d(M0 ) 6 4, so assume otherwise. Then M̄ = (M̄ ∩ A).Zk .B and (M̄ ∩ A).B is a maximal subgroup of A.B = 1c (V4 o B), where c ∈ {1, 2}. Therefore d((M̄ ∩ A).B) 6 6 by Lemma 2.7, so d(M̄ ) 6 7 and thus d(M ) 6 9 since S is 2-generator.  Lemma 5.10. Proposition 5.1 holds if H ∈ C8 . Proof. First assume G0 = Ln (q). If H is of type Spn (q), then n > 4 and Lemma 5.2 applies. Next suppose H is of type On (q). If (n, q) 6= (3, 3) and (n, ) 6= (4, +), then we can use Lemma 5.2 once again. It is easy to check that d(M ) 6 3 if (n, q) = (3, 3). If (n, ) = (4, +) then (2) holds and we can repeat the argument in the proof of Lemma 5.7. Finally, suppose that H is of type Un (q0 ), where n > 3 and q = q02 . If (n, q) = (3, 4) then d(M ) 6 3, otherwise the result follows from Lemma 5.2. Finally let us assume that G0 = PSpn (q) and H is of type On (q), where q is even, n > 4 and (n, q) 6= (4, 2). If (n, ) 6= (4, +) then H is almost simple and thus d(M ) 6 6. On the other hand, if (n, ) = (4, +) then H0 = O4+ (q) = L2 (q) o S2 = (L2 (q) × L2 (q)).2 = N.2 and N < H 6 Aut(N ), so Lemma 2.8 implies that d(M ) 6 8.  To complete the proof of Proposition 5.1, it remains to deal with certain novelty subgroups H of G, where H0 = H ∩ G0 is non-maximal in G0 . In view of [2] and our earlier work, we may assume that one of the following holds: (a) G0 = PSp4 (q), q even and G contains a graph-field automorphism; (b) G0 = PΩ+ 8 (q) and G contains a triality automorphism. In [2, Section 14], Aschbacher proves a version of his main theorem which describes the various possibilities for H in case (a), but his theorem does not apply in case (b); here the possibilities were determined later by Kleidman [18]. We record the relevant non-parabolic subgroups in Table 2. Note that in case (a) we may assume q > 2 since PSp4 (2)0 ∼ = A6 . G0 Type of H PSp4 (q) O2 (q) o S2 O2− (q 2 ).2   PΩ+ 8 (q) GL3 (q) × GL1 (q) − 2 − 2 O2 (q ) × O2 (q ) [29 ].SL3 (2) Conditions q > 2 even q > 2 even q=p>2 Table 2. Some novelty subgroups Lemma 5.11. Proposition 5.1 holds if G0 = PSp4 (q) and H is in Table 2. Proof. Here H0 = D2(q±1) o S2 or Zq2 +1 .4, so d(M0 ) 6 4 and the result follows.  Lemma 5.12. Proposition 5.1 holds if G0 = PΩ+ 8 (q) and H is in Table 2. Proof. As before, it suffices to show that d(M0 ) 6 9. First assume H is of type GL3 (q) × 2 GL1 (q). Set d = (2, q−1). Working in Ω+ 8 (q) we have H0 = N0 .Z(q−)/d .[2 ] and H = N0 .A, where N0 = d1 GL3 (q) and A = Z(q−)/d .[2a ].B.Zk with a ∈ {2, 3, 4}, B ∈ {Z3 , S3 } and k a divisor of logp q. If M contains N0 then M0 = N0 .C and C 6 Z(q−)/d .[22 ] is 3-generator, so d(M0 ) 6 5. Now assume N0 66 M , so M = (M ∩N0 ).A and M0 = (M ∩N0 ).Z(q−)/d .[22 ], where M ∩ N0 is a maximal A-invariant subgroup of N0 . Now M ∩ SL3 (q) = D ∩ SL3 (q), where D is maximal in a group E of the form SL3 (q) 6 E 6 ΓL3 (q).hγi, 20 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV where γ is a graph automorphism. By applying Theorem 2.1 we deduce that d(M ∩ SL3 (q)) 6 5, so d(M ∩ N0 ) 6 6 and thus d(M0 ) 6 9 as required. If H is of type O2− (q 2 ) × O2− (q 2 ) then H0 = (D2l × D2l ).22 , where l = (q 2 + 1)/(2, q − 1) is odd, and we deduce that d(M0 ) 6 5 since every subgroup of D2l × D2l is 3-generator. In the final case we have H0 = [29 ].SL3 (2) and using Magma one can check that every subgroup of H0 is 8-generator. In particular, d(M0 ) 6 8 and the result follows.  This completes the proof of Proposition 5.1. 6. Exceptional groups In this section we turn to the exceptional groups of Lie type, establishing Theorem 1 for the second maximal subgroups lying in a maximal non-parabolic subgroup. Proposition 6.1. Suppose M < H < G with each subgroup maximal in the next, where G is an almost simple exceptional group of Lie type and H is non-parabolic. Then d(M ) 6 12. Proof. Let G0 be the socle of G, and H0 = H ∩ G0 , M0 = M ∩ G0 . Write G0 = G(q), an exceptional simple group of Lie type over Fq , where q = pe , p prime. With the aid of Magma, it is easy to check that d(M ) 6 4 if G0 = 2F4 (2)0 , G2 (3) or 3D4 (2), so we may assume otherwise. As d(G/G0 ) 6 2 it is sufficient to show that d(M0 ) 6 10. According to [23, Theorem 2], the possibilities for H0 are as follows: (i) H0 is almost simple; (ii) H0 = NG0 (K), where K is a reductive subgroup of G0 of maximal rank, not a maximal torus; the possibilities are listed in [22, Table 5.1]; (iii) H0 = NG0 (T ), where T is a maximal torus of G0 ; the possibilities are listed in [22, Table 5.2]; (iv) The generalized Fitting subgroup F ∗ (H0 ) is as in [23, Table III]; (v) H0 = NG0 (E), where E is an elementary abelian group given in [11, Theorem 1(II)]. In case (i), d(M0 ) 6 4 by Theorem 2.1. In case (iv), with two exceptions H0 has a subgroup H1 of index at most 6 that is a direct product S1 × S2 of non-isomorphic simple groups Si ; in the exceptional cases, H0 has a subgroup H1 ∼ = L2 (q)2 or L2 (q) × G2 (q)2 of index dividing 4. Excluding the exceptional cases, we must have M0 ∩ H1 = S1 × M2 where either M2 = S2 or M2 is a maximal H-invariant subgroup of S2 . Using Theorem 2.1 we see that d(M2 ) 6 4, so d(M0 ) 6 8. The first exceptional case H1 = S1 × S2 ∼ = L2 (q)2 is entirely similar: either M0 ∩ H1 = S1 × M2 as above, or it is a diagonal subgroup isomorphic to L2 (q). In the second exceptional case, the two G2 (q) factors are interchanged by an element of H0 , so either M0 ∩ H1 is M1 × G2 (q)2 with M1 maximal H-invariant in L2 (q), or it is L2 (q) × D where D is a diagonal subgroup of G2 (q)2 isomorphic to G2 (q). In every case we easily see that d(M0 ) 6 8 using Theorem 2.1. Next consider case (v). In this case, either H0 is one of the groups 53 .SL3 (5), 25+10 .SL5 (2), 33+3 .SL3 (3), 33 .SL3 (3), 23 .7, 23 .SL3 (2), (4) or G0 = E7 (q) and H0 = (22 × PΩ+ 8 (q)).S3 with q odd. In the latter case, either M0 + contains PΩ+ (q) in which case d(M 0 ) 6 4, or M0 ∩ PΩ8 (q) is a maximal S3 -invariant 8 subgroup, in which case d(M0 ) 6 6 by Theorem 2.1. The only problematic possibility in the list (4) is H0 = 25+10 .SL5 (2). Let P = O2 (H0 ). Then Φ(P ) = 25 and H0 /P ∼ = SL5 (2) acts on P/Φ(P ) as the wedge-square of the natural module. If M0 contains P , then GENERATION OF SECOND MAXIMAL SUBGROUPS G0 E8 (q) E8 (q) E7 (q) 2 E (q) 6 F4 (q) 21 K q A1 (q)8 2, 3 4 A− 2 2 (q) 7 A1 (q) 2, 3 3 A− 2 2 (q) − A2 (q)2 2 Table 3. Cases with K solvable M0 = P.X where X is maximal in SL5 (2); by inspecting [7, Tables 8.18, 8.19] we see that X is either a parabolic subgroup or 31:5, and so has at most 3 composition factors on P/Φ(P ). In particular, we deduce that d(M0 ) 6 3 + d(X) 6 7 in this case. And if P 66 M0 then M0 = Φ(P ).SL5 (2) and hence d(M0 ) 6 3. Next we handle case (iii). Here H0 = NG0 (T ), where T is a maximal torus of G0 , as listed in [22, Table 5.2]. The groups W = NG0 (T )/T are also listed in Table 5.2 of [22]; these are subgroups of the Weyl group of G0 . Suppose first that T 6 M0 , so that M = T.X with X maximal in NG (T )/T (which is W × hφi, possibly extended by a graph automorphism, where φ is a field automorphism). If T 6= (q ± 1)r with r ∈ {7, 8}, it is clear from the list that d(T ) 6 6, and one checks that d(X) 6 6 also, giving d(M ) 6 12. And if T = (q ± 1)r then W = W (Er ) and one checks that d(X) 6 4 for a maximal subgroup in this case, giving d(M ) 6 r + 4 6 12. Now suppose T 66 M0 . Then M0 = (M ∩ T ).W . A check gives d(W ) 6 2, hence d(M0 ) 6 d(M ∩ T ) + 2 6 10. It remains to handle case (ii), in which H0 = NG0 (K), where K is a reductive subgroup of G0 of maximal rank, not a maximal torus. The possibilities for K and H0 /K are listed Q in [22, Table 5.1]. In all cases K is a central product Li ◦ R, where each Li is either quasisimple or in {SL2 (2), SL2 (3), SU3 (2)}, and R is an abelian p0 -group of rank at most 2 (also R = 1 unless G0 is of type E7 , E6 or 3D4 ). The cases where K is solvable are those in Table 3. We exclude these cases from consideration until the end of the proof. Let N = coreH (M ). By Lemma 2.3 we may assume that N 6= 1. Assume first that K 6 N . Then M = K.X where X is maximal in H/K. Inspecting the list of possibilities for K and H/K, it is easy to check that d(K) 6 4 and d(X) 6 8, giving the conclusion. Next assume that N 6 Z(K). Then H = M K so dM (N ) = dH (N ). Inspection of the list shows that d(N ) 6 2 except for the cases K = A1 (q)r (r = 7, 8), and in these cases Z(K) = 2r−4 and dM (N ) 6 2. Hence by Remark 2.4 we have d(M ) 6 dM (N ) + 10 6 12, as required. Now assume K 66 N and N 66 Z(K). Then N contains a product N0 of factors Li of K. In all but two cases in the list where K has at least two isomorphic factors Li , H0 /K acts transitively on these factors; the two exceptional cases are K = A2 (q)2 in F4 (q) and K = A1 (q)2 in G2 (q). Hence inspecting the list, we see that K is in Table 4, with N0 equal to one of the factors (or A1 (q)3 ): Write K = N0 K0 , where K0 is the product of the factors Li (or R) not in N0 . Then M ∩ K = N0 M0 , where M0 is a maximal H-invariant subgroup of K0 . From the above table, K0 is either a single factor Li or R of K, or it is A1 (q)3 . In the former case, using Theorem 2.1 we see that d(M0 ) 6 4, whence d(M ) 6 d(N0 ) + d(M0 ) + d(H/K) 6 12. The other possibility is that K0 = A1 (q)3 , N0 = D4 (q). If q > 3 then M0 must be a diagonal subgroup of K0 , so d(M0 ) 6 2; and if q 6 3 then H/N0 ∼ = A1 (q)3 .d3 .S3 where d = (2, q − 1), and we easily check that d(M/N0 ) 6 10, so that d(M ) 6 d(N0 ) + 10 6 12. 22 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV G0 E8 (q) E7 (q) E6 (q) K A1 (q)E7 (q), A2 (q)E6 (q) A1 (q)D6 (q), A2 (q)A5 (q), 3D4 (q)A1 (q 3 ), D4 (q)A1 (q)3 , E6 (q) ◦ (q − ) A1 (q)A5 (q), A2 (q 2 )A2− (q), 3D4 (q) × (q 2 + q + 1), D5 (q) ◦ (q − ), D4 (q) ◦ (q − )2 F4 (q) A1 (q)C3 (q), A2 (q)2 G2 (q) A1 (q)2 3D (q) A (q)A (q 3 ), A (q) ◦ (q 2 + q + 1) 4 1 1 2 Table 4. Cases with K 66 N and N 66 Z(K) It remains to handle the cases where K is solvable, given in Table 3. The most complicated example is K = A1 (q)8 in E8 (q) with q = 3. We deal with this case and leave the others to the reader. In this case Z(K) = 24 , H/K ∼ = 24 .AGL3 (2), so H = 24 .216 .38 .24 .23 .L3 (2). Let R denote the solvable radical of H. If R 6 M then M = R.X where X is maximal in L3 (2); since d(X) = 2 and dM (A1 (3)8 ) = 2, it follows that d(M ) 6 2+d(24 .23 )+d(X) < 12. And if R 66 M then M/M ∩ R ∼ = L3 (2) and it follows that dM (M ∩ R) 6 10, whence d(M ) 6 10 + d(L3 (2)) = 12.  7. Parabolic subgroups and Number Theory In this section we complete the proof of Theorems 1 and 3 by handling second maximal subgroups M lying in parabolic subgroups. In particular we relate the boundedness of d(M ) to the number-theoretic question (?) stated in the Introduction. Lemma 7.1. Let q = pk , where p is a prime and k > 1, let e be a divisor of q − 1 and let E be the subgroup of order e of the multiplicative group F× q . Let M = Fq .E be the ∼ corresponding subgroup of the semidirect product Fq .F× AGL = 1 (q). Then q k/` 6 d(M ) 6 k/` + 1, where ` = min{i > 1 : e divides pi − 1} is the multiplicative order of p modulo e. Proof. Let K be the minimal subfield of Fq containing E. Then K has order p` where ` divides k. Therefore Fq has dimension k/` as a vector space over K. Thus M is generated by a basis of that vector space together with a generator of the cyclic group E, so d(M ) 6 k/` + 1. To prove the other inequality, suppose (ai , bi ) are generators for M , where ai ∈ Fq , bi ∈ E and i = 1, . . . , d. Then a1 , . . . , ad generate Fq as a vector space over K, so d > k/`, as required.  The next result helps in establishing a connection between bounding the number of generators of second maximal subgroups and the answer to the number-theoretic question (?) stated in Section 1. Lemma 7.2. Let G = L2 (q), 2 B2 (q) or 2 G2 (q) where q = pk (p prime), let d = (2, q − 1), 1 or 1 respectively, and let B = U T be a Borel subgroup of G with unipotent normal subgroup U and Cartan subgroup T of index d in F× q . Let s be a prime divisor of q − 1 , so that B has a maximal subgroup M = U.e of index s. Let ` be the and let e = q−1 ds multiplicative order of p modulo e. Then (i) we have k/` 6 d(M ) 6 k/` + 1; GENERATION OF SECOND MAXIMAL SUBGROUPS 23 (ii) d(M ) is unbounded if and only if ` = o(k); (iii) either k ∈ {`, 2`} (in which case d(M ) 6 3), or pk −1 p` −1 = s is prime. Proof. We first prove part (i). If G = L2 (q), then U ∼ = Fq and so k/` 6 d(M ) 6 k/` + 1 by the previous lemma. The other families 2 B2 (q) and 2 G2 (q) are handled by the same argument, noting that U/Φ(U ) ∼ = Fq with T acting by scalar multiplication (see [32, 34]). pk −1 p` −1 · e p` −1 that k` is even, Part (ii) follows immediately from part (i). To prove (iii), note that ds = and s is a prime. If pk −1 p` −1 pk −1 . This implies p` −1 (q0m −1)(q0m +1) , which forces q0 −1 6= 1, s, then d = 2 and 2s = say k` = 2m. Then writing q0 = p` , we have 2s = k = 2`. This proves (iii). m = 1, hence  Lemma 7.3. Let G be an almost simple group of Lie type with socle G0 . Suppose G has a maximal Borel subgroup B, and suppose B has a maximal subgroup M with d(M ) > 12. Then G0 = L2 (q), 2 B2 (q) or 2 G2 (q), and M ∩ G0 is as in Lemma 7.2. Proof. These are the cases where G0 has BN -rank 1, or is L3 (q), C2 (2e ) or G2 (3e ) and G contains a graph or graph-field automorphism. We need to rule out the latter three cases, and also the case where G0 = U3 (q). As before, set M0 = M ∩ G0 . Note that if G0 = L2 (q), 2 B2 (q) or 2 G2 (q), then Lemma 2.3 shows that M ∩ G0 is as in Lemma 7.2. Consider first G0 = U3 (q), so that B ∩ G0 = QT where Q = q 1+2 is a special group with Q0 = Φ(Q) ∼ = Z(q2 −1)/d with d = (3, q + 1). If Q 6 M then = F2q and T ∼ = Fq , Q/Q0 ∼ M = QS where S contains either Zq−1 or Z(q+1)/d (note that d(S) 6 2). Using Lemma 7.1 we see that dM/Q0 (Q/Q0 ) 6 4 and it follows that d(M ) 6 4 + d(S) + 1 6 7, a contradiction. And if Q 66 M then M0 = (M ∩ Q).T and M ∩ Q is a maximal T -invariant subgroup of Q; it follows that dM0 (M ∩ Q) 6 2, so d(M0 ) 6 2 + d(T ) = 3 and thus d(M ) 6 5, a contradiction. Next consider G0 = C2 (q) where q = 2e and G contains an element inducing a graphfield automorphism on G0 . Adopting the notation of [10], let B ∩ G0 = QT where Q is generated by the positive root groups relative to a fixed root system (so |Q| = q 4 ), and T = hhα (t), hβ (u) : t, u ∈ Fq i, where α, β are fundamental roots with α long and β short. By assumption, G = G0 hτ i, where τ is a graph-field automorphism of G0 normalizing Q and T , sending hα (t) 7→ hβ (tr ), hβ (u) 7→ hα (u2r ), where r = 2f for some f 6 e. Let π1 , π2 : T → F× q be the maps sending hα (t), hβ (u) to t, u respectively. Assume first that Q 6 M , so M0 = QT0 and T0 is a maximal τ -invariant subgroup of T. × If π1 (T0 ) = F× q then π2 (T0 ) = Fq also (as T0 is τ -invariant), and so T0 acts as the full group of scalars on each factor of a series 1 = Q0 < Q1 < · · · < Q4 = Q with Qi /Qi−1 ∼ = Fq for all i; hence dM0 (Q) 6 4 and it follows that d(M ) 6 4 + d(T0 ) + 1 6 7, a contradiction. Now assume π1 (T0 ) = A < F× q . As T0 is τ -invariant, π2 (T0 ) = A as well, and so by maximality T0 = {hα (t)hβ (u) : t, u ∈ A}. If e is even (recall that q = 2e ) then (again by maximality) |A| is divisible by q 1/2 −  for some  = ±1, and now the result follows as in the previous paragraph, using Lemma 7.1. On the other hand, if e is odd, then the automorphism t 7→ t2 of Fq has odd order, so there is an automorphism φ of Fq such that φ2 (t) = t2 for all t ∈ Fq . But then h{hα (t)hβ (u), hα (φ(v))hβ (v) : t, u ∈ A, v ∈ F× q }i is a proper τ -invariant subgroup of T , contradicting the maximality of T0 . 24 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Finally for this case (G0 = C2 (q)), if Q 66 M then M0 = (M ∩ Q).T and M ∩ Q is a maximal T -invariant subgroup of Q; it follows that dM0 (M ∩ Q) 6 3 and so d(M ) 6 3 + d(T ) + 1 6 6, a contradiction. The case where G0 = G2 (3e ) and G contains a graph or graph-field automorphism is handled in very similar fashion. The case G0 = L3 (q) is also similar, but this time τ sends hα (t) 7→ hβ (tr ), hβ (u) 7→ hα (ur ) for all t, u ∈ F× q , and in the case of the above argument where M0 = QT0 , we must have πi (T0 ) = F× for i = 1, 2, giving dM0 (Q) 6 3.  q Proposition 7.4. Theorem 1 holds in the case where M < H < G with G an almost simple group of Lie type and H a maximal parabolic subgroup of G. Proof. Let G0 denote the socle of G, which is a simple group of Lie type over Fq , a field of characteristic p. Let M0 = M ∩ G0 , and write H0 = H ∩ G0 = P = QR, a parabolic subgroup with unipotent radical Q and Levi subgroup R. We use the notation P = Pij... to mean a parabolic with excluded nodes i, j, . . . from the Dynkin diagram. By Lemma 7.3, we may assume that H0 is not a Borel subgroup. In particular, G0 is not of type 2G2 or 2B2 . We also exclude for now the cases where (G0 , p) is special in the sense of [4] – that is to say, p = 2 and G0 is of type Cn , F4 , 2F4 , G2 , or p = 3 and G0 is of type G2 . We shall deal with these excluded cases at the end of the proof. Suppose first that G0 is untwisted and H0 = Pi for some i. Then by [4, Theorem 2(a)], Q/Q0 has the structure of an irreducible Fq R-module, and Q0 6 Φ(Q), so Q0 6 M0 . It follows that either M0 = QK with K a maximal H/Q-invariant subgroup of R, or M0 = Q0 .R. Consider the case where M0 = QK. Now R = R0 Z, where Z is a central torus of rank 1 inducing scalars on the module Q/Q0 . Hence either K = R0 Z0 with Z0 < Z, or K = K0 Z with K0 < R0 . For G0 classical, R0 is of type SLi (q) × SLn−i (q) or SLi (q) × Cln−2i (q) and Q/Q0 is the corresponding tensor product space U ⊗ W with dim U = i, dim W = n − i or n − 2i (here Cln−2i (q) denotes an appropriate classical group of dimension n − 2i over Fq ). Then using Lemma 2.5 we see that Q/Q0 is a cyclic K-module. Using Theorem 2.1 we deduce that d(K) 6 6. Hence d(M0 ) 6 1 + d(K) 6 7. For G0 of exceptional type, the irreducible module Q/Q0 has dimension at most 64 with equality for (G0 , R0 ) = (E8 (q), D7 (q)), so we get d(M0 ) 6 dim(Q/Q0 ) + d(K) 6 70. Now suppose M0 = Q0 .R. Here we bound d(M0 ) by dM0 (Q0 ) + d(R). Now R0 is a commuting product of at most 3 factors which are either quasisimple or groups in {SL2 (q), Ω3 (q), Ω+ 4 (q) : q 6 3}; hence it is straightforward to check that d(R) 6 4. Also dM0 (Q0 ) is at most the number of R-composition factors in Q0 . By [4, Theorem 2], this is 1 less than the i-th coefficient of the highest root in the root system of G0 , hence is at most 1 for G0 classical, and at most 5 for G0 exceptional. We conclude that d(M0 ) 6 9 in this case. Next assume that G0 is twisted (and not special) – hence of type 2An , 2Dn , 2E6 or 3D4 . In the first case consider the covering group Ĝ0 = SUm (q) (where m = n + 1), where H0 = Pi = QR with R of type SLi (q 2 ) × SUm−2i (q). Here Q/Q0 has the structure of the R-module V1 + V2 with V1 = U ⊗ W and V2 = U (q) ⊗ W ∗ , where U, W are the natural modules for the factors of R. Hence as above, the possibilities for M0 are QK, Q1 .R and Q2 .R, where Qi = Q0 .Vi < Q. We deal with the possibilities just as before. The 2Dn or 2E6 cases are very similar – again, Q/Q0 is a sum of at most two irreducible R-submodules, leading to three possibilities for M0 as above. Finally, if G0 = 3D4 (q) then H0 = Pi with i = 1 or 2. If i = 2 then R0 = A1 (q 3 ) and Q/Q0 is the irreducible Fq R-module (q) V2 ⊗ V2 (q 2 ) ⊗ V2 ; and if i = 1 then R contains A1 (q) ◦ (q 3 − 1) and again Q/Q0 is an GENERATION OF SECOND MAXIMAL SUBGROUPS 25 irreducible Fq R-module (of dimension 6). In either case the result follows in the usual way. The case where G0 is of type An , Dn , D4 or E6 and G contains a graph automorphism is very similar. In these cases, the maximal parabolics of G for which Q/Q0 is a reducible R-module are Pi,n−i (for An ), Pn−1 (for Dn ), P134 (for D4 when G contains a triality automorphism) and P16 , P35 (for E6 ). For these, [4] shows that Q/Q0 is a sum of two irreducible R-modules (three for the D4 case), and we argue as in the previous paragraph. It remains to handle the cases where G0 is special. These are dealt with by the same method as above. By the proof of [8, Lemma 7.3], Q/Q0 has at most 4 Fq R-module composition factors, so we can compute the possibilities for M0 and bound d(M0 ) just as before.  By combining this result with Propositions 3.1, 4.1, 5.1 and 6.1, we conclude that the proof of Theorem 1 is complete. Remark 7.5. The upper bound of 70 in part (ii) of Theorem 1 is not sharp, and we make some remarks here about how one could go about improving it. As observed in the proof of Proposition 7.4, we have this upper bound of 70 because of second maximal subgroups M < QR = P1 , a D7 -parabolic subgroup of E8 (q), of the form M = QK0 Z where K0 is a maximal subgroup of D7 (q). To improve the bound significantly, one would have to study the actions of such subgroups K0 on Q/Q0 , which is a 64-dimensional spin module for D7 (q). Likewise, the E7 -parabolic P8 of E8 (q) has maximal subgroups M = QK0 Z with K0 a maximal subgroup in E7 (q) (not all of which are known); consequently, in order to improve the obvious upper bound d(M ) 6 dim(Q/Q0 ) + d(K0 ) 6 60 in this case, one would have to study the actions of such K0 on the 56-dimensional E7 (q)-module Q/Q0 . We are also in a position to give a proof of Theorem 3. Proof of Theorem 3. Clearly, part (i) of Theorem 3 implies (ii), and (ii) implies (iii). For the next implication, note that the question (?) stated in Section 1 has a negative answer if and only if there exists a constant c such that if p is a prime and (pk − 1)/(p` − 1) is prime for some natural numbers k, `, then k 6 c`. Hence the fact that (iii) implies (iv) follows from Lemma 7.2. Finally, we show that (iv) implies (i). Assume (iv) holds, and let G be an almost simple group with socle G0 . Let M be second maximal in G. By Theorem 1, we have d(M ) 6 70 except possibly if G0 = L2 (q), 2 B2 (q) or 2 G2 (q), and M is maximal in a Borel subgroup B of G. In the latter cases, B ∩ G0 = U T as in Lemma 7.2. If U 66 M then d(M ) 6 10 by Lemma 2.3; and if U 6 M , then d(M ) is bounded by Lemma 7.2 together with the assumption (iv). Hence (iv) implies (i) and the proof of Theorem 3 is complete.  8. Random generation and third maximal subgroups In this final section we prove Proposition 4 and Theorems 5 and 6. Proof of Proposition 4. Let p > 5 be a prime such that p ≡ ±3 (mod 8). The group PGL2 (p) has a maximal subgroup S4 (cf. [14]), and Sp+1 has a maximal subgroup PGL2 (p) (by [21]). Moreover, for n = 2(p + 1), the imprimitive subgroup S2 o Sp+1 is maximal in Sn (again by [21]). Hence we have the following chain of subgroups of Sn , each maximal in the previous one: Sn > S2 o Sp+1 > S2 o PGL2 (p) > (S2 )p+1 .S4 . 26 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV Write M = (S2 )p+1 .S4 , and let B be the base group (S2 )p+1 . By the Schreier index formula, d(B) − 1 6 |M : B| (d(M ) − 1), and hence p d(B) − 1 = . 24 24 Since M is third maximal in Sn and p can be arbitrarily large, this completes the proof of the proposition.  d(M ) > For the proof of Theorem 5, we need the following result on chief factors of second maximal subgroups. Proposition 8.1. Let M be a second maximal subgroup of an almost simple group. Then γ(M ) 6 5, where γ(M ) is the number of non-abelian chief factors of M . Proof. Let G be an almost simple group with socle G0 and write M < H < G with M maximal in H and H maximal in G. Note that if N is a normal subgroup of M , then γ(M ) 6 γ(N ) + γ(M/N ). In particular, if N is solvable then γ(M ) = γ(M/N ). By [8, Lemma 8.2], we have γ(M ) 6 3 if H is almost simple, so we may assume otherwise. More generally, if H is of the form H = N.A, where N is solvable and A is almost simple, then either M = (M ∩ N ).A and γ(M ) = 1, or M = N.J and J < A is maximal, so γ(M ) 6 3. Similarly, if H = N.(A × B) with N solvable and A and B almost simple, then either γ(M ) = 2 or M = N.J with J < A × B maximal and it is easy to check that γ(M ) = γ(J) 6 4. If G0 is sporadic then all the maximal subgroups of G are known (apart from a handful of small almost simple candidates in the Monster) and it is straightforward to verify the bound γ(M ) 6 4 by direct inspection. Next suppose G0 = An is an alternating group. As noted in the proof of Proposition 3.1, the possibilities for H are determined by the O’NanScott theorem and once again it is easy to check that γ(M ) 6 4. This bound is sharp. For example, if G = Sn and H = Sk o St , where k > 5 and t > 11, then M = (Sk )t .(S5 × St−5 ) is a maximal subgroup of H with γ(M ) = 4. Next assume G0 is a classical group. Here we use [19] to inspect the possibilities for H (recall that we may assume H is not almost simple) and one checks that γ(M ) 6 4 if H is non-parabolic. In fact, the same bound holds in all cases, with the possible exception of the case where G0 = Ln (q) and H is a parabolic subgroup of type Pm,n−m as described in [19, Proposition 4.1.22]. In the latter case, we could have γ(M ) = γ(J) + 2 where J = K ∩ La (q) for some maximal subgroup K of an almost simple group with socle La (q) (here a = m or n − m). Therefore, γ(M ) 6 5. Similar reasoning applies when G0 is an exceptional group. A convenient description of the maximal subgroups of G is given in [24, Theorem 8] and it is straightforward to show that γ(M ) 6 5.  We now derive consequences concerning the invariant ν(M ) defined in Section 1. Our main tool is Theorem 1 of Jaikin-Zapirain and Pyber [16]. Corollary 8.2. There exists an absolute constant c such that if M is a second maximal subgroup of an almost simple group, then ν(M ) 6 c d(M ). Consequently ν(M ) is bounded if and only if d(M ) is bounded. Proof. Let β be the constant in [16, Theorem 1]. By combining Proposition 8.1 with this theorem, we obtain ν(M ) < βd(M ) + The result follows. log(γ(M )) 6 βd(M ) + 1. log 5  GENERATION OF SECOND MAXIMAL SUBGROUPS 27 Proof of Theorem 5. Let G be an almost simple group with socle G0 and let M be a second maximal subgroup of G which is not as in part (iii) of Theorem 1. Then d(M ) 6 70 by Theorem 1, and the result follows from Corollary 8.2.  For the proof of Theorem 6 we need the following result, which may be of some independent interest. Lemma 8.3. Let R be a finite-dimensional algebra over a finite field F. Let M be an Rmodule of finite dimension over F. Then M has at most |M/JM |−1 maximal submodules, where J is the Jacobson radical of R. Moreover, this upper bound is best possible. Proof. It is well known that every maximal submodule of M contains JM . Therefore the number of maximal submodules of M equals the number of maximal submodules of M/JM (as an R/J-module). This enables us to reduce to the case where J = 0, so that R is a semisimple algebra and M is a semisimple R-module. Hence we may write m M M= ni S i , i=1 where the Si (1 6 i 6 m) are pairwise non-isomorphic simple R-modules, and ni > 1 is the multiplicity of Si . ∼ Let M0 < M be a maximal submodule. Then M/M L 0 = Si for some unique i with 1 6 i 6 m. It follows that M0 ⊇ Mi where Mi = j6=i nj Sj . Hence M0 /Mi may be regarded as a maximal submodule of ni Si . The number of such maximal submodules is less than |Hom(ni Si , Si )| = |End(Si )|ni . Since Si (being simple) is a cyclic module we have |End(Si )| 6 |Si |. It follows that M has less than |Si |ni maximal submodules M0 satisfying M/M0 ∼ = Si . Summing over i we see that the number of maximal submodules of M is less than m m X Y ni |Si | 6 |Si |ni = |M |. i=1 i=1 This completes the proof of the upper bound. To show that this upper bound is best possible, let R = F = F2 and let M be a ddimensional vector space over F. Then |M/JM | = 2d and M has |M/JM | − 1 maximal submodules.  Proof of Theorem 6. Let G be an almost simple group with socle G0 . By [8, Corollary 6], G has at most na second maximal subgroups of index n for some absolute constant a and for all n > 1. It therefore suffices to show the following. Claim. There is an absolute constant b such that, for every n > 1, every second maximal subgroup M of G has at most nb maximal subgroups of index n in G. Indeed, assuming the claim, a third maximal subgroup N of index n in G is contained in some second maximal subgroup M of G, which – being of index at most n – can be chosen in at most na+1 ways. Given M , the third maximal subgroup N can be chosen in at most nb ways. Thus G has at most na+b+1 third maximal subgroups of index n. To prove the claim, let M be a second maximal subgroup of G. Recall that mn (M ) denotes the number of maximal subgroups of M of index n in M . If mn (M ) 6 nb for an absolute constant b and for all n then the claim follows immediately. 28 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV We show that this is the case assuming G0 is not L2 (q), 2 B2 (q) or 2 G2 (q). Indeed, in this case we have ν(M ) 6 c by Theorem 5, so by [26, Proposition 1.2] we have mn (M ) 6 nb where b = c + 3.5. Now assume that G0 = L2 (q), 2 B2 (q) or 2 G2 (q). We apply Lemma 7.3 which describes the second maximal subgroups M of G for which d(M ) is possibly unbounded. By Corollary 8.2 these are the ones for which ν(M ) is possibly unbounded. Suppose G0 = L2 (q) with q = pk , and let G = G1 .A where G1 = G ∩ PGL2 (q) and A is a group of field automorphisms of order dividing k. Set f = |A|. The relevant second maximal subgroups M are of the form U.T1 .A, where U ∼ = Fq and T1 6 F× q has order e. Let ` be the multiplicative order of p modulo e as in Lemma 7.2. Note that |G : M | > q. We shall show that such subgroups M have less than n4 maximal subgroups of index n in G. The maximal subgroups of such a group M split naturally into two types. The first type is U.X where X is maximal in T1 .A. Now, T1 .A is metacyclic, and so are its subgroups. Since all subgroups of T1 .A are 2-generated, there are at most |T1 .A|2 = e2 f 2 < q 2 k 2 < q 4 such subgroups (including non-maximal ones). This proves the claim with b = 4 for subgroups of M of the first type. The second type of subgroups of M is U0 .T1 .A, where U0 is a proper Fp` -subspace of U ∼ = Fq that is maximal A-invariant. Let q0 = p` and consider the group algebra R = Fq0 [A]. Then U, U0 are R-modules and U0 is a maximal submodule of U . Applying Lemma 8.3, there are fewer than |U | = q possibilities for U0 . We now claim that, given U0 , there are less than q 3 subgroups of M of type U0 .T1 .A. Indeed, T1 is split in U0 .T1 , so there are less than q possibilities for U0 .T1 ; and the cyclic group A is generated by an element of the form uφ where u ∈ U0 .T1 and φ is a fixed field automorphism, so there are less than q 2 possibilities for such a generator, hence less than q 3 possibilities in all for U0 .T1 .A. We conclude that the number of maximal subgroups of M of the second type is also less than q 4 . Since |G : M | > q this completes the proof of the claim for G0 = L2 (q), with b = 4. The proofs for Suzuki and Ree groups are similar, and this completes the proof of the claim, and hence of the theorem.  GENERATION OF SECOND MAXIMAL SUBGROUPS 29 References [1] M. Aschbacher, On intervals in subgroup lattices of finite groups, J. Amer. Math. Soc. 21 (2008), 809–830. [2] M. Aschbacher, On the maximal subgroups of the finite classical groups, Invent. Math. 76 (1984), 469–514. [3] M. Aschbacher and R. Guralnick, Some applications of the first cohomology group, J. Algebra 90 (1984), 446–460. [4] H. Azad, M. Barry and G.M. Seitz, On the structure of parabolic subgroups, Comm. Algebra 18 (1990), 551–562. [5] A. Basile, Second maximal subgroups of the finite alternating and symmetric groups, PhD thesis (Australian National University, 2001), arxiv:0810.3721. [6] W. Bosma, J. Cannon and C. Playoust, The Magma algebra system I: The user language, J. Symbolic Comput. 24 (1997), 235–265. [7] J.N. Bray, D.F. Holt and C.M. Roney-Dougal, The Maximal Subgroups of the Low-dimensional Finite Classical Groups, London Math. Soc. Lecture Note Series, vol. 407, Cambridge University Press, 2013. [8] T.C. Burness, M.W. Liebeck and A. Shalev, Generation and random generation: From simple groups to maximal subgroups, Advances in Math. 248 (2013), 59–95. [9] T.C. Burness, E.A. O’Brien, and R.A. Wilson, Base sizes for sporadic simple groups, Israel J. Math. 177 (2010), 307–334. [10] R.W. Carter, Simple groups of Lie type, John Wiley and Sons, 1972. [11] A.M. Cohen, M.W. Liebeck, J. Saxl, and G.M. Seitz, The local maximal subgroups of exceptional groups of Lie type, Proc. London Math. Soc. 64 (1992), 21–48. [12] J.H. Conway, R.T. Curtis, S.P. Norton, R.A. Parker, and R.A. Wilson, Atlas of Finite Groups, Oxford University Press, 1985. [13] F. Dalla Volta and A. Lucchini, Generation of almost simple groups, J. Algebra 178 (1995), 194–223. [14] L.E. Dickson, Linear groups with an exposition of the Galois field theory, Teubner, Leipzig 1901 (Dover reprint 1958). [15] W. Feit, An interval in the subgroup lattice of a finite group which is isomorphic to M7 , Algebra Universalis 17 (1983), 220–221. [16] A. Jaikin-Zapirain and L. Pyber, Random generation of finite and profinite groups and group enumeration, Annals of Math. 173 (2011), 769–814. [17] W.M. Kantor and A. Lubotzky, The probability of generating a finite classical group, Geom. Dedicata 36 (1990), 67–87. [18] P.B. Kleidman, The maximal subgroups of the finite 8-dimensional orthogonal groups PΩ+ 8 (q) and of their automorphism groups, J. Algebra 110 (1987), 173–242. [19] P.B. Kleidman and M.W. Liebeck, The Subgroup Structure of the Finite Classical Groups, London Math. Soc. Lecture Note Series, vol. 129, Cambridge University Press, 1990. [20] M.W. Liebeck, B.M.S. Martin and A. Shalev, On conjugacy classes of maximal subgroups of finite simple groups, and a related zeta function, Duke Math. Journal 128 (2005), 541–557. [21] M.W. Liebeck, C.E. Praeger and J. Saxl, A classification of the maximal subgroups of the finite alternating and symmetric groups J. Algebra 111 (1987), 365–383. [22] M.W. Liebeck, J. Saxl, and G.M. Seitz, Subgroups of maximal rank in finite exceptional groups of Lie type, Proc. London Math. Soc. 65 (1992), 297–325. [23] M.W. Liebeck and G.M. Seitz, Maximal subgroups of exceptional groups of Lie type, finite and algebraic, Geom. Dedicata 36 (1990), 353–387. [24] M.W. Liebeck and G.M. Seitz, A survey of of maximal subgroups of exceptional groups of Lie type, in Groups, combinatorics & geometry (Durham, 2001), 139–146, World Sci. Publ., 2003. [25] M.W. Liebeck and A. Shalev, The probability of generating a finite simple group, Geom. Dedicata 56 (1995), 103–113. [26] A. Lubotzky, The expected number of random elements to generate a finite group, J. Algebra 257 (2002), 452–459. [27] A. Mann, Positively finitely generated groups, Forum Math. 8 (1996), 429–459. [28] A. Mann and A. Shalev, Simple groups, maximal subgroups, and probabilistic aspects of profinite groups, Israel J. Math. 96 (1996), 449–468. [29] I. Pak, On probability of generating a finite group, preprint (1999). [30] P.P. Pálfy, On Feit’s examples of intervals in subgroup lattices, J. Algebra 116 (1988), 471–479. [31] R. Steinberg, Generators for simple groups, Canad. J. Math. 14 (1962), 277–283. [32] M. Suzuki, On a class of doubly transitive groups, Annals of Math. 75 (1962), 105–145. [33] J. Thévenaz, Maximal subgroups of direct products, J. Algebra 198 (1997), 352–361. [34] H.N. Ward, On Ree’s series of simple groups, Trans. Amer. Math. Soc. 121 (1966), 62–89. 30 TIMOTHY C. BURNESS, MARTIN W. LIEBECK, AND ANER SHALEV [35] R.A. Wilson et al., A World-Wide-Web http://brauer.maths.qmul.ac.uk/Atlas/v3/. Atlas of finite group representations, T.C. Burness, School of Mathematics, University of Bristol, Bristol BS8 1TW, UK E-mail address: [email protected] M.W. Liebeck, Department of Mathematics, Imperial College, London SW7 2BZ, UK E-mail address: [email protected] A. Shalev, Institute of Mathematics, Hebrew University, Jerusalem 91904, Israel E-mail address: [email protected]
4math.GR
VARIATIONS ON A THEME BY HIGMAN arXiv:1604.05454v2 [math.GR] 21 Apr 2016 NICOLAS MONOD A BSTRACT. We propose elementary and explicit presentations of groups that have no amenable quotients and yet are SQ-universal. Examples include groups with a finite K (π, 1), no Kazhdan subgroups and no Haagerup quotients. 1. I NTRODUCTION In 1951, G. Higman defined the group (1) Hign = ai (i ∈ Z/nZ) : [ ai−1 , ai ] = ai and proved that for n ≥ 4 it is infinite without non-trivial finite quotient [8]. Since the presentation (1) is explicit and simple, A. Thom suggested that Hign is a good candidate to contradict approximation properties for groups and proved such a result in [20]. Perhaps the most elusive approximation property is still soficity [6, 21]; but a non-sofic group would in particular not be residually amenable, a statement we do not know for the Higman groups (cf. also [7]). The purpose of this note is to propound variations of Higman’s construction with no non-trivial amenable quotients at all. There are several known sources of groups without amenable quotients since it suffices to take a (non-amenable) simple group to avoid all possible quotients. However, as Thelonius Sphere Monk observed, simple ain’t easy. To wit, one had to wait until the break-through of Burger–Mozes [2, 3] for simple groups of type F, i.e. admitting a finite K (π, 1). Before this, no torsion-free finitely presented simple groups were known. The examples below are of a completely opposite nature because they admit a wealth of quotients: indeed, like Hign , they are SQ-universal, i.e. contain any countable group in a suitable quotient. It follows that they have uncountably many quotients [13, §III], despite having no amenable quotients. We shall start with the easiest examples, whose cyclic structure is directly inspired by (1). Below that, we propose a cleaner construction, starting from copies of Z only, which might be a better candidate to contradict approximation properties; the price to pay is to replace the cycle by a more complicated graph. Disclaimer. No claim is made to produce the first examples of groups with a hodgepodge of sundry properties (for instance, if G is a Burger–Mozes group, then G ∗ G satisfies many properties of Gn in Theorem 2 below, though with “amenable” instead of “Haagerup”). Our goal is to suggest transparent presentations for which the stated properties are explicit and their proofs effective. Date: April 2016. 1 2 NICOLAS MONOD 1.A. Starting from large groups. Given a group K, an element x ∈ K and a positive integer n, we define the group K (n,x ) = Ki (i ∈ Z/nZ) : [ xi−1 , xi ] = xi , where Ki , xi denote n independent copies of K, x. Thus, K (n,e) = K ∗n and Hign = Z(n,1) . We recall that a group is normally generated by a subset if no proper normal subgroup contains that subset. Following the ideas of Higman and Schupp, we obtain: Proposition 1. Let K be a group normally generated by an element x of infinite order and let n ≥ 4. (i) If K has no infinite amenable quotient (e.g. if K is Kazhdan), then K (n,x ) has no non-trivial amenable quotient. (ii) If K is finitely presented, torsion-free, type F∞ , or type F, then K (n,x ) has the corresponding property. (iii) Every countable group embeds into some quotient of K (n,x ). Remark. Suppose that C is any class of groups closed under taking subgroups. The proof of (i) shows: if every quotient of K in C is finite, then K (n,x ) has no non-trivial quotient in C . For instance, if K is Kazhdan, then K (n,x ) has no non-trivial quotient with the Haagerup property. Example. The group K = SLd (Z) is an infinite, finitely presented (even type F∞ ) Kazhdan group for all d ≥ 3 and the Steinberg relations show that it is normally generated by any elementary matrix (with coefficient 1). Alternatively, the Steinberg group itself K = Std (Z) has the same properties (it is Kazhdan because it is a finite extension of SLd (Z), see e.g. [12, 10.1]). This gives us the following presentations of SQ-universal type F∞ groups without Haagerup quotients: Sd,n = * p,q Ei p,q q,r p,r + [ Ei , Ei ] = Ei ( p 6 = r 6 = q ) p,q r,s (i ∈ Z/nZ, 1 ≤ p 6= q ≤ d) : [Ei , Ei ] = e (q 6= r, p 6= s 6= r) . 1,2 1,2 [Ei1,2 − 1 , Ei ] = Ei The choice of the pair (1, 2) is arbitrary and any other elementary matrix for x gives an isomorphic group. If we use the Magnus–Nielsen presentation [9, 19] of SLd (Z) instead of the Steinberg group, we have to add the relations ( Ei1,2 ( Ei2,1 )−1 Ei1,2 )4 = e. These groups are not, however, torsion-free. Although congruence subgroups of SLd (Z) are torsion-free (and even type F by [16]), the latter are never normally generated by a single element because they have large abelianizations. This construction can be transposed to other Chevalley groups. Notice that if in addition K is just infinite, like for instance K = SLd (Z) for d odd [11], then this construction shows that K embeds into all non-trivial quotients of K (n,x ), such as for instance the simple quotients obtained from maximal normal subgroups. 1.B. An example built from Z. Consider the semi-direct product L = (Z[1/2])2 ⋊ (Z × F2 ) VARIATIONS ON A THEME BY HIGMAN 3 where the generator h of Z acts on (Z[1/2])2 by multiplication by 2, and the generators u, v of the free group F2 act by multiplication by     1 1 1 0 and 0 1 1 1 respectively. In particular the group L is torsion-free, linear and finitely presented. It is generated by { x, y, h, u, v} where ( x, y) is the standard basis of Z2 . We define a group Gn by fusing together n copies Li of L in a circular fashion along the corresponding generators as follows: (2) Gn = Li : (hi , ui , vi ) = (yi−2 , xi−2 , yi−1 ), i ∈ Z/nZ . It is easy to write down an explicit presentation of Gn . Observe first that L, with our choice of generators, has a presentation with the following set R of relations R( x, y, h, u, v) : e = [ x, y] = [ x, u] = [y, v] = [h, u] = [h, v], [h, x] = [u, y] = x, [h, y] = [v, x] = y. Now (2) is equivalent to the finite presentation (3) Gn = xi , yi : R( xi , yi , yi−2 , xi−2 , yi−1 ), i ∈ Z/nZ . We find these groups more elementary than K (n,x ) (with Kazhdan K) and hope that they will be easier to use in applications. In return, we have to work more than before to deduce some of the following properties. Theorem 2. Let n ≥ 8. (i) The group Gn has no non-trivial Haagerup quotient. 1 -Følner set for the generators xi , yi is trivial. (ii) Any quotient with a 36 (iii) The only Kazhdan subgroup of Gn is the trivial group. (iv) The group Gn admits a finite K (π, 1). (v) The group Gn can be constructed starting from copies of Z, using amalgamated free products, semi-direct products and HNN-extensions. (vi) Every countable group embeds into some quotient of Gn if n ≥ 9. (vii) The groups Gm are trivial for m ≤ 4 and m = 6. The restriction n ≥ 9 is probably not needed in (vi) but makes it very easy to check Schupp’s criterion for SQ-universality. We have not elucidated G5 and G7 . Scholium. We should like to point out a general type of presentations subsuming the examples above. Consider a group L and two finite sets A, P ⊆ L. We think of elements in A as “active”, whilst those in P are “passive”. Consider furthermore a transitive labelled oriented graph g whose edges are labelled by P × A. To every vertex i of g we associate an independent copy Li of L. We then form the group G = Li , i ∈ g : p j = ak if ∃ ( p, a)-labelled edge from j to k . In order to get a manageable group from this presentation, we would like to ensure at the very least that each Li embeds. A favourable case is when A is a basis for a free subgroup in L and the edges spread the passive elements of Pj incoming to a vertex k over copies L j for suitably distinct js. (In our case, we allowed a commutation in Ak because it was going to hold also among the corresponding Pj .) 4 NICOLAS MONOD The trade-off is that this spreading should remain limited compared to the girth of the cycles in g along which we can cut the amalgamation scheme. Higman’s groups and the groups K (n,x ) use a simple n-cycle for g; as for Gn , we depict its graph in the figure below for n = 8; the orientation is implicit from the labelling. v y 3 h y x u y y x 2 v u h y y x 1 u v h v h u y 4x y The graph g for G8 . h v y u x 5 x y y u 0 v h h u x v 6 y y u h v y x y 7 y Notation. Our convention for commutators is [α, β] = αβα−1 β−1 ; Higman used a different convention for (1) but this does not affect the group Hign . Given a subset E of a group H, we denote the subgroup it generates by h Ei or by h Ei H when H needs to be clarified. 2. P ROOF OF P ROPOSITION 1 This proposition really is just a variation on the work of Higman and Schupp. For (i), we start by recalling the following. Lemma 3 (Higman’s circular argument). Let f be a homomorphism from Hign to another group. If f ( ai ) has finite order for some i, then f is trivial. Proof (see also [14, p. 547]). The relations in (1) imply inductively that f ( ai ) has finite order ri ≥ 1 for all i. Suppose for a contradiction that ri > 1 for some i, hence for all i by the r j −1 r j −1 − r j −1 relations (1). Let p be the smallest prime dividing any r j . The relation a j− = a2j 1 a j a j−1 implies that 2r j−1 − 1 is a multiple of r j and hence of p. In particular, p 6= 2 and the order s > 1 of 2 in (Z/pZ)× divides r j−1 . This contradicts the choice of p because s ≤ p − 1.  Suppose now that f is a homomorphism from K (n,x ) to an amenable group. The image of Ki in K (n,x ) is mapped by f to a finite group, so that in particular f ( xi ) has finite order for all i. Since we have a homomorphism Hign → K (n,x ) sending ai to xi , we deduce from Lemma 3 that f ( xi ) is in fact trivial. Since K is normally generated by x, it follows that f (Ki ) is trivial. We conclude that f is trivial because the various Ki generate K (n,x ) . VARIATIONS ON A THEME BY HIGMAN 5 The two other points follow once we re-construct K (n,x ) as a suitable amalgam. Recall that x has infinite order; thus (4) L = hK, h : [h, x] = xi is an HNN-extension; we define Li , hi similarly. Now H = L 0 , L 1 : x0 = h1 is a free product with amalgamation (because x0 has infinite order) and therefore, using also the HNN-structure of (4), it follows that hh0 , x1 i is a free group on h0 , x1 . Likewise, since n ≥ 4, we deduce that H ′ = L 2 , . . . L n − 1 : x2 = h3 , . . . , x n − 2 = h n − 1 is a (successive) free product with amalgamation and that h2 , xn−1 are a basis of a free group in H ′ . Therefore, we obtain K (n,x ) by amalgamating H and H ′ over the groups hh0 , x1 i and h xn−1 , h2 i by identifying the free generators in the order given here. Now the finiteness properties of (ii) all follow since K (n,x ) was obtained from copies of K by finitely many HNN-extensions and amalgamated free products (see e.g. [5, §7]). Regarding SQ-universality, P. Schupp proved that it suffices to find a blocking pair for hh0 , x1 i in H, see Thm. II in [18]. A blocking pair is provided for instance by any distinct non-trivial powers of an element t ∈ H such that t, h0 , x1 form a basis of a free group (see the comment after Thm. II in [18]). Just as in Lemma 4.3 of [18], the element t = x0−1 x1 h0 x1−1 x0 will do. 3. P ROOF OF T HEOREM 2 We now turn to the groups L and Gn defined in part 1.B of the Introduction and fix some more notation. Denote by Heis(α, β, ζ ) the (discrete) Heisenberg group with generators α, β and central generator ζ. More precisely, it is defined by the relations [α, β] = ζ and [ζ, α] = [ζ, β] = e. For instance, {v, x, y} (or just {v, x}) generate a copy of Heis(v, x, y) in L. We shall use repeatedly, but tacitly, the following fundamental property of a free product with amalgamation A ∗C B. If A′ < A and B′ < B are subgroups whose intersections with C yield the same subgroup C ′ < C, then the canonical map A′ ∗C′ B′ → A ∗C B is an embedding [15, 8.11]. We embed L into a larger group J generated by L together with an additional generator z by defining the following free product with amalgamation: (5) J = L ∗hh,vi Heis(h, z, v). Although h and v already occur in our definition of L, there is no ambiguity since they form a basis of a copy of Z2 both in L and in Heis(h, z, v). In particular, L is indeed canonically embedded in J. When we want to consider normal forms for this amalgamation (cf. [17, §1] or Thm. 4.4 in [10]), it is convenient that there are very nice coset representatives of hh, vi in each factor. Indeed, in Heis(h, z, v), we can simply take the group hzi. In L written as L = (Z[1/2])2 ⋊ (hhi × hu, vi), we can take as set of representatives the group (Z[1/2])2 ⋊ K, where K ⊳ hu, vi is the kernel of the morphism killing v. 6 NICOLAS MONOD As before, we shall denote by Ji a family of independent copies of J. We further denote by zi the corresponding additional generator. Then we have an equivalent presentation of Gn given by (6) * vi−1 = hi x = zi Ji : i−1 yi−1 = vi z i−1 = u i + ∀ i ∈ Z/nZ . The advantage is that each relation involves only successive indices i − 1 and i. We define inductively the groups Dr for r ∈ N, starting with D0 = J0 , by the presentation Dr = * vr − 1 = hr + x = zr Dr −1 , Jr : r −1 . yr − 1 = vr zr − 1 = u r We claim that this is in fact a free product with amalgamation of Dr −1 and Jr . More precisely, we claim that the subgroups of J given respectively by (7) Q = hv, x, y, zi J and T = hh, z, v, ui J are isomorphic under matching their generators in the order listed in (7). This claim, transported to the various Ji , implies in particular by induction that Dr is indeed a free product with amalgamation Dr ∼ = Dr −1 ∗Qr−1 = Tr Jr , where Qi , Ti denote the corresponding subgroups of Ji . To prove the claim, we note first that the structure of Q is revealed by observing which subgroups are generated by {v, x, y} and by {v, z} in the amalgamation (5) defining J. Both intersect hh, vi exactly in hvi and thus Q is itself a free product with amalgamation Q = Heis(v, x, y) ∗hvi hv, zi J with hv, zi J ∼ = Z2 . As for T, given its relations, we have an epimorphism Q → T given by the above matching of generators; we need to show that it is in fact injective. To this end, consider that T is generated by its subgroups Heis(h, z, v) and hh, v, ui J . Since L is a factor of J, the latter is hh, v, ui L ∼ = Z × F2 . Thus T is an amalgamated free product Heis(h, z, v) ∗hh,vi hh, v, ui L . The injectivity now follows. In conclusion, Dr is the following iterated free product with amalgamations: Dr ∼ = J0 ∗Q0 = T1 J1 ∗Q1 = T2 · · · ∗Qr−1 = Tr Jr . We also need to understand the intersection Q ∩ T, which contains at least the group hz, vi J ∼ = Z2 . In fact, this intersection is exactly hz, vi J . This follows by examining the normal form for the particularly simple choice of coset representatives made above. As a consequence, we deduce that when r ≥ 3, the subgroups T0 and Qr of   (8) Dr ∼ = J0 ∗Q0 = T1 J1 ∗Q1 = T2 · · · ∗Qr−2 = Tr−1 Jr −1 ∗Qr−1 = Tr Jr intersect trivially and hence generate a free product T0 ∗ Qr . Finally, to close the circle, we will use the assumption n ≥ 8 and glue Dn−5 with a copy D3′ of D3 as follows. We shift indices in the D3 factor to obtain the isomorphic group D3′ = Jn−4 ∗Qn−4 = Tn−3 · · · ∗Qn−2 = Tn−1 Jn−1 . VARIATIONS ON A THEME BY HIGMAN 7 In D3′ , the subgroups Tn−4 and Qn−1 generate Tn−4 ∗ Qn−1 . Since we have constructed isomorphisms T0 ∼ = Qn−1 and Qn−5 ∼ = Tn−4 , we have a corresponding isomorphism ϕ : T0 ∗ Qn−5 −→ Qn−1 ∗ Tn−4 and therefore we have a free product with amalgamation (9) Dn−5 ∗ ϕ D3′ . Since this is a rewriting of the presentation (6), we have indeed constructed Gn as an amalgam whenever n ≥ 8. In particular, Li is embedded in Gn . At this point, we have established point (v) of Theorem 2, observing that (Z[1/2])2 ⋊ hhi is an HNN-extension of Z × Z, that we can write   L∼ = (Z[1/2])2 ⋊ hhi ⋊ (Z ∗ Z) and that Heisenberg groups have the form (Z × Z) ⋊ Z. On the other hand, point (iv) follows from (v), see e.g. [5, §7]. As for (iii), we only need to recall that Kazhdan groups have Serre’s property FA [4, §6.a]. This implies that any Kazhdan subgroup of Gn can be recursively constrained into the factors of any amalgam. By (v), we finally reach Z, which has no non-trivial Kazhdan subgroup. For (vi), we indulge in the expedience of n ≥ 9. This allows us to see from the decomposition (8) applied to r = n − 5 ≥ 4 that we have a free product h T0 , u2 x2 , Qr i Dr = T0 ∗ hu2 x2 i ∗ Qr . Indeed, reasoning within J, we see that huxi intersects both Q and T trivially (and is infinite). This implies that any two distinct non-trivial powers of u2 x2 constitute a blocking pair for T0 ∗ Qr in Dr , see again [18]; we conclude that Gn is SQ-universal. Turning to (i), we first observe that every generator in the presentation (3) functions as a self-destruct button for the group Gn , i.e. normally generates Gn . Lemma 4. Let f be a homomorphism from Gn to another group. If f sends some xi or some yi to the identity, then f is trivial. 1 −1 Proof. The element ui v− and therefore we can assume that f (yi ) is i u i conjugates xi to yi trivial. Since yi = vi+1 , the relation [vi+1 , xi+1 ] = yi+1 implies inductively that f (y j ) vanishes 1 for all j. Conjugating by u j v−  j u j , we find that all generators in (3) are trivialized by f . Let now f be a homomorphism from Gn to some Haagerup group. The subgroup h x, yi of h x, yi ⋊ hu, vi has the relative property (T). Indeed, the proof of the corresponding statement for Z2 ⋊ SL2 (Z) only depends on the image of SL2 (Z) in the automorphism group of Z2 , see e.g. [1]. Therefore, f (h xi , yi i) is finite for all i. On the other hand, the presentation (2) shows that we have a morphism Hign → Gn defined by ai 7→ y2i . By Higman’s argument (Lemma 3), it follows that f (y2i ) is trivial for all i. We conclude from Lemma 4 that f is trivial. For (ii), we use the explicit relative Kazhdan pair (S0 , ǫ0 ) provided by M. p Burger, Example 2 √ 2 p. 40 in [1]. Here S0 is a certain generating set of Z ⋊ SL2 (Z) and ǫ0 = 2 − 3. Being a relative Kazhdan pair means that any unitary representation of Z2 ⋊ SL2 (Z) with (S0 , ǫ0 )invariant vectors admits Z2 -invariant vectors, see [4]. We denote by S = { x, y, u, v} our usual generators of Z2 ⋊ F2 and write S = S ∪ S−1 ∪ {e}; then (S, ǫ)-invariance is equivalent 8 NICOLAS MONOD 3 to (S, ǫ)-invariance. The set S0 from [1, Ex. 2] is contained in S under the map F2 → SL2 (Z) and therefore every (S, ǫ0 /3)-invariant vector is (S0 , ǫ0 )-invariant. Now (ii) follows because √ ǫ0 /3 > 1/6 and because any (S, ǫ)-Følner set gives a (S, ǫ)-invariant vector. Remark. The corresponding argument provides also a lower bound on Følner constants for quotients of K (n,x ) when K is Kazhdan. It only remains to prove (vii). Consider again the homomorphism Hign → Gn above. When n is even, this factors through a morphism Hign/2 → Gn . Since Higr is trivial for r ≤ 3 (see [8]), it follows that y0 is trivial when n = 4, 6; now Lemma 4 shows that Gn is trivial. The same argument applied to the original map Hign → Gn takes care of n ≤ 3. R EFERENCES [1] Marc Burger, Kazhdan constants for SL(3, Z), J. reine angew. Math. 413 (1991), 36–67. [2] Marc Burger and Shahar Mozes, Finitely presented simple groups and products of trees, C. R. Acad. Sci. Paris Sér. I Math. 324 (1997), no. 7, 747–752. [3] , Lattices in product of trees, Inst. Hautes Études Sci. Publ. Math. (2000), no. 92, 151–194. [4] Pierre de la Harpe and Alain Valette, La propriété ( T ) de Kazhdan pour les groupes localement compacts, Astérisque (1989), no. 175, 158. [5] Ross Geoghegan, Topological methods in group theory, Graduate Texts in Mathematics, vol. 243, Springer, New York, 2008. [6] Mikhaïl Leonidovich Gromov, Endomorphisms of symbolic algebraic varieties, J. Eur. Math. Soc. 1 (1999), no. 2, 109–197. [7] Harald Andrés Helfgott and Kate Juschenko, Soficity, short cycles and the Higman group, Preprint, http://arxiv.org/abs/1512.02135, 2015. [8] Graham Higman, A finitely generated infinite simple group, J. London Math. Soc. 26 (1951), 61–64. [9] Wilhelm Magnus, Über n-dimensionale Gittertransformationen, Acta Math. 64 (1935), no. 1, 353–367. [10] Wilhelm Magnus, Abraham Karrass, and Donald Moiseyevitch Solitar, Combinatorial group theory: Presentations of groups in terms of generators and relations, revised ed., Dover Publications Inc., New York, 1976. [11] Jens Mennicke, Finite factor groups of the unimodular group, Ann. of Math. (2) 81 (1965), 31–37. [12] John Milnor, Introduction to algebraic K-theory, Princeton University Press, 1971, Annals of Mathematics Studies, No. 72. [13] Bernhard Hermann Neumann, Some remarks on infinite groups., J. Lond. Math. Soc. 12 (1937), 120–127. [14] , An essay on free products of groups with amalgamations, Philos. Trans. Roy. Soc. London. Ser. A. 246 (1954), 503–554. [15] Hanna Neumann, Generalized free products with amalgamated subgroups, Amer. J. Math. 70 (1948), no. 3, 590– 625. [16] Madabusi Santanam Raghunathan, A note on quotients of real algebraic groups by arithmetic subgroups, Invent. Math. 4 (1968), 318–335. [17] Otto Schreier, Die Untergruppen der freien Gruppen, Abhandlungen Math. Hamburg 5 (1927), 161–183. [18] Paul Eugene Schupp, Small cancellation theory over free products with amalgamation, Math. Ann. 193 (1971), 255–264. [19] Robert Steinberg, Some consequences of the elementary relations in SLn , Contemp. Math., vol. 45, Amer. Math. Soc., 1985, pp. 335–350. [20] Andreas Thom, About the metric approximation of Higman’s group, J. Group Theory 15 (2012), no. 2, 301–310. [21] Benjamin Weiss, Sofic groups and dynamical systems, Sankhyā Ser. A 62 (2000), no. 3, 350–359, Ergodic theory and harmonic analysis (Mumbai, 1999). EPFL, 1015 L AUSANNE , S WITZERLAND
4math.GR
Robust Minutiae Extractor: Integrating Deep Networks and Fingerprint Domain Knowledge arXiv:1712.09401v1 [cs.CV] 26 Dec 2017 Dinh-Luan Nguyen, Kai Cao and Anil K. Jain Michigan State University East Lansing, Michigan, USA [email protected], {kaicao,jain}@cse.msu.edu Abstract We propose a fully automatic minutiae extractor, called MinutiaeNet, based on deep neural networks with compact feature representation for fast comparison of minutiae sets. Specifically, first a network, called CoarseNet, estimates the minutiae score map and minutiae orientation based on convolutional neural network and fingerprint domain knowledge (enhanced image, orientation field, and segmentation map). Subsequently, another network, called FineNet, refines the candidate minutiae locations based on score map. We demonstrate the effectiveness of using the fingerprint domain knowledge together with the deep networks. Experimental results on both latent (NIST SD27) and plain (FVC 2004) public domain fingerprint datasets provide comprehensive empirical support for the merits of our method. Further, our method finds minutiae sets that are better in terms of precision and recall in comparison with state-of-the-art on these two datasets. Given the lack of annotated fingerprint datasets with minutiae ground truth, the proposed approach to robust minutiae detection will be useful to train network-based fingerprint matching algorithms as well as for evaluating fingerprint individuality at scale. MinutiaeNet is implemented in Tensorflow: https://github.com/luannd/MinutiaeNet Figure 1. Minutiae detection by the proposed approach on two latent fingerprint images (#7 and #39) from the NIST SD27 dataset [6]. Left column: minutiae score maps obtained from the latent images shown in the right column. Right column: minutiae detected by the proposed framework (red) and ground truth minutiae (blue) overlaid on the latent image. 1. Introduction images, continues to be a bottleneck in fingerprint recognition systems. Automatic fingerprint recognition is one of the most widely studied topic in biometrics over the past 50 years [12]. One of the main challenges in fingerprint recognition is to increase the recognition accuracy, especially for latent fingerprints. Fingerprint comparison is primarily based on minutiae set comparison [28, 11]. A number of hand-crafted approaches [10, 28] have been used to augment the minutiae with their attributes to improve the recognition accuracy. However, robust automatic fingerprint minutiae extraction, particularly for noisy fingerprint With rapid developments and success of deep learning techniques in a variety of applications in computer vision and pattern recognition [8, 20], we are beginning to see network-based approaches being proposed for fingerprint recognition. Still, the prevailing methods of minutiae extraction primarily utilize fingerprint domain knowledge and handcrafted features. Typically, minutiae extraction and matching involves pre-processing stages such as ridge extraction and ridge thinning, followed by minutiae extraction [10, 4] and finally heuristics to define minutiae at- Table 1. Published network-based approaches for automatic minutiae extraction. Study Method Training Data Testing Data Comments Sankaran et al. [18] Jiang et al. [13] Tang et al. [21] Darlow et al. [3] Tang et al. [22] Sparse autoencoders for classification A combination of JudgeNet and LocateNet Fully convolutional neural network Convolutional network classifier Unified network with domain knowledge 132, 560 plain fingerprint images; 129 images from NIST SD27 200 live scan fingerprints 4, 205 latent images from private database and 129 latents from NIST SD27 6, 336 images from FVC 2000, 2002, and 2004 8, 000 images from private forensic latent database 129 remaining latents from NIST SD27 100 images from private database 129 latents from NIST SD27 1, 584 images from FVC 2000, 2002, and 2004 Set A of FVC 2004 and NIST SD27 Sliding window; manual segmentation of latent fingerprints Sliding window; hand-crafted dividing regions; no minutiae orientation information Hard thresholds to cut off candidate regions; plain network Sliding window; hard threshold for candidate regions (minutiae); separately estimated minutiae orientation Plain network; depends largely on the quality of the enhancement and segmentation stages Proposed approach Domain knowledge with Residual learning based CoarseNet and inception-resnet based FineNet FVC 2002 with data augmentation (8, 000 images in total) FVC 2004 (3, 200 images) and NIST SD27 (all 258 latents) Residual network; automatic minutiae extractor utilizing domain knowledge; robust patch based minutiae classifier Performance Evaluation Patch-based and minutia-based, metric and matching performance(*) Precision, recall, and F1 score Precision, recall, F1 score, and matching performance Equal error rate and matching performance Precision, recall, and matching performance Precision, recall, and F1 score under different location and orientation thresholds (*) different matchers were used in different studies and none of them were state of the art, i.e. top performing latent or slap matchers identified in the NIST evaluations. For this reason, we do not report matching performance because otherwise it would not be a fair comparison with previous studies. tributes. While such an approach works well for good quality fingerprint images, it provides inaccurate minutiae location and orientation for poor quality rolled/plain prints and, particularly for latent fingerprints. To overcome the noise in fingerprint images, Yoon et al. [27] used Gabor filtering to calculate the reliability of extracted minutiae. Although this approach can work better than [10], it also resulted in poor results with highly noisy images. Because these prevailing approaches are based on handcrafted methods or heuristics, they are only able to extract basic (or low level) features1 of images. We believe learning based approaches using deep networks will have better ability to extract high level features2 from low quality fingerprint images. In this paper, we present a novel framework that exploits useful domain knowledge coded in the deep neural networks to overcome limitations of existing approaches to minutiae extraction. Figure 1 visualizes results of the proposed framework on two latent fingerprints from the NIST SD27 dataset. Specifically, our proposed approach comprises of two networks, called CoarseNet and FineNet: - CoarseNet is a residual learning [8] based convolutional neural network that takes a fingerprint image as initial input, and the corresponding enhanced image, segmentation map, and orientation field (computed by the early stages of CoarseNet) as secondary input to generate the minutiae score map. The minutiae orientation is also estimated by comparing with the fingerprint orientation. - FineNet is a robust inception-resnet [20] based minutiae classifier. It processes each candidate patch, a square region whose center is the candidate minutiae point, to refine the minutiae score map and approximate minutiae orientation by regression. Final minutiae are the classification results. Deep learning approach has been used by other researchers for minutiae extraction (see Table 1). But, our approach differs from published methods in the way we encode fingerprint domain knowledge in deep learn- ing. Sankaran et al. [18] classified the minutiae and nonminutiae patches by using sparse autoencoders. Jiang et al. [13] introduced a combination of two networks: JudgeNet for classifying minutiae patches, and LocateNet for locating precise minutiae location. While Jiang et al. use neural networks, their approach is very time-consuming due to use of sliding window to extract minutiae candidates. Another limitation of this approach is that it does not provide minutiae orientation information. Tang et al. [21] utilized the idea of object detection to detect candidate minutiae patches, but it suffers from two major weaknesses: (i) hard threshold to delete the candidate patches, and (ii) the same network is used for both candidate generation and classification. By using sliding windows, Darlow et al. [3] fed each pixel of the input fingerprint to a convolutional neural network, called MENet, to classify whether it corresponds to a minutia or not. It also suffers from time-consuming sliding windows as in [13], and separate modules for minutiae location and orientation estimates. Tang et al. [22] proposed FingerNet that maps traditional minutiae extraction pipeline including orientation estimation, segmentation, enhancement, and extraction to a network with fixed weights. Although this approach is promising because it combines domain knowledge and deep network, it still uses plain 3 network architecture and hard threshold in non-maximum suppression 4 . Finally, the accuracy of FingerNet depends largely on the quality of the enhanced and segmentation stage while ignoring texture information in the ridge pattern. In summary, the published approaches suffer from using sliding windows to process each pixel in input images, setting hard threshold in post-processing step, and using plain convolutional neural network to classify candidate regions. Furthermore, the evaluation process in these studies is not consistent in terms of defining “correct” minutiae. The contributions of our approach are as follows: • A network-based automatic minutiae extractor utilizing domain knowledge is proposed to provide reli3A 1 Features such as edges, corners, etc. 2 Abstract/semantic features retrieved from deep layers. series of stacked layers. post-processing algorithm that merges all detections belonging to the same object. 4A Figure 2. Proposed automatic minutiae extraction architecture. While CoarseNet takes full fingerprint image as input, FineNet processes minutiae proposed patches output by CoarseNet. able minutiae location and orientation without a hard threshold or fine tuning. • A robust patch based minutiae classifier that significantly boosts the precision and recall of candidate patches. This can be used as a robust minutiae extractor with compact embedding of minutiae features. • A non-maximum suppression is proposed to get precise locations for candidate patches. Experimental evaluations on FVC 2004 [15] and NIST SD27 [6] show that the proposed approach is superior to published approaches in terms of precision, recall, and F1 score values. 2. Proposed framework Our minutiae extraction framework has two modules: (i) residual learning based convolutional neural network, called CoarseNet that generates candidate patches containing minutiae from input fingerprint image; (ii) inceptionresnet based network architecture, called FineNet which is a strong minutiae classifier that classifies the candidate patches output by CoarseNet. These two networks also provide minutiae location and orientation information as outputs. Figure 2 describes the complete network architecture for automatic minutiae location and orientation for an input fingerprint image. Section 2.1 presents the architecture of CoarseNet. In Section 2.2, we introduce FineNet with details on training to make it a strong classifier. 2.1. CoarseNet for minutiae extraction We adopt the idea of combining domain knowledge and deep representation of neural networks in [22] to boost the minutiae detection accuracy. In essence, we utilize the automatically extracted segmentation map, enhanced image, and orientation map as complementary information to the input fingerprint image. The goal of CoarseNet is not to produce the segmentation map or enhanced image or orientation map. They are just the byproducts of the network. However, these byproducts as fingerprint domain knowledge must be reliable to get robust minutiae score map. Because Tang et al. [22] proposed an end-to-end unified network that maps handcrafted features to network based architecture, we use this as a baseline for our CoarseNet. 2.1.1 Segmentation and orientation feature sharing Adding more layers in the deep network with the hope of increasing accuracy might lead to the exploding or vanishing gradients problem. From the success of residual learning [8], we use residual instead of just plain stacked convolutional layers in our network to make it more powerful. Figure 3 shows the detailed architecture of the network. Unlike existing works using plain convolutional neural network [21, 22] or sliding window [18, 3] to process each patch with fixed size and stride, we use a deeper residual learning based network with more pooling layers to scale down the region patch. Specifically, we get the output after the 2nd , 3rd , and 4th pooling layer to feed to an ASPP network [2] with corresponding rates for multiscale segmentation. This ensures the output has the same size as input without a loss of information when upsampling the score map. By using four pooling layers, each pixel in the j th feature map, called level j, corresponds to a region 2j × 2j in the original input. Result layers at level 4 and 3 will be tested as coarse estimates while the level 2 serves as fine estimation. Segmentation map. Image segmentation and fingerprint orientation estimation share the same convolutional layers. Thus, by applying multi-level approach mentioned above, we get probability maps of each level-corresponding region in input image. For instance, to get finer-detailed segmentation for each region level jl , we continue to process probability map of region level jl /2. Figure 3. CoarseNet architecture. Orientation map. To get complete minutiae information from context, we adopt the fusion idea of Cao et al. [1]. We fuse the results of Dictionary-based method [26] with our orientation results from CoarseNet. Because [26] uses a hand-crafted approach, we set the fusion weight ratio of its output with our network-based approach as 1:3. 2.1.2 Candidate generation The input fingerprint image might contain large amounts of noise. So, without using domain knowledge we may not be able to identify prominent fingerprint features. The domain knowledge comprises of four things: raw input image, enhanced image, orientation map, and segmentation map. In the Gabor image enhancement module, we take the average of filtered image and the orientation map for ridge flow estimation. To emphasize texture information in fingerprints, we stack the original input image with the output of enhancement module to obtain the final enhancement map. To remove spurious noises, we apply segmentation map on the enhancement map and use it as input to coarse minutiae extractor module. To obtain the precise location of minutiae, each level of residual net is fused to get the final minutiae score map with size h/16 × w/16, where h and w are the height and width of the input image. Figure 4 shows the details of processing score map. To reduce the processing time, we use score map at level 4 as a coarse location. To get precise location, lower level score maps are used. 2.1.3 Non-maximum suppression Using non-maximum suppression to reduce the number of candidates is common in object detection [7, 17]. Some of the candidate regions are deleted to get a reliable minutiae score map by setting a hard threshold [3] or using heuristics [21, 22]. However, a hard threshold can also suppress valid minutiae locations. A commonly used heuristics is to sort the candidate scores in ascending order. The L2 distance between pairwise candidates is calculated with hard thresholds for distance and orientation. By iteratively comparing each candidate with the rest in the candidate list, only the candidate with higher score and score above the thresholds is kept. However, this approach fails when two minutiae are near each other and the inter-minutiae distance is below the hard thresholds. Since each score in the minutiae map corresponds to a specific region in the input image, we propose to use the intersection over union strategy. Specifically, after sorting the scores of the candidate list, we keep high score candidates while ignoring the lower scoring candidates with at least 50% overlap with the candidates already selected. 2.1.4 Training data for CoarseNet Given the lack of datasets with ground truth, we use the approach in Tang et al. [22] to generate weak labels for training the segmentation and orientation module. The coarse minutiae extractor module uses minutiae location and minutiae orientation ground truth provided in the two datasets. We also use data augmentation techniques as mentioned in Section 3. 2.2. FineNet Figure 4. Candidate patch processing map. Lower the level of score map, more detail it provides. Extracting minutiae based on candidate patches is not adequate. Although CoarseNet is reliable, it still fails to de- tect true minutiae or detects spurious minutiae. This can lead to poor performance in fingerprint matching. This motivates our use of FineNet - a minutiae classifier from generated candidate patches. FineNet takes candidates from the output of CoarseNet as input to decide whether the region 10 × 10 in the center of the corresponding patch has a valid minutia or not. dom sampling with the center regions do not contain partial or fully minutiae location. To make the network more robust, we use some small techniques like Batch Normalization [9], rotation, flipping, scaled augmentation [19], and bounding blurring [13] as pre-processing stage. 2.2.1 Intra-Inter class losses. Because input captured fingerprint image is not always in the ideal condition, it might be easily affected by distortion, finger movement, or quality (wet/dry) of finger. Thus, the variation of minutiae shapes and surrounding ridges can affect the accuracy of the classifier. To handle this situation and make the FineNet more robust with intra-class variations, we use Center Loss [25] as a complementary of softmax loss and minutiae orientation loss. While softmax loss tends to push away features of different classes, center loss tends to pull features in the same class closer. Let L, LC , LS , LO be the total loss, center loss, sofmax loss, and orientation loss, the total loss for training is calculated as follows: L = αLC + (1 − α)LS + βLO (1) FineNet architecture Figure 5 describes the architecture of FineNet. As mentioned in Section 2.1.1, we use the Inception-Resnet v1 architecture as a core network in FineNet. For FineNet training, we extract an equal number of t1 × t1 sized minutiae and non-minutiae patches with t1 = 45. FineNet determines the whether the 10 × 10 pixel region in the center of each patch contains a valid minutia or not. The candidate patches are resized into t2 × t2 pixels that feed to FineNet. Based on the observation that the original input image size (without rescaling) is not large in comparison with images for object classification, too much up scaling the image can cause blurring the tiny details, and too small an input image size is not sufficient for network with complex architecture, we choose t2 = 160 pixels. Training data for FineNet is extracted from the input gray scale images where minutiae data are based on the ground truth minutiae location and non-minutiae ones are from ran- 2.2.2 Losses and implementation details where we set α = 0.5 to balance between intra-class (center) and inter-class (sofmax) loss and β = 2 to emphasize the importance of precision of minutiae orientation. Parameter settings. As mentioned in Section 2.2.1, fingerprint patches are input to FineNet where the patch size is 160 × 160. To ensure our network can handle distortion in input image, we apply scaled augmentation [19], random cropping, and brightness adjustment. Horizontal and vertical flip with pixel mean subtraction are also adopted. We randomly initialize all variables by using a Gaussian distribution N (0, 0.01). Batch size is set to 100. We use schedule learning rate after particular iterations. Specifically, we set it as 0.01 in the beginning and reduce 10 times after 50K iterations. To prevent vanishing gradient problem, we set the maximum epoch to 200K. We use 0.0004 as the value for momentum and weight decay is 0.9. 3. Experimental results We evaluate our method on two different datasets with different characteristics under different settings of parameters D and O (see Eq. (2)). We also visualize examples of score maps with correct and incorrect minutiae extractions in Figure 7. All experiments were implemented in Tensorflow and ran on Nvidia GTX GeForce. 3.1. Datasets Figure 5. FineNet architecture. For details of the Inception-Resnet v1 arichitecture block, we refer the readers to [20]. We use FVC 2002 dataset [16] with data augmentation consisting of 3, 200 plain fingerprint images for training. To compensate for the lack of a large scale dataset for training, we distort the input images in x and y coordinates in the spirit of hard-training with non-ideal input fingerprint images. Furthermore, we also apply additive random noise to Table 2. Comparison of different methods for minutiae extraction on FVC 2004 and NIST SD27 datasets. Note that [18, 21] reported their results only on subsets of FVC 2004 and NIST SD27 as mentioned in Table 1. “ ” means the authors neither provided these results in their paper nor made their code available. D and O are parameters defined in Eq. (2). Dataset NIST SD27 FVC 2004 Methods MINDTCT [24] VeriFinger [23] Gao et al. [5] Sankaran et al. [18] Tang et al. [21] FingerNet [22] Proposed method MINDTCT [24] VeriFinger [23] Gao et al. [5] FingerNet [22] Proposed method Setting 1 (D = 8, O = 10) Precision Recall F1 score 8.3% 14.7% 0.106 3.6% 40.1% 0.066 53.2% 69.2% 30.8% 39.8% 49.5% 67.7% 64.3% 69.2% 0.513 0.684 0.416 0.505 58.0% 70.5% 37.7% 45.6% 58.1% 72.3% 72.1% 77.5% 0.58 0.714 0.495 0.574 68.7% 79.0% 62.1% 80.1% 0.643 0.795 72.9% 83.6% 70.4% 83.9% 0.716 0.837 the input images. Thus, for training CoarseNet, we have an augmented dataset of 8, 000 images. To obtain data for training FineNet, we extract 45 × 45 pixel patches from these 8K training images for CoarseNet whose center is a ground truth minutia point. For non-minutiae patches, we randomly extract patches with the criteria that the 10 × 10 center of each patch does not contain any minutia. Thus, we collect around 100K minutia and non-minutia patches for training FineNet. As mentioned in Section 2.1.4, we use FingerNet [22] to generate labels for domain knowledge groundtruth. Besides, we manually correct segmentation grountruth results from FingerNet to ensure better learning for CoarseNet. 3.2. Evaluation To demonstrate the robustness of our framework, we compare our results with published approaches on FVC 2004 [15]5 and NIST SD27 [6] datasets under different criteria of distance and orientation thresholds. Let the tuples (lp , op ) and (lgt , ogt ) be the location coordinates and orientation values of predicted and ground truth minutia. The predicted minutia is called true if it satisfies the following ( constrains: klp − lgt k2 ≤ D (2) kop − ogt k1 ≤ O where D and O are the thresholds in pixels and degrees, respectively. Specifically, we set the range of distances between detected and ground truth minutiaes from 8 to 16 pixels (in location) and 10 to 30 degree (in orientation) with default threshold value (0.5). We choose these settings to demonstrate the robust and precise results from the proposed approach while published works degrade rather quickly. Table 2 shows the precision and recall comparisons of different approaches to minutiae extraction. 5 We obtained the groundtruth from [14] Setting 2 (D = 12, O = 20) Precision Recall F1 score 10.0% 16.4% 0.124 5.3% 47.9% 0.095 Setting 3 (D = 16, O = 30) Precision Recall F1 score 11.2% 18.9% 0.141 7.6% 58.3% 0.134 23.5% 8.7% 0.127 26.4% 63.1% 0.372 53.0% 53.4% 0.532 63.0% 63.2% 0.631 71.2% 75.7% 0.734 42.1% 79.8% 0.551 51.8% 81.9% 0.635 48.8% 82.7% 0.614 76.0% 80.0% 0.779 85.9% 84.8% 0.853 Table 3. The importance of non-maximum suppression in our framework. N M S and N M S ∗ denote the non-maximum approaches of FingerNet and the proposed approach, respectively. Configuration Precision Recall F1 score FingerNet + N M S 63.0% 63.2% 0.631 FingerNet + N M S ∗ 65.2% 65.4% 0.653 Proposed method + N M S 69.4% 73.5% 0.714 Proposed method + N M S ∗ 71.2% 75.7% 0.734 MINDTCT [24] is the open source NIST Biometric Image Software. VeriFinger [23] is a commercial SDK for minutiae extraction and matching. Since Gao et al. [5] did not release their code in public domain, we report their results on NIST SD27 and FVC 2004 database from [22]. Darlow et al. [3] use only a subset of the FVC dataset for training and the rest for testing, we do not include in our evaluation. Table 2 shows that the proposed method outperforms state-of-the-art techniques under all settings of parameters (thresholds) D and O for both FVC 2004 and NIST SD27. Our results also reveal that by using only rolled/plain fingerprint images for training, our framework can work pretty well for detecting minutiae in latents. Table 3 shows a comparison between using and not using our proposed non-maximum suppression method on the NIST SD27 dataset with setting 3 in Table 2. Because nonmaximum suppression is a post processing step, it helps improve precision, recall and F1 values. To make a complete comparison (at all the operating points) with published methods, we present the precisionrecall curves in Figure 6. The proposed approach surpasses all published works on both FVC 2004 and NIST SD27 datasets. Figure 7 shows the minutiae extraction results on both FVC 2004 and NIST SD27 datasets with different quality images. Our framework works well in difficult situations such as noisy background or dry fingerprints. However, there are some cases where the proposed framework Figure 6. Precision-Recall curves on FVC 2004 (left) and NIST SD27 (right) datasets with published approaches in Setting 3. either misses the true minutiae or extracts spurious minutiae. For the FVC 2004 dataset and rolled fingerprints from NIST SD27 dataset, we obtain results that are close to the ground truth minutiae. However, some minutiae points are wrongly detected (image a) because of the discontinuity of ridges or missed detections (image c) because the location of minutiae is near the fingerprint edge. For the latent fingerprints from NIST SD27 dataset, besides the correctly extracted minutiae, the proposed method is sensitive to severe background noise (image e) and poor latent fingerprint quality (image g). The run time per image is around 1.5 seconds for NIST SD27 and 1.2 seconds for FVC 2004 on Nvidia GTX GeForce. 4. Conclusions We have presented two network architectures for automatic and robust fingerprint minutiae extraction that fuse fingerprint domain knowledge and deep network representation: - CoarseNet: an automatic robust minutiae extractor that provides candidate minutiae location and orientation without a hard threshold or fine tuning. - FineNet: a strong patch based classifier that accelerates the reliability of candidates from CoarseNet to get final results. A non-maximum suppression is proposed as a post processing step to boost the performance of the whole framework. We also reveal the impact of residual learning on minutiae extraction in the latent fingerprint dataset despite using only plain fingerprint images for training. Our experimental results show that the proposed framework is robust and achieves superior performance in terms of precision, recall and F1 values over published state-of-the-art on both benchmark datasets, namely FVC 2004 and NIST SD27. The proposed framework can be further improved by (i) using larger training set for network training that includes latent images, (ii) constructing context descriptor to exploit the region surrounding minutiae, (iii) improving processing time, and (iv) unifying minutiae extractor into an end-to-end fingerprint matching framework. References [1] K. Cao and A. K. Jain. Automated latent fingerprint recognition. arXiv preprint arXiv:1704.01925, 2017. 3 [2] L.-C. Chen, G. Papandreou, I. Kokkinos, K. Murphy, and A. L. Yuille. Deeplab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected crfs. IEEE Trans. PAMI, 2017. 3 [3] L. Darlow and B. Rosman. Fingerprint minutiae extraction using deep learning. In Proc. IEEE IJCB, 2017. 2, 3, 4, 6 [4] J. Feng. Combining minutiae descriptors for fingerprint matching. Pattern Recognition, 41(1):342–352, 2008. 1 [5] X. Gao, X. Chen, J. Cao, Z. Deng, C. Liu, and J. Feng. A novel method of fingerprint minutiae extraction based on Gabor phase. In Proc. 17th IEEE ICIP, pages 3077–3080, 2010. 6 [6] M. D. Garris and R. M. McCabe. NIST special database 27: Fingerprint minutiae from latent and matching tenprint images. NIST Technical Report NISTIR, 6534, 2000. 1, 3, 6 [7] R. Girshick, F. Iandola, T. Darrell, and J. Malik. Deformable part models are convolutional neural networks. In Proc. IEEE CVPR, pages 437–446, 2015. 4 [8] K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. In Proc. IEEE CVPR, pages 770–778, 2016. 1, 2, 3 [9] S. Ioffe and C. Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. In Proc. ICML, pages 448–456, 2015. 5 [10] A. Jain, L. Hong, and R. Bolle. On-line fingerprint verification. IEEE Trans. PAMI, 19(4):302–314, 1997. 1, 2 [11] A. K. Jain, Y. Chen, and M. Demirkus. Pores and ridges: Highresolution fingerprint matching using level 3 features. IEEE Trans. PAMI, 29(1):15–27, 2007. 1 [12] A. K. Jain, K. Nandakumar, and A. Ross. 50 years of biometric research: Accomplishments, challenges, and opportunities. Pattern Recognition Letters, 79:80–105, 2016. 1 [13] L. Jiang, T. Zhao, C. Bai, A. Yong, and M. Wu. A direct fingerprint minutiae extraction approach based on convolutional neural networks. In Proc. IEEE IJCNN, pages 571–578, 2016. 2, 5 [14] M. Kayaoglu, B. Topcu, and U. Uludag. Standard fingerprint databases: Manual minutiae labeling and matcher performance analyses. arXiv preprint arXiv:1305.1443, 2013. 6 [15] D. Maio, D. Maltoni, R. Cappelli, J. Wayman, and A. Jain. FVC2004: Third fingerprint verification competition. In Biometric Authentication, pages 31–35. Springer, 2004. 3, 6 Figure 7. Visualizing minutiae extraction results. From top to bottom in each column: score maps, and minutiae extraction results overlaid on fingerprint images. (a)-(b): two plain images from FVC 2004; (c)-(d): rolled (reference) fingerprints from NIST SD27; (e)-(h): latent fingerprint images from NIST SD27. [16] D. Maio, D. Maltoni, R. Cappelli, J. L. Wayman, and A. K. Jain. FVC2002: Second fingerprint verification competition. In Proc. 16th ICPR, volume 3, pages 811–814, 2002. 5 [17] S. Ren, K. He, R. Girshick, and J. Sun. Faster r-cnn: Towards realtime object detection with region proposal networks. IEEE Trans. PAMI, 39(6):1137–1149, 2017. 4 [18] A. Sankaran, P. Pandey, M. Vatsa, and R. Singh. On latent fingerprint minutiae extraction using stacked denoising sparse autoencoders. In Proc. IEEE IJCB, pages 1–7, 2014. 2, 3, 6 [19] K. Simonyan and A. Zisserman. Very deep convolutional networks for large-scale image recognition. arXiv:1409.1556, 2014. 5 [20] C. Szegedy, S. Ioffe, V. Vanhoucke, and A. Alemi. Inception-v4, inception-resnet and the impact of residual connections on learning. In Proc. AAAI, pages 4278–4284, 2017. 1, 2, 5 [21] Y. Tang, F. Gao, and J. Feng. Latent fingerprint minutia extraction using fully convolutional network. In Proc. IEEE IJCB, 2017. 2, 3, 4, 6 [22] Y. Tang, F. Gao, J. Feng, and Y. Liu. Fingernet: An unified deep network for fingerprint minutiae extraction. In Proc. IEEE IJCB, 2017. 2, 3, 4, 6 [23] Verifinger. Neuro-technology, 2010. 6 [24] C. I. Watson, M. D. Garris, E. Tabassi, C. L. Wilson, R. M. McCabe, S. Janet, and K. Ko. User’s guide to NIST biometric image software (NBIS). NIST Interagency/Internal Report 7392, 2007. 6 [25] Y. Wen, K. Zhang, Z. Li, and Y. Qiao. A discriminative feature learning approach for deep face recognition. In Proc. ECCV, pages 499– 515. Springer, 2016. 5 [26] X. Yang, J. Feng, and J. Zhou. Localized dictionaries based orientation field estimation for latent fingerprints. IEEE Trans. PAMI, 36(5):955–969, 2014. 4 [27] S. Yoon, J. Feng, and A. K. Jain. Latent fingerprint enhancement via robust orientation field estimation. In Proc. IEEE IJCB, pages 1–8, 2011. 2 [28] F. Zhao and X. Tang. Preprocessing and postprocessing for skeleton-based fingerprint minutiae extraction. Pattern Recognition, 40(4):1270–1281, 2007. 1
1cs.CV
arXiv:1708.02691v3 [stat.ML] 20 Dec 2017 UNIVERSAL FUNCTION APPROXIMATION BY DEEP NEURAL NETS WITH BOUNDED WIDTH AND RELU ACTIVATIONS BORIS HANIN Abstract. This article concerns the expressive power of depth in neural nets with ReLU activations and bounded width. We are particularly interested in the following questions: what is the minimal width wmin (d) so that ReLU nets of width wmin (d) (and arbitrary depth) can approximate any continuous function on the unit cube [0, 1]d aribitrarily well? For ReLU nets near this minimal width, what can one say about the depth necessary to approximate a given function? We obtain an essentially complete answer to these questions for convex functions. Our approach is based on the observation that, due to the convexity of the ReLU activation, ReLU nets are particularly well-suited for representing convex functions. In particular, we prove that ReLU nets with width d + 1 can approximate any continuous convex function of d variables arbitrarily well. These results then give quantitative depth estimates for the rate of approximation of any continuous scalar function on the d-dimensional cube [0, 1]d by ReLU nets with width d + 3. 1. Introduction Over the past several years, neural nets − particularly deep nets − have become the state of the art in a remarkable number of machine learning problems, from mastering Go to image recognition/segmentation and machine translation (see the review article [2] for more background). Despite all their practical successes, a robust theory of why they work so well is in its infancy. Much of the work to date has focused on the problem of explaining and quantifying the expressivity − the ability to approximate a rich class of functions − of deep neural nets [1, 8, 9, 11, 12, 13, 15, 16, 17, 18]. Expressivity can be seen both as an effect of both depth and width. It has been known since at least the work of Cybenko [4] and Hornik-Stinchcombe-White [7] that if no constraint is placed on the width of a hidden layer, then a single hidden layer is enough to approximate essentially any function. The purpose of this article, in contrast, is to investigate the “effect of depth without the aid of width.” More precisely, for each d ≥ 1 we would like to estimate   ReLU nets of width w can approximate any . wmin (d) := min w ∈ N positive continuous function on [0, 1]d arbitrarily well (1) In Theorem 1, we prove that ωmin (d) ≤ d + 2. This raises two questions: Q1. Is the estimate in the previous line sharp? Q2. How efficiently can ReLU nets of a given width w ≥ wmin (d) approximate a given continuous function of d variables? 1 2 B. HANIN On the subject of Q1, we will prove in forthcoming work with M. Sellke [6] that in fact ωmin (d) = d + 1. When d = 1, the lower bound is simple to check, and the upper bound follows for example from Theorem 3.1 in [11]. The main results in this article, however, concern Q1 and Q2 for convex functions. For instance, we prove in Theorem 1 that conv wmin (d) ≤ d + 1, (2) where   ReLU nets of width w can approximate any conv . (3) wmin (d) := min w ∈ N positive convex function on [0, 1]d arbitrarily well This illustrates a central point of the present paper: the convexity of the ReLU activation makes ReLU nets well-adapted to representing convex functions on [0, 1]d . Theorem 1 also addresses Q2 by providing quantitative estimates on the depth of a ReLU net with width d + 1 that approximates a given convex function. We provide similar depth estimates for arbitrary continuous functions on [0, 1]d , but this time for nets of width d + 3. Several of our depth estimates are based on the work of BalázsGyörgy-Szepesvári [3] on max-affine estimators in convex regression. In order to prove Theorem 1, we must understand what functions can be exactly computed by a ReLU net. Such functions are always piecewise affine, and we prove in Theorem 2 the converse: every piecewise affine function on [0, 1]d can be exactly represented by a ReLU net with hidden layer width at most d + 3. Moreover, we prove that the depth of the network that computes such a function is bounded by the number affine pieces it contains. This extends the results of Arora-Basu-MianjyMukherjee (e.g. Theorem 2.1 and Corollary 2.2 in [1]). Convex functions again play a special role. We show that every convex function on [0, 1]d that is piecewise affine with N pieces can be represented exactly by a ReLU net with width d + 1 and depth N. 2. Statement of Results To state our results precisely, we set notation and recall several definitions. For d ≥ 1 and a continuous function f : [0, 1]d → R, write kf kC 0 := sup |f (x)| . x∈[0,1]d Further, denote by ωf (ε) := sup{|f (x) − f (y)| | |x − y| ≤ ε} the modulus of continuity of f, whose value at ε is the maximum f changes when its argument moves by at most ε. Note that by definition of a continuous function, ωf (ε) → 0 as ε → 0. Next, given din , dout , and w ≥ 1, we define a feed-forward neural net with ReLU activations, input dimension din , hidden layer width w, depth n, and output dimension dout to be any member of the finite-dimensional family of functions ReLU ◦An ◦ · · · ◦ ReLU ◦A1 ◦ ReLU ◦A1 that map Rd to Rd+out = {x = (x1 , . . . , xdout ) ∈ Rdout | xi ≥ 0}. In (4), Aj : Rw → Rw , j = 2, . . . , n − 1, A1 : Rdin → Rw , An : Rw → Rdout (4) 3 are affine transformations, and for every m ≥ 1 ReLU(x1 , . . . , xm ) = (max{0, x1 }, . . . , max{0, xm }) . We often denote such a net by N and write fN (x) := ReLU ◦An ◦ · · · ◦ ReLU ◦A1 ◦ ReLU ◦A1 (x) for the function it computes. Our first result contrasts both the width and depth required to approximate continuous, convex, and smooth functions by ReLU nets. Theorem 1. Let d ≥ 1 and f : [0, 1]d → R+ be a positive function with kf kC 0 = 1. We have the following three cases: 1. (f is continuous): There exists a sequence of feed-forward neural nets Nk with ReLU activations, input dimension d, hidden layer width d + 2, output dimension 1, such that lim kf − fNk kC 0 = 0. (5) k→∞ In particular, wmin (d) ≤ d+2. Moreover, write ωf for the modulus of continuity of f, and fix ε > 0. There exists a feed-forward neural nets Nε with ReLU activations, input dimension d, hidden layer width d + 3, output dimension 1, and 2 · d! (6) depth (Nε ) = ωf (ε)d such that kf − fNε kC 0 ≤ ε. (7) 2. (f is convex): There exists a sequence of feed-forward neural nets Nk with ReLU activations, input dimension d, hidden layer width d + 1, and output dimension 1, such that lim kf − fNk kC 0 = 0. (8) k→∞ conv (d) ≤ d + 1. Further, there exists C > 0 such that if f is both Hence, ωmin convex and Lipschitz with Lipschitz constant L, then the nets Nk in (8) can be taken to satisfy depth (Nk ) = k + 1, kf − fNk kC 0 ≤ CLd3/2 k−2/d . (9) 3. (f is smooth): There exists a constant K depending only on d and a constant C depending only on the maximum of the first K derivative of f such that for every k ≥ 3 the width d + 2 nets Nk in (5) can be chosen so that depth(Nk ) = k, kf − fNk kC 0 ≤ C (k − 2)−1/d . (10) conv (d) ≤ d + 1 and the The main novelty of Theorem 1 is the width estimate wmin quantitative depth estimates (9) for convex functions as well as the analogous estimates (6) and (7) for continuous functions. Let us breifly explain the origin of the other estimates. The relation (5) and the corresponding estimate wmin (d) ≤ d + 2 are a combination of the well-known fact that ReLU nets with one hidden layer can approximate any continuous function and a simple procedure by which a ReLU net with input dimension d and a single hidden layer of width n can be replaced by another ReLU net that computes the same function but has depth n + 2 and width d + 2. For 4 B. HANIN these width d + 2 nets, we are unaware of how to obtain quantitative estimates on the depth required to approximate a fixed continuous function to a given precision. At the expense of changing the width of our ReLU nets from d + 2 to d + 3, however, we furnish the estimates (6) and (7). On the other hand, using Theorem 3.1 in [11], when f is sufficiently smooth, we obtain the depth estimates (10) for width d + 2 ReLU nets. Our next result concerns the exact representation of piecewise affine functions by ReLU nets. Instead of measuring the complexity of a such a function by its Lipschitz constant or modulus of continuity, the complexity of a piecewise affine function can be thought of as the minimal number of affine pieces needed to define it. Theorem 2. Let d ≥ 1 and f : [0, 1]d → R+ be the function computed by some ReLU net with input dimension d, output dimension 1, and arbitrary width. There exist affine functions gα , hβ : [0, 1]d → R such that f can be written as the difference of positive convex functions: f = g − h, g := max gα , 1≤α≤N h := max hβ . 1≤β≤M (11) Moreover, there exists a feed-forward neural net N with ReLU activations, input dimension d, hidden layer width d + 3, output dimension 1, and depth (N ) = 2(M + N ) (12) that computes f exactly. Finally, if f is convex (and hence h vanishes), then the width of N can be taken to be d + 1 and the depth can be taken to N. The fact that the function computed by a ReLU net can be written as (11) follows from Theorem 2.1 in [1]. The novelty in Theorem 2 is therefore the uniform width estimate d + 3 in the representation on any function computed by a ReLU net and the d + 1 width estimate for convex functions. Theorem 2 will be used in the proof of Theorem 1. 3. Relation to Previous Work This article is related to several strands of prior work: (1) Theorems 1-2 are “deep and narrow” analogs of the well-known “shallow and wide” universal approximation results (e.g. Cybenko [4] and Hornik- Stinchcombe -White [7]) for feed-forward neural nets. Those articles show that essentially any scalar function f : [0, 1]d → R on the d−dimensional unit cube can be arbitrarily well-approximated by a feed-forward neural net with a single hidden layer with arbitrary width. Such results hold for a wide class of nonlinear activations but are not particularly illuminating from the point of understanding the expressive advantages of depth in neural nets. (2) The results in this article complement the work of Liao-Mhaskar-Poggio [8] and Mhaskar-Poggio [11], who consider the advantages of depth for representing certain heirarchical or compositional functions by neural nets with both ReLU and non-ReLU activations. Their results (e.g. Theorem 1 in [8] and Theorem 3.1 in [11]) give bounds on the width for approximation both for shallow and certain deep heirarchical nets. 5 (3) Theorems 1-2 are also quantitative analogs of Corollary 2.2 and Theorem 2.4 in the work of Arora-Basu-Mianjy-Mukerjee [1]. Their results give bounds on the depth of a ReLU net needed to compute exactly a piecewise linear function of d variables. However, except when d = 1, they do not obtain an estimate on the number of neurons in such a network and hence cannot bound the width of the hidden layers. (4) Our results are related to Theorems II.1 and II.4 of Rolnick-Tegmark [14], which are themselves extensions of Lin-Rolnick-Tegmark [9]. Their results give lower bounds on the total size (number of neurons) of a neural net (with nonReLU activations) that approximates sparse multivariable polynomials. Their bounds do not imply a control on the width of such networks that depends only on the number of variables, however. (5) This work was inpsired in part by questions raised in the work of Telgarsky [15, 16, 17]. In particular, in Theorems 1.1 and 1.2 of [15], Telgarsky constructs interesting examples of sawthooth functions that can be computed efficiently by deep width 2 ReLU nets that cannot be well-approximated by shallower networks with a simlar number of parameters. (6) Theorems 1-2 are quantitative statements about the expressive power of depth without the aid of width. This topic, usually without considering bounds on the width, has been taken up by many authors. We refer the reader to [12, 13] for several interesting quantitative measures of the complexity of functions computed by deep neural nets. (7) Finally, we refer the reader to the interesting work of Yarofsky [18], which provides bounds on the total number of parameters in a ReLU net needed to approximate a given class of functions (mainly balls in various Sobolev spaces). 4. Acknowledgements It is a pleasure to thank Elchanan Mossel and Leonid Hanin for many helpful discussions. This paper originated while I attended EM’s class on deep learning [10]. In particular, I would like to thank him for suggesting proving quantitative bounds in Theorem 2 and for suggesting that a lower bound can be obtained by taking piece-wise linear functions with many different directions. He also pointed out that the width estimates for continuous function in Theorem 1 where sub-optimal in a previous draft. l would also like to thank Leonid Hanin for detailed comments on a several previous drafts and for useful references to results in approximation theory. I am also grateful to Brandon Rule and Matus Telgarsky for comments on an earlier version of this article. I am also grateful to BR for the original suggestion to investigate the expressivity of neural nets of width 2. I also would like to thank Max Kleiman-Weiner for useful comments and discussion. Finally, I thank Zhou Lu for pointing out a serious error what used to be Theorem 3 in a previous version of this article. I have removed that result. 6 B. HANIN 5. Proof of Theorem 2 We first treat the case gα : [0, 1]d → R f = sup gα , 1≤α≤N affine when f is convex. We seek to show that f can be exactly represented by a ReLU net with input dimension d, hidden layer width d + 1, and depth N. Our proof relies on the following observation. Lemma 3. Fix d ≥ 1, let T : Rd+ → R be an arbitrary function, and L : Rd → R be affine. Define an invertible affine transformation A : Rd+1 → Rd+1 by A(x, y) = (x, L(x) + y) . Then the image of the graph of T under A ◦ ReLU ◦A−1 is the graph of x 7→ max{T (x), L(x)}, viewed as a function on Rd+ . Proof. We have A−1 (x, y) = (x, −L(x) + y). Hence, for each x ∈ Rd+ , we have  A ◦ ReLU ◦A−1 (x, T (x)) = x, (T (x) − L(x)) 1{T (x)−L(x)>0} + L(x) = (x, max{T (x), L(x)}) .  We now construct a neural net that computes f. Define invertible affine functions Aα : Rd+1 → Rd+1 by Aα (x, xd+1 ) := (x, gα (x) + xd+1 ) , and set x = (x1 , . . . , xd ), Hα := Aα ◦ ReLU ◦A−1 α . Further, define Hout := ReLU ◦ h~ed+1 , ·i (13) where ~ed+1 is the (d + 1)−st standard basis vector so that h~ed+1 , ·i is the linear map from Rd+1 to R that maps (x1 , . . . , xd+1 ) to xd+1 . Finally, set Hin := ReLU ◦ (id, 0) , where (id, 0) (x) = (x, 0) maps [0, 1]d to the graph of the zero function. Note that the ReLU in this initial layer is linear. With this notation, repeatedly using Lemma 3, we find that Hout ◦ HN ◦ · · · ◦ H1 ◦ Hin therefore has input dimension d, hidden layer width d + 1, depth N and computes f exactly. Next, consider the general case when f is given by f = g − h, g = sup gα , 1≤α≤N h = sup hβ 1≤β≤M as in (11). For this situation, we use a different way of computing the maximum using ReLU nets. 7 Lemma 4. There exists a ReLU net M with input dimension 2, hidden layer width 2, output dimension 1 and depth 2 such that M (x, y) = max{x, y}, x ∈ R, y ∈ R+ . Proof. Set A1 (x, y) := (x − y, y), A2 (z, w) = z + w, and define M = ReLU ◦A2 ◦ ReLU ◦A1 . We have for each y ≥ 0, x ∈ R fM (x, y) = ReLU((x − y)1{x−y>0} + y) = max{x, y}, as desired.  We now describe how to construct a ReLU net N with input dimension d, hidden layer width d + 3, output dimension 1, and depth 2(M + N ) that exactly computes f . We use width d to copy the input x, width 2 to compute successive maximums of the positive affine functions gα , hβ using the net M from Lemma 4 above, and width 1 as memory in which we store g = supα gα while computing h = supβ hβ . The final layer computes the difference f = g − h.  6. Proof of Theorem 1 We begin by showing (8) and (9). Suppose f : [0, 1]d → R+ is convex and fix ε > 0. A simple discretization argument shows that there exists a piecewise affine convex function g : [0, 1]d → R+ such that kf − gkC 0 ≤ ε. By Theorem 2, g can be a exactly represented by a ReLU net with hidden layer width d + 1. This proves (8). In the case that f is Lipschitz, we use the following, a special case of Lemma 4.1 in [3]. Proposition 5. Suppose f : [0, 1]d → R is convex and Lipschitz with Lipschitz constant L. Then for every k ≥ 1 there exist k affine maps Aj : [0, 1]d → R such that ≤ 72L d3/2 k−2/d . f − sup Aj 1≤j≤k C0 Combining this result with Theorem 2 proves (9). We turn to checking (5) and (10). We need the following observations, which seems to be well-known but not written down in the literature. Lemma 6. Let N be a ReLU net with input dimension d, a single hidden layer of e that computes the width n, and output dimension 1. There exists another ReLU net N same function as N but has input dimension d and n + 2 hidden layers with width d + 2. Proof. Denote by {Aj }nj=1 the affine functions computed by each neuron in the hidden layer of N so that   n X cj ReLU(Aj (x)) . fN (x) = ReLU b + j=1 8 B. HANIN Let T > 0 be sufficiently large that T+ k X ∀1 ≤ k ≤ n, x ∈ [0, 1]d . cj ReLU(Aj (x)) > 0, j=1 e are then The affine transformations Aej computed by the j th hidden layer of N e1 (x) := (x, Aj (x), T ) A and and en+2 (x, y, z) = z − T + b, A ej (x, y, z) = (x, Aj (x), z + cj−1 y) , A x ∈ Rd , y, z ∈ R j = 2, . . . , n + 1. We are essentially using width d to copy in the input variable, width 1 to compute each Aj and width 1 to store the output.  Recall that positive continuous functions can be arbitrarily well-approximated by smooth functions and hence by ReLU nets with a single hidden layer (see e.g. Theorem 3.1 [11]). The relation (5) therefore follows from Lemma 6. Similarly, by Theorem 3.1 in [11], if f is smooth, then there exists K = K(d) > 0 and a constant Cf depending only on the maximum value of the first K derivatives of f such that inf kf − fN k ≤ Cf n−1/d , N where the infimum is over ReLU nets N with a single hidden layer of width n. Combining this with Lemma 6 proves (10). It remains to prove (6) and (7). To do this, fix a positive continuous function f : [0, 1]d → R+ with modulus of continuity ωf . Recall that the volume of the unit d-simplex is 1/d! and fix ε > 0. Consider the partition d!/ωf (ε)d d [0, 1] = [ Pj j=1 of [0, 1]d into d!/ωf (ε)d copies of ωf (ε) times the standard d-simplex. Define fε to be a piecewise linear approximation to f obtained by setting fε equal to f on the vertices of the Pj ’s and taking fε to be affine on their interiors. Since the diameter of each Pj is ωf (ε), we have kf − fε kC 0 ≤ ε. Next, since fε is a piecewise affine function, by Theorem 2.1 in [1] (see Theorem 2), we may write fε = gε − hε , where gε , hε are convex, positive, and piecewise affine. Applying Theorem 2 completes the proof of (6) and (7).  9 References [1] R. Arora, A. Basu, P. Mianjy, A. Mukherjee. Understanding deep neural networks with Rectified Linear Units. arXiv:1611.01491v4 [2] Y. Bengio, G. Hinton, and Y. LeCun. Deep learning. Nature. Vol. 521, no. 7553, p. 436-444, 2015. [3] G. Balázs, A, György, and C. Szepesvári. Near-optimal max-affine estimators for convex regression. Proceedings of the Eighteenth International Conference on Artificial Intelligence and Statistics. Vol. 38, p. 56-64, 2015. [4] G. Cybenko. Approximation by superpositions of a sigmoidal function. Mathematics of Control, Signals, and Systems (MCSS). Vol. 2 no. 4, p. 303-314, 1989. [5] B. Hanin, E. Mossel. Expressivity of ReLU nets on the simplex. In preparation. [6] B. Hanin, M. Sellke. Approximating Continuous Functions by ReLU Nets of Minimal Width. arXiv:1710.11278. [7] K. Hornik, M. Stinchcombe, H. White. Multilayer feedforward networks are universal approximators Journal Neural Networks. Vol. 2 no. 5, p. 359-366, 1989. [8] Q. Liao, H. Mhaskar, and T. Poggio. Learning functions: when is deep better than shallow. arXiv:1603.00988v4 (2016). [9] H. Lin, D. Rolnick, M. Tegmark. Why does deep and cheap learning work so well? arXiv:1608.08225v3 (2016). [10] E. Mossel. Mathematical aspects of deep learning: http://elmos.scripts.mit.edu/mathofdeeplearning/mathematica [11] H. Mhaskar, T. Poggio. Deep vs. shallow networks: an approximation theory perspective arXiv:1608.03287v1 (2016). [12] B. Poole, S. Lahiri, M. Raghu, J. Sohl-Dickstein, S. Ganguli Exponential expressivity in deep neural networks through transient chaos. arXiv:1606.05340 (2016) [13] M. Raghu, B. Poole, J. Kleinberg, S. Ganguli, J. Dickstein. On the expressive power of deep neural nets. arXiv:1606.05336v6 (2017) [14] D. Rolnick, M. Tegmark. The power of deeper networks for expressing natural functions. arXiv:1705.05502v1 (2017) [15] M. Telgrasky. Representation benefits of deep feedforward networks. arXiv:1509.08101 (2015). [16] M. Telgrasky. Benefits of depth in neural nets. JMLR: Workshop and Conference Proceedings vol 49:123, 2016. [17] M. Telgrasky. Neural networks and rational functions. arXiv:1706.03301 (2017). [18] D. Yarotsky Error bounds for approximations with deep ReLU network. arXiv:1610.01145 (2017) (B. Hanin) Department of Mathematics, Texas A&M, College Station, United States E-mail address: [email protected]
10math.ST
1 Detection, Recognition and Tracking of Moving Objects from Real-time Video via Visual Vocabulary Model and Species Inspired PSO Kumar S. Ray, Anit Chakraborty, Sayandip Dutta  Abstract— In this paper, we address the basic problem of recognizing moving objects in video images using Visual Vocabulary model and Bag of Words and track our object of interest in the subsequent video frames using species inspired PSO. Initially, the shadow free images are obtained by background modelling followed by foreground modeling to extract the blobs of our object of interest. Subsequently, we train a cubic SVM with human body datasets in accordance with our domain of interest for recognition and tracking. During training, using the principle of Bag of Words we extract necessary features of certain domains and objects for classification. Subsequently, matching these feature sets with those of the extracted object blobs that are obtained by subtracting the shadow free background from the foreground, we detect successfully our object of interest from the test domain. The performance of the classification by cubic SVM is satisfactorily represented by confusion matrix and ROC curve reflecting the accuracy of each module. After classification, our object of interest is tracked in the test domain using species inspired PSO. By combining the adaptive learning tools with the efficient classification of description, we achieve optimum accuracy in recognition of the moving objects. We evaluate our algorithm benchmark datasets: iLIDS, VIVID, Walking2, Woman. Comparative analysis of our algorithm against the existing state-of-the-art trackers shows very satisfactory and competitive results. Index Terms— Background Modelling, Bag of Words, Cubic SVM, Foreground Modelling, Object Detection, Object recognition, PSO, Shadow Removal, Visual Vocabulary. I. INTRODUCTION E FFECTIVE recognition of objects for tracking in real-time video stream and processing of data involve integration of background modelling, shadow removal, foreground modelling and proper detection of objects. Recognition of the detected objects is done by extracting the features obtained from the principle of bag of words (BOW). Extracted feature sets are tracked in the successive test frames via species inspired PSO. Although, various detection and tracking algorithms exist, still; object detection, recognition, effective tracking of feature sets and adoptability of handling occlusions and other noise are still a standing challenge in the field of computer vision. In Kumar S. Ray is with Indian Statistical Institute, 203 B.T Road, Kolkata 108, India. (e-mail: [email protected]) Anit Chakraborty is with Indian Statistical Institute, 203 B. T Road, Kolkata – 108, India. (e-mail: [email protected]). Sayandip Dutta is with Indian Statistical Institute, 203 B.T Road, Kolkata 108, India. (e-mail: [email protected]) order to perform well, in any domain of interest, for any tracking algorithm, satisfactory training model is of utmost importance. In recent years, several attentions [51, 49, 43, 38, 32, 30, 17, 18, 20] have been given in this direction to achieve and share the goal of this paper. Generally, appearance based tracking algorithms are of two types mainly; generative [51, 32, 20, 18] and discriminative [49, 43, 38, 30, 17]. Several tracking algorithms based on static appearance models exists, which are either trained using only the first few consecutive set of iterations or defined manually [56], [36], [7], [35]. These algorithmic frameworks often fail to deal with momentous appearance changes, which cause nonlinear transformation of the appearance of a given object. Such challenges lead to difficulty when there is an absence of sufficient amount of priori knowledge. In our paper, we have considered several appearances of a given training object of our interest, which can capture the momentous and nonlinear changes of the appearances, which are explained in length in Section III and IV. Here, we use the Visual Vocabulary Model using Bag of Words to extract the necessary features of certain instances of objects through rigorous high level training. Subsequently, we apply the features to the test datasets to recognize and locate our objects in the video scenes. Using visual instance occurrence and their probabilistic presence to imply a certain domain, we obtain optimum accuracy in domain recognition as well. The contributions of this paper are: • Background modelling and extraction of astute shadow free images using color invariant approach. • Foreground modelling using morphological operators for effective reconstruction of the image. • Adoptability of handling occlusions and other noises present in the test datasets. • Extraction of the features of the objects captured in the blobs via the principle of Bag of Words. • Classification of the objects in our domain of interest using probabilistic word occurrence for domain recognition. • Tracking of the recognized objects via species inspired PSO. 2 The organization of the paper constitutes: review of related works in the field of object detection and recognition, especially, based on supervised learning are briefly described in the following section (II). Section III explains the proposed method for detection, recognition and tracking, specifically, section III (D) describes the concept of Visual Vocabulary Model for object recognition. Experimental results on several datasets and the comparative analysis with some state-of-theart algorithms are presented in section IV. Section V concludes the paper and discusses the future possibilities for further improvements. II. BRIEF REVIEW OF RELATED WORKS Numerous color histograms based tracking algorithms [52, 55] have been proposed in recent years. The mean shift tracking algorithm has been extended by Collins [53] with the scale variation of object of interests in a video frame. Perez et al. [55] used color histogram in addition with a particle filter [57] for tracking of objects in video frames. A spatiogram based approach has been proposed to capture spatial relationships of statistical properties of pixel, in Birchfield and Rangarajan [45]. He et al. [7] developed a locality sensitive histogram at each pixel for finer distribution of the visual feature points for object tracking in video scenes. Histograms of oriented gradients (HOGs) [42] is proposed for object tracking [34] in addition to the integral histogram [44]. Covariance region descriptors [39] based approaches were introduced for tracking, to combine different features. Local binary patterns (LBP) [54] as well as Haar-like features [47] have been proposed for appearance based tracking of objects [17], [38], [19], [9]. Spatio-temporal representation combined with genetic algorithm has also been used for feature extraction [1]. Recently pixel based segmentations have been applied [2] to handle tracking. Various generative models have been proposed for multiple object tracking in past years. In [58] and [59], Sparse Generative Appearance Modeling is implemented to build an appearance model of objects. Gaussian Mixture Models (GMM) [60] [62], are popular generative approach for tracking. Apart from GMM, several other mixture models have been used in tracking in earlier days, such as finite mixture models [6368]. Priebe et al. [67] introduced an algorithm based on recursive mixture density estimation. To extract time-invariant characteristics, the authors of [69] present a Bayesian Tracking approach using autoregressive Hidden Markov Model (ARHMM) for robust visual tracking. In recent years, discriminative models are leading the way in the field of object tracking [49], [33]. In this method, a binary classifier is trained from the input video sequence, for separation of target and background. The classifiers that have been extensively used for object tracking are: ranking SVM [18], semi-boosting [30], support vector machine (SVM) [49], boosting [38], structured output SVM [19], and online multiinstance boosting [17]. In [49], a trained SVM classifier is integrated for tracking, to tackle appearance based changes with varying illumination. A confidence map [43] in each frame is built using a discriminative feature combination, learned online, for separation of background from target objects. Larese et al. [3] have used SIFT descriptor to discriminate the patterns and then used it to build Bag of Words model and finally classified with SVM. Various tracking codes are available for evaluation with significant effort of the authors, e.g., MIL [17], OAB [38], IVT [32], L1 [26], TLD [23] and likes. III. PROPOSED METHOD Accurate detection of the objects of interest across multiple frames and tracking of the recognized objects are still a challenge. In order to do that, first we model the background and remove the hard shadows from the background to extract the exact area occupied by the object in a frame. Next, we model the foreground and subtract the background model without shadow to obtain the blob of an object. Before recognizing the object inside the blob, we train a machine learning inspired Visual Vocabulary Model with a set of objects which can represent our domain of interest for recognition and tracking. In both the cases, i.e., in case of training stage we extract the features of the objects of the training data by principle of Bag of Words and in the testing phase, we use the same technique to extract the features of the objects of the test data. After classification of extracted feature sets, we track the features of interest of the recognized objects in successive video frames via Species inspired PSO. A. Background Modeling Background modelling is an integral part of our algorithm. This part consists of pretreatment of each frame of the video sequence, followed by temporal image analysis. We update the background continuously so as to adapt to the changing background and other variations. We set a background adaptive threshold in order to differentiate between foreground and background objects. Finally, we apply certain domain centric morphological operators to the updated background to obtain smooth background images. In [31], Li et al. proposed an idea for background modelling. In our work, we introduced some modification of the same work and proceed as follows: 𝑡 At each time step an image 𝐼𝑚 is obtained by subtracting two 𝑡 successive video frames and 𝐹𝑚 can be obtained by subtracting the current video frame with the background model. To deal with sudden illumination variation an AND-OR operation is 𝑡 performed over 𝐼𝑚 and 𝐹𝑚𝑡 . (Fig. 1) Fig. 1. Block diagram of the motion detection module. [31] 3 a. Pretreatment Transformation of color image to grayscale is defined as: gray = 0.299R + 0.587G + 0.114B. (1) b. Temporal image analysis: The extracted frame I t is compared with its previous frame It 𝑡 −1 in order to obtain 𝐼𝑚 by predicting the similarity between the two consecutive pixel values of frames It (x, y) and It-1(x, y), expressed using radiometric similarity R (I t (x,y), I t −1 (x,y)) [31]: R(It(x,y), It−1(x,y))= 𝐸[𝑊(𝐼 𝑡 (𝑥,𝑦)𝑊(𝐼 𝑡−1 (𝑥,𝑦))]−𝐸[𝑊(𝐼 𝑡 (𝑥,𝑦)]𝐸[𝑊(𝐼 𝑡−1 (𝑥,𝑦))] √𝐷[𝑊(𝐼 𝑡 (𝑥,𝑦)]𝐷[𝑊(𝐼 𝑡−1 (𝑥,𝑦)] . (2) Mean and variance of the pixel intensities captured in a particular window of a specific video frame W; E[W], D[W]. Pixel centers are compared between the succeeding images (I t (x, y), I t −1 (x, y)). Temporal binary image of the moving object (𝐼𝑚 ) has a radiometric similarity value, formally expressed as: 1, 𝑖𝑓 𝑅(𝑥, 𝑦) > 𝑇𝑏 𝐼𝑚 (𝑥, 𝑦) = { . (3) 0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 𝑡 Similarly, 𝐹𝑚 is formulated on a hypothesis based on the difference threshold (𝑇𝑏 ), between background frame and the current frame, formally: 1, 𝑖𝑓 |𝐼 𝑡 (𝑥, 𝑦) − 𝐵𝑡 (𝑥, 𝑦)| > 𝑇𝑏 𝐹𝑚𝑡 = { . (4) 0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 The pixels (x,y) of moving objects are formulated by operating on 𝐼𝑚 (𝑥, 𝑦) and 𝐹 𝑡 (𝑥, 𝑦): 1, 𝑖𝑓 (𝐼𝑚 (𝑥, 𝑦) ∩ 𝐹 𝑡 (𝑥, 𝑦)) = 1) 𝑀𝑡 (𝑥, 𝑦) = { . (5) 0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 𝑡 (𝑥, The moving pixels in video frames are identified by 𝑀 𝑦). 𝑝(𝑛) = 1 √2𝜋𝜎 𝑒𝑥𝑝 {− (𝑛−𝜇)2 2𝜎 2 }, (9) where p(n) is the probability of the background pixel. Let d be a pixel of the image, the gray histogram of the pixel is h(d), and background pixels and foreground pixels are denoted by IB and IF respectively. Probability of a background pixel misidentified as foreground pixel and vice versa are as follows: 𝑃𝐹|𝐵 = ∑𝑑∈𝐼𝐹 𝑝(𝑑 | 𝐵) and 𝑃𝐵|𝐹 = ∑𝑑∈𝐼𝐵 𝑝(𝑑 | 𝐹) , (10) where Pd| B is the probability of background pixel and Pd| F is the probability of foreground pixel. Our goal is to minimize Pd|B and Pd|F as much as possible. The Min PF|B is significant, as after morphological operation in the post-process, PB|F will be smaller. 𝑝(𝐵) is the priori probability of the background as calculated 𝑡 from gray histogram of the image 𝐼𝑚 . 𝑇 𝑝(𝐵) = ∑𝑑=−𝑇 ℎ(𝑑) µ = 0. (11) Following is the noise of the variance model, as expressed: 𝜎 = ∑𝑇𝑑=−𝑇 ℎ2 (𝑑)/𝑝(𝐵). (12) A fitting criterion describes the threshold value defined as, 𝑒𝑀𝑖𝑛 = ∑𝑑∈𝐷(𝑝(𝐵)𝑝(𝑑|𝐵) − ℎ(𝑑))2 . (13) e. Morphologic image operation: Apart from moving objects, binary images contain a lot of residual noise. The object detection fails fatally because of many pixel holes in the image. The morphological operators help to remove the holes present and many of the noise by smoothening the edges of the blob. The morphological operators used in this experiment are Adaptive Kernel operator, Gaussian operator and Laplacian Filter. B. Shadow removal As mentioned in [41] by Xu et al., the shadow removal approach is pictorially described in Fig. 2. c. Background updating Background model is updated with newly arrived information from previous frame using the first-order recursive filter: Bt +1 (x, y) = Bt (x, y) +α × (I t (x, y) – B t (x, y)), (6) where α is an arbitrary adaptation coefficient. In our implementation, a vector history V, with the six last values updated cumulatively, is considered as: V = [E(t), E (t −1), E (t − 2), E (t − 3), E(t − 4), E (t − 5)]. (7) At time t, the mean value of the frame is E(t). For each frame, we calculate proper learning rate 𝛼, based on this vector: |𝐸(𝑡)−𝐸(𝑡−5)| 𝛼 =𝑎+𝑏 , (8) max(𝐸(𝑡),𝐸(𝑡−5)) Typically, 𝑎 ranges from 0.04 to 0.06. Here a is chosen to be 0.05. For a given value of b and the gain as stated by |𝐸(𝑡)−𝐸(𝑡−5)| , usually we obtain a small value of 𝛼. The slope Fig. 2. Block diagram of the shadow removal system. [41] max(𝐸(𝑡),𝐸(𝑡−5)) of the gain variation curve, is denoted by b, where the gain is |𝐸(𝑡)−𝐸(𝑡−5)| represented by [ ]. max(𝐸(𝑡),𝐸(𝑡−5)) d. Adaptive threshold: The formulation of the noise is described as follows: The r,g,b normalization is formulated as follows: 𝑟 𝑟 ′ = 2 2 2, (14) 𝑔′ = , (15) , (16) 𝑏′ = √𝑟 +𝑔 +𝑏 𝑔 √𝑟 2 +𝑔2 +𝑏 2 𝑏 √𝑟 2 +𝑔2 +𝑏 2 4 where r, g, b are input image color channels, r’,b’,g’ construct the shadow-free color invariant image. Application of Gaussian smooth filter suppresses the high frequency textures in both invariant and original images. These smoothed color images are converted to gray scale, following the HSV color model definition, to detect the edges, formally: 𝐸𝑜𝑟𝑖 = ‖𝑒𝑑𝑔𝑒(𝐼𝑜𝑟𝑖 )‖, 𝐸𝑖𝑛𝑣(𝑖) = ‖𝑒𝑑𝑔𝑒(𝐼𝑖𝑛𝑣(𝑖) )‖, (17) where 𝐸𝑜𝑟𝑖 is the edge of the original image after applying smooth filter and 𝐼𝑜𝑟𝑖 is the original image. 𝐸𝑖𝑛𝑣(𝑖) is the edge of the color invariant image after applying smooth filter and 𝐼𝑖𝑛𝑣(𝑖) is the color invariant image. Here, the values of i (i.e. the invariant image index) are 1 and 2. The hard shadow edge mask is constructed by choosing the strong edges of original images that are absent in the invariant images. Thus, we get: 1, 𝐸𝑜𝑟𝑖 (𝑥, 𝑦) > 𝑡1, & min(𝐸𝑖𝑛𝑣(𝑖) (𝑥, 𝑦) < 𝑡2) , 𝐻𝑆(𝑥, 𝑦) = { (18) 𝑖 0, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒 where t1, t2 are thresholds, set manually, and assessed hard shadow edge mask is HS(x,y). In (18), t1 maps the selected shadow edges to the strong edges of the subsequent hard shadows in images. t2 selects edges belonging only to shadows. C. Foreground Modelling and Reconstruction In the present work, we have introduced a new concept of foreground modeling. This is essential to recognize and detect the objects from static or moving background variants. We consider Poisson equation solution to reinforce the shadow portions from the derivative frames. To begin with, shadow edge masks of the two kinds and are merged as: mask = VS | HS, (19) where VS represents vague shadow and HS represents hard shadow. Furthermore, masking is applied to the gradient field: ∇𝑖 ′ = 𝑚𝑎𝑠𝑘 ⋅ ∇𝑖 = (𝑚𝑎𝑠𝑘 ⋅ 𝐺𝑥 , 𝑚𝑎𝑠𝑘 ⋅ 𝐺𝑦 ) , (20) where 𝐺𝑥 and 𝐺𝑦 are gradient field along the axis. The clipped derivatives are denoted as Gx’ and Gy’ and the calculation of the scalar is represented as: 𝑑𝑖𝑣𝐺 = 𝜕𝐺𝑥′ 𝜕𝑥 + 𝜕𝐺𝑦′ 𝜕𝑦 . (21) Finally, shadow image restoration is done by working out the well-known Poisson equation: ∇2s = divG, (22) where, s is the calculated shadow image. As we perform the process in logarithmic domain, an exponent operation is added to the image: 𝑆(𝑥, 𝑦) = exp(𝑠(𝑥, 𝑦) − max(𝑠(𝑥, 𝑦))). (23) 𝑥,𝑦 Shadow extraction from original image, as formulated: r(x, y) = i(x, y) − s(x, y), (24) 𝑅(𝑥, 𝑦) = exp(𝑟(𝑥, 𝑦) − max(𝑟(𝑥, 𝑦))), (25) 𝑥,𝑦 where S and R are the shadow image and shadow free image respectively, after reconstruction. Figure 3. (a) shows the actual video frames; column (b) is the modelled background, column (c) corresponds to the foreground modelling. The figures visible are accepted as foreground objects. Fig. 3. (a) Video Frame (b) Background Model (c)Foreground Model D. Visual Vocabulary Model for Object Recognition Visual Vocabulary Model is a machine learning based image classification model, specifically, handling images as documents, by labelling specific features as words. By observing presence of such feature key words in an image, Visual Vocabulary Model can predict the domain of the image and by their arrangement in an image, it can recognize different objects. We have adopted this method as it yields satisfactory results with limited training samples, and the accuracy only increases with the increase in training datasets. In our paper, scene recognition is essential to narrow down the objects that can be present in a scene. Recognition using Visual Vocabulary consists of selection of distinct key words and normalization of the surrounding regional content. Assigning a descriptor to the normalized content, helps matching the captured objects which are of our domain of interest. a. Visual keyword localization: To localize the keywords, first step is to extract the features of the object of interest such that they are distinct and invariant under different scale and illumination based conditions even with the presence of noise. To construct the Visual Vocabulary a corpus of training images need to be stored in the feature space in order to model the descriptor instances. Subsequently, the modelled descriptors have to be clustered for quantization of the feature space into distinctive visual words, where the visual words signify the center of the cluster. For given video frames, the closest matching visual key points are recognized with the corresponding features. The bag of words feature sets can be used to define the principle description of any given videoframe. This process can be divided into three steps, namely; tokenization, counting and normalization. In tokenization phase, similar feature patches are labelled via kmean clustering. In the counting phrase, the number of tokens are counted to get an estimate of the scene. Finally, different tokens are assigned with different weightage based on their arrangement, which differentiates between various objects. 5 b. Classification: Extracted features are classified in order to distinguish the objects of interest (say, human) from any other objects present in the videoframe. We have used Nonlinear (cubic) Support Vector Machine (SVM) as the feature classifier. Cubic SVM bundles consider consecutive triples of words for classification. In our case, cubic SVM performed better than all other types of SVM as well as other classifiers. Polynomial kernel for cubic SVM is: 𝐾(𝑥, 𝑦) = (𝑥 𝑇 𝑦 + 𝑐)3 . (26) Here x and y are input vector features, calculated from the training samples. A free parameter, c  0, is indicating how far the equation is from homogeneity. The matching cost is 𝑚𝑖 (𝑙𝑖 ) at location 𝑙𝑖 , with the placing part 𝑣𝑖 and deformation cost between two corresponding part locations represented by 𝑑𝑖,𝑗 (𝑙𝑖 , 𝑙𝑗 ): c. Detection of feature of test objects: In this section, we have followed the similar approach of bag words to extract the textual distribution as feature of the test objects in the video scenes. During classification process, similar feature in different objects can lead to uncertainty in feature assignment. Dealing with uncertainty, implicit shape model has been proposed (ISM). In ISM algorithm, extraction of local features and matching it to the Visual Vocabulary is done using soft matching. At the time of validation of our classification process we used the notion of soft computing which is basically a heuristic interpretation of our matching threshold. The following equation expresses the contribution of a feature f, at location l, at position x in the object class o𝑛 with matching visual keywords (C𝑖 ) indicating its potentiality of belonging to the class o𝑛 . Thus, we get: 𝑝(𝑜𝑛 , 𝑥|𝑓, 𝑙) = ∑𝑖 𝑝(𝑜𝑛 , 𝑥|𝐶𝑖 , 𝑙) 𝑝(𝐶𝑖 |𝑓), (27) where 𝑝(𝑜𝑛 , 𝑥|𝑓, 𝑙) indicates the probability of feature f at frame location l to belong to the class of o𝑛 at image position x. The weights are populated in continuous 3D weighing region for object position x= (x, y, s). For visual keyword 𝐶𝑖 , the first term of the right-hand side of (27) indicates the stored occurrence distribution, which is weighted by the second term, the probability of feature f, belonging to the exact class of 𝐶𝑖 . Mean-shift mode estimation with a kernel K, along with scale-adaptive kernel, is used to obtain the maxima in this space: 𝑥−𝑥 1 ∑𝑘 ∑𝑗 𝑝(𝑜𝑛 , 𝑥𝑗 |𝑓𝑘 , 𝑙𝑘 )𝐾 ( 𝑗 ). 𝑝̂ (𝑜𝑛 , 𝑥) = (28) 𝑙1∗ = arg min (𝑚1 (𝑙1 ) + ∑𝑛𝑖=2 min 𝑚𝑖 (𝑙𝑖 ) + ||𝑙𝑖 − 𝑉b (𝑥𝑠 ) 𝑏(𝑥𝑠 ) Kernel bandwidth is denoted by b, and volume is denoted by 𝑉𝑏 , which are varied over the radius of the kernel. In order to fix the hypothesized interest object, size and scale coordinate 𝒙𝑠 is parallelly updated. This strategy makes it easier to deal with partial occlusions and also typically requires fewer training examples. The pictorial structure model represents any object of interest as collection of parts, connected in pairs, and defined by a graph G = (V, E), where the nodes V = {𝑣1 , … , 𝑣𝑛 } defines the parts and the edges (𝑣𝑖 , 𝑣𝑗 ) 𝜖 𝐸 describes the corresponding connections. L = {𝑙1 , … , 𝑙𝑛 } be a certain arrangement of part frame locations. Then the matching of the model to a video frame is formulated using an energy minimization function: 𝐿∗ = arg min (∑𝑛𝑖=1 𝑚𝑖 (𝑙𝑖 ) + ∑(𝑣𝑖,𝑣𝑗 )∈𝐸 𝑑𝑖,𝑗 (𝑙𝑖 , 𝑙𝑗 )). (29) 𝐿 𝑇 𝑑𝑖,𝑗 (𝑙𝑖 , 𝑙𝑗 ) = (𝑇𝑖𝑗 (𝑙𝑖 ) − 𝑇𝑗𝑖 (𝑙𝑗 )) 𝑀𝑖𝑗−1 (𝑇𝑖𝑗 (𝑙𝑖 ) − 𝑇𝑗𝑖 (𝑙𝑗 )), (30) where 𝑑𝑖,𝑗 is Mahalanobis Distance between transformed locations 𝑇𝑖𝑗 (𝑙𝑖 ) and 𝑇𝑗𝑖 (𝑙𝑗 ), 𝑀𝑖𝑗 being the diagonal covariance. The root node optimum location stated as: 𝑙1∗ = arg min(𝑚1 (𝑙1 ) + ∑𝑛𝑖=2 𝐷𝑚𝑖 (𝑇1𝑖 (𝑙1 ))), (31) 𝑙1 where 𝐷𝑚𝑖 (𝑇1𝑖 (𝑙1 )) represents a sum of the root node’s response as a distance-transformed version of each child node. Thus, we get: 𝑙1 𝑙𝑖 𝑇1𝑖 (𝑙1 )||2𝑀𝑖𝑗 ) . (32) In (Fig. 4), visual word tokenization is explained and furthermore, the visual word occurrence frequency is explained in the following section. It signifies the number of time a particular word vector represents its class of object in varied frames. This is evidently the parameter that decides the characteristics of a particular object. Fig. 4. Tokenization in Bag of Words: Similar feature vectors are grouped as one word, which is later used for matching. To validate the classification, cross validation approach is applied by randomly splitting the array of objects into train data subsets and test data subsets. Then it creates a confusion matrix for comparing the correct and incorrect classification of features for training of Visual Vocabulary Model. The sum along the principle diagonal of the confusion matrix represents the number of correctly classified objects. The ratio between correctly classified object to the total number of objects to be identified gives the validation accuracy. d. Adaption of Discriminative model based on Pyramid Matching Kernel (PMK) approach: In this paper, we have essentially considered discriminative model for tracking the objects with different appearance (Fig. 9). For further improvement of our validation score by approximating the similarity measures, we are modelling a 6 linear time matching function, represented by the Pyramid Match Kernel (PMK) model to bridge the feature sets to the variable cardinalities. Let the input of a histogram pyramid be X ϵ S where Ψ(X) = [𝐻0 (𝑋), … , 𝐻𝐿−1 (𝑿)], number of pyramid levels expressed as L. The histogram vector of point X is defined by 𝐻𝑖 (𝑿). Similarity between two input set of features Y and Z is expressed as: 𝜅𝑃𝑀𝐾 (Ψ(𝑌), Ψ(𝑍)) = ∑𝐿−1 𝑖=0 𝜔𝑖 (𝐼(𝐻𝑖 (𝑌), 𝐻𝑖 (𝑍)) − 𝐼(𝐻𝑖−1 (𝑌), 𝐻𝑖−1 (𝑍))), ∗ 𝑥𝑡,𝑘 = arg max 𝑝(𝑜𝑡,𝑘 |𝑥𝑡,𝑘 ), 𝑘 = 1, … , 𝑀 𝑥𝑡,𝑘 (35) b. Competition Model: When different object obscure one another, there is an overlap between corresponding support regions. In these circumstances, the competition between two objects elevates to subjugate the overlapping part (Fig. 5). In order to effectively design the competition phenomenon, the visual problem needs to be merged with the competition process. (33) where 𝐼(𝐻𝑖 (𝑌), 𝐻𝑖 (𝑍))signifies the histogram intersection of two input set of features Y and Z at ith level of the pyramid. E. Region of Interest Tracking The species inspired PSO framework provides an effective way to track multiple object that are detected and recognized from aforementioned method (visual word features). First, for singular object tracking, following analogies need to be assumed: • The groundtruth of an object and surrounding region can be considered as ecological properties. • State space particles correspond to a particular species. • Each particle’s observation likelihood and fitness capability of a particular species is analogous. For multiple object tracking, these postulates can be easily extended by creating a tracker for each object. These trackers are managed independently. In case of occlusion, support regions of concerning objects may overlap, which implies, the intersectional area between two species are elementary to both. Subsequently, the repulsion and competition among the species arise as both of them aspire to the same resource, the stronger one has higher probability of winning the competition. During the course of video scene, there may be overlap between two object areas due to occlusion and the related features between them may become ambiguous. To handle this hindrance, we design a multiple-species-based PSO algorithm. The principle idea behind this approach [19], is to divide the groundtruth particles of the object into various species according to the species object numbers and successfully model the relations and the partial visibility among varied species. Detailed description of the species inspired PSO algorithm is briefly described in the following sections. a. Problem Construction: Let us consider, M number of objects, surrounded with N 𝑖,𝑛 number of particles, constitute a set 𝜒 = { 𝑥𝑡,𝑘 , 𝑖 = 1, … , 𝑁, 𝑘 = 𝑖,𝑛 1, … , 𝑀}, 𝓞 = { 𝑜𝑡,𝑘 , 𝑖 = 1, … , 𝑁, 𝑘 = 1, … , 𝑀}. Here t is the 2D translation parameter. Formula of multiple object tracking is as follows: 𝜒 ∗ = arg max 𝑝(𝓞|𝝌) (34) 𝑖 By independently maximizing of the individual observation likelihood, the above optimization may be simplified, in case of no occlusion. In case of no occlusion, the above optimization may be simplified by maximizing the individual observation likelihood independently (here, we drop the superscript i, n for simplicity): Figure 5. Overlap between two object areas. To evaluate the fitness value on the overlapping part as the competition ability, the overlapping part is viewed at a whole and projected onto the learned subspace corresponding to each object. We define the power of each object or species in following manner: ̂𝑘 𝑈 ̂𝑘𝑇 𝑜̂𝑡,𝑘 ‖2 ), (36) 𝑝𝑜𝑤𝑒𝑟 𝑘 = 𝑝(𝑜̂𝑡,𝑘 |𝑥𝑡,𝑘 ) = 𝑒𝑥𝑝 (−‖𝑜̂𝑡,𝑘 − 𝑈 ̂𝑘 are the overlapping part of the object and its where k and 𝑈 corresponding subspace respectively. In a similar way, the interactive likelihood of object 𝑘1 over the overlapping regions can be calculated: 𝑝𝑜𝑤𝑒𝑟 𝑘1 𝑝(𝑜̂𝑡,𝑘1 |𝑥𝑡,𝑘1 , 𝑥𝑡,𝑘2 ) = . ⏟ ∑𝑖=1,2 𝑝𝑜𝑤𝑒𝑟 𝑘𝑖 (37) 𝑖𝑛𝑡𝑒𝑟𝑎𝑐𝑡𝑖𝑣𝑒 𝑙𝑖𝑘𝑒𝑙𝑖ℎ𝑜𝑜𝑑 The mutual likelihood of each species describes the competition ability. Higher the competition ability of a species more like it is to win the competition. It means that the species which won the competition is more likely to be of the object that was occluding the other object species involved. c. Annealed Gaussian Based PSO (AGPSO) An annealed Gaussian based PSO algorithm [21] is considered in this paper, as in conventional PSO requires careful and fine tuning of various parameters. In this algorithm, the particles and corresponding velocities are updated in below mentioned manner: 𝑣 𝑖,𝑛+1 = |𝑟1 |(𝑝𝑖 − 𝑥 𝑖,𝑛 ) + |𝑟2 |(𝑔 − 𝑥 𝑖,𝑛 ) + 𝜖 (38) 7 𝑥 𝑖,𝑛+𝑖 = 𝑥 𝑖,𝑛 + 𝑣 𝑖,𝑛+1 , (39) where |𝑟1 | and |𝑟2 | being the absolute values of the samples from Gaussian probability distribution N (0, 1). This is zeromean Gaussian disturbance that stops the algorithm from getting trapped in local optima. With the help of adaptive simulated annealing, the covariance matrix of 𝜖 is changed [34]: ∑𝜖 = ∑ 𝑒 −𝑐𝑛 . (40) Here, a transition distribution is predefined and Σ is its covariance matrix, annealing constant c, and iteration number n. The components in Σ decrease in proportion to the iteration number which results in a fast rate of convergence. When 𝑘1 and 𝑘2 occlude each other at time t, a repulsion force is added to the evolution process of particles, and subsequently the iteration step for 𝑘1 becomes as follows: 𝑖,𝑛+1 𝑖,𝑛 𝑖,𝑛 𝑖 𝑣𝑡,𝑘 = |𝑟1 |(𝑝𝑡,𝑘 − 𝑥𝑡,𝑘 ) + |𝑟2 |(𝑔𝑡,𝑘1 − 𝑥𝑡,𝑘 )+ 1 1 1 1 |𝑟3 |𝐹⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗⃗ 𝑘2 ,𝑘1 + 𝜖 𝑖,𝑛+1 𝑥𝑡,𝑘 1 = 𝑖,𝑛 𝑥𝑡,𝑘 1 + 𝑖,𝑛+1 𝑣𝑡,𝑘 , 1 (41) (42) where the parameter 𝑟3 is Gaussian random number sampling from N (0, 1). The third term on the right-hand side of the above equation depicts the shared effect between object 𝑘2 and 𝑘1 . In other words, the competition phenomenon on the observation level has been modelled in this paper. Also, the competition model of state space has been modelled to drive the evolution process of the species in the right direction. d. Updating of the Appearance Model Selectively In most of the tracking algorithms [24], [29], appearance models are not updated during occlusion. However, the appearance of the object under occlusion may change, and that can cause the tracker to fail to recapture the object appearance after it is not occluded anymore. A selective updating algorithm is implemented to cope with the appearance changes during occlusion: pixels belonging to the visual part of the objects are cumulatively updated in the normal way and pixels that are part of the overlapping region (Fig. 5) are projected onto the subsequent subspace of each object. Then the errors due to the reconstruction are calculated. If this error is smaller than a predefined threshold for pixels inside the overlapping area, then it is again updated in the subsequent subspace. Due to this careful modelling of the updating strategy, the appearance changes can be easily accommodated, allowing more persistent tracking throughout the video stream. IV. EXPERIMENTAL RESULTS AND ANALYSIS Proposed method is evaluated on benchmark datasets and compared it with the existing state-of-the art tracking algorithms. Brief description of the experimental datasets is shown followed by the experimental parameter settings and analysis. All the tests were done on an Intel 5th Gen core i7, 2.10 GHz processor with 6 Gigabytes of RAM and 2 Gigabytes NVDIA GeForce GPU and the algorithm was implemented using MATLAB’16 development tool. A. Experimental Datasets We evaluate the proposed algorithm on benchmark TB100 sequences, namely, iLIDS [4], VIVID [46], Walking2 [50] and Woman [40]. In the following section, we discuss the various attributes of the aforementioned datasets. The primary challenges in the iLIDS dataset [4] (imagery Library for Intelligent Detection Systems) is the Scale Variation (SV), In Plane Rotation (IPR), Occlusion (OCC), Low Resolution (LR) and Illumination Variation (IV). This video consists of a total number of four people walking to, from and across the camera view, with the camera mounted at an isometric angle, where only one man carries a trolley. The video is 10 minutes long, at 25 frames per second, with each frame having a dimension of 720x570 pixels, which we have scaled down to 180x144 for low resolution analysis. The woman dataset [40] is much more challenging, as one has to handle Illumination variation, Scale variation, Occlusion, Deformation (DEF), Motion Blur (MB), Fast Motion (FM) and Out Plane Rotation (OPR). It has 597 video frames of 352x288 resolution. Here the camera view follows a woman walking past several cars. The VIVID dataset [46] is part of DARPA VIVID program consisting 9 video sequences. Here we deal with one of those nine videos, namely, RedTeam. The video contains challenges such as; Scale Variation, Occlusion, In Plane Rotation, Out Plane Rotation and Low Resolution. This is an aerial footage of a car driving on a straight road then turning a corner at the end forming long shadow cast of the object. Therefore, shadow removal gives a better result in tracking. Walking2 dataset [50] contains difficulties like Scale Variation, Occlusion and Low Resolution. The video contains 500 frames, each of dimension 384x288 pixels. The video is of some people walking down the corridor of an office interior. This video is in many ways similar to the iLIDS dataset. In the following section, we demonstrate the accuracy of our algorithm and susceptibility in handling all the challenges offered by these benchmark datasets. B. Experimental Setting All the aforementioned datasets consist of RGB color channels, which are more memory extensive for image processing. So, we temporarily convert them to grayscale using the equation: gray = 0.299R + 0.587G + 0.114B. Furthermore, we update the background model with the process mentioned in (14) (15) and (16) of our proposed method. Then we process each frame with their original RGB color channels and reconstruct a new image by feeding only the normalized R and G color channel values. This normalized image removes the shadow component from the image, which essentially, helps in accurate tracking. After this step, we convert this image into a binary image through background subtraction [Figure 6.(b)]. We dilate the image by employing some morphological operations. However, this image does not preserve the edges satisfactorily enough. Thus, we extract the binary image with edges intact, by simple background subtraction [Figure 6. (c)]. Then we pointwise multiply these images to obtain the complete shadow free image [Figure6. (d)] with edges preserved. 8 Fig. 6. (a) Original Image, (b) Color Invariant Image, (c) Simple Background Subtracted Image, (d) Reconstructed Image For training, we consider the domain with train data sets and we use Visual Vocabulary features. We’re extracting key points and calculating the probable occurrences in the subsequent frames (Fig. 7). Continuing with this process, we extract all the key points of certain domain oriented objects from different angle-posture-view high definition picture datasets for better accuracy. Fig. 8. Tracking Results C. Analysis and Evaluation We test our algorithm on the dataset mentioned above with the aforementioned setting. The confusion matrix (Fig. 10) shows that we have reached up to 85.33% accuracy. Here, we consider INRIA Person Dataset for training of our Visual Vocabulary Model from various angle and postures for accurate detection and recognition, as portrayed in Fig. 9. Fig. 7. Training Results Visual Vocabulary using Cubic SVM based classification covers two other parameters, namely domain detection of the scene and object identification for further video frames, which are independent to camera axis orientation, camera background relationship and surroundings. It provides recognition accuracy of roughly 93.3%. Then we use the extracted and trained features to the Species inspired PSO for accurate and content aware tracking. Following this process, as we can see in (Fig. 8), the unattended luggage is also recognized. Here the luggage is a rigid object which remains stationary for most of the video and when it is moved by any human, it forms a connected blob with that human. Normally, in such cases, PSO cannot track successfully, but because of the feature driven input to the Species inspired PSO, we get the results shown below. Fig. 9. Training image montage: Moderately high-resolution pictures of the object of interest, preferably from different angles More training always leads to higher accuracy. Our training data here consisted of partial photos of train that had almost similar dimension like cars. That is why our classifier has maximum confusion in this situation, as reflected by the confusion matrix. 9 Next, a comparative analysis of the Frame Per Second (FPS), provided in [5], is demonstrated in Table 5. We implement our algorithm on the VIVID dataset [46], and compare it with various state-of-the-art methods to obtain the necessary data for Table 5. Table 1. Detection Accuracy on iLIDS Dataset [4] Fig. 10. Confusion Matrix and ROC Curve Other plots like, ROC curve and scatter point data show the classifier performance and the plot between True Positive Rate and False Positive Rate. Prediction model curve shows the structure containing a classification object and a function for prediction. This structure allows to make predictions for data models that include principal component analysis (PCA). Applying the extracted features to the test datasets, using Visual Key points, prediction of new objects of interest in the video sequence is done. Subsequently, using the trained model as a reference to recognize newly arrived objects, as shown in the (Fig. 11), with a validation accuracy of roughly 93.13%. Approach Year Accuracy ASLA [11] DFT [12] IVT [32] MIL [17] PCOM [6] LSS [8] Proposed method 2012 2012 2008 2009 2014 2013 79.24% 81.21% 82.36% 84.29% 79.87% 78.39% 91.3% Table 2. Detection Accuracy on VIVID Dataset [46] Approach Year Accuracy ASLA [11] DFT [12] IVT [32] MIL [17] PCOM [6] LSS [8] Proposed method 2012 2012 2008 2009 2014 2013 86.3% 85.3% 88.9% 90.2% 86.7% 87.2% 92.7% Table 3. Detection Accuracy on Walking2 Dataset [50] Fig. 11. Prediction on Test Data Train models using machine learning learners are applied in the video sequences and the algorithm predicts with recognition, the objects of interests, present in the consequent video frames, as stated above. Domain recognition of the test sequence also being predicted by the probability distribution of presence of objects [i.e. Visual Key Points] in the scene, as shown in the [Fig. 12] Approach Year Accuracy ASLA [11] DFT [12] IVT [32] MIL [17] PCOM [6] LSS [8] Proposed method 2012 2012 2008 2009 2014 2013 88.2% 87.9% 89.8% 90.2% 88.3% 90.7% 93.5% Table 4. Detection Accuracy on Woman Dataset [40] Fig. 12. Domain Recognition Now, we compare the detection accuracy of our algorithm with different benchmark methods as shown in Table 1, 2, 3, 4. Approach Year Accuracy ASLA [11] DFT [12] IVT [32] MIL [17] PCOM [6] LSS [8] Proposed method 2012 2012 2008 2009 2014 2013 87.8% 88.2% 90.9% 91.2% 88.4% 89.1% 93.7% 10 Table 5. Evaluated Tracking Algorithms Published ✓ FPS ✓ ✓ Matlab C Model Update Generative ✓ Code Discriminative Sparse ✓ Binary or Haar Subspace ✓ Histogram ✓ Color Template ASLA Representation Local Trackers ✓ 8.5 ‘12 BSBT H ✓ ✓ ✓ 7.0 ‘09 CXT B ✓ ✓ ✓ 15.3 ‘11 ✓ 13.2 ‘12 DFT ✓ ✓ ✓ ✓ IVT ✓ ✓ LIAPG ✓ ✓ LOT ✓ LSS ✓ ✓ ✓ ✓ ✓ ✓ MIL H MTT ✓ ✓ ORIA ✓ ✓ PCOM ✓ ✓ SMS Proposed method ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ ✓ 33.4 ‘08 ✓ ✓ ✓ ✓ 2.0 ‘12 ✓ ✓ ✓ 0.7 ‘12 ✓ ✓ ✓ 15 ‘13 ✓ ✓ H ✓ ✓ ✓ ✓ 38.1 ‘09 ✓ ✓ ✓ 1.0 ‘12 ✓ ✓ 20.2 ‘11 20 ‘14 19.2 ‘03 ✓ ✓ ✓ ✓ ✓ In all these cases, our algorithm performs competitively better than all the popular existing approaches. This is due to the fact that other algorithms are effective to deal with certain challenges offered by the datasets, but they are not susceptible enough to cope up with all the challenges of datasets, as stated earlier in section IV (A). Table 6 represent the comparative performance of different trackers with our proposed algorithm. In Table 6, each entry has a numerator term which represents tracking score and the denominator term represents the false positive in tracking. A careful inspection of Table. 6 reveals the fact that in all the cases our algorithm performs better than the existing ones. Fig. 14 graphically depicts the above stated fact about the performance measure which indicates the proposed algorithm’s flexibility in adapting with real-life challenges. Fig. 13 further shows a comparative study on the performance of our algorithm with respect to tracking accuracy and the size of Visual Vocabulary Model. Thus, the ✓ ✓ ✓ ✓ ✓ 29 _ proposed algorithm performs very satisfactorily over different challenging attributes of different images and illumination variations of the video frames. Fig. 13. Graphical Representation of Accuracy Analysis As it can be seen in (Fig. 14), our algorithm performs best on Walking2 datasets, which is expected because of fewer number of challenging attributes. It performs well on iLIDS and VIVID datasets despite the low-resolution video frames. 11 Table 6. Performance of different algorithms on different attributes Trackers Features Scale Variation (SV) In Plane Rotation (IPR) Occlusion (OCC) Illumination Variation (IV) ASLA [11] DFT [12] IVT [32] MIL [17] PCOM [6] LSS [8] 54.0 / 3.9 52.1 / 4.1 56.0 / 3.8 59.6 / 3.0 47.9 / 5.9 50.7 / 5.1 52.7 / 5.1 53.0 / 4.7 47.1 / 5.3 46.4 / 5.3 49.3 / 5.1 51.2 / 4.8 44.5 / 6.5 45.7 / 5.9 47.6 / 5.8 47.1 / 5.6 44.8/5.7 48.5 / 5.3 47.1 / 5.5 51.2 / 5.1 51.4 / 5.2 43.7/5.9 47.4/5.5 47.8/5.8 Proposed method 58.0/4.1 50.7/3.9 60.9/1.6 59.9/2.7 REFERENCES Fig. 14. Accuracy vs Visual Vocabulary of the proposed algorithm, plotted on 4 datasets. V. CONCLUSION This paper presents object detection, recognition of the detected objects based on Visual Vocabulary Model and tracking of the recognized objects using Species inspired PSO. We train different objects separately in several images with multiple aspects and camera viewpoints to find the best key word points for recognition. Subsequently, we verify the extracted features of the train images. These key word points are applied to the regions based on visual feature point analysis. The comparative analysis is done using visual key word points. We present similarity measures using PMK approach [Section IV, D(d)] for feature matching. The object is satisfactorily detected. After detection of the object, the recognition of the specific object of our interest is done in section IV (D). Finally, the features of the recognized objects are tracked by the Species inspired PSO, which can also efficiently handle the tracking under partial occlusions as shown in Fig 8. The performance measure of the proposed algorithm is done with respect to available benchmark data [4, 46, 50, 40] and we obtain very satisfactory and competitive results. In future, we have a plan to modify the detection and recognition scheme based on the theory of SP (Simplicity & Power) Intelligence. [1] Learning Spatio-Temporal Representations for Action Recognition: A Genetic Programming Approach, IEEE Trans. On cybernetics, Vol. 46, No. 1, Nov. 2016 [2] F. Xiao, Y. J. Lee, “Track and Segment: An Iterative Unsupervised Approach for Video Object Proposals”, 2016. [3] M. G. Larese, P. M. Granitto, “Finding local leaf vein patterns for legume characterization and classification”, Machine Vision and Applications, 2015 [4] P. Foggia, A. Greco, A Saggese and M. Vento, “A Method for Detecting Long Term Left Baggage Based on Heat Map”, VISAPP, 2015 [5] Y. Wu, J. Lim, M. Yang, “Object Tracking Benchmark”, IEEE Trans. Pattern Analysis and Machine Intelligence, vol. 37, no. 9, pp. 1837-1838, Sept. 2015. [6] D. Wang and H. Lu, “Visual tracking via probability continuous outlier model,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2014, pp. 3478–3485. [7] S. He, Q. Yang, R. W. H. Lau, J. Wang, and M.-H. Yang, “Visual tracking via locality sensitive histograms,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2013, pp. 2427– 2434. [8] D. Wang, H. Lu, and M.-H. Yang, “Least soft-thresold squares tracking,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2013, pp. 2371–2378. [9] K. Zhang, L. Zhang, and M.-H. Yang, “Real-time compressive tracking,” in Proc. 12th Eur. Conf. Comput. Vis., 2012, pp. 864–877. [10] Y. Bai and M. Tang, “Robust tracking via weakly supervised ranking SVM,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1854–1861. [11] X. Jia, H. Lu, and M.-H. Yang, “Visual tracking via adaptive structural local sparse appearance model,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1822– 1829. [12] L. Sevilla-Lara and E. Learned-Miller, “Distribution fields for tracking,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1910–1917. [13] C. Bao, Y. Wu, H. Ling, and H. Ji, “Real time robust l1 tracker using accelerated proximal gradient approach,” in Proc. 12 IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1830– 1837. [14] S. Oron, A. Bar-Hillel, D. Levi, and S. Avidan, “Locally orderless tracking,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1940–1947. [15] T. Zhang, B. Ghanem, S. Liu, and N. Ahuja, “Robust visual tracking via multi-task sparse learning,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 2042–2049. [16] Y. Wu, B. Shen, and H. Ling, “Online robust image alignment via iterative convex optimization,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2012, pp. 1808–1814. [17] B. Babenko, M.-H. Yang, and S. Belongie, “Robust object tracking with online multiple instance learning,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 33, no. 7, pp. 1619–1632, Aug. 2011. [18] Li, H., Shen, C., Shi, Q.: Real-time visual tracking using compressive sensing. In: CVPR, pp. 1305–1312 (2011). [19] S. Hare, A. Saffari, and P. H. S. Torr, “Struck: Structured output tracking with kernels,” in Proc. IEEE Int. Conf. Comput. Vis., 2011, pp. 263–270. [20] Mei, X., Ling, H.: Robust visual tracking and vehicle classification via sparse representation. PAMI 33, 2259–2272 (2011) [21] T. B. Dinh, N. Vo, and G. Medioni, “Context tracker: Exploring supporters and distracters in unconstrained environments,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2011, pp. 1177– 1184. [22] B. Liu, J. Huang, L. Yang, and C. Kulikowsk, “Robust tracking using local sparse appearance model and K-selection,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2011, pp. 1313–1320. [23] Z. Kalal, J. Matas, and K. Mikolajczyk, “P-N Learning: Bootstrapping binary classifiers by structural constraints,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2010, pp. 49–56. [26] X. Mei and H. Ling, “Robust visual tracking using l1 minimization,” in Proc. 12th IEEE Int. Conf. Comput. Vis., 2009, pp. 1436–1443. [27] S. Stalder, H. Grabner, and L. van Gool, “Beyond semisupervised tracking: Tracking should be as simple as detection, but not simpler than recognition,” in Proc. 12th IEEE Int. Conf. Comput. Vis. Workshop, 2009, pp. 1409–1416. [28] P. Dolla´r, B. Babenko, S. Belongie, P. Perona, and Z. Tu, “Multiple Component Learning for Object Detection,” Proc. European Conf. Computer Vision, 2008. [29] P. Felzenszwalb, D. McAllester, and D. Ramanan, “A Discriminatively Trained, Multiscale, Deformable Part Model,” Proc. IEEE Conf. Computer Vision and Pattern Recognition, 2008. [30] Grabner, H., Leistner, C., Bischof, H.: Semi-supervised On-Line Boosting for Robust Tracking. In: Forsyth, D., Torr, P., Zisserman, A. (eds.) ECCV 2008, Part I. LNCS, vol. 5302, pp. 234–247. Springer, Heidelberg (2008) [31] G. Li, Y. Wang, W. Shu, Real-time moving object detection for video monitoring systems, International Symposium on Intelligent Information Technology Application, 2008. [32] D. Ross, J. Lim, R.-S. Lin, and M.-H. Yang, “Incremental learning for robust visual tracking,” Int. J. Comput. Vis., vol. 77, no. 1, pp. 125–141, 2008. [33] S. Avidan, “Ensemble tracking,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 29, no. 2, pp. 261–271, Feb. 2007. [34] F. Tang, S. Brennan, Q. Zhao, and H. Tao, “Co-Tracking using semi- supervised support vector machines,” in Proc. 11th IEEE Conf. Comput. Vis. Pattern Recognit., 2007, pp. 1–8. [35] A. Adam, E. Rivlin, and I. Shimshoni, “Robust FragmentsBased Tracking Using the Integral Histogram,” Proc. IEEE Conf. Computer Vision and Pattern Recognition, vol. 1, pp. 798-805, 2006. [36] V. Lepetit and P. Fua, “Keypoint Recognition Using Randomized Trees,” IEEE Trans. Pattern Analysis and Machine Intelligence, vol. 28, no. 9, pp. 1465-1479, Sept. 2006. [37] D. Nister, H. Stewenius, “Scalable Recognition with a Vocabulary Tree”, Department of Computer Science, University of Kentucky, 2006. [38] H. Grabner, M. Grabner, and H. Bischof, “Real-time tracking via on-line boosting,” in Proc. British Mach. Vis. Conf., 2006, pp. 6.1– 6.10. [39] O. Tuzel, F. Porikli, and P. Meer, “Region covariance: A fast descriptor for detection and classification,” in Proc. 9th Eur. Conf. Comput. Vis., 2006, pp. 589–600. [40] A. Adam, E. Rivlin, and I. Shimshoni, “Robust fragmentsbased tracking using the integral histogram,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2006, pp. 798–805. [41] L. Xu, F. Qi, R. Jiang, "Shadow Removal from a Single Image", Proc. IEEE Int'l Conf. Intelligent Systems Design and Applications, pp. 1049-1054, 2006. [42] N. Dalal and B. Triggs, “Histograms of oriented gradients for human detection,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2005, pp. 886–893. [43] R. T. Collins, Y. Liu, and M. Leordeanu, “Online selection of discriminative tracking features,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 27, no. 10, pp. 1631–1643, Oct. 2005. [44] F. Porikli, “Integral histogram: A fast way to extract histograms in cartesian spaces,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2005, pp. 829–836. [45] S. T. Birchfield and S. Rangarajan, “Spatiograms versus histograms for region-based tracking,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2005, pp. 1158–1163. [46] R. Collins, X. Zhou, and S. K. Teh, “An open source tracking testbed and evaluation web site,” in Proc. IEEE Int. Workshop Perform. Eval. Tracking Surveillance, 2005, pp. 17– 24. [47] P. Viola and M. J. Jones, “Robust real-time face detection,” Int. J. Comput. Vis., vol. 57, no. 2, pp. 137–154, 2004. [49] S. Avidan, “Support vector tracking,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 26, no. 8, pp. 1064–1072, Aug. 2004. [50] R. B. Fisher, “The PETS04 surveillance ground-truth data sets,” in Proc. IEEE Int. Workshop Perform. Eval. Tracking Surveillance, 2004, pp. 1–5. [51] Jepson, A., Fleet, D., Maraghi, T.: Robust online appearance models for visual tracking. PAMI 25, 1296–1311 (2003) [52] D. Comaniciu, V. Ramesh, and P. Meer, “Kernel-based object tracking,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 25, no. 5, pp. 564–577, May 2003. [53] R. T. Collins, “Mean-shift blob tracking through scale space,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2003, pp. 234–240. 13 [54] T. Ojala, M. Pietikäinen, and T. Mäenpää, “Multiresolution grayscale and rotation invariant texture classification with local binary patterns,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 24, no. 7, pp. 971–987, Jul. 2002. [55] P. P_erez, C. Hue, J. Vermaak, and M. Gangnet, “Colorbased probabilistic tracking,” in Proc. 7th Eur. Conf. Comput. Vis., 2002, pp. 661–675 [56] M. Isard and J. Maccormick, “Bramble: A Bayesian Multiple-Blob Tracker,” Proc. IEEE Int’l Conf. Computer Vision, vol. 2, pp. 34-41, 2001. [57] M. Isard and A. Blake, “Condensation-Conditional density propagation for visual tracking,” Int. J. Comput. Vis., vol. 29, no. 1, pp. 5–28, 1998. [58] D. Riahi and G.-A. Bilodeau, “Multiple object tracking based on sparse generative appearance modeling,” in Image Processing (ICIP), 2015 IEEE International Conference on. IEEE, 2015, pp. 4017–4021. [59] Chenglong Bao, Yi Wu, Haibin Ling, and Hui Ji, “Real time robust l1 tracker using accelerated proximal gradient approach,” in CVPR. IEEE, 2012, pp. 1830–1837. [60] C. Stauffer, W.E.L. Grimson, "Adaptive Background Mixture Models for Real-Time Tracking", Proc. Computer Vision and Pattern Recognition 1999 (CVPR '99), 1999-June [62] S. McKenna, Y. Raja, S. Gong, "Tracking Colour Objects Using Adaptive Mixture Models", Image and Vision Computing J., vol. 17, pp. 223-229, 1999. [63] C. Bishop, Neural Networks for Pattern Recognition, Oxford University Press, New York, 1995. [64] B.S. Everitt, D.J. Hand, Finite Mixture Distributions, Chapman and Hall, New York, 1981. [65] G.J. McLachlan, K.E. Basford, Mixture Models: Inference and Applications to Clustering, Marcel Dekker Inc., New York, 1988. [66] C.E. Priebe, Adaptive mixtures, Journal of the American Statistics Association 89 (427) (1994) 796–806. [67] C.E.Priebe,D.J. Maxchette, Adaptive mixtures: recursive nonparametric pattern recognition, Pattern Recognition 24 (12) (1991) 1197–1209. [68] C.E. Priebe, D.J. Marchette, Adaptive mixture density estimation, Pattern Recognition 26 (5) (1993) 771–785. [69] D. Park, J. Kwon, and K. Lee, “Robust visual tracking using autoregressive hidden markov model,” in CVPR, pp. 1964–1971, IEEE, 2012.
2cs.AI
Decomposable Submodular Function Minimization: Discrete and Continuous arXiv:1703.01830v1 [cs.LG] 6 Mar 2017 Alina Ene∗ Huy L. Nguyễn† László A. Végh‡ March 7, 2017 Abstract This paper investigates connections between discrete and continuous approaches for decomposable submodular function minimization. We provide improved running time estimates for the state-of-the-art continuous algorithms for the problem using combinatorial arguments. We also provide a systematic experimental comparison of the two types of methods, based on a clear distinction between level-0 and level-1 algorithms. 1 Introduction Submodular functions arise in a wide range of applications: graph theory, optimization, economics, game theory, to name a few. A function f : 2V → R on a ground set V is submodular if f (X) + f (Y ) ≥ f (X ∩ Y ) + f (X ∪ Y ) for all sets X, Y ⊆ V . Submodularity can also be interpreted as a decreasing marginals property. There has been significant interest in submodular optimization in the machine learning and computer vision communities. The submodular function minimization (SFM) problem arises in problems in image segmentation or MAP inference tasks in Markov Random Fields. Landmark results in combinatorial optimization give polynomial-time exact algorithms for SFM. However, the high-degree polynomial dependence in the running time is prohibitive for large-scale problem instances. The main objective in this context is to develop fast and scalable SFM algorithms. Instead of minimizing arbitrary submodular functions, several recent papers aim to exploit special structural properties of submodular functions arising in practical applications. A popular model is decomposable submodular functions: these can be written as sums of several “simple” submodular functions defined on small supports. Some definitions are in order. Let f : 2V → R be a submodular function, and let n := |V |. We can assume w.l.o.g. that f (∅) = 0. We are interested in solving the submodular function minimization problem min f (S). S⊆V The base polytope of a submodular function is defined as B(f ) := {x ∈ RV : x(S) ≤ f (S) ∀S ⊆ V, x(V ) = f (V )}. ∗ Department of Computer Science, Boston University, [email protected] of Computer and Information Science, Northeastern University, [email protected] ‡ Department of Mathematics, London School of Economics, [email protected] † College 1 (SFM) One can optimize linear functions over B(f ) using the greedy algorithm. The problem (SFM) can be reduced to finding the minimum norm point of the base polytope B(f ) [Fuj80].   1 2 min kyk2 : y ∈ B(f ) . (Min-Norm) 2 This reduction is the starting point of convex optimization approaches for (SFM). We refer the reader to Sections 44–45 in [Sch03] for concepts and results in submodular optimization, and to [Bac11] on machine learning applications. We assume that f is given in the decomposition f (S) = r X fi (S), i=1 where each fi : 2V → R is a submodular function. Such functions are called decomposable or Sum-ofSubmodular (SoS) in the literature. In this paper, we will use the abbreviation DSFM. For each i ∈ [r], the function fi has an effective support Ci such that fi (S) = fi (S ∩ Ci ) for every S ⊆ V . For each i ∈ [r], we assume that two oracles are provided: (i) a value oracle that returns fi (S) for any set S ⊆ V in time EOi ; and (ii) a quadratic minimization oracle Oi (w). For any input vector w ∈ Rn , this oracle returns an optimal solution to (Min-Norm) for the function fi + w, or equivalently, an optimal solution to miny∈B(fi ) ky + wk22. We let Θi denote the running time of a single call to the oracle Oi , Θmax := maxi∈[r] Θi P denote the maximum time of an oracle call, Θavg := 1r i∈[r] Θi denote the average time of an oracle call.1 We let Fi,max := maxS⊆V |fi (S)|, Fmax := maxS⊆V |f (S)| denote the maximum function values. Decomposable SFM thus requires algorithms on two levels. The level-0 algorithms are the subroutines used to evaluate the oracles Oi for every i ∈ [r]. The level-1 algorithm minimizes the function f using the level-0 algorithms as black boxes. 1.1 Prior work SFM has had a long history in combinatorial optimization since the early 1970s, following the influential work of Edmonds [Edm70]. The first polynomial-time algorithm was obtained via the ellipsoid method [GLS81]; recent work presented substantial improvements using this approach [LSW15]. Substantial work focused on designing strongly polynomial combinatorial algorithms [Sch00, IFF01, FI03, Iwa03, Orl09, IO09]. Still, designing practical algorithms for SFM that can be applied to large-scale problem instances remains an open problem. Let us now turn to decomposable SFM. Previous work mainly focused on level-1 algorithms. These can be classified as discrete and continuous optimization methods. The discrete approach builds on techniques of classical discrete algorithms for network flows and for submodular flows. Kolmogorov [Kol12] showed that the problem can be reduced to submodular flow maximization, and also presented a more efficient augmenting path algorithm. Subsequent discrete approaches were given in [ABKM12, FJMPZ13, FWZ14]. Continuous approaches start with convex programming formulation (Min-Norm). Gradient methods were applied for the decomposable setting in [SK10, NJJ14, EN15]. Less attention has been given to the level-0 algorithms. Some papers mainly focus on theoretical guarantees on the running time of level-1 algorithms, and treat the level-0 subroutines as black-boxes (e.g. [Kol12, NJJ14, EN15]). In other papers (e.g. [SK10, JBS13]), the model is restricted to functions fi of a simple specific type that are easy to minimize. An alternative assumption is that all Ci ’s are small, of size at most k; and thus these oracles can be evaluated by exhaustive search, in 2k value oracle calls (e.g. [ABKM12, FJMPZ13]). 1 For flow-type algorithms for DSFM, a slightly weaker oracle assumption suffices, returning a minimizer of minS⊆Ci fi (S) + w(S) for any given w ∈ RCi . This oracle and the quadratic minimization oracle are reducible to each other: the former reduces to a single call to the latter, and one can implement the latter using O(|Ci |) calls to the former (see e.g. [Bac11]). 2 Shanu et al. [SAS16] use a block coordinate descent method for level-1, and allow arbitrary functions fi . The oracles are evaluated via the Fujishige-Wolfe minimum norm point algorithm [FI11, Wol76] for level-0. 1.2 Our contributions Our paper establishes connections between discrete and continuous methods for decomposable SFM, as well as provides a systematic experimental comparison of these approaches. Our main theoretical contribution improves the worst-case complexity bound of the most recent continuous optimization methods [NJJ14, EN15] by a factor of r, the number of functions in the decomposition. This is achieved by improving the bounds on the relevant condition numbers. Our proof exploits ideas from the discrete optimization approach. This provides not only better, but also considerably simpler arguments than the algebraic proof in [NJJ14]. The guiding principle of our experimental work is the clean conceptual distinction between the level-0 and level-1 algorithms. Previous experimental studies considered the level-0 and level-1 algorithms as a single “package”. For example, Shanu et al. [SAS16] compare the performance of their SoS Min-Norm algorithm to the continuous approach of Jegelka et al. [JBS13] and the combinatorial approach of Arora et al. [ABKM12]. However, these implementations are difficult to compare since they use three different level-0 algorithms: Fujishige-Wolfe in SoS Min-Norm, a general QP solver for the algorithm of [JBS13], and exhaustive search for [ABKM12]. For potentials of large support, Fujishige-Wolfe outperforms these other level-0 subroutines, hence the algorithms in [JBS13, ABKM12] could have compared more favorably using the same FujishigeWolfe subroutine. In our experimental setup, we compare level-1 algorithms by using the same level-0 subroutines. We compare the state-of-the-art continuous and discrete algorithms: RCDM and ACDM from [EN15] with Submodular IBFS from [FJMPZ13]. We consider multiple options for the level-0 subroutines. For certain potential types, we use tailored subroutines exploiting the specific form of the problem. We also consider a variant of the Fujishige-Wolfe algorithm as a subroutine applicable for arbitrary potentials. Our experimental results reveal the following tradeoff. Discrete algorithms on level-1 require more calls to the level-0 oracle, but less overhead computation. Hence using algorithms such as IBFS on level-1 can be significantly faster than gradient descent as long as the potentials have fairly small supports. However, as the size of the potentials grow, or we do need to work with a generic level-0 algorithm, the better choice is using gradient methods. Gradient methods can perform better for larger potentials also due to weaker requirements on the level-0 subroutines: approximate level-0 subroutines suffice for them, whereas discrete algorithms require exact optimal solutions on level-0. Paper outline. The rest of the paper is structured as follows. Section 2 describes the level-1 algorithmic framework for DSFM that is based on network flows, and outlines the IBFS algorithm. Section 3 describes the level-1 algorithmic framework for DSFM that is based on convex optimization, and outlines the gradient descent algorithms. Section 4 gives improved convergence guarantees for the gradient descent algorithms outlined in Section 3. Section 5 discusses the different types of level-0 algorithms and how they can be used together with the level-1 frameworks. Section 6 presents our experimental results. 2 Level-1 algorithms based on network flow In this section, we outline a level-1 algorithmic framework for DSFM that is based on a combinatorial framework first studied in [FZ92].2 Pr For a decomposable function f , every x ∈ B(f ) can be written as x = i=1 xi , where supp(xi ) ⊆ Ci and xi ∈ B(fi ) (see e.g. Theorem 44.6 in [Sch03]). A natural algorithmic approach is to maintain an x ∈ B(f ) in such a representation, and iteratively update it using the combinatorial framework described below. DSFM 2 The framework was introduced in a slightly different context, for the submodular intersection problem. The dual of this problem is minimizing a submodular function of the form f = f1 + f2 , with access to oracles minimizing f1 and f2 . 3 can be casted as a maximum network flow instance in a network that is suitably defined based on the current point x. This can be viewed as an analogue of the residual graph in the maxflow/mincut setting, and it is precisely the residual graph if the DSFM instance was a mincut instance. Pr The auxiliary graph. For an x ∈ B(f Sr) of the form x = i=1 xi , we construct the following directed auxiliary graph G = (V, E), with E = i=1 Ei and capacities c : E → R+ . The arc sets Ei are complete directed graphs (cliques) on Ci , and for an arc (u, v) ∈ Ei , we define c(u, v) := min{fi (S)−xi (S) : S ⊆ Ci , u ∈ S, v ∈ / S}. This is the maximum value ε such that x′i ∈ B(fi ), where x′i (u) = xi (u) + ε, x′i (v) = xi (v) − ε, ′ xi (z) = xi (z) for z ∈ / {u, v}. Let N := {v ∈ V : x(v) < 0} and P := {v ∈ V : x(v) > 0}. The algorithm aims to improve the current x by updating along shortest directed paths from N to P with positive capacity; there are several ways to update the solution, and we discuss specific approaches later in the section. If there exists no such directed path, then we let S denote the set reachable from N on directed paths with positive capacity; thus, S ∩ P = ∅. It is easy to show that S is a minimizer of the function f . Updating along a shortest path Q from N to P amounts to the following. Let ε denote the minimum capacity of an arc on Q. If (u, v) ∈ Q ∩ Ei , then we increase xi (u) by ε and decrease xi (v) by ε. The crucial technical claim [FZ92] is the following. Let d(u) denote the shortest path distance of positive capacity arcs from u to the set P . Then, an update along a shortest directed path from N to P results in a feasible x ∈ B(f ), and further, all distance labels d(u) are non-decreasing. Level-1 algorithms based on the network flow approach. Using this auxiliary graph, and updating on shortest augmenting paths, one can generalize several maximum flow algorithms to a level-1 algorithm of DSFM. These algorithms include: the Edmonds-Karp-Dinitz maximum flow algorithm, the preflow-push algorithm [GT88], the incremental breadth first search algorithm (IBFS) [GHK+ 11], and the excesses incremental breadth first search algorithm [GHK+ 15]. Our experiments will use an implementation of IBFS, following [FJMPZ13]. Submodular incremental breadth first search (IBFS). Fix et al. [FJMPZ13] adapt the IBFS algorithm to the above described submodular framework using the above mentioned claims by Fujishige & Zhang [FZ92]. IBFS is an augmenting path algorithm for the maximum flow problem. It identifies a shortest path from the source set N to the sink set P via growing shortest path trees simultaneously forwards from N and backwards from P . The submodular IBFS algorithm provides us with a level-1 algorithm for DSFM. Each step of the algorithm involves determining the capacity of an arc in the auxiliary graph; as we explain in Section 5, each of these capacities can be computed using a single call to a level-0 subroutine Oi . By combining the level-1 IBFS algorithm with appropriate level-0 subroutines, we obtain an algorithm for DSFM whose running time can be upper bounded as follows. On a directed graph with n nodes and m P arcs, IBFS runs in time O(n2 m). In the DSFM setting, we have m = O( i∈[r] |Ci |2 ). Every step involves determining an auxiliary capacity, which can be implemented using a single call to a level-0 subroutine Oi (see Section 5); the maximum time of P such an oracle call is Θmax . Hence, the running time bound for submodular IBFS can be given as O(n2 Θmax i∈[r] |Ci |2 ). If all Ci ’s are small, O(1), then this gives O(n2 rΘmax ). 3 Level-1 algorithms based on convex optimization In this section, we outline the level-1 algorithms for DSFM that are based on gradient descent. Recall the convex quadratic program (Min-Norm) from the Introduction. This program has a unique optimal solution s∗ ; the set S = {v ∈ V : s∗ (v) < 0} is the unique smallest minimizer to (SFM). We will refer to this optimal solution s∗ throughout the section. In the DSFM setting, one can write (Min-Norm) in multiple equivalent forms [JBS13]. For the first formu- 4 lation, we let P := Qr i=1 B(fi ) ⊆ Rrn , and let A ∈ Rn×(rn) denote the following matrix: A := [In In . . . In ] . | {z } r times Pr Note that, for every y ∈ P, Ay = i=1 yi , where yi is the i-th block of y, and thus Ay ∈ B(f ). The problem (Min-Norm) can be reformulated for DSFM as follow.   1 2 kAyk2 : y ∈ P . (Prox-DSFM) min 2 The second formulation is the following. Let us define the subspace A := {a ∈ Rnr : Aa = 0}, and minimize its distance from P:  min ka − yk22 : a ∈ A, y ∈ P . (Best-Approx) The set of optimal solutions for both formulations (Prox-DSFM) and (Best-Approx) is the set E := {y ∈ P : Ay = s∗ }, where s∗ is the optimum of (Min-Norm). We note that, even though the set of solutions to (Best-Approx) are pairs of points (a, y) ∈ A × P, the optimal solutions are uniquely determined by y ∈ P, since the corresponding a is the projection of y to A. Lemma 3.1 ([JBS13], Lemma 2). The set E is non-empty and it coincides with the set of optimal solutions of (Prox-DSFM) and (Best-Approx). Gradient methods. The gradient descent algorithms of [NJJ14, EN15] provide level-1 algorithms for DSFM. In the following, we provide a brief overview of these algorithms and we refer the reader to the respective papers for more details. The alternating projections algorithm. Nishihara et al. minimize (Best-Approx) using alternating projections and it iteratively constructs a sequence  (k) (k) [NJJ14]. The algorithm starts with(k)a point a0 ∈ A (k) (a , x ) k≥0 by projecting onto A and P: x = argminx∈P ka − xk2 , a(k+1) = argmina∈A ka − x(k) k2 . Random coordinate descent algorithms. Ene and Nguyen minimize (Prox-DSFM) using random coordinate descent [EN15]. The RCDM algorithm adapts the random coordinate descent algorithm of Nesterov [Nes12] to (Prox-DSFM). In each iteration, the algorithm samples a block i ∈ [r] uniformly at random and it updates xi via a standard gradient descent step for smooth functions. ACDM, the accelerated version of the algorithm, presents a further enhancement using techniques from [FR15]. Rate of convergence. The algorithms mentioned above enjoy a linear convergence rate despite the fact that the objective functions of (Best-Approx) and (Prox-DSFM) are not strongly convex. Instead, these works show that there are certain parameters that one can associate with the objective functions such that the convergence is at the rate (1 − α)k , where α ∈ (0, 1) is a quantity that depends on the appropriate parameter. Let us now precisely define these parameters and state the convergence guarantees as a function of these parameters. Let A′ be the affine subspace A′ := {a ∈ Rnr : Aa = s∗ }. Note that E = P ∩ A′ . For y ∈ Rnr and a closed set K ⊆ Rnr , we let d(y, K) = min {ky − zk2 : z ∈ K} denote the distance between y and K. The relevant parameter for the Alternating Projections algorithm is defined as follows. Definition 3.2 ([NJJ14]). For every y ∈ (P ∪ A′ ) \ E, let d(y, E) , and max {d(y, P), d(y, A′ )} κ∗ := sup {κ(y) : y ∈ (P ∪ A′ ) \ E} . κ(y) := The relevant parameter for the random coordinate descent algorithms is the following. 5 Definition 3.3 ([EN15]). For every y ∈ P, let y ∗ := argminp {kp − yk2 : Ap = s∗ } be the optimal solution to (Prox-DSFM) that is closest to y. We say that the objective function 21 kAyk22 of (Prox-DSFM) is restricted ℓ-strongly convex if, for all y ∈ P, we have kA(y − y ∗ )k22 ≥ ℓky − y ∗ k22 , and   1 ℓ∗ := sup ℓ : kAyk22 is restricted ℓ-strongly convex . 2 The running time dependence of the algorithms on these parameters is given in the following theorems. Theorem 3.4 ([NJJ14]). Let (a(0) , x(0) = argminx∈P ka(0) − xk2 ) be the initial solution and let (a∗ , x∗ ) be an optimal solution to (Best-Approx). The alternating projection algorithm produces in    (0) kx − x∗ k2 k = Θ κ2∗ ln ǫ iterations a pair of points a(k) ∈ A and x(k) ∈ P that is ǫ-optimal, i.e., ka(k) − x(k) k22 ≤ ka∗ − x∗ k22 + ε. Theorem 3.5 ([EN15]). Let x(0) ∈ P be the initial solution and let x∗ be an optimal solution to (Prox-DSFM) that minimizes kx(0) − x∗ k2 . The random coordinate descent algorithm produces in    (0) r kx − x∗ k2 k=Θ ln ℓ∗ ǫ   iterations a solution x(k) that is ǫ-optimal in expectation, i.e., E 21 kAx(k) k22 ≤ 21 kAx∗ k22 + ǫ. The accelerated coordinate descent algorithm produces in   (0)  r kx − x∗ k2 1 ln k=Θ r ℓ∗ ǫ  q    (0) ∗  k2 epochs with Θ r ℓ1∗ iterations in each epoch) a solution x(k) iterations (specifically, Θ ln kx −x ǫ 1  that is ǫ-optimal in expectation, i.e., E 2 kAx(k) k22 ≤ 12 kAx∗ k22 + ǫ. Nishihara et al. √ show that κ∗ ≤ nr, and a family of instances (in fact, minimum cut instances) is given for 2 which κ∗ ≥ Ω(n r). Ene √ and Nguyen show 2that ℓ∗ ≥ r/κ∗ . In Theorem 4.2, we close the remaining gap and show that κ∗ = Θ(n r) and ℓ∗ = Θ(1/n ), and thus we obtain tight analyses for the running times of the above mentioned algorithms. By combining the level-1 gradient descent algorithms with appropriate level-0 subroutines, we obtain algorithms for DSFM whose running times can be upper bounded as follows. our improved conver  (0)Using  kx −x∗ k2 2 gence guarantees, it follows that RCDM obtains in time O n rΘavg ln a solution that is  ǫ  (0) ∗  k2 . We ε-approximate in expectation. For ACDM, the improved time bound is O nrΘavg ln kx −x ǫ √ can upper bound the diameter of the base polytope by O( nFmax ) [JB11]. For integer-valued functions, a ε-approximate solution can be converted to an exact optimum if ε = O(1/n) [Bac11]. 4 Tight convergence bounds for the continuous algorithms In this section, we show that the combinatorial approach introduced in Section 2 can be applied to obtain better bounds on the parameters κ∗ and ℓ∗ defined in Section 3. Besides giving a stronger bound, our proof is considerably simpler than the algebraic one using Cheeger’s inequality in [NJJ14]. The key is the following lemma. 6 Lemma 4.1. Let y ∈ P and s∗ ∈ B(f ). Then there exists a point x ∈ P such that Ax = s∗ and kx − yk2 ≤ √ n ∗ 2 kAy − s k1 . Before proving this lemma, we show how it can be used to derive the bounds. √ Theorem 4.2. We have κ∗ ≤ n r/2 + 1 and ℓ∗ ≥ 4/n2 . Proof: We start with the bound on κ∗ . In order to bound κ∗ , we need to upper bound κ(y) for any y ∈ (P ∪ A′ ) \ E. We distinguish between two cases: y ∈ P \ E and y ∈ A′ \ E. √ Case I: y ∈ P \ E. The denominator in the definition of κ(y) is equal to d(y, A′ ) = kAy − s∗ k2 / r. This follows since the closest point a = (a1 , . . . , ar ) to y in A′ is to set ai = yi + (s∗ − Ay)/r for each i ∈ [r]. √ Lemma 4.1 gives an x ∈ P such that Ax = s∗ and kx − yk2 ≤ 2n kAy − s∗ k1 ≤ n2 kAy − s∗ k2 . Since Ax√= s∗ , ∗ we √have x ∈ E and thus the numerator of κ(y) is at most kx−yk2 . Thus κ(y) ≤ kx − yk2 /(kAy − s k2 / r) ≤ n r/2. Case II: y ∈ A′ \ E. This means that Ay = s∗ . The denominator of κ(y) is equal to d(y, P). For each i ∈ [r], let qi ∈ B(fi ) be the point that minimizes kyi − qi k2 . Let q = (q1 , . . . , qr ) ∈ P. √Then d(y, P) = ky − qk2 . Lemma 4.1 with q in place of y gives a point x ∈ E such that kq − xk2 ≤ 2n kAq − s∗ k1 . We have √ Pr √ n r kq − yk2 . − yk . Thus kq − xk ≤ kAq − s∗ k1 = kAq − Ayk1 ≤ i=1 kqi − yi k1 = kq − yk1 ≤ nrkq 2 2 2     Since x ∈ E, we have d(y, E) ≤ kx − yk2 ≤ kx − qk2 + kq − yk2 ≤ 1 + Therefore κ(p) ≤ 1 + √ n r 2 , √ n r 2 kq − yk2 = 1 + √ n r 2 d(y, P). as desired. Let us now prove the bound on ℓ∗ . Let y ∈ P and let y ∗ := argminp {kp − yk2 : Ap = s∗ }. We need to verify that kA(y −y ∗ )k22 ≥ n42 ky −y ∗ k22 . Again, we apply Lemma 4.1 to obtain a point x ∈ P such that Ax = s∗ and 2 kx − yk22 ≤ n4 kAx − Ayk21 ≤ n4 kAx − Ayk22 . Since Ax = s∗ , the definition of y ∗ gives ky − y ∗ k22 ≤ kx − yk22 . Using that Ax = Ay ∗ = s∗ , we have kAx − Ayk2 = kAy − Ay ∗ k2 . The same calculation as in Case II above 2 implies the required ky − y ∗ k22 ≤ n4 kA(y − y ∗ )k22 .  Proof of Lemma 4.1: We give an algorithm that transforms y to a vector x ∈ P as in the statement through a sequence of path augmentations in the auxiliary graph defined in Section 2. We initialize x = y and maintain x ∈ P (and thus Ax ∈ B(f )) throughout. We now define the set of source and sink nodes as ∗ N := {v ∈ V : (Ax)(v) < s∗ (v)} and P := {v ∈ V : (Ax)(v) N = P = ∅, we have Ax = s∗ P > s (v)}.POnce ∗ ∗ and terminate. Note that since Ax, s ∈ B(f ), we have v (Ax)(v) = v s (v) = f (V ), and therefore N = ∅ is equivalent to P = ∅. The blocks of x are denoted as x = (x1 , x2 , . . . , xr ), with xi ∈ B(fi ). Claim 4.3. If N 6= ∅, then there exists a directed path of positive capacity in the auxiliary graph between the sets N and P . Proof: We say that a set T is i-tight, if xi (T ) = fi (T ). It is a simple consequence of submodularity that the intersection and union of two i-tight sets are also i-tight sets. For every i ∈ [r] and every u ∈ V , we define Ti (u) as the unique minimal i-tight set containing u. It is easy to see that for an arc (u, v) ∈ Ei , c(u, v) > 0 if and only if v ∈ Ti (u). We note that if u ∈ / Ci , then x(u) = fi ({u}) = 0 and thus Ti (u) = {u}. Let S be the set of vertices reachable from N on a directed path of positive capacity in the auxiliary graph. For a contradiction, assume S ∩ P = ∅. By the definition of S, we must have Ti (u) ⊆ S for every u ∈ S and every i ∈ [r]. Since the union of i-tight sets is also i-tight, we see that S is i-tight for every i ∈ [r], and consequently, x(S) = f (S). On the other hand, since N ⊆ S, S ∩ P = ∅, and N 6= ∅, we have x(S) < s∗ (S). Since s∗ ∈ B(f ), we have x(S) < s∗ (S) ≤ f (S), which is a contradiction. We conclude that S ∩ P 6= ∅.  In every step of the algorithm, we take a shortest directed path Q of positive capacity from N to P , and update x along this path. That is, if (u, v) ∈ Q ∩ Ei , then we increase xi (u) by ε and decrease xi (v) by ε, where ε is the minimum capacity of an arc on Q. Note that this is the same as running the Edmonds-KarpDinitz algorithm in the submodular auxiliary graph. Using the analysis in [FZ92], one can show that this change maintains x ∈ P, and that the algorithm terminates in finite (in fact, strongly polynomial) time. 7 It remains to bound kx− yk2. At every path update, the change in ℓ∞ -norm of x is atP most ε, and the change in ℓ1 -norm is at most nε, since the length of the path is ≤ n. At the same time, v∈N (s∗ (v) − (Ax)(v)) decreases by ε. Thus, kx − yk∞ ≤ kAy −√s∗ k1 /2 and kx − yk1 ≤ nkAy − s∗ k1 /2. Using the inequality p kpk2 ≤ kpk1 kpk∞ , we obtain kx − yk2 ≤ 2n kAy − s∗ k1 , completing the proof.  5 The level-0 algorithms In this section, we briefly discuss the level-0 algorithms and the interface between the level-1 and level-0 algorithms. Two-level frameworks via quadratic minimization oracles. Recall from the Introduction the assumption on the subroutines Oi (w) that finds the minimum norm point in B(fi + w) for the input vector w ∈ Rn . The continuous methods in Section 3 directly use the subroutines Oi (w) for the alternating projection or coordinate descent steps. For the flow-based algorithms in Section 2, the main oracle query is to find the auxiliary graph capacity c(u, v) of an arc (u, v) ∈ Ei for some i ∈ [r]. This can be easily formulated as minimizing the function fi + w for an appropriate w with supp(w) ⊆ Ci ; the details are given in Lemma 5.1. As explained at the beginning of Section 3, an optimal solution to (Min-Norm) immediately gives an optimal solution to (SFM) for the same submodular function. Hence, the auxiliary graph capacity queries can be implemented via the subroutines Oi (w). Let us also remark that, while the functions fi are formally defined on the entire ground set V , their effective support is Ci , and thus it suffices to solve the quadratic minimization problems on the ground set Ci . Lemma 5.1. The capacity c(u, v) := min{fi (S) − xi (S) : S ⊆ Ci , u ∈ S, v ∈ / S} can be computed as the minimum value of minS⊆Ci fi (S) + w(S) for an appropriately chosen vector w ∈ Rn , supp(w) ⊆ Ci . Proof: We define a weight vector w ∈ Rn as follows: w(u) = −(fi ({u}) + 1); w(v) = −(fi (Ci ) − fi (Ci \ {v}) − 1); w(a) = −x(a) for all a ∈ Ci \ {u, v}, and w(a) = 0 for all a ∈ / Ci . Let A ⊆ Ci be a minimizer / A. Note that fi ({u}) = fi ({u}) − f (∅) is of minS⊆Ci fi (S) + w(S). It suffices to show that u ∈ A and v ∈ the maximum marginal value of u, i.e., maxS (fi (S ∪ {u}) − fi (S)). Moreover, fi (Ci ) − fi (Ci \ {v}) is the minimum marginal value of v. To show u ∈ A, let us assume for a contradiction that u ∈ / A. fi (A ∪ {u}) + w(A ∪ {u}) = (fi (A) + w(A)) + (fi (A ∪ {u}) − fi (A)) + w(u) = (fi (A) + w(A)) + (fi (A ∪ {u}) − fi (A)) − fi ({u}) + 1 ≤ fi (A) + w(A) − 1. Similarly, to show that v ∈ / A, suppose for a contradiction that v ∈ A, and consider the set A \ {v}. Since fi (Ci ) − fi (Ci \ {v}) ≤ fi (A) − fi (A \ {v}), we have fi (A \ {v}) + w(A \ {v}) = (fi (A) + w(A)) − (fi (A) − fi (A \ {v})) − w(v) = (fi (A) + w(A)) − (fi (A) − fi (A \ {v})) + (fi (Ci ) − fi (Ci \ {v})) − 1 ≤ fi (A) + w(A) − 1. Therefore u ∈ A and v ∈ / A, and hence A ∈ argmin{fi (S) − xi (S) : u ∈ S, v ∈ / S}.  Whereas discrete and continuous algorithms require the same type of oracles, there is an important difference between the two algorithms in terms of exactness for the oracle solutions. The discrete algorithms require exact values of the auxiliary graph capacities c(u, v), as they must maintain xi ∈ B(fi ) throughout. Thus, the oracle must always return an optimal solution. The continuous algorithms are more robust, and return a solution with the required accuracy even if the oracle only returns an approximate solution. As discussed in Section 6, this difference leads to the continuous methods being applicable in settings where the combinatorial algorithms are prohibitively slow. Level-0 algorithms. We now discuss specific algorithms for quadratic minimization over the base polytopes of the functions fi . Several functions that arise in applications are “simple”, meaning that there is a 8 Table 1: Instance sizes image bee octopus penguin plant plane # pixels 273280 273280 154401 273280 154401 # edges 1089921 1089921 615200 1089921 615200 # squares 68160 68160 38400 68160 38400 # regions 50 49 50 50 50 min, 298 7 5 8 10 max, and average region size 299 298.02 299 237.306 299 279.02 298 275.22 299 291.48 Table 2: Minimum cut experiments image bee octopus penguin plant plane # iter = 5r 0.951421 0.937317 0.492372 0.943306 0.521685 # iter = 5r 1.3769 1.40884 0.757929 1.39893 0.766455 # functions (r) IBFS time (sec) 1363201 1.70942 1363201 1.09101 769601 0.684413 1363201 1.30977 769601 0.745521 UCDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 1.6234 13.4594 134.719 1.6279 13.9887 137.969 0.836147 7.1069 70.1742 1.63492 13.9559 137.865 0.850145 7.31664 71.8874 ACDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 2.2696 18.4351 182.069 2.33431 19.0471 188.887 1.24094 9.99443 98.5717 2.29446 18.6846 185.274 1.26081 10.1244 99.0298 function-specific quadratic minimization subroutine that is very efficient. If a function-specific subroutine is not available, one can use a general-purpose submodular minimization algorithm. The works [ABKM12, FJMPZ13] use a brute force search as the subroutine for each each fi , whose running time is 2|Ci | EOi . However, this is applicable only for small Ci ’s and is not suitable for our experiments where the maximum clique size is quite large. As a general-purpose algorithm, we used the Fujishige-Wolfe minimum norm 2 point algorithm [FI11, Wol76]. This provides an ε-approximate solution in O(|Ci |Fi,max /ε) iterations, with 4 2 2 overall running time bound O((|Ci | + |Ci | EOi )Fi,max /ε). [CJK14]. The experimental running time of the Fujishige-Wolfe algorithm can be prohibitively large [JLB11]. As we discuss in Section 6, by warmstarting the algorithm and performing only a small number of iterations, we were able to use the algorithm in conjunction with the gradient descent level-1 algorithms. 6 Experiments We evaluate the algorithms on energy minimization problems that arise in image segmentation problems. We follow the standard approach and model the image segmentation task of segmenting an object from the background as finding a minimum cost 0/1 labeling of the pixels. The total labeling cost is the sum of labeling costs corresponding to cliques, where a clique is a set of pixels. We refer to the labeling cost 9 Table 3: Small cliques experiments image bee octopus penguin plant plane # iter = 5r 4.14091 4.29358 2.16441 4.6404 2.182 # iter = 5r 5.24474 5.5891 2.95226 5.8395 2.95003 # functions (r) IBFS time (sec) 1431361 14.5125 1431361 12.9877 808001 7.58177 1431361 13.7403 808001 7.67518 RCDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 7.57959 66.0576 660.496 7.80816 68.5862 675.23 4.08777 37.8157 372.733 8.21702 69.059 672.753 4.12521 37.8602 373.825 ACDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 10.0951 98.7737 932.954 10.7124 99.4081 924.076 5.71215 52.9766 512.665 11.0806 102.023 900.979 5.70771 53.7524 486.294 Table 4: Large cliques experiments with potential specific quadratic minimization for the region potentials. In order to be able to run IBFS, we used smaller regions: 50 regions with an average size between 45 and 50. image bee octopus penguin plant plane # iter = 5r 4.29954 4.18879 2.132 4.55894 2.16248 # iter = 5r 5.34726 5.44726 2.90223 5.72946 2.89726 # functions (r) IBFS time (sec) 1431411 14.7271 1431411 12.698 808051 7.51067 1431411 13.6282 808051 7.64527 RCDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 7.87555 67.8876 664.816 7.61576 66.7 656.71 4.01926 36.9896 364.694 8.06429 67.72 659.685 4.0713 37.1917 366.272 ACDM time (sec) # iter = 10r # iter = 100r # iter = 1000r 10.3231 100.24 912.477 10.4446 96.2384 898.579 5.60117 51.9775 500.083 10.8512 99.6597 879.872 5.61102 52.5439 475.967 10 Table 5: Large cliques experiments with Fujishige-Wolfe quadratic minimization algorithm for the region potentials. The Fujishige-Wolfe algorithm was run for 10 iterations starting from the current gradient descent solution. The region sizes are given in Table 1. # iter = 5r 4.4422 4.30835 2.2724 4.61008 2.28484 # iter = 5r 5.29305 5.55511 2.95909 5.71402 2.9556 RCDM # iter = 10r 8.18077 7.86231 4.28243 8.20094 4.30316 ACDM # iter = 10r 10.2853 10.6411 5.74585 10.8467 5.73271 time (sec) # iter = 100r 69.0444 68.1428 38.1329 68.8351 38.0435 time (sec) # iter = 100r 103.452 97.955 54.3808 99.6515 54.0599 # iter = 1000r 674.526 665.57 366.549 660.469 366.825 # iter = 1000r 936.613 901.875 505.977 873.694 482.496 functions as clique potentials. The main focus of our experimental analysis is to compare the running times of the decomposable submodular minimization algorithms. Therefore we have chosen to use the simple hand-tuned potentials that were used in previous work [SAS16, ABKM12, SK10]: the edge-based costs defined by [ABKM12] and the count-based costs defined by [SK10]. Specifically, we used the following clique potentials in our experiments, all of which are submodular: • Unary potentials for each pixel. The unary potentials are derived from Gaussian Mixture Models of color features [RKB04]. • Pairwise potentials for each edge of the 8-neighbor grid graph. Each graph edge (i, j) between pixels i and j is assigned a weight that is a function of exp(−kvi − vj k2 ), where vi is the RGB color vector of pixel i. The clique potential for the edge is the cut function of the edge: the cost of a labeling is equal to zero if the two pixels have the same label and it is equal to the weight of the edge otherwise. • Square potentials for each 2 × 2 square of pixels. We view a 2 × 2 square as a graph on 4 nodes connected with 4 edges (two horizontal and two vertical edges). The cost of a labeling is the square root of the number of edges of the square that have different labels. This is the basic edge-based potential defined by [ABKM12]. • Region potentials for a set of regions of the image. We compute a set of regions of the image using the region growing algorithm suggested by [SK10]. For each region Ci , we define a count-based clique potential as in [SK10, SAS16]: for each set S ⊆ Ci of pixels, fi (S) = |S||Ci \ S|. We used five image segmentation instances to evaluate the algorithms3 . Table 1 provides the sizes of the resulting instances. The experiments were carried out on a single computer with a 3.3 GHz Intel Core i5 processor and 8 GB of memory. The reported times are averaged over 10 trials. Number of iterations for the coordinate methods. We have run the coordinate descent algorithms for 1000r iterations, where r is the number of functions in the decomposition. Our choice is based on the empirical results of Jegelka et al. [JBS13] that showed that this number of iterations suffices to obtain good results. Minimum cut experiments. We evaluated the algorithms on instances containing only the unary poten3 The data is available at http://melodi.ee.washington.edu/~jegelka/cc/index.html and http://research.microsoft.com/en-us/um/cambridge/projects/visionimagevideoediting/segmentation/grabcut.htm 11 tials and the pairwise potentials. Table 2 gives the running times in seconds. Small cliques experiments. We evaluated the algorithms on instances containing the unary potentials, the pairwise potentials, and the square potentials. Table 3 gives the running times in seconds. Large cliques experiments. We evaluated the algorithms on instances containing all of the potentials: the unary potentials, the pairwise potentials, the square potentials, and the region potentials. For the region potentials, we used a potential-specific level-0 algorithm that performs quadratic minimization over the base polytope in time O(|Ci | log(|Ci |) + |Ci |EOi ). Additionally, due to the slow running time of IBFS, we used smaller regions: 50 regions with an average size between 45 and 50. Large cliques experiments with Fujishige-Wolfe algorithm. We also ran a version of the large cliques experiments with the Fujishige-Wolfe algorithm as the level-0 algorithm for the region potentials. The Fujishige-Wolfe algorithm was significantly slower than the potential-specific quadratic minimization algorithm and in our experiments it was prohibitive to run the Fujishige-Wolfe algorithm to near-convergence. Since the IBFS algorithm requires almost exact quadratic minimization in order to compute exchange capacities, it was prohibitive to run the IBFS algorithm with the Fujishige-Wolfe algorithm. In contrast, the coordinate descent methods can potentially make progress even if the level-0 solution is far from being converged. In order to empirically evaluate this hypothesis, we made a simple but crucial change to the Fujishige-Wolfe algorithm: we warm-started the algorithm with the current solution. Recall that the coordinate descent algorithms maintain a solution xi ∈ B(fi ) for each function fi in the decomposition. We warm-started the Fujishige-Wolfe algorithm with the current solution xi , and we ran the algorithm for a small number of iterations. In our experiments, we ran the Fujishige-Wolfe algorithm for 10 iterations. These changes made the level-0 running time considerably smaller, which made it possible to run the level-1 coordinate descent algorithms for as many as 1000r iterations. At the same time, performing 10 iterations starting from the current solution seemed enough to provide an improvement over the current solution. Table 5 gives the running times. Conclusions. The combinatorial level-1 algorithms such as IBFS are exact and can be significantly faster than the gradient descent algorithms provided that the sizes of the cliques are fairly small. For instances with larger cliques, the combinatorial algorithms are no longer suitable if the only choice for the level-0 algorithms are generic methods such as the Fujishige-Wolfe algorithm. The experimental results suggest that in such cases, the coordinate descent methods together with a suitably modified Fujishige-Wolfe algorithm provides an approach for obtaining an approximate solution. 12 References [ABKM12] Chetan Arora, Subhashis Banerjee, Prem Kalra, and SN Maheshwari. Generic cuts: An efficient algorithm for optimal inference in higher order mrf-map. In European Conference on Computer Vision, pages 17–30. Springer, 2012. [Bac11] Francis Bach. Learning with submodular functions: A convex optimization perspective. ArXiv preprint arXiv:1111.6453, 2011. [CJK14] Deeparnab Chakrabarty, Prateek Jain, and Pravesh Kothari. Provable submodular minimization using Wolfe’s algorithm. In Advances in Neural Information Processing Systems, pages 802–809, 2014. [Edm70] Jack Edmonds. Submodular functions, matroids, and certain polyhedra. Combinatorial structures and their applications, pages 69–87, 1970. [EN15] A. R. Ene and H. L. Nguyen. Random coordinate descent methods for minimizing decomposable submodular functions. In Proceedings of the 32nd International Conference on Machine Learning (ICML), 2015. [FI03] Lisa Fleischer and Satoru Iwata. A push-relabel framework for submodular function minimization and applications to parametric optimization. Discrete Applied Mathematics, 131(2):311–322, 2003. [FI11] Satoru Fujishige and Shigueo Isotani. A submodular function minimization algorithm based on the minimum-norm base. Pacific Journal of Optimization, 7(1):3–17, 2011. [FJMPZ13] Alexander Fix, Thorsten Joachims, Sung Min Park, and Ramin Zabih. Structured learning of sum-of-submodular higher order energy functions. In Proceedings of the IEEE International Conference on Computer Vision, pages 3104–3111, 2013. [FR15] Olivier Fercoq and Peter Richtárik. Accelerated, parallel, and proximal coordinate descent. SIAM Journal on Optimization, 25(4):1997–2023, 2015. [Fuj80] Satoru Fujishige. Lexicographically optimal base of a polymatroid with respect to a weight vector. Mathematics of Operations Research, 5(2):186–196, 1980. [FWZ14] Alexander Fix, Chen Wang, and Ramin Zabih. A primal-dual algorithm for higher-order multilabel markov random fields. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 1138–1145, 2014. [FZ92] Satoru Fujishige and Xiaodong Zhang. New algorithms for the intersection problem of submodular systems. Japan Journal of Industrial and Applied Mathematics, 9(3):369, 1992. [GHK+ 11] Andrew V Goldberg, Sagi Hed, Haim Kaplan, Robert E Tarjan, and Renato F Werneck. Maximum flows by incremental breadth-first search. In European Symposium on Algorithms, pages 457–468. Springer, 2011. [GHK+ 15] Andrew V Goldberg, Sagi Hed, Haim Kaplan, Pushmeet Kohli, Robert E Tarjan, and Renato F Werneck. Faster and more dynamic maximum flow by incremental breadth-first search. In Algorithms-ESA 2015, pages 619–630. Springer, 2015. [GLS81] Martin Grötschel, László Lovász, and Alexander Schrijver. The ellipsoid method and its consequences in combinatorial optimization. Combinatorica, 1(2):169–197, 1981. [GT88] Andrew V Goldberg and Robert E Tarjan. A new approach to the maximum-flow problem. Journal of the ACM (JACM), 35(4):921–940, 1988. 13 [IFF01] Satoru Iwata, Lisa Fleischer, and Satoru Fujishige. A combinatorial strongly polynomial algorithm for minimizing submodular functions. Journal of the ACM (JACM), 48(4):761–777, 2001. [IO09] Satoru Iwata and James B Orlin. A simple combinatorial algorithm for submodular function minimization. In ACM-SIAM Symposium on Discrete Algorithms (SODA), 2009. [Iwa03] Satoru Iwata. A faster scaling algorithm for minimizing submodular functions. SIAM Journal on Computing, 32(4):833–840, 2003. [JB11] Stefanie Jegelka and Jeff A Bilmes. Online submodular minimization for combinatorial structures. In Proceedings of the 28th International Conference on Machine Learning (ICML-11), pages 345–352, 2011. [JBS13] Stefanie Jegelka, Francis Bach, and Suvrit Sra. Reflection methods for user-friendly submodular optimization. In Advances in Neural Information Processing Systems (NIPS), 2013. [JLB11] Stefanie Jegelka, Hui Lin, and Jeff A Bilmes. On fast approximate submodular minimization. In Advances in Neural Information Processing Systems, pages 460–468, 2011. [Kol12] Vladimir Kolmogorov. Minimizing a sum of submodular functions. Discrete Applied Mathematics, 160(15):2246–2258, 2012. [LSW15] Yin Tat Lee, Aaron Sidford, and Sam Chiu-wai Wong. A faster cutting plane method and its implications for combinatorial and convex optimization. In IEEE Foundations of Computer Science (FOCS), 2015. [Nes12] Yurii Nesterov. Efficiency of coordinate descent methods on huge-scale optimization problems. SIAM Journal on Optimization, 22(2):341–362, 2012. [NJJ14] Robert Nishihara, Stefanie Jegelka, and Michael I Jordan. On the convergence rate of decomposable submodular function minimization. In Advances in Neural Information Processing Systems (NIPS), pages 640–648, 2014. [Orl09] James B Orlin. A faster strongly polynomial time algorithm for submodular function minimization. Mathematical Programming, 118(2):237–251, 2009. [RKB04] Carsten Rother, Vladimir Kolmogorov, and Andrew Blake. Grabcut: Interactive foreground extraction using iterated graph cuts. ACM Transactions on Graphics (TOG), 23(3):309–314, 2004. [SAS16] Ishant Shanu, Chetan Arora, and Parag Singla. Min norm point algorithm for higher order mrf-map inference. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 5365–5374, 2016. [Sch00] Alexander Schrijver. A combinatorial algorithm minimizing submodular functions in strongly polynomial time. Journal of Combinatorial Theory, Series B, 80(2):346–355, 2000. [Sch03] A. Schrijver. Combinatorial optimization - Polyhedra and Efficiency. Springer, 2003. [SK10] Peter Stobbe and Andreas Krause. Efficient minimization of decomposable submodular functions. In Advances in Neural Information Processing Systems (NIPS), 2010. [Wol76] Philip Wolfe. Finding the nearest point in a polytope. Mathematical Programming, 11(1):128– 149, 1976. 14
8cs.DS
A Dictionary Approach to Identifying Transient RFI Daniel Czecha,∗, Amit Mishraa , Michael Inggsa arXiv:1711.08823v1 [astro-ph.IM] 23 Nov 2017 a Department of Electrical Engineering, University of Cape Town, Cape Town, South Africa Abstract As radio telescopes become more sensitive, the damaging effects of radio frequency interference (RFI) become more apparent. Near radio telescope arrays, RFI sources are often easily removed or replaced; the challenge lies in identifying them. Transient (impulsive) RFI is particularly difficult to identify. We propose a novel dictionary-based approach to transient RFI identification. RFI events are treated as sequences of sub-events, drawn from particular labelled classes. We demonstrate an automated method of extracting and labelling sub-events using a dataset of transient RFI. A dictionary of labels may be used in conjunction with hidden Markov models to identify the sources of RFI events reliably. We attain improved classification accuracy over traditional approaches such as SVMs or a naı̈ve kNN classifier. Finally, we investigate why transient RFI is difficult to classify. We show that cluster separation in the principal components domain is influenced by the mains supply phase for certain sources. Keywords: Transient radio frequency interference classification, hidden Markov models, kernel principal components analysis, density-based clustering, transient detection. 1. Introduction Radio frequency interference (RFI) presents an intensifying problem for radio astronomy. The reasons are two-fold: instruments are becoming significantly more sensitive, while new technologies require more spectrum as they ∗ Corresponding author Email address: [email protected] (Daniel Czech) Preprint submitted to Elsevier November 27, 2017 proliferate. In this paper, we aim to classify unintentional, transient RFI. Unintentional RFI is the release of RF energy as an unintended byproduct of the normal operation of some device or system. For example, relays, electric motors and fluorescent lights produce RF signals when switched on or off. It is difficult to identify the sources of this type of interference, since the signals are broadband, impulsive, and often extremely short. Furthermore, there is a risk of RFI being misidentified as real astronomical phenomena. In at least one case a transient RFI source was thought to be a potential astronomical source [1]. Certain astronomical observations are particularly vulnerable to impulsive RFI, such as those involving pulsars [2, 3]. In radio quiet reserves, different radio telescopes are often under construction in the close vicinity of others which are already beginning operations. In particular, the infrastructure and equipment attendant to the construction work have the potential to generate unintentional RFI. Therefore, it is important to have the ability to identify the sources of such RFI, so that they may be tracked down and removed or replaced (with shielded equipment, for example). There are few attempts to characterise or identify impulsive RFI in the literature. In work by Doran [4] for example, three attributes were used: time of day, intensity, and the telescope’s pointing direction. Another high-level approach was taken in other work [5], where different vehicles were classified according to their RF emissions when their engines were running. An artificial neural network was used to good effect; however, only five different vehicles were tested. In more recent work [6], a number of transient sources found at the MeerKAT radio telescope site were classified using Gaussian Mixture Models and k-Nearest Neighbours (kNN) classifiers with high classification accuracy. However, as the authors note, the recorded transients were limited in length as a result of hardware constraints. In our own prior work [7], we recorded a dataset of 9 typical sources of transient RFI and characterised them in statistical terms. We showed how components analysis techniques (specifically kernel principal components analysis) showed promise as a feature selection step and investigated class separability. We were also able to record for the full length of each RFI event. The problem of classifying transient signals is not limited to the radio spectrum. Several important classification tasks deal with acoustic transients, for example in speech processing [8], sonar target classification [9] and bio-acoustics [10]. The classification approach that we demonstrate in this paper requires signals to be segmented into individual transients. In one paper investigating the automated classification of cricket songs by species 2 [10], an algorithm for segmenting audio recordings into individual pulses is presented. The algorithm makes use of a dual-threshold approach, in which the signal energy must exceed two thresholds within a set time period for the onset of a pulse to be detected. Prior to classification, feature vectors are acquired using moving windows, measuring a variety of quantities such as pulse length and pulse frequency, among others. In our prior work [7] and in this paper, however, we use kernel principal components analysis (kernel PCA) [11, 12] as part of the feature selection step as all of these quantities are encoded in the resultant principal components. Kernel PCA, a nonlinear extension of PCA, is well established as a feature-selection step in classification problems [13, 14, 15]. In this paper, our classification approach deals with sequences of labelled transients. We consider transient RFI signals (or events), which consist of sequences of sub-transients, as analogous to spoken words, which consist of sequences of phonemes. Hidden Markov models (HMMs) [8] have proven highly successful at dealing with this type of classification problem in which sequences are constructed from a lexicon of building blocks. For example, in work by Hu, Lim and Brown [16], HMMs are used for handwriting recognition in this manner - HMMs are trained for individual characters built from a lexicon of sub-character strokes. In another example dealing with sign language recognition, different sub-unit types are used to train HMMs [17]. HMMs have also been used in conjunction with a dictionary composed of sub-units to classify whale songs [18]. In our previous paper [7], we showed that a time-domain approach is suitable for classifying the sources of unintentional, impulsive RFI events. In this paper we propose a new approach to the identification of these RFI events, inspired in part by speech processing techniques. Our current work contains several novelties. We propose a new way to identify RFI in the time-domain by considering each event as a sequence of transients drawn from a common dictionary. A tailored algorithm for developing such a dictionary is presented, and we illustrate how it may be used as a basis for source identification techniques. We show how events may be separated into individual transients, and how these transients may be labelled using unsupervised density-based clustering methods such as DBSCAN [19]. In keeping with our speech-processing inspired approach, we show how hidden Markov models may be used to identify the sources of new RFI events. As far as we are aware, this is the first time such a dictionary-based approach has been applied to the identification of impulsive RFI in the time3 domain, with the exception of our prior conference paper [20] in which we reported our initial ideas. This paper extends and completes the two main ideas we proposed in two prior conference papers [20, 21]. Furthermore, we believe this is the first time (aside from our prior conference paper [21]) that hidden Markov models have been used to identify RFI events in the timedomain, in an approach loosely inspired by speech processing techniques. We assess the performance of our technique by comparing its accuracy to naı̈ve kNN and support vector machine (SVM) classifiers. We use a rigorous method of testing, in which an unseen holdout set is kept completely separate from the training set which is used to train hyperparameters via cross-validation. Lastly, we show that the phase of the AC mains supply at the moment an RFI source is switched can influence clustering behaviour in the principal components domain. We illustrate how this affects cluster separability and hence potential classification accuracy. To our knowledge, this investigation has not been attempted before. The paper is organised as follows: In Section 2, we describe the dataset used and the limited preprocessing steps taken. We provide a motivation for the dictionary approach in Section 3 and describe how a dictionary of transients may be constructed. Section 3 also includes the algorithms for extracting individual transients from events and subsequently labelling them. In Section 4, we show how a dictionary of transients may be used to identify RFI events by using hidden Markov models, and how various parameters may be optimised. Additionally we report the classification accuracy attained and compare the results to more traditional, direct classification approaches. In Section 5, we show how the mains supply phase influences cluster separation in the principal components domain. Finally, conclusions are drawn in Section 6 and acknowledgments given in Section 7. 2. Data and Preprocessing Two datasets are used in this paper. The first consists of 944 individual time-domain recordings of 9 different sources of transient RFI. These sources are common representative devices that might be found near radio telescopes, especially those operating while others are under construction nearby. The devices are listed in Table 1. RFI events were captured using an FPGAbased Reconfigurable Open Architecture Computing Hardware (ROACH) board [22]. Further details on how this dataset was obtained, including a statistical analysis, are given in our previous work [7]. 4 Table 1: The sources of RFI used in this paper. Class No. events RFI Source 1 Compact fluorescent bulb 128 2 Power tool 135 3 Small step-down transformer 142 4 Cable 102 5 Mechanical relay (700W resistive load) 128 6 Mechanical relay (without load) 141 7 AC motor (≈ 1 kW) 63 8 Small switching power supply unit 105 Two of the sources are very similar, each being a different compact fluorescent lamp (CFL). In the clustering approach taken in our prior paper [7] they were the least separable of all the sources. We amalgamated these two together to form a single CFL class, reasoning that most of the value lies in detecting that a particular source is a CFL. Knowing the brand is of less importance. Additionally, we limited each full RFI event to 950 000 samples, or around 593 µs, as virtually all of the activity across events took place within this time. If we had included more samples we would have increased the computational overhead of our analyses unnecessarily, since the additional samples are almost entirely devoid of signal. One further step we took was to normalise event amplitude by class. For each recording r in the where µ and σ set of recordings R of a particular source, rnormalised = r−µ σ are the mean and standard deviation respectively of all r ∈ R. A second, smaller set of recordings of three of the sources was collected under lab conditions to test the hypothesis that certain underlying physical characteristics account for variations within clusters of events (dealt with in Section 5). 700 time-domain recordings were taken of the switching signals of three different transient RFI sources. Signal capturing was handled with an Agilent MSO9104A mixed signal oscilloscope and a folded dipole antenna with a center frequency of 146 MHz. To avoid aliasing effects, a low-pass 5 filter was used and the sampling rate was set at 2 GS/s. Each capture was 2 × 106 samples long. Further details are given in Section 5. 3. Dictionary Creation In this section, we describe the process of creating a dictionary of transients from which full RFI events may be represented. In our dictionary approach, we propose that full transient RFI events, which consist of sequences of transients, are analogous to spoken words, which consist of sequences of phonemes. We motivate for this approach by making several observations. Firstly, these types of unintentional transient RFI events do tend to consist of sequences of transients. In Fig. 1 several examples are given. Secondly, as with spoken words, there are small variations in repeated events from the same source. Each time a word is spoken, it might sound slightly different, or have a slightly altered sequence of phonemes, but the underlying meaning remains the same. In Fig. 1, it is apparent that for a particular RFI source, there are small variations from one recording to the next. However, the underlying structural similarities remain recognisable. Considering RFI events as sequences of transients drawn from a canonical dictionary allows us to use powerful techniques such as hidden Markov models to identify their sources (as we proposed in our prior conference paper [21]). Furthermore, if this concept of a dictionary is successful, we would expect that RFI events from different sources share at least some of the same labels amongst them. This is the case: in our conference paper [20] we showed this for a limited dataset, and in Section 3.3 of this paper, we extend this finding to the full dataset used in this work. 3.1. Automated Transient Extraction As each full event generally contains numerous individual transients, the total quantity extracted from the dataset numbers in the thousands. We deemed it impractical to extract a such a large number of transients by hand, instead developing an automated extraction algorithm and tuning it with a smaller, representative set of hand-selected transients. In this section, we document the approach we developed, although there are surely alternative methods of automatically extracting such transients. We provide the pseudocode in Algorithm 1. 6 Mechanical Relay 200 CFL 0 mV −200 200 0 −200 200 0 −200 0 50 100 150 μμ 200 250 300 0 50 100 μμ 150 200 Figure 1: Examples of RFI events caused by switching a mechanical relay (with a resistive load) and a CFL. There is a common underlying structure to the events in each class, although variations exist between them. 3.1.1. Extraction Algorithm The basic procedure is as follows. Firstly, the Hilbert transform is applied to the raw time-domain recording to extract its approximate envelope. The absolute value of the resultant envelope is smoothed a small amount by convolving it with L1 , a moving window. L1 is determined empirically; see Section 3.1.2. A static threshold is applied, set at F1 = 1.5% of the maximum range of values in the signal. In this first pass over the signal, a very lenient threshold is permissible, since a stricter threshold is applied later. This minimises the number of transients that are missed while ensuring individual transients are separated from one another. Where this threshold is breached, these regions are selected for further investigation. Regions closer together than TM samples (determined in Section 3.1.2) are merged and those shorter than TM samples are discarded. For each of the regions selected for further investigation, additional steps are taken to ensure that multiple transients close to one another are not merged together. This procedure is illustrated in Fig. 2. Firstly, a scaled median filter is applied to the smoothed region extracted previously. The result is an adaptive threshold (T2 ) that allows us to separate transients 7 that are close together. We used a window length of 8000 samples, although the exact value is not critical, so long as it is kept a few times larger than L1 . Subregions are selected where the parent region exceeds this adaptive threshold. In Fig. 2 these subregions are labelled as ‘Selected regions (strict threshold)’. If there are significant gaps between these subregions, a subdivision is made at the midpoints between them. Finally, segments of the raw time-domain signal (labelled 2.1 and 2.2 in Fig. 2) are extracted according to these subdivisions. Algorithm 1 Transient Extraction Input: an RFI event, e(t) Output: Transients extracted from e(t) eH (t) ← |H(eH )(t)| esmth (t) ← eH (t) ∗ L11 × ones(L1 ) emask (t) ←where esmth (t) > F1 × (max(esmth (t)) − min(esmth (t))) + min(esmth (t)) for each region ri in emask (t) do while ri closer than TM samples to ri+1 do ri ←merge ri and ri+1 end while if length ri < TM then delete ri end if end for for each region ri in emask (t) do esmthi (t) ← region ri in esmth (t) T2 (t) ← scaled moving median filter applied to esmthi (t) emaski (t) ←where esmthi (t) > T2 (t) for each sub-region sj in emaski (t) do rf inal ← subdivide ri at midpoints between sj and sj+1 transientj (t) ← rf inal in original event signal e(t) return transientj (t) end for end for 8 Figure 2: The extraction procedure. A threshold is applied to the smoothed absolute value of the signal’s envelope in (a) and (b). In the first pass a lenient threshold is applied, ensuring that all transients are captured. However, such a lenient threshold often results in merged transients, as is the case in Region 2. To avoid this, a second pass with a stricter adaptive threshold is applied to the regions identified in the first pass, as shown in (b). The original regions are then subdivided at the midpoints between subregions resulting from the stricter threshold. 3.1.2. Parameter Selection The extraction accuracy of the algorithm given in Section 3.1.1 is influenced by several parameters. To optimise them, the accuracy of the extraction algorithm was tested by applying it to a set of transients that were selected by a human. Three metrics were used to assess the performance of the extraction algorithm. 9 1. The fraction of all ground truth transients that were extracted. A transient is considered extracted if > 60% of its samples (in the manually selected ground truth) are assigned by the extraction algorithm to any transient. 2. The fraction of false extractions. An extracted transient is considered falsely extracted if < 30% of its samples belong to a ground truth transient. 3. The fraction of all transients which have been incorrectly merged together by the extraction algorithm. In Fig. 3, the extraction results are shown for different values of the two most important parameters, L1 and TM . As can be seen in the plots, there are a wide variety of suitable values of L1 and TM that offer good results. For the purposes of this investigation, we selected L1 = 640 samples and TM = 1540 samples. Using these values, the extraction accuracy is 93.4%, the erroneous merging rate 2.6% and the false extraction rate 2.2%. 3.2. Feature Extraction Prior to labelling the transients through unsupervised clustering techniques, we applied a feature selection step to reduce the computational burden. A typical choice might be Principal Components Analysis (PCA). In our previous work [7], we analysed entire RFI events (consisting of multiple transients) and showed that across sample locations, their distributions were non-Gaussian. This led us to conclude that non-linear components analysis techniques such as kernel PCA [11, 12] would fare better than standard PCA (which assumes a Gaussian distribution). Furthermore, we showed that a Gaussian radial basis function is a reasonable choice of kernel function. We can apply these findings to the transients extracted here, since these transients are extracted from the same RFI events studied in our previous paper. Accordingly, we apply kernel PCA to the transients as a feature selection stage, using the following kernel function: k(x, y) = e−γkx−yk 2 1 We set γ = no. samples and select the top components (excepting the first 3) that accounted for 65% of the variance. In addition, prior to unsupervised clustering, we scale each of these components by its relative contribution (within the subset) to the variance in the data. C is the set of m components of dimension n, and λ is the set of m eigenvalues corresponding to the 10 Figure 3: Evaluation results for automated transient extraction. In (i), the fraction of all transients that were correctly extracted for different values of M1 and L1 is given. (ii) shows the number of false extractions as a fraction of the total number of actual transients, a value that can exceed 1. Plot (iii) shows the fraction of all transients that were incorrectly merged together. The final plot indicates how the values of the two parameters were chosen. We set requirements that > 90% of all transients should be extracted, while ensuring that < 5% of all extracted transients are falsely extracted and < 5% of all extracted transients are incorrectly merged. Regions (a), (b) and (c) each fail to satisfy one or more of these criteria, while region (d) satisfies them all. We selected L1 = 640 samples and a M1 = 1540 samples, for an extraction accuracy of 93.4%, an erroneous merging rate of 2.6% and a false extraction rate of 2.2%. The star indicates where these results are satisfied. components in C. The components in C are sorted by descending eigenvalue. If C 0 is the set of scaled components, then for each component Ci ∈ C: Ci0 = Ci × λi − min(λ) max(λ) − min(λ) 11 3.3. Transient Labelling Once kernel PCA has been applied, the transients need to be labelled. Of the range of unsupervised clustering methods available, we initially looked at k-means. We quickly realised that density-based methods such as DBSCAN [19] would be preferable, however. In the principal components domain, dense, often elongated clusters of points appear within other regions that are relatively sparsely populated with points. As a result the limitations of k-means become quickly apparent - visibly separable clusters are often joined or cut in half depending on the initial conditions of the k-means algorithm. One important disadvantage of DBSCAN is that it struggles to account for variations in cluster density. In the principal components domain, the transients clearly group together in clusters of varying density. As a result, points that belong to sparse (but nevertheless, distinct) clusters are often labelled as noise. There are several variations of DBSCAN that attempt to account for varying cluster density [23, 24] as well as other techniques that use density ratios, for example [25]. We opted to implement a simpler approach in which DBSCAN is performed in a recursive manner. DBSCAN is first applied with parameters tuned for dense clusters. Thereafter it is applied again, this time only on points that were labelled as noise, with parameters favouring sparser clusters. We discuss how we selected these parameters in Section 4.3. Fig. 4 provides a visualisation of our recursive application of DBSCAN to the data, showing 3 of the 92 principal components. We also provide three examples of transients belonging to three of the different clusters. If these labels generate a good universal dictionary, we would expect the most important of them to correspond with transients drawn from a wide variety of sources. In other words, we would expect labels to be shared amongst events from different sources. In Table 2, we show how three of the most prevalent labels (out of 53 in this example) are distributed amongst the 8 classes in this paper. As expected, they account for a large proportion of the transients drawn from each class, and are widely shared amongst classes. 4. RFI Source Identification In this section, we describe how RFI events may be identified using hidden Markov models, based on the labelled dictionary of transients. We also compare the classification accuracy of this dictionary-based approach to two 12 Figure 4: An example of the results of unsupervised clustering to label transients. Each marker represents a particular transient, while the colour and shape of each marker represents the particular label it has been allocated. Note that for legibility we do not show points labelled as noise in this explanatory plot. In addition only 3 particular components are shown here, while the clustering itself was carried out using 92 components. As a result, some clusters which appear to overlap are in fact well-separated in higher dimensions. Three examples of different transient types corresponding to particular labels are given on the right-hand side of the figure. The amplitude of the transients is in arbitrary units, since they are displayed after preprocessing. other classic methods, a k-Nearest Neighbours (kNN) classifier and an SVM classifier. 4.1. Sequence Reconstruction and New Events Now that a dictionary has been constructed, each full RFI event may be represented as a sequence of labelled transients. A full RFI event is given as a sequence of numbers, each number representing the label assigned to a transient in the sequence of transients that together make up the event. An example is given in Fig. 5. New events, those that are not part of a training set from which a dictionary is constructed, are converted to sequences as follows: Firstly, a new raw RFI event is divided into its individual transients using the extraction approach described in Section 3.1. These extracted transients are then represented in the principal components space by projecting them onto the principal components extracted previously from the transients in the training data. They are then assigned labels based on the clusters obtained via the pre-constructed dictionary. Specifically, a new point 13 % of in-class transients Label 1 Label 2 Label 3 power tool 27.83 33.36 4.65 transformer 31.26 2.68 7.72 cable 21.66 57.49 7.77 relay (load) 27.48 7.62 0.25 relay 27.69 25.82 0.0 AC motor 27.91 42.55 1.08 CFL 33.11 13.33 12.80 PSU 27.79 25.81 11.79 Source Table 2: The distribution of three of the most important labels amongst the 8 classes. A large proportion of the transients within each class correspond with labels widely shared amongst the 8 classes, supporting the concept of a canonical dictionary as proposed here and in our previous conference paper [20]. is assigned the label belonging to the most prevalent class in the k-nearest training points. Finally, the new event is represented as a sequence of labels, as with the training data. 4.2. Source Identification Using Hidden Markov Models Given our approach in which RFI events are analogous to spoken words, and individual transients are analogous to phonemes, HMMs are a natural choice for identification purposes. They are a proven approach to classifying non-stationary and piecewise stationary signals in many fields, such as speech processing [8, 26] and financial time-series [27]. Their robustness to variations in repeated examples of the same signal is responsible for much of their success in speech processing. As discussed in Section 3, the full RFI events, when considered as sequences of transients, exhibit such variations in repeated examples from the same source. In addition (as noted in Section 1) HMMs are well suited to classification problems involving sequences of sub-units [16, 17]. In our case, the sub-units are labelled transients. We 14 Figure 5: An example of a full RFI event represented as a sequence of labels. Each of the transients is labelled as described in Section 3.3 or 4.1 depending on whether the RFI event is used in training or testing. The RFI event is then represented as a sequence of these labels: [4, 4, 4, 6, 7] for example. Units of amplitude are not given since this particular example is displayed after preprocessing. omit the theory of HMMs here for conciseness. For an excellent explanation of the basic theory of HMMs, please consult the paper by Rabiner [8]. In Section 4.1 we described how each full RFI event is represented as a sequence of labels. The sequences reconstructed from events in each randomised training set are used to train an HMM for each different class, using the Expectation-Modification method [8]. When a new event (from a test set) is to be classified, a likelihood figure of merit is calculated from the log probability for each of the different models, using the Viterbi algorithm [8]. The new event is then assigned the class of the model for which the highest likelihood figure of merit is calculated. The optimal number of hidden states, n, is determined empirically as a hyperparameter (see Section 4.3). We used the software package hmmlearn [28] to train and apply unconstrained HMMs with Gaussian emission probabilities. 4.3. Parameter Tuning and Classification Performance Prior to hyperparameter tuning and performance evaluation, the data were divided into 5 randomised sets of approximately 189 examples each. These sets were stratified, in that as near as possible, 15 of the examples from each class were included in each of the 5 sets. One of these sets was then set aside as a hold-out testing set, never to be used in hyperparam15 eter tuning or model training. The remaining four were combined in four different train/development pairs and used in four-fold cross-validation to tune hyperparameters. Each fold was made up of approximately 566 training examples, and 189 validation samples. Due to the large search space, a series of parametric searches were conducted to determine good values for the various hyperparameters. These parameters included the number of neighbouring points, k, to use when assigning class labels to new transients (see Section 4.1); the number of hidden states to use when training the hidden Markov models, and the two minpts and two eps parameters for each application of DBSCAN. We present the optimal values in Table 3. Our final accuracy result was obtained by using all four cross-validation sets together as a training set, and testing on the hitherto completely unseen testing set. Table 3: Classification results and associated parameters. The test accuracy is the classification accuracy on the unseen test-set, while the training accuracy is the average accuracy of four-fold cross-validation applied to the training set. % acc. % acc. min(test) (train) pts1 minpts2 eps1 69.47 10 0.0745 0.0792 11 65.54 40 eps2 k No. hidden states 33 Surprisingly, our unseen test result exceeded the best average score we were able to obtain using four-fold cross-validation on the training set. We attribute this to the 25% increase in training examples when training the final dictionary. During cross-validation, only 60% of the data were available at any one time for training, whereas when training the final dictionary, we could use the full cross-validation set consisting of 80% of the data. In Table 4, we display a confusion matrix, showing exactly how the test set data were classified. The best result, correctly classified 93.1% of the time, was for the small step-down transformer. The worst was for the AC motor, classified correctly only 38.5% of the time, and misclassified as a power tool and a power supply unit 23.1% of the time each. Misclassification as a power tool is not necessarily bad, however, as the power tool contains a smaller AC motor of a similar type. Another way to evaluate the dictionary-based classification approach is to compare its performance with that of other, well known methods. For the comparison we conduct here, we use the same cross-validation sets and 16 power tool transformer cable relay (load) relay AC motor CFL PSU Table 4: This table displays the classification results for the unseen test set. An overall accuracy of 69.47% was obtained. Each row shows as a percentage how the examples belonging to a particular class were classified. In the perfect case, each of the bold values along the diagonal would be 100%, indicating that each source was correctly classified 100% of the time. power tool 51.9 11.1 7.4 0.0 22.2 3.7 0.0 3.7 transformer 0.0 93.1 0.0 0.0 3.4 0.0 3.4 0.0 cable 0.0 0.0 80.0 5.0 10.0 5.0 0.0 0.0 relay (load) 0.0 0.0 3.8 69.2 7.7 15.4 0.0 3.8 relay 0.0 3.6 25.0 0.0 71.4 0.0 0.0 0.0 AC motor 23.1 7.7 0.0 0.0 0.0 38.5 7.7 23.1 CFL 0.0 0.0 11.5 0.0 11.5 0.0 73.1 3.8 PSU 4.8 4.8 4.8 0.0 14.3 0.0 9.5 61.9 17 separate unseen holdout set as before. In this case, we do not extract the transients that make up each full event; rather we consider each full event to be one training/development/testing example. Before applying the different classification methods, we use kernel PCA for dimensionality reduction (see our previous work [7]), selecting the top components that together explain 80% of the variance in each cross-validation training set. Following this step, we tested two basic methods, SVMs and a kNN classifier. In the case of the kNN classifier, we optimised k using the same cross-validation approach as before. As shown in Table 5, the dictionary-based approach to identifying these RFI events in conjunction with HMMs significantly outperforms these basic methods. Table 5: Comparison of the dictionary method and other basic methods. A linear SVM (rather than kernel-based SVMs) performed best after kernel PCA had been applied to the data. The best result for the kNN classifier was obtained for k = 1. Classification method Dictionary approach and HMMs Overall accu69.47 racy [%] Direct approach Direct approach and SVM classi- and kNN classifier fier 58.42 52.11 5. The Difficult Nature of Classifying Transient RFI It is clear that classifying unintentional transient RFI is a difficult task. As we have shown, a traditional approach with SVMs or kNN-based classifiers (along with a kernel PCA feature reduction step) yields poor results. Unravelling the reasons responsible for this will aid the development of future identification algorithms. During our investigations, we began to suspect that the mains supply voltage phase had an effect on cluster shapes in the principal components space. That is, the shape and density of a cluster belonging to a specific device is related to the supply phase at the instant the device is switched. It is already known that the supply voltage affects the generation of impulsive RFI from certain sources - for example, in one paper [29] it is shown that impulsive RFI generated by a defective thermostat exhibits a high correlation with the positive and negative peaks of the supply 18 RFI Source Oscilloscope Ch 1 Vsupply Antenna Ch 2 Isolating Transformer LPF Figure 6: The experiment to record RFI events and the mains supply voltage simultaneously. voltage. However, to our knowledge, the effects of supply phase on clusters of events in the principal components domain have not yet been investigated. We set up an experiment in which three of the RFI sources were switched between 200 and 300 times each and the corresponding transient RFI signals recorded. Simultaneously, the instantaneous mains supply voltage was recorded at the moment each device was switched. We used a folded dipole antenna with a center frequency of 146 MHz, identical to the one used in our previous paper [7]. Both the RF signal and mains supply measurement were handled with an Agilent MSO9104A mixed signal oscilloscope to ensure simultaneous captures. A low-pass filter was used for anti-aliasing purposes. In Fig. 6, we provide a diagram of the experiment. In Fig. 7, we show how the clusters of RFI transients generated by each different device change according to the instantaneous voltage of the AC supply voltage. Kernel PCA is applied to the data in a direct approach as described in Section 4.3 and our previous paper [7]. In the case of the mechanical relay and the switching PSU, there is clearly a relationship between the spread of the data points and the instantaneous supply voltage. This relationship has important implications for the classification of sources. In Fig. 8, we apply kernel PCA to the data from both the PSU and the relay. Visualised in 2D, overlap between the two clusters is apparent. However, this overlap is dependent on the instantaneous supply voltage at the time of switching. We can evaluate cluster separation for different supply voltages 19 Relay PSU 0.04 0.2 −0.1 −0.2 0.00 −0.3 −0.02 −0.2 −0.3 −0.1 PC 2 PC 4 PC 2 0.0 −0.4 −0.5 −0.04 −0.2 0.0 PC 1 0.2 0.4 |V| = Vpeak 0.0 0.02 0.1 Transformer 0.1 −0.1 0.0 PC 3 0.1 −0.6 −0.2 0.0 PC 1 0.2 Figure 7: Kernel PCA applied separately to the RFI events from three different sources. Each marker represents a single RFI event, while the colour of the marker indicates the absolute instantaneous mains supply voltage. In the case of the power supply and the relay, there is a visible correspondence between clustering behaviour and the mains supply voltage. using the mean silhouette coefficient [30]. The silhouette coefficient for a single example is given as follows: s= b−a max(a, b) Here, a is the average distance from the sample in question to each sample in its own cluster, and b is the average distance to each point in the nearest cluster of a different class. The silhouette coefficient indicates how wellseparated a point is from clusters other than its own and how well-suited it is to its own cluster. A silhouette coefficient near −1 indicates overlap and poorly formed clusters, while a coefficient near 1 indicates that the points belong to appropriate, well-separated clusters. If only the data recorded for |V | > 0.6Vpeak are included, then the silhouette coefficient improves; this is visually apparent in the top two principal components. Conversely, if the data are restricted to those recorded when |V | < 0.4Vpeak , then the silhouette score drops. Therefore, for at least some sources of transient RFI, classification accuracy is affected by the mains supply voltage at the moment of switching. By accounting for the mains supply phase, it may be possible to create better classifiers for certain sources of RFI. For example, measures of classification confidence could be increased for certain ranges of the mains supply phase. 20 |V| = 0 Figure 8: Kernel PCA applied to the RFI events from the relay and the power supply. Each marker represents a particular RFI event; the shape of the marker indicates its source. The colour of each marker indicates the absolute instantaneous mains supply voltage. A separate colour bar is included for each source to aid legibility. In (i), no restriction is placed on |V |; using the top 10 principal components, a silhouette score of 0.24 is obtained. If |V | is restricted to < 0.4Vpeak , shown in (ii), then cluster overlap increases and the silhouette score drops to 0.07. If |V | is restricted to > 0.6Vpeak , shown in (iii), cluster overlap is reduced and the silhouette score increases to 0.33. 6. Conclusion We have developed a novel, effective approach to classifying and identifying impulsive RFI events according to their sources in the time domain. A useful analogy may be drawn between these RFI events, which consist of sequences of transients, and spoken words, which consist of sequences of phonemes. We demonstrate how a dictionary of labelled transients may be constructed from which any full RFI event may be represented as a sequence of labels. In addition, we present an automated algorithm for reliably extracting individual transients from recordings of full RFI events. We show how a dictionary built in this manner may be used to identify the sources of transient RFI using hidden Markov models, in an approach loosely inspired by speech processing. This approach yields better accuracy than other well established, more direct methods when applied to an existing dataset of transient RFI. Furthermore, we show that the mains supply phase at the instant an RFI source is triggered can have a direct influence on the shape of its clusters in the principal components domain. We illustrate the implications of this effect on cluster separability, providing some insight into the difficulty of accurately identifying sources of transient RFI. In future, we expect the dictionary approach to provide a useful first step prior to the application of various different identification algorithms, in addition to hidden Markov models. 21 7. Acknowledgments The financial assistance of the South African SKA project (SKA SA) is hereby acknowledged. Opinions expressed and conclusions arrived at are those of the author and are not necessarily to be attributed to the SKA SA (www.ska.ac.za). Computations were performed using facilities provided by the University of Cape Town’s ICTS High Performance Computing team: http://hpc.uct.ac.za References [1] E. Petroff, E. Keane, E. Barr, J. Reynolds, J. Sarkissian, P. Edwards, J. Stevens, C. Brem, A. Jameson, S. Burke-Spolaor, et al., Identifying the source of perytons at the Parkes radio telescope, Monthly Notices of the Royal Astronomical Society 451 (4) (2015) 3933–3940. [2] M. A. McLaughlin, J. M. Cordes, Searches for giant pulses from extragalactic pulsars, The Astrophysical Journal 596 (2) (2003) 982. [3] J. M. Cordes, N. D. R. Bhat, T. H. Hankins, M. A. McLaughlin, J. Kern, The brightest pulses in the universe: Multifrequency observations of the Crab pulsar’s giant pulses, The Astrophysical Journal 612 (1) (2004) 375. [4] G. Doran, Characterizing interference in radio astronomy observations through active and unsupervised learning. [5] X. Dong, H. Weng, D. G. Beetner, T. H. Hubing, D. C. Wunsch, M. Noll, H. Gksu, B. Moss, et al., Detection and identification of vehicles based on their unintended electromagnetic emissions, IEEE Transactions on Electromagnetic Compatibility 48 (4) (2006) 752–759. [6] C. J. Wolfaardt, D. Davidson, T. Niesler, Statistical classification of radio frequency interference (RFI) in a radio astronomy environment, in: Pattern Recognition Association of South Africa and Robotics and Mechatronics International Conference (PRASA-RobMech), 2016, IEEE, 2016, pp. 1–5. [7] D. Czech, A. Mishra, M. Inggs, Characterizing transient radio-frequency interference, Radio Science 52 (7) (2017) 841–851. 22 [8] L. R. Rabiner, A tutorial on hidden Markov models and selected applications in speech recognition, Proceedings of the IEEE 77 (2) (1989) 257–286. [9] B. Barshan, B. Ayrulu, Fuzzy clustering and enumeration of target type based on sonar returns, Pattern Recognition 37 (2) (2004) 189–199. [10] C. Dietrich, G. Palm, K. Riede, F. Schwenker, Classification of bioacoustic time series based on the combination of global and local decisions, Pattern Recognition 37 (12) (2004) 2293–2305. [11] B. Schölkopf, A. Smola, K.-R. Müller, Kernel principal component analysis, in: Artificial Neural Networks–ICANN’97, Springer, 1997, pp. 583– 588. [12] C. M. Bishop, Pattern Recognition and Machine Learning, Springer, New York, NY, USA, 2006. [13] C. H. Park, H. Park, Nonlinear feature extraction based on centroids and kernel functions, Pattern Recognition 37 (4) (2004) 801–810. [14] J. Yang, A. F. Frangi, J.-y. Yang, D. Zhang, Z. Jin, KPCA plus LDA: a complete kernel fisher discriminant framework for feature extraction and recognition, IEEE Transactions on Pattern Analysis and Machine Intelligence 27 (2) (2005) 230–244. [15] H. Hoffmann, Kernel PCA for novelty detection, Pattern Recognition 40 (3) (2007) 863–874. [16] J. Hu, S. G. Lim, M. K. Brown, Writer independent on-line handwriting recognition using an HMM approach, Pattern Recognition 33 (1) (2000) 133 – 147. [17] H. Cooper, E.-J. Ong, N. Pugeault, R. Bowden, Sign language recognition using sub-units, Journal of Machine Learning Research 13 (Jul) (2012) 2205–2231. [18] F. Pace, Automated classification of humpback whale (megaptera novaeangliae) songs using hidden Markov models, Ph.D. thesis, University of Southampton (2013). 23 [19] M. Ester, H.-P. Kriegel, J. Sander, X. Xu, et al., A density-based algorithm for discovering clusters in large spatial databases with noise., in: Kdd, Vol. 96, 1996, pp. 226–231. [20] D. Czech, A. K. Mishra, M. Inggs, A canonical interferencelet-based approach to RFI identification, in: Radio Frequency Interference (RFI), IEEE, 2016, pp. 16–20. [21] D. Czech, A. K. Mishra, M. Inggs, Identifying radio frequency interference with hidden Markov models, in: Radio Frequency Interference (RFI), IEEE, 2016, pp. 21–25. [22] ROACH, Collaboration for Astronomy Signal Processing and Electronics Research, [Online]. Available: https://casper.berkeley.edu/wiki/ROACH, [Accessed: 2016-09-27] (2013). [23] M. Ankerst, M. M. Breunig, H.-P. Kriegel, J. Sander, OPTICS: ordering points to identify the clustering structure, in: ACM Sigmod record, Vol. 28, ACM, 1999, pp. 49–60. [24] R. J. Campello, D. Moulavi, J. Sander, Density-based clustering based on hierarchical density estimates, in: Pacific-Asia Conference on Knowledge Discovery and Data Mining, Springer, 2013, pp. 160–172. [25] Y. Zhu, K. M. Ting, M. J. Carman, Density-ratio based clustering for discovering clusters with varying densities, Pattern Recognition 60 (2016) 983–997. [26] B. H. Juang, L. R. Rabiner, Hidden Markov models for speech recognition, Technometrics 33 (3) (1991) 251–272. [27] B. Knab, A. Schliep, B. Steckemetz, B. Wichern, Model-based clustering with Hidden Markov Models and its application to financial time-series data, in: Between Data Science and Applied Data Analysis, Springer, 2003, pp. 561–569. [28] R. Weiss, S. Du, J. Grobler, S. Lebedev, G. Varoquaux, hmmlearn 0.2.1, [Online]. Available: https://github.com/hmmlearn/hmmlearn, [Accessed: 2017-11-08] (2017). 24 [29] I. E. Portugues, P. J. Moore, I. A. Glover, R. J. Watson, A portable wideband impulsive noise location system, IEEE Transactions on Instrumentation and Measurement 57 (9) (2008) 2059–2066. [30] P. J. Rousseeuw, Silhouettes: a graphical aid to the interpretation and validation of cluster analysis, Journal of computational and applied mathematics 20 (1987) 53–65. 25
1cs.CV
Efficient decoding of random errors for quantum expander codes arXiv:1711.08351v2 [quant-ph] 25 Mar 2018 Omar Fawzi∗ Antoine Grospellier† Anthony Leverrier† Abstract We show that quantum expander codes, a constant-rate family of quantum LDPC codes, with the quasi-linear time decoding algorithm of Leverrier, Tillich and Zémor can correct a constant fraction of random errors with very high probability. This is the first construction of a constant-rate quantum LDPC code with an efficient decoding algorithm that can correct a linear number of random errors with a negligible failure probability. Finding codes with these properties is also motivated by Gottesman’s construction of fault tolerant schemes with constant space overhead. In order to obtain this result, we study a notion of α-percolation: for a random subset E of vertices of a given graph, we consider the size of the largest connected α-subset of E, where X is an α-subset of E if |X ∩ E| ≥ α|X|. 1 Introduction A major goal of quantum information research is to build a large quantum computer that would exploit the laws of quantum mechanics to solve problems out of reach for classical computers. Perhaps the main difficulty of this program lies with the fragility of quantum information. While classical information can easily be stored and manipulated without error, this is not the case of quantum information which will tend to decohere quickly as soon as it interacts with the environment. Finding the right balance between protecting the qubits from decoherence and allowing them to be accessed in order to perform a computation turned out to be an extremely challenging task. A natural solution to protect quantum information is to encode the logical qubits into a larger set of physical qubits thanks to quantum error correction techniques. Classically, good error correcting codes that feature a constant encoding rate, a minimal distance linear in their length and efficient decoding algorithms exist; this is for instance the case of low-density parity-check (LDPC) codes [24]. The situation for quantum codes is direr. Here, the LDPC condition is particularly appealing for implementation, but finding good quantum LDPC codes has proven difficult. The canonical quantum LDPC code is the toric code due to Kitaev [18], which is indeed local since only involving 4-body correlations and can be decoded efficiently thanks to Edmonds algorithm for minimum weight perfect matching [8] (or more recently [5]). Unfortunately, the toric code as well as its surface code generalizations display a zero rate, in the sense that the ratio between encoded and physical qubits tends to zero when the code size tends to infinity. The minimum distance of the toric code, on the other hand, is quite good and grows as Θ(n1/2 ) for a code of length n. This is essentially the best available value for LDPC codes since the current record is ∗ ENS de Lyon, UMR 5668 LIP - CNRS - UCBL - INRIA - Université de Lyon, 69364 Lyon, France. [email protected] † Inria, SECRET Project, 2 Rue Simone Iff, 75012 Paris Cedex, France. [email protected], [email protected] 1 Ω(n1/2 log1/4 n) due to Freedman, Meyer and Luo [10] and it is a fascinating theoretical open question to construct quantum LDPC codes with minimum distance Ω(n1/2+ǫ ) for some constant ǫ > 0. However, even if for the toric code and its generalizations there exist errors of weight √ O( n) that cannot be corrected, it turns out that there are efficient decoding algorithms that can, with high probability, correct random errors on a linear number of qubits provided the error rate is below some threshold [8]. In this paper, we ask the following natural question: are there quantum LDPC codes with efficient decoding algorithms that display constant rate and can correct a linear number of random errors with very high probability? This question is also motivated by reducing the space overhead for fault-tolerant quantum computation. One of the crowning theoretical achievements in the field of quantum computation is the threshold theorem [2] which shows that an arbitrarily long computation can be performed with an imperfect implementation (noisy qubits, imperfect gates), provided that the noise level is below some constant threshold. This is achieved thanks to quantum fault-tolerance techniques, by replacing the target logical circuit using m qubits and containing T gates by a fault-tolerant circuit using O(mpolylog(mT )) qubits. In a recent breakthrough paper [13], Gottesman has argued that the polylogarithmic space overhead isn’t necessary and is in fact a consequence of using zero-rate codes such as the toric code in the fault-tolerant circuit. In contrast, one can achieve a constant space overhead by relying on constant-rate quantum LDPC codes satisfying a number of desirable properties. The most important such property is that it should be able to efficiently correct with very high probability1 random errors provided the error rate is below some threshold.2 A main contender for such a family of codes is obtained from the hypergraph-product construction of Tillich and Zémor [27]. Starting with good classical LDPC codes, the construction yields quantum LDPC codes with constant rate and minimum distance growing like n1/2 . The reason they cannot directly be plugged in Gottesman’s construction is the absence of an efficient decoding algorithm to correct a linear number of random errors. Other code constructions such as hyperbolic codes in 4 dimensions are also a candidate since they combine a constant rate with a polynomial minimum distance [14], but they lack an efficient decoding algorithm providing the required error suppression, see however [15, 21]. Finally, hyperbolic surface codes can also achieve constant rate but only with a logarithmic minimum distance [10, 17, 30]. While such codes come with an efficient decoding algorithm, for instance Edmonds’ maximum matching algorithm [9], the success probability will not be very high and will scale like 1 − 1/poly(n) because the minimum distance is only logarithmic. As a result, they cannot be used to provide quantum fault tolerance with constant overhead and error thresholds independent of how the computation size scales with the number of qubits. Our main result is to show that the family of quantum expander codes of Ref. [20] combine the following desirable properties: they are constant rate, with a quasi-linear time decoding algorithm √ that corrects adversarial errors of weight O( n) and corrects random errors of linear size with very high probability provided that the error rate is below some constant value. Main result and proof techniques In this paper, we consider quantum expander codes, a family of constant-rate quantum hypergraphproduct codes [27], and show that the efficient decoding algorithm introduced in Ref. [20] can correct a constant fraction of random errors. More precisely, we prove the existence of a threshold for various models of noise, including depolarizing noise, as well as more adversarial models which are relevant for quantum fault-tolerance. The decoding algorithm is inspired by the bit-flip We use the term very high probability to refer to a probability 1 − ǫ(n) where ǫ(n) is negligible, i.e., nc ǫ(n) → 0 as n → ∞ for any constant c. 2 As is standard in the fault tolerance literature, we use the word “threshold” to mean that below this value, errors are corrected with high probability. And we do not care about what happens above this value. 1 2 decoding algorithm studied by Sipser and Spielman in the context of classical expander codes [25], and works by finding error patterns of small size that decrease the weight of the syndrome. For this reason, we’ll refer to it as “small-set-flip” decoding algorithm in the sequel. Similarly to the classical case, it runs in quasi-linear time. Our approach for the analysis of the decoding algorithm is inspired by the previous work of Kovalev and Pryadko [19] who studied the behaviour of the maximum likelihood decoding algorithm (that has exponential running time in general) applied to hypergraph-product codes and established the existence of a threshold for the random independent error model. Here, we use similar techniques to the study of a sub-optimal but efficient decoding algorithm, and also find the existence of a threshold. Technically, we represent the set of qubits as a graph G = ({1, . . . , n}, E) called adjacency graph where the vertices correspond to the qubits of the code and two qubits are linked by an edge if there is a stabilizer generator that acts on the two qubits. The approach is then to show that provided the vertices E corresponding to the error do not form large connected subsets, the error can be corrected by the decoding algorithm. How large the connected subsets are allowed to be is related to the minimum distance of the code for the maximum-likelihood decoder, or to the maximum size of correctable errors for more general decoders. This naturally leads to studying the size of the largest connected subset of a randomly chosen set of vertices of a graph. This is also called site percolation on finite graphs and its connection with the performance of decoding algorithms is old and was used for example in [8], [6], [7] for the surface codes and in [19] for the maximum likelihood decoder of hypergraph product codes. Here, in order to analyse the efficient small-set-flip decoding algorithm for expander graphs, we identify a slightly more complex notion of connectivity as relevant. Namely, instead of studying the size of the largest connected subset of E, we study the size of the largest connected α-subset of E. We say that X is an α-subset of E if |X ∩ E| ≥ α|X|. Note that for α = 1, this is the same as X is a subset of E. Our main technical contribution is to show that for some relevant noise models, if the probability of error of each qubit is below some threshold depending on α and the degree of G, then the probability that a random set E has a connected α-subset of size ω(log n) √ vanishes as n grows. As the minimum distance of expander codes is Ω( n) and the efficient decoding algorithm can correctly decode this many errors, we obtain the claimed result. In fact, our analysis is not restricted to quantum expander codes and applies to any “local” decoding algorithm (see Section 3.3 for a definition). We show that a “local” decoding algorithm with parameter α can correct errors on a subset of qubits E if the size of the largest connected αsubset of E is of size less than t, where t is such that the decoding algorithm can correct all errors of weight at most t. A “local” decoding algorithm here refers to a decoding algorithm where in each step errors on distant qubits are decoded independently, and is satisfied by the small-set-flip decoding algorithm for quantum expander codes. Similarly, the bit-flip decoding algorithm for classical expander codes as well as the maximum likelihood decoders for classical LDPC codes or quantum CSS LDPC codes are local in this sense. Our main theorem is the following: Theorem 1. Consider a quantum expander code with sufficient expansion and the small-set-flip decoding algorithm (Algorithm 1). Then there exists a probability p0 > 0 and constants C, C ′ such that if the noise parameter satisfies p < p0 , the small-set-flip decoding algorithm corrects a   C ′ √n p . random error with probability at least 1 − Cn p0 These results are shown in the independent error model, and also in the local stochastic error model that will be defined in Section 3.1 and is intermediate between independent and adversarial errors, and is particularly relevant in the context of fault tolerance. The proof of Theorem 1 can be found at the end of Section 4. We point out that the case of quantum CSS LDPC codes with 3 the (inefficient) maximum likelihood decoder was already studied in Ref. [19] for the independent error model and in Ref. [13] for local stochastic noise. The family of quantum expander codes with the small-set-flip decoding algorithm thus satisfies the requirements of the construction of [13] for a fault-tolerant scheme with constant space overhead. However, to plug these codes in the construction, we need in addition to analyze errors on the syndrome measurements. We believe that such syndrome errors can be analyzed similarly as in [13], but a full analysis remains to be done. The manuscript is structured as follows. In Section 2, we recall the constructions of classical and quantum expander codes and describe their respective decoding algorithms. In Section 3, we consider a generalized version of the small-set-flip decoding algorithm for quantum expander codes and introduce a notion of “locality” for decoding algorithms as well as associated parameters α and t. We then prove that the algorithm will correct any error E as long as all connected αsubsets are of size at most t. In Section 4, we study the notion of α-percolation with the tools of percolation theory and show that for t = ω(log n), there exists a threshold below which a random set E will have connected α-subsets of size at most t with high probability. Finally, in Section 5, we show that the efficient small-set-flip decoding algorithm for quantum expander codes satisfies the locality condition necessary to apply our results. 2 Classical and Quantum expander codes 2.1 Classical expander codes F A linear classical error correcting code C of dimension k and length n is a subspace of n2 of dimension k. Mathematically, it can be defined as the kernel of an (n − k) × n matrix H, called the parity-check matrix of the code: C = {x ∈ n2 : Hx = 0}. The minimum distance dmin of the code is the minimum Hamming weight of a nonzero codeword: dmin = min{|x| : x ∈ C, x 6= 0}. Such a linear code is often denoted as [n, k, dmin ]. It is natural to consider families of codes, instead of single instances, and study the dependence between the parameters n, k and dmin . In particular, a family of codes has constant rate if k = Θ(n). Another property of interest of a linear code is the weight of the rows and columns of the parity-check matrix H. If these weights are upper bounded by a constant, then we say that the code is a low-density parity-check (LDPC) code [11]. This property is particularly attractive because it allows for efficient decoding algorithms, based on message passing for instance. An alternative description of a linear code is via a bipartite graph known as its factor graph. Let G = (V ∪ C, E) be a bipartite graph, with |V | = nV and |C| = nC . With such a graph, we associate the nC × nV matrix H, whose rows are indexed by the vertices of C, whose columns are indexed by the vertices of V , and such that Hcv = 1 if v and c are adjacent in G and Hcv = 0 otherwise. The binary linear code CG associated with G is the code with parity-check matrix H. The graph G is the factor graph of the code CG , V is the set of bits and C is the set of check-nodes. It will be convenient to describe codewords and error patterns as subsets of V : the binary word e ∈ n2 V is described by a subset E ⊆ V whose indicator vector is e. Similarly we define the syndrome of a binary word either as a binary vector of length nC or as a subset of C: M σ(E) := Γ(v) ⊆ C. σ(e) := He ∈ n2 C , F F F v∈E In this paper, the operator ⊕ is interpreted either as the symmetric difference of sets or as the bit-wise exclusive disjunction depending on whether errors and syndromes are interpreted as sets or as binary vectors. A family of codes that will be central in this work are those associated to so-called expander graphs, that were first considered by Sipser and Spielman in [25]. 4 Definition 2 (Expander graph). Let G = (V ∪C, E) be a bipartite graph with left and right degrees bounded by dV and dC respectively. Let |V | = nV and |C| = nC . We say that G is (γV , δV )left-expanding for some constants γV , δV > 0, if for any subset S ⊆ V with |S| ≤ γV nV , the neighbourhood Γ(S) of S in the graph G satisfies |Γ(S)| ≥ (1 − δV )dV |S|. Similarly, we say that G is (γC , δC )-right-expanding if for any subset S ⊆ C with |S| ≤ γC nC , we have |Γ(S)| ≥ (1 − δC )dC |S|. Finally, the graph G is said (γV , δV , γC , δC )-expanding if it is both (γV , δV )-left expanding and (γC , δC )-right expanding. Sipser and Spielman introduced expander codes, which are the codes associated with (left)expander graphs. Remarkably these codes come with an efficient decoding algorithm, that can correct arbitrary errors of weight Ω(n) [25]. Theorem 3 (Sipser, Spielman [25]). Let G = (V ∪ C, E) be a (γ, δ)-left expander graph with δ < 1/4. There exists an efficient decoding algorithm for the associated code CG that corrects all error patterns E ⊆ V such that |E| ≤ γ(1 − 2δ)|V |. The decoding algorithm called the “bit-flip” algorithm is very simple: one simply cycles through the bits and flip them if this operation leads to a reduction of the syndrome weight. Sipser and Spielman showed that provided the expansion is sufficient, such an algorithm will always succeed in identifying the error if its weight is below γ(1 − 2δ)|V |. In this paper, however, we will be interested in the decoding of quantum expander codes, that we will review next. Before that, let us mention for completeness that although finding explicit constructions of highly-expanding graphs is a hard problem, such graphs can nevertheless be found efficiently by probabilistic techniques. Verifying that a given graph is expanding is a hard task, however. Theorem 4 (Theorem 8.7 of [24]). Let δV , δC be positive constants. For integers dV > 1/δV and dC > 1/δC , a graph G = (V ∪ C, E) with left-degree bounded by dV and right-degree bounded by dC chosen at random according to some distribution is (γV , δV , γC , δC )-expanding for γV , γC = Ω(1) with high probability. 2.2 Quantum error correcting codes C A quantum code encoding k logical qubits into n physical qubits is a subspace of ( 2 )⊗n of dimension 2k . A quantum stabilizer code is described by a stabilizer, that is an Abelian group of n-qubit Pauli operators (tensor products of single-qubit Pauli operators X, Y, Z and I with an overall phase of ±1 or ±i) that does not contain −I. The code is defined as the eigenspace of the stabilizer with eigenvalue +1 ([12]). A stabilizer code of dimension k can be described by a set of n − k generators of its stabilizer group. A particularly nice construction of stabilizer codes is given by the CSS construction ([4], [26]), where the stabilizer generators are either products of single-qubit X Pauli matrices or products of Z Pauli matrices. The condition that the stabilizer group is Abelian therefore only needs to be enforced between X-type generators (corresponding to products of Pauli X operators) and Z-type generators. More precisely, consider two classical linear codes CX and CZ of length n ⊥ ⊆ C . (Here, C ⊥ is the dual code to C consisting of satisfying CZ⊥ ⊆ CX , or equivalently, CX Z X X the words which are orthogonal to all the words in CX .) This condition also reads HX · HZT = 0, if HX and HZ denote the respective parity-check matrices of CX and CZ . The quantum code CSS(CX , CZ ) associated with CX (used to correct X-type errors and corresponding to Z-type stabilizer generators) and CZ (used to correct Z-type errors and corresponding to X-type stabilizer nP o generators) has length n and is defined as the linear span of , where |x + zi : x ∈ C ⊥ X z∈C F C Z {|xi : x ∈ n2 } is the canonical basis of ( 2 )⊗n . In particular, two states differing by an element of the stabilizer group are equivalent. The dimension of the CSS code is given by k = 5 ⊥ ) = dim C + dim C − n. Its minimum distance is defined in dim(CX /CZ⊥ ) = dim(CZ /CX X Z analogy with the classical case as the minimum number of single-qubit Pauli operators needed to map a codeword to an orthogonal one. For the code CSS(CX , CZ ), one has dmin = min(dX , dZ ) where dX = min{|E| : E ∈ CX \ CZ ⊥ } and dZ = min{|E| : E ∈ CZ \ CX ⊥ }. We say that CSS(CX , CZ ) is a [[n, k, dmin ]] quantum code. In the following, it will be convenient to consider the factor graph GX = (V ∪ CX , EX ) (resp. GZ ) of CX (resp. of CZ ). We will denote by ΓX (resp. ΓZ ) the neighbourhood in GX (resp. GZ ). For instance, if g ∈ CZ is an X-type generator, that is a product of Pauli X operators, then ΓZ (g) is the set of qubits (indexed by V ) on which the generator acts non-trivially. Among stabilizer codes, and CSS codes, the class of quantum LDPC codes stands out for practical reasons: these are the codes for which one can find sparse parity-check matrices HX and HZ . More precisely, such matrices are assumed to have constant row weight and constant column weight. Physically, this means that each generator of the stabilizer acts at most on a constant number of qubits, and that each qubit is acted upon by a constant number of generators. Note, however, that while surface codes exhibit in addition spatial locality in the sense that interactions only involve spatially close qubits (for an explicit layout of the qubits in Euclidean space), we do not require this for general LDPC codes. This means that generators might involve long-range interactions. This seems necessary in order to find constant rate quantum codes with growing minimum distance [3]. In this work, we will be concerned with Pauli-type noise, mapping a qubit ρ to p1 ρ+pX XρX+ pY Y ρY + pZ ZρZ, for some p1 , pX , pY , pZ . Such a noise model is particularly convenient since one can interpret the action of the noise as applying a given Pauli error with some probability. As usual, it is sufficient to deal with both X and Z-type errors in order to correct Pauli-type errors, and one can therefore define an error by the locations of the Pauli X and Pauli Z errors. An error pattern is a pair (eX , eZ ) of n-bit strings, which describe the locations of the Pauli X errors, and Pauli Z errors respectively. The syndrome associated with (eX , eZ ) for the code CSS(CX , CZ ) consists of σX = σX (eX ) := HX eX and σZ = σZ (eZ ) := HZ eZ . A decoder is given the pair (σX , σZ ) of syndromes and should return a pair of errors (êX , êZ ) such that eX + êX ∈ CZ⊥ and ⊥ . In that case, the decoder outputs an error equivalent to (e , e ), and we say that eZ + êZ ∈ CX X Z it succeeds. Similarly as in the classical case, it will be convenient to describe X-type error patterns and Xtype syndromes as subsets of the vertices of the factor graph GX = (V ∪ CX , EX ). The error pattern is then described by a subset EX ⊆ V whoseL indicator vector is eX and the syndrome is the subset σX (EX ) ⊆ CX defined by σX (EX ) := v∈EX ΓX (v). Z-type error patterns and Z-type syndromes are described in the same fashion using the factor graph GZ . In the rest of this paper, we will consider special decoding algorithms that try to recover eX and eZ independently. More precisely, a decoding algorithm is given by an X-decoding algorithm that takes as input σX and returns êX such that σX (êX ) = σX , and a Z-decoding algorithm that takes as input σZ and returns êZ such that σZ (êZ ) = σZ . We note that this special type of decoding algorithm might achieve sub-optimal error probabilities for some error models. In fact, if there are correlations between X and Z errors (for instance in the case of the depolarizing channel where pX = pY = pZ ), one can decrease the error probability by trying to recover eX by using both σX and σZ . However, for the purpose of this paper, it is sufficient to consider these special decoding algorithms. In addition, as we will consider codes where HX and HZ play symmetric roles, so the Z-decoding algorithm is obtained from the X-decoding algorithm by exchanging the roles of X and Z. Let us conclude this section by mentioning the maximum likelihood decoding algorithm which 6 returns an error (êX , êZ ) of minimum Hamming weight with the appropriate syndrome, that is: êZ = arg min |fZ |. êX = arg min |fX |, σZ (fZ )=σZ σX (fX )=σX This inefficient algorithm always succeeds provided that the error weights satisfy |eX | ≤ ⌊(dX − 1)/2⌋ and |eZ | ≤ ⌊(dZ − 1)/2⌋. 2.3 Quantum expander codes In this work, we are particularly interested in a family of LDPC CSS codes that features a constant √ rate and a minimum distance Θ( n) obtained by applying the hypergraph product construction of Tillich and Zémor to classical expander codes. If these expander codes have sufficient expansion, the corresponding quantum code is called quantum expander code and comes with an efficient decoding algorithm that corrects arbitrary errors of size linear in the minimum distance. The construction is as follows. Let G = (A ∪ B, E) be a biregular (γA , δA , γB , δB )-expanding graph with δA , δB < 1/6, and constant left and right degrees denoted dA and dB . Let us also denote nA = |A| and nB = |B| with nA < nB . According to Theorem 4, such graphs can be found efficiently (in a probabilistic fashion) provided that dA , dB ≥ 7. Let C be the classical code associated with G, let dmin (C) be the minimal distance of C and let H be its parity-check matrix (that we assume to be full rank) corresponding to the factor graph G. In particular, the weights of rows and columns of H are dA and dB , respectively. The hypergraph product code of C with itself admits the following parity check matrices:  HX = InA ⊗ H, H T ⊗ InB  H Z = H ⊗ In A , In B ⊗ H T . It is immediate to check that this defines a legitimate CSS code since HX HZT = InA ⊗ H · (H ⊗ InA )T + H T ⊗ InB (InB ⊗ H T )T = H T ⊗ H + H T ⊗ H = 0. Moreover, the code is LDPC with generators of weight dA + dB and qubits involved in at most 2 max(dA , dB ) generators. We can describe the factor graphs GX and GZ as follows: the set of qubits is indexed by A2 ∪ B 2 , the set of Z-type generators is indexed by A × B and the set of X-type generators is indexed by B × A. The bipartite graph GX has left vertices A2 ∪ B 2 , right vertices A × B and there is an edge between a vertex (α, a) ∈ A2 (resp. (b, β) ∈ B 2 ) and a vertex (α, β) ∈ A × B when a (resp. b) is in the neighbourhood of β (resp. α) in G. The bipartite graph GZ has left vertices A2 ∪ B 2 , right vertices B × A and there is an edge between a vertex (α, a) ∈ A2 (resp. (b, β) ∈ B 2 ) and a vertex (b, a) ∈ B × A when α (resp. β) is in the neighbourhood of b (resp. a) in G. The following theorem summarizes the main properties of this quantum code. Theorem 5 (Tillich, Zémor [27]). The CSS code defined above is LDPC with parameters [[n, k, dmin ]], where n = nA 2 + nB 2 , k ≥ (nA − nB )2 and dmin = dmin (C). Since the graph G is sufficiently expanding, we can apply the results from Ref. [20] and show the existence of an efficient decoding algorithm called “small-set-flip” decoding algorithm. Focusing on X-type errors for instance, and assuming that the syndrome σX = HX eX is known, the algorithm cycles through all the X-type generators of the stabilizer group (i.e. the rows of HZ ), and for each one of them, determines whether there is an error pattern contained in the generator that decreases the syndrome weight. Assuming that this is the case, the algorithm applies the error 7 pattern (maximizing the ratio between the syndrome weight decrease and the pattern weight). The algorithm then proceeds by examining the next generator. Since the generators have (constant) weight dA + dB , there are 2dA +dB possible patterns to examine for each generator. If the graph G has sufficient expansion and if the error weight is small enough, there always exists a generator containing an error pattern decreasing the syndrome weight. It can then be proved that if the error weight is below the value w0 of Eq. (1) below, the decoding algorithm will not stop before reaching a null syndrome, hence corresponding to a codeword. Moreover, because the number of steps of the algorithm is sufficiently low, it is not possible to have reached an incorrect codeword, hence the decoding succeeded. Let us introduce some additional notations: let X be the set of subsets of V corresponding to X-type generators: X = {ΓZ (g) : g ∈ CZ } ⊆ P(V ). The indicator vectors of the elements of X span the dual code CZ⊥ . The condition for successful decoding then asks that there exists a subset X ⊂ X such that M E ⊕ Ê = x, x∈X meaning that the remaining error after decoding is trivial, that is equal to a sum of generators. At each step, the small-set-flip algorithm tries to flip a subset of some g ∈ X . In other words, it tries to flip some element of F := {F ⊆ x : x ∈ X }. Algorithm 1 (Ref. [20]): Small-set-flip decoding algorithm for quantum expander codes INPUT: σ ⊆ CX , a syndrome where σ = σX (E) with E ⊆ V an error OUTPUT: Ê ⊆ V , a guess L for the error pattern (alternatively, a set of qubits to correct) SUCCESS: if E ⊕ Ê = x∈X x for X ⊆ X , i.e. E and Ê are equivalent errors Ê0 = 0 ; σ0 = σ ; i = 0 while (∃F ∈ F : |σi | − |σi ⊕ σX (F )| > 0) do Fi = arg max F ∈F |σi | − |σi ⊕ σX (F )| |F | Êi+1 = Êi ⊕ Fi σi+1 = σi ⊕ σX (Fi ) i=i+1 end while return Êi // pick an arbitrary one if there are several choices // σi+1 = σX (E ⊕ Êi+1 ) Theorem 6 (Leverrier, Tillich, Zémor [20]). Let G = (A∪B, E) be a (dA , dB )-biregular (γA , δA , γB , δB )expanding graph with δA , δB < 1/6. Letting dA and dB be fixed and allowing nA , nB to grow, Algorithm 1 runs in time linear in the code length n = n2A + n2B , and decodes any quantum error pattern of weight less than w0 = 1 min(γA nA , γB nB ). 3(1 + dB ) (1) The analysis above applies to arbitrary errors of weight less than w0 . Unfortunately, w0 = √ √ O( n), corresponding to an error rate of O(1/ n), which is often insufficient for applications, where a constant error rate is typically required. The main goal of this work is to determine the performance of the algorithm above against random noise with constant error rate. Such an error model leads to typical errors of size linear in n, and Theorem 6 is useless in that regime. The rest of the paper is devoted to show the existence of a threshold for natural models of random noise for Algorithm 1. 8 3 Efficient decoding algorithms for quantum expander codes In this section, we first describe two natural noise models for which we will establish the existence of thresholds for the decoding algorithm of quantum expander codes. Then, we will present a variant of the small-set-flip decoding algorithm of Ref. [20]. Finally, we will describe the crucial features of this decoding algorithm, notably its locality, and define parameters α and t, that will be particularly useful to establish the existence of thresholds. 3.1 Noise models We think of an error pattern as a pair (EX , EZ ) of subsets of the set of qubits V . A noise model is thus described by a distribution on pairs of subsets of V . Letting (EX , EZ ) be distributed according to such a model, the failure probability of a decoding algorithm that outputs (ÊX , ÊZ ) is given by P((EX , EZ ) not equivalent to (ÊX , ÊZ )) ≤ P(EX not equivalent to ÊX ) + P(EZ not equivalent to ÊZ ) . (2) As the decoders we consider treat X and Z symmetrically, it suffices to focus on X-type errors and the analysis of failure probability for identifying Z-type errors is exactly symmetrical. For this reason, we will now assume that we deal with X-type errors and simply use E for EX . The most natural error model is that of independent noise, where each qubit is in error independently, with the same probability. Definition 7 (Independent noise error model). Let V be the set of qubits. The error of parameter p is a random variable E ⊆ V such that P(E) = p|E| (1 − p)|V |−|E| . For example, the X-type errors (resp. Z-type errors) produced by a depolarizing channel ρ 7→ (1 − p)ρ + p/3(XρX + Y ρY + ZρZ) are independent with parameter 2p/3 since Y = iXZ = −iZX. More generally, a channel ρ 7→ p1 ρ + pX XρX + pY Y ρY + pZ ZρZ satisfies the independent noise condition with parameter pX + pY for the X-type errors and parameter pY + pZ for the Z-type errors. The independent noise error model is often too restrictive in practice, notably in the context of fault-tolerance since errors will propagate through the circuit and become correlated. Instead of trying to control such correlations, it is handy to simply allow for any possible error set, but put a bound on the probability of observing an error of a given size. A convenient model was considered by Gottesman in Ref. [13] where we ask that such a probability is exponentially small in the error size. Definition 8 (Local stochastic error model). Let V be the set of qubits. The error of parameter p is a random variable E ⊆ V such that for all F ⊆ V : P(F ⊆ E) ≤ p|F |. In other words, the location of the errors is arbitrary but the probability of a given error decays exponentially with its weight. 3.2 Small-set-flip decoding algorithm for quantum expander codes Let us now turn to the decoding of quantum codes. As mentioned previously, we focus here on decoding X errors. Given a syndrome σX = σX (EX ), the decoding algorithm should output a guess ÊX which is equivalent to EX , in the sense that EX + ÊX belongs to the dual code CZ⊥ . In the description of Algorithm 1, the idea is to go through all the elements of CZ (called X-type generators and corresponding to products of Pauli X operators), one at a time, and check 9 whether applying any error pattern within this generator would decrease the syndrome weight. If this is the case, then apply the “best” such error pattern. Then proceed with the next generator. It is possible to design Algorithm 2, a slight generalization of Algorithm 1 that depends on an extra-parameter β ∈ (0, 1], where a small set F is flipped only if it leads to a decrease of the syndrome weight by at least βdB |F |. Note that Algorithm 2 is a “tool” that we use in order to study Algorithm 1 since any error E ⊆ V corrected by Algorithm 2 is corrected by Algorithm 1 (see Remark 9). Requiring a larger value for β reduces the number of qubits incorrectly flipped during the decoding procedure. This property will be useful for studying the performance of the algorithm against various random noise models. The drawback, however, is that larger values of β mean better expansion (smaller value of δA and δB ) and therefore larger degrees dA and dB . The value of β should be optimized in order to find the largest possible threshold p0 under which the small-set-flip decoding algorithm will correct random errors, except with negligible probability. Algorithm 2 : Small-set-flip decoding algorithm for quantum expander codes, with parameter β ∈ (0, 1] INPUT: σ ⊆ CX , a syndrome where σ = σX (E) with E ⊆ V an error OUTPUT: Ê ⊆ V , a guess L for the error pattern (alternatively, a set of qubits to correct) SUCCESS: if E ⊕ Ê = x∈X x for X ⊆ X , i.e. E and Ê are equivalent errors Ê0 = 0 ; σ0 = σ ; i = 0 while (∃F ∈ F : |σi | − |σi ⊕ σX (F )| ≥ βdB |F |) do Fi = arg max F ∈F |σi | − |σi ⊕ σX (F )| |F | Êi+1 = Êi ⊕ Fi σi+1 = σi ⊕ σX (Fi ) i=i+1 end while return Êi // pick an arbitrary one if there are several choices // σi+1 = σX (E ⊕ Êi+1 ) Remark 9. The while loop condition in Algorithm 2 is stronger than in Algorithm 1 and this is the only difference between the two algorithms. As a consequence if Algorithm 2 corrects an error E, then Algorithm 1 corrects E. Analyzing this modified algorithm can be done similarly as for the original one. For a given quantum expander code, we prove that there exists β0 > 0 such that for β ≤ β0 , the small-set-flip √ decoding algorithm with parameter β corrects any adversarial errors of size up to Θ( n). The value of β0 is defined in Definition 10. Definition 10. Let G = (A ∪ B, E) be a (dA , dB )-biregular (γA , δA , γB , δB )-left-right-expanding graph. We define r and β0 by: r= dA , dB β0 =  r 1 − 4(δA + δB + (δB − δA )2 ) . 2 Note that δA , δB < 1/8 is sufficient to ensure that β0 > 0 and there exists such expander graphs as soon as dA , dB ≥ 9 (see Theorem 4). As a reminder, the weight of the stabilizer generators is dA + dB . Proposition 11. Let G = (A∪B, E) be a (dA , dB )-biregular (γA , δA , γB , δB )-left-right-expanding graph and r, β = β0 be defined using the associated quantum expander code (Definition 10). The 10 small-set-flip decoding algorithm of parameter β described in Algorithm 2 can correct any adversarial error of size up to tSSF(β) where: tSSF(β) ≥ rβ min(γA nA , γB nB ). 1+β The proof of Proposition 11 is provided in Appendix B.1. Note that Algorithm 2 is not deterministic since the Fi are not necessarily unique but if the weight of the error is smaller than tSSF(β) , then the error is corrected for any non-deterministic choice of the Fi . 3.3 Locality of the small-set-flip decoding algorithm This section is devoted to explicitly state the properties of the small-set-flip decoding algorithm that we need in order to prove Theorem 1. Recall that our goal is to establish the existence of a threshold: in the random error model of Definition 7, if the probability of error is small enough then we correct the error with high probability. An important property of the p algorithm that we consider is that it can correct adversarial errors of size ≤ t where t = Θ( |V |) and V is the set of qubits. The second crucial property we will rely on is that the algorithm is local, meaning in words that errors far away in the adjacency graph G of the code will not interact during the decoding process. The adjacency graph G = (V, E) associated with the code admits the set of qubits as vertices, and two vertices are adjacent in G if the corresponding qubits share an X-type or Z-type stabilizer generator. Let us now define the notion of locality more formally. For an input syndrome σX (E) ⊆ CX with E ⊆ V an error, the output of Algorithm 2 is Ê = F0 ⊕ . . . ⊕ Ff −1 , where Fi is the small set flipped at the ith round of the algorithm, and we will call U = E ∪ F0 ∪ . . . ∪ Ff −1 the support. We have Ê ⊆ U but Ê 6= U in general. Proposition 12 (Locality of the small-set-flip decoding algorithm). Let E ⊆ V be an error and run Algorithm 2 on input σX (E). Consider K, a connected component in G of U where U = E ∪ F0 ∪ . . . ∪ Ff −1 is the support and Ê = F0 ⊕ . . . ⊕ Ff −1 is the output. Then there is a valid execution of Algorithm 2 with input σX (E ∩ K), output Ê ∩ K and support K. Let’s give the intuition of the proof of Proposition 12 (the formal proof is given in Section 5). The execution of Algorithm 2 on the input syndrome σX (E) provides some sets F0 , . . . , Ff −1 that we use to define the support U = E ∪ F0 ∪ . . . ∪ Ff −1 and the output Ê = F0 ⊕ . . . ⊕ Ff −1 . We would like to prove that there is a valid execution of the algorithm with input σX (E ∩ K), output Ê ∩ K and support K where K is some connected component of U in G. In other words, we would like to prove that on the input syndrome σX (E ∩ K), Algorithm 2 provides some sets F0′ , . . . , Ff′ ′ −1 (as well as σ0′ , . . . , σf′ ′ −1 ) which satisfy K = (E ∩ K) ∪ F0′ ∪ . . . ∪ Ff′ ′ −1 and Ê ∩ K = F0′ ⊕ . . . ⊕ Ff′ ′ −1 . For simplicity, we first assume that Fi ⊆ K for all i and we define CK = ΓX (K) ⊆ CX to be the set of Z-type generators which touch at least one qubit of K in the factor graph GX . Let’s prove that a valid choice for f ′ , Fi′ and σi′ is given by f ′ = f , Fi′ = Fi and σi′ = σi ∩ CK . In the factor graph GX , all the neighbours of CK are in K ∪ U and all the neighbours of CK are in K. Hence, the syndrome part included in CK is the same for an error W ⊆ V and for the error W ∩ K: σX (W ∩ K) = σX (W ) ∩ CK (Lemma 20). If we apply this formula with W = E, we get σ0′ = σX (E ∩ K) which matches the input of Algorithm 2 in the conclusion of ′ Proposition 12. With W = Fi and our additional hypothesis Fi ⊆ K, we get σi+1 = σi′ ⊕ σX (Fi ) which matches the manner in which σi is updated in Algorithm 2. On the other hand, the value of the syndrome σi determines the algorithm behaviour and, similarly, the value of σi′ = σi ∩ CK 11 determines the algorithm behaviour on the qubits of K (this is a consequence of Lemma 21). As a conclusion, flipping the sets Fi is a valid execution for Algorithm 2 on input σX (E ∩ K) and thus Proposition 12 holds. In the general case, we have some indices i satisfying Fi * K. Since K is a connected component of U in G, such i always satisfy Fi ∩ K = ∅ and thus flipping Fi does not change the syndrome part included in CK . Hence, with the sets Fi′ defined to be the sets Fi such that Fi ⊆ K, we can prove Proposition 12 as previously. The concept of locality allows us to treat the errors piece-wise in the sense that if Algorithm 2 corrects E ∩ K for any connected component K of U , then the entire error E is corrected. On the other hand, we know that Algorithm 2 corrects any error of size smaller than some tSSF(β) = √ Θ( n). We do not have |E| ≤ tSSF(β) in general, but using the concept of α-subset, we will prove that with high probability |E ∩ K| ≤ |K| ≤ tSSF(β) . Hence Algorithm 2 corrects E ∩ K and, by locality, E is corrected. Definition 13 (α-subsets, MaxConnα (E)). An α-subset of a set E ⊆ V is a set X ⊆ V such that |X ∩ E| ≥ α|X|. We denote by MaxConnα (E) the maximum size of a connected α-subset of E. Note that a 1-subset is a subset in the usual sense and MaxConn1 (E) is the size of the largest connected subset of E. As a relevant example, a corollary of Proposition 12 and of Lemma 14 is β that the set K defined in Proposition 12 is a connected 1+β -subset of E ∩ K. Lemma 14. Let E ⊆ V be an error and run the small-set-flip decoding algorithm of parameter β and U = E ∪ F0 ∪ . . . ∪ Ff −1 be the support. Then U is an β > 0 on input σX (E). Let α = 1+β α-subset of E. Proof. For all i, the decrease in the syndromePweight |si | − |si+1 | satisfies |si | − |si+1 | ≥ βdB |Fi | and thus dB |E| ≥ |s0 | ≥ |s0 | − |sf | ≥ βdB i |Fi |. We conclude that: |U | = E ∪ f[ −1 i=0 Fi ! ≤ |E| + f −1 X i=0 |Fi | ≤ 1+β 1+β |E| = |E ∩ U |. β β All these notions allow us to prove the following general characterization of correctable errors. Proposition 15. Suppose that for some quantum expander code, Algorithm 2 with parameter β > 0 corrects any error E ⊆ V satisfying |E| ≤ t. β is corrected. Then any error E ⊆ V satisfying MaxConnα (E) ≤ t with α = 1+β Proof. Our goal is to prove that when we apply Algorithm 2 on the input σX (E), the error E and the output Ê = F0 ⊕ . . . ⊕ Ff −1 are equivalent. Let U = E ∪ F0 ∪ . . . ∪ Ff −1 be the support, then U U we can decompose E as E = K (E ∩ K) and Ê as Ê = K (Ê ∩ K), where the index K of these disjoint unions goes through the set of connected components of U . In order to prove that E and Ê are equivalent, we will prove the sufficient condition that E ∩ K and Ê ∩ K are equivalent for any K. By Proposition 12, there is a valid execution of Algorithm 2 with input σX (E ∩ K), output Ê ∩K and support K. By Lemma 14, K is an α-subset of E ∩K and thus K is a connected α-subset of E. If we suppose MaxConnα (E) ≤ t then |E ∩ K| ≤ |K| ≤ t and we can conclude that E ∩ K and Ê ∩ K are equivalent because Algorithm 2 corrects E ∩ K. 12 Remark 16. A similar analysis has been done in [19] and [13] for the maximum likelihood decoding algorithm of quantum LDPC codes and we could also apply the same arguments for the bit-flip algorithm of classical expander codes. However, this is less relevant since this algorithm can already correct adversarial errors of linear size. In fact, the maximum likelihood decoding algorithm and the bit-flip algorithm are both local in the sense of Proposition 12. 4 Properties of random errors: α-percolation In order to establish Theorem 1 at the end of this section, we first study a specific model of site percolation that is relevant for the analysis of our decoding algorithms. More specifically, for a graph G = (V, E) with degree upper bounded by some constant d, and a probabilistic model for choosing a random subset E ⊆ V , site percolation asks about the size of the largest connected subset of vertices of E. Here, instead of looking for a connected subset of E, we instead ask about the size MaxConnα (E) of the largest α-subset of E which is connected. The simplest model for the choice of E is the i.i.d. model where each site (or vertex) is occupied independently with probability p. In this model, a standard result in percolation theory 1 there is an infinite connected subset of E and if is that for the infinite d-regular tree, if p > d−1 1 p < d−1 all connected subsets are finite [22]. In the setting of finite graphs, for a random d-regular 1 graph the maximum connected subset of E is of size O(log n) for p < d−1 and of size Ω(n) for 1 1 p > d−1 [16]. For general graphs with degree bounded by d, [19] showed that for p < d−1 the size of the largest connected component of E in G has size O(log |V |). We will also consider the more general local stochastic model where the probability of a subset E is upper bounded by p|E|. Theorem 17 (α-percolation). Let G = (V, E) a graph with degree upper bounded by d. Let α ∈ (0, 1] and let t ≥ 1 be an integer. Let pls = 2−h(α) 1 d−2 (d − 1)(1 + d−2 ) !1 α , (3) where h(α) = −α log2 α − (1 − α) log2 (1 − α) is the binary entropy function. Then, for an error random variable E satisfying the local stochastic noise property (Definition 8) with parameter p < pls , we have  αt p (4) P[MaxConnα (E) ≥ t] ≤ C|V | pls   α  . In the special case, where vertices are chosen indewhere 1/C = (1 − 2h(α)/α p) 1 − ppls α pendently with probability p < d−1 , the result can be slightly improved to P[MaxConnα (E) ≥ t] ≤ |V | where q = (1 − p)d−1−α pα 2h(α) (d − 1)(1 +  d−1 d−2 2 qt , 1−q (5) 1 d−2 . d−2 ) Note that (5) shows that if p is chosen small enough so that q < 1 the size of the largest component will be O(log |V |) with high probability. It is simple to see that choosing p < pls leads to q < 1 but one can even take p slightly larger. For example, in the case α = 1, we have q < 1 1 even though pls = (d−1)(1+1 1 )d−2 . More generally, q as a function of p is as soon as p < d−1 d−2 α α ] and thus there is a value piid ∈ [pls , d−1 ] such that q = 1 increasing in the interval p ∈ [0, d−1 (see Lemma 29) and any p < piid leads to a q < 1. 13 Proof. We focus here on the local stochastic noise bound. The finer analysis of the independent noise model in (5) is left to Appendix B.2. Let Cs (G) be the set of connect sets of vertices of size s in G. Applying a union bound, we obtain P[MaxConnα (E) ≥ t] = P [∃s ≥ t, ∃X ∈ Cs (G) : |X ∩ E| ≥ α|X|] X X ≤ P [|X ∩ E| ≥ α|X|] . s≥t X∈Cs (G) Let us first consider the quantity P [|X ∩ E| ≥ α|X|]: X X P [|X ∩ E| ≥ α|X|] ≤ P [X ∩ E = Y ] m≥αs Y ⊆X: |Y |=m ≤ X X P [Y ⊆ E] X X pm m≥αs Y ⊆X: |Y |=m ≤ from the definition of the noise model m≥αs Y ⊆X: |Y |=m X s ≤ pm . m m≥αs Using Lemma 25, we get P [|X ∩ E| ≥ α|X|] ≤ ≤ ≤ X  2 s h m m s m≥αs  m p m X  2h(α)/α p m≥αs since (x 7→ h(x)/x) is non increasing on [α, 1] (2h(α)/α p)αs . 1 − 2h(α)/α p We now need an upper bound on the number of connected sets of size s in a graph with degree upper bounded by d. For this we use Corollary 28 saying that |Cs (G)| ≤ |V |K(d)s with K(d) =  d−2 1 (d − 2) 1 + d−2 . Then, we get P[MaxConnα (E) ≥ t] ≤ ≤ X X s≥t X∈Cs (G) P [|X ∩ E| ≥ α|X|)] 1 1 − 2h(α)/α p X s≥t |Cs (G)| 2h(α)s pαs by the union bound s X |V | h(α) α K(d)2 p ≤ 1 − 2h(α)/α p s≥t ≤ Observing that pls =  1 K(d)2h(α) |V | (K(d)2h(α) pα )t . 1 − 2h(α)/α p 1 − K(d)2h(α) pα 1/α , we obtain the desired result. Using Propositions 11 and 15 and Theorem 17, we are now ready to prove Theorem 1: 14 Proof of Theorem 1. Using Remark 9, it is sufficient to prove Theorem 1 for Algorithm 2 instead of Algorithm 1. Under the condition that the expansion of the initial graph G is good enough, the parameter β = β0 from Definition 10 is positive. We let p0 = pls as defined in (3) where G is the adjacency graph of the quantum expander code and d = d2B + 2dB (dA − 1) is an upper bound on the degree of G. Then for p < p0 , for an error E chosen according to a local stochastic noise, and √ fixing t = tSSF(β) = Ω( n) as defined in Proposition 11, we obtain P[MaxConnα (E) ≥ t] ≤ Cn  p p0 αt . As a result, applying Proposition 15, E is corrected except with probability at most Cn and this gives us the desired results.  αt p p0 Remark 18. It is an interesting question of percolation theory to find the maximum value of p for which the largest connected α-subset is of size O(log n). This will depend on the graph G but as mentioned earlier, it is known that for random d-regular graphs and α = 1, p = 1/(d − 1) is the threshold for the appearance of large connected sets (see [16], Theorem 3.5). In Proposition 30, 1 1−ǫ ) and thus Eq. (3) we show that for p > 1 , the largest connected α-subset is of size Ω(n (d−1) α −h(α) can be improved by a factor of at most ( 2 e 1 )α . 5 The small-set-flip decoding algorithm is local (proof of Proposition 12) In this section we show that the small-set-flip decoding algorithm (Algorithm 2) is local in the sense of Proposition 12 (the intuition of the proof has been given after the statement of the proposition). Notation 19. Throughout this section we keep the following notations: • The sets F, E, K, U, F0 , . . . , Ff −1 and Ê are defined as in Algorithm 2 and proposition 12. • CK = ΓX (K) ⊆ CX is the set of Z-type generators which touch at least one qubit of K in the factor graph GX . • For σ ⊆ CX and F ∈ F: ∆(σ, F ) = Algorithm 2. |σ| − |σ ⊕ σX (F )| is the function optimized by |F | Lemma 20. Let W ⊆ U (later we will take either W = E or W = Fi ) then σX (W ∩ K) = σX (W ) ∩ CK . Proof. We decompose σX (W ) ∩ CK using the partition W = (W ∩ K) ⊎ (W ∩ K) and the distributivity:   σX (W ) ∩ CK = σX (W ∩ K) ⊕ σX (W ∩ K) ∩ CK = (σX (W ∩ K) ∩ CK ) ⊕ (σX (W ∩ K) ∩ CK ). The first term of this sum satisfies σX (W ∩ K) ∩ CK = σX (W ∩ K) because σX (W ∩ K) ⊆ ΓX (K) = CK . On the other hand, since K is a connected component of U in G, it holds that ΓX (U \ K) ∩ ΓX (K) = ΓX (U \ K) ∩ CK = ∅ and thus the second term of the sum satisfies σX (W ∩ K) ∩ CK = ∅ because W ∩ K ⊆ U \ K. 15 Lemma 21. Let F ∈ F then: (i) ∆(σ ∩ CK , F ) ≤ ∆(σ, F ), (ii) If F ⊆ K then ∆(σ ∩ CK , F ) = ∆(σ, F ). Proof. Rewrite ∆(σ, F ) in a more friendly way using the definition of ⊕: ∆(σ, F ) = 2|σX (F ) ∩ σ| − |σX (F )| . |F | (6) The proof of item (i) is straightforward using eq. (6): let F ∈ F, we have: 2|σX (F ) ∩ σ ∩ CK | − |σX (F )| |F | 2|σX (F ) ∩ σ| − |σX (F )| ≤ |F | = ∆(σ, F ) by eq. (6) ∆(σ ∩ CK , F ) = by eq. (6) Under the assumption F ⊆ K of item (ii), we have σX (F ) ∩ CK = σX (F ). As a consequence, the inequality in the proof of item (i) is an equality and thus item (ii) holds. We are now ready to prove Proposition 12. Proof of Prop. 12. We would like to prove that there is a valid execution of Algorithm 2 with input σX (E ∩K), output Ê ∩K and support K. This means that there exists some sets F0′ , . . . , Ff′ ′ −1 ⊆ ′ ′ (F ′ ) for j ∈ J0; f ′ − 1K then we V such that if we define σ0′ = σX (E ∩ K) and σj+1 = σj′ ⊕ σX j have the following properties: (i) The set Ê ∩ K satisfies Ê ∩ K = F0′ ⊕ . . . ⊕ Ff′ ′ −1 . (ii) The set K satisfies K = (E ∩ K) ∪ F0′ ∪ . . . ∪ Ff′ ′ −1 . (iii) For j ∈ J0; f ′ − 1K, Fj′ maximises F 7→ ∆(σj′ , F ) over F. (iv) For j ∈ J0; f ′ − 1K, ∆(σj′ , Fj′ ) ≥ βdB . (v) For all F ∈ F, ∆(σf′ ′ , F ) < βdB . In the adjacency graph G, two qubits in the support of the same generator are connected. As a consequence, since the set Fi is included in the support of a generator and since K is connected, either Fi ⊆ K or Fi ∩ K = ∅. Consider i0 < . . . < if ′ −1 ∈ J0; f − 1K the steps of the algorithm such that Fik ⊆ K and let’s prove that the sets F0′ = Fi0 , . . . , Ff′ ′ = Fif ′ −1 are appropriate. By definition we have: Fi ∩ K = Fi if i ∈ {i0 , . . . , if ′ −1 } Fi ∩ K = ∅ if i ∈ / {i0 , . . . , if ′ −1 } Using eqs. (7) and (8), we can easily prove items (i) and (ii): ! ′ −1 fM f −1 f −1 M M Fj′ . (Fi ∩ K) = Fi ∩ K = (i) Ê ∩ K = i=0 j=0 i=0 16 (7) (8) (ii) ′ −1 f[ j=0 Fj′ = f[ −1 i=0 (Fi ∩ K) and using the distributivity: K = U ∩ K = (E ∩ K) ∪ F0′ ∪ . . . ∪ Ff′ ′ −1 . By hypothesis, we further have a valid execution of Algorithm 2 with input σX (E), output Ê and support U . This implies: (iii’) For i ∈ J0; f − 1K, Fi maximises F 7→ ∆(σi , F ) over F. (iv’) For i ∈ J0; f − 1K, ∆(σi , Fi ) ≥ βdB . (v’) For all F ∈ F, ∆(σf , F ) < βdB . We also need the property of eq. (9) where we have defined if ′ = f : σj′ = σij ∩ DK j ∈ J0; f ′ K. (9) Note that item (iii) (resp. item (iv), resp. item (v)) is a direct consequence of Lemma 21, eq. (9) and item (iii’) (resp. item (iv’), resp. item (v’)). To complete the proof, it remains to prove eq. (9). By Lemma 20: σ0 ∩ DK = σX (E) ∩ DK = σX (E ∩ K), σi+1 ∩ DK = (σi ⊕ σX (Fi )) ∩ DK = (σi ∩ DK ) ⊕ σX (Fi ∩ K) i ∈ J0; f − 1K. If i ∈ {i0 , . . . , if ′ −1 } then by eq. (7): σi+1 ∩ DK = (σi ∩ DK ) ⊕ σX (Fi ). If i ∈ / {i0 , . . . , if ′ −1 } then by eq. (8): σi+1 ∩ DK = σi ∩ DK . In summary:  (   σ0 ∩ DK = σX (E ∩ K) σ0′ = σX (E ∩ K) σi+1 ∩ DK = (σi ∩ DK ) ⊕ σX (Fi ) ′ σj+1 = σj′ ⊕ σX (Fij ) j ∈ J0; f ′ − 1K   σi+1 ∩ DK = σi ∩ DK i ∈ {i0 , . . . , if ′ −1 } i∈ / {i0 , . . . , if ′ −1 } Equation (9) is a direct corollary of the following property that we can prove by induction: σ0′ = σ0 ∩ DK = . . . = σi0 ∩ DK , ′ σj+1 = σij +1 ∩ DK = . . . = σij+1 ∩ DK A j ∈ J0; f ′ − 1K. Numerical bounds In this section, we look at the numerical values of the bounds on the threshold that we derived in the main text. We obtain a threshold pls = 2.70.10−16 for the small-set-flip decoding algorithm of quantum expander codes with errors in the locally stochastic noise model. By Theorem 4, there exists a family of (γA , δA , γB , δB )-expanders for γA , γB = Ω(1) with left degree dA = 38, right degree dB = 39, δA = 1/dA + ǫ and δB = 1/dB + ǫ for ǫ arbitrarily small. From the construction of Section 2.3 we get a family of quantum expander codes. The degree of the associated adjacency graph is d = d2B + 2dB (dA − 1) = 4407 and by Definition 10 and propositions 11 and 15 and Theorem 17, the small-set-flip algorithm with parameter β = 17 dA 2dB  1 − 4(δA + δB + (δB − δA )2 ) ≈ 0.386 corrects random errors in the locally stochastic noise model of probability p < pls with high probability where  β ≈ 0.278, α= 1+β pls = 2−h(α) 1 d−2 (d − 1)(1 + d−2 ) !1 α ≈ 2.70 · 10−16 . Note that the threshold piid in the independent error model is essentially the same: piid − pls ≈ 1 · 10−27 . From a practical point of view, this theoretical value of 2.70 · 10−16 is too small to be relevant. We believe, however, that in practice the threshold will be much better. Take as an example the toric code: our analysis leads to a threshold of 8.1 · 10−4 in the independent error model with ideal syndrome extraction, whereas it is known that the actual threshold is around 10% (see e.g. Ref. [29]). Notice furthermore that the graph expansion arguments are generally pessimistic since they are based on averaging (see for example the discussion of Ref. [24] example 8.14, about the correction capacity of the bit-flip algorithm for classical expander codes). In addition the threshold for α-percolation given in Theorem 17 is valid for any graph G of degree bounded by d. In particular, the case α = 1 shows that the threshold is the smallest when the graph G is randomly sampled [16]. The point is that the number of connected sets in that kind of graphs is close to the upper bound of Lemma 27. In contrast, the adjacency graphs G we considered are not random and seem to contain far less connected sets than the upper bound that we relied on. As a consequence, if one were able to improve the bound of Lemma 27, it would automatically lead to a better threshold as can be seen in the proof of Theorem 17. One last argument is that one can improve the analysis of the “propagation” of errors: suppose that during the bit flip algorithm, a bit v with no error is flipped, then it would mean that at least half of the neighbours of v in the graph G are in error. This shows that not all the connected sets allow the error to propagate, and thus the bound of Lemma 27 would be improved by only counting this kind of connected sets. Note also the similarity with the setup of “bootstrap percolation” (see Ref. [1]). We believe that some arguments from this field can be used to improve our threshold. B Proofs B.1 Proof of Proposition 11 We follow the proof of [20]. An element g ∈ CZ is called a generator. An error E ⊆ V is called reduced if |E| is minimal among the errors of E + CZ ⊥ . Following Ref. [20], we introduce a notion of critical generator which corresponds to a generator g with ΓZ (g) containing a set of qubits that can be flipped to decrease the syndrome weight. More precisely, a critical generator as defined below can always be used to decrease the syndrome weight, but there might exist noncritical generators that also contain a subset of qubits that lead to a decrease of the weight of the syndrome, when flipped. Definition 22 (Definition 6 of [20]). A generator g ∈ CZ is said to be critical for E ⊆ V if: ΓZ (g) = xa ⊎ xa ⊎ χa ⊎ xb ⊎ xb ⊎ χb where • ΓZ (g) ∩ A2 = xa ⊎ xa ⊎ χa and ΓZ (g) ∩ B 2 = xb ⊎ xb ⊎ χb ; • xa , xb ⊆ E and xa , xb ⊆ V \ E; • for all va ∈ xa , vb ∈ xb , v a ∈ xa and v b ∈ xb : 18 – E ∩ ΓX [ΓX (va ) ∩ ΓX (vb )] = {va , vb } – E ∩ ΓX [ΓX (v a ) ∩ ΓX (v b )] = ∅ – E ∩ ΓX [ΓX (va ) ∩ ΓX (v b )] = {va } – E ∩ ΓX [ΓX (v a ) ∩ ΓX (vb )] = {vb } • xa ∪ xb 6= ∅, |χa | ≤ 2δB dB and |χb | ≤ 2δA dA . Lemma 23 (Lemma 7 of [20]). For an error E ⊆ V such that 0 < |E| ≤ min(γA nA , γB nB ), there exists a critical generator for E. Lemma 24 (Modified version of Lemma 8 of [20]). Let r and β = β0 be defined as in Definition 10. Let E ⊆ V be a reduced error such that 0 < |E| ≤ r min(γA nA , γB nB ) then there exists an error F ∈ F with |σX (E)| − |σX (E ⊕ F )| ≥ βdB |F |. Proof. For convenience, we use a notion of reduced cardinality. Given an error E ⊆ V = A2 ⊎B 2 , kEk is defined by: kEk = |E ∩ A2 | |E ∩ B 2 | + . dB dA It is straightforward to check that for E ⊆ V : dA kEk ≤ |E| ≤ dB kEk. (10) Let ER be the error of E + CZ ⊥ which minimizes kER k. The size of ER satisfies: 0 < |ER | ≤ dB kER k ≤ dB kEk ≤ dB |E| ≤ min(γA nA , γB nB ). dA We exploit Lemma 23 applied to ER and prove that if we flip F = xA ⊎ xB in the generator promised by the lemma then |σX (E)| − |σX (E ⊕ F )| ≥ βdB |F |. We use the notations of the proof of Lemma 8 of [20]: x = kxa k = |xa |/dB y = kxb k = |xb |/dA z = kχa k = |χa |/dB t = kχb k = |χb |/dA x = 1 − x − z = kxa k = |xa |/dB y = 1 − y − t = kxb k = |xb |/dA For F = xA ⊎ xB , we have kF k = x + y and: |σX (E)| − |σX (E ⊕ F )| ≥ [|xa ||xb | + |xa ||xb | − |xa ||χb | − |xb ||χa |] = dA dB [xy + xy − xt − yz] = dA dB [x(1 − y − t) + (1 − x − z)y − xt − yz] = dA dB [x + y − 2xy − 2xt − 2yz] ≥ dA dB [x + y − 2xy − 4xδA − 4yδB ] = dA dB [x(1 − 4δA ) + y(1 − 4δB ) − 2xy] Moreover 0 < x + y because xA ⊎ xB 6= ∅ and x + y ≤ 1 because ER minimizes kER k over E + CZ ⊥ . 1 Let f (x, y) = [x(1 − 4δA ) + y(1 − 4δB ) − 2xy] defined for x, y such that: x+y 0 ≤ x ≤ 1, 0 ≤ y ≤ 1, 19 0 < x + y ≤ 1. The function analysis below shows that f (x, y) ≥ β/r and thus Lemma 23 holds using eq. (10): |σX (E)| − |σX (E ⊕ F )| ≥ dA dB f (x, y)kF k ≥ βdB |F |.   The remaining point is to show that f (x, y) ≥ β/r = 12 1 − 4(δA + δB + (δB − δA )2 ) : The partial derivative of f with respect to x is equal to: y ∂f (x, y) = [4(δB − δA ) − 2y] . ∂x (x + y)2 • If y ≤ 2(δB − δA ) then x 7→ f (x, y) is non-decreasing and thus: f (x, y) ≥ f (0, y) = 1 − 4δB ≥ β/r. • Otherwise, x 7→ f (x, y) is non-increasing and thus: f (x, y) ≥ f (1 − y, y) = 2y 2 + y(4δA − 4δB − 2) + 1 − 4δA . f (x, y) is then lower bounded by β/r the minimum of y 7→ f (1 − y, y) on [0, 1] reached for y = 1/2 + δB − δA . rβ min(γA nA , γB nB ) and run Algorithm 2 1 + β Li−1  with parameter β on E0 . Set Ei = E0 ⊕ Êi = E0 ⊕ k=0 Fi for i ∈ J1; f K, where f is the number of steps of the algorithm (the algorithm terminates because the syndrome weight decreases strictly at each step and must remain non negative). Since |σX (Ei )| − |σX (Ei+1 )| ≥ βdB |Fi |, we have: Proof of Proposition 11. Let E0 ⊆ V with |E0 | ≤ βdB f −1 X i=0 |Fi | ≤ f −1 X i=0 |σX (Ei )| − |σX (Ei+1 )| = |σX (E0 )| − |σX (Ef )| ≤ dB |E0 |, and: |Ef | = E0 ⊕ f −1 M i=0 Fi ! ≤ |E0 | + f −1 X i=0 |Fi | ≤ 1+β |E0 | ≤ r min(γA nA , γB nB ). β Let ER be the reduced error of Ef + CZ ⊥ then |ER | ≤ |Ef | ≤ r min(γA nA , γB nB ) and Algorithm 2 stops on sf = σX (Ef ) = σX (ER ). We conclude by Lemma 24 that |ER | = 0 and therefore the error is corrected. 20 B.2 Results for percolation We start by stating useful bounds on binomial coefficients. Lemma 25. For k, n integers, we have:   n ≤ 2nh(k/n) , k where h(x) = −x log2 (x) − (1 − x) log2 (1 − x) is the binary entropy function. Lemma 26 (Chernoff bound for the binomial distribution). Let p ∈ [0; 1], s ∈ we have: X s k pm (1 − p)s−m ≤ 2−sD( s kp) . m N and k ≥ sp, then m≥k Lemma 27 gives an upper bound on the number of connected sets of size s in a graph with an upper bound on the degree. Note that for a rooted tree of degree bounded by d, each vertex which is not the root has at most d − 1 sons. Using this remark and results from [23], Lemma 27 can be proved following the proof of [28]. Lemma 27 ([23],[28]). Let G = (V, E) be a graph of degree bounded byd ≥ 2. For  s ≥ 1, the s(d − 1) d . number of connected sets of size s satisfies |Cs (G)| ≤ |V | s[s(d − 2) + 2] s − 1 Proof. Let T (s) be the set of labelled rooted trees with s vertices such that the maximum outdegree of the root is d and the maximum outdegree of the other nodes is d − 1. An element of T (s) is a directed graph where the root has at most d sons and the other vertices have at most d − 1 sons. The directed edges whose head is some node v are injectively labeled with labels in J1; dK if v is the root and with labels in J1; d − 1K if v is not the root. Note that in the underlying undirected graph, a node which is not the root can have d neighbours. Using Ref. [23], we have s(d−1) d where R(a, b, c) are the Raney numbers. |T (s)| = R(d − 1, s − 1, d) := s(d−2)+2 s−1 From the graph G we construct the oriented graph G0 where each non-oriented edge of G has been replaced by two opposite oriented edges. Similarly than for the trees, we fix some labelling of G0 : the directed edges whose head is some node v are injectively labeled with labels in J1; deg+ (v)K where deg+ (v) is the outdegree of v. Now let v ∈ V and let Cs (v) be the set of connected sets X ∈ Cs (G) with v ∈ X. For a given X ∈ Cs (v), there is at least one spanning tree T0 of X. We then get a labelled rooted tree T ∈ T (s) by fixing v as the root and fixing the labelling of T using the labelling of T0 in G0 . Note that the labelling for T is not exactly the same labelling than T0 since the labels in T are in J1; d − 1K (for edges whose head is not the root) whereas the label d is allowed for T0 . The key point is that when we consider a vertex v1 6= v in T0 then this vertex has a father v0 . Let i be the label in T0 of the oriented edge from v1 to v0 and j be the label in T0 of another edge whose head is v1 . The label in T of this edge is then j if j < i and j − 1 if j > i. Conversely given T ∈ T (s), T can be obtained by this procedure using at most P one connected set X ∈ Cs (v). Thus |Cs (v)| ≤ |T (s)|. When we consider the sum v∈V |Cs (v)|, each connected set of Cs (G) is counted s times. Therefore,   d s(d − 1) 1X |Cs (v)| ≤ |V | . |Cs (G)| = s s[s(d − 2) + 2] s−1 v∈V 21 Corollary 28. Let G = (V, E) be a graph of degree bounded by d ≥ 2. For s ≥ 1, the number of  d−2 1 connected sets of size s satisfies |Cs (G)| ≤ |V |K(d)s where K(d) = (d − 1) 1 + d−2 . Proof. From Lemma 27, we have:   d s(d − 1) |Cs (G)| ≤ |V | s[s(d − 2) + 2] s − 1   s(d − 1) d = |V | [s(d − 2) + 1][s(d − 2) + 2] s   s(d − 1) ≤ |V | since d ≥ 2 and s ≥ 1 s ≤ |V |2s(d−1)h(1/(d−1))  d−2 !s 1 = |V | (d − 1) 1 + . d−2 We now prove the improved bound (5) on the probability of E to be a connected α-subset of size ≥ t. The calculation is similar to that in [19, Theorem 3] who considered 21 -percolation in their proof. Proof of Eq. (5). For v ∈ V, X ⊆ V, E ⊆ V and s ∈ N, let us define: Cs (v) = {X ∈ Cs (G) : v ∈ X}, ∂X = Γ(X) \ X, the boundary of X, A(E, α, s, v) = {X ∈ Cs (v) : |X ∩ E| ≥ α|X|, ∂X ∩ E = ∅}. In other words, the sets A(E, α, s, v) are the connected sets E containing v such that |X ∩ E| ≥ α|X| (and whose boundary does not intersect E). The reason for the second condition in the definition of A(E, α, s, v) is to capture the idea that the sets X ∈ A are of maximum size: indeed, increasing the size of a set X ∈ A(E, α, s, v) would only decrease the fraction of vertices in X ∩ E. By induction on the size |X| of a connected set X ⊆ V , it is straightforward to show that |∂X| ≤ (d − 2)|X| + 2. By definition, we have: P[MaxConnα (E) ≥ t] = P [∃s ≥ t, ∃X ∈ Cs (G) : |X ∩ E| ≥ α|X|] = P [∃s ≥ t, ∃X ∈ Cs (G) : |X ∩ E| ≥ α|X|, ∂X ∩ E = ∅] = P [∃s ≥ t, ∃v ∈ V : A(E, α, s, v) 6= ∅] XX ≤ P [A(E, α, s, v) 6= ∅] . s≥t v∈V Note that we used the fact that if there exists X ∈ Cs (G) with s ≥ t such that |X ∩ E| ≥ α|X|, then we can construct X ′ by repeatedly adding vertices in ∂X ∩ E until we cannot do so. Thus, X ′ satisfied ∂X ∩ E = ∅. In addition, we have |X ′ ∩ E| − |X ∩ E| = |X ′ | − |X| is the number of vertices added in this process, which implies that |X ′ ∩ E| ≥ α|X ′ |. For v ∈ V and s ∈ , we have: X X s P [A(E, α, s, v) 6= ∅] ≤ pm (1 − p)s−m+|∂X| . m N X∈Cs (v) m≥αs 22 Note furthermore that for any p, we have P [A(E, 1, s, v) 6= ∅] = For p < 1 d−1 , X X∈Cs (v) ps (1 − p)|∂X| ≤ 1. (11) we have: P [A(E, α, s, v) 6= ∅] X s X ≤ (1 − p)|∂X| pm (1 − p)s−m m m≥αs X∈Cs (v) X |∂X| −sD(αkp) ≤ (1 − p) 2 by Lemma 26 X∈Cs (v) !|∂X| 1−p 2−sD(αkp) 1 |∂X| = (d − 1)s (1 − ) 1 s (d − 1) d−1 1 − d−1 X∈Cs (v) !(d−2)s+2 |∂X| X  1 s  1 1−p −sD(αkp) s 1− 2 (d − 1) ≤ 1 d−1 d−1 1 − d−1 X∈Cs (v)     d−1 s (1 − p)(d − 1) 2 d−2 −D(αkp) (d − 1) ≤ from Eq.(11) (1 − p) 2 d−2 (d − 2)d−2   d−1 2 s q = d−2 X since p < 1 where we defined q = (1 − p)d−1−α pα 2h(α)+(d−1)h( d−1 ) . The main improvement compared to the local stochastic bound is the factor (1 − p)d−1−α . Summing over s ≥ t and v ∈ V yields: X X  d − 1 2 qs P[MaxConnα (E) ≥ t] ≤ d−2 s≥t v∈V   d − 1 2 qt ≤ |V | . d−2 1−q 1 d−2 ) is Lemma 29. For α ∈ (0, 1], the function q : p 7→ (1 − p)d−1−α pα 2h(α) (d − 1)(1 + d−2 α α increasing in the interval [0, d−1 ] and it satisfies q(0) = 0 and q( d−1 ) ≥ 1. Consequently, there exists piid in this interval such q(piid ) = 1. Proof. It is simple to verify that q is increasing. Moreover, we have q(0) = 0 and   d−1−α  α d−2 α α 1 α h(α) )= 1− 2 (d − 1) 1 + q( d−1 d−1 d−1 d−2  d−1−α  α α α (d − 1)d−1 = 1− 2h(α) d−1 d−1 (d − 2)d−2 d−1−α (d − 1 − α) αα α−α (1 − α)−(1−α) = (d − 2)d−2 ≥1, where we used the fact that α ∈ (0, 1]. 23 1 d−1 The following proposition gives an upper bound on the value of p for which we have only small connected components. This shows basically that the value in Eq. (3) of Theorem 17 can be −h(α) 1 at most improved by a factor of ( 2 e ) α . Proposition 30. Let d ≥ 3 be an integer, α ∈ (0, 1], ℓ be the smallest integer ℓ > α1 and 1 ∗, p > (d−1) ℓ . Then there exists a constant κ (only depending on d, α, p) such that for any c ∈ there exists and a family of graphs Gk on Nk vertices (with Nk → ∞) such that if E contains each vertex independently with probability p, we have N lim P[MaxConnα (E) ≥ κ|Nk |1−1/c ] = 1 . k→∞ Proof. We define Gk to be a complete (d − 1)-tree of height ck. Note that every vertex has degree ck −1 . We write V for the set of vertices of the at most d and the number of vertices is Nk = (d−1) d−2 graph Gk and Li for the set of vertices at depth i, where the root is at depth 0. For every such vertex v ∈ L(c−1)k , we define the event:   1 Ev = ∃w(c−1)k , . . . , wck−1 : w(c−1)k = v, wi+1 is a child of wi and |E ∩ {w(c−1)k , . . . , wck−1 }| ≥ k . ℓ (12) We define Pv = ∅ if Ev does not hold and if it does hold, then Pv = {w(c−1)k , . . . , wck−1 }, where wi are as in (12). We then define the (random) subset S of vertices as (c−1)k−1 S= [ i=0 Li ∪ [ Pv . v∈L(c−1)k The claim is then that, provided k is large enough, with high probability, S is an α-subset of E and it is of size Ω(|Nk |1−1/c ). To see this, observe that 1 |E ∩ S| ≥ |{v ∈ L(c−1)k : Ev holds}| k ℓ   1 = αk|{v ∈ L(c−1)k : Ev holds}| + − α k|{v ∈ L(c−1)k : Ev holds}| ℓ On the other hand (d − 1)(c−1)k − 1 . d−2 Thus, in order to show that S is an α-subset of E, it suffices to show that for large enough k, we have with high probability   (d − 1)(c−1)k − 1 1 − α k|{v ∈ L(c−1)k : Ev holds}| ≥ α . ℓ d−2 |S| = k|{v ∈ L(c−1)k : Ev holds}| + Now to prove this, it suffices to show that for any v ∈ L(c−1)k , P[Ev ] ≥ τ with τ > 0 a constant independent of k and c. In fact, once we have that, |{v ∈ L(c−1)k : Ev holds}| has a binomial distribution with parameters ((d − 1)(c−1)k , ≥ τ ) and the inequality will follow easily for large enough k. Note also the inequality P[Ev ] ≥ τ also implies the claimed lower bound on the size of S. Now to lower bound the probability of Ev , we look at an even more restricted event. Namely, we consider the event that w(c−1)k = v ∈ E, and there exists a descendent w(c−1)k+ℓ ∈ L(c−1)k+ℓ of w(c−1)k that is in E, and there is a descendent w(c−1)k+2ℓ ∈ L(c−1)k+2ℓ of w(c−1)k+1 that is in E, and all the way until we reach the bottom of the tree. Note that the probability that such a path exists is lower bounded by the probability of survival of the branching process with offspring distribution binomial with parameters ((d − 1)ℓ , p). But as p(d − 1)ℓ > 1, the probability of survival is > 0 and we obtain the desired result. 24 Acknowledgments We would like to thank Benjamin Audoux, Alain Couvreur, Anirudh Krishna, Vivien Londe, JeanPierre Tillich and Gilles Zémor for many fruitful discussions on quantum codes as well as Daniel Gottesman for answering our questions about [13]. AG and AL acknowledge support from the ANR through the QuantERA project QCDA. References [1] Joan Adler. Bootstrap percolation. Physica A: Statistical Mechanics and its Applications, 171(3):453–470, 1991. [2] Dorit Aharonov and Michael Ben-Or. Fault-tolerant quantum computation with constant error. In Proceedings of the twenty-ninth annual ACM symposium on Theory of computing, pages 176–188. ACM, 1997. [3] Sergey Bravyi and Barbara Terhal. A no-go theorem for a two-dimensional self-correcting quantum memory based on stabilizer codes. New Journal of Physics, 11(4):043029, 2009. [4] A Robert Calderbank and Peter W Shor. Good quantum error-correcting codes exist. Physical Review A, 54(2):1098, 1996. [5] Nicolas Delfosse and Naomi H. Nickerson. Almost-linear time decoding algorithm for topological codes. arXiv preprint arXiv:1709.06218, 2017. [6] Nicolas Delfosse and Gilles Zémor. Quantum erasure-correcting codes and percolation on regular tilings of the hyperbolic plane. In Information Theory Workshop (ITW), 2010 IEEE, pages 1–5. IEEE, 2010. [7] Nicolas Delfosse and Gilles Zémor. Upper bounds on the rate of low density stabilizer codes for the quantum erasure channel. Quantum Information & Computation, 13(9&10):0793– 0826, 2013. [8] Eric Dennis, Alexei Kitaev, Andrew Landahl, and John Preskill. Topological quantum memory. Journal of Mathematical Physics, 43(9):4452–4505, 2002. [9] Jack Edmonds. Maximum matching and a polyhedron with 0, 1-vertices. Journal of Research of the National Bureau of Standards B, 69(125-130):55–56, 1965. [10] Michael H Freedman, David A Meyer, and Feng Luo. Z2-systolic freedom and quantum codes. Mathematics of quantum computation, Chapman & Hall/CRC, pages 287–320, 2002. [11] Robert Gallager. Low-density parity-check codes. IRE Transactions on information theory, 8(1):21–28, 1962. [12] Daniel Gottesman. Stabilizer codes and quantum error correction. quant-ph/9705052, 1997. arXiv preprint [13] Daniel Gottesman. Fault-tolerant quantum computation with constant overhead. arXiv preprint arXiv:1310.2984, 2013. [14] Larry Guth and Alexander Lubotzky. Quantum error correcting codes and 4-dimensional arithmetic hyperbolic manifolds. Journal of Mathematical Physics, 55(8):082202, 2014. 25 [15] Matthew B Hastings. Decoding in hyperbolic spaces: Ldpc codes with linear rate and efficient error correction. arXiv preprint arXiv:1312.2546, 2013. [16] Svante Janson. On percolation in random graphs with given vertex degrees. Electronic Journal of Probability, 14:86–118, 2009. [17] Isaac Hyun Kim. Quantum codes on Hurwitz surfaces. PhD thesis, Massachusetts Institute of Technology, 2007. [18] A Yu Kitaev. Fault-tolerant quantum computation by anyons. Annals of Physics, 303(1):2– 30, 2003. [19] Alexey A Kovalev and Leonid P Pryadko. Fault tolerance of quantum low-density parity check codes with sublinear distance scaling. Physical Review A, 87(2):020304, 2013. [20] Anthony Leverrier, Jean-Pierre Tillich, and Gilles Zémor. Quantum expander codes. In Foundations of Computer Science (FOCS), 2015 IEEE 56th Annual Symposium on, pages 810–824. IEEE, 2015. [21] Vivien Londe and Anthony Leverrier. Golden codes: quantum LDPC codes built from regular tessellations of hyperbolic 4-manifolds. arXiv preprint arXiv:1712.08578, 2017. [22] Russell Lyons. Random walks, capacity and percolation on trees. The Annals of Probability, pages 2043–2088, 1992. [23] Chin Hee Pah and Mohamed Ridza Wahiddin. Combinatorial interpretation of raney numbers and tree enumerations. Open Journal of Discrete Mathematics, 5(01):1, 2015. [24] Tom Richardson and Ruediger Urbanke. Modern coding theory. Cambridge University Press, 2008. [25] Michael Sipser and Daniel A Spielman. Expander codes. IEEE Transactions on Information Theory, 42(6):1710–1722, 1996. [26] Andrew M Steane. Error correcting codes in quantum theory. Physical Review Letters, 77(5):793, 1996. [27] Jean-Pierre Tillich and Gilles Zémor. Quantum ldpc codes with positive rate and minimum distance proportional to the square root of the blocklength. IEEE Transactions on Information Theory, 60(2):1193–1202, 2014. [28] Ryuhei Uehara et al. The number of connected components in graphs and its applications. Manuscript. URL: http://citeseerx. ist. psu. edu/viewdoc/summary, 1999. [29] David S Wang, Austin G Fowler, Ashley M Stephens, and Lloyd Christopher L Hollenberg. Threshold error rates for the toric and surface codes. arXiv preprint arXiv:0905.0531, 2009. [30] Gilles Zémor. On Cayley Graphs, Surface Codes, and the Limits of Homological Coding for Quantum Error Correction. In IWCC, pages 259–273. Springer, 2009. 26
7cs.IT
Expresso: A User-Friendly GUI for Designing, Training and Exploring Convolutional Neural Networks Ravi Kiran Sarvadevabhatla [email protected] R. Venkatesh Babu [email protected] arXiv:1505.06605v2 [cs.CV] 18 Oct 2015 Video Analytics Lab, Supercomputer Education and Research Centre Indian Institute of Science Bangalore, INDIA - 560012 ABSTRACT With a view to provide a user-friendly interface for designing, training and developing deep learning frameworks, we have developed Expresso, a GUI tool written in Python. Expresso is built atop Caffe, the open-source, prize-winning framework popularly used to develop Convolutional Neural Networks. Expresso provides a convenient wizard-like graphical interface which guides the user through various common scenarios – data import, construction and training of deep networks, performing various experiments, analyzing and visualizing the results of these experiments. The multi-threaded nature of Expresso enables concurrent execution and notification of events related to the aforementioned scenarios. The GUI sub-components and inter-component interfaces in Expresso have been designed with extensibility in mind. We believe Expresso’s flexibility and ease of use will come in handy to researchers, newcomers and seasoned alike, in their explorations related to deep learning. Figure 1: Expresso’s main screen Categories and Subject Descriptors I.5.1 [Pattern Recognition]: Applications– Computer Vision; D.2.2 [Software Engineering]: Design Tools and Techniques—software libraries; I.5.1 [Pattern Recognition]: Models – Neural Nets General Terms Design, Experimentation Keywords Open Source, Computer Vision, Neural Networks, Parallel Computation, Graphical User Interface Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. To copy otherwise, to republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Copyright 20XX ACM X-XXXXX-XX-X/XX/XX ...$15.00. 1. INTRODUCTION In the recent years, deep learning has established itself as a disruptive framework, raising the state-of-the-art for challenging problems related to signal recognition and analysis [7]. In particular, Convolutional Neural Networks (CNNs), a category of deep learning networks, have shown impressive performance on challenging image recognition datasets [2, 4, 6]. The rapid adoption of CNNs has been made possible to a large extent by the availability of ready-to-use software for designing CNNs and related data processing. Of these softwares, the Caffe framework [5] is one of the most popular. The detailed nature of source and usage documentation along with an active user forum has contributed immensely to Caffe’s popularity. The fact that Caffe was the prize-winning entry in the competitive ACMMM–2014 Open Source Software Competition further promotes its credibility. The Caffe framework is primarily command-line based. To supplement Caffe’s functionality and expand its ease of use, particularly for newcomers, we have developed Expresso. Expresso is a GUI tool written in Python which uses Caffe as the back-end framework for CNNs. The project page (http: //val.serc.iisc.ernet.in/expresso) provides an overview of Expresso’s main features and information regarding installation and usage. Figure 2: Using the intelli-sense editor for creating and modifying layers of a deep net Figure 3: Viewing the layers of a pre-trained deep net. The net’s layers are color-coded by type. 2. browser is also provided which can be used for a quick preview of the imported data. In addition, the imported data can also be exported to other formats. Currently, .mat and HDF5 are supported. A common requirement involves split of data into training and testing sets. This functionality is also provided in the Data view. Another interesting feature is that the back-end framework related to Data view also features a parser. This parser can be utilized to quickly extend the import interface to load data in formats not provided yet in Data view. SALIENT FEATURES OF EXPRESSO • Expresso provides a convenient wizard-like interface to contextually guide the user during common scenarios such as data import, design and training of CNNs, performing experiments and visualizing their results (Figure 1). The wizard interface avoids the cognitive load involved in switching between the GUI and reading documentation from another interface (e.g. PDF file or browser window). • Expresso’s multi-threaded architecture enables asynchronous, concurrent execution of tasks in the aforementioned scenarios. • Important events that occur related to various tasks (task initialization, progress and termination) are conveyed to users via a notification system similar to that present in social media user-interfaces (Figure 1). • The modular nature of GUI sub-components and intercomponent interfaces in Expresso have been designed with ease of extensibility in mind. 3. THE EXPRESSO FRAMEWORK Expresso operates primarily as four views - Data, Net, Train, Experiment. These “views” reflect the predominant use-case scenarios involving CNNs. In Expresso’s GUI, each view and associated interface elements are rendered in a uniform color livery for ease of visual grouping (Figures 1,3,4). Next, we describe these views. 3.1 Data view This view is meant for import of input data and typically forms the first step for most tasks. The import interface is quite flexible and enables data import in a variety of input formats1 – starting from the basic “all-images-in-the-folder” up to a sophisticated, high-capacity format such as HDF5. Auxiliary information typically associated with data such as class labels can also be concurrently imported. A summary of salient details related to the imported data are presented in a list-based view upon import. A rudimentary image 1 Currently, Text,LevelDB,.mat,HDF5,Folder formats are supported. 3.2 Net view The Net view is utilized for constructing deep neural network architectures (nets) – either from scratch or by modification of existing nets. The net construction phase requires specification of a training ‘prototxt’ file whose contents are interpreted by Caffe as the specification for network architecture. A related text file, usually referred to as the ‘deploy’ prototxt file is associated with the usage of the network for testing and other experimentation. Optionally, a solver file is also present which contains various auxiliary parameter settings. The purpose of the Net view is to generate all the files required to specify a network in Caffe-compatible format. In Net view, two net construction options exist. 3.2.1 Constructing the net from scratch Once the option is chosen to construct the net from scratch, the layers which are associated with data are added automatically. Network layers of various common types can be subsequently added below the data layers. The back-end framework automatically calculates the sizes of responses for the resulting layers. The settings for each layer can be edited using a contextual smart-edit interface. The various properties of a layer are typically specified in programming-language style ‘scopes’. The smart-edit interface automatically provides layer description options depending on the position of the edit cursor within the layer description scope (see Figure 2). As each layer is completed, the net design so far can be viewed. The graphical nature of both this process and the smart-edit interface provides an easy-to-use approach for CNN net design. At the end of the process, the resulting net, typically called the ‘training net’ forms the basis for the related ‘de- ploy net’ prototxt file and therefore, the latter is initialized as a slightly modified copy of the ‘training net’ prototxt file. All the aforementioned files, related to the newly constructed net can be saved into a net configuration. This freshly created net configuration can be trained by following the steps detailed in Training view (Section 3.3). 3.2.2 Create modified version of an existing net Alternately, if the objective is to create a modified version of an existing net, a net needs to be chosen from the list of available net configurations. Making this choice pre-loads the associated prototxt files (train, deploy and optionally, the solver). Having done so, the subsequent modifications to the net can be done as described earlier. A helpful feature of the Net view is that the layers of a net are displayed in color-coded fashion for ease of visualization (see Figure 3). Another important feature is that the created nets are Caffe-compatible files. Therefore, the files associated with a net configuration (train prototxt file, deploy prototxt file etc.) can be utilized directly with Caffe, outside of Expresso as well. 3.3 Training view The Training view is utilized to train the nets with userspecified data. The work flow proceeds as follows : 1. Select a net for training : This choice is made from a list of previously created net configurations whose location information is cached. Alternately, unlisted nets can be added for faster look-up in future sessions. 2. Set training parameters : If the net configuration does not have a solver, one is defined at this point. The solver is typically associated with a number of associated parameters. These parameters are set next, with an option for modifying and saving them if the solver already exists (see Figure 4). 3. Data association : The data to be used for training is chosen next. 4. Choosing net vs external training : Two kinds of training are commonplace with CNNs. The first kind involves training the net from scratch. The second kind involves extracting features obtained by passing training data through a pre-trained net and tapping the output at pre-specified layer(s) of the net – a task which can be done from the Experiment view. The extracted features are used to train an external classifier such as a Support Vector Machine (SVM) [1, 3]. If such a choice is made, the associated parameters (type of SVM kernel, related parameter settings) are specified. 5. Commence training : Pressing the ‘Finish’ button in this step kick starts the net training process. A notification panel provides information related to progress of training such as number of epochs completed, estimated time to completion and training error plots. At the end of training, a model file is created regardless of training choice (net-based or external-classifier-based). An important feature in the Train view is the ability to stop a particular training task. This is particularly useful if the training is not proceeding satisfactorily (e.g. too slowly or has an unacceptable loss function magnitude). Figure 4: Interface to upload and adjust training parameters in Train view. 3.4 Experiment view The Experiment view can be used for three important tasks, each of which is described below. 3.4.1 Feature extraction using pre-trained nets When data is provided to a pre-trained CNN, the corresponding output from CNN layers has been shown to act as informative and discriminative feature representation [4] of the data. To facilitate feature extraction, the user is asked to first choose a pre-trained net and then choose the layer(s) of interest. Having made the choice, the user then selects the data to be provided to the net. The subsequent step of feature extraction results in feature data which can be stored in a variety of data formats, such as the ones compatible with the popular libsvm software [1]. 3.4.2 Visualizing feature data Features from certain layers of CNNs tend to preserve and highlight various spatial aspects of input data [2]. To help visualize such features, an option is provided wherein features extracted previously can be selected. Such visualization can lead to a better understanding of both the data and evolution of features at various layers of the net (see Figure 5). 3.4.3 Testing pre-trained models To determine the performance of the CNN, previously unseen data is processed by a trained CNN and the results are compared against ground truth. For this process, the net configuration is chosen first. Subsequently, the test data is selected. Once the testing concludes, various standard performance metrics such as accuracy (global and per-class) and the confusion matrix are displayed. As with Training view, testing using external classifiers (SVM) can also be performed on features extracted from CNN layers. 4. ADDITIONAL NOTES Expresso is written in Python and has been developed on machines running Linux Ubuntu 14.04. The BSD-licensed source code for Expresso can be accessed on Github at https: //github.com/val-iisc/expresso. Expresso’s project page (http://val.serc.iisc.ernet.in/expresso) provides instructions and information regarding installation and usage. An illustrated set of tutorials have also been provided with [6] A. Krizhevsky, I. Sutskever, and G. E. Hinton. Imagenet classification with deep convolutional neural networks. In NIPS, 2012. [7] T. A. Tveit, T. Morland, and T. B. Rost. Deeplearning.university : An annotated deep learning bibliography. http://memkite.com/deep-learning-bibliography/. Figure 5: Visualizing layer features of a deep network Expresso in text and narrated video formats. These tutorials, covering typical use scenarios, assist the user in gaining familiarity with Expresso’s functionality. We also note that since Expresso has been built atop Caffe, future improvements and extensions to the latter are readily conferred to Expresso. 5. CONCLUSION In this paper, we have presented a brief overview of the first version of Expresso – a GUI tool for designing, training and using Convolutional Neural Networks. In the spirit of open-source movement, we hope that users will not only use the tool, but also extend it, thereby making Expresso the go-to GUI based tool for exploring deep learning. 6. ACKNOWLEDGEMENT We gratefully acknowledge the support of NVIDIA Corporation for their donation of K40 GPU as a hardware grant. We would like to thank the members of Video Analytics Lab, IISc (http://val.serc.iisc.ernet.in) for their feedback during the development of Expresso. Finally, we would like to acknowledge the creators of Caffe for providing the shoulders of giants on which we stand. 7. REFERENCES [1] C.-C. Chang and C.-J. Lin. Libsvm: A library for support vector machines. ACM Trans. Intell. Syst. Technol., 2(3):27:1–27:27, May 2011. [2] J. Donahue, Y. Jia, O. Vinyals, J. Hoffman, N. Zhang, E. Tzeng, and T. Darrell. Decaf: A deep convolutional activation feature for generic visual recognition. CoRR, abs/1310.1531, 2013. [3] R. Fan, K. Chang, C. Hsieh, X. Wang, and C. Lin. LIBLINEAR: A library for large linear classification. Journal of Machine Learning Research, 9:1871–1874, 2008. [4] R. Girshick, J. Donahue, T. Darrell, and J. Malik. Rich feature hierarchies for accurate object detection and semantic segmentation. In CVPR, 2014. [5] Y. Jia, E. Shelhamer, J. Donahue, S. Karayev, J. Long, R. Girshick, S. Guadarrama, and T. Darrell. Caffe: Convolutional architecture for fast feature embedding. In ACMMM, 2014.
9cs.NE
High-dimensional Linear Regression for Dependent Observations with Application to Nowcasting Yuefeng Han and Ruey S. Tsay arXiv:1706.07899v2 [math.ST] 15 Jul 2017 University of Chicago July 18, 2017 Abstract In the last few years, an extensive literature has been focused on the `1 penalized least squares (Lasso) estimators of high dimensional linear regression when the number of covariates p is considerably larger than the sample size n. However, there is limited attention paid to the properties of the estimators when the errors or/and the covariates are serially dependent. In this study, we investigate the theoretical properties of the Lasso estimators for linear regression with random design under serially dependent and/or non-sub-Gaussian errors and covariates. In contrast to the traditional case in which the errors are i.i.d and have finite exponential moments, we show that p can at most be a power of n if the errors have only polynomial moments. In addition, the rate of convergence becomes slower due to the serial dependencies in errors and the covariates. We also consider sign consistency for model selection via Lasso when there are serial correlations in the errors or the covariates or both. Adopting the framework of functional dependence measure, we provide a detailed description on how the rates of convergence and the selection consistencies of the estimators depend on the dependence measures and moment conditions of the errors and the covariates. Simulation results show that Lasso regression can be substantially more powerful than the mixed frequency data sampling regression (MIDAS) in the presence of irrelevant variables. We apply the results obtained for the Lasso method to now-casting with mixed frequency data for which serially correlated errors and a large number of covariates are common. The empirical analysis shows that the Lasso procedure outperforms the MIDAS in both forecasting and now-casting. CMS2000 Subject Classification: Primary 62J05; Secondary 62M10. Keywords: high-dimensional time series, Lasso, Consistency, Model selection, Forecasting, Nowcasting, Mixed-frequency data. 1 1 Introduction During the past two decades, there have been significant developments in high-dimensional linear regression analysis. Consider the usual regression setup for the response variable yi and the covariate vector xi , yi = xTi β + ei , 1 ≤ i ≤ n, (1) where β ∈ Rp are unknown coefficients to be estimated, ei is the error term, and xTi denotes the transpose of xi . Denote the dimension of xi by p. In matrix notation, we can write the model as Y = Xβ+e, where Y is the n×1 outcome vector, X is the n×p design matrix, and e is the n×1 error vector. Under certain sparsity conditions on β, a great deal of attention has been focused on the `1 penalized least squares (Lasso) estimator of parameters when the number of variables p can be much larger than the sample size n; see Efron et al. (2004), Zhao and Yu (2006), and Meinshausen and Yu (2009), among others. Other related approaches include the Dantzig-selector introduced by Candes and Tao (2007), the adaptive Lasso of Zou (2006), the Group Lasso proposed by Yuan and Lin (2006) and the SCAD estimator of Fan and Li (2001), among others. Theoretical properties of those estimators have been established in the literature under the independence assumption; see, for example, Bickel et al. (2009) and Bühlmann and Van De Geer (2011). Here we focus on the Lasso estimator, defined as   1 2 β̂ = arg min |Y − Xβ|2 + λ |β|1 , (2) β 2 where λ ≥ 0 is a tuning parameter, controlling the level of sparsity in β̂. Much of the available research dedicated to the Lasso problem deals with the case of large p and small n when the design matrix is static and the errors are independent and identically distributed (i.i.d.) random variables. On the other hand, in many real applications, xi consists of stochastic random variables that might be dynamically dependent or ei is serially dependent or both. Despite a considerable amount of recent work on Lasso estimators, there has been very limited research on theoretical properties of the estimates when the observations are dependent. Wang et al. (2007) proposed a Lasso estimator for the regression model with autoregressive errors. Gupta (2012) investigated Lasso estimator for weakly dependent errors. Both papers concentrate on the case when n is greater than p. More recently, Basu and Michailidis (2015) investigated theoretical properties of Lasso estimators with a random design for high-dimensional Gaussian processes. Kock and Callot (2015) established oracle inequalities of the Lasso for Gaussian errors in stationary vector autoregressive models. Wu and Wu (2016) analyzed Lasso estimator with a fixed design matrix and assumed that a restricted eigenvalue condition is satisfied. Medeiros and Mendes (2016) studied the asymptotic properties of the adaptive Lasso when the errors are nonGaussian and may be conditionally heteroskedastic. The goal of this paper is to investigate the limiting properties of Lasso estimators of model (1) in the presence of serial dependence in both the covariate vector xi and the errors. In practice, many important macroeconomic variables are not sampled at the same frequency. For example, gross domestic product (GDP) data are available quarterly, industrial production data are monthly, and most interest rate data are available daily. Analyzing such data jointly is referred to as mixed-frequency data analysis. In the econometrics literature, Ghysels et al. (2004) proposed a mixed-data sampling (MIDAS) approach to analyze mixed-frequency data. In particular, they use 2 newly available high-frequency data to improve the prediction of a lower-frequency macroeconomic variable of interest and refer to such predictions as now-casting. Consider, for example, the problem of predicting quarterly GDP growth rate yn+1 at the forecast origin i = n. Here the time interval is a quarter. Traditional forecasting uses data available at i = n to build a model, then employs the fitted model to perform prediction. In practice, some monthly and daily data become available during the quarter i = n + 1. Now-casting is to make use of such newly available monthly and daily data to update the prediction of yn+1 . Therefore, the term now-casting means taking advantages of high-frequency data within a given quarter to update the prediction of GDP growth rate of that quarter. In short, the basic principle of now-casting is the exploitation of the information which is published at higher frequencies than the target variable of interest in order to obtain an improved prediction before the official lower-frequency data becomes available. Since many high-frequency data are available, a large number of covariates are common in now-casting. Therefore, the model of Equation (1) with dependent covariates and errors is applicable to now-casting, and the Lasso method is highly relevant. The mixed-data sampling approach of Ghysels et al. (2004) has proven useful for various different forecasting and now-casting purposes. We compare the performance of Lasso regression with MIDAS in this paper. The rest of the paper is structured as follows. Section 2 defines the high dimensional dependence measure, adopting the dependence concept of Wu (2005). Section 3 deals with rates of convergence of Lasso estimators. Model selection consistency of Lasso estimators is given in Section 4, and simulation studies are carried out in Section 5. Section 6 considers some real data examples, including forecasting and now-casting applications. We begin by introducing some basic definitions. Throughout the paper, for a matrix Aq = (aij ) ∈ P 2 Rp×p , define the spectral norm ρ(A) = sup|x|≤1 |Ax| and the Frobenius norm |A|F = ij aij , infinity norm P |A|∞ = max1≤i,j≤p |aij |. For a vector a = (a1 , ..., ap )T ∈ Rp , define the vector q norm |a|q = ( pi=1 |ai |q )1/q for 1 ≤ q ≤ ∞. Let |a|∞ = max1≤i≤p |ai | and |a|0 = #{i : ai 6= 0}. For a random variable ξ ∈ Lk , denote the q-norm by kξkq = (E |ξ|q )1/q for 1 ≤ q ≤ k. For two sequences of real numbers {an } and {bn }, write an = O(bn ) if there exists a constant C such that |an | ≤ C |bn | holds for all sufficiently large n, write an = o(bn ) if limn→∞ an /bn = 0, and write an  bn if there are positive constants c and C such that c ≤ an /bn ≤ C for all sufficiently large n. Denote a ∧ b = min{a, b} and a ∨ b = max{a, b}. 2 High Dimensional Time Series Let εi , i ∈ Z, be i.i.d. random vectors and σ-field Fi = (· · · , εi−1 , εi ). In our random-design setting, we assume that in model (1) the covariate process (xi , i = 1, ..., n) is high-dimensional and weakly stationary in the form xi = (g1 (Fi ), ..., gp (Fi ))T , (3) ei = ge (Fi ), (4) and the error ei assumes the form where g1 (·), ..., gp (·) and ge (·) are measurable functions in R such that xi is well-defined. We can allow models with homogeneous or heteroscedastic errors; see Example 1 of Section 3. In the 3 homogeneous case, the covariate process (xi ) and the errors (ei ) can be independent of each other. Following Wu (2005), we define the functional dependence measure δi,q,j = xij − x∗ij δi,q,e = kei − e∗i kq q = kxij − gj (Fi∗ )kq = kgj (Fi ) − gj (Fi∗ )kq , ge (Fi∗ )kq = kei − = kge (Fi ) − ge (Fi∗ )kq (5) , (6) where the coupled process x∗ij = gj (Fi∗ ) and e∗i = ge (Fi∗ ) with Fi∗ = (..., ε−1 , ε00 , ε1 , ..., εi−1 , εi ) and ε00 , εl , l ∈ Z, being i.i.d. random elements. We shall assume short-range dependence so that ∞ X ∆m,q,j := ∆m,q,e := δi,q,j < ∞, (7) δi,q,e < ∞. (8) i=m ∞ X i=m Then for fixed m, ∆m,q,j and ∆m,q,e measure the cumulative effect of ε0 on (xij )i≥m and (ei )i≥m . We introduce the following dependence adjusted norm (DAN) kx.j kq,α = ke. kq,α = sup (m + 1)α ∆m,q,j , α ≥ 0. (9) α ≥ 0. (10) m≥0 sup (m + 1)α ∆m,q,e , m≥0 It can happen that, due to dependence, ke. kq,α = ∞ while kei kq < ∞. Since e0 = E(e0 |Fl−1 )), we have ke0 kq ≤ ∞ X kE(e0 |F−l ) − E(e0 |F−l−1 )kq = l=0 ∞ X kE(el − e∗l |F0 )k ≤ l=0 ∞ X P0 l=−∞ (E(e0 |Fl )− kel − e∗l kq = ke. kq,0 , (11) l=0 by stationarity. If ei , i ∈ Z, are i.i.d., the dependence adjusted norm ke. kq,α and the Lq norm ke0 kq are equivalent in the sense that ke0 kq ≤ ke. kq,α ≤ 2 ke0 kq . To account for the cross-sectional dependence for the p-dimensional stationary process (xi ), we define the L∞ functional dependence measure and its corresponding dependence adjusted norm ωi,q = k max |xij − x∗ij |kq , 1≤j≤p k|x. |∞ kq,α = sup (m + 1)α Ωm,q , α ≥ 0, and Ωm,q = m≥0 ∞ X ωi,q . i=m Additionally, we define Ψq,α = max kx.j kq,α 1≤j≤p and Υq,α  1/q p X = kx.j kq  , q,α j=1 where Ψq,α and Υq,α can be viewed as the uniform and the overall dependence adjusted norms of (xi ). Clearly, Ψq,α ≤ k|x. |∞ kq,α ≤ Υq,α . In this paper, we use dependence adjusted norms k|x. |∞ kq,α , Ψq,α , and Υq,α to study the limiting properties of Lasso estimators in the presence of serial dependence. These adjusted norms are more convenient than the commonly used mixing conditions for handling serial dependence in high-dimensional time series. 4 3 Convergence Rate of the Lasso estimator In this section, we present the main results on convergence rate of the Lasso estimator for dependent data. We assume the true model parameter β has at most s non-zero entries, i.e., |β|0 ≤ s. Let s = o(n). We assume also that the restricted eigenvalue assumption RE(s,3) of Bickel et al. (2009) holds for the population covariance matrix Σ = (σjk )1≤j,k≤p = (Cov(xij , xik ))1≤j,k≤p , namely, κ := min J⊆{1,...,p},|J|0 ≤s min u6=0,|uJ c |1 ≤3|uJ |1 u0 Σu/|u|22 > 0. (12) In the low dimensional regime, the consistency of β̂ relies on the assumption that sample covariance matrix converges to the population covariance matrix. The restricted eigenvalue conditions, which require that |X(β̂ − β)|2 is small only when |β̂ − β|2 is small, can be viewed as an analogous sufficient condition in high-dimensional regime (n  p). As shown in the proof of Theorem 1, the RE condition for the sample covariance matrix will hold with high probability under certain conditions. However verifying that issue is nontrivial. The following theorem shows the convergence rate of β̂ to β and the prediction error |X(β̂ −β)|22 depend on the moment condition and the temporal and cross-sectional dependence conditions. Theorem 1. Assume that Ψγ,αX = maxj kx.j kγ,αX = MX < ∞ and ke. kq,αe = Me < ∞, where q, γ > 2 and αX , αe > 0. Define  1 if αX ≥ 1/2 − 2/γ, ν= γ/4 − αX γ/2 if αX < 1/2 − 2/γ. Assume τ = qγ/(q + γ) and let α = min(αX , αe ). Define  1 if α ≥ 1/2 − 1/τ , ρ= τ /2 − ατ if α < 1/2 − 1/τ . 2/(1−2ν/γ) 4 s2 log p/κ2 + s1/(1−2ν/γ) (log p)3/(2−4ν/γ) k|x | k κ1/(2ν/γ−1) for γ > 4, If |β|0 = s, n & MX . ∞ γ,αX 2/(1−2/γ) 1/(1−2/γ) 4/(γ−2) −1/(1−2/γ) and n & MX s p κ for 2 < γ ≤ 4, then there exists B > 0 such that  p log p/nMe MX + nρ/τ −1 (log p)3/2 Me k|x. |∞ kγ,αX for τ > 2, λ& Bp1/τ n1/τ −1 MX Me for 1 < τ ≤ 2, any Lasso solution β̂ satisfies, √ |β̂ − β|2 ≤ 4λ s/κ, (13) |β̂ − β|1 ≤ 16λs/κ, (14) |X(β̂ − β)|22 /n ≤ 8λ s/κ, with probability 1 − P1 − P2 , where  −γ/2 + C p−C3 ,  2  C1 (log p) γ 2 γ/2 P1 = p nMX s   C1 (nκ)γ/2 ,   C4 (log p)−τ + C5 p−C6 , P2 =  C4 B −τ , 5 2 (15) if γ>4 if 2 < γ ≤ 4, if τ >2 if 1 < τ ≤ 2. P Proof. Recall Σ̂ = (σ̂jk )1≤j,k≤p = 1/n ni=1 xi xTi = n−1 X T X, Σ = (σjk )1≤j,k≤p , J = support(β) ⊆ {1, ..., p} with |J|0 = s, and define the events A = {|Σ̂ − Σ|∞ ≤ a} = {max |σ̂jk − σjk | ≤ a}, (16) B = {n−1 X T e (17) j,k ∞ ≤ λ/4}. We first need a positive lower bound on u0 Σ̂u/|u|22 , uniformly over all u ∈ {u : |uJ c |1 ≤ 3|uJ |1 , u 6= 0}, that holds with high probability. On the event A, by Lemmas F.1 and F.3 of Basu and Michailidis (2015), we have the following upper bound u0 (Σ̂ − Σ)u sup ≤ 75 |uJ c |1 ≤3|uJ |1 ,|u|2 =1 sup u0 (Σ̂ − Σ)u |u|0 =2s,|u|2 =1 ≤ 150as Since inf |uJ c |1 ≤3|uJ |1 ,|u|2 =1 u0 Σu = κ, we have, on the event A, inf |uJ c |1 ≤3|uJ |1 ,|u|2 =1 Setting a = κ 300s , u0 Σ̂u ≥ κ − 150as. we obtain inf |uJ c |1 ≤3|uJ |1 ,|u|2 =1 u0 Σ̂u ≥ κ/2. (18) Since β̂ minimizes (2), we have 1 1 |Y − X β̂|22 + λ|β̂|1 ≤ |Y − Xβ|22 + λ |β|1 . 2 2 (19) After some algebra, this reduces to (β̂ − β)Σ̂(β̂ − β) + λ|β̂|1 ≤ 2eT X(β̂ − β)/n + λ|β|1 (20) On the event B, the above inequality implies that 1 3 0 ≤ (β̂ − β)Σ̂(β̂ − β) ≤ λ|β̂J − βJ |1 − λ|β̂J c |1 2 2 (21) This ensures |β̂J c − βJ c |1 ≤ 3|β̂J − βJ |1 , i.e., β̂ − β ∈ {u : |uJ c |1 ≤ 3|uJ |1 , u 6= 0}, which by (18) entails (β̂ − β)Σ̂(β̂ − β) ≥ κ|β̂ − β|22 /2. Note that inequality (21) also implies that √ 1 λ|β̂ − β|1 + (β̂ − β)Σ̂(β̂ − β) ≤ 2λ|β̂J − βJ |1 ≤ 2λ s|β̂J − βJ |2 2 (22) κ So (13), (14) and (15) follow on the event A ∩ B with a = 300s . Then we need to control the probability P(Ac ) and P(B c ). By Hölder’s inequality, we have for m ≥ 0 that ∞ X xlj el − x∗lj e∗l τ ≤ l=m = ∞  X l=m ∞  X kxlj (el − e∗l )kτ + (xlj − x∗lj )e∗l kxlj kγ kel − e∗l kq + xlj − x∗lj l=m 6  τ  ∗ ke k l q . γ Since α = min(αX , αe ), the dependence adjusted norm satisfies kx.j e. kτ,α ≤ kx.j kγ,0 ke. kq,αe + kx.j kγ,αX ke. kq,0 ≤ 2 kx.j kγ,αX ke. kq,αe . (23) Similarly, we have kx.j x.k − σjk kγ/2,αX /2 ≤ 2 kx.j kγ,αX kx.k kγ,αX , (24) Hence, max kx.j e. kτ,α ≤ 2Me MX , 1≤j≤p 2 max kx.j x.k − σjk kγ/2,αX /2 ≤ 2MX . 1≤j,k≤p (25) (26) Employing a similar derivation, we can show that, k max |x.j e. |kτ,α ≤ 2k|x. |∞ kγ,αX Me , (27) k max |x.j x.k − σjk |kγ/2,αX /2 ≤ 2k|x. |∞ k2γ,αX . (28) 1≤j≤p 1≤j,k≤p Note that MX ≤ k|x. |∞pkγ,αX ≤ Υγ,αX . If τ > 2, for λ & log p/nMe MX + nρ/τ −1 (log p)3/2 Me k|x. |∞ kγ,αX , adopting (25), (27) and Lemma 3, we have, nρ (log p)τ /2 k|x. |∞ kτγ,αX Meτ 2 2 2 P(B ) = C4 + C5 e−C6 nλ /(MX Me ) . (nλ)τ c If 1 < τ ≤ 2, applying (25), Lemma 2 and Markov inequality, we have P(B c ) = C4 τ Mτ pnMX e . (nλ)τ Under our choice of λ, if τ > 2, P2 = P(B c ) = C4 (log p)−τ + C5 p−C6 . If 1 < τ ≤ 2, P2 = B −τ . Similarly, we can prove P1 = P(Ac ). Remark 1. Based on the theorem, we have the following cases: Assume MX  1 and Me  1. Consider γ > 4 and τ > 2. Under the weak cross-sectional dependence k|x. |∞ k  p1/γ , which would hold if the p components of xij (1 ≤ j ≤ p) are nearly independent, then the required sam2 ple size p + s1/(1−2ν/γ) (log p)3/(2−4ν/γ) p2/(γ−2ν) and regularization parameter satisfies p is n & s log ρ/τ and Lemma 1 in the λ & log p/n + n −1 (log p)3/2 p1/γ . In comparison, Bonferroni Inequality p Appendix would result in n & s2 log p + s1/(1−2ν/γ) p4/(γ−2ν) and λ & log p/n + nρ/τ −1 p1/τ . In addition, under the strongest cross-sectional dependence k|x. |∞ k  1, which would hold if the p components of xij (1 ≤ j ≤ p) are linear combinations of fixed random variables, the required sample size is n & s2 log p + s1/(1−2ν/γ) (log p)3/(2−4ν/γ) and regularization parameter satisfies λ & p log p/n + nρ/τ −1 (log p)3/2 . Next, we give an example to which the results of Theorem 1 apply. 7 Example 1. Consider the autoregressive model with exogenous inputs, that is, the ARX(a, b) model: yi = a X l=1 φl yi−l + b X ψl0 zi−l + ei = β 0 xi + ei , (29) l=0 where a and b are nonnegative integers, zi follows a linear P process given below and ei follows a GARCH(1,1) model. Assume the roots of the polynomial 1− al=1 φl B l are outside the unity circle, which ensures stationarity of the autoregressive part of the model. Also assume the population covariance matrix Σ = Exi x0i is positive definite. Let p hi = π0 + π1 e2i−1 + π2 hi−1 , (30) e i = hi η i , 2 )q/2 < ∞, q > 4. Then it is easy to show ke k with π0 > 0, π1 ≥ 0, π2 ≥ 0 and E(π1 +π2 ηi−1 . q,αe < ∞. Let εij , i, j ∈ Z, be i.i.d. random variables with mean 0, variance 1, and having finite qth moments, q > 2, and let Ai , i ≥ 0, be p × d coefficient matrices with real entries such that P∞ T T i=0 tr(Ai Ai ) < ∞. Write εi = (εi1 , ..., εid ) . Then by Kolmogorov’s three-series theorem the linear process zi = ∞ X Al εi−l (31) l=0 exists. Linear processes are widely used in practice and they include the popular ARMA processes. Denote Al = (al;jk )1≤j≤p,1≤k≤d , Al,j. the jth row of Al . By Burkholder’s inequality, kAl,j. ε0 kγ ≤ √ γ − 1|Al,j. |2 kε00 kγ . If there exist constants K1 > 1 and αZ > 0 such that maxj≤p |Al,j. |2 ≤ K1 (l + 1)1+αZ hold for all l ≥ 0, then we have maxj kz.j kγ,αZ = K1 K2 kε00 kγ , where the constant K2 ony P depends on αZ and γ. Together with the assumption that the roots of the polynomial 1 − al=1 φl B l are outside the unity circle, we ensure maxj kx.j kγ,αZ < ∞. 4 Model Selection Consistency In this section, we extend the asymptotic properties of sign consistency for model selection via the Lasso to the dependent setting. The sign consistency of Lasso was introduced by Zhao and Yu (2006). Without loss of generality, write β = (β1 , ..., βs , ..., βp )0 , where βj 6= 0 if j ≤ s and βj = 0 0 , β 0 )0 , where β if j > s. That is, the first s predictors are relevant variables. Denote β = (β(1) (1) (2) is a s × 1 vector. Correspondingly, for any i, denote xi = (x0i(1) , x0i(2) )0 and X = (x1 , ..., xn )0 = (X(1) , X(2) ), where X(1) is the n × s sub-matrix consisting of the relevant variables, and X(2) is the n × (p − s) sub-matrix with the irrelevant ones. Similarly, consider the partition of Σ = Exi x0i as   Σ11 Σ12 Σ= , Σ21 Σ22 where Σ11 is a s × s sub-matrix with the relevant variables. 8 To account for the cross-sectional dependence for the stationary process (xi(1) ) and (xi(2) ), we define the L∞ functional dependence measure and its corresponding dependence adjusted norm ωi,q,(1) = k max |xij − x∗ij |kq , 1≤j≤s α k|x.(1) |∞ kq,α = sup (m + 1) Ωm,q,(1) , α ≥ 0, and Ωm,q,(1) = m≥0 ∞ X ωi,q,(1) . i=m Additionally, we define Ψq,α,(1) = max kx.j kq,α 1≤j≤s and Υq,α,(1)  1/q s X = kx.j kq  . q,α j=1 The quantities k|x.(2) |∞ kq,α , Ψq,α,(2) and Υq,α,(2) can be similarly defined. Clearly, Ψq,α,(l) ≤ k|x.(l) |∞ kq,α ≤ Υq,α,(l) , for l = 1, 2. We employ similar conditions as those in Zhao and Yu (2006). Define the strong irrepresentable condition of population covariance as follows: There exists a positive constant η ∈ (0, 1) such that Σ21 Σ−1 11 sign(β(1) ) ∞ ≤ 1 − η. (32) Theorem 2 below extends the results of Zhao and Yu (2006) to random design linear model with dependent errors. In comparison, Medeiros and Mendes (2016) derived asymptotic properties of sign consistency for the adaptive Lasso, while our results apply to the original Lasso and do not need any assumptions on weights. Note that even for heavy-tail variables, our results show that if the dependence is strong, the allowed dimension p can be as large as exponential of sample size n; see Remark 2 for more details. Theorem 2. Let Σ−1 1/N1 , σ = maxs+1≤k≤p σkk , N1 = o(sσ), and L = min1≤j≤s |βj |. 11 2 = √ Assume that λ ≤ nN1 L/(2 s), max1≤j≤p kx.j kγ,αX = MX < ∞, and ke. kq,αe = Me < ∞, where q > 2, γ > 4 and αX , αe > 0. Define  1 if αX > 1/2 − 2/γ, ν= γ/4 − αX γ/2 if αX < 1/2 − 2/γ. Let α = min(αX , αe ). Assume τ = qγ/(q + γ) > 2 and define  1 if α > 1/2 − 1/τ , ρ= τ /2 − ατ if α < 1/2 − 1/τ . Then, when the sample size n & 4 σs3 log s 2 log p 4 s2 log p MX MX MX N13 σ 1/(2−4ν/γ) + + ( + ) (s log s)3/(2−4ν/γ) k|x.(1) |∞ k2/(1−2ν/γ) γ,αX σ2 η2 η 2 N13 η 2 N12 1/(1−2ν/γ) +(ηN1 )−1/(1−2ν/γ) s1/(1−2ν/γ) (log p)3/(2−4ν/γ) k|x.(1) |∞ kγ,α k|x.(2) |∞ k1/(1−2ν/γ) γ,αX X 1/(1−2ν/γ) +σ −1/(1−2ν/γ) (log p)3/(2−4ν/γ) k|x.(2) |∞ kγ,α X 9 (33) such that √ p sσ ∨ 1]( n log sMe MX + nρ/τ (log s)3/2 Me k|x.(1) |∞ kγ,αX ) λ & [ √ η N1 p +( n log pMe MX + nρ/τ (log p)3/2 Me k|x.(2) |∞ kγ,αX )/η (34) the consistency probability P(β̂ =s β) is at least 1 − C1 (log p)−γ/2 − C2 (log s)−γ/2 − C3 (log p)−τ − C4 (log s)−τ − C5 p−C6 − C7 s−C8 . (35) −1 Proof. Reall |Σ−1 11 |2 = 1/N1 and let |Σ̂11 |2 = 1/N2 . Define the events A1 = {|Σ̂11 − Σ11 |∞ ≤ a1 } = { max |σ̂jk − σjk | ≤ a1 }, (36) A2 = { max |σ̂kk − σkk | ≤ a2 }, (37) 1≤j,k≤s s+1≤k≤p A3 = {|Σ̂21 − Σ21 |∞ ≤ a3 } = { max 1≤j≤s,s+1≤k≤p |σ̂jk − σjk | ≤ a3 }. (38) Let X = (x1 , ..., xn )0 and denote by X(1) and X(2) the first s and last p − s columns of X. Denote P Wn = √1n ni=1 xi ei and Wn (1), β(1) and Wn (2), β(2) the first s and last p − s entries of Wn and β, respectively. On the event A1 and A2 , by Cauchy inequality, for s + 1 ≤ k ≤ p and letting A = |[Σ̂21 (Σ̂−1 11 − −1 Σ11 )sign(β(1) )]k |, we have −1 A = |[Σ̂21 Σ̂−1 11 (Σ11 − Σ̂11 )Σ11 sign(β(1) )]k | T = |X(2)k X(1) (X1T X(1) )−1 (Σ11 − Σ̂11 )Σ−1 11 sign(β(1) )| v u n q u1 X −1 −1 2 T t ≤ xik · (Σ−1 11 sign(β(1) )) (Σ11 − Σ̂11 )Σ̂11 (Σ11 − Σ̂11 )Σ11 sign(β(1) ) n i=1 1 max σkk + a2 · √ · |(Σ11 − Σ̂11 )Σ−1 11 sign(β(1) )|2 s+1≤k≤p N2 q q 1 √ ≤ max σkk + a2 · · s|Σ11 − Σ̂11 |∞ sign(β(1) )T Σ−2 11 sign(β(1) ) s+1≤k≤p N2 √ q s sa1 ≤ max σkk + a2 · √ . s+1≤k≤p N2 N1 ≤ q Similarly, on the event A3 , it can be shown that |[(Σ̂21 − Σ21 )Σ−1 11 sign(β(1) )]k | ≤ sa3 . N1 p √ Setting a1 = ηN1 N2 /(4s 2s maxs+1≤k≤p σkk ), a2 = maxs+1≤k≤p σkk and a3 = ηN1 /(4s), we get −1 |Σ̂21 Σ̂−1 11 sign(β(1) ) − Σ21 Σ11 sign(β(1) )|∞ ≤ η , 2 and −1 1 − |Σ̂21 Σ̂−1 11 sign(β(1) )|∞ ≤ 1 − |Σ21 Σ11 sign(β(1) )|∞ − 10 η η ≤ . 2 2 By Lemma 4, √ ηN1 N2 N2 = inf ζ Σ̂11 ζ > inf ζ Σ11 ζ − sa1 = N1 − p . |ζ|2 =1 |ζ|2 =1 4 2s maxs+1≤k≤p σkk T T Since N1 = o(s maxs+1≤k≤p σkk ), N2 ≥ N1 /2 when n and p are sufficiently large. Then √ ηN1 N1 a1 ≥ p . 8s 2s maxs+1≤k≤p σkk √ √ √ √ −1 2 s|Σ̂11 |2 = N2s . For λ ≤ nN1 L/(2 s), λ ≤ nN2 L/ s when n Note that |Σ̂−1 11 sign(β(1) )|∞ ≤ √ λ 1√ and p are sufficiently large. Then n|βj | − 2√ |[Σ̂−1 11 sign(β(1) )]j | ≥ 2 nL for all 1 ≤ j ≤ s. By n Lemma 5, on the events A1 , A2 and A3 , we obtain P(β̂ 6=s β) ≤ P(B c ) + P(Dc ), where   1√ −1 B = |Σ̂11 Wn (1)|∞ < nL , 2   λη −1 . D = |Σ̂21 Σ̂11 Wn (1) − Wn (2)|∞ ≤ √ 4 n Simple application of the Cauchy inequality shows that v uX n X u s 1 T −1 t ( √1 sup ζ Σ̂11 Wn (1) ≤ xij ei )2 . N2 n |ζ|2 =1 j=1 i=1 This yields s \ B = {|[Σ̂−1 11 Wn (1)]j | < j=1 1√ nL} 2 = { sup ζ T Σ̂−1 11 Wn (1) < |ζ|2 =1 1√ nL} 2 v  s n u  X uX √ 1 1 t (√ ⊇ nLN2 xij ei )2 ≤   2 n j=1 i=1 ( ) n 1 X λ ⊇ max | √ xij ei | ≤ √ . 1≤j≤s n 2 n i=1 On the other hand, D ⊇ D1 ∩ D2 , where D1 = p \ λη T {|X(2)k X(1) (X1T X(1) )−1 Wn (1)| ≤ √ }, 8 n k=s+1 and D2 = p \ p n \ λη 1 X λη √ √ {|[Wn (2)]k | ≤ }= {| xik ei | ≤ √ }. 8 n n 8 n k=s+1 k=s+1 11 i=1 Employing a similar derivation, we can show that, on the event A2 , √ n 1 X λη N1 xij ei | ≤ √ D1 ⊆ { max | √ }. 1≤j≤s 16 ns maxs+1≤k≤p σkk n i=1 By carrying out similar procedures as those of Theorem 1, we can control the probability P(Ac1 ), P(Ac2 ), P(Ac3 ), P(B c ), P(D1c ) and P(D2c ). Then (35) follows. Remark 2. In particular, assume MX  1, Me  1, σ  1, N1  1, η  1. Also assume the weak temporal dependence case αX > 1/2 − 2/γ. If the dependence measure k|x.(1) |∞ kγ,αX  s1/γ and k|x.(2) |∞ kγ,αX  p1/γ , which would hold if the p components of xij (1 ≤ j ≤ p) are nearly independent, then (33) and (34) reduce to n & s3 log s + s2 log p + (log p)3/(2−4/γ) s(3/2+2/γ)/(1−2/γ) + (log p)3/(2−4/γ) s(1+1/γ)/(1−2/γ) p1/(γ−2) , and λ& p p ns log s + n1/τ (log s)3/2 s1/γ+1/2 + n log p + n1/τ (log p)3/2 p1/γ . Additionally, if s = O(nc1 ) and L  n(c2 −1)/2 for some 0 ≤ c1 < c2 /2 ≤ 1/2, then the existence of regularization parameter λ requires the dimension p  nc3 with c3 = {γ(c2 − c1 + 1)/2 − 1 − γ/q} ∧ 1 {γ − 2 − (γ + 1)c1 } and c1 < { γ2 − 1 − γq } ∧ 2γ−4 3γ+4 ∧ 3 . On the other hand, if k|x.(1) |∞ kγ,αX  Ψγ,αX ,(1)  1 and k|x.(2) |∞ kγ,αX  Ψγ,αX ,(2)  1, s = O(nc1 ), L  n(c2 −1)/2 for some 0 ≤ c1 < c2 /2 ≤ 1/2, then the existence of regularization 2 1 parameter λ requires the dimension p  exp{nc3 }, where c3 = c2 −c ∧ c31 ∧ (1 − 2c1 ) ∧ { 2γ−4 2 3γ − 3 c1 } with c1 < 13 ∧ 2γ−4 3γ . In summary, the allowed dimension p varies from nc3 to exp{nc3 } depending on the crosssectional dependence. Similar to that of Remark 1, results derived by Bonferroni Inequality and Lemma 1 in the Appendix would be worse that those of Theorem 2. Note that if the assumptions in Example 1 hold, together with the Strong Irrepresentable Condition, the results of Theorem 2 continue to apply. In general, the Strong Irrepresentable Condition is non-trivial, particularly since we do not know sign(β) a priori. Then, we need the Strong Irrepresentable Condition to hold for every possible combination of different signs and placement of zeros. We give a simple example below in which the Strong Irrepresentable Condition is guaranteed. All diagonal elements of Σ are assumed to be 1 which is equivalent to normalizing all covariates in the model to the same scale since Strong Irrepresentable Condition is invariant under any common scaling of Σ. Example 2. Consider the following autoregressive model with exogenous inputs model: yi = a X φl yi−l + ψzi + ei = β 0 xi + ei , (39) l=1 where a is nonnegative finite integer, zi is P independent of ei , and the errors ei are homogeneous. Assume the roots of the polynomial 1 − al=1 φl B l are outside the unity circle, which ensures 12 stationarity of the autoregressive part of the model. Also assume Σ = Exi x0i is positive definite. Furthermore, suppose β has s nonzero entries. Similar to Corollary 2 in Zhao and Yu (2006), Σ c for a constant 0 < c < 1 then Strong has 1’s on the diagonal and bounded correlation |σjk | ≤ 2s−1 Irrepresentable Condition holds. In this case, we need autocorrelation of yi to be very weak, and all the covariates zi are slightly correlated. 5 Simulation Study In this section, we use simulation to demonstrate the performance of Lasso regression for dependent data in finite samples and to compare its efficacy with the mixed-frequency data sampling regression (MIDAS) commonly used in the econometric literature; see Ghysels et al. (2004). We first consider the following data generating process, yi = φyi−1 + xTi−1,1 βs + ei ,   X   m xi,1 xi−j,1 xi = = Aj + ηi , xi,2 xi−j,2 (40) j=1 where φ = 0.6 and each element of βs is given by βs,j = √1s (−1)j , xi,1 is a s × 1 vector of relevant variables. Let β = (βs , βsc ), where βsc = 0 is a (p − s) × 1 vector. The errors in the model, ei and ηij , are i.i.d random variables of Student-t distribution with 5 degrees of freedom, and ei and ηi are all mutually uncorrelated. The explanatory variable process xi , which has p − s irrelevant variables, follows a vector autoregressive, VAR(m), model. The following two choices of xi are considered, denoted as Model 1 and Model 2, respectively. (1). Model 1: The explanatory variable process xi is a VAR(4) process, where A1 and A4 assume a block-diagonal structure and A2 = A3 = 0. In particular, the first two and the last two blocks are 5 × 5 matrices with all entries of the blocks of A1 equal to 0.15 and all entries of the blocks of A4 equal to −0.1. The other blocks are 10 × 10 matrices with all elements of the blocks of A1 equal to 0.075 and all elements of the blocks of A4 equal to −0.05. This structure could be motivated by a model built for mixed-frequency data with some quarterly time series often encountered in macroeconometric analysis. (2). Model 2: The explanatory variable process xi follows a VAR(1) model, where A1 is blockdiagonal with the same block structure given by Model 1. The (j, k)th entry of the block is (−1)|j−k| ρ|j−k|+1 with ρ = 0.4. Hence, the entries decrease exponentially fast with their distances from the diagonal. We employ sample sizes n = 50, 100, 200 with different choices of p and s. We set p = 100, 200, 400 and s = 5, 10, 20. For comparison, we also simulate a response series from a MIDAS model. In the model (40), for s = 5, 10, 20, let βs = β(1), (β(1)T , β(2)T )T or (β(1)T , β(2)T , β(3)T )T respectively, with exp(δ1 j + δ2 j 2 ) βj (l) = P|β(l)| 0 2 k=1 exp(2δ1 k + 2δ2 k ) (41) where β(1) and β(2) have 5 variables, β(3) has 10 variables, and δ = (δ1 , δ2 )0 = (0.5, −1)0 . All the other settings are the same as above. The two choices of xi as in Models 1 and 2 are used, and 13 we denote the resulting MIDAS models as Models 3 and 4, respectively. The models estimated by Lasso are with λ selected by the BIC; see Bühlmann and Van De Geer (2011). We also employed models with λ selected by cross validation but found that cross-validation does not improve the results while being considerably more slower in computation. For the models estimated by MIDAS, we only consider Exponential Almon lag polynomial weighting scheme (see (41)) for the first 100 variables and impute the true values as initial values. Table 1 shows the average of absolute error (AE), the average of root mean squared error (RMSE) for the Lasso estimators and MIDAS estimators over the 10,000 Monte Carlo simulations for the data generating processes used. The AE and the RMSE are defined as, MC 1 1 X (φ̂; β̂) − (φ; β) , p + 1 MC 1 l=1 v u MC u 1 2 1 X t RMSE = (φ̂; β̂) − (φ; β) , p + 1 MC 2 AE = l=1 where MC denotes the number of Monte Carlo repetitions. From the table, it is clear that both the AE and RMSE measures show that the Lasso regression provides substantially more accurate parameter estimation than the mixed-frequency data sampling regression (MIDAS) in the presence of irrelevant variables. Also, as expected, the AE and the RMSE of the estimators decrease with n and p, but increase with s. To evaluate the performance of out-of-sample forecasts, we use the estimated parameters to compute one-step-ahead forecasts and consider a total of 10 out-of-sample observations, denoted by yn+1 , . . . , yn+10 . Table 2 shows the average absolute forecast error (AFE) and the average root mean squared forecast error (RMSFE) over the 10,000 Monte Carlo simulations, which are calculated as M C 10 1 XX AFE = |ŷn+k − yn+k | , 10M C l=1 k=1 v u MC X 10 u 1 X RMSFE = t |ŷn+k − yn+k |2 . 10M C l=1 k=1 The forecasting results in Table 2 show that the Lasso regression has much smaller AE and RMSFE than the MIDAS in all settings. Furthermore, the results show clearly that the performance of the Lasso regression and the MIDAS improves with the sample size, but deteriorates as the number of relevant variables s increases. Finally, both AE and RMSFE of the Lasso regression decrease fast than those of MIDAS as n grows. As a matter of fact, the AE and the RMSFE of the MIDAS remain high even when n = 200. Since we only fit MIDAS through the first 100 variables, the performance of the MIDAS does not change as p grows. Overall, in the presence of irrelevant variables, the Lasso regression significantly outperforms the MIDAS regression. 6 Empirical Analysis We consider the problem of predicting the growth rate of U.S. quarterly gross domestic product (GDP). In addition, nine (9) macroeconomic variables with different sampling frequencies are also 14 Table 1: Accuracy in Parameter Estimation of Lasso Regression and Mixed-Frequency Data Sampling Regression. The results are based on 10,000 repetitions, where AE and RMSE denote the average of mean absolute errors and average of root mean square errors over Monte Carlo repetitions and parameters. In the table, s, p, and n denote the number of non-zero parameters, the dimension of regressors, and sample size, respectively. s Absolute Error (AE) ×102 Lasso MIDAS n Model 1 5 50 100 200 10 50 100 200 20 50 100 200 Model 2 5 50 100 200 10 50 100 200 20 50 100 200 Model 3 5 50 100 200 10 50 100 200 20 50 100 200 Model 4 5 50 100 200 10 50 100 200 20 50 100 200 Root Mean Square Error (RMSE) ×102 Lasso MIDAS p 100 200 400 100 200 400 100 200 400 100 200 400 2.435 1.887 1.265 4.595 3.686 2.282 7.832 6.564 4.694 1.320 1.035 0.745 2.493 2.053 1.368 4.407 3.667 2.773 0.709 0.555 0.426 1.324 1.098 0.823 2.233 1.925 1.639 6.626 6.243 5.909 8.257 7.855 7.504 10.757 10.382 10.082 3.322 3.131 2.956 4.153 3.940 3.773 5.408 5.213 5.062 1.668 1.569 1.486 2.081 1.974 1.891 2.708 2.611 2.538 9.462 7.784 5.190 13.376 11.304 7.017 16.671 14.771 10.935 7.022 5.902 4.249 9.902 8.688 5.749 12.493 11.262 8.858 5.177 4.431 3.449 7.248 6.496 4.891 9.012 8.328 7.288 13.944 13.241 12.686 16.760 16.135 15.668 19.532 18.935 18.501 9.853 9.360 8.956 11.890 11.424 11.093 13.842 13.401 13.093 6.984 6.629 6.349 8.410 8.087 7.853 9.793 9.490 9.272 0.953 0.540 0.338 1.909 1.058 0.647 3.193 1.747 1.066 0.571 0.301 0.179 1.201 0.621 0.357 2.105 1.071 0.603 0.344 0.167 0.096 0.730 0.366 0.198 1.236 0.647 0.344 4.946 4.550 4.204 5.460 5.032 4.600 6.116 5.676 5.260 2.486 2.289 2.106 2.732 2.534 2.314 3.073 2.844 2.634 1.247 1.145 1.055 1.366 1.270 1.163 1.544 1.426 1.322 4.065 2.429 1.587 6.427 3.678 2.304 8.729 4.995 3.138 3.194 1.837 1.169 5.326 2.903 1.740 7.405 4.072 2.413 2.537 1.392 0.870 4.363 2.309 1.331 6.157 3.305 1.882 10.967 10.107 9.380 12.455 11.492 10.550 14.141 13.201 12.344 7.778 7.173 6.615 8.804 8.159 7.474 10.040 9.352 8.749 5.516 5.060 4.691 6.221 5.780 5.302 7.119 6.621 6.191 1.709 0.929 0.566 3.742 2.059 1.197 7.229 4.452 2.526 1.026 0.529 0.313 2.233 1.262 0.692 4.386 2.907 1.464 0.608 0.302 0.172 1.268 0.751 0.396 2.345 1.753 0.876 6.569 6.266 6.165 8.405 8.197 8.098 11.019 10.918 10.871 3.298 3.154 3.100 4.220 4.119 4.070 5.534 5.483 5.463 1.654 1.582 1.552 2.116 2.063 2.039 2.773 2.750 2.737 6.881 4.128 2.637 11.139 6.694 3.993 15.241 10.354 6.204 5.418 3.218 2.038 8.713 5.524 3.178 11.903 8.661 4.845 4.230 2.526 1.562 6.658 4.507 2.522 8.861 7.070 3.931 14.019 13.341 13.029 17.072 16.616 16.363 19.937 19.651 19.523 9.931 9.463 9.238 12.099 11.770 11.603 14.131 13.926 13.841 7.034 6.706 6.537 8.573 8.333 8.211 9.998 9.865 9.797 1.391 0.956 0.705 2.395 1.671 1.234 3.676 2.432 1.781 0.790 0.526 0.387 1.396 0.931 0.689 2.290 1.386 0.998 0.446 0.281 0.207 0.784 0.505 0.376 1.243 0.766 0.555 5.138 4.575 4.217 6.031 5.503 5.131 6.884 6.383 6.042 2.583 2.296 2.115 3.033 2.766 2.577 3.464 3.212 3.039 1.291 1.148 1.062 1.524 1.387 1.290 1.731 1.612 1.520 6.190 4.502 3.366 8.409 6.100 4.455 10.387 7.363 5.398 4.792 3.455 2.604 6.642 4.743 3.510 8.378 5.817 4.241 3.671 2.598 1.976 5.150 3.610 2.716 6.616 4.521 3.346 12.009 10.974 10.453 14.438 13.601 13.119 16.464 15.712 15.319 8.508 7.784 7.414 10.251 9.656 9.292 11.692 11.143 10.863 5.999 5.507 5.255 7.267 6.833 6.573 8.265 7.905 7.687 15 Table 2: Performance of Out-of-sample predictions of Lasso regression and mixed frequency data sampling regression (MIDAS). The results are based on 10 one-step ahead predictions and 10,000 iterations, where AFE and RMSFE denote the average absolute forecast errors and root mean squared forecast errors, respectively, and s, p, and n are the number of non-zero parameters, the dimension of regressors, and sample size. For MIDAS, the maximum p is fixed at 100. s Absolute Error (AE) ×102 Lasso MIDAS n Root Mean Square Forecast Error (RMSFE) ×102 Lasso MIDAS p Model 1 5 50 100 200 10 50 100 200 20 50 100 200 Model 2 5 50 100 200 10 50 100 200 20 50 100 200 Model 3 5 50 100 200 10 50 100 200 20 50 100 200 Model 4 5 50 100 200 10 50 100 200 20 50 100 200 100 200 400 100 200 400 100 200 400 100 200 400 119.99 102.79 86.91 151.64 125.69 96.05 177.67 150.27 118.66 125.80 106.61 90.69 159.68 133.96 101.90 188.85 162.24 128.71 130.36 110.78 95.44 166.47 141.71 112.21 195.07 170.04 145.10 169.21 162.23 156.83 185.09 177.60 171.93 205.00 195.78 190.13 161.59 156.72 152.43 178.89 171.63 167.74 200.04 191.71 185.97 162.30 156.44 153.22 179.96 172.37 168.25 199.89 191.17 188.20 147.28 127.78 109.77 185.17 155.16 120.33 216.17 184.07 146.77 153.88 132.30 114.18 194.31 164.97 127.25 229.23 198.59 159.20 158.88 136.95 119.46 202.08 173.88 139.39 236.27 207.74 178.44 206.07 197.71 191.41 225.99 216.92 210.23 250.24 239.45 232.48 197.41 191.79 186.73 218.66 210.14 206.10 244.51 235.01 228.41 198.05 191.38 187.42 219.98 211.44 206.33 244.14 234.43 230.51 96.42 84.12 78.40 114.17 90.98 81.72 126.93 97.76 85.38 101.85 85.79 79.61 125.73 95.36 83.17 144.58 105.07 87.98 107.24 88.10 80.62 140.04 100.84 85.38 167.82 113.79 91.91 14.735 142.10 138.69 171.54 156.73 151.43 178.20 169.73 161.70 148.84 142.71 137.68 164.12 157.99 151.18 173.15 164.32 157.18 148.45 142.91 138.83 163.98 158.02 151.95 173.51 164.74 158.06 119.75 106.20 99.93 139.96 114.19 103.73 155.42 121.64 107.88 125.53 108.09 101.57 153.71 118.74 105.12 175.94 130.10 110.59 131.79 110.48 102.35 169.80 124.92 107.56 202.89 139.89 115.16 179.91 173.36 169.06 208.01 190.66 184.12 216.55 206.51 196.96 181.54 174.08 168.10 199.56 191.93 183.72 211.19 200.44 191.94 180.98 174.08 169.27 199.45 191.94 184.55 211.63 200.96 192.93 117.40 89.46 80.66 154.49 103.13 84.72 197.33 130.89 97.00 128.72 92.89 81.29 172.52 112.89 88.20 224.55 150.83 101.21 140.51 97.12 82.89 188.94 124.33 91.00 244.37 172.29 109.04 152.98 144.72 142.38 178.91 171.22 166.99 206.91 196.60 193.16 153.15 145.04 141.08 179.17 171.38 168.24 205.01 197.56 193.86 153.34 145.03 141.18 179.87 170.69 167.46 205.36 196.41 193.71 143.06 112.27 102.39 185.90 127.93 107.10 236.10 160.22 121.25 155.57 116.07 103.00 206.03 138.75 111.14 266.53 182.91 125.92 168.37 120.47 105.04 224.65 152.27 114.33 288.42 207.60 134.84 187.54 144.72 174.76 218.49 209.72 204.75 251.62 240.20 236.45 187.60 178.25 173.69 218.85 209.58 205.95 249.72 240.89 237.35 187.90 178.19 173.54 219.67 209.18 205.31 249.88 239.33 237.13 103.01 88.40 81.36 117.65 95.87 84.99 132.27 102.48 88.69 108.75 90.43 82.61 126.66 99.88 87.51 148.54 108.94 92.16 113.21 92.91 83.47 136.29 103.49 89.77 162.37 115.48 96.20 131.70 121.62 118.07 148.56 139.40 134.25 163.81 154.26 150.06 131.89 122.02 117.18 148.51 139.54 135.06 164.72 154.08 149.82 130.89 121.51 116.84 148.57 139.30 134.78 163.75 154.70 150.28 126.83 110.89 103.35 144.18 119.86 107.39 161.32 127.28 111.70 133.36 113.01 104.44 154.43 124.25 110.18 180.28 134.83 115.72 138.23 115.84 105.47 165.67 128.22 112.78 196.31 142.38 120.28 162.63 150.96 147.01 183.37 172.53 166.58 201.70 190.68 185.86 162.98 151.52 145.74 183.01 172.69 167.30 202.77 190.74 185.49 161.77 150.80 145.27 183.02 172.38 167.08 201.69 190.99 185.79 16 available. The data are obtained from the St. Louis Federal Reserve Economic Data website. The predictive regression used is yi = φ0 + φ1 yi−1 + · · · + φa yi−a + Bl 9 X X βl,b zl,i×ml −b + ei (42) l=1 b=0 where a and Bl are nonnegative integers, yi is the growth rate (first difference of natural logarithm) of U.S. quarterly seasonally adjusted real GDP and zl,· ’s are the high-frequency covariates with frequency ml , e.g., ml = 3 for monthly data. The nine covariates considered in this study are: z1,· is the change of monthly civilian unemployment rates, z2,· is the growth rate of monthly all employees total payrolls, z3,· is the growth rate of monthly industrial production total index, z4,· is the growth rate of monthly consumer price index, z5,· is the growth rate of monthly Moody’s Seasoned Baa Corporate Bond Yields, z6,· is the change of daily 3-Month Treasury Bill Secondary Market Rate, z7,· is the change of daily 10-Year Treasury Constant Maturity Rate, z8,· is the change of daily NASDAQ Composite Index, and z9,· is the change of daily Wilshire 5000 Total Market Full Cap Index. The transformations of all variables are based on those of Stock and Watson (2002). Note that all the data are seasonally adjusted if necessary, and the explanatory variables are monthly or daily data. For daily variables z6,· and z7,· , we only use data of the first 16 trading days in a month. For daily variables z8,· and z9,· , we only use data of the first 15 trading days. The sampling period was from January 1980 to February 2017, but the prediction origin started with the second quarter of 2013 and ended with the first quarter of 2017. Two types of empirical analysis are entertained. First, we consider a linear model with all explanatory variables and estimated by the Lasso procedure. For comparison, we include a model with all explanatory variables except the NASDAQ Composite Index and Wilshire 5000 Total Market Full Cap Index, estimated by the MIDAS regression (denoted by MIDAS-B model), a model with monthly all-employees total payrolls as the only explanatory variable, also estimated by MIDAS (denoted by MIDAS-A model), and a simple ARMA model of the GDP growth rates (denoted by ARMA model). We use BIC to select the number of autoregressive lags (a) and the lags (Bl ) of explanatory variables. The Lasso tuning parameter λ is also chosen by the BIC; see Bühlmann and Van De Geer (2011). Here we aggregate daily explanatory variables z6 and z7 to weekly frequency for the MIDAS regression. Table 3 shows the median absolute deviation (MAD), the mean absolute error (MAE), and the root mean squared error (RMSE) for the prediction period. From the table, it is clear that the Lasso based model outperforms all the other models in this particular instance. The poor performance of MIDAS-B is likely due to using too many explanatory variables with multiple sampling frequencies. Figure 1 displays the cumulative absolute errors and the cumulative squared errors for different models in predicting the GDP growth rate. It shows clearly that the Lasso model is the best one. The MIDAS-A model also improves the prediction errors over the simple ARMA model. However, the MIDAS-B model fares poorly. Consequently, unlike the Lasso model, the MIDAS regression is not robust to the presence of irrelevant regressors. In fact, the MIDAS regression is also sensitive to the weighting schemes and the starting points of its optimization program. Turn to comparison between forecasting and now-casting. Recall that the goal of now-casting is to take advantages of available high-frequency data to improve the prediction of lower-frequency variables of interest. For the quarterly GDP growth rate, during the quarter of interest, some monthly macroeconomic variables and even some daily economic variables become available, nowcasting attempts to update the GDP prediction by incorporating those newly available high17 0.04 0.06 0.08 ARMA Lasso Forcasting MIDAS A Forecasting MIDAS B Forecasting 0.00 0.02 cumulative absolute errors 0.10 Absolute Errors 5 10 15 number of one step ahead predictions (a) 0.0005 0.0010 ARMA Lasso Forcasting MIDAS A Forecasting MIDAS B Forecasting 0.0000 cumulative squared errors 0.0015 Squared Errors 5 10 15 number of one step ahead predictions (b) Figure 1: Panel (a): Cumulative absolute errors. Panel (b): Cumulative squared errors. MIDASA represents the MIDAS regression model using only monthly all-employees total payrolls as the explanatory variable. MIDAS-B represents the MIDAS regression model with seven regressors z1,· , · · · , z7,· , where z6,· and z7,· are aggregated into weekly data. 18 Table 3: Results of out-of-sampling prediction of U.S. quarterly real GDP growth rate. The data span is from 1980 to February 2017, but the forecast origins are from the second quarter of 2013 to the first quarter of 2017. All measurements are multiplied by 103 . In the table, MAD, MAE, and RMSE are the median absolute error, mean absolute error, and root mean squared error, respectively. Model ARMA Lasso MIDAS-A MIDAS-B MAD 3.175 2.328 2.463 4.089 MAE 3.486 2.845 3.264 7.143 RMSE 4.319 3.491 4.245 9.920 frequency explanatory variables. In this exercise, we consider now-casting with the first month data within the quarter available and the first two months data available. For comparison purpose, we employ an autoregressive (AR) model yi = φ0 + φ1 yi−1 + · · · + φa yi−a + i , (43) as a benchmark for prediction. The AR order is selected by the BIC in the modeling subsample and is assumed to be fixed in the forecasting subsample. The AR model in Equation (43) is estimated by two ways. First, it is estimated by the ordinary least squares method and we denote the model by AR-OLS. Second, assuming sparsity, we estimate the AR model via Lasso method with the tuning parameter λ also selected by BIC. The forecasting result of this model is denoted by AR-Lasso. These two models represent the performance of forecasting. For now-casting, we augment the AR model in Equation (43) with all explanatory variables available in the first month of the quarter and denote the resulting results by Now-casting 1. Similarly, if we augment the AR model with all explanatory variables available in the first two months of the quarter, then the results are denoted by Now-casting 2. Specifically, for now-casting, we employ the model yi = φ0 + φ1 yi−1 + · · · + φa yi−a + β T xi + i , where xi denotes the available high-frequency explanatory variables. For Now-casting 1, xi consists of data of the first month into a given quarter whereas for Now-casting 2, it consists of data of the first two months into a given quarter. In this exercise, we use all monthly and daily high-frequency variables z1,· , · · · , z9,· . We denote the results for MIDAS regression as MIDAS-C Now-casting 1 and MIDAS-C Now-casting 2, respectively. Finally, we also employ a MIDAS regression that only uses explanatory variables z1,· , · · · , z7,· in the now-casting and denote the results as MIDAS-D. Table 4 summarizes the performance of now-casting in predicting U.S. quarterly GDP growth rates in the forecasting period. From the table, we make the following observations. First, as expected, now-casting fares better than forecasting. The only exception is MIDAS-D now-casting. Second, also as expected, Now-casting 2 shows some improvement over Now-casting 1 for a given model. Keep in mind, however, Now-casting 1 is available one month into a quarter whereas Nowcasting 2 needs to wait for an additional month. Third, from the performance of MIDAS-C and MIDAS-D, the stock market indexes do not seem to be helpful in predicting the GDP growth rate. In real applications, there exist many high-frequency explanatory variables, but their contributions 19 to predicting the low-frequency variable of interest in unknown a priori. In this situation, the results obtained in this paper suggest that the Lasso regression could be helpful. Figure 2 shows both the Lasso model and the MIDAS-B model improve the prediction via nowcasting. But when irrelevant variables exist, MIDAS regression might encounter some difficulties. Table 4: Comparison of forecasting and now-casting based on predicting the U.S. quarterly real GDP growth rate. The data span is from 1980 to February 2017, but the forecast origins are from the second quarter of 2013 to the first quarter of 2017. All measurements are multiplied by 103 . In the table, MAD, MAE, RMSE are the median absolute deviation, mean absolute error, and root mean squared error, respectively. Model AR-OLS AR-Lasso Lasso Now-casting 1 Lasso Now-casting 2 MIDAS-C Now-casting 1 MIDAS-C Now-casting 2 MIDAS-D Now-casting 1 MIDAS-D Now-casting 2 7 MAD 2.865 3.327 2.731 2.834 4.181 5.108 3.670 2.784 MAE 3.400 3.448 3.278 3.247 5.102 5.666 3.561 3.279 RMSE 4.242 4.174 3.962 3.941 6.507 6.430 4.125 4.048 Appendix In this appendix, we describe some lemmas used in the paper. Lemma 1. Assume that ke. kq,α < ∞, where q > 2 and α > 0. Let ςn = 1 (resp. (log n)1+2q or P nq/2−1−αq ) if α > 1/2 − 1/q (resp. α = 0 or α < 1/2 − 1/q). Then for all x > 0, Sn = ni=1 ei , ! ςn n ke. kqq,α K3 x2 P(|Sn | ≥ x) ≤ K1 + K2 exp − xq n ke. k22,α where K1 , K2 , K3 are constants that depend only on q and α. Proof. See Wu and Wu (2016) Theorem 2. Lemma 2. Assume that ke. kq,0 < ∞, where q > 1. Let q 0 = min{2, q}. Then for Sn = Pn i=1 ei , 0 E(|Sn |q ) ≤ K0 nq/q ke. kqq,0 , where K0 is a constant that depends only on q. Proof. See Wu (2007). Lemma 3. Assume k|x. |∞ kq,α √ < ∞, where q > 2 and α > 0, and Ψ2,α < ∞, Tn = α > 1/2 − 1/q, then for x & n log pΨ2,α + n1/q (log p)3/2 k|x. |∞ kq,α , ! Kq,α n(log p)q/2 k|x. |∞ kqq,α Kq,α x2 P(|Tn |∞ ≥ x) ≤ + Kq,α exp − . xq nΨ22,α 20 Pn i=1 xi . (i) If (44) 0.06 0.04 AR−OLS AR−Lasso Lasso Nowcasting1 Lasso Nowcasting2 MIDAS C Nowcasting1 MIDAS C Nowcasting2 MIDAS D Nowcasting1 MIDAS D Nowcasting2 0.00 0.02 cumulative absolute errors 0.08 Absolute Errors 5 10 15 number of one−step ahead predictions (a) 0e+00 1e−04 2e−04 3e−04 4e−04 5e−04 6e−04 7e−04 cumulative squared errors Squared Errors AR−OLS AR−Lasso Lasso Nowcasting1 Lasso Nowcasting2 MIDAS C Nowcasting1 MIDAS C Nowcasting2 MIDAS D Nowcasting1 MIDAS D Nowcasting2 5 10 15 number of one−step ahead predictions (b) Figure 2: Panel (a): Cumulative absolute errors. Panel (b) Cumulative squared errors. MIDAS-D represents the MIDAS regression model with seven regressors z1,· , ..., z7,· . MIDAS-C represents the MIDAS regression model with nine regressors z1,· , ..., z9,· . Now-casting 1 and Now-casting 2 represent predicting quarterly GDP growth rate when the first month and the first two months 21 data are available, respectively. P(|Tn |∞ √ n log pΨ2,α + n1/2−α (log p)3/2 k|x. |∞ kq,α , ! Kq,α nq/2−αq (log p)q/2 k|x. |∞ kqq,α Kq,α x2 + Kq,α exp − , ≥ x) ≤ xq nΨ22,α (ii) If 0 < α < 1/2 − 1/q, then for x & (45) where Kq,α is a constant that depends on q and α only. Proof. See Zhang and Wu (2017) Theorem 6.2. Lemma 4. Let A and B denote two positive semi-definite, s-dimensional square matrices. If max1≤j,k≤s |Ajk − Bjk | ≤ δ, then inf |ζ|2 =1 ζ 0 Bζ > inf |ζ|2 =1 ζ 0 Aζ − sδ. Proof. See Medeiros and Mendes (2016) Lemma 3. Lemma 5. For Bn Dn √  λ −1 = < n β(1) − √ |Σ̂11 sign(β(1) )| , 2 n   λ −1 √ W (1) − W (2)| ≤ = |Σ̂21 Σ̂−1 sign(β )|) , (1 − | Σ̂ Σ̂ n n 21 11 (1) 11 2 n  |Σ̂−1 11 Wn (1)| P P(β̂ =s β) ≥ P(Bn ∩ Dn ), where Wn = √1n ni=1 xi ei and Wn (1), β(1) and Wn (2), β(2) denote the first s and last p − s entries of Wn and β respectively. Proof. See Zhao and Yu (2006) proposition 1. References Sumanta Basu and George Michailidis. Regularized estimation in sparse high-dimensional time series models. Ann. Statist., 43(4):1535–1567, 08 2015. 2, 6 Peter J. Bickel, Yaacov Ritov, and Alexandre B. Tsybakov. Simultaneous analysis of lasso and dantzig selector. Ann. Statist., 37(4):1705–1732, 08 2009. 2, 5 Peter Bühlmann and Sara Van De Geer. Statistics for high-dimensional data: methods, theory and applications. Springer Science & Business Media, 2011. 2, 14, 17 Emmanuel Candes and Terence Tao. The dantzig selector: Statistical estimation when p is much larger than n. Ann. Statist., 35(6):2313–2351, 12 2007. 2 Bradley Efron, Trevor Hastie, Iain Johnstone, and Robert Tibshirani. Least angle regression. Ann. Statist., 32(2):407–499, 04 2004. 2 Jianqing Fan and Runze Li. Variable selection via nonconcave penalized likelihood and its oracle properties. Journal of the American Statistical Association, 96(456):1348–1360, 2001. 2 Eric Ghysels, Pedro Santa-Clara, and Rossen Valkanov. The midas touch: Mixed data sampling regression models. Finance, 2004. 2, 3, 13 22 Shuva Gupta. A note on the asymptotic distribution of lasso estimator for correlated data. Sankhyā: The Indian Journal of Statistics, Series A (2008-), 74(1):10–28, 2012. 2 Anders Bredahl Kock and Laurent Callot. Oracle inequalities for high dimensional vector autoregressions. Journal of Econometrics, 186(2):325 – 344, 2015. 2 Marcelo C. Medeiros and Eduardo F. Mendes. L1-regularization of high-dimensional time-series models with non-gaussian and heteroskedastic errors. Journal of Econometrics, 191(1):255 – 271, 2016. 2, 9, 22 Nicolai Meinshausen and Bin Yu. Lasso-type recovery of sparse representations for high-dimensional data. Ann. Statist., 37(1):246–270, 02 2009. 2 James H. Stock and Mark W. Watson. Forecasting using principal components from a large number of predictors. J. Amer. Statist. Assoc., 97(460):1167–1179, 2002. 17 Hansheng Wang, Guodong Li, and Chih-Ling Tsai. Regression coefficient and autoregressive order shrinkage and selection via the lasso. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 69(1):63–78, 2007. ISSN 1467-9868. 2 Wei Biao Wu. Nonlinear system theory: Another look at dependence. Proceedings of the National Academy of Sciences of the United States of America, 102(40):14150–14154, 2005. 3, 4 Wei Biao Wu. Strong invariance principles for dependent random variables. Ann. Probab., 35(6): 2294–2320, 11 2007. 20 Wei-Biao Wu and Ying Nian Wu. Performance bounds for parameter estimates of high-dimensional linear models with correlated errors. Electron. J. Statist., 10(1):352–379, 2016. 2, 20 Ming Yuan and Yi Lin. Model selection and estimation in regression with grouped variables. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 68(1):49–67, 2006. ISSN 1467-9868. 2 Danna Zhang and Wei Biao Wu. Gaussian approximation for high dimensional time series. Ann. Statist., To appear, 2017. 22 Peng Zhao and Bin Yu. On model selection consistency of lasso. J. Mach. Learn. Res., 7:2541–2563, December 2006. ISSN 1532-4435. 2, 8, 9, 13, 22 Hui Zou. The adaptive lasso and its oracle properties. Journal of the American Statistical Association, 101(476):1418–1429, 2006. 2 23
10math.ST
COMPUTING THE PARTITION FUNCTION OF arXiv:1503.07463v4 [cs.DS] 29 Nov 2016 A POLYNOMIAL ON THE BOOLEAN CUBE Alexander Barvinok May 2016 Abstract. For a polynomial f : {−1, 1}n −→ C, we define the partition function as the average of eλf (x) over all points x ∈ {−1, 1}n , where λ ∈ C is a parameter. We present a quasi-polynomial algorithm, which, given such f , λ and ǫ > 0 approximates the partition within a relative error of ǫ in N O(ln n−ln ǫ) time provided √ function −1 |λ| ≤ (2L deg f ) , where L = L(f ) is a parameter bounding the Lipschitz constant of f from above and N is the number of monomials in f . As a corollary, we obtain a quasi-polynomial algorithm, which, given such an f with coefficients ±1 and such that every variable enters not more than 4 monomials, approximates the maximum  √ of f on {−1, 1}n within a factor of O δ −1 deg f , provided the maximum is Nδ for some 0 < δ ≤ 1. If every variable enters not more than k monomials for some fixed k > 4, we are able to establish a similar result when δ ≥ (k − 1)/k. 1. Introduction and main results (1.1) Polynomials and partition functions. Let {−1, 1}n be the n-dimensional Boolean cube, that is, the set of all 2n n-vectors x = (±1, . . . , ±1) and let f : {−1, 1}n −→ C be a polynomial with complex coefficients. We assume that f is defined as a linear combination of square-free monomials: f (x) = (1.1.1) X αI xI where I⊂{1,... ,n} and xI = Y xi αI ∈ C for for all I x = (x1 , . . . , xn ) , i∈I where we agree that x∅ = 1. As is known, the monomials xI for I ⊂ {1, . . . , n} constitute a basis of the vector space of functions f : {−1, 1}n −→ C. 1991 Mathematics Subject Classification. 90C09, 68C25, 68W25, 68R05. Key words and phrases. Boolean cube, polynomial, partition function, algorithm. This research was partially supported by NSF Grant DMS 1361541. 1 Typeset by AMS-TEX We introduce two parameters measuring the complexity of the polynomial f in (1.1.1). The degree of f is the largest degree of a monomial xI appearing in (1.1.1) with a non-zero coefficient, that is, the maximum cardinality |I| such that αI 6= 0: deg f = max |I|. I: αI 6=0 We also introduce a parameter which controls the Lipschitz constant of f : X |αI |. L(f ) = max i=1,... ,n I⊂{1,... ,n} i∈I Indeed, if dist is the metric on the cube, dist(x, y) = n X i=1 |xi − yi | where x = (x1 , . . . , xn ) and y = (y1 , . . . , yn ) then |f (x) − f (y)| ≤ L(f ) dist(x, y). We consider {−1, 1}n as a finite probability space endowed with the uniform measure. For λ ∈ C and a polynomial f : {−1, 1}n −→ C, we introduce the partition function X 1 eλf (x) = E eλf . 2n n x∈{−1,1} Our first main result bounds from below the distance from the zeros of the partition function to the origin. (1.2) Theorem. Let f : {−1, 1}n −→ C be a polynomial and let λ ∈ C be such that 0.55 √ |λ| ≤ . L(f ) deg f Then E eλf 6= 0. If, additionally, the constant term of f is 0 then E eλf ≥ (0.41)n . We prove Theorem 1.2 in Section 4. As a simple example, let f (x1 , . . . , xn ) = x1 + . . . + xn . Then n  λ   e + e−λ λf λx1 λxn . Ee = Ee ··· Ee = 2 2 We have L(f ) = deg f = 1 and Theorem 1.2 predicts that E eλf 6= 0 provided |λ| ≤ 0.55. Indeed, the smallest in the absolute value root of E eλf is λ = πi/2 with |λ| = π/2 ≈ 1.57. If we pick f (x1 , . . . , xn ) = ax1 + . . . + axn for some real constant a > 0 then the smallest in the absolute value root of E eλf is πi/2a with |λ| inversely proportional to L(f ), just as Theorem 1.2 predicts. It is not clear at the moment whether the dependence of the bound in Theorem 1.2 on deg f is optimal. As we will see shortly, Theorem 1.2 implies that E eλf can be efficiently computed if |λ| is strictly smaller than the bound in Theorem 1.2. When computing E eλf , we may assume that the constant term of f is 0, since E eλ(f +α) = eλα E eλf and hence adding a constant to f results in multiplying the partition function by a constant. For a given f , we consider a univariate function λ 7−→ E eλf . As follows from Theorem 1.2, we can choose a branch of  0.55 √ g(λ) = ln E eλf for |λ| ≤ L(f ) deg f such that g(0) = 0. It follows that g(λ) is well-approximated by a low degree Taylor polynomial at 0. (1.3) Theorem. Let f : {−1, 1}n −→ C be a polynomial with zero constant term and let  0.55 √ . g(λ) = ln E eλf for |λ| ≤ L(f ) deg f For a positive integer m ≤ 5n, let m X λk dk Tm (f ; λ) = g(λ) k! dλk λ=0 k=1 be the degree m Taylor polynomial of g(λ) computed at λ = 0. Then for n ≥ 2 50n + e−n |g(λ) − Tm (f ; λ)| ≤ (m + 1)(1.1)m provided 1 √ . (1.3.1) |λ| ≤ 2L(f ) deg f In Section 3, we deduce Theorem 1.3 from Theorem 1.2. As we discuss in Section 3.1, for a polynomial f given by (1.1.1), the value of Tm (f ; λ) can be computed in nN O(m) time, where N is the number of monomials in the representation (1.1.1). Theorem 1.3 implies that as long as ǫ ≫ e−n , by choosing m = O ln n − ln ǫ , we can compute the value of E eλf within relative error ǫ in N O(ln n−ln ǫ) time provided λ satisfies the inequality (1.3.1). For ǫ exponentially small in n, it is more efficient to evaluate E eλf directly from the definition. 3 (1.4) Relation to prior work. This paper is a continuation of a series of papers by the author [Ba15], [Ba16] and by the author and P. Soberón [BS14], [BS16] on algorithms to compute partition functions in combinatorics, see also [Re15]. The main idea of the method is that the logarithm of the partition function is wellapproximated by a low-degree Taylor polynomial at the temperatures above the phase transition (the role of the temperature is played by 1/λ), while the phase transition is governed by the complex zeros of the partition function, cf. [YL52], [LY52]. The main work of the method consists of bounding the complex roots of the partition function, as in Theorem 1.2. While the general approach of this paper looks similar to the approach of [Ba15], [Ba16], [BS14] and [BS16] (a martingale type and a fixed point type arguments), in each case bounding complex roots requires some effort and new ideas. Once the roots are bounded, it is relatively straightforward to approximate the partition function as in Theorem 1.3. Another approach to computing partition functions, also rooted in statistical physics, is the correlation decay approach, see [We06] and [BG08]. While we did not pursue that approach, in our situation it could conceivably work as follows: given a polynomial f : {−1, 1}n −→ R and a real λ > 0, we consider the Boolean cube as a finite probability space, where the probability of a point x ∈ {−1, 1}n is eλf (x) /E eλf . This makes the coordinates x1 , . . . , xn random variables. We consider a graph with vertices x1 , . . . , xn and edges connecting two vertices xi and xj if there is a monomial of f containing both xi and xj . This introduces a graph metric on the variables x1 , . . . , xn and one could hope that if λ is sufficiently small, we have correlation decay: the random variable xi is almost independent on the random variables sufficiently distant from xi in the graph metric. This would allow us to efficiently approximate the probabilities P (xi = 1) and P (xi = −1) and then recursively estimate E eλf . While both approaches treat the phase transition as a natural threshold for computability, the concepts of phase transition in our method (complex zeros of the partition function) and in the correlation decay approach (non-uniqueness of Gibbs measures) though definitely related and even equivalent for some spin systems [DS87], in general are different. Theorem 1.3 together with the algorithm of Section 3.1 below implies that to approximate E eλf within  a relative error of ǫ > 0, it suffices to compute moments k −1 E f for k = O ln ǫ . This suggests some similarity with one of the results of [K+96], where (among other results) it is shown that the number of satisfying assignments of a DNF on n Boolean variables is uniquely determined by the numbers of satisfying assignments for all possible conjunctions of k ≤ 1 + log2 n clauses of the DNF (though this is a purely existential result with no algorithm attached). 4 Each conjunction of the DNF can be represented as a polynomial φj (x) = 1 2|Sj | Y (1 + ǫi xi ) where i∈Sj Sj ⊂ {1, . . . , n} and and we let f (x) = m X ǫi ∈ {−1, 1}, φj (x). j=1 Then the number of points x ∈ {−1, 1}n such that f (x) > 0 is uniquely determined by various expectations E φj1 · · · φjk for k ≤ 1+log2 n. The probability that f (x) = 0 for a random point x ∈ {−1, 1}n sampled from the uniform distribution, can be approximated by E e−λf for a sufficiently large λ > 0. The expectations are precisely those that arise when we compute the moments E f k . It is not clear at the moment whether the results of this paper can produce an efficient way to compute the number of satisfying assignments. 2. Applications to optimization (2.1) Maximizing a polynomial on the Boolean cube. Let f : {−1, 1}n −→ R be a polynomial with real coefficients defined by its monomial expansion (1.1.1). As is known, various computationally hard problems of discrete optimization, such as finding the maximum cardinality of an independent set in a graph, finding the minimum cardinality of a vertex cover in a hypergraph and the maximum constraint satisfaction problem can be reduced to finding the maximum of f on the Boolean cube {−1, 1}n , see, for example, [BH02]. The problem is straightforward if deg f ≤ 1. If deg f = 2, it may already be quite hard even to solve approximately: Given an undirected  simple graph G = (V, E) V with set V = {1, . . . , n} of vertices and set E ⊂ 2 of edges, one can express the largest cardinality of an independent set (a set vertices no two of which are connected by an edge of the graph), as the maximum of n 1X 1 f (x) = (xi + 1) − 2 4 i=1 X (1 + xi ) (1 + xj ) {i,j}∈E on the cube {−1, 1}n . It is an NP-hard problem to approximate the size of the largest independent set in a given graph on n vertices within a factor of n1−ǫ for any 0 < ǫ ≤ 1, fixed in advance [Hå01], [Zu07]. If deg f = 2 and f does not contain linear or constant terms, the problem reduces to the max cut problem in a weighted graph (with both positive and negative weights allowed on the edges), where there exists a polynomial time algorithm achieving an O(ln n) approximation factor, see [KN12] for a survey. 5 If deg f ≥ 3, no efficient algorithm appears to be known that would outperform choosing a random point x ∈ {−1, 1}n . The maximum of a polynomial f with deg f = p3 and no  constant, linear or quadratic terms can be approximated within an O n/ ln n factor in polynomial time, see [KN12]. Finding the maximum of a general real polynomial (1.1.1) on the Boolean cube {−1, 1}n is equivalent to the problem of finding the maximum weight of a subset of a system of weighted linear equations over Z2 that can be simultaneously satisfied [HV04]. Assuming that deg f is fixed in advance, f contains N monomials and the constant term of f is 0, a√polynomial time algorithm approximating the maximum of f within a factor of O( N ) is constructed in [HV04]. More precisely, the algorithm from [HV04] √ P constructs a point x such that f (x) is within a factor of O( N ) from I |αI | for f defined by (1.1.1). If deg f ≥ 3, it is unlikely that a polynomial time algorithm 1−ǫ exists approximating the maximum of f within a factor of 2(ln N) for any fixed 0 < ǫ ≤ 1 [HV04], see also [Hå01]. Let us choose 1 √ λ= 2L(f ) deg f as in Theorem 1.3. As is discussed in Section 3.5, by successive conditioning, we can compute in N O(ln n−ln ǫ) time a point y ∈ {−1, 1}n which satisfies eλf (y) ≥ (1 − ǫ)E eλf (2.1.1) for any given 0 < ǫ ≤ 1. How well a point y satisfying (2.1.1) approximates the maximum value of f on the Boolean cube {−1, 1}n ? We consider polynomials with coefficients −1, 0 and 1, where the problem of finding an x ∈ {−1, 1}n maximizing f (x) is equivalent to finding a vector in Zn2 satisfying the largest number of linear equations from a given list of linear equations over Z2 . (2.2) Theorem. Let f (x) = X αI xI I∈F be a polynomial with zero constant term, where F is a family of non-empty subsets of the set {1, . . . , n} and αI = ±1 for all I ∈ F . Let max x∈{−1,1}n f (x) = δ|F | for some 0 ≤ δ ≤ 1. Suppose further that every variable xi enters at most four monomials xI for I ∈ F . Then   2 2 3λ δ λf |F | for 0 ≤ λ ≤ 1. Ee ≥ exp 16 Since E f = 0, the maximum of f is positive unless F = ∅ and f ≡ 0. It is not clear whether the restriction on the number of occurrences of variables in Theorem 2.2 is essential or an artifact of the proof. We can get a similar estimate for any number occurrences provided the maximum of f is sufficiently close to |F |. 6 (2.3) Theorem. Let f (x) = X αI xI I∈F be a polynomial with zero constant term, where F is a family of non-empty subsets of the set {1, . . . , n} and αI = ±1 for all I ∈ F . Let k > 2 be an integer and suppose that every variable xi enters at most k monomials xI for I ∈ F . If max x∈{−1,1}n then λf Ee ≥ exp  k−1 |F | k f (x) ≥ 3λ2 |F | 16  for all 0 ≤ λ ≤ 1. We prove Theorems 2.2 and 2.3 in Section 5. Let f be a polynomial of Theorem 2.2 and suppose that, additionally, |I| ≤ d for all I ∈ F , so that deg f ≤ d. We have L(f ) ≤ 4 and we choose 1 λ= √ . 8 d Let y ∈ {−1, 1}n be a point satisfying (2.1.1). Then f (y) ≥ ln(1 − ǫ) 3λδ 2 ln(1 − ǫ) 1 ln E eλf + ≥ |F | + . λ λ 16 λ That is, if the maximum of f is at least δ|F | for some 0 < δ ≤ can approximate  1, we √  −1 d . Equivalently, the maximum in quasi-polynomial time within a factor of O δ if for some 0 < δ ≤ 0.5 there is a vector in Zn2 satisfying at least (0.5 + δ)|F | equations of a set F of linear equations over Z2 , where each variable enters at most 4 equations, in quasi-polynomial time we can compute a vector v ∈ Zn2 satisfying √ at least (0.5 + δ1 )|F | linear equations from the system, where δ1 = Ω(δ 2 / d) and d is the largest number of variables per equation. Similarly, we can approximate in√quasi-polynomial time the maximum of f in Theorem 2.3 within a factor of O(k d) provided the maximum is sufficiently close to |F |, that is, is at least k−1 |F |. k In Theorems 2.2 and 2.3, one can check in polynomial time whether the maximum of f is equal to |F |, as this reduces to testing the feasibility of a system of linear equations over Z2 . However, for any fixed 0 < δ < 1, testing whether the maximum is at least δ|F | is computationally hard, cf. [Hå01]. Håstad [Hå00] constructed a polynomial time algorithm that approximates the maximum of f within a factor of O(kd). In [B+15], see also [Hå15], a polynomial √ algorithm is constructed that finds the maximum of f within a factor of eO(d) k, provided f is an odd function. More √ precisely, the algorithm finds a point x such O(d) k from |F |. that f (x) is within a factor of e 7 3. Computing the partition function  (3.1) Computing the Taylor polynomial of g(λ) = ln E eλf . First, we discuss how to compute the degree m Taylor polynomial Tm (f ; λ) at λ = 0 of the function  g(λ) = ln E eλf , see Theorem 1.3. Let us denote h(λ) = E eλf Then g′ = h′ h and g(λ) = ln h(λ). and hence h′ = g ′ h. Therefore, (3.1.1) (k) h  k  X k − 1 (j) g (0)h(k−j) (0) for (0) = j − 1 j=1 k = 1, . . . , m. If we calculate the derivatives (3.1.2) h(0), h(1) (0), . . . , h(m) (0), then we can compute g(0), g (1) (0), . . . , g (m) (0) by solving a non-singular triangular system of linear equations (3.1.1) which has h(0) = 1 on the diagonal. Hence our goal is to calculate the derivatives (3.1.2). We observe that X 1 f k (x) = E f k . h(k) (0) = n 2 n x∈{−1,1} For a polynomial f defined by its monomial expansion (1.1.1) we have E f = α∅ . We can consecutively compute the monomial expansion of f, f 2 , . . . , f m by using the following multiplication rule for monomials on the Boolean cube {−1, 1}n : xI xJ = xI∆J , where I∆J is the symmetric difference of subsets I, J ⊂ {1, . . . , n}. It follows then that for a polynomial f : {−1, 1}n −→ C given by its monomial expansion (1.1.1) and a positive integer m, the Taylor polynomial Tm (f ; λ) = m X λk dk g(λ) k! dλk k=1 λ=0 can be computed in nN O(m) time, where N is the number of monomials in f . Our next goal is deduce Theorem 1.3 from Theorem 1.2. The proof is based on the following lemma. 8 (3.2) Lemma. Let p : C −→ C be a univariate polynomial and suppose that for some β > 0 we have p(z) 6= 0 provided |z| ≤ β. Let 0 < γ < β and for |z| ≤ γ, let us choose a continuous branch of g(z) = ln p(z). Let m X z k dk g(z) Tm (z) = g(0) + k! dz k k=1 z=0 be the degree m Taylor polynomial of g(z) computed at z = 0. Then for τ= we have |g(z) − Tm (z)| ≤ β > 1 γ deg p (m + 1)τ m (τ − 1) for all |z| ≤ γ. Proof. Let n = deg p and let α1 , . . . , αn be the roots of p, so we may write  n  Y z 1− p(z) = p(0) αi i=1 |αi | ≥ β where Then g(z) = g(0) + n X i=1 for i = 1, . . . , n.   z ln 1 − , αi where we choose the branch of the logarithm which is 0 when z = 0. Using the Taylor series expansion of the logarithm, we obtain   m X z zk ln 1 − + ζm =− αi kαki provided k=1 where +∞ X zk |ζm | = − kαki k=m+1 Therefore, g(z) = g(0) − ≤ +∞ X k=m+1 |z| ≤ γ, γk 1 ≤ . k kβ (m + 1)τ m (τ − 1) n X m X zk + ηm k kα i i=1 k=1 9 for |z| ≤ γ, where n . (m + 1)τ m (τ − 1) |ηm | ≤ It remains to notice that n X m X zk Tm (z) = g(0) − . kαki i=1 k=1  Next, we need a technical bound on the approximation of ez by its Taylor polynomial. (3.3) Lemma. Let ρ > 0 be a real number and let m ≥ 5ρ be an integer. Then z e − m X zk k=0 ≤ e−2ρ k! for all z∈C such that |z| ≤ ρ. Proof. For all z ∈ C such that |z| ≤ ρ, we have ez − m X zk k=0 = k! +∞ X zk k! ≤ k=m+1 ≤ ρm+1 (m + 1)! +∞ X k=0 +∞ +∞ X ρk ρm+1 X ρk (m + 1)! = k! (m + 1)! (k + m + 1)! k=m+1 k=0 ρm+1 eρ ρm+1 eρ+m+1 ρk = ≤ . k! (m + 1)! (m + 1)m+1 Since m ≥ 5ρ, we obtain z e − +∞ k X z k=0 ≤ k! eρ eρ ρm+1 eρ+m+1 = ≤ ≤ e−2ρ . 5m+1 ρm+1 (5/e)m+1 (5/e)5ρ and the proof follows.  (3.4) Proof of Theorem 1.3. Without loss of generality, we assume that L(f ) = 1. Since the constant term of f is 0, for any x ∈ {−1, 1}n , we have |f (x)| ≤ n X X i=1 I: i∈I |αI | ≤ n. Applying Lemma 3.3, we conclude that (3.4.1) λf (x) e 5n X λf (x) − k! k=0 k ≤ e−2n 10 for all x ∈ {−1, 1}n provided |λ| ≤ 1. Let 5n X  λk dk λf E e p(λ) = 1 + k! dλk k=1 λ=0 be the degree 5n Taylor polynomial of the function λ 7−→ E eλf at λ = 0. From (3.4.1) it follows that E eλf − p(λ) ≤ e−2n provided |λ| ≤ 1. From Theorem 1.2, we conclude that p(λ) 6= 0 for all λ ∈ C 0.55 such that |λ| ≤ √ deg f and, moreover, (3.4.2) ln p(λ) − ln E eλf  ≤ e−n 0.55 |λ| ≤ √ deg f provided and n ≥ 2. Applying Lemma 3.2 with 0.55 β=√ , deg f γ=√ 0.5 deg f and τ= β = 1.1, γ we conclude that for the Taylor polynomial of ln p(λ) at λ = 0, Tm (λ) = ln p(0) + m X λk dk ln p(λ) k! dλk k=1 λ=0 we have (3.4.3) |Tm (λ) − ln p(λ)| ≤ 50n (m + 1)(1.1)m provided |λ| ≤ 1 . 2 deg f √ It remains to notice that the Taylor polynomials of degree m ≤ 5n of the functions λ 7−→ ln E eλf  and λ 7−→ ln p(λ) at λ = 0 coincide, since both are determined by the first m derivatives of respectively E eλf and p(λ) at λ = 0, cf. Section 3.1, and those derivatives coincide. The proof now follows by (3.4.2) – (3.4.3).  11 (3.5) Computing a point y in the cube with a large value of f (y). We discuss how to compute a point y ∈ {−1, 1}n satisfying (2.1). We do it by successive conditioning and determine one coordinate of y = (y1 , . . . , yn ) at a time. Let F + and F − be the facets of the cube {−1, 1}n defined by the equations xn = 1 and xn = −1 respectively for x = (x1 , . . . , xn ), x ∈ {−1, 1}n . Then F + and F − can be identified with the (n − 1)-dimensional cube {−1, 1}n−1 and we have E eλf =  1  1 E eλf |F + + E eλf |F − . 2 2 Moreover, for the restrictions f + and f − of f onto F + and F − respectively, considered as polynomials on {−1, 1}n−1 , we have deg f + , deg f − ≤ deg f and L(f + ), L(f − ) ≤ L(f ).  λf + Using the algorithm of Section 3.1 and Theorem 1.3, we compute E e and |F  λf − E e |F within a relative error ǫ/2n, choose the facet with the larger computed  λf + value, let yn = 1 if the value of E e |F appears to be larger and let yn = −1 if  λf − the value of E e |F appears to be larger and proceed further by conditioning on the value of yn−1 . For polynomials with N monomials, the complexity of the algorithm is N O(ln n) . 4. Proof of Theorem 1.2 To prove Theorem 1.2, we consider restrictions of the partition function onto faces of the cube. (4.1) Faces. A face F ⊂ {−1, 1}n consists of the points x where some of the coordinates of x are fixed at 1, some are fixed at −1 and others are allowed to vary (a face is always non-empty). With a face F , we associate three subsets I+ (F ), I− (F ), I(F ) ⊂ {1, . . . , n} as follows:  I+ (F ) = i : xi = 1 for all x ∈ F, x = (x1 , . . . , xn ) ,  I− (F ) = i : xi = −1 for all x ∈ F, x = (x1 , . . . , xn ) and I(F ) ={1, . . . , n} \ (I+ (F ) ∪ I− (F )) . Consequently, n F = (x1 , . . . , xn ) where i ∈ I+ (F ) and o for i ∈ I− (F ) . xi = 1 for xi = −1 In particular, if I+ (F ) = I− (F ) = ∅ and hence I(F ) = {1, . . . , n}, we have F = {−1, 1}n . We call the number dim F = |I(F )| 12 the dimension of F . For a subset J ∈ {1, . . . , n}, we denote by {−1, 1}J the set of all points x = (xj : j ∈ J) where xj = ±1. Let F ⊂ {−1, 1}n be a face. For a subset J ⊂ I(F ) and a point ǫ ∈ {−1, 1}J , ǫ = (ǫj : j ∈ J), we define  F ǫ = x ∈ F, x = (x1 , . . . , xn ) : xj = ǫj for j∈J . In words: F ǫ is obtained from F by fixing the coordinates from some set J ⊂ I(F ) of free coordinates to 1 or to −1. Hence F ǫ is also a face of {−1, 1}n and we think of F ǫ ⊂ F as a face of F . We can represent F as a disjoint union (4.1.1) [ F = Fǫ ǫ∈{−1,1}J for any J ⊂ I(F ). (4.2) The space of polynomials. Let us fix a positive integer d. We identify the set of all polynomials f as in (1.1.1) such that deg f ≤ d and the constant term of f is 0 with CN , where d   X n . N = N (n, d) = k k=1 For δ > 0, we consider a closed convex set U(δ) ⊂ CN consisting of the polynomials f : {−1, 1}n −→ C such that deg f ≤ d and L(f ) ≤ δ. In other words, U(δ) consists of the polynomials f (x) = X αI xI where X I: i∈I I⊂{1,... ,n} 1≤|I|≤d |αI | ≤ δ for i = 1, . . . , n. (4.3) Restriction of the partition function onto a face. Let f : {−1, 1}n −→ C be a polynomial and let F ⊂ {−1, 1}n be a face. We define  E ef |F = 1 2dim F X ef (x) . x∈F We suppose that f is defined by its monomial expansion as in (1.1.1) and consider 13  E ef |F as a function of the coefficients αI . Using (4.1.1) we deduce  ∂ 1 X J f (x) x e E ef |F = dim F ∂αJ 2 x∈F = (4.3.1) × |I− (F )∩J| (−1) 2|I(F )| X ǫ∈{−1,1}I(F )∩J ǫ=(ǫj : j∈I(F )∩J)  Y  j∈I(F )∩J (−1)|I− (F )∩J| 2|I(F )∩J|  X  ×  ǫj  X ef (x) x∈F ǫ = ǫ∈{−1,1}I(F )∩J ǫ=(ǫj : j∈I(F )∩J) Y j∈I(F )∩J   ǫj  E ef |F ǫ . In what follows, we identify complex numbers with vectors in R2 = C and measure angles between non-zero complex numbers. (4.4) Lemma. Let 0 < τ ≤ 1 and δ > 0 be real numbersand let F ⊂ {−1, 1}n be a face. Suppose that for every f ∈ U(δ) we have E ef |F = 6 0 and, moreover, for any K ⊂ I(F ) we have f E e |F  ≥  τ |K| 2 X ǫ∈{−1,1}K E ef , F ǫ  . Given f ∈ U(δ) and a subset J ⊂ {1, . . . , n} such that |J| ≤ d, let fb ∈ U(δ) be the polynomial obtained from f by changing the coefficient αJ of the monomial xJ in f to −αJ and leaving all other coefficients intact.  Then the angle between the two  f fb non-zero complex numbers E e |F and E e |F does not exceed 2|αJ | . τd Proof. Without loss of generality, we assume that αJ 6= 0.  f We note that for any f ∈ U(δ), we have fb ∈ U(δ). Since E e |F 6= 0 for all  f f ∈ U(δ), we may consider a branch of ln E e |F for f ∈ U(δ). Let us fix coefficients αI for I 6= J in X αI xI (4.4.1) f (x) = I⊂{1,... ,n} 1≤|I|≤d 14 and define a univariate function g(α) = ln E ef |F  where |α| ≤ |αJ | obtained by replacing αJ with α in (4.4.1). We obtain (4.4.2) Let  ∂ g (α) = ln E ef |F = ∂αJ ′    .  ∂ f E e |F E ef |F . ∂αJ k = |I(F ) ∩ J| ≤ |J| ≤ d. Using (4.3.1) we conclude that (4.4.3)  1 ∂ E ef |F ≤ k ∂αJ 2 X ǫ∈{−1,1}I(F )∩J E ef |F ǫ  . On the other hand, (4.4.4) f E e |F  ≥  τ k 2 X ǫ∈{−1,1}I(F )∩J E ef |F ǫ  . Comparing (4.4.2) - (4.4.4), we conclude that |g ′ (α)| = Then  1 1 ∂ ln E ef |F ≤ k ≤ d. ∂αJ τ τ    2|αJ | b ln E ef |F − ln E ef |F = |g (αJ ) − g (−αJ )| ≤ 2|αJ | max |g ′ (α)| ≤ |α|≤|αJ | τd and the proof follows.  (4.5) Lemma. Let θ ≥ 0 and δ > 0 be real numbers such that θδ <  π, let F ⊆ {−1, 1}n be a face such that dim F < n and suppose that E ef |F 6= 0 for all f ∈ U(δ). Assume that for any f ∈ U(δ), for any J ⊂ {1, . . . , n} such that |J| ≤ d, and for the polynomial fb obtained from f by changing the coefficient αJ to −αJ and leaving all other intact, the angle between non-zero complex numbers  coefficients   f fb E e |F and E e |F does not exceed θ|αJ |. Suppose that Fb ⊂ {−1, 1}n is a face obtained from F by changing the sign of one of the coordinates in I+ (F ) ∪ I− (F ). Then G = F ∪ Fb is a face of {−1, 1}n and for θδ τ = cos 2 15 we have for any f ∈ U(δ).     τ E ef |G ≥ E ef |F + E ef |Fb 2 Proof. Suppose that Fb is obtained from F by changing the sign of the i-th coordinate. Let f˜ be a polynomial obtained from f by replacing the coefficients αI by −αI whenever i ∈ I and leaving allothercoefficients intact. Then f˜ ∈ U(δ) and  ˜ the angle between E ef |F and E ef |F does not exceed θ X I: i∈I  f˜ On the other hand, E e |F   |αI | ≤ θδ.  b = E e |F and f  1  1  1   1  ˜  E ef |G = E ef |F + E ef |Fb = E ef |F + E ef |F . 2 2 2 2  Thus E ef |G is the sum of two non-zero complex numbers, the angle between which does not exceed θδ < π. Interpreting the complex numbers as vectors in R2 = C, we conclude that the length of the sum is at least as large as the length of the sum of the orthogonal projections of the vectors onto the bisector of the angle between them, and the proof follows.  (4.6) Proof of Theorem 1.2. Let us denote d = deg f . One can observe that the equation 2   =θ θβ cos 2 has a solution θ ≥ 0 for all sufficiently small β > 0. Numerical computations show that one can choose β = 0.55, in which case θ ≈ 2.748136091. Let 0.55 β δ= √ = √ . d d We observe that 0 < θδ ≤ θβ ≈ 1.511474850 < π. Let τ = cos θδ θβ = cos √ . 2 2 d 16 In particular, τ ≥ cos θβ ≈ 0.7277659962. 2 Next, we will use the inequality (4.6.1)  α cos √ d d ≥ cos α for 0≤α≤ π 2 d ≥ 1. and One can obtain (4.6.1) as follows. Since tan(0) = 0 and the function tan α is convex for 0 ≤ α < π/2, we have √ α d tan √ ≤ tan α d for 0≤α< π . 2 Integrating, we obtain α d ln cos √ ≥ ln cos α d for 0≤α< π 2 and (4.6.1) follows. Using (4.6.1), we obtain (4.6.2) 2 2 2   = θ.  d =  d ≤ θβ θβ cos 2 cos θδ cos 2√d 2 We prove by induction on m = 0, 1, . . . , n the following three statements. (4.6.3) Let F ⊂ {−1, 1}n be a face of dimension m. Then, for any f ∈ U(δ), we have E ef |F 6= 0. (4.6.4) Let F ⊂ {−1, 1}n be a face of dimension m, let f ∈ U(δ) and let fb be a polynomial obtained from f by changing one of the coefficients αJ to −αJ and leaving all other coefficients  intact.  Then the angle between two non-zero complex  f fb numbers E e |F and E e |F does not exceed θ|αJ |. (4.6.5) Let F ⊂ {−1, 1}n be a face of dimension m and let f ∈ U(δ). Assuming that m > 0 and hence I(F ) 6= ∅, let us choose any i ∈ I(F ) and let F + and F − be the corresponding faces of F obtained by fixing xi = 1 and xi = −1 respectively. Then    τ E ef |F + + E ef |F − . E ef |F ≥ 2 If m = 0 then F consists of a single point x ∈ {−1, 1}n , so  E ef |F = ef (x) 6= 0 17 and (4.6.3) holds. Assuming that fb is obtained from f by replacing the coefficient αJ with −αJ and leaving all other coefficients intact, we get   E ef |F   = exp 2αJ xJ . E efb|F Since |2αJ xJ | = 2|αJ | ≤ θ|αJ |,    f fb the angle between E e |F and E e |F does not exceed θ|αJ | and (4.6.4) follows. The statement (4.6.5) is vacuous for m = 0. Suppose that (4.6.3) and (4.6.4) hold for faces of dimension m < n. Lemma 4.5 implies that if F is a face of dimension m + 1 and F + and F − are m-dimensional faces obtained by fixing xi for some i ∈ I(F ) to xi = 1 and xi = −1 respectively, then      E ef |F + + E ef |F − θδ f E e |F ≥ cos 2 2   τ = E ef |F + + E ef |F − 2 and the statement (4.6.5) holds for (m + 1)-dimensional faces. The statement (4.6.5) for (m + 1)-dimensional faces and the statement (4.6.3) for m-dimensional faces imply the statement (4.6.3) for (m + 1)-dimensional faces. Finally, suppose that the statements (4.6.3) and (4.6.5) hold for all faces of dimension at most m + 1. Let us pick a face F ⊂ {−1, 1}n of dimension m + 1, where 0 ≤ m < n. Applying the condition of statement (4.6.5) recursively to the faces of F , we get that for any K ⊂ I(F ), E ef |F  ≥  τ |K| 2 X ǫ∈{−1,1}K E ef |F ǫ  . Then, by 4.4, the angle between two non-zero complex numbers E ef |F  Lemma  b and E ef |F does not exceed 2|αJ | 2|αJ | = d ≤ θ|αJ | d τ cos θδ 2  by (4.6.2), and the statement (4.6.4) follows for faces of dimension m + 1. This proves that (4.6.3) – (4.6.5) hold for faces F of all dimensions. Iterating (4.6.5), we obtain that for any f ∈ U(δ), we have  τ n X f |ef (x) |. Ee ≥ 2 n x∈{−1,1} 18 Since for any x ∈ {−1, 1}n and for any f ∈ U(δ), we have |f (x)| ≤ n X X i=1 I⊂{1,... ,n} i∈I we conclude that E ef |αI | ≤ nδ ≤ βn, ≥ τ n e−βn ≥ (0.41)n . The proof follows since if f : {−1, 1}n −→ C is a polynomial with zero constant term and 0.55 √ , |λ| ≤ L(f ) deg f then λf ∈ U(δ).  5. Proofs of Theorems 2.2 and 2.3 The proofs of Theorems 2.2 and 2.3 are based on the following lemma. (5.1) Lemma. Let f (x) = X αI xI I∈F be a polynomial such that αI ≥ 0 for all I ∈ F . Then Y  eαI + e−αI  f . Ee ≥ 2 I∈F Proof. Since αx e =  eα + e−α 2 we have (5.1.1) f Ee = E Y I∈F Since αI x I e  +x  eα − e−α 2  for x = ±1,  αI  Y  eαI + e−αI  e − e−αI I =E +x . 2 2 I∈F eαI − e−αI ≥ 0 provided 2 and E xI1 · · · xIk  αI ≥ 0 ≥ 0 for all I1 , . . . , Ik , expanding the product in (5.1.1) and taking the expectation, we get the desired inequality.  Next, we prove a similar estimate for functions f that allow some monomials with negative coefficients. 19 (5.2) Lemma. Let f (x) = g(x) − h(x) where X X g(x) = xI , h(x) = xI , I∈G I∈H G ∩ H = ∅. Suppose that the constant terms of g and h are 0 and that every variable xi enters not more than k monomials of f for some integer k > 0. Then  2  3λ λf Ee ≥ exp (|G| − (k − 1)|H|) for 0 ≤ λ ≤ 1. 8 Proof. Since E f = 0, by Jensen’s inequality we have E eλf ≥ 1 and the estimate follows if |G| ≤ (k − 1)|H|. Hence we may assume that |G| > (k − 1)|H|. Given a function f : {−1, 1}n −→ R and a set J ⊂ {1, . . . , n} of indices, we define a function (conditional expectation) fJ : {−1, 1}n−|J| −→ R obtained by averaging over variables xj with j ∈ J: 1 X f (x1 , . . . , xn ) . fJ (xi : i ∈ / J) = |J| 2 x =±1 j j∈J In particular, fJ = f if J = ∅ and fJ = E f if J = {1, . . . , n}. We obtain the monomial expansion of fJ by erasing all monomials of f that contain xj with j ∈ J. By Jensen’s inequality we have (5.2.1) E eλf ≥ E eλfJ for all real λ. Let us choose a set J of indices with |J| ≤ |H| such that every monomial in h(x) contains at least one variable xj with j ∈ J. Then every variable xj with j ∈ J is contained in at most (k − 1) monomials of g(x) and hence fJ is a sum of at least |G| − (k − 1)|H| monomials. From (5.2.1) and Lemma 5.1, we obtain |G|−(k−1)|H| |G|−(k−1)|H|   λ λ2 e + e−λ λf λfJ . ≥ 1+ Ee ≥ Ee ≥ 2 2 Using that (5.2.2)  x2 x ln(1 + x) ≥ x − =x 1− 2 2 for x ≥ 0, we conclude that    2   2 λ2 3λ λ λf 1− (|G| − (k − 1)|H|) ≥ exp (|G| − (k − 1)|H|) Ee ≥ exp 2 4 8 as desired. Now we are ready to prove Theorem 2.3. 20  (5.3) Proof of Theorem 2.3. Let x0 ∈ {−1, 1}n , x0 = (ξ1 , . . . , ξn ) be a maximum point of f , so that max n f (x) = f (x0 ). x∈{−1,1} Let us define f˜ : {−1, 1}n −→ R by f˜ (x1 , . . . , xn ) = f (ξ1 x1 , . . . , ξn xn ) . Then max f (x) = x∈{−1,1}n max x∈{−1,1}n f˜(x), ˜ E eλf = E eλf and the maximum value of f˜ on the cube {−1, 1}n is attained at u = (1, . . . , 1). Hence without loss of generality, we may assume that the maximum value of f on the cube {−1, 1}n is attained at u = (1, . . . , 1). We write X X f (x) = g(x) − h(x) where g(x) = xI and h(x) = xI I∈G I∈H for some disjoint sets G and H of indices. Moreover, max x∈{−1,1}n f (x) = f (u) = |G| − |H| ≥ k−1 |F |. k Since |G| + |H| = |F |, we conclude that |G| ≥ 2k − 1 |F | and 2k |H| ≤ 1 |F |. 2k By Lemma 5.2, λf Ee ≥ exp    2  3λ 3λ2 (|G| − (k − 1)|H|) ≥ exp |F | 8 16 as desired. To prove Theorem 2.2, we need to handle negative terms with more care. (5.4) Lemma. Let f (x) = g(x) − h(x) where X X xI , g(x) = xI , h(x) = I∈G I∈H and |G| ≥ |H|. 21 G ∩H =∅  Suppose that the constant terms of g and h are 0 and that the supports I ∈ H of monomials in h(x) are pairwise disjoint. Then λf ≥ exp Ee   p 2 3λ2 p |G| − |H| 8 for 0 ≤ λ ≤ 1. Proof. By Jensen’s inequality we have E eλf ≥ exp {λE f } = 1, which proves the lemma in the case when |G| = |H|. Hence we may assume that |G| > |H|. If |H| = 0 then, applying Lemma 5.1, we obtain λf Ee λg ≥ = Ee  eλ + e−λ 2 |G|  |G| λ2 ≥ 1+ . 2 Using (5.2.2), we conclude that λf Ee ≥ exp  λ2 2     2  λ2 3λ 1− |G| ≥ exp |G| , 4 8 which proves the lemma in the case when |H| = 0. Hence we may assume that |G| > |H| > 0. Since the supports I ∈ H of monomials in h are pairwise disjoint, we have λh (5.4.1) Ee = Y λxI Ee = I∈H  eλ + e−λ 2 |H| . Let us choose real p, q ≥ 1, to be specified later, such that 1 1 + = 1. p q Applying the Hölder inequality, we get λg/p Ee   λf /p λh/p ≤ =E e e and hence λf Ee ≥  λf 1/p Ee p E eλg/p p/q . E eλqh/p 22  λqh/p Ee 1/q Applying Lemma 5.1 and formula (5.4.1), we obtain λf Ee ≥  eλ/p + e−λ/p 2 Since x2 /2 e we obtain λf Ee |G|p  −|H|p/q eλq/p + e−λq/p 2 ex + e−x x2 ≥ ≥ 1+ 2 2 . x ≥ 0, for  |G|p  2  λ q|H| λ2 . exp − ≥ 1+ 2 2p 2p Applying (5.2.2), we obtain λf Ee Let us choose ≥ exp  λ2 |G| λ2 q|H| λ4 |G| − − 2p 2p 8p3 p |G| p p= p |G| − |H| Then    λ2 p p q=p and 4 2 λ |H| − p |G| |H|  . . p 3   |H|  |G| − p   8 |G| 2  p   p   2   λ2 p  |G| − |H| λ p 2   p |G| − |H| 1− = exp  2 4 |G|  2  p 2 3λ p ≥ exp |G| − |H| 8 E eλf ≥ exp |G| − p and the proof follows. (5.5) Lemma. Let f (x) = g(x) − h(x) where X X xI , h(x) = xI , g(x) = I∈G I∈H  G ∩H =∅ and |G| ≥ |H|. Suppose that the constant terms of g and h are 0, that every variable xi enters at most two monomials in h(x) and that if xi enters exactly two monomials in h(x) then xi enters at most two monomials in g(x). Then for 0 ≤ λ ≤ 1, we have   2 p 2 3λ p λf |G| − |H| . Ee ≥ exp 8 23 Proof. We proceed by induction on the number k of variables xi that enter exactly two monomials in h(x). If k = 0 then the result follows by Lemma 5.4. Suppose that k > 0 and that xi is a variable that enters exactly two monomials in h(x) and hence at most two monomials in g(x). As in the proof of Lemma 5.2, let fi : {0, 1}n−1 −→ R be the polynomial obtained from f by averaging with respect to xi . As in the proof of Lemma 5.2, we have E eλf ≥ E eλfi where fi (x) = X I∈Gi xI − X xI I∈Hi and Gi , respectively Hi , is obtained from G, respectively H, by removing supports of monomials containing xi . In particular, |Hi | = |H| − 2 and |Gi | ≥ |G| − 2. Applying the induction hypothesis to fi , we obtain λf Ee  2  p 3λ2 p ≥ Ee ≥ exp |Gi | − |Hi | 8  2  2  2  p p 2 3λ p 3λ p ≥ exp |G| − 2 − |H| − 2 ≥ exp |G| − |H| 8 8 λfi and the proof follows.  Finally, we are ready to prove Theorem 2.2. (5.6) Proof of Theorem 2.2. As in the proof of Theorem 2.3 of Section 5.3, without loss of generality we may assume that the maximum of f is attained at u = (1, . . . , 1). We write X X f (x) = g(x) − h(x) where g(x) = xI and h(x) = xI I∈G I∈H for some disjoint sets G and H of indices. Moreover, max x∈{−1,1}n f (x) = f (u) = |G| − |H| = δ|F |. Since |G| + |H| = |F |, we conclude that (5.6.1) |G| = 1+δ |F | and 2 24 |H| = 1−δ |F |. 2 For i = 1, . . . , n let µ+ i be the number of monomials in g that contain variable i and let µ− be the number of monomials in h that contain xi . Then i − µ+ i + µi ≤ 4 (5.6.2) for i = 1, . . . , n. − If for some i we have µ+ i < µi then for the point ui obtained from u by switching the sign of the i-th coordinate, we have    + > f (u), = |G| − |H| + 2 µ− − |H| − 2µ− f (ui ) = |G| − 2µ+ i − µi i i contradicting that u is a maximum point of f . Therefore, − µ+ i ≥ µi for i = 1, . . . , n and, in view of (5.6.2), we conclude that i = 1, . . . , n and if µ− i = 2 then µ− i ≤ 2 for By Lemma 5.5, λf Ee ≥ exp Using (5.6.1), we deduce that   3λ2 r  µ+ i = 2.  p 2 3λ2 p |G| − |H| . 8 r !2   1−δ |F |   8 2   2 2   2  p 3λ δ 3λ 2 1 − 1 − δ |F | ≥ exp |F | , = exp 8 16 E eλf ≥ exp 1+δ − 2 which completes the proof.  Acknowledgments I am grateful to Johan Håstad for advice and references on optimizing a polynomial on the Boolean cube and to the anonymous referees for careful reading of the paper and useful suggestions. References [B+15] [BG08] B. Barak, A. Moitra, R. O’Donnell, P. Raghavendra, O. Regev, D. Steurer, L. Trevisan, A. Vijayaraghavan, D.Witmer and J. Wright, Beating the random assignment on constraint satisfaction problems of bounded degree, ECCC preprint TR15-082 (2015). A. Bandyopadhyay and D. Gamarnik, Counting without sampling: asymptotics of the log-partition function for certain statistical physics models, Random Structures & Algorithms 33 (2008), no. 4, 452–479. 25 [Ba15] A. Barvinok, Computing the partition function for cliques in a graph, Theory of Computing 11 (2015), Article 13, 339–355. [Ba16] A. Barvinok, Computing the permanent of (some) complex matrices, Foundations of Computational Mathematics 16 (2016), issue 2, 329–342. [BS14] A. Barvinok and P. Soberón, Computing the partition function for graph homomorphisms, preprint arXiv:1406.1771, to appear in Combinatorica (2014). [BS16] A. Barvinok and P. Soberón, Computing the partition function for graph homomorphisms with multiplicities, Journal of Combinatorial Theory, Series A 137 (2016), 1–26. [BH02] E. Boros and P.L. Hammer, Pseudo-Boolean optimization, Workshop on Discrete Optimization, DO’99 (Piscataway, NJ), Discrete Applied Mathematics 123 (2002), no. 1–3, 155–225. [DS87] R.L. Dobrushin and S.B. Shlosman, Completely analytical interactions: constructive description, Journal of Statistical Physics 46 (1987), no. 5–6, 983–1014. [Hå00] J. Håstad, On bounded occurrence constraint satisfaction, Information Processing Letters 74 (2000), no. 1–2, 1–6. [Hå01] J. Håstad, Some optimal inapproximability results, Journal of the ACM 48 (2001), no. 4, 798–859. [Hå15] J. Håstad, Improved bounds for bounded occurrence constraint satisfaction, manuscript, available at https://www.nada.kth.se/∼johanh/bounded2.pdf (2005). [HV04] J. Håstad and S. Venkatesh, On the advantage over a random assignment, Random Structures & Algorithms 25 (2004), no. 2, 117–149. [K+96] J. Kahn, N. Linial and A. Samorodnitsky, Inclusion-exclusion: exact and approximate, Combinatorica 16 (1996), no. 4, 465–477. [KN12] S. Khot and A. Naor, Grothendieck-type inequalities in combinatorial optimization, Communications on Pure and Applied Mathematics 65 (2012), no. 7, 992–1035. [LY52] T.D. Lee and C.N. Yang, Statistical theory of equations of state and phase transitions. II. Lattice gas and Ising model, Physical Review (2) 87 (1952), 410–419. [Re15] G. Regts, Zero-free regions of partition functions with applications to algorithms and graph limits, preprint arXiv:1507.02089 (2015). [We06] D. Weitz, Counting independent sets up to the tree threshold, STOC’06: Proceedings of the 38th Annual ACM Symposium on Theory of Computing, ACM, New York, 2006, pp. 140–149. [YL52] C.N. Yang and T.D. Lee, Statistical theory of equations of state and phase transitions. I. Theory of condensation, Physical Review (2) 87 (1952), 404–409. [Zu07] D. Zuckerman, Linear degree extractors and the inapproximability of max clique and chromatic number, Theory of Computing 3 (2007), 103–128. Department of Mathematics, University of Michigan, Ann Arbor, MI 48109-1043, USA E-mail address: [email protected] 26
8cs.DS
arXiv:1611.00606v1 [cs.CE] 31 Oct 2016 Hybrid CPU-GPU generation of the Hamiltonian and Overlap matrices in FLAPW methods Diego Fabregat-Traver∗, Davor Davidović†, Markus Höhnerbach∗ , and Edoardo di Napoli‡∗ ⋆ AICES, RWTH Aachen, Germany † RBI, Zagreb, Croatia ‡ JSC and JARA, Jülich, Germany [email protected], [email protected], [email protected], [email protected] Abstract. In this paper we focus on the integration of high-performance numerical libraries in ab initio codes and the portability of performance and scalability. The target of our work is FLEUR, a software for electronic structure calculations developed in the Forschungszentrum Jülich over the course of two decades. The presented work follows up on a previous effort to modernize legacy code by re-engineering and rewriting it in terms of highly optimized libraries. We illustrate how this initial effort to get efficient and portable shared-memory code enables fast porting of the code to emerging heterogeneous architectures. More specifically, we port the code to nodes equipped with multiple GPUs. We divide our study in two parts. First, we show considerable speedups attained by minor and relatively straightforward code changes to off-load parts of the computation to the GPUs. Then, we identify further possible improvements to achieve even higher performance and scalability. On a system consisting of 16-cores and 2 GPUs, we observe speedups of up to 5× with respect to our optimized shared-memory code, which in turn means between 7.5× and 12.5× speedup with respect to the original FLEUR code. 1 Introduction Many legacy codes in scientific computing have grown over time with an eye on functionality, but little emphasis on portable performance and scalability. Often, these codes are a direct translation of mathematical formulae, and lack proper engineering (i.e. modularity, code reuse, etc). One such example is FLEUR, a software for electronic structure calculations developed at the Jülich Research Center during the last two decades [3]. In previous work by Di Napoli et al. [2], the authors made the effort of reengineering a portion of FLEUR’s code base in an attempt to demonstrate the value of writing the computational bottlenecks in terms of kernels provided by standardized and highly-tuned libraries. There, they show an increase in performance and anticipate its portability beyond multi-core architectures. In this paper, we confirm that the reengineering process indeed guarantees quick portability and high-performance on emerging heterogeneous architectures, as in the case of multi-core CPUs equipped with one or more coprocessors such as GPUs. In times where massively-parallel heterogeneous architectures have become the most common computing platform, legacy scientific code has to be modernized. New software is often designed with portable efficiency and scalability in mind, and some old code is undergoing major rewriting to adapt to the newest architectures. However, there is still a lot of reluctance to undergo through the rewriting process since it requires a vast initial effort and may incur in validation issues. While it is understandable that domain scientists are hesitant to introduce major changes into a code developed and tested in the course of many years, legacy codes that do not go through this process are destined to be marginalized. A critical insight in writing long-lasting scientific code is to have a modular design where, at the bottom layers, the computational bottlenecks are written in terms of kernels available from standardized and highly-tuned libraries. Examples of such kernels are fast Fourier transforms, matrix products, and eigensolvers, provided by a number of commercial as well as academic libraries. The most prominent example of standard and optimized scientific library is the Basic Linear Algebra Subprograms (BLAS). This library has its roots in the early realization of the necessity for portable performance. Today, BLAS kernels, which include matrix products and linear systems, are the building blocks for a multitude of libraries, so much that BLAS is the first library to be ported to and optimized for every new architecture. Therefore, writing code on top of BLAS and other standardized and broadly available libraries constitutes a first and essential step in the modernization of scientific software. In this paper we follow the same approach illustrated in [2], where the authors made a major effort to address the computational bottlenecks of the FLEUR’s code base: the generation of the so-called Hamiltonian and Overlap matrices. In generating such matrices, the main goal of the original FLEUR code was the minimization of memory usage. Furthermore there is no notion of abstraction and encapsulation, and the different modules are tightly coupled. At this point, low-level optimizations were unfeasible, and the authors opted for a clean slate approach: starting from the mathematical formulation behind the code, they cast it in terms of matrix operations supported by the BLAS and LAPACK libraries. As presented in their results, despite lacking some mathematical insight that reduced the amount of computation in the FLEUR code, HSDLA (the new code) outperformed the original one with speedups between 1.5× and 2.5×. Most importantly, the authors claim that HSDLA could be easily ported to other architectures. In this paper, we continue their work, and illustrate how such an initial reengineering effort enables a quick port to heterogeneous architectures consisting of multi-core CPUs and one or more GPUs. More specifically, we quantify the minimal effort required in terms of additional code to attain substantial speedups. When running on a system equipped with two GPUs, we observe speedups of up to 5× with respect to HSDLA and about one order of magnitude with respect to the corresponding FLEUR code. Moreover, we identify the additional work required to attain close-to-optimal efficiency and scalability, and partially implement it to illustrate the idea. Finally, beyond the results specific to the case of FLEUR, the main contribution of this paper is to demonstrate that, despite the major initial effort, a reengineering of legacy codes is not only worth it but imperative in order to obtain long-lasting portable performance and scalability. This paper is organized as follows. Section 1.1 provides the background on Density Functional Theory (DFT) and the math behind the computation to generate the Hamiltonian and Overlap matrices. Section 2 gives an overview of the optimized algorithm behind HSDLA for the generation of these matrices. In Sec. 3 we discuss the porting of the code to heterogeneous architectures, including a review of the available BLAS libraries for GPUs and a simple analysis of the computation to decide which portions of the code to off-load to the GPUs. Section 4 presents experimental results for 1, 2 and 4 GPUs, and points at potential improvements to the hybrid code. Finally, Sec. 5 draws conclusion and discusses future research directions. 1.1 DFT, FLAPW and the H and S matrices The FLEUR code is based on the widely accepted framework of Density Functional Theory (DFT). In the last decade, Density Functional Theory (DFT) [6,7] has become the “standard model” in Materials Science. Within the DFT framework, it is possible to simulate the physical properties of complex quantum mechanical systems made of few dozens up to few hundreds of atoms. The core of the method relies on the simultaneous solution of a set of Schrödinger-like equations. These equations are determined by a Hamiltonian operator Ĥ containing an effective potential V0 [n] that depends functionally on the one-particle electron density n(r). In turn, the solutions of the equations ψi (r) determine the one-particle electron density n(r) used in calculating the effective potential V0 .  2  ~ Ĥψi (r) = − 2m ∇2 + V0 (r) ψi (r) = ǫi ψi (r) ; ǫ1 ≤ ǫ2 ≤ . . . (1) P 2 n(r) = N i |ψi (r)| In practice, this set of equations, also known as Kohn-Sham (KS) [5], is solved self-consistently; an initial guess for n0 (r) is used to calculate the effective potential V0 which, in turn, is inserted in Eq. (1) whose solutions, ψi (r), are used to compute a new charge density n1 (r). Convergence is checked by comparing the new density to the starting one. When convergence is not reached, an opportune mixing of the two densities is selected as a new guess, and the process is repeated. This is properly called a Self-Consistent Field (SCF) iteration. In principle, the theory only requires as input the quantum numbers and the positions of the atoms that are part of the investigated system. In practice, there is a plethora of DFT methods which depends on the discretization used to parameterize the KS equations. The discretization in the Full-potential Linearized Augmented Plane Wave (FLAPW) method [10,4] is based on plane wave expansion of ψk,ν (r), where the momentum vector k and the band index ν replace the P generic index i. The k-point wave function ψk,ν (r) = |G+k|≤Kmax cG k,ν ϕG (k, r) is expanded in terms of a basis set ϕG (k, r) indexed by the vectors G lying in the lattice reciprocal to configuration space up to a chosen cut-off value Kmax . In FLAPW, the physical (configuration) space of the simulation cell is divided into spherical regions, called Muffin-Tin (MT) spheres, centered around atomic nuclei, and interstitial areas between the MT spheres. The basis set ϕG (k, r) takes a different expression depending on the region  i(k+G)r Interstitial  eX h i a,G a,G a a th ϕG (k, r) ∝ A (k)u (r) + B (k) u̇ (r) Y (r̂ ) a Muffin Tin (2) l,m a l l l,m l,m  l,m a,G where the coefficients Aa,G l,m (k) and Bl,m (k) are determined by imposing continuity of ϕG (k, r) and its derivative at the boundary of the MTs. Due to this expansionP the KS equations naturally translate to a set of generalized eigenvalue ′ problems G′ [HG,G′ (k) − λkν SG,G′ (k)] cG k,ν = 0 for the coefficients of the ex′ pansion cG k,ν where the Hamiltonian and Overlap matrices H and S are given by multiple integrals and sums X ZZ {H(k), S(k)}G,G′ = (3) ϕ∗G (k, r){Ĥ, I}ϕG′ (k, r)dr. a Since the set of basis functions in Eq. (2) is implicitly labeled by the values the variable k takes in the Brillouin zone, there are multiple Hamiltonian and Overlap matrices, one for each independent k-point. Without loss of generality, we can abstract from the k-point index and recover an explicit formulation of the HG,G′ and SG,G′ matrices by substituting Eq. (2) in Eq. (3) and carrying out the multiple integration. The computation is particularly complex within the MT regions where the initialization of the Hamiltonian and Overlap matrices is by far the most computationally intensive task. By exploiting the properties of the basis functions, the H and S matrices are directly expressed as functions of the set of A and B coefficients. (S)G′ ,G = NA X  X a=1 l,m (H)G′ ,G = Aa,G l,m ′ ∗  ∗ a,G′ a,G Aa,G Bl,m ku̇al k2 l,m + Bl,m (4) NA X  ∗     X ′ ∗ [AB] [AA] a,G′ a,G a,G + A T B Aa,G T A ′ ′ ′ ′ L L ,L;a L L L ,L;a L a=1 L′ ,L +       ′ ∗ ′ ∗ [BB] [BA] + BLa,G TL′ ,L;a BLa,G . (5) BLa,G TL′ ,L;a Aa,G ′ ′ L Notice that in Eq. (5) for convenience we have compacted the indexes l , m into L, and expressed the range of the index a over all the distinct atom types NA . [... ] The new matrices TL′ ,L;a ∈ CNL ×NL are dense and their computation involves multiple integrals between the basis functions and the non-spherical part of the potential V0 (See [2, Appendix A.2] for details). Due to the non-orthornormality of the basis function set (2), the matrix S is non-diagonal, dense, and generically positive definite with the exception of having few very small singular values. On the opposite H is always non-definite and both matrices are either complex Hermitian or real symmetric. 2 Algorithm As a first step towards using the BLAS and LAPACK libraries, all the involved objects in Eqs. (4) and (5) are expressed in matrix form, dropping indexes L, L′ , G, and G′ . Assuming the coefficient objects A and B as well as the T matrices as input, matrices H and S can be computed as follows: H= NA X a=1 S= NA X AH T [AA] Aa + AH T [AB] Ba + BaH T [BA] Aa + BaH T [BB] Ba | a {z } |a {z } (6) H H AH a Aa + Ba Ua Ua Ba , (7) HAA HAB+BA+BB a=1 [...] where Aa and Ba ∈ CNL ×NG , Ta ∈ CNL ×NL , H and S ∈ CNG ×NG , and U ∈ CNL ×NL is a diagonal matrix. Typical for the matrix sizes are NA ∼ O(100), NG ∼ O(1000) to O(10000), and NL ∼ O(100). Algorithm 1 illustrates the algorithm used to compute Eqs. (6) and (7) in HSDLA. Two main insights drive the design of the algorithm. First, it exploits symmetries to reduce the computational cost; then, it casts the computation in terms of BLAS and LAPACK kernels. Furthermore, when possible, multiple matrices are stacked together to allow for larger matrix products, which in general results in higher performance. The computation of H is split into two parts, HAB+BA+BB and HAA . The computation of HAB+BA+BB corresponds to lines 4 through 10. The key idea behind the calculation is to rewrite the expression as NA X 1 1 [AB] BaH (T [BA] Aa ) + (AH )Ba + BaH (T [BB] Ba ) + (BaH T [BB] )Ba , a T 2 2 a=1 noting that T [BA] is the Hermitian transpose of T [AB] and that T [BB] is itself Hermitian. The operations in parentheses are computed one at a time for each i. Then, the results are aggregated into single large matrices for a large product. The computation of HAA corresponds to lines 17 through 29. The algorithm first attempts a Cholesky factorization of T [AA] (Ca Ca = T [AA]), which requires the matrix to be Hermitian positive definite (HPD). While, in theory, T [AA] is HPD, in practice, due to numerical considerations, the factorization may fail. Depending on the success or failure of each individual factorization, the results of operations in lines 21 and 24 are stacked on different temporary operands to then compute HAA in two steps (lines 28 and 29). The computation of S (lines 13 through 15) is more straightforward. First, the product AH A is computed as a single large product. Then B is updated with the norms stored in U and a second large product B H B completes the computation. Algorithm 1 : Computation of the H and S matrices in HSDLA. 1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 3 Create A, B Backup  = A, B̂ = B // First part of H for a := 1 → NA do [BA] Za = Ta Aa [BB] Ba Za = Za + 21 Ta Stack Za to Z Stack Ba to B end for H = ZH B + BH Z Restore A = Â, B = B̂ // S S = AH A B = UB S = S + BH B // Second part of H for a := 1 → NA do try: [AA] Ca = Cholesky(Ta ) success: Ya = CaH Aa Stack Ya to YHPD failure: [AA] Xa = Ta Aa Stack Xa to X¬HPD Stack Aa to A¬HPD end for H = H + AH ¬HPD X¬HPD H H = H + YHPD YHPD ⊲ (zgemm: 8NL2 NG Flops) ⊲ (zhemm: 8NL2 NG Flops) 2 ⊲ (zher2k: 8NA NL NG Flops) 2 ⊲ (zherk: 4NA NL NG Flops) ⊲ (scaling: 2NA NL NG Flops) 2 ⊲ (zherk: 4NA NL NG Flops) ⊲ (zpotrf: 4 N3 3 L Flops) ⊲ (ztrmm: 4NL2 NG Flops) ⊲ (zhemm: 8NL2 NG Flops) 2 Flops) ⊲ (zgemm: 8NA¬HPD NL NG 2 ⊲ (zherk: 4NAHPD NL NG Flops) Software re-engineering and performance portability In this section we set the focus on the porting of the multi-core implementation of Alg. 1 to heterogeneous architectures consisting of one multi-core node equipped with one or more GPUs. We perform a quick analysis of the computation to determine how to split the computation between CPU and GPU(s) with minimal modifications to the code, and illustrate how with these minor modifications one can already benefit considerably from the combined computational power of CPU and GPUs. Given the characteristic values for NA , NL , and NG observed in our test cases, at least 97% of the computation is performed by the operations in lines 10, 13, 15, 28 and 29. Thanks to the aggregation of many small matrix products into single large ones, all these 5 operations are large enough to be efficiently computed on the GPUs. Therefore, the first step is to off-load these computations to the GPU making sure that relatively high efficiency is attained. All five calls correspond to BLAS kernels; we thus look into available BLAS implementations for GPUs. There exists a range of GPU libraries that offer BLAS functionality, both academic and commercial, such as cuBLAS [1], cuBLAS-XT, MAGMA [8], and BLASX [9]. The first two are commercial and developed by NVIDIA, the other two are academic efforts. From the point of view of programmability, the most convenient alternatives are cuBLAS-XT and BLASX, since they require minor or no changes to the calls to BLAS routines and take also care of the data transfers between CPU and GPU transparently. While BLASX offers certain advantages from the programmability perspective and claims higher performance and scalability (see [9]), we encountered some problems in the integration and opted for using cuBLAS-XT for our initial study. Since cuBLAS-XT does not abide to the BLAS standard interface, three wrappers, of about 15 lines of code each, around the calls to zherk, zher2k and zgemm are required to ensure the code works seamlessly in both CPU-only and CPU-GPU(s) modes. An example for zgemm follows: void gpu_zgemm_( char *transa, char *transb, int *m, int *n, int *k, std::complex<double> *alpha, std::complex<double> *A, int *lda, std::complex<double> *B, int *ldb, std::complex<double> *beta, std::complex<double> *C, int *ldc ) { cublasOperation_t cu_transa = transa[0] == ’N’ ? CUBLAS_OP_N : transa[0] == ’T’ ? CUBLAS_OP_T : CUBLAS_OP_C; cublasOperation_t cu_transb = transb[0] == ’N’ ? CUBLAS_OP_N : transb[0] == ’T’ ? CUBLAS_OP_T : CUBLAS_OP_C; cublasXtZgemm( handle, cu_transa, cu_transb, *m, *n, *k, (cuDoubleComplex *)alpha, (cuDoubleComplex *)A, *lda, (cuDoubleComplex *)B, *ldb, (cuDoubleComplex *)beta, (cuDoubleComplex *)C, *ldc ); } In addition, two routines for proper initialization and cleanup of the cuda runtime and the devices are needed. Finally, for the data transfers between CPU and GPU to be efficient, memory for the matrices involved must be pinned (page-locked). With these minor modifications, about 100 lines of extra coding, the program is ready to off-load most of the computation to multiple GPUs and attain n-fold speedups. It is important to highlight that this simple extension is only possible thanks to the initial effort in rewriting the initial FLEUR code in terms of matrix (BLAS/LAPACK) operations. At that point the efficiency and scalability of the code may be easily ported to more complex architectures. Had the original FLEUR code not undergone the reengineering process, the coding of efficient low level routines for the GPUs would be a much more complex and time-consuming effort. 4 Experimental Results We turn now our attention to experimental results. We compare the performance of our hybrid CPU-GPU implementation of Alg. 1 with the performance of the multi-core (CPU only) HSDLA. As test cases we use two input systems describing two distinct physical systems, to which we refer as NaCl and AuAg, respectively. By including both an insulator and a conductor, these systems represent a heterogeneous sample with different physical properties. The tests generate the matrices H and S for one single k-point, and different Kmax values. The actual problem sizes, that is, the values for NA , NL , and NG in each case are given in Tab. 1. Test case NA NL NG : Kmax = 2.5 Kmax = 3.0 Kmax = 3.5 Kmax = 4.0 NaCl 512 49 2256 3893 6217 9273 AuAg 108 121 3275 5638 8970 13379 Table 1: Problem sizes for NaCl and AuAg and for a variety of Kmax values. The value of NG varies with Kmax . We ran our experiments in two different compute nodes, which we will refer to as RWTH and JURECA. The RWTH node consists of two eight-core Sandy Bridge E5-2650 processors, running at a nominal frequency of 2.0 GHz, and 2 NVIDIA Tesla K20Xm GPUs. The node is equipped with 64 GBs of RAM. The combined peak performance for the 16 CPU cores in double precision is of 256 GFlops, while the peak performance for double precision of each GPU is of 1.3 TFlops, for a total of 2.6 TFlops. The JURECA node consists of two twelve-core Haswell E5-2680v3 processors, running at a nominal frequency of 2.5 GHz, and 2 NVIDIA K80 GPUs (each of which consists of two K40 GPU devices). The node is equipped with 128 GBs of RAM. The combined peak performance for the 24 CPU cores in double precision is of 960 GFlops, while the peak performance for double precision of each GPU device is of about 1.45 TFlops, for a total of 5.8 TFlops. In all cases, the code was linked to Intel MKL version 11.3.2 for the BLAS and LAPACK routines on the CPU; the GPU code was linked to NVIDIA cuBLAS-XT version 7.5. RWTH. Table 2 collects the timings for the NaCl test case for the three scenarios of interest (CPU only, CPU + 1 GPU, CPU + 2 GPUs). The speedup with respect to HSDLA is given in parentheses. As expected, the considerable gap in performance between CPU and GPU is reflected in the observed large speedups: up to 2.76× and 4.04× for 1 and 2 GPUs, respectively. Similar results are presented in Tab. 3 for the AuAg test case, but in this case the observed speedups are even larger. The reason for this is that, while MKL is already close to its peak performance for the matrix sizes of NaCl, cuBLAS-XT still has room for improvement and benefits from the larger matrices in AuAg. In fact, one can expect still better speedups for larger systems. Setup Kmax = 2.5 Kmax = 3.0 Kmax = 3.5 Kmax = 4.0 CPU only 18.27s 39.84s 91.52s 189.53s CPU + 1 GPU 8.03s (2.28×) 15.87s (2.51×) 35.64s (2.57×) 68.59s (2.76×) CPU + 2 GPUs 6.51s (2.81×) 12.37s (3.22×) 24.39s (3.75×) 46.97s (4.04×) Table 2: Timings and speedup (in parentheses) for the NaCl test case for varying Kmax . Results for the RWTH node. Setup Kmax = 2.5 Kmax = 3.0 Kmax = 3.5 Kmax = 4.0 CPU only 15.64s 46.23s 104.25s 215.98s 7.52s (2.08×) 16.16s (2.86×) 35.62s (2.93×) 71.35s (3.03×) CPU + 1 GPU CPU + 2 GPUs 5.62s (2.78×) 11.28s (4.10×) 23.10s (4.51×) 43.54s (4.96×) Table 3: Timings and speedup (in parentheses) for the AuAg test case for varying Kmax . Results for the RWTH node. JURECA. Results for the JURECA node are presented in Tabs. 4 and 5 for NaCl and AuAg, respectively. In this case we show timings and speedups for up to 4 GPUs. The maximum observed speedups are 1.77×, 2.76× and 4.26× for 1, 2 and 4 GPUs, respectively. Given that the increase in computational power in each case is of 2.4×, 3.9× and 6.8×, respectively, these numbers are quite satisfactory. Setup Kmax = 2.5 Kmax = 3.0 Kmax = 3.5 Kmax = 4.0 CPU only 9.334s 23.293s 41.500s 74.731s 6.474s (1.44×) 14.502s (1.61×) 32.728s (1.27×) 66.546s (1.12×) CPU + 1 GPU CPU + 2 GPUs 4.995s (1.87×) 10.381s (2.24×) 21.842s (1.90×) 42.581s (1.76×) CPU + 4 GPUs 4.720s (1.98×) 8.760s (2.66×) 15.449s (2.69×) 26.575s (2.81×) Table 4: Timings and speedup (in parentheses) for the NaCl test case for varying Kmax . Results for the JURECA node. Setup Kmax = 2.5 Kmax = 3.0 Kmax = 3.5 Kmax = 4.0 CPU only 9.102s 22.681s 57.314s 100.190s CPU + 1 GPU 6.136s (1.48×) 14.466s (1.57×) 32.338s (1.77×) 68.910s (1.45×) 9.699s (2.34×) 20.800s (2.76×) 42.242s (2.37×) CPU + 2 GPUs 4.376s (2.08×) CPU + 4 GPUs 3.533s (2.58×) 6.690s (3.39×) 13.457s (4.26×) 25.359s (3.95×) Table 5: Timings and speedup (in parentheses) for the AuAg test case for varying Kmax . Results for the JURECA node. 4.1 Fine-tuning for performance and scalability The observed speedups are substantial. Yet, one could expect even better results, especially in the case of the RWTH node where the computational power of the two GPUs combined is ten times larger than that of the CPUs. This potential for improvement comes as no surprise, since this is only a basic port to illustrate how far one can get with minimal code modifications; to attain close-to-optimal performance further work is required. For ideal results, a hybrid and highlytuned BLAS as well as a GPU-accelerated version of the computation in the loops are needed. In order to have a more tangible discussion, we provide in Tab. 6 a breakdown of the timings for the NaCl (Kmax = 4.0) test case running in the RWTH node with two K20x GPUs. The bottom rows correspond to the large BLAS operations off-loaded to the two GPUs; the top rows correspond to the rest of the code (both loops and the application of the U norm) executed on the CPU only. The efficiency is measured with respect to the combined performance of CPU plus GPUs. Section (line(s)) Loop 1 (4–9) Loop 2 (17–27) U norm (14) Time Performance Efficiency 2.27 secs 2.62 secs 0.23 secs 80.35 GFlops/s 34.81 GFlops/s 1.01 GFlops/s 0.03 0.01 0.00 S1 (13) 4.37 secs 1974.63 GFlops/s 0.69 S2 (15) 4.41 secs 1956.72 GFlops/s 0.68 H1 (10) 9.49 secs 1818.57 GFlops/s 0.63 H2 (28) 2.32 secs 1859.72 GFlops/s 0.65 4.75 secs 1816.66 GFlops/s 0.63 H3 (29) Table 6: Breakdown of timings for NaCl (Kmax = 4.0) together with the respective attained performance and efficiency. Three main messages can be extracted from Tab. 6: 1. NVIDIA’s cuBLAS-XT does a good job attaining an efficiency between 63% and 69%. 2. Yet, these operations may attain about 90% of the peak if the matrices are large enough and the code is highly optimized and hybrid. This would mean attaining around 2.5 TFlops/s, that is, an extra 25% speedup for these heavy computations. 3. When the target architecture offers massive parallelism, minor portions of code that do not scale may become a bottleneck. In our case, the 3% of the computation that was not off-loaded to the GPUs becomes non-negligible. In fact, the weight of these operations in our experiments may account for up to 35% of the time to solution, and compromise the overall scalability. Due to the size of the matrices involved in these operations (between 50 × 50 and 100 × 100 for the T matrices in our test cases), these products do not scale well, especially on GPUs. Specialized code is required to mitigate their impact in the overall time to solution. 5 Conclusions and Future Work We concentrated on the benefits of rewriting scientific code in terms of standardized libraries for portable performance and scalability. As use case we considered a portion of the FLEUR code base, a software for electronic structure calculations. We demonstrated that major efforts in re-engineering part of the original FLEUR code, and writing it in terms of the BLAS and LAPACK libraries, enables a fast porting that exploits the vast computational power of emerging heterogeneous architectures such as multi-core CPUs combined with multiple GPUs. Most importantly, the porting only required less than 100 new lines of code. The resulting implementation attains speedups of up to 3× and 5× for simulations run on a system equipped with two K20x GPUs, respectively, and speedups of up to 1.8×, 2.8× and 4.3× for runs with 1, 2 and 4 GPUs, respectively, on a system equipped with two K80 GPUs (each consisting of two K40 GPUs). While satisfactory, these results highlight room for improvement. In the future, we aim at developing more efficient hybrid CPU-GPU routines for the major matrix products in the code as well as attaining sufficient scalability of the rest of the code to ensure a uniform overall scalability. 6 Acknowledgements This work was partially funded by the Ministry of Science and Education of the Republic of Croatia and the Deutsche Akademische Austauschdienst (DAAD) from funds of the Bundesministeriums für Bildung und Forschung (BMBF) through project “PPP Kroatien” ID 57216700. Financial support from the Jülich Aachen Research Alliance-High Performance Computing and the Deutsche Forschungsgemeinschaft (DFG) through grant GSC 111 is also gratefully acknowledged. Furthermore, the authors thank the RWTH IT Center and the Jülich Supercomputing Centre for the computational resources. References 1. cuBLAS: The NVIDIA CUDA Basic Linear Algebra Subroutines, https://developer.nvidia.com/cublas 2. Di Napoli, E., Peise, E., Hrywniak, M., Bientinesi, P.: High-performance generation of the Hamiltonian and Overlap matrices in FLAPW methods. Computer Physics Communications (Oct 2016), DOI: 10.1016/j.cpc.2016.10.003 3. FLEUR: The Jülich FLAPW code family (Oct 2016), http://www.flapw.de/pm/index.php 4. Jansen, H.J.F., Freeman, A.J.: Total-Energy Full-Potential Linearized AugmentedPlane-Wave Method for Bulk Solids - Electronic and Structural-Properties of Tungsten. Physical Review B 30(2), 561–569 (Jul 1984) 5. Kohn, W., Sham, L.J.: Self-Consistent Equations Including Exchange and Correlation Effects. Phys.Rev. 140, A1133–A1138 (1965) 6. Nogueira, F., Marques, M.A.L., Fiolhais, C.: A primer in density functional theory. Lecture Notes in Physics, Springer, Berlin (2003) 7. Sholl, D., Steckel, J.A.: Density Functional Theory. A Practical Introduction, John Wiley & Sons (Sep 2011) 8. Tomov, S., Nath, R., Ltaief, H., Dongarra, J.: Dense linear algebra solvers for multicore with GPU accelerators. In: Proc. of the IEEE IPDPS’10. pp. 1–8. IEEE Computer Society, Atlanta, GA (April 19-23 2010), DOI: 10.1109/IPDPSW.2010.5470941 9. Wang, L., Wu, W., Xu, Z., Xiao, J., Yang, Y.: BLASX: A High Performance Level3 BLAS Library for Heterogeneous Multi-GPU Computing. In: Proceedings of the 2016 International Conference on Supercomputing. pp. 20:1–20:11. ICS ’16, ACM, New York, NY, USA (2016) 10. Wimmer, E., Krakauer, H., Weinert, M., Freeman, A.J.: Full-Potential Self-Consistent Linearized-Augmented-Plane-Wave Method for Calculating the Electronic-Structure of Molecules and Surfaces - O2 Molecule. Physical Review B 24(2), 864–875 (Jul 1981)
5cs.CE
A 4/5 - Approximation Algorithm for the Maximum Traveling Salesman Problem∗ arXiv:1512.09236v2 [cs.DS] 20 Mar 2016 Szymon Dudycz†, Jan Marcinkowski‡, Katarzyna Paluch§, and Bartosz Rybicki¶ Institute of Computer Science, University of Wrocław Abstract In the maximum traveling salesman problem (Max TSP) we are given a complete undirected graph with nonnegative weights on the edges and we wish to compute a traveling salesman tour of maximum weight. We present a fast combinatorial 45 - approximation algorithm for Max TSP. The previous best approximation for this problem was 97 . The new algorithm is based on a novel technique of eliminating difficult subgraphs via half-edges, a new method of edge coloring and a technique of exchanging edges. A half-edge of edge e = (u, v) is informally speaking “a half of e containing either u or v”. ∗ Partly supported by Polish National Science Center grant UMO-2013/11/B/ST6/01748 [email protected][email protected] § [email protected][email protected] † 1 Introduction The maximum traveling salesman problem (Max TSP) is a classical variant of the famous traveling salesman problem. In the problem we are given a complete undirected graph G = (V, E) with nonnegative weights on the edges and we wish to compute a traveling salesman tour of maximum weight. Max TSP, also informally known as the “taxicab ripoff problem” is both of theoretical and practical interest. Previous approximations of Max TSP have found applications in combinatorics and computational biology: the problem is useful in understanding RNA interactions [21] and providing algorithms for compressing the results of DNA sequencing [20]. It has also been applied to a problem of finding a maximum weight triangle cover of the graph [19] and to a combinatorial problem called bandpass-2 [22], where we are supposed to find the best permutation of rows in a boolean-valued matrix, so that the weighted sum of structures called bandpasses is maximised. Previous results. The first approximation algorithms for Max TSP were devised by Fisher, Nemhauser and Wolsey [5]. They showed several algorithms having approximation ratio 21 and one having a guarantee of 23 . In [10] Kosaraju, Park and Stein presented an improved algorithm having 19 ([2]). This was in turn improved by Hassin and Rubinstein, who gave a 57 - approximation a ratio 27 ([7]). In the meantime Serdyukov [18] presented (in Russian) a simple and elegant 34 -approximation algorithm. The algorithm is deterministic and runs in O(n3 ), where n denotes the number of vertices in the graph. Afterwards, Hassin and Rubinstein ([6]) gave a randomized algorithm having expected 2 1/ǫ )), where ǫ is an arbitrarily small approximation ratio at least 25(1−ǫ) 33−32ǫ and running in O(n (n + 2 constant. The first deterministic approximation algorithm with the ratio better than 43 was given in [3] by Chen, Okamoto and Wang. It is a 61 81 -approximation and a nontrivial derandomization of the algorithm from [6] and runs in O(n3 ). The currently best known approximation has been given by Paluch, Mucha and Madry [13] and achieves the ratio of 79 . Its running time is also O(n3 ). Related Work. It is known that Max-TSP is max-SNP-hard [23], so there exists a constant δ < 1, which is an upper bound on the approximation ratio of any algorithm for this problem. The geometric version of the problem, where all vertices are in Rd and the weight of each edge is defined as the Euclidean distance of its endpoints, was considered in [24]. The algorithm presented in this paper solves the problem exactly in polynomial time, assuming that the number d of dimensions is constant. Moreover, it is quite fast for real-life instances, in which d is small. Regarding the path version of Max TSP - Max-TSPP (the Maximum Traveling Salesman Path Problem), the approximation algorithms with ratios correspondingly 12 and 23 have been given in [12]. The first one is for the case when both endpoints of the path are specified and the other for the case when only one endpoint is given. Another related problem is called the maximum scatter TSP (see [25]). In it the goal is to find a TSP tour (or a path) which maximizes the weight of the minimum weight (lightest) edge selected in the solution. The problem is motivated by medical imaging and some manufacturing applications. In general there is no constant approximation for this problem, but if the weights of the edges obey the triangle inequality, then it is possible to give a 21 -approximation algorithm. The paper studies also the more general version of the maximum scatter TSP – the max-min-m-neighbour TSP. The improved approximation results for the max-min-2-neighbour problem have been given in [4]. In the maximum latency TSP problem we are given a complete undirected graph with vertices v0 , v1 , . . . , vn . Our goal is to find a Hamiltonian path starting at a fixed vertex v0 , which maximizes the total latency of the vertices. If in a given path P the weight of the i-th edge is wi , then the 2 P P latency of the j-th vertex is Lj = ji=1 wi and the total latency is defined as L(P ) = nj=1 Lj . A ratio 12 approximation algorithm for this problem is presented in [26]. Our approach and results. We start with computing a maximum weight cycle cover Cmax of G. A cycle cover of a graph G is a collection of cycles such that each vertex belongs to exactly one of them. The weight of a maximum weight cycle cover Cmax is an upper bound on opt, where by opt we denote the weight of a maximum weight traveling salesman tour. By computing a maximum weight perfect matching M we get another, even simpler than Cmax , upper bound – on opt/2. From Cmax and M we build a multigraph G1 which consists of two copies of Cmax and one copy of M , i.e., for each edge e of G the multigraph G1 contains between zero and three copies of e. Thus the total weight of the edges of G1 is at least 52 opt. Next we would like to path-3-color G1 , that is to color the edges of G1 with three colors, so that each color class contains only vertex-disjoint paths. The paths from the color class with maximum weight can then be patched in an arbitrary manner into a tour of weight at least 56 opt. Technique of eliminating difficult subgraphs via half-edges. However, not every multigraph G1 can be path-3-colored. For example, a subgraph of G1 obtained from a triangle t of Cmax such that M contains one of the edges of t (such triangle is called a 3-kite (of G1 )) cannot be path-3-colored as, clearly, it is impossible to color such seven edges with three colors and not create a monochromatic triangle. Similarly, a subgraph of G1 obtained from a square s (i.e., a cycle of length four) of Cmax such that M contains two edges connecting vertices of s (such square is called a 4-kite (of G1 )) is not path-3-colorable. To find a way around this difficulty, we compute another cycle cover C2 improving Cmax with respect to M , which is a cycle cover that does not contain any 3-kite or 4-kite of G1 and whose weight is also at least opt. An important feature of C2 is that it may contain half-edges. A half-edge of an edge e is, informally speaking, a half of the edge e that contains exactly one of its endpoints. Half-edges have already been introduced in [14]. Computing C2 is done via a novel reduction to a maximum weight perfect matching. It is, to some degree, similar to computing a directed cycle cover without length two cycles in [14], but for Max TSP we need much more complex gadgets. From one copy of C2 and M we build another multigraph G2 with weight at least 23 opt. It turns out that G2 can always be path-2-colored. The multigraph G1 may be non-path-3-colorable - if it contains at least one kite. We notice, however, that if we remove one arbitrary edge from each kite, then G1 becomes path-3-colorable. The edges removed from G1 are added to G2 . As a result, the modified G2 may stop being path-2-colorable. To remedy this, we in turn remove some edges from G2 and add them to G1 . In other words, we find two disjoint sets of edges - a set F1 ⊆ G1 and a set F2 ⊆ G2 , called exchange sets such that the multigraph G′1 = G1 \ F1 ∪ F2 is path-3-colorable and the multigraph G′2 = G2 \ F2 ∪ F1 is path-2-colorable. Since G1 and G2 have the total weight at least 4 opt, by path-3-coloring G′1 and path-2-coloring G′2 we obtain a 45 - approximate solution to Max TSP. Edge coloring. The presented algorithms for path-3-coloring and path-2-coloring are essentially based on a simple notion of a safe edge, i.e., an edge colored in such a way that it is guaranteed not to belong to any monochromatic cycle, used in an inductive way. The adopted approach may appear simple and straightforward. For comparison, let us point out that the method of path-3-coloring the multigraph obtained from two directed cycle covers described in [9] is rather convoluted. Generally, the new techniques are somewhat similar to the ones used for the directed version of the problem - Max ATSP in [15]. We are convinced that they will prove useful for other problems related with TSP, cycle covers or matchings. 3 The main result of the paper is Theorem 1 There exists a 45 -approximation algorithm for Max TSP. Its running time is O(n3 ). 2 Path-3-coloring of G1 We compute a maximum weight cycle cover Cmax of a given complete undirected graph G = (V, E) and a maximum weight perfect matching M of G. We are going to call cycles of length i, i.e., consisting of i edges i-cycles. Also sometimes 3-cycles will be called triangles and 4-cycles – squares. The multigraph G1 consists of two copies of Cmax and one copy of M . We want to color each edge of G1 with one of three colors of K3 = {1, 2, 3} so that each color class consists of vertex-disjoint paths. The graph G1 is a subgraph of the multigraph G1 that contains an edge (u, v) iff the multigraph G1 contains an edge between u and v. The path-3-coloring of G1 can be equivalently defined as coloring each edge of (the graph) G1 with the number of colors equal to the number of copies contained in the multigraph G1 . From this time on, unless stated otherwise, G1 denotes a graph and not a multigraph. We say that a colored edge e of G1 is safe if no matter how we color the so far uncolored edges of G1 e is guaranteed not to belong to any monochromatic cycle of G1 . An edge e of M is said to be external if its two endpoints belong to two different cycles of Cmax . Otherwise, e is internal. We say that an edge e is incident to a cycle c if it is incident to at least one vertex of c. We prove the following useful lemma. Lemma 1 Consider a partial coloring of G1 . Let c be any cycle of Cmax such that for each color k ∈ K3 there exists an edge of M incident to c that is colored k. Then we can color c so that each edge of c and each edge incident to one of the edges of c is safe. Proof. The proposed procedure of coloring c is as follows. If there exists an edge of c that also belongs to M , we color it with all three colors of K3 . For each uncolored edge of M incident to c, we color it with an arbitrary color of K3 . Next, we orient the edges of c (in any of the two ways) so that c becomes a directed cycle c. Let e = (u, v) be any uncolored edge of c oriented from u to v. Then, there exists an edge e′ of M incident to u. If e′ is contained in c, then we color e with any two colors of K3 . Otherwise e′ is colored with some color k of K3 . Then we color e with the two colors belonging to K3 \ k. First, no vertex of c has three incident edges colored with the same color, as for each vertex its outgoing edge is colored with different colors than an incident matching edge. Second, as for each color k ∈ K3 there is a matching edge incident to c colored with k, there exists an edge of c that is not colored k, thus c does not belong to any color class, i.e. there exists no color k ∈ K3 such that each edge of c is colored with k. Let us consider now any edge e = (u, v) of M incident to some edge of c and not belonging to c. The edge e is colored with some color k. Suppose also that vertex u belongs to c (v may belong to c or may not belong to c.) Let u′ be any other vertex of c such that some edge of M \ Cmax colored k is incident to it (u′ may be equal to v if e is internal). To show that e is safe, it suffices to show that there exists no path consisting of edges of c ∪ M that connects u and u′ and whose every edge is colored k. However, by the way we color edges of c we know that the outgoing edges of u and u′ are not colored with k because of the way we oriented the cycle, there is no path connecting u and u′ contained in c that starts and ends with incoming edge. ✷ 4 For each cycle c of Cmax we define its degree of flexibility denoted as f lex(c) and its colorfulness, denoted as col(c). The degree of flexibility of a cycle c is the number of internal edges of M incident to c and the colorfulness of c is the number of colors of K3 that are used for coloring the external edges of M incident to c. From Lemma 1 we can easily derive Lemma 2 If a cycle c of Cmax is such that f lex(c) + col(c) ≥ 3, then we can color c so that each edge of c and each edge incident to one of the edges of c is safe. Sometimes, even if a cycle c of Cmax is such that f lex(c) + col(c) < 3, we can color the edges of c so that each of them is safe. For example, suppose that c is a square consisting of edges e1 , . . . , e4 and there are four external edges of M incident to c, all colored 1. Suppose also that each external edge incident to c is already safe. Then we can color e1 with 1 and 2, e3 with 1 and 3 and both e2 and e4 with 2 and 3. We can notice that e1 is guaranteed not to belong to a cycle colored 1 because external edges incident to e1 are colored 1 and are safe. Analogously, we can easily check that each other edge of c is safe. However, for example, a triangle t of Cmax that has three external edges of M incident to it, all colored with the same color of K3 , cannot be colored in such a way that it does not contain a monochromatic cycle. Consider a cycle c of Cmax such that every external edge of M incident to c is colored. We say that c is non-blocked if and only if (1) f lex(c) + col(c) ≥ 3 or (2) c contains at least 3 − f lex(c) − col(c) vertex-disjoint edges, each of which has the property that it has exactly two incident external edges of M and the two external edges of M incident to it are colored with the same color of K3 or (3) c is a square such that f lex(c) = 1. Otherwise we say that c is blocked. We can see that a cycle c of Cmax is blocked if • c is a triangle and all external edges of M incident to c are colored with the same color of K3 , • c is a square with two internal edges of M incident to it (f lex(c) = 2), • c is a cycle of even length, f lex(c) = 0 and there exist two colors k1 , k2 ∈ K3 such that external edges of M incident to c are colored alternately with k1 and k2 . Among blocked cycles we distinguish kites. We say that a cycle c is a kite if it is a triangle such that f lex(c) = 1 and then we call it a 3-kite or it is a square such that f lex(c) = 2 - called a 4-kite. A cycle of Cmax which is not a kite is called unproblematic. Now, we are ready to present the algorithm for path-3-coloring G1 . Lemma 3 Let c be an unproblematic cycle of Cmax that at some step of Algorithm Color G1 has the fewest uncolored external edges incident to it. Then, it is always possible to color all uncolored external edges incident to c so that no unproblematic cycle of Cmax becomes blocked. Moreover, if c has at least two uncolored ext. edges incident to c then, additionally, it is always possible to do it in such a way that f lex(c) + col(c) ≥ 3. If c has exactly one uncolored external edge e of M incident to it, then we can color e so that f lex(c) + col(c) ≥ 3 or so that e is safe. Proof. If c has at least two uncolored external edges of M incident to it, then we can use at least two different colors for coloring the edges. Moreover if f lex(c) = 0, then we can choose them in such a way that col(c) = 3, i.e. so that for every color k ∈ K3 at least one external edge of M incident 5 Algorithm 1 Color G1 while ∃ an uncolored external edge e of M do c ← an unproblematic uncolored cycle of Cmax with the fewest uncolored external edges incident to e color uncolored external edges incident to c so that no unproblematic cycle of Cmax becomes blocked and if possible, so that f lex(c) + col(c) ≥ 3 color c using Lemma 4 and internal edges incident to it in such a way, that each edge incident to c is safe end while while ∃c – an unproblematic, uncolored cycle of Cmax do color c and internal edges incident to it in such a way, that each edge incident to c is safe end while to c is colored with k. At this stage, every other uncolored cycle c′ of Cmax has also at least two uncolored external edges of M incident to it. Therefore c′ is in danger of becoming blocked only if it has an even number of incident external edges of M , all of them are colored with the same two colors, say k1 and k2 , in an alternate way and it has exactly two incident uncolored external edges e1 , e2 of M . However, even if we would like to also use k1 and k2 for coloring the external edges of M incident to c, we can do it in such a way that c′ does not become blocked, because, as one can easily see, one of the ways of coloring e1 and e2 with k1 and k2 does not make c′ blocked. If c has exactly one uncolored external edge e of M incident to it and c is in danger of becoming blocked, then either c is a triangle whose two other incident external edges are colored with the same color of K3 or c has even length and all of its incident external edges of M are colored with the same two colors in an alternate way. In each of these cases we have a choice and can color e with one of two colors so that c does not become blocked. If e is incident to a cycle c′ that is also in danger of becoming blocked, then with respect to c′ we can also color e with one of two colors of K3 so that it does not become blocked. As the intersection of two two-element subsets of K3 is always nonempty, we can color e, say with k, so that no cycle of Cmax becomes blocked. As all other external edges of c were safe, then e is also safe. ✷ From the above lemma we get Corollary 1 After all external edges are colored, each of them is incident to a cycle c of Cmax such that f lex(c) + col(c) ≥ 3 or is safe. We say that a cycle c of G1 is a subcycle of cycle c′ of Cmax if it goes only through vertices that belong to c′ . Lemma 4 Let c be an unproblematic and non-blocked cycle of Cmax whose all incident external edges of M are already colored and safe. Then it is always possible to color c and internal edges incident to c in such a way that each edge incident to c is safe. Proof. If c is such that f lex(c) + col(c) ≥ 3, then by Lemmas 1 and 2, the claim holds. Now let us first prove that if c is not blocked and f lex(c) + col(c) < 3, then it is always possible to color the edges of c so that no color class contains all edges of any subcycle of c. 6 Case 1: All edges of M incident to c are colored with the same color, say k. We can then assume that all edges of M incident to c are external. (Otherwise we would have colored internal edges of M with a different color than k.) c must have length at least 4. (Otherwise it would be blocked.) Let k1 , k2 denote the two colors of K3 \ k. We choose two nonadjacent edges of c, color one of them with k and k1 and the other with k and k2 . The remaining edges of c are colored with k1 and k2 . Case 2: All edges of M incident to c are colored with two colors, say k1 and k2 . We can assume that either (1) c has no incident internal edges of M or (2) that it has exactly one incident internal edge of M and all external edges of M incident to c are colored in the same way. Let k denote the color belonging to K3 \ {k1 , k2 } and assume that c goes through vertices v1 , v2 , . . . , vs in the given order. Then let vi denote a vertex of c such that edges of M incident to vi−1 and vi are colored in the same way, say with k1 , and vi+1 is colored with k2 . Then for each j 6= i we color edge (vj , vj+1 ) of c with colors belonging to K3 \ k′ , where k′ denotes the color used on an edge of M incident to vj . Edge (vi , vi+1 ) is going to be colored with k1 and k2 . We colored the edges, so that there is no monochromatic cycle on edges of c and internal matching edges. Therefore, together with the safety of all external edges, it ensures the safety of all internal edges. ✷ 3 A cycle cover improving Cmax with respect to M Since Cmax may contain kites, we may not be able to path-3-color G1 . Therefore, our next aim is to compute another cycle cover C2 of G such that it does not contain any cycle of Cmax which is problematic and whose weight is an upper bound on OP T . Since computing such C2 may be hard, we relax the notion of a cycle cover and allow C2 to contain half-edges. A half-edge of the edge e is informally speaking a half of the edge e that contains exactly one of the endpoints of e. Let us also point out here that C2 may contain kites which do not belong to Cmax . To be able to give a formal definition of such a relaxed cycle cover, we introduce a graph G̃. We say that an edge (u, v) is problematic if u and v belong to the same kite. An edge connecting vertices of a kite c is also said to be a problematic edge of c. A 3-kite has no diagonals and a 4-kite has two diagonals. G̃ = (Ṽ , Ẽ) is the graph obtained from G by splitting each problematic edge (u, v) with a vertex x{u,v} into two edges (u, x{u,v} ) and (x{u,v} , v), each with weight 21 w(u, v). Each of the edges (u, x{u,v} ) and (x{u,v} , v) of G̃ is said to be a half-edge of the edge (u, v) of G. In what follows, when we speak of an edge of a kite, we mean an edge of the original graph G. Definition 1 A relaxed cycle cover improving Cmax with respect to M is a subset C̃ ⊆ Ẽ such that (i) each vertex in V has exactly two incident edges in C̃; (ii) for each 3-kite t of Cmax the number of half-edges of the edges of t contained in C̃ is even and not greater than four; (iii) for each 4-kite s of Cmax the number of half-edges of the edges or diagonals of s contained in C̃ is even and not greater than six. 7 To compute a relaxed cycle cover C2 improving Cmax with respect to M we construct the following graph G′ = (V ′ , E ′ ). The set of vertices V ′ is a superset of the set of verices V of G. For each problematic edge (u, v) of G we add two vertices xu{u,v} , xv{u,v} to V ′ and edges (u, xu{u,v} ), (xv{u,v} , v) to E ′ . For each problematic edge (u, v) which is not a diagonal of a 4-kite we add also an edge (xu{u,v} , xv{u,v} ). The edge (xu{u,v} , xv{u,v} ) has weight 0 in G′ and each of the edges (u, xu{u,v} ), (xv{u,v} , v) has weight 12 w(u, v). Each of the vertices xu{u,v} , xv{u,v} is called a splitting vertex of the edge (u, v). For each edge (u, v) of G which is not problematic we add an edge (u, v) to E ′ with weight w(u, v). xzw z w xw v xw z xzv xzu q xw u xw u pz xvu pu xu z xu v pv xvw xu w u u (a) b(u) = b(v) = b(w) = 2, ∀i ∈ {1, . . . , 6} b(xi ) = 1, b(p) = b(q) = 1 xw v pw q p xu w w v xvw xvz xu v xvu v (b) b(u) = b(v) = b(w) = b(z) = 2, ∀k 6= l ∈ {u, v, w, z} b(xlk ) = 1, b(pu ) = b(pv ) = b(pw ) = b(pz ) = b(q) = 2 Figure 1: Gadgets for 3-kites (a) and 4-kites (b) of G1 in graph G. Half-edges corresponding to the original edges are thickened, the auxiliary edges are thin. Original vertices (thick dot) are connected with all the other original vertices of graph G. The auxiliary vertices have no connections outside of the gadget. The figures are subtitled with the specifications of b(v) values for different vertices. For a vertex t with b(t) = i, the resulting b-matching will contain exactly i edges ending in t. Next we build so-called gadgets. For each 3-kite t on vertices u, v, w we add two vertices pt , q t to V ′ . Let’s assume that u is incident to external edge of M . Vertex pt is connected to the splitting vertices of edges of t that are neighbors of u, i.e. to vertices xu{u,v} , xu{u,w} and to vertex xv{v,w} . w v Vertex q t is connected to every other splitting vertex of t, i.e. xw {u,w} , x{v,w} , x{u,v} . All edges incident to verices pt , q t have weight 0 in G′ . For each 4-kite of Cmax on vertices u, v, w, z we add five vertices psu , psv , psw , psz , q s to V ′ . Vertex s pu is connected to the splitting vertices of edges of s that are neighbors of u, i.e. to vertices xu{u,v} , xu{u,w} , xu{u,z} . Vertices psv , psw , psz are connected analogously. Vertex q is connected to vertices psu , psv , psw , psz . All edges incident to verices psu , psv , psw , psz , q s have weight 0. We will reduce the problem of computing a relaxed cycle cover improving Cmax with respect to M to the problem of computing a perfect b-matching of the graph G′ . We define the function b : V ′ → N in the following way. For each vertex v ∈ V we set b(v) = 2. For each splitting vertex v ′ of some problematic edge we set b(v ′ ) = 1. For all vertices pt and q t , where t denotes a 3-kite of Cmax we have b(pt ) = b(q t ) = 1. For all vertices psu and q s , where s denotes a 4-kite of Cmax and u 8 one of its vertices we have b(psu ) = b(q s ) = 2. Theorem 2 Any perfect b-matching of G′ yields a relaxed cycle cover C2 improving Cmax with respect to M . A maximum weight perfect b- matching of G′ yields a relaxed cycle cover C2 improving Cmax with respect to M such that w(C2 ) ≥ OP T . Proof. First we show that any perfect b-matching of G′ yields a relaxed cycle cover improving Cmax with respect to M . Let B be any perfect b-matching of G′ . B defines C2 ⊆ Ẽ as follows. A half-edge (u, x{u,v} ) is contained in C2 iff edge (u, xu{u,v} ) of G′ is contained in B. A non-problematic edge (u, v) is contained in C2 iff (u, v) is contained in B. Since b(v) = 2 for any vertex v of V , we can see that the property (i) of Definition 1 is satisfied. Consider now an arbitrary 3-kite t of Cmax . There are 3 problematic edges of t and thus six half-edges. Suppose that t is on vertices u, v, w. We can notice that a half-edge (u, x{u,v} ) is not contained in C2 iff a splitting vertex xu{u,v} is connected in B to one of the vertices pt , q t or to a splitting vertex xv{u,v} . Since pt and q t are connected to one splitting vertex each, at most 4 halfedges of the problematic edges of t are contained in B. If a splitting vertex xu{u,v} is connected in B to xv{u,v} , then both half-edges of the edge (u, v) are excluded from C2 . This shows that the number of half-edges of problematic edges of t contained in C2 is even. Consider now an arbitrary problematic square s of Cmax . There are six problematic edges of s and thus twelve half-edges of these edges. Suppose that s is on vertices u, v, w, z. We can notice that a half-edge (u, x{u,v} ) is not contained in C2 iff a splitting vertex xu{u,v} is not matched to u in B. Thus a half-edge (u, x{u,v} ) does not occur in C2 iff a splitting vertex xu{u,v} is connected in B to one of the vertices psu , psv , psw , psz or to a splitting vertex xv{u,v} . Since q is connected to two of the vertices psu , psv , psw , psz and b(psu ) = b(psv ) = b(psw ) = b(psz ) = 2, exactly six splitting vertices of the problematic edges of s are connected in B to vertices psu , psv , psw , psz . This means that at least six half-edges of the problematic edges of s are not contained in B. If a splitting vertex xu{u,v} is connected in B to xv{u,v} , then both half-edges of the edge (u, v) are excluded from C2 . This shows that the number of half-edges of problematic edges of s contained in C2 is even. In order to show that w(C2 ) ≥ OP T it suffices to prove the following lemma. Lemma 5 Every cycle cover not containing kites of G1 corresponds to some perfect b-matching of G′ . The proof is in Section 10 4 ✷ Exchange sets F1 , F2 and path-2-coloring of G′2 We construct a multigraph G2 from one copy of a relaxed cycle cover C2 and one copy of a maximum weight perfect matching M . Since C2 may contain half-edges and we want G2 to contain only edges of G, for each half-edge of edge (u, v) contained in C2 , we will either include the whole edge (u, v) in G2 or not include it at all. While doing so we have to ensure that the total weight of the constructed multigraph G2 is at least 32 opt. The main idea behind deciding which half-edges are extended to full edges and included in G2 is that we compute two sets Z1 and Z2 such that for each kite in G1 half of the edges containing half-edges belongs to Z1 and the other half to Z2 . (Note that by Lemma ?? each kite in G1 contains 9 an even number of half-edges in C2 .) Let I(C2 ) denote the set consisting of whole edges of G contained in C2 . This way w(C2 ) = w(I(C2 )) + 21 (w(Z1 ) + w(Z2 )). Next, let Z denote the one of the sets Z1 and Z2 with maximum weight. Then G2 is defined as a multiset consisting of edges of M , edges of I(C2 ) and edges of Z. We obtain Fact 1 The total weight of the constructed multigraph G2 is at least 23 opt. Proof. The weight of M is at least 21 opt. The weight of w(C2 ) = w(I(C2 )) + 12 (w(Z1 ) + w(Z2 )) is at least opt. Since w(Z) = max{w(Z1 ), w(Z2 )}, we obtain that w(I(C2 )) + w(Z) ≥ w(C2 ). ✷ Since Cmax contains at least one kite, G1 is non-path-3-colorable. We can notice, however, that if we remove one edge from each kite from the multigraph G1 , then the obtained multigraph is path-3-colorable. If we manage to construct a set F1 with one edge per each kite such that additionally the multigraph G2 ∪ F1 is path-2-colorable, then we have a 54 -approximation of Max TSP. Since computing such F1 may be difficult, we allow, in turn, certain edges of C2 to be removed from G2 and added to G1 . Thus, roughly, our goal is to compute such disjoint sets F1 , F2 that: 1. F1 ⊂ Cmax contains at least one edge of each kite; 2. for each kite c, F2 ⊂ I(C2 ) contains exactly one edge not contained in c; 3. the multigraph G′1 = G1 \ F1 ∪ F2 is path-3-colorable; 4. the multigraph G′2 = G2 \ F2 ∪ F1 is path-2-colorable. Let F1 and F2 be two sets of edges that satisfy properties 1. and 2. of the above. Then the set of edges C2′ = (I(C2 ) ∪ Z ∪ F1 ) \ F2 can be partitioned into cycles and paths of G′2 , where G′2 denotes the resulting multigraph G2 \ F2 ∪ F1 . The partition of C2′ into cycles and paths is carried out in such a way that two incident edges of C2′ belonging to a common path or cycle of C2 , belong also to a common path or cycle of C2′ (and G′2 ). Also, the partition is maximal, i.e., we cannot add any edge e of C2′ to any path p of G′2 so that p ∪ {e} is also a path or cycle of G′2 . We say that e is a double edge of G′2 , or that e is double, if the multigraph G′2 contains two copies of e. In any path-2-coloring of G′2 every double edge must have both colors of K2 assigned to it. We observe that in order for G′2 to be path-2-colorable, we have to guarantee that there does not exist a cycle c of G′2 of odd length l that has l incident double edges. Since every two consecutive edges of c are incident to some double edge, they must be assigned different colors of K2 and because the length of c is odd, this is clearly impossible. The way to avoid this is to choose one edge of each such potential cycle and add it to F2 . We say that a path p of G′2 beginning at w and ending at v is amenable if (i) neither v nor w has degree 4 in G′2 or (ii) v has degree 4, w has degree smaller than 4 and p ends with a double edge, the last-but-one edge of p is a double edge or the last-but-one and the last-but-three vertices in p are matched in M . It turns out that G′2 that does not contain odd cycles described above and whose every path is amenable is path-2-colorable - we show it in Section 8. To facilitate the construction of G′2 , whose every path is amenable and to ensure that F1 and F2 have certain other useful properties we create 10 two opposite orientations of I(C2 ): D2 and opp(D2 ). In each of these orientations I(C2 ) contains directed cycles and paths and each kite has the same number of incoming and outgoing edges. (This can be achieved by pairing the endpoints of paths ending at the same kite and combining them. For example, if C2 contains half-edges h1 = (u, xu{u,v} ) and h2 = (w, xw {u,w} ) of a certain 3-kite t ′ ′ and edges e1 = (u , u), e2 = (w , w), then in the orientation in which e1 is directed from u′ to u the edge e2 must be directed from w′ to w.) Apart from whole edges C2 contains also half-edges. Let H(C2 ) denote the set of edges of G such that C2 contains exactly one half-edge of each of these edges. We partition H(C2 ) into two sets Z1 , Z2 so that for each kite c half of the edges of H(C2 ) is contained in Z1 and the other half in Z2 . With each of the orientations D2 , opp(D2 ) we associate one of the sets Z1 , Z2 . Thus, we assume that D2 contains Z1 , with the edges of Z1 being oriented in a consistent way with the edges of I(C2 ) under orientation D2 , and opp(D2 ) contains Z2 , with its edges being oriented accordingly. The exact details of the construction of Z1 and Z2 are given in the proof of Lemma 6. Depending on which of the sets Z1 , Z2 has bigger weight, we either choose the orientation D2 or opp(D2 ). Hence, from now on, we assume that the edges of I(C2 ) ∪ Z are directed. Lemma 6 It is possible to compute sets F1 , F2 such that they and the resulting G′2 satisfy: 1. F1 ⊂ Cmax \ ((Z ∪ I(C2 )) ∩ M ); 2. F2 ⊆ I(C2 ) ∪ Z; 3. for each kite c, (i) the set F1 contains exactly one edge of c and the set F2 contains zero edges of c or (ii) (it can happen only for 4-kites) the set F1 contains exactly two edges of c and the set F2 contains one edge of c \ M ; 4. for each kite c the set F2 contains exactly one outgoing edge of c; 5. for each kite c and each vertex v of c the number of edges of F2 incident to v is at most one greater than the number of edges of F1 incident to v; 6. there exists no cycle of G′2 of odd length l that has l double edges incident to it; 7. each path of G′2 is amenable. The property 1. of this lemma guarantees that G′2 does not contain more than two copies of any edge. We show in Appendix 8 that properties 6. and 7. are essentially sufficient for the multigraph G′2 to be path-2-colorable. Properties 4. and 5. will be helpful in finding a path-3-coloring of G′1 . Property 5. ensures that no vertex v has six incident edges in G′1 . The proof of this lemma is given in Section 9. The path-2-coloring of G′2 is quite similar to the path-3-coloring of G1 . It is described in Section 8. 5 Completing the path-coloring of G After the construction and path-2-coloring of G′2 we are presented with the task of extending the partial path-3-coloring of G1 to the complete path-3-coloring of G′1 . In particular, we have to color 11 the edges of kites, edges of F2 that have been added during the construction of G′2 and external edges of M incident to 3-kites, called tails. A tail incident to a 3-kite t is said to be a tail of t. Let us now describe the set of uncolored edges of G′1 in more detail. Each one of them is incident to some kite and has either (1) two endpoints belonging to the same kite c (an internal edge of c), or (2) one of its endpoints belongs to some kite c and the other does not belong to any kite (an external edge of c) or (3) its endpoints belong to two different kites c and c′ (an external edge both of c and c′ ). Let t denote a 3-kite. Then by Lemma 6 exactly one edge of t belongs to F1 , no edge of t belongs to F2 and there also exists exactly one edge in e ∈ F2 that is an outgoing edge of t, i.e., e is an external edge of t and is directed from an endpoint belonging to t in I(C2 ). F2 may also contain up to three incoming edges of t, each one incident to a different vertex of t. Any incoming edge of t is also an outgoing edge of some other kite. A tail of t is also uncolored in G′1 . Each uncolored edge e of G′1 has a requirement d(e) denoting the number of colors of K3 that must be assigned to it. Then for any edge e contained in some 3-kite, d(e) = 3 if e ∈ M \ F1 , d(e) = 1 if e ∈ F1 \ M and d(e) = 2 otherwise. Thus, for each 3-kite t we have to color exactly six of its edges in the multigraph G′1 . Let s denote a 4-kite. Then by Lemma 6 either (1) exactly one edge of s belongs to F1 and no edge of s belongs to F2 or (2) exactly two edges of s belong to F1 and one edge of s belongs to F2 . There also exists exactly one edge e ∈ F2 that is an outgoing edge of s. F2 may also contain up to four incoming edges of s, each one incident to a different vertex of s. For any edge e belonging to some 4-kite, d(e) = 3 if e ∈ M \ F1 or e ∈ F2 , d(e) = 1 if e ∈ F1 \ M and d(e) = 2 otherwise. Thus, for each 4-kite s we have to color exactly nine of its edges in the multigraph G′1 . Each uncolored external edge e in G′1 has requirement d(e) = 1. Let H denote the subgraph of G′1 comprising all edges with positive requirement. We need to assign colors of K3 to edges of H (or, in other words, color edges of H with colors of K3 ) in such a way that each color class in the whole graph G′1 forms a collection of disjoint paths. The coloring of edges of H is an extension of the already existing partial path-3-coloring of G1 . Therefore, for some edges there exist restrictions on colors of K3 that can be assigned to them. Consider any vertex v that does not belong to any kite and that has one or two incident edges in H. If v has an incident tail in H, then it has exactly two incident edges in G′1 \ H that are colored with two different pairs of colors of K3 (while path-3-coloring G1 we can easily guarantee that two consecutive edges of Cmax incident to v such that an edge of M incident to v is also incident to a 3-kite are colored with two different pairs of colors). Let these pairs of colors be {k1 , k2 } and {k2 , k3 }. Hence any edge of H incident to v may be colored only with k1 or k3 - we associate with v a two-element subset Z(v) = {k1 , k3 }. Moreover, if v has two incident edges in H and we color one of them with k1 , then the other one must be colored with k3 . If v does not have an incident tail in H, then it has at most one incident edge in H and exactly five edges in the multigraph G1 as well as in the multigraph G′1 \ H. In this case there exists exactly one color k of K3 that can be assigned to an edge of H incident to v and we associate a one-element subset Z(v) = {k} with v. Let t be a 3-kite. Then a vertex of t incident to its tail is called a foot vertex (of t). If e′ ∈ F1 ∩t is incident to the foot vertex of t, then t is said to be vertical; otherwise it is horizontal. Two 3-kites t1 and t2 having a common tail are called twins. Also, each one of them is called a twin and t1 is said to be a brother of t2 . A 3-kite that is not a twin is said to be non-twin. Some of the edges contained in H are directed. The directions of edges of H satisfy: 1. each internal edge is undirected (i.e., each edge contained in a kite); 12 2. the direction of each edge of F2 is the same as in I(C2 ); the properties of edges of F2 are described in Lemma 6 in properties (3), (4) and (5); 3. a tail of two twins is undirected; otherwise, a tail of a 3-kite t is an incoming edge of t. (It may happen that a tail e of some 3-kite belongs also to I(C2 ) and F2 . Then G′1 contains two copies of e, each one with the requirement d(e) = 1 and the copy corresponding to a tail is treated as a tail and the other copy is treated as an external directed edge.) From graph H we build a graph I by shrinking each kite to a single vertex. Each vertex of I that corresponds to a kite in H is called, respectively a t-vertex (if it is a 3-kite) or an s-vertex (if it is a 4-kite); each remaining vertex is called an o-vertex. In any coloring of I or H, we say that an o-vertex v is respected if any edge incident to v is assigned a color belonging to Z(v) and if there are two edges incident to v, then they have different colors assigned to them. To pre-color a directed cycle or path r of I means to color each of its edges with a color of K3 so that each o-vertex of r is respected. To color a kite c means to color each edge e of c with d(e) colors of K3 . We are going to color the edges of H in portions - by considering directed cycles and paths in I. For each such cycle or path we will color its edges as well as some of the kites corresponding to its vertices. To be able to talk more precisely about these operations we introduce below the notions of processing a directed cycle or path r in I and step-processing a vertex v on r. Processing a directed cycle or path r in I consists in step-processing each of its vertices on r. Definition 2 Let r be a directed cycle or path in I and v a vertex on r that has an outgoing edge that belongs to r. To step-process v (or in case v corresponds to a kite c, to step-process c) on r means: • if an outgoing edge of v is uncolored - to color it, • if v has an incoming edge contained in r - to color it, • if v corresponds to a kite c - to color the kite c unless c is a horizontal twin, whose brother has not been step-processed (on any directed cycle or path in I), • if v corresponds to a non-twin 3-kite t - to color the tail of t, • if v corresponds to a twin 3-kite t, whose brother t′ has already been step-processed - to color the common tail of t and t′ and in case t′ has not already been colored, to color t′ , • to carry out the above so that each color class forms a collection of vertex-disjoint paths in G′1 and so that each o-vertex in I is respected. To process a directed path r in I that goes through vertices v1 , . . . , vk and directed from vk to v1 means to step-process each of the vertices v2 , . . . , vk in turn, starting from v2 . When we process such a path, then we start the step-processing v2 by coloring an outgoing edge of v2 incident also to v1 . We then continue step-processing v2 and afterwards, proceed to ste-processing v3 , then v4 and so on. If vi and vj of r correspond to twins ti and tj such that ti is horizontal and considered before tj on r, then while step-processing ti we only color the edges incident to vi and leave ti and its tail uncolored. When we come to vj , we color the incoming edge of r incident to vj and both twins ti 13 and tj and their common tail. In an analogous way we define the processing of a directed cycle r in I - we start from step-processing any vertex on r and continue with step-processing subsequent vertices along r. Let us notice that if a vertex v corresponding to a kite c has not been step-processed, then c is uncolored and either (1) every external edge of c is also uncolored or (2) an outgoing edge of c is colored because we have just step-processed v ′ on some directed path or cycle r such that r contains an edge (v, v ′ ); apart from this every other external edge of c is uncolored. Also, a given vertex v has exactly one outgoing edge in I but may belong to more than one directed path in I or it may belong to a directed cycle and some directed path(s) in I. However, in Algorithm 2 the first time we encounter v while processing a directed cycle or path, we will step-process it, because each considered directed path is maximal under inclusion. If we encounter v again while processing a different cycle or path, we will just color some of its incoming edges (and possibly a tail and so on) but will not step-process v again. Algorithm 2 Color H while ∃ a directed cycle in I do process it and remove its edges from I end while while ∃ a directed maximal path in I do process it and remove its edges from I end while In Section 7 we prove that every directed cycle or path can be processed. 14 6 Summary Algorithm MaxTSP 1. Compute a cycle cover Cmax of G of maximum weight and a perfect matching M of G of maximum weight. 2. Let G1 denote a multigraph obtained from two copies of Cmax and one copy of M - its weight is at least 25 opt. Path-3-color G1 with colors of K3 = {1, 2, 3} leaving kites and edges of M incident to kites uncolored. 3. Compute a maximum weight relaxed cycle cover C2 improving Cmax with respect to M . 4. Let G2 denote a multigraph obtained from one copy of C2 and one copy of M - its weight is at least 32 opt. Compute the sets of edges F1 ⊂ Cmax , F2 ⊂ C2 such that the multigraph G′1 = G1 \ F1 ∪ F2 is path-3-colorable and the multigraph G′2 = G2 \ F2 ∪ F1 is path-2-colorable (i.e. F1 , F2 are as in Lemma 6). 5. Path-2-color G′2 with colors of K2 = {4, 5}. 6. Extend the partial path-3-coloring of G1 to the complete path-3-coloring of G′1 . 7. Choose the color class of maximum weight - its weight is at least 54 opt and complete the paths of this class into a traveling salesman tour in an arbitrary way. The presented algorithm works for graphs with an even number of vertices. If the number of vertices of a given graph is odd, then we can guess one edge, shrink it and compute the remaining part of the solution in the graph with even vertices. 7 Correctness of Algorithm 2 We are going to prove that every directed cycle or path in I can be processed. First we give several auxiliary lemmas. Lemma 7 Let c be a directed cycle in I of even length, whose every other vertex is an o-vertex. Then we are able to pre-color c in such a way that its every two consecutive edges get assigned different colors. Proof. First, let us notice that an o-vertex v may have two incident edges in I only if one of them is a tail of some 3-kite. Thus, every vertex of c that is not an o-vertex must correspond to a 3-kite and be a t-vertex. 15 If the length of c is two, then c contains exactly one o-vertex v. We then assign one color of Z(v) to one edge of c and the other color of Z(v) to the other edge of c and are done. Suppose now that c has length greater than two. Let v be any o-vertex of c and e1 , e2 the edges of I incident to v. We assign one of the colors k1 of Z(v) to e1 and the other k2 to e2 . Assume that e2 is an incoming edge of v1 , e3 is an outgoing edge of v1 and e4 , . . . , ek are the subsequent edges of c. The edges e3 and e4 are incident to another o-vertex v ′ of c. We will show now that whatever the set Z(v ′ ), we are always able to asign colors to e3 and e4 in such a way that e4 does not get assigned k1 - the color already assigned to e1 . If Z(v ′ ) contains k2 and some other color k4 , then we assign k4 to e3 and k2 to e4 . If Z(v ′ ) does not contain k2 , then it contains k1 and k3 and we assign k1 to e3 and k3 to e4 . This way (i) edges e2 and e3 get assigned different colors and (ii) e4 gets assigned a color different from k1 . If c has length 4, then we notice that the edges e1 and e4 of c get assigned different colors as well and we are done. If c has length greater than 4, then we consider the next pairs of edges and continue in the manner described above. More precisely, when we consider the pair of edges e2i+1 and e2i+2 incident to some o-vertex w, we know that the invariant that e1 and e2i have different colors assigned is satisfied. Our goal is to color e2i+1 and e2i+2 in such a way that (i) e2i+1 gets assigned a color different from the color assigned to e2i and (ii) e2i+2 gets assigned a color different from k1 . From the way we have analysed coloring e3 and e4 , we know that it can always be done. ✷ Corollary 2 Let c be a directed cycle in I of even length, whose every other vertex is an o-vertex. Then we are able to process c. Proof. First, let us notice that every t-vertex of c corresponds to a non-twin 3-kite, because the tail of each such kite is contained in c and thus is directed. While pre-coloring c whenever two edges e1 , e2 of c adjacent to the same kite c get colored, we also color c. While coloring c we only have to see to it that no vertex of c gets three incident edges of the same color in G′1 and to that c does not contain a monochromatic cycle i.e. a 3-cycle. We show how to color c in Figure 2 and in Figure ??. Let us notice that after pre-coloring c and all 3-kites corresponding to t-vertices on c, no color class contains a cycle - this is because every edge e of c is incident to a t-vertex corresponding to a 3-kite t and the only external edges incident to t in the whole graph G′1 are e and some other edge e′ of c. We know, however, that every two consecutive edges of c are colored differently. Hence e′ is colored differently from e. Thus, neither e nor e′ can belong to a monochromatic cycle, which means that in this way we process c. ✷ Suppose that the tail e of t is uncolored. Then t is said to be flexible if there exist such two colors k, k′ ∈ K3 that e can be colored both with k and k′ , by which we mean that if we color the tail of t with k (or correspondingly k′ ), then the foot of t does not have more than three incident edges colored with k (resp. k′ ). The flexibility of a 3-kite t is useful when t is a vertical twin that is step-processed before its twin t′ . Then while step-processing t we color t but leave its tail uncolored and later later while step-processing t′ we have a greater ’flexibility’ in coloring t′ and its tail. Lemma 8 Let t be any uncolored vertical 3-kite and e1 , e2 ∈ F2 \ M two external edges incident to t colored with, respectively, k1 and k2 . Let w be the foot vertex and e the tail of t. Additionally, e1 16 and e2 are not both incident to w and k1 6= k2 . Then it is possible to color the edges of t so that t becomes flexible and so that e can be colored with k3 ∈ / {k1 , k2 }. Proof. For all possible triangles we will show how to color the edges for t. These colorings are presented in Figure 2. k2 k1 k2 k2 k1 k2 k3 k1 k2 k3 k1 k2 k3 k1 k1 k3 k1 k3 k2 k1 k2 k1 k2 (a) e can be colored with all colors in K3 (b) By Lemma 6 edge in F1 ∩ t must be incident to e1 and e2 . e can be colored with all colors in K3 (c) Both edges of t incident to w can be colored with k3 , depending on which one is not in F1 . e can be colored with k1 and k3 Figure 2: Vertical triangles with k1 6= k2 and e1 not incident to w ✷ Lemma 9 The computed sets F1 , F2 satisfy: 1. No foot of a 3-kite has two incident edges of F2 . 2. If a 3-kite has four incident edges of F2 , then it is vertical. The proof follows from the proof of Lemma 6. Lemma 10 Let t be a vertical 3-kite, whose tail e is uncolored and that has been colored at some point as in Lemma 8. Then, however, we color any further external edges of H incident to t apart from its tail, t always stays flexible. Proof. The lemma follows from the fact that the foot of t has not two incident edges of F2 . ✷ Let t be an uncolored 3-kite t, whose tail e is also uncolored. Then we say that t is weakly flexible if there exist two colors k, k′ ∈ K3 such that t can be colored in at least two ways and in one of these colorings e can be colored with k and in the other with k′ , i.e., after coloring e with k or k′ , the foot of t has at most two incident edges colored with respectively k or k′ . We say that an uncolored twin t is versatile if every two colored edges of H incident to t have different colors assigned to them. The weak flexibility of a 3-kite t is useful when t is a horizontal twin that is step-processed before its twin t′ . While step-processing t on some directed cycle or path r we do not color it or its tail but only the incident edges of r and later while step-processing t′ we color both t and t′ and their common tail. 17 Lemma 11 Every uncolored versatile horizontal 3-kite is weakly flexible. Proof. Let t be any triangle on vertices u, v, w as in Lemma 11 and let e1 , e2 , e3 three external edges incident to t colored with, respectively, k1 , k2 and k3 . Let w be the foot vertex and e the tail of t. Let us assume that e2 and e3 are not incident to w. Then we can color e with k2 and k3 . For each of these colors we have to show how to color edges of t. As these cases are symmetric, we assume that e is colored with k2 . Let us assume that e2 is incident to v. Then we color (u, v) and (u, w) with k2 . k2 e2 k2 k2 As t is horizontal, we still have to color (v, w) with 2 colors, and the other edges with one color. If there is an edge, say e1 , incident to w we color (v, w) and (v, u) with k1 . If there is an edge incident to v other than e2 , say e3 , we color (v, w) and (u, w) with k3 . If there are both of these edges, than it is correct coloring. Otherwise there is an edge incident to u, say e1 , and we can color (v, w) and either (u, v) or (u, w) with k1 , so we can always color t. ✷ Lemma 12 Every directed cycle or path can be processed in such a way that at all times every uncolored horizontal twin is versatile. Proof. Let us consider a directed path p going through vertices v1 , . . . , vk and directed from vk to v1 . We can notice that since cycles are processed before paths, each vertex of p is distinct. We observe also that v1 is either an o-vertex or corresponds to a kite that has already been step-processed otherwise we could extend p, because then the outgoing edge of v1 would be uncolored. Vertex vk , on the other hand, is either an o-vertex or corresponds to an uncolored (and not step-processed) kite. We begin by coloring the arc (v2 , v1 ) with any color of K3 that is available. Let us note that some color of K3 is always available because of the following. If v1 is an o-vertex, then it has exactly six incident edges in the multigraph G′1 - apart from five edges in the multigraph G1 , it has an additional incoming edge that is an outgoing edge of some kite. If v1 corresponds to a kite, then Lemma 6 Property 5 guarantees that any vertex in G′1 belonging to a kite has degree at most six. Also, if v1 corresponds to an uncolored 3-kite t that has already been step-processed, then we color (v2 , v1 ) with such a color k of K3 that no external edge of t is colored with k. Such a color k always exists because only horizontal 3-kites can be left uncolored and they have at most three incident edges of F2 . Thus we can guarantee that t remains versatile. We step-process subsequent vertices on p according to the rules listed below. Let e1 ∈ p be an outgoing edge of v colored with k1 and e2 an uncolored incoming edge of v. Depending on whether v is an o-, t- or s-vertex and other conditions we proceed as follows: 18 1. e2 ∈ M . Then v must be a t-vertex corresponding to a 3-kite t and e2 is an outgoing edge of an o-vertex v ′ . We color t, e2 and an incoming edge e3 of v ′ . If Z(v ′ ) = {k1 , k′ }, then we color e2 with k′ and e3 with k1 . Otherwise Z(v ′ ) = {k2 , k3 } = K3 \ k1 . Then we color e2 with k2 and e3 with k3 or the other way around. 2. v is a t-vertex corresponding to a non-twin 3-kite t and e is the tail of t incident to an overtex v ′ . We color t, e2 and e. If Z(v ′ ) = {k1 , k′ }, then we color e with k ′ and e2 with k ∈ K3 \ {k1 , k′ }. Otherwise Z(v ′ ) = {k2 , k3 } = K3 \ k1 . Then we color e2 with k2 and e with k3 or the other way around. 3. v is a t-vertex corresponding to a twin 3-kite t, whose brother t′ has already been colored and e is the tail of t. Then by Lemmas 8 and 10, there exist two colors of K3 , such that if we look only at t′ , then e can be colored with either of them. Let Z(e) denote the set consisting of these two colors. Now we proceed almost identically as in the case above. If Z(e) = {k1 , k′ }, then we color e with k′ and e2 with k ∈ K3 \ {k1 , k′ }. Otherwise Z(e) = {k2 , k3 } = K3 \ k1 . Then we color e2 with k2 and e with k3 or the other way around. We color t. Note that each colored external edge of t is colored with a different color. This cannot be said about t′ - it may happen that the tail of t′ is colored with the same color as some other external edge e′ of t′ , but we do not have to worry about edge e′ ending in a monochromatic cycle because then the tail of t and t′ would also have to belong to such cycle. 4. v is a t-vertex corresponding to a twin 3-kite t, whose brother t′ has not been step-processed. We color e2 with k2 or k3 . If t is vertical, then we color t. Otherwise we leave t uncolored. 5. v is a t-vertex corresponding to a twin 3-kite t, whose brother t′ has been step-processed but is uncolored. Since t′ has been step-processed, but is uncolored, it is horizontal. By Lemma 11 t′ is weakly flexible - therefore there exist two colors k, k′ that can be used for coloring the tail of t′ . If k1 ∈ {k, k′ }, then we color the tail of t and t′ with the color belonging to {k, k′ } \ k1 and e2 with the remaining color of K3 - note that this way each colored external edge of t is colored with a different color. If k1 ∈ / {k, k′ }, then we color the tail with k2 and ′ e2 with k3 . We also color both t and t . 6. v is an s-vertex. Then we color e2 with any color of K3 different from k1 . We also color s. We argue that by proceeding as above, we do not create a monochromatic cycle in G′1 and thus process p. This is so, because every external edge colored with k while processing p is contained in some path p′ consisting of edges colored with k that ends at a vertex of p corresponding to a kite c′ such that c′ has only one incident external edge in G′1 colored with k. Let us now turn our attention to directed cycles. Let c be a directed cycle of I. We can assume that c is not as in Lemma 7, because we have already dealt with such cycles. Thus c contains two subsequent vertices v, v ′ such that neither v nor v ′ is an o-vertex and c contains an edge (v, v ′ ) directed from v to v ′ . If possible we choose v that is an s-vertex or corresponds to a 3-kite t, whose tail also belongs to c. If such v does not exist then we choose v that corresponds to a 3-kite that is either non-twin or whose brother has already been step-processed. For now, we assume that this is the case. We start by coloring an incoming edge of v. If v corresponds to a 3-kite t, whose tail q does not belong to c, then q can be colored with some two colors k2 , k3 . In this case we color the incoming edge of v with k1 ∈ / {k2 , k3 }. 19 We continue processing c according to the rules described above until we reach the vertex v ′ . If applying the rules also to v ′ would result in the arc (v, v ′ ) being colored with a different color than an incoming edge of v, we apply the rules to v ′ and are done. Otherwise v ′ must correspond to a 3-kite t′ which is either non-twin or that is a twin whose brother has already been colored. Also, assume that the incoming edge of v is colored with k1 . It follows that the tail of t′ can be colored with k2 or k3 , both different from k1 , and that the outgoing edge of t′ is colored with k2 or k3 . Otherwise we would be able to color (v, v ′ ) with a color different from k1 . Suppose that the outgoing edge of v is colored with k2 . In this case we color the tail of t′ with k3 and color (v, v ′ ) with k3 - if it is not incident to the tail of t′ and with k2 otherwise. By Lemma 9 property 1, it cannot happen that both the outgoing and incoming edge of t′ is incident to the foot of t′ . We are left with the case when each vertex of c corresponds to a twin 3-kite whose brother also occurs on c. We leave this case to the reader. ✷ 8 Path-2-coloring The partition of G′2 into cycles and paths is carried out in such a way that two edges of C2′ belonging to a common path or cycle of C2 , belong also to a common path or cycle of G′2 . Also, the partition is maximal, i.e., we cannot add any edge e of C2′ to any path p of G′2 so that p ∪ {e} is also a path or cycle of G′2 . We may assume that each path and cycle of G′2 is directed - the orientations of edges are consistent with those in G2 . A surrounding of a cycle c of C2 , denoted as sur(c), contains every edge of c and every edge of M incident to c. Let p be a path of G′2 directed from u to v. If v has degree 4 in G′2 , then an edge e of p incident to v is said to be a border of p. The surrounding of p, denoted as sur(p), contains every edge of p and every edge of M incident to p. We construct a directed graph Gp = (Vp , Ep ) such that each path of G′2 is represented by some vertex of Vp and Ep contains an edge (p, p′ ) iff p has a border and the border of p is incident to some vertex of p′ . Thus each vertex of Vp has at most one outgoing edge. Below we describe the algorithm for path-2-coloring the graph G′2 . In it we first color the cycles of G′2 and their surroundings. The order of coloring the paths of G′2 is dictated by the structure of graph Gp : we begin by coloring the paths of G′2 that form cycles in Gp ; next at each step we color an uncolored path, whose outdegree in Gp is zero. The presence of borders complicates path-2-coloring in two aspects: 1. Suppose that edges e1 = (u, u′ ) and e2 = (u, u′′ ) belong to some path of G′2 and that u is incident to a double edge ed different from e1 and e2 . Since ed has to be colored with two colors of K2 , edges e1 and e2 must be assigned different colors of K2 . Therefore while path-2-coloring G′2 we will preserve the following invariant: Invariant 1 Every two edges e1 = (u, u′ ), e2 = (u, u′′ ) of G′2 such that their common endpoint u is incident to a double edge ed different from e1 and e2 are assigned different colors of K2 . 2. Each border b of a path p of G′2 is colored while coloring the path p and not before. In particular, if b is double and is incident to a path or cycle p′ such that p′ is colored before p, then while coloring p′ we assign only one color to b. The second one is assigned while coloring 20 p. If b is double we may also think of it as of two edges - one being a border and the other an edge of the matching M . Because of this we modify the meaning of a safe edge in this section as follows. We say that a colored edge e is safe if no matter how we color the so far uncolored edges except for any uncolored borders, e is guaranteed not to belong to any monochromatic cycle. In particular, it means that if we want to prove that a newly colored border b is safe we have to explicitly show that it does not belong to any monochromatic cycle - without taking use of the fact that previously colored edges are safe. Algorithm 3 Color G′2 During the whole execution ensure that Invariant 1 is satisfied. while ∃c – an uncolored cycle of G′2 do for e ∈ sur(c) do color e in such a way, that it is safe end for end while while ∃cp – a directed cycle of Gp do for p such that p is a vertex on cp do color each e ∈ sur(p) in such a way, that it is safe end for remove each vertex of cp together with incident edges from Gp end while while ∃p – an uncolored path of G′2 such that outdegGp (p) = 0 do for e such that e ∈ sur(p) do color e in such a way, that it is safe end for remove p together with incident edges from Gp end while Lemma 13 Let c be an uncolored cycle c of C2 considered at some step of Algorithm Color G2 . Then it is possible to color each edge belonging to sur(c) in such a way that it is safe. Proof. The procedure of coloring the edges of sur(c) is similar to that described in the proofs of Lemmas 1 and 4. We orient the edges of c so that c becomes directed. Case 1: (i) For each color k ∈ K2 there exists an edge of M incident to one of the edges of c that is colored k or (ii) there exists an uncolored edge of M incident to one of the edges of c. First we color every uncolored non-double edge e of M incident to c so that case (i) holds. Next we color each double edge incident to c. Let e = (u, v) be a double edge such that u belongs to c. Then, necessarily v belongs to some path of C2 and since we color cycles of C2 before coloring paths of C2 , e is uncolored. We start with such a double edge e = (u, v) that the predecessor u′ of u on the cycle c has no incident double edge. The existence of such double edge is guaranteed by Lemma 6. Let e1 = (u, u′ ) and e2 = (u, u′′ ) be two edges of c incident to u and let e′ be an edge of M incident to u′ and k the color of K2 assigned to e′ . To preserve Invariant 1 we have to color the edges e1 , e2 with different colors of K2 . To make it possible we color e with a color k ′ belonging to K2 \ k, i.e., 21 for the time being we color e only with one color instead of two. We proceed with each subsequent double edge incident to c in the same way, i.e., we color such edges in order of their occurrence along c. Further we color all edges of c. Let e = (u, v) be an edge of c oriented from u to v and let e′ be an edge of M incident to u k the color of K2 assigned to e′ . Then we color e with a color k ′ belonging to K2 \ k. We can notice that each so far colored edge is safe. Suppose that e = (u, v) is colored with k. Then we additionally assign k ′ 6= k to e. Case 2: All edges of M incident to c are colored with the same color k. We color any chosen one edge of c with k and the remaining ones with k ′ 6= k. ✷ Lemma 14 Let p be an uncolored path p of C2 considered at some step of Algorithm Color G2 such that outdegGp (p) = 0. Then it is possible to color each edge belonging to sur(p) in such a way that it is safe. Proof. Generally we proceed in a very similar way as in Lemma 13. The path p is already oriented. First we color each edge of M incident to p with one color of K2 in order of their occurrence along p. If a given edge e of M incident to u is double, then we color it with one color only and with the one different from that assigned to an edge of M incident to u′ which proceeds u on p. Next we color each edge (u, v) of p directed from u to v, which is not a border of p with a color different from that assigned to an edge e′ of M incident to u. We must also color the border b of p, if p has one. If b is double, then it must have got assigned one color of K2 before we started coloring p - that is because outdegGp (p) = 0, which means that b got colored while coloring the path or cycle of G′2 incident to b. It may also happen that the border b of p is incident to some ”internal” vertex of p but then we have also already assigned one color of K2 to it. If b is already colored with k1 , then we additionally assign k2 6= k1 to it. The safety of b follows from the following. The edge e proceeding b on p is colored with one color k of K2 . From the way we color edges of p, we notice that e is contained in a monochromatic path pk colored with k, whose one endpoint lies on p. In other words we claim that pk has a ”dead end”. We can observe that a part of pk starting with e is contained in p and does not leave p. It follows from the fact that each edge (u, v) of p is colored with a color different from the one assigned to the edge of M incident to u. This means that e is safe, because we have already colored every edge of p and every edge of M incident to p (except possibly for some borders), hence b is safe. If the border b = (u, v) of p is not double, then we still have to color it. Suppose that v is the endpoint of p. Then three edges of the multigraph G′2 incident to v have already been colored. This means that there is only one color of K2 that can be used for coloring b. We must also ensure that after coloring b, it does not belong to any monochromatic cycle. Since p is amenable, b is either proceeded by a double edge on p or an edge e′ of M incident to v is also incident to a last-but-three vertex of p. In the first case, the safety of b follows from the fact that an edge of p proceeding a double edge proceeding b is safe. (The argument is the same as above.) In the second case we leave the edge e′ uncolored till this point. Once we know that we are forced to color b, with say k ∈ K2 , we color e′ with the other color of K2 and we also color accordingly the two edges proceeding b and are done. ✷ 22 Lemma 15 Let cp be a directed cycle of Gp considered at some step of Algorithm Color G2 . Then it is possible to color each edge belonging to the surrounding of each path of G′2 occurring on cp in such a way that it is safe. Proof. Suppose that the cycle cp goes through vertices p1 , p2 , . . . , pk in this order. Let (ui , vi ) denote the border of path pi of G′2 for each i, 1 ≤ i ≤ k. We start by coloring the path p1 and its surrounding in the manner described in the proof of Lemma 14. If the border (u1 , v1 ) is not double, then we leave it uncolored. Next we color each of the paths p2 , . . . , pk−1 and their surroundings together with their borders, also in the way described in the proof of Lemma 14. Next we have to check two possibilities of dealing with the path pk . First we color the path pk together with its border and surrounding in the same manner as the remaining paths p1 , . . . , pk−1 and if the border (u1 , v1 ) is uncolored, because it is not double, we color it with the only possible color of K2 . It may happen, however, that by doing so we create a monochromatic cycle c′ that is formed by the part of p1 between v1 and v2 , the part of p2 between v2 and v3 and so on until the part of pk between vk and v1 . If this is the case, then we leave the part of pk between vk and v1 colored as it is and uncolor the remaining part of pk . If the border (u1 , v1 ) is not double, then we change its color to the opposite one. If the border (u1 , v1 ) is double, then we change the color of the edge proceeding it on p1 to the opposite one. Next we change the orientation of the uncolored part of pk as follows. The endpoints of pk are vk and some vertex wk and originally pk is oriented from wk to vk . Now we change the orientation of the part p′ of pk between v1 and wk so that it is directed from v1 to wk . Let e = (w, v1 ) denote the edge of p′ incident to v1 . Since v1 has degree 4 in the multigraph G′2 , there exists only one color k of K2 that can be used for coloring e. The rest of p′ is colored in the standard way. We only have to show that the edge e is safe, as every other edge considered in this lemma is safe by reasoning analogous to that used in two previous lemmas. The edge e is safe because it is colored with same color k that every edge of c′ but one is colored with. Also, e is the only edge incident to c′ but not lying on c′ that is colored with k. The example of this algorithm is presented on Figure 3. ✷ 9 The proof of Lemma 6 First we want to guarantee that property 6. is satisfied. Let us say that an edge e is a d-edge if it belongs to M and some kite. Let S contain every cycle of C2 of odd length l that has l different incident d-edges. Let T denote the set of all d-edges. We build a bipartite graph Gd = (S ∪ T, Ed ) such that there exists an edge in Ed between a cycle c of S and edge e of T iff e is incident to c. Furthermore for each 4-kite s incident to at most three cycles in S we merge vertices corresponding to d-edges in s into one vertex. Let us notice that the degree of each d-edge of T in Gd is at most 3 and the degree of each cycle c of S is at least 3. We compute a matching Md of size |S| in the graph Gd . By Hall’s Theorem such a matching always exists. Then for each cycle c and matched to it d-edge e we will either (i) add an outgoing edge of c incident to e to F2 or (ii) ensure that e is not a double edge. We begin with the proof for the case when there are only 3-kites. Let t be any 3-kite on vertices u, v, w such that e = (u, v) is a d-edge of t and e2 = (u, w) and e3 = (v, w). 23 v1 w2 5 4 u2 45 u1 4 5 45 4 4 5 5 w1 5 4 5 5 v2 5 (a) Paths of cp before coloring. There are two paths: the first one from w1 to v1 and the second one from w2 to v2 . 4 (b) Preliminary coloring of paths of cp . There is a monochromatic cycle in color 5 5 5 45 4 4 5 5 45 4 5 5 4 (c) We recolor edge (u1 , v1 ) and path from v1 to w2 . All edges are now safe Figure 3: Example of algorithm described in Lemma 15 24 We begin with the case when t has three incoming and three outgoing edges of C2 incident to it. We add e to F1 . To F2 we add any outgoing edge of t belonging to C2 (it can be an edge required by Md ). If at some later point t gets three incident incoming edges of F2 , then we remove e from F1 and replace it with that one of the edges e2 , e3 that is incident to an outgoing edge of F2 and orient it so that it is directed to w. We do it so that Lemma ?? Property (2) is satisfied. Whenever e does not belong to Z, we add it to F1 and an outgoing edge of t incident to e to F2 . We consider now the cases when t has two incoming and two outgoing edges of C2 incident to it. In Figure 4 we show how to assign edges of all possible 3-kites with two incoming and two outgoing edges to F1 and F2 . In case of triangles with one incoming and one outgoing edge there are already two edges of t in C2 ∪ Z. Therefore we add remaining edge to F1 and incident edge (we can guarantee that it is outgoing when constructing D2 ) to F2 . To finish the proof we must consider all cases for 4-kites. We say that an edge e is a side edge if it belongs to 4-kite, but not to M . Let c be any 4-kite on vertices u, v, w, z such that (u, v) and (w, z) are d-edges and (u, z) and (v, w) are side edges. Let Ic be the set of those edges in I(C2 ), whose both endpoints are in {u, v, w, z} (so I(C2 ) \ Ic contains all incoming and outgoing edges incident to c). First we consider the cases when c has one incoming and one outgoing edge of C2 incident to it (by our construction of C2 these edges must be incident to different vertices of c). If these edges are not incident to the same side edge, we add outgoing edge to F2 and the side edge incident to it to F1 . Otherwise let’s assume that they are incident to (u, z), and that edge incident to u is outgoing in D2 , whereas edge incident to z is outgoing in opp(D2 ). 1. u and z are incident to at most 2 half-edges or 1 edge of Ic and 1 half-edge - we divide halfedges into Z1 and Z2 so that degree of z in I(C2 )∪Z1 ∪M is 3 and degree of u in I(C2 )∪Z2 ∪M is 3. Then we add (u, z) to F1 and outgoing edge to F2 . 2. z is incident to 1 edge of Ic and 2 half-edges and (u, z) is not in Ic - then half-edge (u, z) is in C2 so u is not incident to any edge in Ic . We divide half-edges into Z1 and Z2 so that (u, v) is not in Z1 and degree of u in I(C2 ) ∪ Z2 ∪ M is 3. If outgoing edge is incident to u we add (u, v) to F1 , and otherwise we add (u, z) to F1 . In both cases we add outgoing edge to F2 . 3. (u, z) is in Ic - we divide half-edges so that (u, v) is not in Z1 and (w, z) is not in Z2 . We add d-edge incident to outgoing edge to F1 and outgoing edge to F2 . Now let’s consider the cases when two vertices incident to the same d-edge, say (u, v), are incident to one incoming and one outgoing edge each and the other two vertices aren’t incident to any incoming or outgoing edges. If w and z are incident to two half-edges each then two half-edges incident to w go to Z1 , and the other two half-edges go to Z2 . If w and z are incident to one half-edge each then I(C2 ) must contain (w, z) and we divide half-edges into Z1 and Z2 arbitrarily. There are three cases depending on which edges incident to z are in Z ∪ I(C2 ) (cases when in Z there are half-edges incident to w are symmetric): 1. (w, z) and (v, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 and add (u, z) and (v, w) to F1 . 2. (w, z) and (u, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to v to F2 and add (v, w) to F1 . 25 e e f f2 e2 f1 e2 e1 e1 f3 (a) We add f to F2 and e2 to F1 . In G′2 we orient e2 so that it is directed from a common endpoint with e. (b) We add f1 to F2 and e to F1 . If e2 is in Z we orient it from w to u and make f2 outgoing. If e3 is in Z we orient it from v to w and make f3 outgoing e e f1 f1 e2 e2 e1 e1 f2 (c) If e2 is in Z we make f1 outgoing. In this case we add e to F1 and f1 to F2 and orient e2 from u to w. If e is in Z we make f2 outgoing, add e3 to F1 and f2 to F2 and we orient e3 from v to w (d) If e is in Z we add e2 to F1 and f1 to F2 . If e2 is in Z we add e to F1 and f2 to F2 e e f2 f3 e2 f1 e2 e1 e1 f1 (e) If e2 is in Z we make f1 outgoing, add e to F1 and f2 to F2 . If e is in Z we make f3 outgoing, add e3 to F1 and f2 to F2 (f) We add e to F1 and f1 to F2 Figure 4: Assigning edges of 3-kites with two incoming and two outgoing edges 3. (v, z) and (u, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to v to F2 . If incoming edge incident to v is also in F2 we add (v, w) to F1 . Otherwise we add (w, z) to F1 The next cases are similar to the previous one, but now vertices incident to one incoming and one outgoing edge each are incident to the same side edge, say (u, z). We divide half-edges same as before, so two half-edges incident to v go to Z1 , and the other two go to Z2 . Now the cases are: 26 1. (v, z) and (v, w) are in Z ∪ I(C2 ) and z was matched in Md with (w, z) - we add outgoing edge incident to z and (v, z) to F2 . If incoming edge incident to z is in F2 we add (w, z) and (u, z) to F1 . Otherwise we add (w, z) and (v, w) to F1 . 2. (v, z) and (v, w) are in Z ∪ I(C2 ) and z wasn’t matched in Md with (w, z) - we add outgoing edge incident to u and (v, z) to F2 and we add (u, v) and (z, w) to F1 . 3. (v, z) and (u, v) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 . If incoming edge incident to u is in F2 we add (u, z) and (v, w) to F1 . Otherwise we add (v, w) and (w, z) to F1 . 4. (u, v) and (v, w) are in Z ∪ I(C2 ) and z was matched in Md with (w, z) - we add outgoing edge incident to z to F2 and (w, z) to F1 . 5. (u, v) and (v, w) are in Z ∪ I(C2 ) and z wasn’t matched in Md with (w, z) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is in F2 we add (u, z) to F1 . Otherwise we add (w, z) to F1 . Now there are three cases in which there is a vertex in c, say u, incident to two edges in I(C2 )\Ic , two vertices incident to one edge in I(C2 ) \ Ic each and a vertex incident to no edge in I(C2 ) \ Ic . The first case is when z isn’t incident to any edge in I(C2 ) \ Ic . Let’s assume that edge incident to v is outgoing in D2 . We divide half-edges into Z1 and Z2 so that (i) in Z1 ∪ I(C2 ) there is an edge incident to v and edge incident to z and, similarly, in Z2 ∪ I(C2 ) there is an edge incident to w and edge incident to z (ii) no two half-edges incident to u are in the same set (this condition can be satisfied because in C2 there are at most two half-edges incident to u). Now we consider all subcases of which edges are in Z ∪ I(C2 ): 1. (v, w) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, z) to F1 . 2. (v, w) and (v, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 and add (u, z) and (w, z) to F1 . 3. (v, w) and (u, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, v) to F1 . Otherwise we add (w, z) to F1 . 4. (v, z) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, v) to F1 . 5. (v, z) and (u, z) are in Z ∪ I(C2 ) - there is no edge incident to w, so edge incident to v is outgoing. We add outgoing edge incident to v to F2 and (v, w) to F1 . 6. (u, v) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, z) to F1 . 7. (u, v) and (v, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 and add (u, z) and (w, z) to F1 . 8. (u, w) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (u, w) to F2 and add (u, v) and (u, z) to F1 . 9. (u, w) and (v, w) are in Z ∪ I(C2 ) - (u, w) is incident to neither v nor z, so edge incident to w is outgoing. We add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (w, z) to F1 . 27 10. (w, z) and (u, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, v) to F1 . In the second case w isn’t incident to any edge in I(C2 ) \ Ic . We divide half-edges same as in the previous case, so we guarantee that (i) in Z1 ∪ I(C2 ) there is an edge incident to v and edge incident to w and, in Z2 ∪ I(C2 ) there is an edge incident to z and edge incident to w. Condition (ii) remains the same. Now the subcases are as follows: 1. (v, w) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, v) to F1 . 2. (v, w) and (u, w) are in Z ∪ I(C2 ) - there is no edge incident to z, so edge incident to v is outgoing. We add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (w, z) to F1 . 3. (v, z) and (v, w) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 and add (u, z) and (w, z) to F2 . 4. (v, z) and (u, w) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, v) to F1 , and otherwise we add (w, z) to F1 . In this case at least one of (u, v), (w, z) is not double edge, so cycle going through v and z satisfies condition 6 from lemma. 5. (v, z) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 and add (u, z) and (v, w) to F2 . 6. (u, v) and (v, w) are in Z ∪ I(C2 ) - there is no edge incident to z, so edge incident to v is outgoing. We add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (w, z) to F1 . 7. (u, v) and (w, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (v, w) to F1 . 8. (w, z) and (u, w) are in Z ∪ I(C2 ) - there is no edge incident to v, so edge incident to z is outgoing. We add outgoing edge incident to u to F2 and (u, v) to F1 . 9. (u, z) and (v, w) are in Z ∪ I(C2 ) - (u, z) is incident to neither v nor w, so edge incident to z is outgoing. We add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, v) to F1 . Otherwise we add (w, z) to F1 . 10. (u, z) and (w, z) are in Z ∪ I(C2 ) - there is no edge incident to v, so edge incident to z is outgoing. We add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, v) to F1 . Otherwise we add (v, w) to F1 . In the third case v isn’t incident to any edge in I(C2 )\Ic . Similarly as before we divide half-edges to guarantee that (i) in Z1 ∪ I(C2 ) there is an edge incident to w and edge incident to v and, in Z2 ∪ I(C2 ) there is an edge incident to z and edge incident to v. Once again condition (ii) remains the same. Now the subcases are as follows: 1. (v, w) and (v, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, v) to F1 . Condition 6 from lemma is satisfied, because (w, z) is not a double edge. 28 2. (v, w) and (u, v) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (w, z) to F1 . 3. (u, w) and (v, w) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, w) to F2 . If incoming edge incident to u is also in F2 we add (u, z) and (u, v) to F1 . Otherwise we add (u, v) and (w, z) to F1 . 4. (u, w) and (v, z) are in Z ∪ I(C2 ) - (u, w) is incident to neither v nor z, so edge incident to w is outgoing. We add u to F2 and (u, v) to F1 . 5. (w, z) and either (v, w) or (v, z) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 and (u, v) to F1 . 6. (w, z) and (u, v) are in Z ∪ I(C2 ) - we add outgoing edge incident to u to F2 . If incoming edge incident to u is also in F2 we add (u, z) to F1 . Otherwise we add (v, w) to F1 . 7. (v, z) and (u, v) are in Z ∪ I(C2 ) - we add outgoing edge incident to u and (v, z) to F2 . If incoming edge incident to u is also in F2 we add (u, z) and (w, z) to F1 . Otherwise we add (v, w) and (w, z) to F1 . 8. (u, z) and (v, w) are in Z ∪ I(C2 ) - (u, z) is incident to neither v nor w, so edge incident to z is outgoing. We add outgoing edge incident to u to F2 and (u, v) to F1 . 9. (u, z) and (v, z) are in Z ∪ I(C2 ) - (u, z) is incident to neither v nor w, so edge incident to z is outgoing. We add outgoing edge incident to u and (v, z) to F2 and add (u, v) and (v, w) to F1 . The final case when c is incident to two incoming and two outgoing edges of C2 is when each vertex of c is incident to one edge of I(C2 ) Ic . First suppose that (u, z) is in I(C2 ). Then we can assume that in Z there is half-edge incident to v (or there is (v, w) in I(C2 )), because other cases are symmetric: 1. (u, v) is in Z ∪ I(C2 ) - we add outgoing edge incident to u or z to F2 and (w, z) to F1 . 2. (v, z) is in Z ∪ I(C2 ) - we add outgoing edge incident to u or z and (v, z) to F2 and (u, v) and (w, z) to F1 . 3. (v, w) is in Z ∪ I(C2 ) - we add outgoing edge incident to u or z to F2 and d-edge adjacent to added outgoing edge to F1 . If (u, w) is in I(C2 ) we assume that in Z ∪I(C2 ) there is an edge incident to z and that edge incident to z is outgoing. If edge incident to u is outgoing we add it to F2 and add (u, v) to F1 . If edge incident to w is outgoing then there are three cases: 1. (u, z) is in Z ∪ I(C2 ) - we add outgoing edge incident to w and (u, w) to F2 and add (v, w) and (w, z) to F1 . 2. (v, z) is in Z ∪ I(C2 ) - we add outgoing edge incident to w to F2 and add (w, z) to F1 . 3. (w, z) is in Z ∪ I(C2 ) - we add outgoing edge incident to w to F2 and add (u, v) to F1 . 29 Now suppose that (u, v) is in I(C2 ). We assume that in Z ∪ I(C2 ) there is an edge incident to z and that edge incident to z is outgoing: 1. (u, z) or (v, z) is in Z ∪ I(C2 ) - we add outgoing edge incident to z to F2 and (w, z) to F1 . 2. (w, z) is in Z ∪ I(C2 ) - we add outgoing edge incident z to F2 and (u, z) to F1 . Finally suppose that there are no whole edges inside c, so there are four half-edges. Into Z1 belong half-edges adjacent to outgoing edges in D2 and into Z2 those adjacent to outgoing edges in opp(D2 ). Now we have to consider all possible edges in Z: 1. (u, z) and one other edge is in Z - we act the same as in case with side edge. 2. (u, v) and (v, z) are in Z - if edge incident to z is outgoing we add it to F2 . Otherwise edge incident to v is outgoing and we add it to F2 . In both cases we add (w, z) to F1 . 3. (u, v) and (w, z) are in Z - we add any outgoing edge to F2 and adjacent side edge to F1 . 4. (u, w) and (v, z) are in Z - we add any outgoing edge to F2 and adjacent d-edge to F1 . Now let’s consider the case when c has three incoming and three outgoing edges of C2 incident to it and there is a vertex, say z which is not incident to any incoming or outgoing edge. Then z is incident to two half-edges, on of which is in Z. If in Z there is half-edge (w, z), we add outgoing edge incident to w to F2 and add (u, z) to F1 . If incoming edge incident to w is also in F2 we add (v, w) to F1 , so that property 5 from lemma is satisfied. If in Z there is either (v, z) or (u, z), we add outgoing edge incident to w to F2 and (w, z) to F1 . In all other cases when c has three incoming and three outgoing edges of C2 incident to it, there are at most two half-edges, each incident to different vertex. In these cases we divide half-edges into Z1 and Z2 in such way, that to Z1 belongs half-edge incident to outgoing edge in D2 . Now we have to consider all cases to which vertices incoming and outgoing vertices are incident: 1. Vertices incident to two edges of I(C2 ) \ Ic are incident to the same d-edge, say (u, v) - let’s assume that edge incident to w is outgoing (and therefore either half-edge incident to w is in Z or (w, z) is in I(C2 )). Then we add outgoing edge incident to w to F2 and either add (v, w) to F1 if (w, z) is in I(C2 ) ∪ Z or add (w, z) to F1 otherwise. 2. Vertices incident to two edges of I(C2 ) \ Ic are incident to the same side edge say (u, z) - let’s assume that edge incident to w is outgoing (and therefore either half-edge incident to w is in Z or (v, w) is in I(C2 )). Then if (v, w) is in Z ∪ I(C2 ) we add outgoing edge incident to w to F2 and (w, z) to F1 . If (u, w) is in Z we add outgoing edge incident to u to F2 and (u, v) to F1 . Finally if (w, z) is in Z we add outgoing edge incident to z to F2 and (v, w) to F1 . If incoming edge incident to z is also in F2 we add (u, z) to F1 , so that property 5 from lemma is satisfied 3. None of the above cases - let’s assume that u and w are incident to two edges in I(C2 ) \ Ic and edge incident to z is outgoing (and therefore either half-edge incident to z is in Z or (v, z) is in I(C2 )). Then if (v, z) is in Z ∪ I(C2 ) we add outgoing edge incident to z to F2 and (w, z) to F1 . If (u, z) is in I(C2 ) we add outgoing edge incident to u to F2 and (u, v) to F1 . Finally if (w, z) is in Z there are two subcases: 30 (a) In matching Md cycle incident to vertex u is matched to d-edge (u, v) - then we add outgoing edge incident to u to F2 and (u, v) to F1 (b) Otherwise we add outgoing edge incident to w to F2 . If also incoming edge incident to w is in F2 we add (v, w) to F1 , and if it isn’t in F2 we add (u, v) to F1 . In the case when c is incident to four incoming and four outgoing edges of C2 we add outgoing edge incident to u or v to F2 (depending on which one of cycles incident to these vertices was matched to (u, v) in Md ; if none of them we choose arbitrarily) and add (u, v) to F1 . ✷ 10 Proof of Lemma 5 Let’s now see, that the cycle cover we have found using our gadgets is indeed what had been promised — the maximum weight cycle cover (in which we agree to having paths ending with half-edges) not containing kites from G1 . To prove that we will show, that no such cycle cover of G has been blocked by our gadgets and demands, so for every proper cycle cover of G, it can be translated into a b-matching in the modified graph. Let’s start off with triangles. Lemma 16 Let K ∈ C1 be a 3-kite in the graph G1 . Let C be a cycle cover of G not containing K (as one of the cycles). There exists a selection of edges in the gadget GK corresponding to K, that is compliant with the cycle cover C and every node v in GK has exactly b(v) adjacent edges in it. Its total weight will be equal to the weight of C. Proof. Since the cycle cover C doesn’t contain K as one of its cycles, it will have at least two edges connecting the nodes of this triangle with other vertices in the graph (that are external with regard to K). These edges are replicated in the gadget-modified graph, so there is no doubt, they can be selected into the b-matching. We will now present, how to handle the edges of the triangle K and the gadget GK . We will consider different interactions between C and K. • If K ∩ C = ∅ (no edge of the kite is used in the cycle cover), then the demands of vertices u, v and w are fulfilled by the external edges. Additionally, we select the edges hx1 , x2 i (middle edge on the right side of the gadget), hx5 , x6 i (middle on the left side), hx3 , pi and hx4 , qi. • If K ∩C = {hu, vi} (the cycle cover contains one side of the triangle), the b-matching obviously contains hu, x1 i and hx2 , vi — the halves of the edge hu, vi. We also select the middle edges of two other sides of the triangle, namely hx3 , x4 i and hx5 , x6 i. We satisfy the demands of p and q by connecting them with x1 and x2 respectively. • Finally, if K ∩ C = {hu, vi, hv, wi} (the cycle cover contains two sides of the triangle), we select the corresponding half-edges hu, x1 i, hx2 , vi, hv, x3 i and hx4 , wi. The nodes p and q are connected with x6 and x5 . ✷ In turn, for the 4-kite it will turn out, that our gadgets not only block selecting a length-4 cycle into the b-matching, but also prevent it from containing a length-3 cycle built on three vertices of the 4-kite. 31 Lemma 17 Let K ∈ C1 be a 4-kite in G1 . Let C be a cycle cover of G not containing any length-4 or length-3 cycle built on the vertices of K as one of its cycles. There exists a selection of edges, that is compliant with the cycle cover C, such that every vertex v ∈ GK has exactly b(v) adjacent edges in the selection (so the selection forms a b-matching). The weight of the b-matching is equal to that of C. Proof. Similarly to the proof of Lemma 16, we need to look into all the possible interactions of the cycle cover C with the edges of K (together with its diagonals). For every such option, we will show, how to expand it into a compliant b-matching. The analysis is presented in the Figure 5 ✷ References [1] A.Barvinok, E.Kh.Gimadi, A.I.Serdyukov: The maximun traveling salesman problem. In: The Traveling Salesman Problem and its variations, 585-607, G.Gutin and A.Punnen, eds., Kluwer, 2002 [2] R.Bhatia: private communication [3] Zhi-Zhong Chen, Yuusuke Okamoto, Lusheng Wang: Improved deterministic approximation algorithms for Max TSP. Information Processing Letters, 95, 2005, 333-342 [4] Yi-Jen Chiang: New Approximation Results for the Maximum Scatter TSP. Algorithmica 41(4): 309-341 (2005) [5] M.L.Fisher, G.L.Nemhauser, L.A.Wolsey: An analysis of approximation for finding a maximum weight Hamiltonian circuit. Oper.Res.27 (1979) 799-809 [6] R.Hassin, S.Rubinstein: Better Approximations for Max TSP. Information Processing Letters, 75, 2000, 181-186 [7] R. Hassin, S. Rubinstein: An Approximation Algorithm for the Maximum Traveling Salesman Problem. Inf. Process. Lett. 67(3): 125-130 (1998) [8] R.Hassin, S.Rubinstein: A 7/8-approximation algorithm for metric Max TSP, Information Processing Letters, 81(5): 247-251, 2002 [9] H.Kaplan, M. Lewenstein, N. Shafrir, M. Sviridenko: Approximation Algorithms for Asymmetric TSP by Decomposing Directed Regualar Multigraphs. J.ACM 52(4):602-626 (2005) [10] S.R.Kosaraju, J.K.Park, C.Stein: Long tours and short superstrings. In: Proc. 35th Annual Symposium on Foundations of Computer Science (FOCS),166-177 (1994) [11] A.V.Kostochka, A.I.Serdyukov: Polynomial algorithms with the estimates 43 and 56 for the traveling salesman problem of he maximum (in Russian). Upravlyaemye Sistemy, 26:55-59, 1985 [12] J. Monnot: Approximation algorithms for the maximum Hamiltonian path problem with specified endpoint(s). European Journal of Operational Research 161(3): 721-735 (2005) 32 [13] Katarzyna E. Paluch, Marcin Mucha, and Aleksander Madry. A 7/9 - approximation algorithm for the maximum traveling salesman problem. In Proceedings of the 12th International Workshop on Approximation Algorithms for Combinatorial Optimization, volume 5687 of Lecture Notes in Computer Science, pages 298–311. Springer, 2009. [14] Katarzyna E. Paluch and Khaled M. Elbassioni and Anke van Zuylen. Simpler Approximation of the Maximum Asymmetric Traveling Salesman Problem. In Proceedings of the 29th Symposium on Theoretical Aspects of Computer Science, STACS’2012, Leibniz International Proceedings of Informatics 14, pages 501–506, 2012. [15] Katarzyna Paluch. Better Approximation Algorithms for Maximum Asymmetric Traveling Salesman and Shortest Superstring. CoRR abs/1401.3670 (2014). [16] C.H.Papadimitriou, M.Yannakakis: The traveling salesman problem with distances one and two. Mathematics of Operations Research 18 Issue 1 (1993), pp. 1-11 [17] A.Schrijver: Nonbipartite Matching and Covering. In: Combinatorial Optimization, Volume A, 520-561, Springer 2003 [18] A.I.Serdyukov: An Algorithm with an Estimate for the Traveling Salesman Problem of Maximum (in Russian). Upravlyaemye Sistemy, 25 (1984):80-86 [19] R. Hassin and S. Rubinstein: An approximation algorithm for maximum triangle packing. Discrete Applied Mathematics, 154 (2006), 971–979 [20] Z. Sichen, L. Zhao, Y. Liang, M. Zamani, R. Patro, R. Chowdhury, E. M. Arkin, J. S. B. Mitchell and Steven Skiena: Optimizing Read Reversals for Sequence Compression - (Extended Abstract). Algorithms in Bioinformatics - 15th International Workshop (WABI), 2015 [21] W. Tong, R. Goebel, T. Liu and G. Lin: Approximation Algorithms for the Maximum Multiple RNA Interaction Problem. Combinatorial Optimization and Applications - 7th International Conference, COCOA 2013, pp. 49–59 [22] Z. Chen and L. Wang: An Improved Approximation Algorithm for the Bandpass-2 Problem. Combinatorial Optimization and Applications - 6th International Conference, COCOA 2012, pp. 188–199 [23] A.I. Barvinok, D.S. Johnson, G.J. Woeginger, R. Woodroofe. Finding maximum length tours under polyhedral norms. In Proceedings of IPCO VI, Lecture Notes in Computer Science, Vol. 1412, 1998, pp. 195–201. [24] Alexander I. Barvinok, Sándor P. Fekete, David S. Johnson, Arie Tamir, Gerhard J. Woeginger, Russell Woodroofe. The geometric maximum traveling salesman problem. In J. ACM 50(5): 641-664 (2003) [25] Esther M. Arkin, Yi-Jen Chiang, Joseph S. B. Mitchell, Steven Skiena, Tae-Cheon Yang. On the Maximum Scatter TSP (Extended Abstract). In SODA 1997: 211-220 [26] Prasad Chalasani, Rajeev Motwani. Approximating Capacitated Routing and Delivery Problems. SIAM J. Comput. 28(6): 2133-2149 (1999) 33 (a) No side or diagonal of the square was taken into C (b) C contains one side of the graph. (c) C contains two opposite sides of K (d) C contains two adjacent sides of the cycle K (e) Three sides of the square are taken into C. (f) C contains one diagonal of K. (g) A diagonal and a side edge of K are in C. (h) C contains one diagonal and two opposite side edges of K. (i) Two diagonals of K are taken into C. (j) Two diagonals and a side of K are in C. Figure 5: Proof of the Lemma 17. For every selection of the edges and diagonals of K in the cycle cover C we are showing, how to select edges of the gadget GK , to realize the cycle cover in the gadgets-modified graph. 34
8cs.DS
Data Readiness Levels arXiv:1705.02245v1 [cs.DB] 5 May 2017 Neil D. Lawrence Amazon Research Cambridge and University of Sheffield 6th April 2017 Abstract Application of models to data is fraught. Data-generating collaborators often only have a very basic understanding of the complications of collating, processing and curating data. Challenges include: poor data collection practices, missing values, inconvenient storage mechanisms, intellectual property, security and privacy. All these aspects obstruct the sharing and interconnection of data, and the eventual interpretation of data through machine learning or other approaches. In project reporting, a major challenge is in encapsulating these problems and enabling goals to be built around the processing of data. Project overruns can occur due to failure to account for the amount of time required to curate and collate. But to understand these failures we need to have a common language for assessing the readiness of a particular data set. This position paper proposes the use of data readiness levels: it gives a rough outline of three stages of data preparedness and speculates on how formalisation of these levels into a common language for data readiness could facilitate project management. 1 Introduction The universal formula of machine learning is data + model → prediction with a high quality of prediction being dependent on both good models and high quality data. Much of the focus on machine learning in the academic world of machine learning is on the quality of the model. This focus arises because data is normally from benchmarks or publicly available data sets, so performance in a task is improved by exercising control over model. The greater interconnectedness of modern society and apparent ease with which we digitise or record data places us in a particular position. We need to develop a lot more control over the quality of our data. Whether it be in the manner in which we choose to collect, or how we choose to annotate. Currently the academic or empirical study of modeling (e.g. support vector machines, neural networks, Gaussian processes) is prominent in the education of the graduates we produce, but approaches for understanding the quality of data are less widely used. 2 Data Readiness Levels In this position paper we introduce the idea of data readiness levels. Data readiness levels are designed to deal with a challenge for human cognitive information processing. It’s difficult for us to reason about concepts when we haven’t developed a language to describe them. The idea of data readiness levels is to correct this issue and make it easier for us to reason about the state of our data. The challenges of data quality arise before modeling even starts. Both questions and data are badly characterized. This is particularly true in the era of Big Data, where one gains the impression that the depth of data-discussion in many decision making forums is of the form “We have a Big Data problem, do you have 1 a Big Data solution?”, “Yes, I have a Big Data solution.” Of course in practice it also turns out to be a solution that requires Big Money to pay for because no one bothered to scope the nature of the problem, the data, or the solution. Data scientists and statisticians are often treated like magicians who are expected to wave a model across a disparate and carelessly collated set of data and with a cry of ‘sortitouticus’ a magical conclusion is drawn. It is apt to think of it as ocean of data, to paraphrase “water, water everywhere and not a drop to drink”, we have “data, data everywhere and not a set to process”. Just as extracting drinkable water from the real ocean requires the expensive process of desalination, extracting usable data from the data-ocean requires a significant amount of processing. For any data analyst, when embarking on a project, a particular challenge is assessing the quality of the available data, how much processing is required? This difficulty can be compounded when project partners do not themselves have a deep understanding of the process of data analysis. If partners are not data-savvy they may not understand just how much good practice needs to be placed in the curation of data to ensure that conclusions are robust and representative. Just as water quality should be measured before consumption, so should data quality. When scoping a project, in most proposal documents, very scant attention is paid to these obstacles, meaning in practice the process of improving data quality is under appreciated and under resourced. One difficulty is that the concept of “data”, for many people, is somehow abstract and diffuse. This seems to mean that it is challenging for us to reason about. Psychologists refer to the idea of vivid information as information that is weighted more heavily in reasoning than non-vivid or pallid information. In this sense data seems to be rendered vivid to be properly accounted for in planning. This may relate to availability heuristics[1]. This abstract nature is also true of other terms, for example for many people the idea of “technology” is also similarly diffuse, it is pallid information (although I’ve never heard anyone remark “we have a big technology problem, we need a big technology solution”). Perhaps to deal with this challenge, in large scale projects, when deploying technology, we are nowadays guided to consider its readiness stage. Technology readiness levels arose in NASA [2]. The readiness of the technology is made manifest through a set of numbers which describe its characteristics:1 is it lab tested only? Is it ready for commercialization? Is it merely conceptual? No doubt there are pros and cons of such readiness levels, but one of the pros is that the manifestation of the technological readiness pipeline ensures that some thought is given to that process. The technology is rendered more vivid even through a shared characterization. It would therefore seem very useful to have a scale to make data readiness manifest. This idea would allow analysts to encourage better consideration of the data collection/production and consolidation, with a set of simple questions, “And what will the data readiness level be at that point?”. Or “How will that have progressed the data readiness?”. Or to make statements, “we’ll be unable to deliver on that integration unless the data readiness level is at least B3..”2 This paper aims to trigger a discussion in statistics and data science communities by proposing an initial set of descriptors for data readiness. The initial proposal is that data readiness should be split into three bands. Each band being represented by a letter, A, B and C. These bands reflect stages of data readiness which would each likely have some sub-levels, so the best data would be A1 and the worst data might be C4. The aim here is to avoid being fine-grained too early. We therefore begin the discussion by focussing on three bands of data readiness. 1 See appendix for examples of technology readiness level descriptions. nanotechnology community has also looked at data readiness levels in this discussion document from the nanotechnology community in 2013. However, their scope doesn’t seem to be general enough to deal with the challenges of data processing in domains beyond nanotechnology. 2 The 2 2.1 Band C Band C is about the accessibility of a data set. The lowest sub-level of Band C (let’s label it as C4) would represent a belief that the data may exist, but its existence isn’t even verified. Signs that data is C4 might include statements like “The sales department should have a record of that.” Or “The data should be available because we stipulated it in the software requirements.” We might think of it as hearsay data. Data that you’ve heard about so you say it’s there. Problems with hearsay data might include • whether it really is being recorded • the format in which it’s being recorded (e.g. handwritten log book, stored in PDF format or old machine formats) • privacy or legal constraints on the accessibility of the recorded data, have ethical constraints been alleviated? • limitations on access due to topology (e.g. the data’s distributed across a number of devices) So when we are first told a data set exists, when we have hearsay data, then it is at band C4. For data to arrive at C1, then it would have all these considerations dealt with. When data arrives at C1 it’s ready to be loaded into analysis software, or it can be made available for others to access (e.g. via a data repository such as OpenML [3]). It is machine readable and ethical procedures for data handling have been addressed. Bringing data to C1 is often a significant effort itself involving many lines of bespoke software and human understanding of systems, ethics and the law. Some parts of Band C are sometimes referred to as “data munging” or “data wrangling”, but those aren’t the only components of this band, there are additional challenges such as ethical and legal that need to be resolved. 2.2 Band B Band B is about the faithfulness and representation of the data. Now that it’s loaded into the software, is what is recorded matching what is purported to be recorded? How are missing values handled, what is their encoding? What is the noise characterization (for sensors) or for manual data are there data entry errors? Are any scientific units correctly formulated? Tukey’s approach of “Exploratory Data Analysis” also fits within Band B. Visualizations of the data should be carried out to help render the data vivid and to ensure decision makers, who may not be data aware, can become involved in the analysis process. Decision makers (e.g. project managers, or the client) should also begin to get a sense of the limitations of their data set through appropriate visualisation. As part of Band B the characteristics of the collection process should also be verified, was data collection randomized, is it biased in any particular way? Other things to watch for at this stage include: 1. If the data has been agglomerated at some point (for example, for privacy) how were missing values dealt with before agglomeration? If they weren’t dealt with then that entire section of the data may be invalidated 2. If the data has been through a spreadsheet software, can you confirm that no common spreadsheet analysis errors were made? For example, was a column or columns accidentally perturbed (e.g. through a sort operation that missed one or more columns)? Or was a gene name accidentally converted to a date? By the end of Band B, when data is B1, a broad idea of limitations in the data should be present in the expert’s mind. Data at C4 was hearsay data, someone heard the data existed and they said what they thought it might be good for. At B1 the analyst knows how faithful the data is to that description. This 3 is the significant challenge for a data scientist. What people believe they have in their data versus what’s actually there. Only at the end of Stage B would the analyst begin to have an intuition about what my really be possible with the data set. Getting to this point is often the most expensive part of the project, but we do not yet have good methods to guage progress, or share the status of a particular data set. 2.3 Band A Band A is about data in context. It is at Band A that we consider the appropriateness of a given data set to answer a particular question or to be subject to a particular analysis. The context must be defined. For example OpenML [3] defines tasks associated with data sets. A data set can only be considered in Band A once a task is defined. A task could be “Use the data to predict a user preference” or “Use this data to prove the efficacy of a drug” or “Use this data verify the functioning of our rocket engine”. Once data has been considered alongside a task and any remedial steps have been taken, then the data is in A1 condition. It is ready to be deployed in the context given and it can be used to make predictions with the data. Because A1 is about data in context, it is possible for a data set to be A1 for one question (e.g. predicting customer churn) but only B1 for a different question (e.g. predicting customer susceptability to a particular special offer). So the definition of the context or task is an important pre-requisite for this band. To bring a data set up to A1, there may be a need for significant annotation of the data by human expert. There may be a realisation that new data needs to be actively collected to get the answers required. In that sense, Band A has some characteristics of a classical statistical analysis where the question would normally preceed the data collection. It is in Band A where you should be carefully thinking about the statistical design because it is only when you have the question you wish to answer that you can really unpick how your data may be biased or what information is missing. 3 The Analysis Pipeline A common mistake in data analysis is to not acknowledge the different processes above. They have different pre-requisites and require different skill sets to carry out. However, this path cannot be completely disconnected. Anyone performing an analysis at Band A also needs to be intimately familiar with the collection process so that any biases in data collection can be understood. Sharing information about decisions taken at Bands B and C will also be critical to achieving a good result. What happens if we bring two data sets together to form a new data set? Some assesment of data readiness would still need to be performed on the new data set, even if the two other data sets had already been assessed. Why? Well, one example is that there may be ethical issues with combining data sets. For example, medical data can be easily deanonymized if it is combined with other related data sets. That would mean that some assesment would need to be made at Band C to see if it is ethically responsible to combine the two data sets in the same analysis package. Futher assesments would also need to be done at Band B to understand differences in collection protocols that might make the two data sets hard to combine. 3.1 Potential Results The idea of these levels is to increase the accountability of the process and allow the nature of the data to be manifest. With data readiness levels in place you can now imagine conversations that would include statements like the following: Be careful, that department claims to have made 10,000 data sets available, but we estimate that only 25% of those data sets are available at C1 readiness. 4 The cost of bringing the data to C1 would be prohibitive for this study alone, but the companywide data audit is targeting this data to be C1 by Q3 2017 which means we can go ahead and recruit the statisticians we need. The project failed because we over recruited statistical expertise and then deployed them on bringing the data set to C1 readiness, a job that would have been better done by building up our software engineering resource. What’s the data readiness level? My team will be ineffectual until it’s B1 and at the moment I see no provision in the plan for resource to bring it there. We estimate that it’s a $100,000 dollar cost to bring that data to B1, but we can amortize that cost across four further studies that also need this data. I gave them the data readiness levels to go through and they realized they hadn’t yet got the necessary ethics approval for sharing the zip codes. We’ll revisit when they’ve got through that and can assure us they can share a C1 set. While their knowledge of the latest methodologies wasn’t as good as I’d hoped, the candidate had a lot of experience of bringing data from C1 to B1, and that’s a skill set that we’re in dire need of. The project came in under budget because they found a team with experience of getting a closely related data set to A1. Many of the associated challenges were the same and they could even reuse some of that team’s statistical models. 4 Case Studies How useful would data readiness levels be? That’s difficult to give a quantitative answer to, large scale analysis of the scale of this problem requires meta data science, i.e. the study of data science itself through acquiring data about data science. That would be a very worthwhile endeavour. In the absence of quantitative information, we provide two anecdotal case studies below. The first is on the cahllenge of extracting data from a popular machine learning conference proceedings. 4.1 Proceedings of Machine Learning Research The Proceedings of Machine Learning Research3 (PMLR) were begun in 2006 (as JMLR Workshop and Conference Proceedings) to provide a convenient way to publish machine learning conference proceedings without the overhead of a conventional publisher. There are now 69 volumes of proceedings published and planned. They contain over 3,198 papers. The original website was manually curated to mimic the JMLR website, but since Volume 26 an automated proceedings production process which relies on editors providing a zip file of PDFs and a bibtex bibliography reference file (referred to below as ‘bib files’) specifying author names, abstracts and titles has been used. In early 2017, as part of a rebranding process, the original website was moved to github and a new process for receiving proceedings and publishing was set up. For the rebranding the old web-sites needed to be scraped, converted to bib files. A key aim in the rebanding was to make abstracts and titles easily available for analysis with an initial target language of Python. This entire process can be seen as taking the data readiness of website data from C4 to C1. In other words, get to the point where the data could be loaded into an analysis software, our target here was to load it into the pandas framework within Python. 3 http://proceedings.mlr.press 5 The original plan was to complete the work in some idle hours at the weekend. The actual work took much longer than projected. The major github commits of code along with a description of the effort involved are listed below. 1. An initial two day effort to create bibliography files for the first 26 volumes which were published before the publication process was first automated. Github commit: https://github.com/mlresearch/papersite/commit/daa51a 2. A three day effort to convert the proceedings to a new format website. Much of this work was on the website presentation, but part was on data curation. Github commit: https://github.com/mlresearch/papersite/commit/81d 3. A three evening effort to tidy the resulting data so it could load into Python pandas via web download. Github commit: https://github.com/mlresearch/papersite/commit/81d7a0556948281d11d8f0652ecdca61005c4318 The result is now available via github as a short jupyter notebook: https://github.com/sods/ods/blob/master/notebooks/pods Data loading is now possible with a single library call. import pods data = pods.datasets.pmlr() where the pods library is available from https://github.com/sods/ods/. This data has therefore successfully transferred from the start of C (e.g. C4, “Hearsay data”) to the end of C (e.g. C1, data loaded into analysis software). The data set only contains 3,198 data points, it was all available in electronic form. There were no issues around privacy or intellectual property but work still took approximately six working days. Much of that work was laborious, but it still involved well qualified understanding of computer software, e.g. regular expressions, scripting languages, libraries for downloading from the internet, github etc.. Alongside that work a new format web page was also provided (http://proceedings.mlr.press). Indeed that could be argued as a consequence of the data tidy up. Naturally the hope is that future volumes will be more cleanly added to this data set. 4.2 Data Wrangling Snafus Some snafus that occurred in the data wrangling of the Proceedings of Machine Learning Research. Each bibliography file is provided by the editors of the relevant volume. Because they each used different approaches to generate the bib files, there were different issues with each bib file. • Many of these bib files will have been produced from conference management software (e.g. CMT or Easychair). That means the original information source is often likely to be author provided. Many authors seemed to paste their abstracts from the PDFs of their papers into this software. This meant that abstracts contained ligatures. A ligature is a single typeset unit such as ‘fi’, which comes about when the previous letter runs into the second, the German ‘Sz’, ß, is an example of a ligature that in the end became a letter. Unfortunately the ligatures did not paste as unicode, but as escaped characters which the python yaml library was unable to read when presented as data. • Papers are mostly written in Latex, so many of the abstracts contain Latex commands. But these commands in the abstracts or title are intepreted as escaped characters in yaml files. Additional ‘escaping’ was needed for these commands. • Author names containing accents were oftentimes corrupted, perhaps due to differences in representation in the original files. Each of the snafus above can be resolved by robust coding, but there is normally a trade off between producing the data (just getting it done quick) and producing the most robust code (ensuring the result is high quality and reusable). The right operating point for the trade off is driven by the scale of the data set. It also requires experience to judge and is dependent on the coding skills of the data engineer. 6 This is the work at the pit face of data mining, it’s difficult to estimate the time it will take, and yet it is normally a critical dependency in any machine learning project. For each of these snafus, better planning at early stage analysis could have saved time in manual correction of the data later. But doing such planning well requires experience and an understanding of best practice. We are not associating enough value with this experience, and therefore we continue to be tripped by snafus when preparing data. 4.2.1 How Data Readiness Levels could have helped This is one of the first projects I undertook after conceiving of data readiness levels, but in reflection I think I still did not take enough of the ideas seriously enough. Because I underestimated the time to be spent on manual curation after the initial scrape of the data, I did not put enough effort into robust code for dealing with ligatures and other unusual character codes. There were several moments where, in retrospect, I should have refactored my processing code. But since I was driven by the desire to complete the project, particularly given I’d severely underestimated how long it would take, I chose to push forward. One interesting question is how ideas from software engineering, such as agile development philosophies, could have helped in making myself more aware of these errors. 4.3 Disease Monitoring in Uganda The second case study refers to work in collaboration with the University of Makerere and UN Global Pulse in Kampala, Uganda in the prediction of disease outbreak [4]. Specifically, our original interest was understanding the spatial correlations of malarial disease in Uganda, and their interactions with other measures such as NDVI, rainfall, altitude etc. Our effort was a countrywide effort, but simultaneous to our work was an international effort in the Malaria Atlas Project.4 We constructed spatial models based on Gaussian processes that were designed to detect and use the correlations between the different covariates. The work was done through two PhD students’ thesis, Martin from Kampala, and Ricardo from the UK. The work in Kampala mainly drove the data collection and collation. In particular, interpretation of satellite images as NDVI, alignment of the rainfall and altitude maps. The data collation in itself took probably around 70-80% of the work on the project. Martin working on it full time, and Ricardo assisting and working on both modeling and data munging. Ricardo visited Uganda twice, initially for a scoping visit and later for a longer collaboration visit in the processing of the data during his PhD. These visits were to the University of Makerere where Martin was working. The malaria incidence data was drawn from Health Management Information System (HMIS) data. For privacy purposes, original data was not available to us, but rather it had been aggregated across certain regions. One key challenge in the data munching is that the administrative areas (in Uganda known as districts) change. One administrative area can divide into two. When this happens the history of the two districts needs to be divided across the two areas. This presented a missing data problem that Ricardo also spent a deal of time addressing during his thesis. By the time of submission of the thesis, Ricardo had recovered a negative result, he couldn’t show spatial correlation among the districts. This was disappointing as it had been one of the main motivations of that thesis work. Nevertheless, even without the spatial correlation there was interest in deploying the system by the Ugandan ministry of health for disease outbreak prediction. Ricardo’s expertise was such that he was able to then spend 3 months in Africa, this time at UN Global Pulse, where Martin and his supervisor were now working, rather than Makerere. This was to help with the implementation of early warning systems based on the model. These early warning systems did not require the spatial correlation that hadn’t worked during the thesis. 4 http://www.map.ox.ac.uk/ 7 During the period at the UN, Ricardo and Martin were able to work directly with disaggregated data. The UN had permission to see the raw health center results, whereas the University of Makerere did not. As a result, they found that aggregation we had previously been working on had been performed across data containing missing values. Ricardo and Martin reworked the model to deal with missing values and recovered the expected spatial correlation. In other words, due to a data processing error at Band B, a negative result was obtained at Band A. A lack of documentation, or a lack of asking the right questions, led to an oversight on this error. The models are now deployed for disease outbreak prediction across Uganda, where they are combined with knowledge of population movement from mobile phone data to trigger interventions. The lessons learned were the following. 1. In data where we had direct access the amount of work required to align, and the number of design decisions we made in the summarization dominated the project. 2. There was still data that fell out of our control due to confidentiality reasons. Despite the work we’d done on our own data, which would have allowed us to infer that other design decisions would have been made by those that were aggregating the data, we failed to ask the right questions of the data providers. Indeed, those data providers may not have even known the answers. There was no substitute for directly looking at the data. 3. Although we began the project with one set of goals in mind: understanding the correlation between different factors in malaria, our outcome: disease prediction for early intervention, was quite different. Happenstance outcomes need to be accommodated in project goals. They arise particularly around Band B of the process. 4.3.1 How Data Readiness Levels could have helped Being aware of data readiness levels would have done three things. Firstly, we would have estimated better how much time that Martin would require in data munging from satellite images etc. Secondly, we would have questioned the process by which the HMIS data was being presented to us, and what stage of readiness it was at, and how it got there. These are broadly questions that sit in Band C and B. Thirdly, awareness of the transition from Band B to Band A (data moving to its context) would have made us realize that the question may well evolve and be more responsive to that outcome. In the end this move was driven by the shift in collaboration from Makerere to the UN. Ricardo has continued to work in this area, and one focus of his new UCSF Global Health research group has been to clean up existing data and make it available as geospatial layers for other groups to use. 5 Conclusion Machine learning researchers probably didn’t enter the field to do project management, but it may be that many failings on large data projects are associated with a failure to provision resource for the challenges involved in preparing our data, rather than a failing in the algorithmics of the system. Costs of data curation are often underestimated and those who do the work in Band C and Band B are very often undervalued. Data readiness levels highlight the different skill sets required in each stage of analysis, from software engineer, to data-munger, to data scientist to machine learning scientist. Some consensus about such levels would help organizations (and their managers, financial controllers) quantify the value associated with data and allocate resource correctly to developing data sets that are robust and representative. A well conducted data analysis will lead to a good customer experience, but by the same token badly waste resources and give a poor customer experience. 8 This paper has outlined the basis for a partial solution to these problem, but to deploy in practice we would need consensus around data readiness levels and how they should be deployed. The emerging field of data science is the ideal domain to explore the utility of these ideas, evolve their specification and begin to properly account for the value of well curated data. For convenient reference below we show examples of technology readiness levels from the Department of Defense (sourced from Wikipedia. For Data Readiness we are proposing to start with the three bands described above. Technology readiness relies entirely on a numbered system. [1] T. Gilovich, D. Griffin, and D. Kahneman, Eds., Heuristics and biases: The psychology of intuitive judgment. Cambridge University Press, 2002. [2] J. Banke, “Technology readiness levels demystified,” NASA, 2010. [3] J. Vanschoren, J. N. Rijn, and B. Bischl, “Taking machine learning research online with OpenML,” in Proceedings of the 4th international workshop on big data, streams and heterogeneous source mining: Algorithms, systems, programming models and applications, 2015, vol. 41, pp. 1–4. [4] R. Andrade-Pacheco, M. Mubangizi, J. Quinn, and N. Lawrence, “Monitoring short term changes of infectious diseases in uganda with gaussian processes,” in Advanced analysis and learning on temporal data: First ecml pkdd workshop, aaltd 2015, porto, portugal, september 11, 2015, revised selected papers, A. DouzalChouakria, J. A. Vilar, and P.-F. Marteau, Eds. Cham: Springer International Publishing, 2016, pp. 95–110. A Exemplar Technology Readiness Levels 1. Basic principles observed and reported Lowest level of technology readiness. Scientific research begins to be translated into applied research and development (R&D). Examples might include paper studies of a technology’s basic properties. 2. Technology concept and/or application formulated Invention begins. Once basic principles are observed, practical applications can be invented. Applications are speculative, and there may be no proof or detailed analysis to support the assumptions. Examples are limited to analytic studies. 3. Analytical and experimental critical function and/or characteristic proof of concept Active R&D is initiated. This includes analytical studies and laboratory studies to physically validate the analytical predictions of separate elements of the technology. Examples include components that are not yet integrated or representative. 4. Component and/or breadboard validation in laboratory environment Basic technological components are integrated to establish that they will work together. This is relatively “low fidelity” compared with the eventual system. Examples include integration of “ad hoc” hardware in the laboratory. 5. Component and/or breadboard validation in relevant environment Fidelity of breadboard technology increases significantly. The basic technological components are integrated with reasonably realistic supporting elements so they can be tested in a simulated environment. Examples include “high-fidelity” laboratory integration of components. 6. System/subsystem model or prototype demonstration in a relevant environment Representative model or prototype system, which is well beyond that of TRL 5, is tested in a relevant environment. Represents a major step up in a technology’s demonstrated readiness. Examples include testing a prototype in a high-fidelity laboratory environment or in a simulated operational environment. 9 7. System prototype demonstration in an operational environment. Prototype near or at planned operational system. Represents a major step up from TRL 6 by requiring demonstration of an actual system prototype in an operational environment (e.g., in an aircraft, in a vehicle, or in space). 8. Actual system completed and qualified through test and demonstration. Technology has been proven to work in its final form and under expected conditions. In almost all cases, this TRL represents the end of true system development. Examples include developmental test and evaluation (DT&E) of the system in its intended weapon system to determine if it meets design specifications. 9. Actual system proven through successful mission operations. Actual application of the technology in its final form and under mission conditions, such as those encountered in operational test and evaluation (OT&E). Examples include using the system under operational mission conditions. 10
2cs.AI
Making Asynchronous Distributed Computations Robust to Noise arXiv:1702.07403v1 [cs.DS] 23 Feb 2017 Keren Censor-Hillel∗ Ran Gelles† Bernhard Haeupler‡ Abstract We consider the problem of making distributed computations robust to noise, in particular to worst-case (adversarial) corruptions of messages. We give a general distributed interactive coding scheme which simulates any asynchronous distributed protocol while tolerating an optimal corruption of a Θ(1/n) fraction of all messages while incurring a moderate blowup of O(n log2 n) in the communication complexity. Our result is the first fully distributed interactive coding scheme in which the topology of the communication network is not known in advance. Prior work required either a coordinating node to be connected to all other nodes in the network or assumed a synchronous network in which all nodes already know the complete topology of the network. ∗ Technion, Department of Computer Science, [email protected]. Supported in part by the Israel Science Foundation (grant 1696/14) and the Binational Science Foundation (grant 2015803). † Faculty of Engineering, Bar-Ilan University, [email protected]. ‡ Carnegie Mellon University, [email protected]. Supported in part by NSF grants CCF-1527110 and CCF1618280. 1 Introduction Fault tolerance is one of the central challenges in the design of distributed algorithms. Typically, computation is performed by n nodes, of which some subset may be faulty and not behave as expected. This includes crash or Byzantine failures. Faults can also occur as communication errors, if links suffer from, e.g., omissions, alterations or Byzantine errors (see, e.g., [Lyn96, AW04]). We focus on alteration errors, in which the content of sent messages may be corrupted. Previous work in the setting of faulty channels provides fault-tolerant algorithms for several specific tasks, such as the leader election or the consensus problem (e.g., [SAA95, Sin96, GLR95, SCY98]). In this paper, we provide a general technique that takes an asynchronous distributed protocol as an input and outputs a simulation of this protocol that is resilient to noise. Specifically, we develop several tools whose combination allows us to obtain the first fully distributed interactive coding scheme. The Challenge. Once communication is unreliable, even the simplest distributed tasks, such as flooding information over the network or constructing a BFS tree, become tremendously difficult to execute correctly. For instance, the asynchronous distributed Dijkstra or Bellman-Ford algorithms [Pel00] miserably fail when messages may be corrupted. To see why, recall that in the Bellman-Ford algorithm, each node sends to all of its neighbors its distance from the root. A node then sets its neighbor that is closest to the root as its parent. However, if messages are incorrect, the distance mechanism may fail and nodes may set their parents in an arbitrary way. Our Contribution. In any attempt to tolerate message corruptions, naturally, some bound on the noise must be given. Indeed, if a majority of the sent messages are corrupted, there is no hope to complete a computation correctly. On the other hand, when the noise falls below a certain threshold, fault tolerant computation can be obtained, for example, by employing various coding techniques. The field of coding for interactive communication (see, e.g., the survey of [Gel15]) considers the case where two or more parties carry some computation by sending messages to one another over noisy channels and strives to devise coding schemes with good guarantees. A coding scheme is a method that is given as an input a protocol π that assumes reliable channels, and outputs a noiseresilient protocol Π that simulates π. The two main measures upon which a coding scheme is evaluated are its noise resilience—the fraction of noise that the resilient simulation Π can withstand— and its overhead—the amount of redundancy Π adds in order to tolerate faults. For networks with n nodes, it is easy to show that the maximal noise fraction that any resilient protocol can cope with is Θ(1/n) [JKL15]. Indeed, if more than (1/n)-fraction of the messages are corrupted, then the noise can completely corrupt all the communication of the node that sends the least number of messages. The overhead depends on the network topology, communication model, and noise resilience, as we elaborate upon in Section 1.2. Our main result, informally stated as follows, is a deterministic coding scheme that fortifies any asynchronous protocol designed for a noise-free setting over any network topology, such that its resilient simulation withstands the maximal Θ(1/n)-fraction of noise. Theorem 1.1. There exists a deterministic coding scheme that takes as an input any asynchronous distributed protocol π designed for reliable channels, and outputs an asynchronous distributed protocol Π that simulates π, is resilient to a fraction Θ(1/n) of adversarially corrupted messages, and has a multiplicative communication overhead of O(n log2 n). 1 1.1 Techniques A Content-Oblivious BFS Construction. A key ingredient in our coding scheme is a BFS construction which is content oblivious. That is, in our BFS construction, the nodes send messages to each other and ignore their content, basing their decisions only on the order of received messages. The challenge is to be able to do this despite asynchrony and despite lack of FIFO assumptions. In a sense, our construction can be seen as a variant of the distributed Dijkstra algorithm, with the property that the nodes send “empty messages” that contain no information (alternatively, the nodes ignore the content of received messages). Recall that the distributed Dijkstra algorithm, see, e.g., [Pel00, Chapter 5], is initiated by some node r, which governs the BFS construction layer by layer, where the construction of each layer is called a phase. The invariant is that after the p-th phase, the algorithm has constructed a BFS tree Tp of depth p rooted at r, where all nodes in Tp know their parent and children in Tp . The base case is T0 = {r}, and the construction of the first layer is as follows. The node r sends an Explore message to all its neighbors, who in turn set r as their parent. Each Explore message is replied to with an Ack message. Once r receives Ack messages from all of its neighbors, the first phase ends and the construction of the second layer begins. Note that T1 indeed holds r and all of its neighbors. For the p-th phase, the root floods a message Phase through Tp−1 . Once a leaf in Tp−1 receives a Phase message, it sends Explore to all of its neighbors, who in turn set their parent unless already in Tp−1 . Each node that receives an Explore replies with an Ack and an indication of its parent node, so that the exploring node learns which of its neighbors is a child and which is a sibling. Upon receiving an Ack from all of its neighbors, the node sends an Ack to its parent, which propagates it all the way to r. Once r has received Ack messages from all of its children, the phase is complete. Our content-oblivious BFS construction imitates the above behavior while using only a “single” type of message, instead of Phase, Explore and Ack messages. Specifically, the construction begins with r sending a message (Explore1 ) to all of its neighbors, who in turn set r as their parent and reply with a message (Ack). When r receives a message from all of its neighbors, the first phase is complete. Then, r begins the second phase by sending another message (Explore/Phase) to all of its neighbors. This message causes a node that has already set its parent to behave like r—it sends a message to all of its neighbors (Explore) except for its parent. After receiving a message (Ack) from all of its neighbors, it sends a message (Ack) to its parent. One can easily verify that this approach behaves similarly to the Dijkstra algorithm described above, in the sense that every node sets its parent correctly. The only difference is when a node u sends an (Explore) message to its sibling w. In the Dijkstra algorithm the sibling w replies by telling the exploring node u that they are siblings (by indicating the parent of w, which is not u). However, in our case messages contain no content and u is unable to distinguish whether w is a child or a sibling, since in both cases w should reply to the Explore message in the same way. Our insight is that serializing each phase provides a solution to the above ambiguity. That is, we let r send a message (Explore/Phase) to one child at a time, waiting to receive a message (Ack) from that child before sending a message (Explore/Phase) to the next child. This gives that if a node is expecting a message (Explore) from its parent but instead it receives a message (Explore) from a non-parent neighbor, then it knows that this neighbor must be a sibling. Hence, the node can mark all siblings and distinguish them from its children. 1 To ease the readability, we write in parenthesis the functionality of each sent message, but we emphasize that messages in our construction contain no content at all, and the labels of Explore and Ack are given only for the analysis. 2 The main advantage of not basing our construction on the content of received messages is that the obtained BFS construction is inherently tolerant against message corruptions: the noise has no effect on the construction since the content of the communicated messages is already being ignored. Notice that in our construction, the nodes do not learn their distance from r, in contrast to what can easily be obtained in the noise-free case. However, this will suffice for our usage of the BFS tree in our coding scheme. Interactive Coding over Sparse Subgraphs. A crucial framework we rely on in our simulation is a multiparty coding scheme for interactive communication by Hoza and Schulman [HS16], which is in turn based on ideas from [RS94]. This coding scheme allows simulating protocols over any graph G = (V, E) and withstands an Θ(1/|E|)-fraction of adversarial message corruption, while incurring a constant communication overhead. The caveat of using this scheme for our simulation is that it applies only for synchronous protocols that communicate over G in a manner which we call fully-utilized synchronous: in each round, every node communicates one symbol over to each of its neighbors. In order to obtain our coding scheme for asynchronous protocol with resilience Θ(1/n), we first convert the asynchronous input protocol π into a fully-utilized synchronous protocol defined over some subgraph G′ = (V, E ′ ) of G with |E ′ | = Θ(n). To this end, we use the BFS tree constructed by our content-oblivious method described above. Once we obtain a BFS tree T , we simulate each message communicated by π via n fully-utilized synchronous rounds over the tree T . During each of such n rounds, a message of π is flooded throughout T until it reaches all the nodes and, in particular, its destination node. Note that in every round, all nodes send messages over all the edges of T . This implies a communication overhead of O(n2 log n): we have at most n rounds with Θ(n) messages per round. The log n term stems from adding the identity of the source node and the destination node to each flooded message.2 Using the Hoza and Schulman [HS16] coding scheme taking as an input the fully-utilized synchronous protocol defined over the topology T gives a resilient simulation of π which withstands a maximal Θ(1/n)-fraction of corrupted messages. Alas, it is a synchronous simulation, while our environment is asynchronous. Hence, to complete our simulation, we need to use a synchronizer [Awe85]. A Root-Triggered Synchronizer. In the original error-free setting, if the input protocol to a synchronizer is guaranteed to be fully-utilized then synchronization is trivial. Each node simply attaches a round number to each of its outgoing messages and produces the outgoing messages for round i + 1 only after receiving messages for round i from all of its neighbors. The key difficulty is then for non-fully utilized synchronous input algorithms, in which a node cannot simply wait to receive a message for round i from all of its neighbors, as it may be the case that some of these do not exist. In our setting, we guarantee that we produce a fully-utilized synchronous algorithm as an input to our synchronizer. However, we do not assume FIFO channels, which means that we cannot rely on the naive synchronizer, despite the promise of a fully-utilized synchronous protocol for an input. Thus, we need a different solution for synchronizing the messages, and our approach is based on having a single node responsible for triggering messages of each round only after the previous round 2 Throughout this work, all logarithms are taken to base 2. 3 has been simulated by all nodes. To this end, our synchronizer bears similarity to the classic treebased synchronizer of Awerbuch [Awe85], with the difference that it does not incur any message overhead because it is given a fully-utilized synchronous input. A Spanner-Based Coding Scheme. We show that our coding technique described above can be further improved. Routing each message over a tree T requires n rounds in the worst case for a message to reach its destination. A more efficient solution would be to route each message through a spanning subgraph S = (V, ES ) of G in which the distance over S of every (u, v) ∈ E is not too large. On the other hand, the Hoza-Schulman coding scheme on S has a noise resilience of Θ(1/|ES |), and hence we require |ES | to be O(n) in order to maintain a maximal resilience level of Θ(1/n). Luckily, for every G there exist sparse spanning subgraphs in which |ES | = O(n) while every two neighbors in G are at distance at most O(log n) in S; such subgraphs are known as O(log n)-spanners [Pel00, PS89]. Flooding a message of π from u to v can be done within O(log n) rounds, in each of which O(|ES |) = O(n) messages are sent by a fully-utilized synchronous simulation of π, leading to our claimed communication overhead of O(n log2 n). Here again, the extra log n term stems from adding identifiers to each flooded message. However, flooding information over a spanner introduces several other difficulties. For instance, in contrast to the case of a tree, it is not guaranteed anymore that each message arrives only once to its destination—indeed, multiple paths may exist between any two nodes. Furthermore, when multiple nodes send messages, the congestion may cause super-polynomial delays if a simple flooding algorithm is used. Then, due to having multiple paths with arbitrary delays, messages may arrive to their destination out of order. Since the delay is super-polynomial in the worst case, adding a counter to each message will increase the overhead by ω(log n) and damage the global overhead. Instead, we provide a contention-resolution flavored technique, which consists of priority-based windows for delivering the messages. In more detail, a message flooding starts only at the beginning of an O(log n)-round window. Multiple messages that are sent during the same window may be dropped during their flooding, yet the source always learns when its message is dropped, so it can retransmit the message in the next window. A similar approach is well-known for constructing a BFS tree when no specific root is given, but our extension of this technique is more involved, since dropped messages must be resent. It remains to explain how to construct the O(log n)-spanner over the noisy network to begin with. For this, we use our previously described tree-based coding scheme to simulate a distributed spanner construction, e.g., the (noiseless) construction of Derbel, Mosbah, and Zemmari [DMZ10]. While coding this part incurs a large overhead of O(n2 log n), this overhead applies only to the part of constructing the spanner, and the global overhead of our coding scheme is still dominated by the overhead of coding the input protocol over the spanner. 1.2 Related Work Performing computations over noisy channels is the heart of coding for interactive communication, initiated by Schulman [Sch92, Sch96]. A long line of work considers the 2-party case and obtains various coding schemes, as well as bounds on their capabilities in various settings and noise models [BR14, BE14, BKN14, GHS14, FGOS15, EGH16, KR13, Hae14, BGMO16, GHK+ 16]. See [Gel15] for a survey on interactive coding. 4 Interactive coding in the multiparty setting was first considered by Rajagopalan and Schulman [RS94] for the case of random noise, where every bit is flipped with some fixed probability. Rajagopalan and Schulman show, for any topology G, a coding scheme with an overhead of O(log(d + 1)), where d is the maximal degree of G. Gelles, Moitra and Sahai [GMS14] provide an efficient extension to that scheme. Alon et al. [ABE+ 16] show a coding scheme with an overhead of O(1) for d-regular graphs with degree d = nΩ(1) . Braverman et al. [BEGH16] demonstrate a lower bound of Ω(log n) on the communication over a star graph. All the above works assume fully-utilized synchronous protocols, in which the protocol works in rounds and in every round all nodes communicate on all the channels connected to them. Gelles and Kalai [GK17] show that if nodes are not required to speak at every round, a lower bound of Ω(log n) on the overhead can be proved even for coding schemes over graphs with small degree, e.g., d = 2. In the case of adversarial noise, Jain, Kalai and Lewko [JKL15] show a coding scheme that is resilient to a noise fraction of Θ(1/n) and has an overhead of O(1) in networks which contain a star as a subgraph. Lewko and Vitercik [LV15] improve the communication balance of that scheme. Hoza and Schulman [HS16] consider fully-utilized synchronous protocols on arbitrary graphs and show a coding with resilience Θ(1/|E|) and overhead O(1). If the topology of the network G is known to all nodes, the nodes can route messages over a sparser spanning graph and decrease the number of edges used by the coding scheme. In this case, Hoza and Schulman show a coding scheme with a maximal resilience level of Θ(1/n) and an overhead of O((|E| log n)/n). Previous work in distributed settings that allow edge failures are typically different from our setting in various aspects. Most notable are synchrony assumptions, complete communication graphs, addressing specific distributed tasks and assuming a bound on the number of links that may exhibit failures. This is in contrast to our work, which addresses an asynchronous setting with an arbitrary topology, and considers the simulation of any distributed task. In particular, all links may send corrupted messages, with the bound being the number of corruptions rather than the number of faulty links. For instance, Singh [Sin96] and Sayeed, Abu-Amara and AbuAmara [SAA95] consider the specific task of leader election and agreement for complete networks. Gong, Lincoln, and Rushby [GLR95], Siu, Chin and Yang [SCY98] and Dasgupta [Das98] consider agreement in complete synchronous networks with both faulty nodes and faulty links. Pelc [Pel92] shows that if the number of Byzantine-corrupted links is bounded by t, reliable communication is achievable only over graphs whose connectivity is more than 2t. The same work also considers the case where each link is faulty with some probability. In a more recent work, Feinerman, Haeupler and Korman [FHK14] also address complete synchronous networks, and study the specific problems of broadcast and majority consensus under random errors. Synchronizers for unreliable settings have been studied by Awerbuch et al. [APPS92], which address a dynamic setting, and by Harrington and Somani [HS94], which assume faulty nodes. 1.3 Organization We define basic notations, our communication and noise model as well as the notion of noise resiliet computations (i.e., coding schemes) in Section 2. In Section 3 we describe our content-oblivious BFS construction. A coding scheme over a spanning tree with overhead O(n2 log n) is provided in Section 4. Finally, a coding scheme based on an underlying spanner with an improved overhead of O(n log2 n) is provided in Section 5. 5 2 Preliminaries Throughout this work we assume a network described by a graph G = (V, E) with n = |V | nodes and m = |E| edges. Each node u ∈ V is a party that participates in the computation and each edge (u, v) ∈ E is a bi-directional communication channel between nodes u and v. The task of the nodes is to conduct some distributed computation given by a deterministic3 protocol π, which consists of the algorithm each node (locally) runs. In particular, the protocol dictates to each node which messages to send to which neighbor as a function of all previous communication (and possibly the node’s identity, private randomness and private input, if exists). The communication complexity of the protocol, CC(π), is the maximal number of bits communicated by all nodes in any instance of π. The message complexity of π is the maximal number of message sent by all nodes in any instance of π. We assume that the topology of G is known only locally, namely, each node v knows only the set Nu of identities of its own neighbors. However, the size of the network n is known to all nodes. Communication Models. Our protocols are for the Asynchronous communication model defined below. In addition, we describe a different communication model named the Fully-Utilized Synchronous Model, which is common in previous interactive coding work [RS94, HS16, ABE+ 16, BEGH16]. In particular, we use coding schemes defined in the fully-utilized synchronous model (specifically, [HS16]) as primitives for encoding our asynchronous protocols (see Lemma 2.1 below). • Asynchronous Model. In this setting, there are no timing assumptions. We assume each node is asleep until receiving a message. Once a message is received, the receiver wakes up, performs some local computation, transmits one or more messages to one or more adjacent nodes and goes back to sleep. Messages can be of any length. A protocol starts by waking up a single node r of its choice. • The Fully-Utilized Synchronous Model. Communication in this model works in synchronous rounds, determined by a global clock. At every clock tick, every node sends one symbol (from some fixed alphabet Σ) on each and every one of the communication links connected to it. That is, at every round exactly 2m symbols are being communicated. Adversary. We assume an all-powerful adversary that knows the network G, the protocol π and the private inputs of the nodes (if there are any). The adversary is able to (a) corrupt messages by changing the content of a transmitted message and (b) rush or delay the delivery of messages by an unbounded but finite amount of time. We restrict the number of messages that the adversary can corrupt, namely, we assume that the adversary can corrupt at most some fixed fraction µ of the communicated messages. We do not restrict how a message can be corrupted and, in particular, the adversary may replace a sent message M with any other message M ′ of any length and content. However, our coding scheme will have the invariant that each message contains a single symbol (from a given alphabet Σ), thus a message corruption will be equivalent to corrupting a single symbol. Note that the adversary is not allowed to inject new messages or completely delete existing messages.4 3 While we focus here on deterministic protocols, ours result also apply to randomized Monte-Carlo protocols. This type of noise, commonly called insertion and deletion noise, is known to be more difficult to deal with in the interactive setting [BGMO16] and may be destructive for asynchronous protocols [FLP85]. 4 6 Protocol Simulation, Resilience, and Overhead. A protocol Π is said to simulate π, if after the completion of Π, each node outputs the transcript it would have seen when running π assuming noiseless channels. The protocol Π is resilient to a µ fraction of noise, if Π succeeds in simulating π even if an all powerful adversary completely corrupts up to a fraction µ of the messages communicated by Π. The overhead of Π with respect to π is defined by overhead(Π | π) = CC(Π)/CC(π). A coding scheme C : π → Π converts any input protocol π into a resilient version Π = C(π). The resilience of a coding scheme is the minimal resilience of any simulation generated by the coding scheme. The (asymptotic) overhead of a coding scheme considers the maximal overhead for the worst input protocol π when CC(π) tends to infinity. Namely, overhead(C) = lim sup max overhead(C(π) | π). c→∞ π s.t. CC(π)=c We are mainly interested in how the overhead scales with n and m. A famous multiparty coding scheme in the fully-utilized synchronous model, shown by Hoza and Schulman [HS16] (based on a previous scheme [RS94]), provides a coding scheme that simulates any noiseless fully-utilized synchronous protocol π defined over some topology G with resilience Θ(1/m) and a constant overhead O(1). Lemma 2.1 ([HS16]). In the fully-utilized synchronous model, any T -round protocol π can be simulated by a protocol Π = HS(π) with round complexity O(T ) and communication complexity O(CC(π)) that is resilient to adversarial corruption of up to an Θ(1/m) fraction of the messages. 3 A Distributed Content-Oblivious BFS Algorithm In this section we show a distributed construction of a BFS tree using messages whose content can be arbitrary. We call this a content-oblivious construction. Our algorithm can be seen as a variant of a simple distributed layered-BFS algorithm, see, e.g., [Gal82, Pel00, Tel00]. 3.1 The BFS Algorithm: Description The BFS construction is initiated by one designated node r we call here the root. The construction builds the tree layer by layer. First, the root sends a message to all of its neighbors. This triggers its neighbors to set r as their parent. Each such a neighbor replies a message to r to acknowledge that it has received r’s message. Once r has received a message from all of its neighbors, it knows that the first layer is completed, and all nodes with distance 1 have set r as their parent. We call the above an Explore step. The root then begins a second Explore which causes all nodes at distance 2 to set their parent and connect to the BFS tree. Specifically, the root sends a message to each of its children and waits until all children reply a message to indicate they are done. However, in contrast to previous distributed BFS algorithms, messages are sent sequentially—the root sends a message to its next child only after receiving the acknowledgement message from its previous child. When a node v that has already set its parent parentv receives a message from its parent, it acts as a root and invokes an Explore: it sends a message to all of its neighbors excluding parentv and waits until they all send a message back. Only then v sends a message to its parent to indicate its 7 Explore process has completed. It is easy to see that when the root completes its k-th Explore, all nodes within distance at most k have set their parent and connected to the BFS tree. A special treatment is needed when a node u receives a message from a node v who is not the parent of u during a time at which u is not in the middle of an Explore step. That is, u is not expecting any messages from its neighbors, except for its parent that may trigger it to initiate another Explore step. Recalling that messages are sent to children in a sequential manner, it is easy to verify that such a message delivery may happen only when v has received a message from its own parent and is now processing its own Explore. That is, such a message indicates that v is a sibling of u in the BFS tree (namely, v is not a parent nor a child of u in the BFS tree). Thus, upon receiving such a message, u marks v as a sibling and removes it from its list of children. To simplify the presentation, as we elaborate in Remark 1, in next exploration steps u will keep sending messages to v as if it was one of its children. One additional property that we require from our BFS construction is that all the nodes complete the algorithm at the same time. As explained in the introduction, we use this construction as an initial part for our coding scheme. Furthermore, recall that in order to be noise-resilient, during the BFS construction the nodes ignore the content of the messages and their entire behavior is based on whether or not a message was received. However, once this construction is complete, the nodes send and receive messages according to the coding scheme and it is crucial that a node is able to distinguish messages that belong to the BFS construction from messages of the coding scheme. We solve this issue by making sure that each node participates in exactly n steps of Explore. Once the node has sent the n-th acknowledgement to its parent, the node knows that the next message from the parent belongs to the coding scheme rather than to the BFS construction.5 To make sure that each node participates in exactly n Explore steps, regardless of its distance from r, we let every node initiate one additional Explore, which we refer to as a dummy Explore. Specifically, when a node completes its (n − 1)-th Explore, and before the node sends the acknowledgement back to its parent, it invokes another Explore step. Now, just by counting the messages received from the parent, every node knows whether the BFS construction has completed or not. The pseudocode of the BFS construction is given in Algorithm 1(a) and Algorithm 1(b). 3.2 The BFS Algorithm: Analysis In this section we analyze Algorithm 1 and show that it satisfies the following properties. Theorem 3.1. For any input G = (V, E) and node r ∈ V , Algorithm 1 finds a BFS tree T with root r. Specifically, each node knows its parent in T and all of its adjacent edges that belong to T . The algorithm communicates O(nm) messages, where no payload is needed in any messages. Furthermore, we show that all nodes know that the BFS construction is complete, in the following sense. Claim 3.2. At the end of Algorithm 1 all nodes are in state DONE. Moreover, if r is in state DONE then all other nodes are in state DONE as well. Proof. (Theorem 3.1) Let T be a graph on the nodes V defined at the end of Algorithm 1 in the following manner: If v = parentu , then (u, v) is an edge in T . We begin by proving that T is a spanning tree. This is implied by the following claim. 5 Note that additional messages may arrive from a sibling node for the BFS construction but still, the next message arriving from the parent belongs to the coding scheme rather than the BFS construction. 8 Algorithm 1(a) Content-oblivious BFS construction: Main Algorithm Initialization: All nodes begin in the INIT state. For node r designated as root: Begin parentr ← ⊥ 4: childrenr ← Nr 5: countr ← 0 6: stater ← IDLE 1: 2: 3: while stater 6= DONE do 8: r invokes Explore 9: end while 10: End ⊲ Perform n instances of Explore 7: Claim 3.3. At the end of the k-th invocation of the root’s Explore step, all the nodes that are at distance k from r set their parent to a node with distance k − 1 from r and move to the state IDLE, and every node of distance larger than k from r is in state INIT. Proof. We prove the claim by induction on k. The base case k = 1 follows since in the first Explore invocation all of r’s children run SetParent, setting r as their parent, and switch to IDLE. They send message only back to r, hence all other nodes remain in INIT. Assume that the claim holds for the k-th invocation and consider the (k + 1)-th invocation of Explore by r. Messages propagating along the BFS tree cause all nodes of distance at most k to invoke Explore (in some order). This triggers a message to every node of distance k + 1, which causes it to switch its state to IDLE and set its parent to the first node (of distance k) that sent it a message. Note that nodes of distance k + 1 only communicate back to their parent and do not invoke Explore at this time, so nodes of distance larger than k + 1 remain in state INIT. At the end of the invocation each Explore, the invoking node switches back to state IDLE. Next, we prove that each node learns which neighbors are its children and which are not. First note that if v = parentu then u only sends v a message as a reply to a prior message received from v (i.e., an “ACK” message at the end of an Explore). Therefore, whenever v receives a a message from u it is in state EXPLORE, and such a message can never invoke the procedure MarkSibling. It follows that at the end of the algorithm v ∈ childrenu . Next, assume (u, v) is an edge in G but not in T . We show that at the end of the algorithm v ∈ / childrenu and u ∈ / childrenv . Let t be the first time after which both u and v have invoked SetParent. We claim that both u and v invoke Explore after time t. This is because time t is within the execution of an Explore step invoked by r and before Line 19 of that execution, and hence for every node w 6= r there is a time tw > t during the execution of the loop in Lines 19–23 for r in which w invokes Explore. Finally, we note that since (u, v) is an edge in G but not in T , then neither u is an ancestor of v in T nor v is an ancestor of u in T . This implies that when v invokes Explore then u is in state IDLE, which causes it to invoke MarkSibling and hence v ∈ / childrenu . The proof for u∈ / childrenv is exactly the same. 9 10 Algorithm 1(b) Content-oblivious BFS construction: Message Handling Procedures 1: 2: 3: 4: 5: 6: 7: For every node u in state INIT upon receiving a message from node v procedure SetParent parentu ← v childrenu ← Nu \ {v} countu ← 0 stateu ← IDLE send a message to v end procedure ⊲ an “ACK” message For every node u in state IDLE/DONE upon receiving a message from v 6= parentu procedure MarkSibling 9: childrenu ← childrenu \ {v} 10: send a message to v ⊲ an “ACK” message 11: end procedure 8: 12: 13: 14: 15: 16: 17: 18: For every node u in state IDLE upon receiving a message from parentu procedure Explore stateu ← EXPLORE countu ← countu + 1 for all v ∈ Nu \ {parent u } do ⊲ note: for is sequential send a message to v ⊲ an “Explore” message wait until a message is received from v end for 23: 24: if countu = n − 1 then for all v ∈ childrenu do send a message to v wait until a message is received from v end for end if 25: send a message to parentu 19: 20: 21: 22: 26: 27: 28: 29: 30: 31: if countu = n − 1 then stateu ← DONE else stateu ← IDLE end if end procedure ⊲ Extra dummy Explore ⊲ an “ACK” message ⊲ Change state to DONE if completed; otherwise, back to IDLE Finally let us analyze the message complexity. In Algorithm 1 each node invokes Explore for n times (see also the proof of Claim 3.2 below), where during each Explore it sends a message on each edge. Therefore, there are O(n) messages sent on each one of the m edges, which amounts to a total message complexity of O(nm) = O(|V | · |E|). Remark 1. It is possible to reduce the message complexity by sending Explore messages only to childrenv nodes. However, this must be delayed at least one Explore step, beyond the point in time where all the neighbors have completed their first Explore (in order to be able to identify siblings). The new message complexity will be O(|V |2 + |E|). For simplicity, we avoid this optimization and assume Explore messages are sent to all non-parent nodes all the time, incurring a message complexity of O(|V | · |E|). We now prove Claim 3.2. This property is important in particular for the next section, as it suggests that there is a point in time (known by the root), when all nodes have completed their BFS algorithm. In hindsight, this allows to distinguish messages that are part of the BFS construction, whose content is ignored, from messages of the coding scheme, whose content is meaningful and must not be ignored. Proof. (Claim 3.2) Note that the Explore procedure works in an DFS manner: a node replies an ACK to its parent only after all of its children reply an ACK to it. Similarly, the root completes an Explore step after receiving an ACK from all its children, which means that they have all completed their Explore steps. Note that each node invokes exactly n Explore steps due to the dummy Explore step initiated in Line 19. To see this, consider the same algorithm without the extra Explore in Lines 19–23 and note that nodes at distance k from the root r invoke exactly n − k Explore steps. Adding this extra Explore step at every node makes all nodes invoke Explore exactly n times. Specifically, during the n-th invocation of Explore by r, every node with distance 1 from r invokes its (n − 1)th Explore step, and then, before sending an ACK to r in Line 30, it invoke its n-th Explore step. This then continues in an inductive manner all the way to the leaves. Only once all of its children have sent an ACK and thus terminated the protocol and switched to DONE, a node replies with an ACK to its parent and changes its state to DONE. It follows that when the root receives an ACK for the n-th Explore step from all of its children, all the nodes have terminated the protocol and switched state to DONE. 4 A Distributed Interactive Coding Scheme In this section we show how to simulate any asynchronous protocol over a noisy network whose topology is unknown in advance. Our main theorem for this part is the following. Theorem 4.1. Any asynchronous protocol π over a network G can be simulated by an asynchronous protocol Π resilient to an Θ(1/n)-fraction of adversarial message corruption, and it holds that CC(Π) = O(nm log n) + CC(π) · O(n2 log n). 4.1 Obtaining a fully-utilized synchronous protocol from an asynchronous input protocol π The first ingredient we need is a way to transform an asynchronous protocol into a fully-utilized synchronous protocol, in order to be able to use the Hoza-Schulman coding scheme. This trans11 formation does not need to be robust to noise, as it is not going to be executed as is, but we will rather encode the fully-utilized synchronous protocol and execute the robust version. Later, we transform it back into the asynchronous setting using a synchronizer that is robust to noise. Recall that in a fully-utilized synchronous protocol nodes operate in rounds, where at each round every node communicates one symbol (from some fixed alphabet Σ) on each communication channel connected to it. We will assume the alphabet is large enough to convey all the information that our coding scheme needs. In particular, we assume each symbol contains O(log n) bits. Remark 2. In the following, we assume the network G is composed of channels with a fixed alphabet Σ of size poly(n). That is, each symbol contains O(log n) bits. In order to avoid confusion, we will use the term “symbols” for messages sent by the coding scheme, while using “messages” to indicate the information sent by the noiseless protocol π. The construction of our transformation into a fully-utilized synchronous protocol is given in Algorithm 2. In this construction, each node u maintains a queue of symbols that it needs to relay throughout a locally known spanning tree T . The queue is initialized with the bits of any message that u needs to send according to the input protocol π, where each bit is encapsulated in a symbol that contains the bit value, the identity of the source (i.e., of u), and the identity of the destination node. Every symbol received by u is pushed into its queue, and relayed to u’s neighbors in future rounds. In particular, upon receiving the symbol (src, dest, val) from a node w, the node u pushes the vector (src, dest, val, w) to its queue. If u is the destination node, it does not push the symbol into its queue; instead, u collects this bit for decoding the message. The transformation works by having each node pop a record from its queue in each round and send the obtained triplet to all of its neighbors in T except for the node w from which the message was received. If the queue is empty then an empty message is sent to all neighbors in T . Note that all fragments of a message are received in order at the destination, since T has no cycles. Therefore, we can assume that the protocol sends a predefined symbol that indicates the end of the message, in order to avoid an assumption of knowledge of the message length. This ensures that Line 17 is well-defined. Our transformation guarantees the following. Lemma 4.2. Algorithm 2 creates a fully-utilized synchronous protocol π ′ that simulates π, in the sense that all messages of π are sent and received. The simulation π ′ has a communication overhead of O(n2 log n) with respect to π, and a message complexity of CC(π) · O(n2 ). Proof. By construction, every node sends a symbol to all of its neighbors in each round and hence Algorithm 2 is a fully-utilized synchronous protocol. In addition, eventually every messages of π reaches its destination and hence the obtained fully-utilized synchronous protocol simulates π. For the communication overhead, note that O(log n) bits of the identities of source and destination are appended to each bit sent by π; that is, a symbol size of O(log n) bits suffices. In addition, a delivery of a single message of π may require O(n) rounds of relaying symbols sent along the tree T . In each such round there are O(n) symbols that are sent since the obtained protocol is a fully-utilized synchronous protocol. This implies that O(n2 ) symbols are communicated per each bit of π and gives a total communication overhead of O(n2 log n). Note that this is a worst-case analysis that assumes a single bit travels within the network at each time so that another bit is sent only after a previous bit reached its destination. If several bits are sent consecutively or if several nodes send bits simultaneously, the resulting number of messages can only decrease. 12 Algorithm 2 Simulating an asynchronous protocol π by a fully-utilized synchronous protocol π ′ . Initialization: Given is a BFS tree T rooted at r. 1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 4.2 In every round, for every node u: Begin for every node v do Let M1 · · · Mℓ be the bit representation of a message M that u has to send to v in π. Push (u, v, M1 , ⊥), · · · , (u, v, Mℓ , ⊥) into queueu end for (src, dest, val, w) ← pop item out of queueu if (src, dest, val, w) is not empty then send (src, dest, val) to every v ∈ Nu (T ) \ {w} and send ⊥ to w else send ⊥ to every v ∈ Nu (T ) end if For every message (src, dest, val) received from w: if dest 6= u then push (src, dest, val, w) into queueu else collect the bits val for decoding M end if End Root-triggered synchronizers We now describe our root-triggered synchronizer, which we use in order to execute the resilient synchronous protocol (which can be obtained by using the Hoza-Schulman coding scheme) in our asynchronous setting. We constructed a tree-based synchronizer as in Awerbuch [Awe85]. The synchronizer gets as an input a fully-utilized synchronous protocol Π′ and outputs an equivalent asynchronous protocol Π that simulates Π′ round by round. We first describe our simulation of a single round of Π′ over a tree. Our synchronizer works as follows. The root initiates the process by sending its messages, determined by Π′ , to its children. This triggers its children to send their messages to their children, but not yet to their parent, and so forth, so that messages propagate all the way to the leaves. Once a leaf receives a message, it sends its message to its parent, and similarly, any node which receives a message from all of its children sends its message to its parent. This continues inductively all the way back to the root, which eventually receives messages from all of its children and complete the simulation of this round of Π′ . We build upon the above idea in order to simulate a fully-utilized synchronous algorithm Π′ over an arbitrary graph S. That is, each node u has a message muv designated to each one of its neighbors v ∈ Nu (S).6 The pseudocode is given in Algorithm 3. We single out a node r, which we refer to as the initiator, which starts by sending a message to all of its neighbors in S. This triggers each neighboring node to send its messages to its neighbors, but not yet to its parent, which is now simply 6 Later, in Section 5, we apply our root-triggered synchronizer to an input protocol on G which is fully-utilized on a spanning subgraph S of G. 13 the neighbor from which it receives the first message. This continues inductively, and only when a node receives messages from all of its neighbors it sends its message to its parent. Eventually, the initiator receives messages from all of its neighbors and completes the simulation of the round. Algorithm 3 A root-triggered synchronizer for a fully-utilized synchronous protocol Π′ over a graph S. Initialization: All nodes begin in the INIT state. For node r designated as initiator: Begin 3: stater ← ACTIVE 4: parentr ← ⊥ 5: childrenr ← Nr (S) 1: 2: r sends mrv to each node v ∈ childrenr r waits to receive a message mvr from every node v ∈ childrenr 8: stater ← DONE 9: End 6: 7: For every node u, upon receiving a message from w when in state INIT: Begin 12: stateu ← ACTIVE 13: parentu ← w 14: childrenu ← Nr (S) \ {w} 10: 11: 15: 16: 17: 18: 19: u sends muv to each node v ∈ childrenu u waits to receive a message mvu from every node v ∈ childrenu u sends muw to w stateu ← DONE End We prove the following properties of Algorithm 3. Lemma 4.3. By the end of Algorithm 3 each node u receives the messages mvu from every node v ∈ Nu (S), and all nodes are in state DONE. Proof. Let T denote the tree rooted at r that is induced by the edges of S that connect each node u with parentu . By construction, each node u 6= r sets its parent to be the first node from which it receives a messages and hence u sets exactly one node as its parent in an acyclic manner, inducing the tree T . We prove by induction on the height of the nodes with respect to T , that each node u receives the messages mvu from every node v ∈ Nu (S) and then switches its state to DONE. Note that every node sends its messages to all of its neighbors so that eventually all such messages arrive, and we only need to verify that the message from u to parentu is eventually sent. The base case is for the leaves of T , which indeed receive messages from all of their neighbors since the only messages that get delayed are messages from nodes to their parents. Assume this holds for all nodes at height h, and consider a node u at height h + 1. Node u receives messages 14 from all of its siblings in the tree. By the induction hypothesis, every child v of u in T receives all of its messages and switches to state DONE. This implies that in between, node v sends its message mvu to its parent u. When this happens for all nodes v ∈ childrenu it is the case that u receives the messages mvu from every node v ∈ Nu (S) and then switches its state to DONE. By having the initiator r control the simulation of each round of a simulated fully-utilized synchronous protocol Π′ , we obtain synchronization for an arbitrary number of rounds. Corollary 4.4. Multiple consecutive invocations of Algorithm 3 simulate any input fully-utilized synchronous protocol Π′ round by round, resulting in an asynchronous protocol Π that uses the same number of messages. 4.3 The Coding Scheme We can now complete the details of our coding scheme for asynchronous networks with unknown topology. The scheme consists of two parts. In the first part, the scheme uses the BFS construction given in Section 3 in order to obtain a BFS tree T . Note that the nodes ignore the content of messages during this part, therefore an adversary that can only modify messages cannot disturb this part. In the second part, the scheme translates π into a fully-utilized synchronous protocol π ′ via O(n) fully-utilized synchronous rounds over T . This is done using Algorithm 2. The protocol π ′ is still non-resilient to noise and hence is not the protocol that is executed. Instead, we add a coding layer for multiparty interactive communication, namely via the Hoza-Schulman coding scheme, whose properties are given in Lemma 2.1. This results in a fully-utilized synchronous protocol Π′ that is resilient to noise, which we then execute through our root-triggered synchronizer to obtain the asynchronous resilient protocol Π. The complete construction is given in Algorithm 4. We prove its communication overhead in the following lemma, and then we prove its correctness and resilience. Algorithm 4 A coding scheme Π for any noiseless asynchronous input protocol π. Initialization: All nodes begin in the INIT state. 1: 2: 3: 4: 5: 6: 7: For node r designated as initiator: Begin Execute Algorithm 1 with r designated as root. Let T be the obtained BFS tree. Let π ′ be a fully-utilized synchronous algorithm induced by π using Algorithm 2. Let Π′ = HS(π ′ ) be the Hoza-Schulman coding scheme for π ′ . Simulate Π′ using the synchronizer of Algorithm 3 over T with r as the initiator. End Lemma 4.5. For any asynchronous protocol π the coding Π of Algorithm 4 has a communication complexity of CC(Π) = O(nm log n) + CC(π) · O(n2 log n). Proof. Recall that we assume channels with a fixed alphabet size, so that each symbol contains O(log n) bits (Remark 2). 15 The O(nm log n) term follows from Theorem 3.1. The transformation of Algorithm 2 induces a communication overhead factor of O(n2 log n) per bit of π, as shown in Lemma 4.2. By Lemma 2.1 there exists a resilient fully-utilized synchronous protocol Π′ that simulates π ′ whose message/communication complexity is linear in the message complexity of π ′ . Finally, Corollary 4.4 gives that the asynchronous simulation of Π′ via Algorithm 2 has the same message and communication complexity as Π′ . It follows that the total overhead in communication of Algorithm 4 is O(n2 log n), as claimed. Remark 3. Note that the BFS construction (Algorithm 1) ignores the contents of messages sent. Hence, if we relax the assumption of Remark 2, the communication complexity can be reduced by sending empty messages (without any payload) during that step. In this case the message complexity of Π remains O(mn)+CC(π)·O(n2 ) yet the communication complexity effectively reduces to CC(Π) = CC(π) · O(n2 log n). Remark 4. In the above, each message sent in π is split into single bits and a separate symbol is dedicated to each such bit. However, instead of communicating a single bit Mi in each symbol, nodes can aggregate blocks of O(log n) bits, so that the payload of each symbol is a single block (of π’s communication) while keeping the coding’s symbol size of the magnitude O(log n). For some protocols, namely those which send large messages, this may result in a slight logarithmic decrease in the message complexity. This optimization, however, will not change the asymptotic overhead in the worst case, when the protocol π communicates a single bit at a time. Lemma 4.6. For any asynchronous protocol π the coding Π of Algorithm 4 correctly simulates π even if up to Θ(1/n) of the messages are adversarially corrupted. Proof. Correctness and resilience to noise are proved as follows. Theorem 3.1 proves the correctness of our content-oblivious BFS construction despite noise, since the contents of the sent messages are ignored by the nodes. We emphasize that by Corollary 3.2, all of the nodes know when to stop ignoring the content of messages for the BFS construction and start executing that synchronizer over Π′ . Lemma 4.2 proves that indeed π ′ is a fully-utilized synchronous transformation of π. By Lemma 2.1, we have that Π′ is a fully-utilized synchronous protocol that simulates π ′ in a manner that is resilient to corrupting up to Θ(1/|Ẽ|) of the messages, where Ẽ is the edges over which the protocol communicates. In our case these are the edges of the BFS tree T , and hence this step is resilient to an Θ(1/n)-fraction of corruptions. Finally, Corollary 4.4 gives that Π′ is executed correctly in the asynchronous setting despite noise. We now need to sum up the maximal number of symbols that can be corrupted and the total number of communicated symbols. Recall that the noise resilience is the ratio between these two sums. Since corruption can only take place on symbols of the Hoza-Schulman coding, of which there are CC(π) · O(n2 ) many, we get that the scheme is resilient to at most Θ(1/n) · CC(π) · O(n2 ) corrupted symbols. The total number of symbols communicated in the scheme includes also the O(mn) symbols required for constructing the BFS tree, implying that our scheme is resilient to a fraction of symbol corruption equal to Θ(1/n) · CC(π) · O(n2 ) . O(nm) + CC(π) · O(n2 ) This is asymptotically equal to an O(1/n) fraction of noise when CC(π) > n, CC(π) → ∞. 16 Lemmas 4.5 and 4.6 directly give our main theorem for this section. Theorem 4.1 Any asynchronous protocol π over a network G can be simulated by an asynchronous protocol Π resilient to an Θ(1/n)-fraction of adversarial message corruption, and it holds that CC(Π) = O(nm log n) + CC(π) · O(n2 log n). 5 A Spanner-Based Distributed Interactive Coding Scheme In this section we slightly improve the overhead obtained by the coding scheme of Theorem 4.1. We demonstrate a family of coding schemes with an interesting tradeoff between their overhead and resilience. The key ingredient is replacing the underlying infrastructure of the BFS tree T with a sparse spanning graph S, where we can trade off the sparseness of the graph (i.e., the number of edges it contains, and as a consequence, the resilience of the obtained coding scheme) with its distance distortion (i.e., the maximal distance in S for any neighboring nodes in G, and as a consequence, the added overhead for routing messages through S in the coding scheme). Assume u sends v a message in the input protocol π. The coding scheme of Algorithm 4 routes every such message via the BFS tree T . This incurs a delay in Π′ , which can be of O(n) rounds: in the worst case, u and v which are neighbors in G may now be two leaves of T whose distance is n. In fact, even if their distance in T is smaller, the coding scheme is not aware of this fact and must propagate the message to the entire network. The only guarantee we have in this case is that the message reaches its destination after at most n rounds (of the underlying fully-utilized synchronous protocol). In this section we suggest a way to reduce the delay factor of n by routing messages over a spanner rather than over the tree T . Definition 1 (t-Spanner). A subgraph S = (V, ES ) is a t-spanner of G = (V, E) if for every (u, v) ∈ E it holds that dist(u, v) ≤ t in S. Replacing the BFS tree T with a t-spanner that has s = |ES | edges ensures that a message reaches its destination after at most t steps (instead of n). Since the noise resilience is determined by the number of edges used by the underlying fully-utilized synchronous protocol, by Lemma 2.1, we obtain a resilience of Θ(1/s). The main result of this section is the following. Theorem 5.1. Let πspanner be an asynchronous distributed algorithm for constructing a t-spanner S with s edges in a noiseless setting. Any asynchronous protocol π over a network G with CC(π) ≫ CC(πspanner ) can be simulated by a noise-resilient asynchronous protocol Π resilient to an Θ(1/s)fraction of message corruption and it holds that CC(Π) = CC(π) · O(st log n). Specifically, due to the existence of O(log n)-spanner with O(n) edges [Awe85, PS89] (see also [Pel00, Section 16]), we can let πspanner be a distributed construction of a spanner with the same parameters [DMZ10] and obtain the following corollary. Corollary 5.2. Let πspanner be an asynchronous distributed algorithm for constructing a log nspanner with O(n) edges in a noiseless setting. Any asynchronous protocol π over a network G with CC(π) ≫ CC(πspanner ) can be simulated by a noise-resilient asynchronous protocol Π resilient to an Θ(1/n)-fraction of message corruption and it holds that CC(Π) = CC(π) · O(n log2 n). 17 There are several challenges that arise when we replace the BFS tree T with a t-spanner S. As in the case of a tree T , the nodes know neither the topology of the graph nor the shortest route between any two nodes, and the only way to propagate information to its destination is by flooding it through the network. One difficulty stems from the fact that multiple paths may exist between any two nodes in S, while only a single path exists in T . This means that we are no longer guaranteed that each message arrives to its destination only once and that consecutive messages arrive in the correct order. One possible way to overcome the above issue is to add a serial counter to each message. Unfortunately, a counter of O(log n) bits is not enough to avoid confusion. Consider for instance the case where u √ and v are at distance t = O(log n) of each other7 , yet each node in between them is connected to n (unique) nodes. Furthermore, assume that all nodes are currently sending messages. If we flood the information through the network similar to the case of the tree T , i.e., where each node holds a queue of incoming messages which it relays one by one, then the message between u and v going through √ that route may be delayed by ( n)t = nΘ(log n) . Such a large delay cannot be recorded by a counter of O(log n) bits. Therefore, if u and v are also connected via another short path (or alternatively, a path that is not congested), then messages from the long path may be confused with messages from the short path so that the correct order of the messages could not be retrieved. To bypass the congestion issue, our coding scheme uses a priority mechanism for contention resolution, where messages with low priority are dropped by congested nodes and are later resent by their originating node. A full description and a careful proof that no messages are dropped are given in Section 5.1. The remaining issue is how to construct the spanner despite the noisy communication. Luckily, this can be done using Theorem 4.1, i.e., by running Algorithm 4 with an input distributed protocol πspanner for constructing spanners. For example, we can take a deterministic synchronous8 protocol for constructing a O(log n)-spanner of size O(n), e.g., the construction of Derbel, Mosbah, and Zemmari [DMZ10] which sends messages of size O(log n) and takes O(n) rounds to complete. On this input, Algorithm 4 communicates O(mn2 ) messages in the worst case (see also Remark 4). Once we obtain a t-spanner, we proceed as in Section 4 by converting the input protocol π to a fully-utilized synchronous protocol over the spanner using Algorithm 2, coding the fully-utilized synchronous protocol using the Hoza-Schulman scheme, and simulating each round of the coded algorithm using the root-triggered synchronizer over the spanner via Algorithm 3. Another issue which requires a careful attention is that when we execute two coded algorithms one after the other we must make sure that the lengths of both parts are balanced. This happens, for example, when we first run the algorithm for obtaining the spanner S and then execute the algorithm for simulating π over S. The reason for this is that otherwise the strong adversary can choose to attack the shorter algorithm using the larger budget of errors it has due to the longer algorithm. For example, assume that the coded construction of the spanner communicates x symbols while the coded simulation of π sends y symbols. If x is at most O(y/s), then the adversary has enough budget to fully corrupt the first part. Requiring, say, x = y, makes the scheme resilient to a Θ(1/2s) = Θ(1/s) fraction of corrupted symbols (see also footnote 10). 7 E.g., when using an O(log n)-spanner of size s = O(n) towards Corollary 5.2. In Theorem 5.1 we assume πspanner is an asynchronous protocol. Note that any synchronous protocol with time complexity τ sending messages of size σ can be thought of as an asynchronous protocol with message complexity O(τ m) and communication complexity O(τ mσ). 8 18 5.1 Obtaining a spanner-based fully-utilized synchronous protocol A main difference between the coding scheme given in Section 4 and in the spanner-based coding scheme of this section is how they transform the input protocol π into a fully-utilized synchronous one. The underlying idea is similar: each node breaks the messages of π bits, encapsulates them in a symbol that contains also their source and destination, and floods them one by one through the underlying graph—a tree in the former case and a spanner in the latter. As mentioned above, the main difficulty in the case of a spanner is the existence of several paths between every two nodes, which may cause a specific symbol to arrive multiple times at the receiver. Moreover, simply flooding the information through the spanner may cause very large delays on certain paths (super-polynomial delays9 ), due to the congestion caused by other symbols that are being relayed through the network. Hence, a receiver that gets multiple copies of symbols out of order with such long delays may not be able to reconstruct π’s message from them. Our solution breaks the simulation into windows of 2t rounds each, where each node attempts to send only a single symbol at each such window. In order to avoid congestion we use a priority system: when two or more symbols are received by some node, it drops all the symbols except for the one with the highest priority—the one whose sender’s identity is maximal. Then, the node relays this symbol to all of its neighbors. This procedure guarantees that at least one symbol arrives at its destination, at every 2t-round window. Furthermore, senders whose symbols were dropped can learn this event and resend their message during the next window. If a sender receives a symbol with a higher priority, it assumes that its own symbol was dropped during that window. We prove that this mechanism may have false negatives (i.e., a sender that resends a symbol while that symbol did arrive at the destination), but it does not have false positives (if a sender does not get an indication that it needs to resend, then its symbol is guaranteed to have arrived). The detailed transformation into a fully-utilized synchronous protocol is given in Algorithm 5. Towards proving the correctness of Algorithm 5, we prove some properties of the algorithm. Lemma 5.3. During every non-overlapping window of 2t rounds of π at least one message (src, dest, val, i) is delivered to its destination. Furthermore, The sender of this message ends this window of 2t rounds with RepeatSendMsgu = false. Proof. Since Relay is performed according to priority, the message with the highest priority (highest src) always survives and gets relayed all the way to the destination (which takes at most t rounds). The sender of this message never receives a message with a higher priority, thus it never sets RepeatSendMsgu to true on Line 31. Lemma 5.4. If u sends a message and after 2t rounds it holds that RepeatSendMsgu = false, then the message has reached its destination. Proof. Assume u sends a message to some node v. Additionally, assume that a node w with a higher priority (w > u) also attempts to send a message during the same 2t-round window. Without loss of generality, we assume w is the only node with priority higher than u; also recall that nodes with lower priority have no effect on the delivery of u’s message. For k ≤ 2t, define Bk to be all the messages that travel during the first k rounds (of that specific 2t-round window) on all the edges of distance at most k from u. We consider several cases: 9 Hence, appending O(log n) bits of a counter to each message does not suffice in order to guarantee the correct ordering of messages at the receiver’s side. 19 Algorithm 5 Simulation of an asynchronous protocol π by a fully-utilized synchronous protocol π ′ using a t-spanner S. Input: An asynchronous protocol π over G; a t-spanner S of G (the value t is known to all nodes) Init: for all nodes u: RepeatSendMsgu ← false; NextMsgu , RelayMemoryu , queueu ← ∅. 1: In every round RND, for every node u: 2: Begin 3: if RND ≡ 1 mod 2t then 4: Invoke SetNextMessage 5: end if 6: Invoke Relay 7: End 8: procedure SetNextMessage (for node u) 9: if RepeatSendMsgu = false or NextMsgu = ∅ then ⊲ Split the next message of π into bits, each to be delivered separately 10: Let M1 · · · Mℓ be the bit representation of a message M that u has to send to v in π. 11: Push (u, v, M1 , 1 mod n), · · · , (u, v, Mℓ , ℓ mod n) into queueu ⊲ ignore if no message to send 12: NextMsgu ← pop(queueu ) 13: RelayMemoryu ← NextMsgu 14: RepeatSendMsgu ← false 15: else if RepeatSendMsgu = true then ⊲ Previous bit may have not reached the des16: RelayMemoryu ← NextMsgu tination; retry with the same NextMsg. 17: RepeatSendMsgu ← false 18: end if 19: end procedure 20: procedure Relay (for node u) 21: (src′ , dest′ , val′ , i′ , w′ ) ← RelayMemoryu 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: ⊲ Relay highest priority message to all neighbors if RelayMemoryu 6= ∅ then send (src′ , dest′ , val′ , i′ ) to every v ∈ Nu (S) \ {w′ } and send ⊥ to w′ else send ⊥ to every v ∈ Nu (S) end if RelayMemoryu ← ∅ ⊲ Receive messages from all neighbors, Upon receiving a message (src, dest, val, i) from w: Begin if src′ > u then ⊲ RepeatSendMsgu ← true end if if dest 6= u then if src > src′ or RelayMemoryu = ∅ then RelayMemoryu ← (src, dest, val, i, w) end if else if dest = u then collect the bits val for decoding M (using the index i to ignore already received bits) 39: end if 40: End 41: end procedure 33: 34: 35: 36: 37: 38: keep only the message with highest priority Whenever a message with higher priority is received, assume own message wasn’t delivered during this window of 2t rounds 1. If u’s message has the highest priority in B2t then it is clear that the statement holds. This happens whenever dist(u, w) > 4t. 2. If dist(u, w) ≤ 2t then u receives w’s message during that window, and sets RepeatSendMsgu to true, so in this case the required conditions of the lemma do not hold to begin with. 3. The last case is when B2t contains w’s message, yet dist(u, w) > 2t. This implies that dist(v, w) > t (otherwise, via the trianlge inequality, we have that dist(u, w) ≤ 2t). This in turn implies that u’s message is the one with the highest priority in Bt , which means that u’s message is delivered to v by round t. Note that the opposite direction of the statement of Lemma 5.4 does not always hold. That is, if u sends a message and after 2t rounds it holds that RepeatSendMsgu = true, then it is possible that the message has nevertheless reached its destination. Lemma 5.3 and Lemma 5.4 suggest that progress is made every 2t rounds: at least one message is being delivered and all nodes whose messages are not delivered receive an indication of this event (and retry during the next window). This leads to the correctness of the algorithm, as stated in the following lemma. Lemma 5.5. Algorithm 5 creates a fully-utilized synchronous protocol π ′ that simulates π, in the sense that all messages of π are sent and received, with a communication overhead of O(st log n), where s is the number of edges in the input t-spanner S. Proof. By construction, every node sends a message to all of its neighbors in S in each round and hence Algorithm 5 is a fully-utilized synchronous protocol. In addition, as implied by Lemma 5.3 and Lemma 5.4, eventually every messages of π reaches its destination and hence the obtained fully-utilized synchronous protocol simulates all messages in π. Note that a message may be resent and received multiple times at the destination. However a node u always receives from any specific node v either the next bit of the message v sends, or a re-transmission of the last bit of the same message. Therefore, adding a single parity bit of the index of the transmitted bit is enough in order to avoid confusion (In Algorithm 3 we actually add to each bit the information (i mod n) where i is the index of the bit; yet communicating the value (i mod 3) would have sufficed). For the communication overhead, note that O(log n) bits of the identities of source and destination and bit index are appended to each bit sent by π, that is log |Σ| = O(log n) suffices. In addition, a delivery of a single bit of π may require O(t) rounds when sent over the spanner S. In each such round O(s) symbols are sent in a fully-utilized synchronous protocol. This implies O(st) messages are communicated per each bit of π which gives a total communication overhead of O(st log n). Note that this is a worst-case analysis that assumes a single bit (of π) travels within the network at each time so that another bit is sent only after a previous bit reached its destination. If several bits are sent consecutively or if several nodes send bits simultaneously, the resulting number of messages can only decrease. 21 Algorithm 6 Spanner-based coding scheme Π for any asynchronous noiseless protocol π. Initialization: All nodes know (a bound on) CC(π). πspanner is an asynchronous (noiseless) protocol for constructing a t-spanner. 1: 2: 3: 4: 5: 6: 7: 5.2 For node r designated as initiator: Begin Execute Algorithm 4 on input πspanner with r designated as root, extending the protocol so that the total message complexity of this step is C2 defined below. Let S be the obtained t-spanner. Let π ′ be a fully-utilized synchronous algorithm induced by π using Algorithm 5 on S. Let Π′ = HS(π ′ ) be the Hoza-Schulman coding scheme for π ′ . Let C2 be the message complexity of Π′ . Simulate Π′ using the synchronizer of Algorithm 3 over S with r as the initiator. End The spanner-based coding scheme Our modified spanner-based coding scheme Π is given in Algorithm 6. As mentioned above, when a coding scheme contains two parts (i.e., constructing the spanner and executing the coding scheme) that are being coded independently, it is necessary to make sure that the two parts are of equal length. Recall that we consider the asymptotical behavior of the coding scheme when CC(π) tends to infinity. Hence, we assume CC(π) ≫ CC(πspanner ), which implies that we need to extend the first part of our scheme where we construct the spanner graph in a resilient way. There are two possible ways to make this extension: either by artificially increasing the communication of πspanner to ≈ O(CC(π) · st/n2 ) bits, say, by sending zeroes after the spanner’s construction has completed; or by running the Hoza-Schulman encoding for O(C2 /n) rounds. We claim that the coding scheme Π of Algorithm 6 satisfies the requirements of Theorem 5.1. Proof. (Theorem 5.1) We first analyze the communication complexity of the scheme. We recall the assumption stated in Remark 2 that symbol of the coding scheme contains O(log n) bits; thus we can equivalently bound the message complexity. The execution of Algorithm 4 in Line 3 has a message complexity of C1 = O(mn) + CC(πspanner ) · O(n2 ). However, we artificially extend this step, so that it would have a message complexity of C2 . By Lemma 5.5, the message complexity of π ′ given by Algorithm 5 (Line 4) is C2 = CC(π) · O(st). Hence, the overall message complexity of Algorithm 6 is 2C2 , and the overall communication complexity is O(C2 log n) = CC(π) · O(ts log n). Regarding the resilience of the scheme, the first part (Line 3) is resilient due to Theorem 4.1; the second part (Lines 4–6) is independently encoded via the Hoza-Schulman coding scheme, whose guarantees are given in Lemma 2.1. The first part is resilient to a µ1 = Θ(1/n) fraction of corrupted messages and the second part is resilient to a µ2 = Θ(1/s) fraction of corrupted messages. Since we balance the message complexity of the two parts so that C1 = C2 and since s = Ω(n), the new scheme is resilient to a fraction of µ2 /2 = Θ(1/s) of corrupted messages overall.10 Acknowledgement. We are grateful to Merav Parter for bringing [DMZ10] to our attention. 10 By balancing the parts C1 and C2 in a weighted way one can obtain a slightly improved resilience of µ1 µ2 /(µ1 + µ2 ) = Θ(1/(n + s)) which is, however, asymptotically equivalent to Θ(1/s). 22 References [ABE+ 16] N. Alon, M. Braverman, K. Efremenko, R. Gelles, and B. Haeupler. Reliable communication over highly connected noisy networks. Proceedings of the 2016 ACM Symposium on Principles of Distributed Computing, PODC ’16, pp. 165–173, 2016. [AW04] H. Attiya and J. Welch. Distributed Computing: Fundamentals, Simulations and Advanced Topics. John Wiley & Sons, 2004. [Awe85] B. Awerbuch. Complexity of network synchronization. J. ACM, 32(4):804–823, 1985. [APPS92] B. Awerbuch, B. Patt-Shamir, D. Peleg, and M. E. Saks. Adapting to asynchronous dynamic networks (extended abstract). STOC ’92: Proceedings of the 24th Annual ACM Symposium on Theory of Computing, pp. 557–570, 1992. [BKN14] Z. Brakerski, Y. T. Kalai, and M. Naor. Fast interactive coding against adversarial noise. J. ACM, 61(6):35:1–35:30, 2014. [BE14] M. Braverman and K. Efremenko. List and unique coding for interactive communication in the presence of adversarial noise. Proceedings of the 55th annual IEEE Symposium on Foundations of Computer Science, FOCS ’14, pp. 236–245, 2014. [BEGH16] M. Braverman, K. Efremenko, R. Gelles, and B. Haeupler. Constant-rate coding for multiparty interactive communication is impossible. Proceedings of the Forty-eighth Annual ACM Symposium on Theory of Computing, STOC ’16, pp. 999–1010, ACM, 2016. [BGMO16] M. Braverman, R. Gelles, J. Mao, and R. Ostrovsky. Coding for interactive communication correcting insertions and deletions. 43rd International Colloquium on Automata, Languages, and Programming (ICALP ’16), Leibniz International Proceedings in Informatics (LIPIcs), vol. 55, pp. 61:1–61:14, 2016. [BR14] M. Braverman and A. Rao. Toward coding for maximum errors in interactive communication. Information Theory, IEEE Transactions on, 60(11):7248–7255, 2014. [Das98] P. Dasgupta. Agreement under faulty interfaces. 65(3):125 – 129, 1998. [DMZ10] B. Derbel, M. Mosbah, and A. Zemmari. Sublinear fully distributed partition with applications. Theory of Computing Systems, 47(2):368–404, 2010. [EGH16] K. Efremenko, R. Gelles, and B. Haeupler. Maximal noise in interactive communication over erasure channels and channels with feedback. IEEE Transactions on Information Theory, 62(8):4575–4588, 2016. [FHK14] O. Feinerman, B. Haeupler, and A. Korman. Breathe before speaking: efficient information dissemination despite noisy, limited and anonymous communication. ACM Symposium on Principles of Distributed Computing, PODC ’14, pp. 114–123, 2014. [FLP85] M. J. Fischer, N. A. Lynch, and M. Paterson. Impossibility of distributed consensus with one faulty process. J. ACM, 32(2):374–382, 1985. 23 Information Processing Letters, [FGOS15] M. Franklin, R. Gelles, R. Ostrovsky, and L. J. Schulman. Optimal coding for streaming authentication and interactive communication. Information Theory, IEEE Transactions on, 61(1):133–145, 2015. [Gal82] R. G. Gallager. Distributed minimum hop algorithms. Tech. Rep. LIDS-P-1175, M.I.T. Laboratory for Information and Decision Systems, 1982. [Gel15] R. Gelles. Coding for interactive communication: A survey, 2015. [GHK+ 16] R. Gelles, B. Haeupler, G. Kol, N. Ron-Zewi, and A. Wigderson. Towards optimal deterministic coding for interactive communication. Proceedings of the Twenty-Seventh Annual ACM-SIAM Symposium on Discrete Algorithms, pp. 1922–1936, 2016. [GK17] R. Gelles and Y. T. Kalai. Constant-rate interactive coding is impossible, even in constant-degree networks. Proceedings of the 8th Conference on Innovations in Theoretical Computer Science, ITCS ’17, 2017. [GMS14] R. Gelles, A. Moitra, and A. Sahai. Efficient coding for interactive communication. Information Theory, IEEE Transactions on, 60(3):1899–1913, 2014. [GHS14] M. Ghaffari, B. Haeupler, and M. Sudan. Optimal error rates for interactive coding I: Adaptivity and other settings. Proceedings of the 46th Annual ACM Symposium on Theory of Computing, STOC ’14, pp. 794–803, 2014. [GLR95] L. Gong, P. Lincoln, and J. Rushby. Byzantine agreement with authentication: Observations and applications in tolerating hybrid and link faults. Dependable Computing and Fault Tolerant Systems, vol. 10, pp. 139–158, IEEE Computer Society, 1995. [Hae14] B. Haeupler. Interactive channel capacity revisited. Proceedings of the 55th annual IEEE Symposium on Foundations of Computer Science, FOCS ’14, pp. 226–235, 2014. [HS94] M. Harrington and A. K. Somani. Synchronizing hypercube networks in the presence of faults. IEEE Trans. Computers, 43(10):1175–1183, 1994. [HS16] W. M. Hoza and L. J. Schulman. The adversarial noise threshold for distributed protocols. Proceedings of the Twenty-Seventh Annual ACM-SIAM Symposium on Discrete Algorithms, pp. 240–258, 2016. [JKL15] A. Jain, Y. T. Kalai, and A. Lewko. Interactive coding for multiparty protocols. Proceedings of the 6th Conference on Innovations in Theoretical Computer Science, ITCS ’15, pp. 1–10, 2015. [KR13] G. Kol and R. Raz. Interactive channel capacity. STOC ’13: Proceedings of the 45th annual ACM symposium on Symposium on theory of computing, pp. 715–724, ACM, 2013. [LV15] A. Lewko and E. Vitercik. Balancing communication for multi-party interactive coding, 2015. ArXiv preprint arXiv:1503.06381. [Lyn96] N. A. Lynch. Distributed Algorithms. Morgan Kaufmann Publishers Inc., San Francisco, CA, USA, 1996. 24 [Pel92] A. Pelc. Reliable communication in networks with byzantine link failures. Networks, 22(5):441–459, 1992. [Pel00] D. Peleg. Distributed Computing: A Locality-Sensitive Approach. Society for Industrial and Applied Mathematics, 2000. [PS89] D. Peleg and A. A. Schäffer. Graph spanners. Journal of Graph Theory, 13(1):99–116, 1989. [RS94] S. Rajagopalan and L. Schulman. A coding theorem for distributed computation. STOC ’94: Proceedings of the twenty-sixth annual ACM symposium on Theory of computing, pp. 790–799, 1994. [SAA95] H. M. Sayeed, M. Abu-Amara, and H. Abu-Amara. Optimal asynchronous agreement and leader election algorithm for complete networks with byzantine faulty links. Distributed Computing, 9(3):147–156, 1995. [Sch92] L. J. Schulman. Communication on noisy channels: a coding theorem for computation. Foundations of Computer Science, Annual IEEE Symposium on, pp. 724–733, 1992. [Sch96] L. J. Schulman. Coding for interactive communication. IEEE Transactions on Information Theory, 42(6):1745–1756, 1996. [Sin96] G. Singh. Leader election in the presence of link failures. IEEE Transactions on Parallel and Distributed Systems, 7(3):231–236, 1996. [SCY98] H.-S. Siu, Y.-H. Chin, and W.-P. Yang. Byzantine agreement in the presence of mixed faults on processors and links. IEEE Transactions on Parallel and Distributed Systems, 9(4):335–345, 1998. [Tel00] G. Tel. Introduction to distributed algorithms. Cambridge university press, 2000. Chapter 12.4. Asynchronous BFS Algorithms, pages 414–420. 25
8cs.DS
arXiv:1703.07199v2 [math.AC] 3 Apr 2017 A characterization of the Macaulay dual generators for quadratic complete intersections T. Harima, Niigata University Department of Mathematics Education, Niigata, 950-2181 Japan ∗ A. Wachi, Hokkaido University of Education Department of Mathematics, Kushiro, 085-8580 Japan J. Watanabe, Tokai University Department of Mathematics, Hiratsuka, 259-1292 Japan April 5, 2017 Abstract Let F be a homogeneous polynomial in n variables of degree d over a field K. Let A(F ) be the associated Artinian graded K-algebra. If B ⊂ A(F ) is a subalgebra of A(F ) which is Gorenstein with the same socle degree as A(F ), we describe the Macaulay dual generator for B in terms of F . Furthermore when n = d, we give necessary and sufficient conditions on the polynomial F for A(F ) to be a complete intersection. 1 Introduction Let R = K[x1 , . . . , xn ] be the polynomial ring in n variables over a field of characteristic zero and Rd the homogeneous space of degree d. For F ∈ Rd , let A = A(F ) be the graded Artinian Gorenstein algebra associated with F . So A has socle degree d and embedding dimension at most n. It is a long standing problem to characterize forms F ∈ Rd for which the associated Artinian Gorenstein algebras A(F ) are complete intersections. If F is a monomial, then A(F ) is a monomial complete intersection. The only other known cases are a few sporadic examples (cf.[13], [10, Examples 2.82–2.85]) that occur as the algebra of co-invariants by pseudo reflection groups. It seems that there is a tendency among the experts to think there are no easily verifiable conditions which enable us to tell, for a given F , whether or not the algebra A(F ) is a complete intersection. However, it is easy to see that if the degree of F is less than n, then A(F ) cannot be a complete intersection, since the socle degree of A(F ) is equals to the degree of the Jacobian of the generators. When A(F ) = R/I is a graded complete intersection with quadratic generators for the defining ideal I = AnnR (F ), then the degree of F ∗ Supported by JSPS KAKENHI Grant 15K04812. 1 is n. In Theorem 3 of this paper we give necessary and sufficient conditions on a form F for A(F ) = R/I to be a complete intersection. There is yet another result of this paper. We discuss the relation of Macaulay dual generators for two Artinian Gorenstein algebras A and B, with A ⊃ B, when the two algebras have the same socle degree. This was one of the topics discussed in the workshop at BIRS in March 2016, under the title “The Lefschetz Properties and Artinian algebras.” There is a good reason to think that many complete intersections can be obtained as subrings of quadratic complete intersections (cf. [8] [14]). We will show that a Macaulay dual generator for B can be obtained from that of A by substituting the linear forms for the variables with duplications allowed. In Theorem 17 we show that the Gorenstein Artinian algebra A has a sub-quotient B of the same socle degree if and only if a Macaulay dual generator for B can be obtained from that of A by substituting the linear forms for the variables. This is independent of Theorem 3 and in this theorem the socle degree and embedding dimension of A are arbitrary. When we speak about the Macaulay dual generator of a Gorenstein algebra, it is important to specify the structure of the inverse system or in the modern term, the injective hull of the residue field. The injective hull does not have a structure of a ring; it is possible, however, to regard it as the divided power algebra, induced by the natural structure of the Hopf algebra associated with the polynomial ring. In characteristic zero, the divided power algebra is the same as the polynomial ring. Throughout §§2–3, we assume, for simplicity, that the characteristic of the ground field is zero, and assume that the injective hull is the same as the polynomial ring itself but the action of the algebra is defined through differentiation. Nonetheless all arguments are valid for a positive characteristic p provided that p is greater than the degree of F . Verification is left to the reader. A basic fact on the Macaulay’s double annihilator theorem is summarized in the Appendix based on the treatment in Meyer-Smith [7]. The reader may also wish to consult Geramita [4] and IarrobinoKanev [6] for the treatment of the inverse system. The authors would like to thank Tony Iarrobino very much for many comments to improve this paper. The third author thanks Larry Smith very much for the suggestion of the usage of the divided power algebra for the inverse system of Macaulay. 2 Some necessary conditions for a homogeneous form to define a quadratic complete intersection Throughout this section K denotes a field of characteristic 0, and R = K[x1 , x2 , . . . , xn ] denotes the polynomial ring over K. We assume each variable has degree 1. We denote by Rd the homogeneous space of R of degree d. Thus we may write R= ∞ M Rd . d=0 We regard R as an R-module via the operation “◦” defined by   ∂ ∂ ∂ , ,..., F, f (x1 , x2 , . . . , xn ) ◦ F = f ∂x1 ∂x2 ∂xn 2 for (f, F ) ∈ R × R. With this operation R is the injective hull of the residue field in the category of finitely generated modules (see Appendix). Thus if f ∈ Ri and F ∈ Rd , then f ◦ F is an element of Rd−i . For F ∈ R, AnnR (F ) denotes AnnR (F ) = {f ∈ R|f ◦ F = 0}. It is the annihilator of F . A(F ) denotes the algebra A(F ) = R/AnnR (F ). We will say that A(F ) is the Gorenstein algebra defined by F or simply A(F ) is defined by F . We will call the vector space Ann(F )2 ⊂ R2 the quadratic space defined by F and denote it by Q(F ). Namely, the quadratic space Q(F ) = Ann(F )2 ⊂ R2 is the kernel of the homomorphism f ∈ R2 7→ f ◦ F ∈ Rd−2 . Note that we have the exact sequence 0 → Q(F ) → R2 → R2 /AnnR (F )2 → 0. L For a graded vector space V = ∞ i=0 Vi , we write HV (T ) = ∞ X (dimK Vi )T i i=0 for the Hilbert series of V . Definition 1. An Artinian algebra A = R/I will be called a quadratic complete intersection if it is a complete intersection and the Hilbert series is (1 + T )d for some d. (The ideal I may contain linear forms.) Proposition 2. Let F ∈ R = K[x1 , x2 , . . . , xn ] be a homogeneous polynomial. Suppose that HA(F ) (T ) = (1 + T )n . Then we have (1) deg F = n. (2) No linear forms are contained in AnnR (F ). (3) The partial derivatives ∂F ∂F ∂F ∂x1 , ∂x2 , . . . , ∂xn are linearly independent. (4) The quadratic space Q(F ) defined by F has dimension n.  (5) dimK (R2 ◦ F ) = dimK (Rn−2 ◦ F ) = n2 . Proof. (1) Recall that the homomorphism of R-modules R→R defined by f 7→ f ◦F induces the degree reversing isomorphism of vector spaces R/AnnR (F ) = A(F ) → R ◦ F ⊂ R, f 7→ f ◦ F, where f = f mod AnnR (F ). This shows that if the algebra A(F ) has the Hilbert series (1 + T )n , then F has degree n. 3 (2) Note that A(F )1 = R1 /AnnR (F )1 . Since dimK A(F )1 = n, this shows that AnnR (F )1 = 0. Hence AnnR (F ) contains no linear forms. (3) Note that A(F )1 ∼ = R1 ◦ F . Since dimK R1 ◦ F = n, this shows that the first partials of F are linearly independent. (4) (5) Consider the exact sequence 0 → Q(F ) → R2 → R2 /AnnR (F )2 → 0.   Note that dim R2 = n+1 and dimK A(F )2 = n2 . The assertions follow from 2 the isomorphisms A(F )2 = R2 /AnnR (F )2 ∼ = R2 ◦ F ∼ = Rn−2 ◦ F . 3 A characterization of the Macaulay dual generator for quadratic complete intersections Following is a characterization of F ∈ R which defines a quadratic complete intersection. Theorem 3. As before R denotes the polynomial ring in n variables over a field K of characteristic zero. Let F ∈ R be a polynomial of degree n. Suppose that ∂F ∂F are linearly independent. Then the Artinian , · · · , ∂x the partial derivatives ∂x n 1 Gorenstein algebra A(F ) = R/AnnR (F ) is a quadratic complete intersection if and only if one of the following conditions is satisfied. (1) The quadratic space Q(F ) is n-dimensional and generates AnnR (F ) as an ideal of R. (2) The quadratic space Q(F ) contains a regular sequence of length n in R. Proof. Assume that A(F ) is a quadratic complete intersection. Then AnnR (F ) is generated by a regular sequence consisting of n homogeneous polynomials of degree two. Hence we have both (1) and (2). Conversely assume (2). Let I be the ideal generated by a regular sequence in Q(F ). Then we have a surjective map R/I → R/AnnR (F ) = A(F ). Since R/I and R/AnnR (F ) are Gorenstein with the same socle degree, we have A(F ) = R/I. (To see this recall that an Artinian Gorenstein local ring has the smallest nonzero ideal.) Assume (1). Then a basis for Q(F ) is a regular sequence in R. Hence AnnR (F ) is generated by a regular sequence consisting of quadrics. Remark 4. Theorem 3 gives us an algorithm which determines whether or not the algebra A(F ) = R/AnnR (F ) is a quadratic complete intersection for a given F ∈ K[x1 , . . . , xn ]. The algorithm proceeds as follows. (1) Let F ∈ K[x1 , . . . , xn ]n be a homogeneous form of degree n. 4 ∂F ∂F (2) Check if the partials ∂x are linearly independent. If they are linearly , . . . , ∂x n 1 dependent, F reduces to a polynomial of a smaller number of variables, but it has degree n. So in this case A(F ) is not a quadratic complete intersection. (It could be a complete intersection with a smaller embedding dimension than n.) If they are linearly independent, compute the second partials of F . If  dimK (R2 ◦ F ) 6= n2 or equivalently dimK Q(F ) 6= n, then A(F ) cannot be a quadratic complete intersection. (3) If dimK Q(F ) = n, let hf1 , . . . , fn i be a K-basis of Q(F ). Compute the rank of 2n  the vector space V = Rn−1 f1 +Rn−1 f2 +· · ·+Rn−1 fn . If dimK V = n+1 , then AnnR (F ) is a quadratic complete intersection; otherwise it is not. (Note that 2n V ⊂ Rn+1 and dimK Rn+1 = n+1 , and V = Rn+1 if and only if f1 , f2 , . . . , fn is a complete intersection.) Remark 5. Suppose that dim Q(F ) = n and Q(F ) = hf1 , f2 , . . . , fn i. It is easy to see that the following conditions are equivalent. (1) f1 , f2 , . . . , fn is a regular sequence. (2) Rn−1 f1 + Rn−1 f2 + · · · + Rn−1 fn = Rn+1 . (3) The initial ideal of (f1 , f2 , . . . , fn ) contains all high powers of the variables. (4) The resultant of f1 , f2 , . . . , fn does not vanish. (For the theory of resultants see [2]. There is a related result in [9].) Remark 6. Tony Iarrobino pointed that Thoerem 3 can be generalized to any homogeneous polynomial F ∈ Rn(d−1) to define a complete intersection with generators of any uniform degree d. We confined ourselves to the quadratic case (d = 2), since the generalization is straightforward, and since we had in mind the results of [8] and [9]. Example 7. Let R = K[x, y, z]. Consider F ∈ R3 . If the partials Fx , Fy , Fz are linearly independent, then the Hilbert series for A(F ) is (1 + T )3 , in which case dimK Q(F ) = 3. So A(F ) is a quadratic complete intersection for most of F ∈ R3 . Following are exceptional cases. These examples are due to Buczyńska et al. [1]. (1) F = −x3 + y 2 z. It is easy to see that Q(F ) ⊃ hz 2 , xzi, and that these are not a regular sequence. So we may conclude Q(F ) cannot be a complete intersection. The fact is that AnnR (F ) is a 5 generated Gorenstein ideal: AnnR (F ) = (z 2 , xz, xy, y 3 , x3 + 3y 2 z). (2) F = x2 y+y 2 z. We can apply the same argument as above to see that AnnR (F ) is not a complete intersection. AnnR (F ) = (z 2 , xz, x2 − yz, y 3 , xy 2 ). The classification of ternary cubics is known over the complex number field. The complete sets of orbits in the parameter space CP9 for the ternary cubics by the general linear group GL(3, C) can be found in [1] Section 2. 5 Example 8. Let R = K[w, x, y, z]. (1) Consider F = (w − x)(y − z)(w2 + x2 + y 2 + z 2 ). Then we have: Q(F ) = hwx − yz, y 2 + 4yz + z 2 , w2 + 4yz + x2 , (w + x)(y + z)i With an aid of a computer algebra system, it is easy to see that the ideal generated by these elements is a complete intersection. Hence A(F ) is a quadratic complete intersection. (2) Consider F = (w − x)(y − z)(w + x + y + z)2 . Then we have: Fw + Fx − Fy − Fz = 0. This shows that AnnR (F ) contains a linear form. A(F ) is not a quadratic complete intersection but is a complete intersection with embedding dimension three. In fact AnnR (F ) = (w + x − y − z, x(x − y − z) + yz, (y + z)2 , z 2 (3y − z).) (3) F = (wx)2 − (yz)2 . It is easy to see that Q(F ) = hwy, wz, xy, xzi. So this is not a quadratic complete intersection. It happens that the Hilbert series is (1 + T )4 . However, AnnR (F ) = (wy, wz, xy, xz, w3 , x3 , y 3 , z 3 , (wx)2 + (yz)2 ). Example 9. Let R = K[v, w, x, y, z]. (1) F = vwxyz + wxyz 2 . It is easy to see that AnnR (F ) contains 5 quadratic relations. In fact (v 2 , w2 , x2 , y 2 , z 2 − 2vz) ⊂ AnnR (F ). So AnnR (F ) is a complete intersection. (2) F = vwxyz + xyz 3 . AnnR (F ) = (v 2 , w2 , x2 , y 2 , z 2 − 6vw). Similarly to the previous example, this is a complete intersection. (3) F = vwxyz + yz 4 . It is easy to see that we have the relations  ∂ ∂v 2 F =  ∂ ∂w 2 F =  ∂ ∂x 2 F =  ∂ ∂y 2 F = 0. With a little contemplation we see that no more quadratic relations are possible. So this is not a complete intersection. In fact we can compute AnnR (F ) = (v 2 , w2 , x2 , y 2 , wz 2 , vz 2 , xz 2 , z 3 − 24vwx). Problem 10. For what binomial F ∈ K[x1 , x2 , . . . , xn ]n is AnnR (F ) a complete intersection? (Define F to be a binomial by F = αM + βN , where M, N are power products of variables and α, β ∈ K.) 6 Remark 11. The vector space Rn may be regarded as the parameter variety for the Gorenstein algebras of socle degree n with embedding dimension at most n. Thus the  projective space PN where N = 2n−1 −1 is the paremeter space for such Gorenstein n algebras. By the Double Annihilator Theorem of Macaulay, each orbit of the general linear group GL(n) contains precisely one isomorphism type of Gorenstein algebras. (See [7].) Thus the dimension of the parameter space for the isomorphism types of Gorenstein algebras with socle degree n and embedding dimension at most n is    2n − 1 − 1 − (n2 − 1). n (We roughly estimated that each orbit is (n2 − 1)-dimensional.) On the other hand, the set of quadratic complete intersections may be parametrized by the n-dimensional subspaces in R2 . Thus the dimension of the parameter space  is n × n2 . The linear transformation of the variables gives us an isomorphism of such complete intersections. Hence the dimension of the parameter space for the isomorphism types is   n n× − (n2 − 1). 2 Here is a list of these dimensions for small values of n. n n 2n−1 − n n 2 − n 2 2 3 4 5 6 − 1 19 101 426 + 1 − 1 9 26 55 n2 Remark 12. Suppose F ∈ Rn defines a quadratic complete intersection. We may assume that the square free monomials are linearly independent in A(F ). (For this fact see  [9].) Let Bk ⊂ Rk be the set of square free monomials of degree k and define the nk × nk matrix Hk (F ) as follows: Hk (F ) = ((αβ) ◦ F )(α,β)∈Bk ×Bk . The rows and columns of Hk (F ) are indexed by Bk . In [12] the authors call the determinant of Hk (F ) the higher Hessian of order k of F (with respect to the basis Bk ). By [15] Theorem 4 the algebra A(F ) has the strong Lefschetz property if and only if det Hk (F ) 6= 0, for all k = 1, 2, . . . , [n/2]. We conjecture that det Hk (F ) does not vanish for F ∈ Rn for all k, if F defines a quadratic complete intersection. This is a part of a larger conjecture which claims that all complete intersections over a field of characteristic zero have the strong Lefschetz property. For more detail see [10] Conjecture 3.46 and Theorem 3.76. In the next example we show that there exists a Gorenstein algebra with the same Hilbert series as a quadratic complete intersection, but fails the SLP. 7 Example 13 (R. Gondim). Consider the polynomial F = v 3 wx + vw3 y + y 2 z 3 of degree 5 in 5 variables. With an aid of a computer algebra system one sees that A(F ) has the Hilbert series (1 + T )5 , but A(F ) is not a complete intersection. It is not difficult to see that the 2nd Hessian of F with respect to certain bases for A2 and A3 is identically zero, so the algebra A(F ) fails the SLP. The set of square free monomials of degree 2 is linearly dependent in A(F )2 , but this is not essential to the failure of the SLP. In fact if F is expressed in generic variables, the sets of square-free monomials can be bases for A2 and A3 . This example was constructed by Gondim [3]. (See [3], Theorem 2.3 and the paragraph preceding it.) 4 The Macaulay dual generator for a subring of a Gorenstein algebra In this section we consider Artinian algebras A over a field K with the assumption characteristic K is zero or greater than the socle degree of A. The socle degree and the embedding dimension of A are arbitrary. L Theorem 14. Suppose that A = di=0 Ai is a standard graded Artinian Gorenstein algebra with Ad 6= 0. Assume that A0 = K is a field of characteristic p = 0 or p > d. Let x1 , x2 , . . . , xn ∈ A1 be the images of the variables of the polynomial ring and let ξ1 , ξ2 , . . . , ξn ∈ K. Fix a nonzero socle element s ∈ Ad . Define the map Φ : Kn → K which sends (ξ1 , ξ2 , . . . , ξn ) to c, where c is defined by (ξ1 x1 + ξ2 x2 + · · · + ξn xn )d = cs. Since c is a function of ξ1 , ξ2 , . . . , ξn , we may write c = Φ(ξ1 , ξ2 , . . . , ξn ). The map Φ is a polynomial map and Φ(ξ1 , ξ2 , . . . , ξn ), as a polynomial, is a Macaulay dual generator for the Gorenstein algebra A. This was proved in [10] Lemma 3.47. Here we give another proof. Proof. Let R = K[x1 , x2 , . . . , xn ] be the polynomial ring and F ∈ Rd a Macaulay dual generator for A. Then we have the isomorphism R/AnnR (F ) ∼ = A defined by xi 7→ xi . Let S = S(x1 , . . . , xn ) ∈ Rd be a pre-image of a nonzero socle element s ∈ Ad . Put α = S ◦ F ∈ K. Since S 6∈ AnnR (F ), we have α 6= 0. Given (ξ1 , ξ2 , . . . , ξn ) ∈ K n , we want to find c = c(ξ1 , . . . , ξn ) ∈ K which satisfies cs = (ξ1 x1 + ξ2 x2 + · · · + ξn xn )d . Such c should satisfy (ξ1 x1 + ξ2 x2 + · · · + ξn xn )d − cS ∈ AnnR (F ). Thus we should have ((ξ1 x1 + ξ2 x2 + · · · + ξn xn )d − cS) ◦ F = 0. 8 We compute the left hand side as follows: ((ξ1 x1 + ξ2 x2 + · · · + ξn xn )d − cS) ◦ F = (ξ1 x1 + ξ2 x2 + · · · + ξn xn )d ◦ F − cS ◦ F = d!F (ξ1 , . . . , ξn ) − cα We used Lemma 15 which we prove below for the last equality. It turned out that c= d! F (ξ1 , . . . , ξn ). α Hence we have d! F (x1 , x2 , . . . , xn ). α Φ(x1 , x2 , . . . , xn ) = Lemma 15. Let R = K[x1 , x2 , . . . , xn ] be the polynomial ring and let ξ1 , ξ2 , . . . , ξn ∈ K be any elements in K. Put D = ξ1 ∂ ∂ ∂ + ξ2 + · · · + ξn . ∂x1 ∂x2 ∂xn Then for any homogeneous polynomial F ∈ Rd of degree d, we have D d F = d!F (ξ1 , ξ2 , . . . , ξn ). Proof. Let F = Dd F P d1 d1 +···+dn =d a(d1 ,...,dn ) x1 · · · xdnn . Then: = (ξ1 ∂x∂ 1 + · · · + ξn ∂x∂ n )d F   X ∂ d1 ∂ dn  d! =  ξ1d1 ( ) · · · ξndn ( ) F d1 ! · · · dn ! ∂x1 ∂xn d1 +···+dn =d    X ∂ dn  d! d1 ∂ d1 dn a(d1 ,...,dn ) xd11 · · · xdnn ) · · · ξn ( ) ξ1 ( = d1 ! · · · dn ! ∂x1 ∂xn d1 +···+dn =d X d! a ξ d1 · · · ξndn d1 ! · · · dn ! = d1 ! · · · dn ! (d1 ,...,dn ) 1 d1 +···+dn =d = d!F (ξ1 , . . . , ξn ). Definition 16. Suppose that F = F (x1 , . . . , xn ) is a polynomial in x1 , . . . , xn and G = G(y1 , . . . , ym ) is a polynomial in y1 , . . . , ym . (Assume that the sets {x1 , . . . , xn } and {y1 , . . . , ym } are independent sets of variables.) We will say that G is obtained from F by substitution by linear forms, if there exists a full rank m × n matrix M = (mij ) such that F (x1 , x2 , . . . , xn ) = G(y1 , y2 , . . . , ym ), if we make a substitution: x1 x2 · · ·  xn = y 1 y 2 · · · 9  ym M. L Theorem 17. Suppose that A = di=0 Ai is a standard graded Artinian Gorenstein algebra over A0 = K, a field, with socle degreeL d. Assume that the characteristic of K is zero or greater than d. Suppose that B = di=0 Bi is a Gorenstein subalgebra of L A = di=0 Ai with the same socle degree. (We assume that B = K[B1 ], A = K[A1 ], and B1 ⊂ A1 .) Then a Macaulay dual generator for B is obtained from that of A by substitution by linear forms. Proof. We have shown that Φ = Φ(ξ1 , . . . , ξn ) defined in Theorem 11 is a Macaulay dual generator for A. Likewise we let Φ′ = Φ′ (η1 , . . . , ηm ) be a Macaulay dual generator for B. Let s be a nonzero socle element of A. We may assume that Ad = Bd = hsi. Let M = (mij ) be the m × n matrix which satisfies     y1 x1  y2   x2      = (m )  ..  ij  ..  ,  .   .  ym xn where hx1 , x2 , · · · , xn i is a basis for A1 and hy1 , y2 , · · · , ym i for B1 . Then, since P d Pn m (η1 y1 + η2 y2 + · · · + ηm ym )d = i=1 ηi ( j=1 mij xj ) P d Pm n = ( η m )x , j=1 i=1 i ij j we have m m X X ηi min ). ηi mi1 , . . . , Φ (η1 , . . . , ηm ) = Φ( ′ i=1 Φ′ This shows that the matrix (mij ): i=1 is obtained from Φ by linear substitution of the variables with (ξ1 ξ2 · · · ξn ) = (η1 η2 · · · ηm )(mij ). Example 18. Let R be the polynomial ring in n variables. Put Sn be the symmetric group acting on R by permutation of the variables. Let I = (f1 , f2 , . . . , fn ) be a quadratic complete intersection such that AnnR (F ) = (f1 , . . . , fn ). So F is a Macaulay dual generator of R/(f1 , . . . , fn ). Suppose that F σ = F for all σ ∈ Sn . Let G be a Young subgroup of Sn such that G = Sn1 × Sn2 × · · · × Snr , n1 + n2 + · · · + nr = n. Then the ring of invariants B = AG ⊂ A is a complete intersection and in many cases AG is generated by linear forms (see [8]). When this is the case, the generators can be chosen as follows: y 1 = x1 + x2 + · · · + xn 1 , 10 y2 = xn1 +1 + xn1 +2 + · · · + xn1 +n2 , | {z } n2 .. . yr = xn1 +···+nr−1 +1 + xn1 +···+nr−1 +2 + · · · + xn . {z } | nr Then a Macaulay dual generator G for B is obtained as follows: G = F (y1 , . . . , y1 , y2 , . . . , y2 , · · · , yr . . . , yr ). | {z } | {z } | {z } n1 n2 nr Example 19. Let R = K[u, v, w, x, y, z] be the polynomial ring in 6 variables. Put f1 = u2 − 2u(v + w + x + y + z), f2 = v 2 − 2v(u + w + x + y + z), f3 = w2 − 2w(u + v + x + y + z), f4 = x2 − 2x(u + v + w + y + z), f5 = y 2 − 2y(u + v + w + x + z), f6 = z 2 − 2z(u + v + w + x + y). Let A = R/(f1 , · · · , f6 ). Then A is an Artinian complete intersection. A Macaulay dual generator is given as follows: F = 80m6 + 48m51 + 120m42 − 30m411 + 160m33 − 60m321 + 60m3111 − 90m222 + 90m2211 − 225m21111 + 1575m111111 , where mijk etc. denotes the monomial symmetric polynomial. For example, m6 = u6 + v 6 + w6 + x6 + y 6 + z 6 , m51 = u5 v + uv 5 + · · · + wz 5 + xz 5 + yz 5 , m411 = u4 vw + · · · + xyz 4 , .. . m111111 = uvwxuz. The polynomial F was obtained by solving a system of linear equations in 462 variables by Mathematica. (462 is the dimension of K[u, · · · , z]6 .) The polynomial F looks complicated, but it has the striking property that any substitution of variables by another set of variables defines a complete intersection. For example F (p, p, q, q, r, s) ∈ K[p, q, r, s]6 is a complete intersection in 4 variables. This corresponds to the ring AG of invariants by the Young subgroup G := S2 × S2 × S1 × S1 . 11 5 Subalgebras of Gorenstein algebras generated by linear forms Ld Theorem 20. Let A = i=0 Ai be an Artinian Gorenstein algebra. Let B be a subring of A generated by a subspace of A1 such that Bd = Ad 6= 0. Then we have the following: (1) There exists an irreducible ideal b of B such that B/b is a Gorenstein algebra with the socle degree d. (2) A Macaulay dual generator of B ′ = B/b is obtained from that of A by a substitution by linear forms. Proof. (1) Let b1 ∩ b2 ∩ · · · ∩ br = 0 be an irredundant decomposition of 0 in B by irreducible ideals. Then we have the injection: r M B/bi . 0→B→ i=1 Note that there exists an i, say i = 1, such that B ′ = B/b1 has the same socle as B. (2) Let η1 , η2 , . . . , ηm be elements of K. The evaluation of the map (η1 y1 + η2 y2 + · · · + ηm ym )d at Bd or Bd′ are the same. Hence the assertion follows in the same way as Theorem 17. Example 21. Let K be a field of characteristic zero. Consider A = K[x, y, z]/I, where I = (x2 − 6yz, y 2 − 6xz, z 2 − 6xy). Let S = K[r, s], define ψ : S → A by r 7→ x, s 7→ y + az. Then we have ker ψ = (3(a3 + 1)rs2 − as3 , r 2 s, (a3 + 1)r 3 − s3 ), provided that a 6= ±1. On the other hand a Macaulay dual generator for A is F = F (x, y, z) = x3 + 3 y + z 3 + xyz. Let G = F (r, s, as). That is, the polynomial G is obtained from F by the substitution by the linear forms:   1 0 0 (x, y, z) = (r, s) 0 1 a A primary decomposition of the ideal I is given by I = AnnS (G) ∩ (r + s, s3 ), where AnnS (G) = (a2 r 2 + 9(a3 + 1)rs − 3as2 , 3(a3 + 1)rs2 − as3 ). If a = 1, then ker ψ is a complete intersection: ker ψ = (r 2 + 18rs − 3s2 , 6rs2 − s3 ). The case a = 0 works as well as other general cases. The computation was done with the computer algebra system Macaulay2 [5]. 12 A Appendix:Divided power algebra and the injective hull Let R = K[x1 , x2 , . . . , xn ] be the polynomial ring over a field K of any characteristic. It is easy to see that HomK (R, K) = ∞ Y HomK (Ri , K) i=0 is an injective R-module. In the category of finitely generated R-modules, we may adopt Γ = gr.Hom(R, K) = ∞ M HomK (Ri , K) i=0 as the injective hull of the residue field of K = R/R+ . It is possible to endow the vector space Γ a structure of a commutative algebra, called the divided power algebra. This can be explained as follows: For the K basis of Γ, we take the dual base of Ri , i.e, the “monomials” (i ) (i ) X1 1 X2 2 · · · Xn(in ) , which are regarded as a homomorphism Ri1 +···+in → K defined by  1, if I = J, (i ) (i ) X1 1 X2 2 · · · Xn(in ) ◦ xj11 xj22 · · · xjnn = 0, otherwise. (i ) (i ) (i ) (I and J are multi-indices.) The multiplication among the monomials {X1 1 X2 2 · · · Xn n } are defined by the rule:   I +J I J X X = X I+J , I where (i ) (i ) X I = X1 1 X2 2 · · · Xn(in ) , (j1 ) X J = X1 (j2 ) X2 · · · Xn(jn ) , I = (i1 , i2 , . . . , in ), J = (j1 , j2 , . . . , jn ), I + J = (i1 + j1 , i2 + j2 , . . . , in + jn ),  I +J (i1 + j1 )!(i2 + j2 )! · · · (in + jn )! = i1 !i2 ! · · · in !j1 !j2 ! · · · jn ! J  Note that the coefficients I+J are integers. If the characteristic p of K is zero, J (k) k we may think X = X /k!, and the divided power algebra is the polynomial ring. If p > 0, then pth power is zero (which is easy to check), hence Γ is not finitely generated.  13 We may regard Γ as an R-module by the openration (j1 ) xi11 xi22 · · · xinn ◦ X1 (j2 ) X2 (j1 −i1 ) · · · Xn(jn ) = X1 (j2 −i2 ) X2 · · · Xn(jn −in ) . At the start of Section 2, we set Γ = R and the action of f for F ∈ Γ be   ∂ ∂ ∂ f ◦F =f , ,..., F. ∂x1 ∂x2 ∂xn The reader may convince himself that this interpretation of the injective hull of R/R+ and the construction of Γ are consistent. For this it is enough to see that (i ) (i ) (ij ) xj ◦ X1 1 X2 2 · · · Xj (i ) (i ) (ij −1) · · · Xn(in ) = X1 1 X2 2 · · · Xj · · · Xn(in ) . Thus the variable xk acts on Γ by “differentiation.” The reasons why we use this formulation are, among other things the following two propositions. Proposition 22. Let F ∈ Rd and assume that p = 0 or p > d. Then if the partials are dependent, then one variable can be eliminated from F by a linear transformation of the variables. Proof is left to the reader. Proposition 23. Assume that p = 0 or p > d. Let F ∈ Rd , and A = A(F ). Then the following conditions are equivalent. 1. The Hessian determinant of F does not vanish. 2. There exists a linear form l ∈ R1 such that the multiplication map ld−2 : A2 → Ad−1 is bijective. For proof see [12]. The second proposition was not explicitly used in this paper, but it is a strong motivation for the usage of the divided power algebra. Suppose that F ∈ Γd . Then A(F ) = R/AnnR (F ) is an Artinian Gorenstein algebra. Macaulay’s double annihilator Theorem can be stated as follows: Theorem 24 (F. S. Macaulay). Let R be the polynomial ring and Γ the divided power algebra as the injective hull of R/R+ . The correspondence F 7→ A(F ) has the inverse. I.e., the set of graded Artinian Gorenstein algebra A = R/I with top degree d and the set of homogeneous forms in Γd of degree d are in one-to-one correspondence up to linear change of variables over the field K. For proof see Meyer-Smith [7, Theorem II.2.1]. See also the original work of Macaulay [11]. Example 25. Let R = K[x, y, z] and consider F = (x + y + z)3 ∈ K[x, y, z]3 . We ∂ ∂ ∂ , ∂y , ∂z )F for f, F ∈ R. Then we have AnnR (F ) = (x − have defined f ◦ F = f ( ∂x 4 y, x − z, z ). F. S. Macaulay originally used “contract” (rather than the differential operator) to make R the injective hull for R. In this case we have AnnR (F ) = (9x2 −10xz−4yz+15z 2 , 9y 2 −10xy−4xz+15x2 , 9z 2 −10yz−4xy+15y 2 ). In either case the double annihilator theorem holds. 14 References [1] W. Buczyńska, J. Buczyński, J. Kleppe, and Z. Teitler, Apolarity and direct sum decomposition of polynomials, Michigan Math. J. Math., 64,(2015) no. 4, 675–719. [2] I. M. Gelfand, M. M. Kaplanov, A. V. Zelevinski, Discriminants, Resultants, and Multidimensional Determinants, Birkhäuser, Boston, 1994. [3] R. Gondim, On higher Hessians and the Lefschetz properties, To appear in J. Algebra. [4] A. V. Geramita, Inverse systems of fat points: Waring’s problem, secant varieties of Veronese varieties and parameter spaces for Gorenstein ideals, The Curves Seminar at Queen’s, Vol. X, 2–114, Queen’s Papers in Pure and Appl. Math., 102, Queen’s Univ., Kingston, ON, 1996. [5] D. R. Grayson and M. E. Stillman, Macaulay2, a software system for research in algebraic geometry, available at http://www.math.uiuc.edu/Macaulay2/. [6] A. Iarrobino, V. Kanev, Power sums, Gorenstein algebras, and determinantal loci, Lecture Notes in Mathematics, 1721, Springer-Verlag, Berlin, 1999. [7] D. M. Meyer, L. Smith, Poincaré duality algebras, Macaulay’s dual systems, and Steenrod operations, Cambridge Tracts in Mathematics, 167. Cambridge University Press, Cambridge, 2005. viii+193 pp. ISBN: 978-0-521-85064-3; 0521-85064-9 Cambridge University Press, Boston, 1994. [8] T. Harima, A. Wachi, J. Watanabe, The quadratic complete intersections associated with the action of the symmetric group, Illinois J. Math.59 (1), 99–113 (2015), MR3459630 [9] T. Harima, A. Wachi, J. Watanabe, The resultants of binomial complete intersections, To appear. [10] T. Harima, T. Maeno, H. Morita, Y. Numata, A. Wachi, and J. Watanabe, The Lefschetz Properties, Springer Lecture Notes 2080, Springer-Verlag, 2013. [11] F. S. Macaulay. The Algebraic Theory of Modular Systems, Camb. Math. Lib. , Cambridge: Cambridge University Press, 1996 (reissued with an introduction by P. Roberts 1994). [12] T. Maeno, J. Watanabe, Lefschetz elements of Artinian Gorenstein algebras and Hessians of homogeneous polynomials, Illinois J. Math.53 (2), 591–603 (2009). [13] L. Solomon, Invariants of Finite Reflection Groups, Nagoya Math. J. 22 (1963) 57–64. [14] C. McDaniel, The strong Lefschetz properties for coinvariant rings of finite reflection groups, J. Algebra 331, (2003), 99–126. 15 [15] J. Watanabe, A remark on the Hessian of homogeneous polynomials, The curves seminar at Queen’s, vol. XIII, Queen’s Papers in Pure and Appl. Math., vol. 119, 2000, Queen’s Univ. ON, 171–178. 16
0math.AC
Stochastic Testing Simulator for Integrated Circuits and MEMS: Hierarchical and Sparse Techniques Invited Paper Zheng Zhang1, Xiu Yang2, Giovanni Marucci3 , Paolo Maffezzoni3, Ibrahim (Abe) M. Elfadel4 , George Karniadakis2 and Luca Daniel1 arXiv:1409.4822v1 [cs.CE] 16 Sep 2014 1 Research Laboratory of Electronics, Massachusetts Institute of Technology, Cambrige, MA 02139 2 Division of Applied Mathematics, Brown University, Providence, RI 02912 3 Dipartimento di Elettronica e Informazione, Politecnico di Milano, Milano, Italy 4 Institute Center for Microsystems, Masdar Institute of Science & Technology, Abu Dhabi, UAE Abstract—Process variations are a major concern in today’s chip design since they can significantly degrade chip performance. To predict such degradation, existing circuit and MEMS simulators rely on Monte Carlo algorithms, which are typically too slow. Therefore, novel fast stochastic simulators are highly desired. This paper first reviews our recently developed stochastic testing simulator that can achieve speedup factors of hundreds to thousands over Monte Carlo. Then, we develop a fast hierarchical stochastic spectral simulator to simulate a complex circuit or system consisting of several blocks. We further present a fast simulation approach based on anchored ANOVA (analysis of variance) for some design problems with many process variations. This approach can reduce the simulation cost and can identify which variation sources have strong impacts on the circuit’s performance. The simulation results of some circuit and MEMS examples are reported to show the effectiveness of our simulator. I. I NTRODUCTION As the device size shrinks to the sub-micro and nano-meter scale, process variations have led to significant degradation of chip performance and yield [1], [2]. Therefore, efficient stochastic simulators are highly desired to facilitate variationaware chip design. Existing circuit and MEMS simulators use Monte Carlo [3], [4] for stochastic simulation. Despite its ease of implementation, Monte Carlo requires a huge number of repeated simulations due to its slow convergence rate, very often leading to prohibitively long computation times. Stochastic spectral methods [5]–[9] are promising alternative techniques. In fact, they have shown significant speedup over Monte Carlo in many engineering fields. The key idea is to represent the stochastic solution as a linear combination of some basis functions such as polynomial chaos [10] or generalized polynomial chaos [8], which then can be computed by stochastic Galerkin [5] or stochastic collocation [11]–[13] techniques. Such techniques have been successfully applied to simulate the uncertainties in VLSI interconnects [14]–[17], electromagnetic and microwave devices [18]–[20], nonlinear circuits [21]–[24] and MEMS devices [25]–[27]. An efficient stochastic testing simulator has been proposed to simulate integrated circuits [28]–[30]. This simulator is a hybrid version of the stochastic collocation and the stochastic Galerkin methods. Similar to stochastic Galerkin, stochastic testing sets up a coupled deterministic equation to directly compute the stochastic solution. However, the resulting coupled equation can be solved very efficiently with decoupling and adaptive time stepping inside the solver. This algorithm has been successfully integrated into a SPICE-type program to perform various (e.g., DC, AC, transient and periodic steadystate) simulation for integrated circuits with both Gaussian and non-Gaussian uncertainties. It can also be easily extended to simulate MEMS designs (c.f. Section II). In this paper we will present two recent advancements based on this formulation. First, Section III will present a hierarchical uncertainty quantification method based on stochastic testing. Hierarchical simulators can be very useful for the statistical verification of a complex electronic system and for multi-domain chip design (such as MEMS-IC co-design). In this simulation flow, we first decompose a complex system into several blocks and use stochastic spectral methods to simulate each block. Then, each block is treated as a random parameter in the higherlevel system, which can be again simulated efficiently using stochastic spectral methods. This approach can be hundreds of times faster than the hierarchical Monte Carlo method in [31]. Second, in Section IV we will present an approach to improve the efficiency of stochastic spectral methods when simulating circuits with many random parameters. It is known that spectral methods can be affected by the curse of dimensionality. In this paper, we utilize adaptive anchored ANOVA [32]– [37] to reduce the simulation cost. This approach exploits the sparsity on-the-fly according to the variance of the computed terms in ANOVA decomposition, and it turns out to be suitable for many circuit problems due to the weak coupling among different variation sources. This algorithm can also be used for global sensitivity analysis that can determine which parameters contribute the most to the performance metric of interest. The simulation results of some integrated circuits and MEMS/IC co-design cases are reported to show the effectiveness of the proposed algorithms. II. S TOCHASTIC T ESTING S IMULATOR In this section we summarize the algorithms and results of our recently developed fast stochastic testing circuit simulator. We refer the readers to [28]–[30] for the technical details. Fig. 1. Overall flow of the stochastic testing simulator. A. Overview of the Simulator The overall flow of the stochastic testing simulator is shown in Fig. 1. The main procedures are summarized below. 1) Set Up Stochastic Circuit Equations: Given a circuit netlist, the device models and the specification of devicelevel uncertainties, one can use modified nodal analysis [38] to obtain a stochastic differential algebraic equation:   ~ ξ~   d~q ~x(t, ξ), (1) ~ ξ~ = B~u (t) + f~ ~x(t, ξ), dt where ~u(t) is the input signal; ~x ∈ Rn denotes nodal voltages and branch currents; ~q ∈ Rn and f~ ∈ Rn represent the charge/flux and current/voltage terms, respectively. Here ~ 1 , · · · , ξd ] ∈ Ω (with Ω ⊆ Rd ) represents d independent ξ=[ξ random variables describing device-level uncertainties. The joint probability density function of ξ~ is ~ = ρ(ξ) d Y ρk (ξk ), (2) where δγ,ν is a Delta function; integers γ and ν denotes the degrees of ξk in φkγ (ξk ) and φkν (ξk ), respectively. Given ρk (ξk ), one can utilize a three-term recurrence relation to construct such orthonormal univariate polynomials [39]. The univariate generalized polynomial chaos basis functions for Gaussian, Gamma, Beta and uniform distributions can be easily obtained by shifting and scaling existing Hermite, Laguerre, Jacobi and Legendre polynomials, respectively [6], [8]. Since for any integer k ∈ [1, K] there is a one-to-one correspondence between k and α ~ , for simplicity we rewrite (3) as ~ ≈ x̃(t, ξ) ~ = ~x(t, ξ) α ~ ∈P n where x̂α~ (t) ∈ R denotes a coefficient indexed by vector ~ is an α ~ = [α1 , · · · , αd ] ∈ Nd , and the basis function Hα~ (ξ) orthonormal multivariate polynomial with the highest order of ξi being αi . In stochastic testing, the highest total degree of the polynomials is set as p, leading to P = {~ α| αk ∈ N, 0 ≤ α1 + · · · + αd ≤ p}. Consequently, the total number of basis functions is   (p + d)! p+d . (4) K= = p p!d! Since all components of ξ~ are assumed mutually independent, the multivariate basis function can be constructed as d Y ~ = Hα~ (ξ) φkαk (ξk ), (5) k=1 φkαk (ξk ) where is a degree-αk univariate polynomial of ξk satisfying the orthonormality condition Z φkγ (ξk ), φkν (ξk ) = φkγ (ξk )φkν (ξk )ρk (ξk )dξk = δγ,ν (6) Ωk ~ x̂k (t)Hk (ξ). (7) k=1 ~ we need to calculate the coefficient In order to find x̃(t, ξ), ~ is substituted into vectors x̂k (t)’s. In stochastic testing, x̃(t, ξ) (1) and then the resulting residual is forced to zero at K testing points ξ~1 , · · · , ξ~K , giving the following coupled deterministic differential algebraic equation of size nK k=1 where ρk (ξk ) is the marginal density of ξk ∈ Ωk ⊆ R. ~ t) has a 2) Stochastic Testing Formulation: When ~x(ξ, bounded 2nd-order moment, we can approximate it by a truncated generalized polynomial chaos expansion [6], [8] X ~ ≈ x̃(t, ξ) ~ = ~ ~x(t, ξ) x̂α~ (t)Hα~ (ξ) (3) K X dq(x̂(t)) + f(x̂(t)) = Bu(t), dt (8) where the state vector x̂(t) = [x̂1 (t); · · · ; x̂K (t)] collects all coefficient vectors in (7). This new differential equation can be easily set up by stacking the function values of (1) evaluated at each testing point [28], [30]. In stochastic testing, the testing points are selected as follows [28], [30]: Step 1. For each ξk , select p + 1 Gauss quadrature points ξkj ’s and weights wkj ’s [40]–[42] to evaluate an integral by Z p+1 X g(ξkj )wkj (9) g(ξk )ρk (ξk )dξk ≈ Ωk j=1 which provides the exact solution when g (ξk ) is a polynomial of degree ≤ 2p + 1 [40]. The d-dimensional quadrature points and weights for ξ~ are then obtained by a tensor rule, leading to (p + 1)d samples in total. Step 2. Define a matrix V∈RK×K , the (j, k) element of which is Hk (ξ~j ). Among the obtained (p + 1)d d-dimensional quadrature points, select the K points with the largest weights as the final testing points, subject to the the constraint that V is invertible and well conditioned. 3) Simulation Step: Instead of simulating (1) using a huge number of random samples, our simulator directly solves the deterministic equation (8) to obtain a generalized polynomial~ In DC and AC analysis, we only chaos expansion for ~x(t, ξ). (a) 300 L1 R3 Q1 6V C3 R1 R2 Vout C1 C2 250 250 200 200 150 150 100 100 50 50 0 1.6 Fig. 2. Schematic of the BJT Colpitts oscillator. need to compute the static solution by Newton’s iterations. In transient analysis, numerical integration can be performed given an initial condition to obtain the statistical information (e.g., expectation and standard deviation) at each time point. This simulator is very efficient due to several reasons [28]. First, it requires only a small number of samples to set up (8) when the parameter dimensionality is not high. Second, the linear equations inside Newton’s iterations can be decoupled although (8) is coupled, and thus the overall cost has only a linear dependence on the number of basis functions. Third, adaptive time stepping can further speed up the time-domain stochastic simulation. B. Performance Summary Extensive circuit simulation examples have been reported in [28], showing promising results for analog/RF and digital circuits with a small to medium number of random parameters. For those examples, the stochastic testing simulator has shown 102 × to 103 × speedup over Monte Carlo due to the fast convergence of generalized polynomial-chaos expansions. This circuit simulator is also significantly more efficient than the standard stochastic Galerkin [5] and stochastic collocation solvers [11]–[13], especially for time-domain simulation. Stochastic periodic steady-state solvers have been further developed on this platform and tested on both forced circuits (e.g., low-noise amplifier) and autonomous circuits (e.g., oscillators) [29]. As an example, we consider the Colpitts BJT oscillator in Fig. 2, the frequency of which is influenced by the Gaussian variation of L1 and non-Gaussian variation of C1 . With a 3rd-order generalized polynomial-chaos expansion, our stochastic testing simulator is about 5× faster than the solver based on stochastic Galerkin [23]. Fig. 3 shows the histograms of the simulated period from our simulator and from Monte Carlo, which are consistent with each other. Note that Monte Carlo is about 507× slower than our simulator when the similar level of accuracy is required. C. Extension to MEMS Simulation The stochastic testing method can be easily extended to simulate MEMS designs. Considering uncertainties, we can describe a MEMS device by a 2nd-order differential equation   2 ~ ~ t), ξ~ d ~z(ξ, t) + M ~z(ξ, dt2 (10)     d~z(ξ, ~ t) ~ ~ ~ ~ ~ + f ~z(ξ, t), u(t), ξ = 0 D ~z(ξ, t), ξ dt Fig. 3. 1.65 1.7 (b) 300 1.75 period (s) 1.8 −8 x 10 0 1.6 1.65 1.7 1.75 period (s) 1.8 −8 x 10 Distributions of the period: (a) stochastic testing, (b) Monte Carlo. where ~z ∈ Rn denotes displacements and rotations; u(t) denotes the inputs such as voltage sources; M, D ∈ Rn×n are the mass matrix and damping coefficient matrix, respectively; f~ denotes the net forces from electrostatic and mechanical forces. This differential equation can be obtained by discretizing a partial differential equation or an integral equation [43], or by using the fast hybrid platform that combines finiteelement/boundary-element models with analytical MEMS de~ t) by a truncated vice models [44]–[46]. First representing ~z(ξ, generalized polynomial-chaos expansion and then forcing the residual of (10) to zero at a set of testing points, we can obtain a coupled deterministic 2nd-order differential equation. This new 2nd-order differential equation can be directly used for stochastic static and modal analysis. For transient analysis, we can convert this 2nd-order differential equation into a 1st-order one which has a similar form with (8), and thus the algorithms in [28]–[30] can be directly used. III. H IERARCHICAL U NCERTAINTY Q UANTIFICATION This section presents a hierarchical non-Monte Carlo flow for simulating a stochastic system consisting of several blocks. Let us consider Fig. 4, which can be the abstraction of a complex electronic circuit or system (e.g., phase-lock loops) or a design with multi-domain devices (e.g., a chip with both transistors and MEMS). The output of each block (denoted by yi ) depends on a group of low-level random parameters ξ~i ∈ Rdi , and the output of the whole system ~h is a function of all low-level random parameters. Stochastic analysis for the whole system is a challenging task due to the potentially large problem size and parameter dimensionality. In this paper we assume that x̂i ’s are mutually independent. A. The Key Idea Instead of directly simulating the whole system using ξ~i ’s as the random sources, we propose to perform uncertainty quantification in a hierarchical way. 1) Step 1: We use our fast stochastic spectral simulator [28], [29] to extract a surrogate model for each block yi = fi (ξ~i ), with ξ~i ∈ Rdi , i = 1, · · · , q. (11) With the surrogate models, yi can be evaluated very rapidly. Note that other techniques [18], [31], [48] can also be utilized to build surrogate models. For numerical stability, we define ζi = (yi − ai )/bi = fˆi (ξ~i ) (12) Vdd r h L Higher-Level Eq. y1 surrogate model ... ξ1 r lower-level parameters Fig. 4. yq yi surrogate model r ... V1 Cm ξi lower-level parameters lower-level parameters Mn (13) Again, we use the stochastic testing algorithm [28]–[30] to solve efficiently this system-level stochastic problem. Stochastic Galerkin and stochastic collocation can be utilized as well. Note that (13) can be either an algebraic or a differential equation, depending on the specific problems. B. Numerical Implementation The main challenge of our hierarchical uncertainty quantification flow lies in Step 2. As shown in Section II, in order to employ stochastic testing, we need the univariate generalized polynomial basis functions and Gauss quadrature rule of ζi , which are not readily available. Let ρ(ζi ) be the probability density function of ζi , then we first construct p + 1 orthogonal polynomials πj (ζi ) via [39] πj+1 (ζi ) = (ζi − γj ) πj (ζi ) − κj πj−1 (ζi ), π−1 (ζi ) = 0, π0 (ζi ) = 1, j = 0, · · · , p − 1 γj = R ζi πj2 (ζi )ρ(ζi )dζi R πj2 (ζi )ρ(ζi )dζi , κj+1 = V2 Cm Parameter Value Vdd 2.5V Vctrl 0-2.5V C 3.3pF R 110Ω L 2.2µH r ~ = 0, with ζ~ = [ζ1 , · · · , ζq ]. F (~h, ζ) RR L ξq such that ζi has a zero mean and unit variance. 2) Step 2: By treating ζi ’s as the new random sources, we compute ~h by solving the system-level equation R R Vctrl surrogate model Rss Demonstration of hierarchical uncertainty quantification [47]. with C 2 πj+1 (ζi )ρ(ζi )dζi RR πj2 (ζi )ρ(ζi )dζi (14) R and κ0 = 1. Here πj (ζi ) is a degree-j polynomial with leading coefficient 1. After that, the first p + 1 basis functions are obtained by normalization: πj (ζi ) , for j = 0, 1, · · · , p. φj (ζi ) = √ κ0 κ1 · · · κj (15) In order to obtain the Gauss quadrature points and weights for ζi , we first form a symmetric tridiagonal matrix J ∈ √ R(p+1)×(p+1) with Jj,j = γj−1 , Jj,j+1 = Jj+1,j = κj and other elements being zero. Let its eigenvalue decomposition be J = UΣUT , where U is a unitary matrix, then the j-th quadrature point and weight are Σj,j and u21,j , respectively [40]. From (14) it becomes obvious that both the basis functions and quadrature points/weights depend on the probability density function of ζi . Unfortunately, unlike the bottom-level random parameters ξ~i ’s that are well defined by process cards, the intermediate-level random parameter ζi does not have a Fig. 5. Mn (W/L)n 4/0.25 Iss 0.5mA Rss 106Ω Iss Schematic of a voltage-control oscillator with MEMS capacitors. given density function. Therefore, the iteration parameters γj and κj are not known. In our hierarchical stochastic simulator, this problem is solved as follows: ~i ) is smooth enough and ξ~i is of low di• When fi (ξ mensionality, we compute the integrals in (14) in the parameter space of ξ~i . In this case, the multi-dimensional quadrature rule of ξ~i is utilized to evaluate the integral. ~i ) is non-smooth or ξ~i has a high dimension• When fi (ξ ality, we evaluate this surrogate model at a large number of Monte Carlo samples. After that, the density function of ζi can be fitted as a monotone piecewise polynomial or a monotone piecewise rational quadratic function [47]. The special form of the obtained density function allows us to analytically compute γj and κj . For further details on this approach, we refer the readers to [47]. C. MEMS/IC Co-Design Example As a demonstration, we consider the voltage-controlled oscillator in Fig. 5. This oscillator has two independent identical MEMS capacitors Cm , the 3-D schematic of which is shown in Fig. 6. Each MEMS capacitor is influenced by four Gaussian-type process and geometric parameters, and the transistor threshold voltage is also influenced by the Gaussiantype temperature variation. Therefore, this circuit has nine random parameters in total. Since it is inefficient to directly solve the coupled stochastic circuit and MEMS equations, our proposed hierarchical stochastic simulator is employed. 1) Surrogate Model Extraction: The stochastic testing algorithm has been implemented in the commercial MEMS simulator MEMS+ [49] to solve the stochastic MEMS equation (10). A 3rd-order generalized polynomial-chaos expansion and 35 testing points are used to calculate the displacements, which then provide the capacitance as a surrogate model. Fig. 7 plots the density functions of the MEMS capacitor from our simulator and from Monte Carlo using 1000 samples. The results match perfectly, and our simulator is about 30× faster. 2) Higher-Level Simulation: The obtained MEMS capacitor models are normalized as done in (12) (and denoted as ζ1 and ζ2 ). A higher-level equation is constructed, which is the stochastic differential algebraic equation in (1) for (a) (b) 0.8 20 10 0 k 1 φ (τ ) Weights 0.6 0.4 −10 k=0 k=1 k=2 k=3 −20 0.2 −30 0 −5 Fig. 6. 12 x 10 13 −40 −5 6 4 2 6.15 6.2 6.25 6.3 Cm [F] 6.35 6.4 0 ζ1 5 (b) Hierarchical Monte Carlo (a) Proposed hierarchical method Proposed Monte Carlo 8 Fig. 7. 15 Fig. 8. The computed Gauss quadrature points/weights and basis functions for the intermediate-level parameter ζ1 . Schematic of the MEMS capacitor. 10 0 6.1 0 5 10 Gauss quadrature points 6.45 6.5 900 900 800 800 700 700 600 600 500 500 400 400 300 300 200 200 100 100 −13 x 10 0 2.506 2.508 2.51 2.512 2.514 2.516 2.518 2.52 period [s] −8 0 2.506 2.508 2.51 2.512 2.514 2.516 2.518 period [s] x 10 2.52 x 10 −8 Computed probability density function of MEMS capacitor Cm . Fig. 9. Histograms of the oscillator period, (a) from our hierarchical stochastic spectral simulator, (b) from hierarchical Monte Carlo [31]. this example. The constructed basis functions and Gauss quadrature points/weights for ζ1 are plotted in Fig. 8. The stochastic-testing-based periodic steady-state solver [29] is utilized to solve this higher-level stochastic equation to provide 3rd-order generalized polynomial expansions for all branch currents, nodal voltages and the oscillation period. In Fig. 9, the computed oscillator period from our hierarchical stochastic spectral simulator is compared with that from the hierarchical Monte Carlo approach [31]. Our approach requires only 20 samples and less than 1 minute for the higher-level stochastic simulation, whereas the method in [31] requires 5000 samples to achieve the similar level of accuracy. Therefore, the speedup factor of our technique is about 250×. IV. ANOVA-BASED S PARSE T ECHNIQUE Some circuit and MEMS problems cannot be simulated in a hierarchical way. When such designs have a large number of random parameters, the performance of stochastic spectral methods can significantly degrade, since the number of basis function K is a polynomial function of d. To mitigate the curse of dimensionality in high-dimensional problems, sparsity of the coefficients in generalized polynomial coefficients can be exploited. This section presents a simulation flow that exploits such sparsity using anchored ANOVA (analysis of variance). A. ANOVA and Anchored ANOVA Decomposition ~ be a performance metric of inter1) ANOVA: Let y = g(ξ) est smoothly dependent on the independent random parameters ~ Given a sample of ξ, ~ the corresponding output y can be ξ. obtained by calling a deterministic circuit or MEMS simulator. With ANOVA decomposition [32], [35], we have X ~ = y = g(ξ) gs (ξ~s ), (16) s⊆I where s is a subset of the full index set I = {1, 2, · · · , d}. Let s̄ be the complementary set of s such that s ∪ s̄ = I and s∩ s̄ = ∅ and |s| be the number of elements in s. When s = i1 , · · · , i|s| 6= ∅, we set Ωs = Ωi1 ⊗ · · · ⊗ Ωi|s| , ξ~s = [ξi1 , · · · , ξi|s| ] ∈ Ωs and have the Lebesgue measure Y dµ(ξ~s̄ ) = (ρk (ξk ) dξk ). (17) k∈s̄ Then, gs (ξ~s ) in ANOVA decomposition (16) is defined recursively by the following formula    R  ~ ~ = g0 , if s = ∅ ~ = g(ξ)dµ( ξ)  E g(ξ) Ω gs (ξ~s ) = (18) P  gt (ξ~t ) , if s 6= ∅.  ĝs (ξ~s ) − t⊂s Here ĝs (ξ~s ) = R ~ g(ξ)dµ( ξ~s̄ ), and the integration is computed Ωs̄ for all elements except those in ξ~s . From (18), we have the following intuitive results: • g0 is a constant term; ~s ) = ĝ{j} (ξj ), gs (ξ~s ) = g{j} (ξj ) = • if s={j}, then ĝs (ξ ĝ{j} (ξj ) − g0 ; ~s ) = ĝ{j,k} (ξj , ξk ) and • if s={j, k} and j < k, then ĝs (ξ gs (ξ~s ) = ĝ{j,k} (ξj , ξk ) − g{j} (ξj ) − g{k} (ξk ) − g0 ; ~s ) and gs (ξ~s ) are |s|-variable functions, and the • both ĝs (ξ decomposition (16) has 2d terms in total. Since all terms in the ANOVA decomposition are mutually orthogonal [32], [35], we have   X   ~ = Var g(ξ) Var gs (ξ~s ) (19) s⊆I where Var(•) denotes the variance over the whole parameter space Ω. What makes ANOVA practically useful is that for ~ is mainly influenced by the many engineering problems, g(ξ) terms that depend only on a small number of variables, and thus it can be well approximated by a truncated ANOVA decomposition X ~ ≈ gs (ξ~s ), s ⊆ I (20) g(ξ) |s|≤m where m ≪ d is called the effective dimension. Unfortunately, it is still difficult to obtain the truncated ANOVA decomposition due to the high-dimensional integrals in (18). 2) Anchored ANOVA: In order to avoid the expensive multidimensional integrals, [35] has proposed an efficient algorithm which is called anchored ANOVA in [33], [36], [37]. Assuming that ξk ’s have standard uniform distributions, anchored ANOVA first choses a deterministic point called anchored point ~q = [q1 , · · · , qd ] ∈ [0, 1]d , and then replaces the Lebesgue measure with the Dirac measure Y dµ(ξ~s̄ ) = (δ (ξk − qk ) dξk ). (21) k∈s̄ As a result, g0 = g(~ q ), and    qk , if k ∈ s̄ ĝs (ξ~s ) = g ξ˜s , with ξ˜k = ξk , otherwise. (22) Anchored ANOVA was further extended to Gaussian random parameters in [36]. In [33], [37], this algorithm was combined with stochastic collocation to efficiently solve highdimensional stochastic partial differential equations, where the index s was selected adaptively. B. Anchored ANOVA for Stochastic Circuit Problems In many circuit and MEMS problems, the process variations can be non-uniform and non-Gaussian. We show that anchored ANOVA can be applied to such more general cases. Observation: The anchored ANOVA in [35] can be applied if ρk (ξk ) > 0 for any ξk ∈ Ωk . Proof: Let uk denote the cumulative density function for ξk , then uk can be treated as a random variable uniformly distributed on [0, 1]. Since ρk (ξk ) > 0 for any ξk ∈ Ωk , there exists ξk = λk (uk ). Therefore, g(ξ1 , · · · , ξd ) = g (λ1 (u1 ), · · · , λd (ud )) = ψ(~u) with ~u = [u1 , · · · , ud ]. Following (22), we have  pk , if k ∈ s̄ ψ̂s (~us ) = ψ (ũs ) , with ũk = (23) uk , otherwise, where p~ = [p1 , · · · , pd ] is the anchor point for ~u. The above result can be rewritten as    λk (qk ), if k ∈ s̄ ĝs (ξ~s ) = g ξ˜s , with ξ˜k = (24) λk (ξk ), otherwise, from which we can obtain gs (ξ~s ) defined in (18). Conse~ can be obtained by using quently, the decomposition for g(ξ) ~ q = [λ1 (p1 ), · · · , λd (pd )] as an anchor point of ξ. ~ Algorithm 1 Stochastic Testing Circuit Simulator Based on Anchored ANOVA. 1: Initialize Sk ’s and set β = 0; 2: At the anchor point, run a deterministic SPICE simulation to obtain g0 , and set y = g0 ; 3: for k = 1, · · · , m do 4: for each s ∈ Sk do 5: run stochastic testing simulator to get the generalized polynomial-chaos expansion of ĝs (ξ~s ) ; 6: get the generalized polynomial-chaos expansion of gs (ξ~s ) according to (18);   7: update β = β + Var gs (ξ~s ) ; 8: update y = y + gs (ξ~s ); 9: end for 10: for each s ∈Sk do  11: θs = Var gs (ξ~s ) /β; 12: if θs < σ 13: for any index set s ′ ∈ Sj with j > k, remove s ′ from Sj if s ⊂ s ′ . 14: end if 15: end for 16: end for For a given effective dimension m ≪ d, let Sk = {s|s ⊂ I, |s| = k} , k = 1, · · · m (25) contain the initialized index sets for all k-variate terms in the ANOVA decomposition. Given an anchor point ~q and a threshold σ, our adaptive ANOVA-based stochastic circuit simulation is summarized in Algorithm 1. The index set for each level is selected adaptively. As shown in Lines 10 to 15, if a term gs (ξ~s ) has a small variance, then any term whose index set includes s as a strict subset will be ignored. All univariate terms in ANOVA (i.e., |s| = 1) are kept. Let the final size of Sk be nk and the total polynomial order in the stochastic testing simulator be p, then the total number of samples used in Algorithm 1 is N =1+ m X k=1 nk (k + p)! . k!p! (26) For most circuit problems, setting the effective dimension as 2 or 3 can achieve a high accuracy due to the weak couplings among different random parameters. For many cases, the univariate terms in ANOVA decomposition dominate the output of interest, leading to a near-linear complexity with respect to the parameter dimensionality d. C. Global Sensitivity Analysis Algorithm 1 P provides a sparse generalized polynomial-chaos ~ From this result, we can identify expansion y= yα~ Hα~ (ξ). |~ α|≤p how much each parameter contributes to the output by global sensitivity analysis. Two kinds of sensitivity information can 0.35 main sensitivity total sensitivity 0.3 0.25 0.2 0.15 0.1 0.05 0 0 5 10 15 20 25 30 35 40 45 50 Parameter index Fig. 11. Global sensitivity for the CMOS folded-cascode operational amplifier. Vdd Vb1 Ibais1 Vout Vin V. C ONCLUSION + Vb2 Vbias Fig. 10. Fig. 11 shows the computed main sensitivity and total sensitivity resulting from all device-level random parameters. Clearly, the uncertainty of the output is dominated by only a few number of device-level variations. The indices of the five device-level variations that contribute most to the output variation are 1, 50, 51, 11 and 46. Ibais2 The schematic of a CMOS folded-cascode operational amplifier. be used to measure the importance of parameter ξk : the main sensitivity Sk and total sensitivity Tk , as computed below: P P 2 |yα~ | |yα~ |2 Sk = αk 6=0,αj6=k =0 Var(y) , Tk = αk 6=0 Var(y) . (27) D. Circuit Simulation Example Consider the CMOS folded-cascode operational amplifier shown in Fig. 10. This circuit has 53 random parameters describing the device-level uncertainties (variations of temperature, threshold voltage, gate oxide thickness, channel length and width). We set p=3, m=3 and σ=0.01 for this example, aiming to extract a generalized polynomial chaos expansion for the static voltage of Vout (other quality of interest such as DC gain and total harmonic distortion can also be extracted). Directly using stochastic testing requires 27720 samples, which is too expensive on a regular workstation. Using the ANOVAbased sparse simulator, only 90 terms are needed to achieve a similar accuracy with Monte Carlo using 5000 samples: besides the constant term, only 53 univariate terms and 36 bivariate terms are computed, and no 3-variable terms are required. Our simulator uses 573 samples and less than 1-min CPU time to obtain a sparse generalized polynomial-chaos expansion with only 267 non-zero coefficients. Note that the full truncated anchored ANOVA requires 24858 terms and 482513 samples, which costs 842× more than our simulator. This paper has demonstrated a fast stochastic circuit simulator for integrated circuits and MEMS. This simulator can provide 100× to 1000× speedup over Monte Carlo when the parameter dimensionality is not high. Based on this simulator, a hierarchical stochastic spectral simulation flow has been developed. This hierarchical simulator has been tested by an oscillator with MEMS capacitors, showing high accuracy and a promising 250× speedup over hierarchical Monte Carlo. For integrated circuits with high parameter dimensionality, a sparsity-aware simulator has been further developed based on anchored ANOVA. This simulator has an almost linear complexity when the couplings among different parameters are weak and a small number of parameters dominate the output of interest. This simulator has been successfully applied to extract the sparse generalized polynomial-chaos expansion of a CMOS amplifier with over 50 random parameters, at the cost of less than 1-minute CPU time. Based on the obtained results, global sensitivity has been analyzed to identify which parameters affect the output voltage the most. ACKNOWLEDGMENT This work was supported by the MIT-SkoTech Collaborative Program and the MIT-Rocca Seed Fund. Elfadel’s work was also supported by SRC under the MEES I, MEES II, and ACE4 S programs, and by ATIC under the TwinLab program. Z. Zhang would like to thank Coventor Inc. for providing the MEMS capacitor example and the MEMS+ license. R EFERENCES [1] D. S. Boning, “Variation,” IEEE Trans. Semicond. Manuf., vol. 21, no. 1, pp. 63–71, Feb 2008. [2] S. R. Nassif, “Modeling and analysis of manufacturing variations,” in Proc. Int. Conf. Custom Integrated Circuits, Sept. 2001, pp. 223 – 228. [3] S. Weinzierl, “Introduction to Monte Carlo methods,” NIKHEF, Theory Group, The Netherlands, Tech. Rep. NIKHEF-00-012, 2000. [4] A. Singhee and R. A. Rutenbar, “Why Quasi-Monte Carlo is better than Monte Carlo or Latin hypercube sampling for statistical circuit analysis,” IEEE Trans. CAD Integr. Circuits Syst., vol. 29, no. 11, pp. 1763–1776, Nov. 2010. [5] R. Ghanem and P. Spanos, Stochastic finite elements: a spectral approach. Springer-Verlag, 1991. [6] D. Xiu, Numerical Methods for Stochastic Computations: A Spectral Method Approach. Princeton University Press, 2010. [7] O. Le Maitre and O. Knio, Spectral methods for uncertainty quantification: with application to computational fluid dynamics. Springer, 2010. [8] D. Xiu and G. E. Karniadakis, “The Wiener-Askey polynomial chaos for stochastic differential equations,” SIAM J. Sci. Comp., vol. 24, no. 2, pp. 619–644, Feb 2002. [9] D. Xiu, “Fast numerical methods for stochastic computations: A review,” Comm. in Comput. Physics, vol. 5, no. 2-4, pp. 242–272, Feb. 2009. [10] N. Wiener, “The homogeneous chaos,” American J. Math., vol. 60, no. 4, pp. 897–936, Oct 1938. [11] D. Xiu and J. S. Hesthaven, “High-order collocation methods for differential equations with random inputs,” SIAM J. Sci. Comp., vol. 27, no. 3, pp. 1118–1139, Mar 2005. [12] I. Babuška, F. Nobile, and R. Tempone, “A stochastic collocation method for elliptic partial differential equations with random input data,” SIAM J. Numer. Anal., vol. 45, no. 3, pp. 1005–1034, Mar 2007. [13] F. Nobile, R. Tempone, and C. G. Webster, “A sparse grid stochastic collocation method for partial differential equations with random input data,” SIAM J. Numer. Anal., vol. 46, no. 5, pp. 2309–2345, May 2008. [14] T. Moselhy and L. Daniel, “Stochastic integral equation solver for efficient variation aware interconnect extraction,” in Proc. Design Auto. Conf., Jun. 2008, pp. 415–420. [15] ——, “Variation-aware stochastic extraction with large parameter dimensionality: Review and comparison of state of the art intrusive and non-intrusive techniques,” in Proc. Intl. Symp. Qual. Electr. Design, Mar. 2011, pp. 14–16. [16] I. S. Stievano, P. Manfredi, and F. G. Canavero, “Parameters variability effects on multiconductor interconnects via hermite polynomial chaos,” IEEE Trans. Compon., Packag., Manuf. Tech., vol. 1, no. 8, pp. 1234– 1239, Aug. 2011. [17] J. Wang, P. Ghanta, and S. Vrudhula, “Stochastic analysis of interconnect performance in the presence of process variations,” in Proc. Design Auto Conf., 2004, pp. 880–886. [18] P. Sumant, H. Wu, A. Cangellaris, and N. R. Aluru, “Reduced-order models of finite element approximations of electromagnetic devices exhibiting statistical variability,” IEEE Trans. Antenn. Propag., vol. 60, no. 1, pp. 301–309, Jan. 2012. [19] R. S. Edwards, A. C. Marvin, and S. J. Porter, “Uncertainty analyses in the finite-difference time-domain method,” IEEE Trans. Electromagn. Compact., vol. 52, no. 1, pp. 155–163, Feb. 2010. [20] A. C. M. Austin and C. D. Sarris, “Efficient analysis of geometrical uncertainty in the FDTD method using polynomial chaos with application to microwave circuits,” IEEE Trans. Microwave Theory Tech., vol. 61, no. 12, pp. 4293–4301, Dec. 2013. [21] K. Strunz and Q. Su, “Stochastic formulation of SPICE-type electronic circuit simulation with polynomial chaos,” ACM Trans. Modeling and Computer Simulation, vol. 18, no. 4, pp. 15:1–15:23, Sep 2008. [22] J. Tao, X. Zeng, W. Cai, Y. Su, D. Zhou, and C. Chiang, “Stochastic sparse-grid collocation algorithm (SSCA) for periodic steady-state analysis of nonlinear system with process variations,” in Porc. Asia South Pacific Design Auto. Conf., 2007, pp. 474–479. [23] R. Pulch, “Modelling and simulation of autonomous oscillators with random parameters,” Math. Comput. Simul., vol. 81, no. 6, pp. 1128– 1143, Feb 2011. [24] ——, “Polynomial chaos for multirate partial differential algebraic equations with random parameters,” Appl. Numer. Math., vol. 59, no. 10, pp. 2610–2624, Oct 2009. [25] N. Agarwal and N. R. Aluru, “A stochastic Lagrangian approach for geometrical uncertainties in electrostatics,” J. Comput. Physics, vol. 226, no. 1, pp. 156–179, Sep 2007. [26] ——, “Stochastic analysis of electrostatic MEMS subjected to parameter variations,” J. Microelectromech. Syst., vol. 18, no. 6, pp. 1454–1468, Dec. 2009. [27] F. A. Boloni, A. Benabou, and A. Tounzi, “Stochastic modeling of the pull-in voltage in a MEMS beam structure,” IEEE Trans. Magnetics, vol. 47, no. 5, pp. 974–977, May 2011. [28] Z. Zhang, T. A. El-Moselhy, I. A. M. Elfadel, and L. Daniel, “Stochastic testing method for transistor-level uncertainty quantification based on generalized polynomial chaos,” IEEE Trans. CAD Integr. Circuits Syst., vol. 32, no. 10, pp. 1533–1545, Oct 2013. [29] Z. Zhang, T. A. El-Moselhy, P. Maffezzoni, I. A. M. Elfadel, and L. Daniel, “Efficient uncertainty quantification for the periodic steady state of forced and autonomous circuits,” IEEE Trans. Circuits Syst. II: Exp. Briefs, vol. 60, no. 10, pp. 687–691, Oct. 2013. [30] Z. Zhang, I. M. Elfadel, and L. Daniel, “Uncertainty quantification for integrated circuits: Stochastic spectral methods,” in Proc. Int. Conf. Computer-Aided Design. San Jose, CA, Nov. 2013, pp. 803 – 810. [31] E. Felt, S. Zanella, C. Guardiani, and A. Sangiovanni-Vincentelli, “Hierarchical statistical characterization of mixed-signal circuits using behavioral modeling,” in Proc. Int. Conf. Computer-Aided Design. Washington, DC, Nov 1996, pp. 374–380. [32] I. M. Sobol, “Global sensitivity indices for nonlinear mathematical models and their Monte Carlo estimates,” Math. Comput. in Simulation, vol. 55, no. 1-3, pp. 271–280, Feb 2001. [33] X. Yang, M. Choi, G. Lin, and G. E. Karniadakis, “Adaptive ANOVA decomposition of stochastic incompressible and compressible flows,” J. Compt. Phys., vol. 231, no. 4, pp. 1587–1614, Feb 2012. [34] X. Ma and N. Zabaras, “An adaptive high-dimensional stochastic model representation technique for the solution of stochastic partial differential equations,” J. Compt. Phys., vol. 229, no. 10, pp. 3884–3915, May 2010. [35] H. Rabitz and O. F. Alis, “General foundations of high-dimensional model representations,” J. Math. Chem., vol. 25, no. 2-3, pp. 197–233, 1999. [36] M. Griebel and M. Holtz, “An adaptive high-dimensional stochastic model representation technique for the solution of stochastic partial differential equations,” J. Compl., vol. 26, no. 5, pp. 455–489, Oct 2010. [37] Z. Zhang, M. Choi, and G. E. Karniadakis, “Error estimates for the ANOVA method with polynomial choas interpolation: tensor product functions,” SIAM J. Sci. Comput., vol. 34, no. 2, pp. A1165–A1186, 2012. [38] C.-W. Ho, A. Ruehli, and P. Brennan, “The modified nodal approach to network analysis,” IEEE Trans. Circuits Syst., vol. CAS-22, no. 6, pp. 504–509, Jun. 1975. [39] W. Gautschi, “On generating orthogonal polynomials,” SIAM J. Sci. Stat. Comput., vol. 3, no. 3, pp. 289–317, Sept. 1982. [40] G. H. Golub and J. H. Welsch, “Calculation of gauss quadrature rules,” Math. Comp., vol. 23, pp. 221–230, 1969. [41] C. W. Clenshaw and A. R. Curtis, “A method for numerical integration on an automatic computer,” Numer. Math., vol. 2, pp. 197–205, 1960. [42] L. N. Trefethen, “Is Gauss quadrature better than Clenshaw-Curtis?” SIAM Review, vol. 50, no. 1, pp. 67–87, Feb 2008. [43] S. Senturia, N. Aluru, and J. White, “Simulating the behavior of MEMS devices: Computational 3-D structures,” pp. 30–43, Jan.-Mar. 1997. [44] M. Kamon, S. Maity, D. DeReus, Z. Zhang, S. Cunningham, S. Kim, J. McKillop, A. Morris, G. Lorenz1, and L. Daniel, “New simulation and experimental methodology for analyzing pull-in and release in MEMS switches,” in Proc. Solid-State Sensors, Actuators and Microsyst. Conf., Jun. 2013. [45] G. Schröpfer, G. Lorenz, S. Rouvillois, and S. Breit, “Novel 3D modeling methods for virtual fabrication and EDA compatible design of MEMS via parametric libraries,” J. Micromech. Microeng., vol. 20, no. 6, pp. 064 003:1–15, Jun. 2010. [46] Z. Zhang, M. Kamon, and L. Daniel, “Continuation-based pull-in and lift-off simulation algorithms for microelectromechanical devices,” J. Microelectromech. Syst., vol. 23, no. 3, 2014. [47] Z. Zhang, T. A. El-Moselhy, I. M. Elfadel, and L. Daniel, “Calculation of generalized polynomial-chaos basis functions and Gauss quadrature rules in hierarchical uncertainty quantification,” IEEE Trans. CAD Integr. Circuits Syst., vol. 33, no. 5, pp. 728–740, May 2014. [48] X. Li, “Finding deterministic solution from underdetermined equation: large-scale performance modeling of analog/RF circuits,” IEEE Trans. CAD Integr. Circuits Syst., vol. 29, no. 11, pp. 1661–1668, Nov 2011. [49] “MEMS+ user’s mannual,” Coventor, Inc.
5cs.CE
arXiv:1601.01988v3 [cs.IT] 2 Jun 2017 Compressed sensing with local structure: uniform recovery guarantees for the sparsity in levels class Chen Li Courant Institute of Mathematical Sciences New York University USA Ben Adcock Department of Mathematics Simon Fraser University Canada June 5, 2017 Abstract In compressed sensing, it is often desirable to consider signals possessing additional structure beyond sparsity. One such structured signal model – which forms the focus of this paper – is the local sparsity in levels class. This class has recently found applications in problems such as compressive imaging, multi-sensor acquisition systems and sparse regularization in inverse problems. In this paper we present uniform recovery guarantees for this class when the measurement matrix corresponds to a subsampled isometry. We do this by establishing a variant of the standard restricted isometry property for sparse in levels vectors, known as the restricted isometry property in levels. Interestingly, besides the usual log factors, our uniform recovery guarantees are simpler and less stringent than existing nonuniform recovery guarantees. For the particular case of discrete Fourier sampling with Haar wavelet sparsity, a corollary of our main theorem yields a new recovery guarantee which improves over the current state-of-the-art. 1 Introduction The Restricted Isometry Property (RIP) is an important concept in compressed sensing (CS) [20, 24]. If a matrix A ∈ Cm×N satisfies an RIP then one is guaranteed stable and robust recovery of all s-sparse vectors from the measurements y = Ax. Such recovery can be achieved by a number of different algorithms, including convex optimization (ℓ1 minimization), greedy or thresholding methods. Moreover, due to a substantial body of research over the last decade, there are now large classes of matrices known to provably satisfy this property. These include not only random matrices (e.g. of Gaussian or Bernoulli type), but also many structured matrices (randomly-subsampled isometries or random convolutions, for example [27]). Although sparsity is by far the most predominant model in CS, there has also been a significant amount of research focusing on more structured signal models. See [3, 9, 33, 23, 32, 36] and references therein. The motivations for this are largely twofold. First, sparsity has been shown to not be the right model for some existing applications of CS. Hence to explain its empirical success in such cases one needs to work with other signal models. Second, if the object to recover is known a priori to possess more structure than sparsity alone, i.e. it belongs to a structured sparsity class, then it can be highly beneficial to leverage such additional structure to enhance reconstruction accuracy. This can be achieved through either the recovery algorithm (so-called structured recovery techniques) or, when possible, through the design of the measurement matrix A (so-called structured sampling techniques [4]). 1 1.1 Aim of the paper Amongst the various models of structured sparsity, the concern of this paper is the so-called local sparsity in levels model, introduced in [3]. Given a set of r levels (a partition of the indices {1, . . . , N }), rather than considering the global sparsity s of a vector x ∈ CN in this model one considers a vector of r sparsities s = (s1 , . . . , sr ), where sk is the sparsity of x restricted to the kth level. Although such levels can be chosen arbitrarily, this model is particularly relevant when x is a vector of wavelet coefficients of a signal or image. In this case, the levels are taken to be wavelet scales and sk counts the number of nonzero coefficients in the kth scale. The benefit of viewing wavelet coefficients within this model rather than with the standard sparsity model is that it incorporates additional structure inherent to such coefficients. In particular, the tendency of the local sparsities sk to decrease as a fraction of the size of the scale as k increases – a property referred to as asymptotic sparsity in [3, 34]. In [3], the sparsity in levels model was analyzed for the case of a measurement matrix A ∈ Cm×N arising from randomly subsampling an arbitrary isometry U ∈ CN ×N according to an appropriate distribution. The key results proved therein are instances of nonuniform recovery guarantees in CS theory. In other words, they ensure recovery of a fixed vector x for each random draw of the matrix A. Nonuniform CS recovery guarantees do not require an RIP and typically lead to somewhat less stringent measurement conditions by several log factors [12, 24]. The purpose of this paper is to complement this work by presenting uniform recovery guarantees for such measurement matrices. We do this by showing that they satisfy an appropriate generalization of the RIP, known as the Restricted Isometry Property in Levels (RIPL). This property was introduced in [8] (see also [36]), and like the original RIP is known to be sufficient for stable and robust recovery via ℓ1 minimization. Our proof of the RIPL for subsampled isometries follows a similar route to existing arguments for proving the standard RIP for such matrices [24], albeit with some significant modifications to take into account the new model. Interestingly, the uniform recovery guarantees we derive – although less sharp in the usual sense of incurring several additional log factors – are better than the nonuniform guarantees of [3] in a number of crucial ways. In particular, they do not require so-called relative sparsities and use a simpler (and fundamentally smaller) notion of local coherence. As in [3], our main example will be the case of Fourier sampling with wavelets. In particular, we prove the uniform version of the nonuniform result proved in [5] for the discrete Haar wavelet case. 1.2 Motivations The sparsity in levels model has recently proved useful in a number of different contexts. A first example is the case of Fourier sampling with wavelets as the sparsifying transform – the typical formulation in some important applications of CS, including Magnetic Resonance Imaging (MRI) [29], radio interferometry [38], and others. Herein it can be shown (via the so-called flip test [34]) that local sparsity in levels, as opposed to global sparsity, is the correct signal model for this problem. The associated nonuniform recovery guarantees for this model derived in [3] (see also [10]) explain some key phenomena seen in such applications; notably the resolution dependence of the reconstruction and the influence of the sparsity structure on the best sampling pattern (by this, we mean the set of Fourier frequencies used). Analysis based on this model provides insight into how to optimize the sampling pattern in these types of applications, as shown practically in [37]. A second example of the usefulness of this model arises in so-called compressive imaging, with applications including single-pixel and lensless imaging, as well as fluorescence microscopy [4, 34]. In such problems one has significant freedom to design the measurement matrix A – as opposed to 2 the previous setting where Fourier measurements are prescribed by the physical sensor – with the main constraint being that A should have binary entries. Since it takes into account the varying sparsities between wavelet scales, the local sparsity in levels model is a more refined model than global sparsity. Hence, when this model is promoted through a suitable measurement matrix, e.g. a subsampled binary Walsh–Hadamard transform, it leads to substantially improved reconstructions over techniques that are based on conventional, sparsity-promoting CS measurements (e.g. random Bernoulli measurements) [34]. Note that this is even the case when the standard CS recovery algorithms are replaced by so-called structured recovery techniques: namely, techniques which promote the structured sparsity of wavelet coefficients by modifying the recovery algorithm (so-called modelbased CS and its generalizations [7, 25, 26, 35]). Although such approaches often provide some improvement, superior recovery can often be achieved through the structured sampling techniques considered in this paper. We refer to [4, 34] for further details. A third, and recent, example of the use of the sparsity in levels model is the case of multi-sensor acquisition, with application to parallel MRI. This corresponds to physical measurement systems where multiple sensors simultaneously record measurements of a single object. It transpires that optimal recovery guarantees are possible in this setting for a much broader class of sensing systems with the sparsity in levels model than with the standard sparsity model. We refer to [16, 17, 18, 19] for the details. Finally, we note that the sparsity in levels model also occurs in the problem of compressed sensing with sparsely corrupted measurements [1, 28], and has also recently been used in the analysis of sparse techniques for radar [22]. 2 Preliminaries We commence with a review of the relevant background material. 2.1 Notation Throughout k·kp denotes the ℓp -norm on CN . If p = 2 then we just write k·k and we denote the corresponding inner product by h·, ·i. We write A . B to mean there exists a constant independent of all parameters (including, we stress, the number of levels r) such that A ≤ CB, and similarly for A & B. For 1 ≤ s ≤ N , recall that a vector x ∈ CN is s-sparse if kxk0 = |supp(x)| ≤ s, where supp(x) = {j : xj 6= 0} is the support of x. As is typical, we denote the set of s-sparse vectors by Σs . For x ∈ CN , we write σs (x) = min {kx − zk1 : z ∈ Σs } , for the error of the best approximation of x by an s-sparse vector, measured in the ℓ1 norm. Let Ω ⊆ {1, . . . , N }. With slight abuse of notation, we write PΩ for both the projection PΩ ∈ CN ×N with  xj j∈Ω , x ∈ CN , (PΩ x)j = 0 otherwise and the matrix PΩ ∈ C|Ω|×N with (PΩ x)j = xj , j ∈ Ω, x ∈ CN . The precise meaning will be clear from the context. If Ω = {1, . . . , M } for some M ∈ N then we M1 merely write PM . Furthermore if Ω = {M1 + 1, . . . , M2 } we write PM = P{M1 +1,...,M2 } . 2 3 2.2 Compressed sensing with subsampled isometries Let U ∈ CN ×N be an isometry. A standard CS setup involves subsampling the rows of U uniformly at random. Specifically, let Ω ⊆ {1, . . . , N }, |Ω| = m be chosen uniformly at random and form the measurement matrix A = PΩ U . Definition 2.1 (Coherence). Let U ∈ CN ×N be an isometry. The coherence of U is the quantity µ(U ) = max i,j=1,...,N |Uij |2 . Note that N −1 ≤ µ(U ) ≤ 1. Coherence is a key quantity determining the efficiency of the measurement matrix A = PΩ U . This can be seen from the following nonuniform recovery guarantee: Theorem 2.2 (Nonuniform recovery for subsampled isometries and the sparsity model). Let U ∈ CN ×N , N ≥ 2, be an isometry and 0 < ǫ < exp(−1). Fix x ∈ CN and suppose p that Ω ⊆ {1, . . . , N }, |Ω| = m is chosen uniformly at random. Let y = PΩ U x + e where kek ≤ N/mη and suppose that x̂ is a solution of p min kzk1 subject to kPΩ U z − yk ≤ N/mη. z∈CN Then, with probability at least 1 − ǫ, we have where L = 1 + √ √ kx − x̂k . σs (x) + (1 + L s)η, log(ǫ−1 ) log(N ) , provided m & s · N · µ(U ) · log(ǫ−1 ) · log(N ). This is Theorem 4.4 of [3] (specialized to the case of one level, and slightly simplified). Note that one may obtain a rather better error estimate by using the weak RIP approach of [12]. Theorem 2.2 is termed a nonuniform recovery guarantee since it ensures the recovery of a fixed vector x for any one draw of Ω. To derive a uniform guarantee, the standard approach is to use the restricted isometry property: Definition 2.3 (Restricted Isometry Property). Let 1 ≤ s ≤ N . The sth Restricted Isometry Constant (RIC) δs of a matrix A ∈ Cm×N is the smallest δ ≥ 0 such that (1 − δ)kxk2 ≤ kAxk2 ≤ (1 + δ)kxk2 , ∀x ∈ Σs . If 0 < δs < 1 we say that A has the Restricted Isometry Property (RIP) of order s. Theorem 2.4 (Stable and robust recovery with the RIP). Suppose that A ∈ Cm×N satisfies the √ RIP of order 2s with constant δ2s < 4/ 41. Let x ∈ CN and y = Ax + e where kek ≤ η. Then for any minimizer x̂ ∈ CN of min kzk1 subject to kPΩ U z − yk ≤ η, z∈CN we have kx̂ − xk1 . σs (x) + √ 1 kx̂ − xk . √ σs (x) + η. s sη, 4 This result is Theorem√6.12 of [24]. We note in passing that the inequality can be improved to the sharp value δ2s < 1/ 2 [11]. In view of this result, to prove uniform recovery guarantees it suffices establish an RIP. The following is a typical result for subsampled isometries: Theorem 2.5 (Subsampled isometries and the RIP). Let U ∈ CN ×N be an isometry and 0 < ǫ, δ < 1. Let t1 , . . . , tm be chosen uniformly and independently from the set {1, . . . , N } and set Ω = {t1 , . . . , tm }. If  m & δ−2 · s · N · µ(U ) · log(2m) log(2N ) log 2 (2s) + log(ǫ−1 ) , then, with probability at least 1 − ǫ the matrix A = PΩ U ∈ Cm×N satisfies the RIP of order s with constant δs ≤ δ. This result is equivalent to Theorem 12.32 of [24] (specialized to the case of isometries), and is in fact a consequence of our main result (Theorem 3.1) when the number of levels r is equal to one. Note that the construction of the set Ω is slightly different to that of Theorem 2.2. This construction transpires to be easier to analyze in practice. We refer to [24, Chpt. 12] for details on different drawing models. We also remark that it is possible to improve the log factors in the main estimate somewhat. See §4 for some further discussion on this topic. 2.3 Compressed sensing with local structure: the framework of [3] The framework of [3] introduced a new structured sparsity model, wherein a vector x is allowed to have different sparsities in separate levels. The precise definition is as follows: Definition 2.6 (Sparsity in levels). For r ∈ N, let M = (M1 , . . . , Mr ), where 1 ≤ M1 < . . . < Mr = N , and s = (s1 , . . . , sr ), where sk ≤ Mk − Mk−1 for k = 1, . . . , r and M0 = 0. A vector x ∈ CN is (s, M)-sparse in levels if |supp(x) ∩ {Mk−1 + 1, . . . , Mk }| ≤ sk , k = 1, . . . , r. We denote the set of (s, M)-sparse vectors by Σs,M . Note that the vector M describes the r sparsity levels, and the vector s enumerates the local sparsities within them. In an analogous manner to the case of standard sparsity, we write σs,M (x) = {kx − zk1 : z ∈ Σs,M } , (2.1) for the error of the best approximation by an (s, M)-sparse vector. A new approach to subsampling isometries in order to promote the sparsity in levels signal model was also introduced in [3], as was a notion of local coherence that refines the usual global coherence quantity in accordance with this model. These are defined as follows: Definition 2.7 (Multilevel random subsampling). For r ∈ N, let N = (N1 , . . . , Nr ), where 1 ≤ N1 < . . . < Nr = N , and m = (m1 , . . . , mr ), where mk ≤ Nk − Nk−1 for k = 1, . . . , r, and N0 = 0. For each k = 1, . . . , r, let tk,1 , . . . , tk,mk be chosen uniformly and independently from the set {Nk−1 + 1, . . . , Nk }, and set Ωk = {tk,1 , . . . , tk,mk }. If Ω = ΩN,m = Ω1 ∪ · · · ∪ Ωr we refer to Ω as an (N, m)-multilevel subsampling scheme. To distinguish them from the sparsity levels, indexed by M, we refer to the levels indexed by N as sampling levels. Note that, similarly to as mentioned above, the probability model used in [3] was slightly different (namely, the set Ωk was chosen uniformly at random of size mk ). 5 Definition 2.8 (Local coherence in levels). Let N = (N1 , . . . , Nr ) and M = (M1 , . . . , Mr ) denote sampling and sparsity levels respectively. The (k, l)th local coherence of an isometry U ∈ CN ×N is  µk,l = µk,l (N, M) = max |Uij |2 : i = Nk−1 + 1, . . . , Nk , j = Ml−1 + 1, . . . , Ml . In [3], the local coherences are defined rather differently. Specifically, one sets µ̃k,l = µ̃k,l (N, M) = max t=1,...,r √ µk,l µk,t. (2.2) Note that µ̃k,l ≥ µk,l . It transpires that for nonuniform recovery guarantees one needs to consider (2.2), whereas, as we shall show in our main result later, in the uniform case one can work with the simpler and strictly smaller quantities µk,l . As discussed in [3], for applications of interest, e.g. Fourier sampling with wavelet sparsity, the global coherence of the corresponding matrix U is often high, meaning that it is impossible to recover s-sparse vectors by subsampling uniformly at random. However, the behaviour of the local coherence is often such that one can get near-optimal recovery guarantees for the sparsity in levels models when subsampling with a multilevel sampling scheme. To confirm this, the following nonuniform recovery guarantee was proved in [3]: Theorem 2.9 (Nonuniform recovery for subsampled isometries and the sparsity in levels model). Let U ∈ CN ×N be an isometry, N ≥ 2, and 0 < ǫ < exp(−1). Fix x ∈ CN and suppose that √ Kη and Ω = ΩN,m is an n (N, m)-multilevel subsampling scheme. Let y = P U x + e, where kek ≤ Ω o Nk −Nk−1 mk K = maxk=1,...,r and suppose that x̂ is a solution of min kzk1 subject to kPΩ U z − yk ≤ √ z∈CN Kη. Then with probability at least 1 − ǫ we have where L = 1 + √ √ kx − x̂k . σs,M (x) + (1 + L s)η, log(ǫ−1 ) log(N ) and s = s1 + . . . + sr , provided mk & (Nk − Nk−1 ) · r X l=1 µ̃k,l · sl ! · log(sǫ−1 ) · log(N ), k = 1, . . . , r, (2.3) and mk & m̂k · log(sǫ−1 ) · log(N ), where the m̂k are such that 1& r  X Nk − Nk−1 k=1 m̂k  − 1 · µ̃k,l · Sk , l = 1, . . . , r. (2.4) Here Sk = Sk (N, M, s) is as in Definition 2.10 and µ̃k,l = µ̃k,l (N, M) is as in (2.2). This theorem relies on the notion of relative sparsities, defined as follows: Definition 2.10 (Relative sparsity). Let U ∈ CN ×N be an isometry. Let N = (N1 , . . . , Nr ), M = (M1 , . . . , Mr ) and s = (s1 , . . . , sr ) define sampling levels, sparsity levels and local sparsities respectively. Then for k = 1, . . . , r the k th relative sparsity Sk = Sk (N, M, s) is given by o n N Sk (N, M, s) = max kPNkk−1 U zk2 : kzk∞ ≤ 1, |supp(z) ∩ {Ml−1 + 1, . . . , Ml }| ≤ sl , l = 1, . . . , r . 6 2.4 The case of 1D Fourier sampling with Haar wavelet sparsity As mentioned, an important instance of this general framework is that of Fourier sampling with wavelets as the sparsifying transform. To illustrate this application, we consider the discrete, onedimensional setting with the Haar wavelet basis. This example was discussed in detail in [5]. N Let N = 2r for some r ∈ N. If x = {xi }N i=1 ∈ C we define the Fourier transform as N 1 X xj exp(2πi(j − 1)ω/N ), Fx(ω) = √ N j=1 ω ∈ R, and write F ∈ CN ×N for the corresponding unitary matrix of this transform, so that F x = N/2 {Fx(ω)}ω=−N/2+1 . Let Φ ∈ CN ×N be the unitary matrix whose columns are the orthonormal Haar basis vectors on CN , and suppose that x ∈ CN is a signal with approximately sparse representation in this basis. We now seek to recover x from m noisy Fourier samples by solving the ℓ1 minimization problem min kΦ∗ zk1 subject to kPΩ F z − yk ≤ η. z∈CN Here y = PΩ F x + e and e satisfies kek ≤ η. Equivalently, if x = Φw where w ∈ CN is the vector of Haar wavelet coefficients of x, then we solve min kzk1 subject to kPΩ U z − yk ≤ η, z∈CN where U = F Φ is an isometry. Note that if ŵ is a minimizer of this problem then w ≈ ŵ provided w is sufficiently sparse, i.e. the signal x is recovered via x ≈ x̂ = Φŵ. It is well-known that the above matrix U is coherent, i.e. µ(U ) = 1. Hence choosing Ω uniformly at random gives poor reconstructions in practice. Fortunately, near-optimal recovery is possible using the setup of §2.3. To see this, we first need to define the levels N and M. As in [5], we order the Haar basis so that the first level {M0 + 1, M1 } = {1, 2} contains the coefficients of the scaling function and the mother wavelet, and subsequent levels {Mk−1 + 1, . . . , Mk } = {2k−1 + 1, . . . , 2k } contain the coefficients of the wavelets at scale k − 1. Note that this gives the following: M0 = 0, Mk = 2k , k = 1, . . . , r. (2.5) We next introduce the sampling levels. Following an idea of [13], we consider dyadic bands in frequency space. Specifically, we let W1 = {0, 1} and Wk+1 = {−2k + 1, . . . , −2k−1 } ∪ {2k−1 + 1, . . . , 2k }, k = 1, . . . , r − 1. We then choose the sampling levels N so that (after reordering the rows of F suitably) the kth level {Nk−1 + 1, . . . , Nk } corresponds to the frequencies in Wk . Note that this gives N0 = 0, Nk = 2k , k = 1, . . . , r. (2.6) Figure 1 gives an illustration of a typical sampling pattern using these levels. With this in hand, one now has the following result: Corollary 2.11 (Nonuniform recovery for the 1D Fourier/Haar wavelet system). Let N = 2r for some r ≥ 1, 0 < ǫ < exp(−1) and x ∈ CN . For each k = 1, . . . , r suppose that mk Fourier samples are drawn uniformly at random from the band Wk , where   r X   −1 2−|k−l|/2 sl  mk &  s + k  · log(sǫ ) · log(N ),  l=1 l6=k 7 (2.7) 100% 100% 100% 50% 25% W2 W1 50% W2 W3 W3 W4 25% W4 Figure 1: Dyadic bands Wk and typical sampling ratios mk /(Nk − Nk−1 ) for the multilevel sampling pattern in the case of Fourier sampling with Haar wavelets. The first two bands W1 and W2 are fully sampled, and the remainder are subsampled. As is typical in practice, more subsampling is used at higher frequencies to capture the asymptotic sparsity of the wavelet coefficients [3, 34]. for some sk ≤ M o, k = 1, . . . , r, the Mk are as in (2.5) and s = s1 + . . . + sr . Let n k − Mk−1 Nk −Nk−1 , where the Nk are as in (2.6), and suppose that y = PΩ F x + e with K = maxk=1,...,r mk √ kek ≤ Kη for some η ≥ 0. Then with probability at least 1 − ǫ any minimizer x̂ of √ min kΦ∗ zk1 subject to kPΩ F z − yk ≤ Kη. z∈CN satisfies where L = 1 + √ log(ǫ−1 ) log(N ) √ kx − x̂k . σs,M (Φ∗ x) + (1 + L s)η, and σs,M is as in (2.1). This is Theorem 2 of [5]. The result follows from Theorem 2.9 after determining appropriate estimates for the local coherences µ̃k,l (N, M) and relative sparsities Sk (N, M, s) for the Fourier/wavelets matrix. These are as follows: µ̃k,l (N, M) . 2−k 2−|k−l|/2 , and Sk (N, M, s) . r X k, l = 1, . . . , r, 2−|k−l|/2 sl . l=1 See [5, eqn. (12)] and [5, eqn. (17)] respectively. The main estimate (2.7) states that the number of measurements mk required in the kth sampling band is proportional to the number of nonzero coefficients in the corresponding wavelet scale plus exponentially-decaying coupling terms. The appearance of these terms is due to interference between wavelet scales [5]. Specifically, the matrix U , although dominated by its diagonal blocks, is not exactly block-diagonal. Hence in the kth sampling level there are contributions from not only the corresponding kth sparsity level, but also all other levels. Note that the optimal recovery guarantee in this setup would be mk & sk (up to log factors), and this would have resulted had U been exactly block diagonal. 2.5 The restricted isometry property in levels This paper is devoted to proving uniform recovery guarantees for the sparsity in levels model combined with the framework of local coherence in levels and multilevel random subsampling. 8 Much as in standard, sparsity-based CS, this will be done by establishing the following generalized RIP condition: Definition 2.12 (RIP in levels). Let M = (M1 , . . . , Mr ) be sparsity levels and s = (s1 , . . . , sr ) be local sparsities. The sth restricted isometry constant in levels (RICL) δs,M of a matrix A ∈ Cm×N is the smallest δ ≥ 0 such that (1 − δ)kxk2 ≤ kAxk2 ≤ (1 + δ)kxk2 , ∀x ∈ Σs,M . If 0 < δs,M < 1 we say that the matrix A satisfies the Restricted Isometry Property in levels (RIPL) of order (s, M). The RIPL was first introduced in [8]. Analogous to Theorem 2.4, it implies stable and robust recovery of ℓ1 minimization (see [8, Thm. 4.4]): Theorem 2.13 (Stable and robust recovery with the RIPL). Suppose that A ∈ Cm×N satisfies the RIPL of order (2s, M) with constant where δ2s,M < q 1 r ρ = ρs,M = √ , 2 ρ + 1/4 + 1 max {sk /sl }. k,l=1,...,r (2.8) (2.9) Let x ∈ CN and y = Ax + e where kek ≤ η. Then, for any minimizer x̂ ∈ CN of min kzk1 subject to kAz − yk ≤ η, z∈CN (2.10) we have kx̂ − xk1 . σs,M (x) + and where s = s1 + . . . + sr . √ sη,  σ (x)  s,M √ kx̂ − xk . 1 + (rρ)1/4 + (1 + (rρ)1/4 )η, s (2.11) Note that this result implies the standard RIP result Theorem 2.4, which corresponds to the case r = 1. As discussed in [8], the asymptotic scaling of the right-hand side of (2.8) with both r and ρ is optimal. The same is true of (2.11). The appearance of the sparsity ratio ρ in these estimates is particularly unfortunate. Fortunately, as shown recently in [36], it can be removed by replacing the ℓ1 minimization term in the optimization problem (2.10) by a weighted ℓ1 minimization functional of the form r X 1 M (2.12) P k−1 z . √ s k Mk 1 k=1 In other words, the entries of z in the kth sparsity level are weighted by the corresponding local sparsity sk in that level. 9 3 Main results Our main results identify sufficient conditions under which an isometry, subsampled according to a multilevel subsampling scheme and scaled in a way below, satisfies the RIPL. The scaling is as follows. Given an isometry U ∈ CN ×N and a multilevel subsampling scheme Ω = ΩN,m = Ω1 ∪ · · · ∪ Ωr , we define the matrix  √  1/ p1 PΩ1 U  1/√p2 PΩ U  2   m = m1 + . . . + mr , (3.1) A=  ∈ Cm×N , ..   . √ 1/ pr PΩr U where pk = mk Nk −Nk−1 for k = 1, . . . , r. Our first result is now as follows: Theorem 3.1 (Subsampled isometries and the RIPL I). Let U ∈ CN ×N be an isometry, r ∈ N and 0 < ǫ, δ < 1. Let Ω = ΩN,m be an (N, m)-multilevel subsampling scheme, and M and s be sparsity levels and local sparsities respectively. Suppose that ! r X  mk & δ−2 · (Nk − Nk−1 ) · µk,l · sl · r log(2m) log(2N ) log 2 (2s) + log(ǫ−1 ) , (3.2) l=1 for k = 1, . . . , r, where m = m1 + . . . + mr . Then with probability at least 1 − ǫ, the matrix (3.1) satisfies the RIPL of order (s, M) with constant δs,M ≤ δ. The proof of this theorem is given in §4. It is informative to compare the main condition (3.2) to those of the nonuniform recovery guarantee of Theorem 2.9. First, note that the relative sparsities Sk , which are required in the nonuniform case through (2.4), are no longer needed in the uniform condition (3.2). This greatly simplifies matters in practice, since the relative sparsities require a nontrivial estimation that depends crucially on the choice of U (see [5] for the Fourier/Haar wavelet case). Second, besides the log factors, the condition (3.2) is smaller than the corresponding condition (2.3) since it involves the local coherences µk,l as opposed to the strictly larger quantities µ̃k,l defined in (2.2). This observation will be of particular relevance in the Fourier/Haar wavelet case, as it will lead to a better estimate than the corresponding nonuniform recovery guarantee (Corollary 2.11). We will discuss this further in §3.1. On the other hand, due to Theorem 2.13 the uniform recovery guarantee also requires δ−2 & rρ (or δ−2 & r if the weighted regularizer (2.12) is used). Thus, (3.2) effectively implies a quadratic scaling with the number of levels r, in contrast to the nonuniform condition which is independent of r. We discuss this point further in §3.3. Theorem 3.1 is in fact a particular instance of the following more general result: Theorem 3.2 (Subsampled isometries and the RIPL II). Let U ∈ CN ×N be an isometry, r ∈ N, 0 < ǫ, δ < 1 and 0 ≤ r0 ≤ r. Let Ω = ΩN,m be an (N, m)-multilevel subsampling scheme, and M and s be sparsity levels and local sparsities respectively. Suppose that mk = Nk − Nk−1 , and mk & δ −2 · (Nk − Nk−1 ) · r X l=1 µk,l · sl ! k = 1, . . . , r0 ,  · r log(2m̃) log(2N ) log 2 (2s) + log(ǫ−1 ) for k = r0 + 1, . . . , r, where m̃ = mr0 +1 + . . . + mr . Then with probability at least 1 − ǫ the matrix (3.1) satisfies the RIPL of order (s, M) with constant δs,M ≤ δ. We shall discuss the significance of this result in §3.2. 10 3.1 Uniform recovery for 1D Fourier sampling with Haar wavelet sparsity Consider the setup introduced in §2.4. The following result is a uniform counterpart to the nonuniform guarantee Corollary 2.11: Corollary 3.3 (RIPL for the 1D Fourier/Haar system I). Let N = 2r for some r ≥ 1 and 0 < ǫ, δ < 1. For each k = 1, . . . , r suppose that mk Fourier samples are drawn randomly from the band Wk , where   r X    2 2 −1 s + mk & δ−2 ·  2−|k−l| sl  k   · log(2m) log (2N ) log (2s) + log(ǫ ) , k = 1, . . . , r, (3.3) l=1 l6=k for some sk ≤ Mk − Mk−1 , k = 1, . . . , r, the Mk are as in (2.5), s = s1 + . . . + sr and m = m1 + . . . + mr . Then with probability at least 1 − ǫ the scaled matrix (3.1) satisfies the RIPL with constant δs,M ≤ δ. Proof. In [5, Lem. 1] it was proved that µk,l . 2−k 2−|k−l| . Since Nk − Nk−1 ≤ 2k (see (2.6)) we have ! r r X X (Nk − Nk−1 ) · µk,l · sl . 2−|k−l| sl . l=1 l=1 We now apply Theorem 3.1, noting that r = log2 (N ) . log(2N ). Upon comparison with the nonuniform result Corollary 2.11, we see that the effect of the interference between separate sparsity levels is substantially smaller in the uniform case. Namely, the dependence on sl in (3.3) scales like 2−|k−l| as opposed to 2−|k−l|/2 in (2.7). Corollary 3.4 (RIPL for the 1D Fourier/Haar system II). Let N = 2r for some r ≥ 1 and 0 < ǫ, δ < 1. For some 0 ≤ r0 ≤ r suppose that the first r0 frequency bands W1 , . . . , Wr0 are fully sampled, i.e. mk = Nk − Nk−1 = 2max{k−1,1} , k = 1, . . . , r0 , and suppose that for k = r0 + 1, . . . , r, mk Fourier samples are drawn randomly from the band Wk , where   r X    2 2 −1 2−|k−l| sl  mk & δ−2 ·  s +  · log(2m̃) log (2N ) log (2s) + log(ǫ ) ,  k l=r0 +1 l6=k for some sk ≤ Mk − Mk−1 , k = r0 + 1, . . . , r, where the Mk are as in (2.5), s = s1 + . . . + sr and m̃ = mr0 +1 + . . . + mr . If Nr0 ≤ sr0 +1 then with probability at least 1 − ǫ the scaled matrix (3.1) satisfies the RIPL with constant δs,M ≤ δ, where s = (s1 , . . . , sr ) and sk = Nk − Nk−1 = 2max{k−1,1} for k = 1, . . . , r0 . Proof. We apply Theorem 3.2. Due to the estimates Nk − Nk−1 ≤ 2k , µk,l . 2−k 2−|k−l| and the 11 fact that k > r0 , we have (Nk − Nk−1 ) · r X l=1 µk,l · sl ! . r X l=1 . r0 X 2−|k−l| · sl 2l−k 2 + l=1 . 22r0 −k + r X 2−|k−l| · sl l=r0 +1 r X −|k−l| 2 l=r0 +1 r0 −k ≤ sr0 +1 2 . r X l=r0 +1 + r X l=r0 +1 · sl 2−|k−l| · sl 2−|k−l| · sl , where in the penultimate step we use the fact that 2r0 = Nr0 ≤ sr0 +1 . 3.2 Why Fourier sampling with wavelets is superior to incoherent sampling As mentioned in §1, when wavelets are used as the sparsifying transform one can obtain superior reconstructions in practice using multilevel subsampled Fourier measurements than with classical incoherent sampling (e.g. random Gaussian measurements). Corollary 3.4 gives some theoretical justification for this empirical observation. To see wny, we first recall that the number random Gaussian measurements sufficient for the standard RIP is  m & δ−2 · s · log(eN/s) + log(ǫ−1 ) , (3.4) (this, of course, implies the RIPL)1 . By means of comparison, if we sum (3.3) over k we obtain m = m1 + . . . + mr & δ−2 · s × log factors, (3.5) which has the same scaling in terms of s as (3.4), and turns out to be slightly worse in terms of the log factors. However, now suppose the first r0 levels are fully sampled. Then, applying Corollary 3.4 instead we arrive at the condition m ≥ Nr0 + C · δ−2 · (sr0 +1 + . . . + sr ) × log factors, (3.6) where C is a constant. Recall that wavelet coefficients tend not to be sparse in the first few, i.e. r0 , coarsest scales, yet most of the energy of the signal is contained in these coefficients. The guarantee (3.6) shows that the nonsparse portion of the wavelet coefficients can be recovered by Fourier sampling using an optimal number of measurements equal to exactly Nr0 ; in particular, free 1 We note in passing that the slightly weaker condition m & δ −2 P r k=1 sk log  e(Mk −Mk−1 ) sk   + log(ǫ−1 ) suffices for an m × N Gaussian randommatrix to have the RIPL. This follows from [21, Cor. 5.4], noting that the Σs,M is a    Q Qr Mk − Mk−1 e(Mk −Mk−1 ) sk ≤ rk=1 subspaces of dimension at most s. However, this bound union of k=1 s k sk does not change the conclusion of the ensuing discussion significantly. 12 from universal constants and possible log factors. In comparison, Gaussian random measurements (or similar) cannot recover the majority of the signal’s energy anywhere near as efficiently.2 It is for this reason that multilevel subsampling of Fourier matrices substantially outperforms random Gaussian sampling in practice for wavelet-based signal and image reconstruction. Note that a similar observation has also been made in [33]. We refer also to [34] for a thorough empirical comparison between incoherent sampling and structured multilevel Fourier subsampling. 3.3 Further discussion In §3.1 we have seen an example where, up to log factors, the uniform recovery guarantees implied by Theorem 3.1 is strictly smaller than the nonuniform guarantee of Theorem 2.9. However, this need not always be the case, as we now discuss. To this end, let N = rn for some n, r ≥ 2 and U be a block diagonal matrix U = (U (1) , . . . , U (r) ), where for each k, the kth diagonal block U (k) ∈ Cn×n is an isometry. For simplicity, we assume that each U (k) is incoherent, i.e. nµ(U (k) ) . 1. It is a straightforward exercise to show that the measurement condition (2.3) of the nonuniform recovery guarantee (Theorem 2.9) reduces to mk & sk · log(sǫ−1 ) · (log(r) + log(n)) , k = 1, . . . , r. (3.7) On the other hand, the measurement condition (3.2) in the RIPL guarantee (Theorem 3.1) is  mk & δ−2 · sk · r log(m) (log(r) + log(n)) log2 (s) + log(ǫ−1 ) , k = 1, . . . , r. (3.8) Of course, when U is block diagonal the problem of recovering x ∈ CN decouples into r subproblems N of recovering the vectors x(k) = PNkk−1 x from measurements y (k) = PΩk U (k) x(k) . As discussed in [12], coherence provides an informatic-theoretic limit, meaning that the minimum number of measurements mk in the kth subproblem has to be of order sk · log(n). Hence the nonuniform measurement condition (3.7) is optimal, up to the logarithmic term in the failure probability log(sǫ−1 ), provided r . n. Conversely, even under the assumption r . n, the uniform measurement condition (3.8) fails to be optimal. First, there is additional logarithmic factor log(m) log2 (s). This, however, is not an artefact of the sparsity in levels model per se, but rather a factor identical to one well-known in classical RIP guarantees for subsampled isometries. See §4 for some further discussion. On the other hand, (3.8) also exhibits a linear dependence on r that is not seen in (3.7). And moreover, while δ−2 & 1 is sufficient for the classical RIP (Theorem 2.4), for the RIPL one requires δ−2 & ρr, where ρ is the sparsity ratio (2.9) (see Theorem 2.13). Note that ρ could be removed via the modified regularizer (2.12), but that still leaves an overall quadratic dependence on the number of levels r in the measurement condition. Naturally, this scaling is not sharp for the above problem. The separability implies that the measurement condition required for uniform recovery of each x(k) is no more than mk & sk · (log(m) log(n) log2 (s) + log(ǫ−1 )), i.e. independent of r. This discussion raises the question of whether the scaling in r can be removed. We offer some further comments on this topic in §5. 2 It is worth noting that in the case of (3.4) the requirement on δ for stable and robust recovery is δ . 1 (recall √ Theorem 2.4). Conversely, in (3.5) and (3.6) the requirement is δ . 1/ rρ (see Theorem 2.13), i.e. δ −2 & rρ. Since r N = 2 , the r term contributes an additional log(N ) factor to the measurement condition. The ρ term, equal to maxk,l=1,...,r {sk /sl }, could potentially blow up depending on the local sparsities sk . However, as discussed in §2.5, this term can be removed by considering the weighted ℓ1 minimization functional (2.12). 13 4 Proof of Theorem 3.2 The proof of Theorem 3.2 is a generalization of that formulated in [31] for the standard RIP for so-called bounded orthonormal systems. See [24] for a historical overview. The general strategy is as follows. First, we use Dudley’s inequality to bound the expectation of the RICL δs,M in terms of an integral of the covering numbers of the set of unit (s, M)-sparse vectors. These covering numbers are estimated for small and large values of the covering radius t (the latter via Maurey’s method), leading to an overall bound for E(δs,M ). In the second step, we use a deviation inequality to bound the probability of δs,M differing from its expectation. Combined with the first step, this results in the required probabilistic bound for the event δs,M ≤ δ. Note that there have been a number of subsequent developments in proving the classical RIP for bounded orthonormal systems, leading to somewhat smaller log factors in the recovery guarantees [6, 14, 32]. Due to the additional complications of the sparsity in levels signal model, we have so far not found these approaches to be successful in proving RIPL results. We also note the recent work of [15] in which an improvement of one log factor in s is obtained, at the expense of a worse scaling in δ. Since δ−2 in our case is required to behave like rρ, where r is the number of levels and ρ is the sparsity ratio (recall Theorem 2.13), we opt not to follow this approach. 4.1 Setup Let U ∈ CN ×N be an isometry. Define the sampling levels N = (N1 , . . . , Nr ), sparsity levels M = (M1 , . . . , Mr ), sparsities s = (s1 , . . . , sr ) and local numbers of samples m = (m1 , . . . , mr ), where Nr = Mr = N and mk = Nk − Nk−1 for k = 1, . . . , r0 . For k = 1, . . . , r0 , let tk,i = Nk−1 + i, i = 1, . . . , mk . Conversely, for each k = r0 +1, . . . , r, draw mk numbers tk,1 , . . . , tk,mk independently and uniformly at random from the set {Nk−1 + 1, . . . , Nk }. Note that such numbers need not be distinct. Let Ωk = {tk,1 , . . . , tk,mk }, k = 1, . . . , r, and write Ω = Ω1 ∪ · · · ∪ Ωr for the corresponding (m, N)-multilevel random subsampling pattern. Consider the rescaled matrix   √ 1/ p1 PΩ1 U  1/√p2 PΩ U  2   m = m1 + . . . + mr , A=  ∈ Cm×N , ..   . √ 1/ pr PΩr U mk . Note that pk = 1 and Ωk = {Nk−1 + 1, . . . , Nk } for k = 1, . . . , r0 . where pk = Nk −N k−1 We first observe that the matrix PΩk can be written as PΩk = mk X etk,i e∗tk,i , i=1 N where {ei }N i=1 is the standard basis on C . It now follows that A∗ A = mk mk r r r X X X X 1 X 1 ∗ ∗ Xk,i Xk,i , U ∗ etk,i e∗tk,i U = U ∗ PNr0 U + U PΩk U = pk pk k=1 k=1 k=r0 +1 i=1 i=1 14 (4.1) where Xk,i are random vectors given by Xk,i = and also that ∗ √1 U ∗ et . k,i pk mk r X X ∗ E(A A) = U PNr0 U + ∗ E Xk,i Xk,i k=r0 +1 i=1 ∗ = U PNr0 U + r X k=r0 +1 ∗ = U PNr0 U + U ∗ Note that the Xk,i are independent,  mk pk (Nk − Nk−1 ) Nk X U ∗ ej e∗j U j=Nk−1 +1 PN⊥r0 U = U ∗ U = I. (4.2) Here, in the second equality we use the fact that tk,i is a random variable taking values j ∈ 1 {Nk−1 + 1, . . . , Nk } with equal probability Nk −N . Let Ds,M be the set of (s, M)-sparse vectors k−1 2 with ℓ -norm at most one. That is to say [ Ds,M = B∆ , (4.3) ∆∈Es,M where and Es,M = {∆ ⊆ {1, . . . , N } : |∆ ∩ {Mk−1 + 1, . . . , Mk }| ≤ sk , k = 1, . . . , r} ,  B∆ = ξ ∈ CN : kξk ≤ 1, supp(ξ) ⊆ ∆ , ∆ ⊆ {1, . . . , N }. We now define the following seminorm on CN ×N : (4.4) |||B|||s,M := sup |hBz, zi| . z∈Ds,M It follows that the restricted isometry constant in levels δs,M satisfies δs,M = |||A∗ A − I|||s,M , and due to (4.1) and (4.2) we may rewrite this as δs,M = mk r X X k=r0 +1 i=1 4.2  ∗ ∗ Xk,i Xk,i − E(Xk,i Xk,i ) . (4.5) s,M Estimation of E(δs,M ) By symmetrization (see [24, Lem. 8.4]), we have E (δs,M ) ≤ 2E mk r X X ∗ ǫk,i Xk,i Xk,i k=r0 +1 i=1 , s,M where {ǫk,i : i = 1, . . . , mk , k = r0 + 1, . . . , r} is a Rademacher sequence (i.e. a sequence of independent random variables each taking the values +1 and −1 with equal probability) independent of the sampling points {tk,i : i = 1, . . . , mk , k = r0 + 1, . . . , r}. By definition Eǫ mk r X X k=r0 +1 i=1 ∗ ǫk,i Xk,i Xk,i = Eǫ sup mk r X X u∈Ds,M k=r +1 i=1 0 s,M 15 ǫk,i |hXk,i , ui|2 . Conditional on the Xk,i , this is the supremum of the absolute value of the Rademacher process mk r X X Zu = k=r0 +1 i=1 ǫk,i |hXk,i , ui|2 , u ∈ Ds,M , (4.6) with corresponding pseudometric  mk r X X d(u, v) =  k=r0 +1 i=1 Observe that |hXk,i , ui|2 − |hXk,i , vi|2 2 1/2  2 |hXk,i , ui|2 − |hXk,i , vi|2  , = (|hXk,i , ui| − |hXk,i , vi|)2 (|hXk,i , ui| + |hXk,i , vi|)2 ≤ |hXk,i , u − vi|2 (|hXk,i , ui| + |hXk,i , vi|)2  ≤ 2|hXk,i , u − vi|2 |hXk,i , ui|2 + |hXk,i , vi|2 , and therefore d(u, v) ≤ 2R where u, v ∈ CN . max |hXk,i , u − vi|, max k=r0 +1,...,r i=1,...,mk v v u u X mk r u X u u R = sup t |hXk,i , zi|2 = t z∈Ds,M k=r0 +1 i=1 mk r X X ∗ Xk,i Xk,i k=r0 +1 i=1 . (4.7) s,M If we define the seminorm kukX = u ∈ CN , max |hXk,i , ui|, max k=r0 +1,...,r i=1,...,mk then d(u, v) ≤ 2Rku − vkX , (4.8) and we see that the rescaled process Zu /(2R) satisfies  E |Zu /(2R) − Zv /(2R)|2 Dudley’s inequality [24, Thm. 8.23] now gives Eǫ mk r X X k=r0 +1 i=1 ∗ ǫk,i Xk,i Xk,i 1/2 ≤ ku − vkX . = 2REǫ sup |Zu /(2R)| u∈Ds,M s,M √ Z ≤ 8 2R √ Z ≤ 8 2R where ∆(Ds,M ) = 0 0 ∆(Ds,M )/2 q ∆(Ds,M )/2 q log(2N (Ds,M , d/(2R), t)) dt log(2N (Ds,M , k·kX , t)) dt p 1 E|Zu |2 , sup 2R u∈Ds,M 16 (4.9) and Zu is as in (4.6). Here, in the second inequality we use the fact that N (T, d, t) ≤ N (T, d′ , t) whenever d(u, v) ≤ d′ (u, v), ∀u, v ∈ T (see [24, §C.2]). Observe that ∆(Ds,M ) ≤ sup kukX by u∈Ds,M (4.8). Also, by definition of the Xk,i , we have kukX = max max k=r0 +1,...,r i=1,...,mk 1 √ |hU ∗ etk,i , ui| pk M r 1 X Xl |Utk,i ,j ||uj | √ k=r0 +1,...,r i=1,...,mk pk l=1 j=Ml−1 v u Ml r X X √ u 1 √ |uj |2 ≤ max √ µk,l sl t k=r0 +1,...,r pk j=Ml−1 l=1 v u r p uX µk,l sl kuk = Qkuk, ≤ max t k=r0 +1,...,r pk ≤ max max (4.10) k=1 (note that the fourth line follows from the Cauchy–Schwarz inequality), where Q is defined by Q= max k=r0 +1,...,r Since kuk ≤ 1 for u ∈ Ds,M we get ∆(Ds,M ) ≤ Eǫ mk r X X ∗ ǫk,i Xk,i Xk,i k=r0 +1 i=1 √ l=1 pk . (4.11) Q, and therefore √ Z ≤ 8 2R 0 s,M r X µk,l sl √ Q/2 q log(2N (Ds,M , k·kX , t)) dt. (4.12) To estimate this integral we next bound the covering number in the small t and large t regimes respectively. 4.2.1 Estimate of the covering number N (Ds,M , k·kX , t) for small t Recalling (4.3) and standard properties of covering numbers, we notice that X N (Ds,M , k·kX , t) ≤ N (B∆ , k·kX , t), ∆∈Es,M where B∆ is as in (4.4). Using the bound (4.10) and several further properties of covering numbers, we find that 2|∆| X  X p p 1 + 2 Q/t . N (Ds,M , k·kX , t) ≤ N (B∆ , k·k, t/ Q) ≤ ∆∈Es,M ∆∈Es,M   N , where s = s1 + . . . + sr . Hence s   2s 2s  p p N  1 + 2 Q/t N (Ds,M , k·kX , t) ≤ ≤ (exp(1)N/s)s 1 + 2 Q/t , s Note that |∆| ≤ s and |Es,M | ≤ which gives the bound ! r  q  p p √ log (2N (Ds,M , k·kX , t)) ≤ 2s log(2 exp(1)N/s) + log 1 + 2 Q/t , 17 t > 0. (4.13) 4.2.2 Estimate of the covering number N (Ds,M , k·kX , t) for large t We use Maurey’s method. Let x ∈ Ds,M and write x = x(1) + . . . + x(r) , where kx(k) k0 ≤ sk . supp(xk ) ⊆ {Mk−1 + 1, . . . , Mk }, Note that kxk2 = defined by Pr k=1 kx (k) k2 and in particular, kx(k) k ≤ 1 for each k = 1, . . . , r. Let k·k∗1 be kzk∗1 = N X i=1 z ∈ CN , (|Re (zi )| + |Im (zi )|) , which is the usual ℓ1 -norm after identifying CN with R2N . Observe that kx(k) k∗1 ≤ we may write x(k) as the convex combination 4(Mk −Mk−1 ) X x(k) = √ 2sk . Hence (k) (k) λ j vj , j=1 (k) where the vectors vj are an enumeration of the 4(Mk − Mk−1 ) vectors √ √ √ √ + 2sk ei , − 2sk ei , +i 2sk ei , −i 2sk ei , i = Mk−1 + 1, . . . , Mk . (k) Let Z (1) , . . . , Z (r) be independent random vectors such that Z (k) takes value vj with probability P4(M −M ) (k) (k) (k) λj . Since λj ≥ 0 and j=1 k k−1 λj = 1 this defines a valid probability distribution for each k. Note that −Mk−1 ) r r 4(MkX r X X X (k) (k) (k) x(k) = x. λj vj = Z = E j=1 k=1 k=1 k=1 (k) (k) Let R1 , . . . , Rr ∈ N be integers whose values will be fixed later. For each k, let Z1 , . . . , ZRk be independent copies of Z (k) , and consider the sum z= Rk r X 1 X Z (k) . Rk q=1 q k=1 By symmetrization, we now have Ekz − xkX = E ≤ 2E ≤ 2E Rk  r  X 1 X Zq(k) − EZq(k) Rk q=1 k=1 r X k=1 1 Rk max Rk X X (k) ǫ(k) q Zq q=1 X max l=r0 +1,...,r i=1,...,ml (k) r X k=1 Rk 1 X ǫ(k) hXl,i , Zq(k) i , Rk q=1 q (k) where {ǫq : q = 1, . . . , Rk , k = 1, . . . , r} is a Rademacher sequence independent of the Zq . Fix a (k) (k) (k) realization of the Zq . Recall that Xl,i = √1pl U ∗ etl,i and that each Zq is equal to vj for some 18 j = 1, . . . , 4(Mk − Mk−1 ). Therefore Rk Rk r r r X X 2sk µl,k 1 X 2 X sk µl,k 1 X (k) 2 |hXl,i , Zq i| ≤ = , pl Rk Rk2 q=1 Rk2 q=1 pl k=1 k=1 k=1 from which it follows that  1/2 Rk r X X √ 1 (k) 2   A, |hX , Z i| ≤ i q Rk2 q=1 A= k=1 We can now define the random variable Yl,i := r P k=1 deduce that Yi satisfies where m̃ = r P 1 Rk Rk P q=1 max l=r0 +1,...,r (k) r X 2sk µl,k k=1 p l Rk . (k) ǫq hXl,i , Zq i. Using [24, Thm. 8.8] we  √  2 Pǫ |Yl,i | ≥ Ay ≤ 2e−y /2 , y > 0, mk . By the union bound k=r0 +1 Pǫ  max |Yl,i | ≥ max √ l=r0 +1,...,r i=1,...,ml Ay  ≤ 2m̃e−y 2 /2 , y > 0, and hence [24, Prop. 7.14] gives Eǫ max max l=r0 +1,...,r i=1,...,ml Rk r X √ p 1 X (k) ǫ(k) q hXl,i , Zt i ≤ 3/2 A log(8m̃). Rk q=1 k=1 Using Fubini’s theorem, we now obtain the bound Ekx − zkX ≤ 2EZ Eǫ max max l=r0 +1,...,r i=1,...,ml Rk r X √ p 1 X (k) ǫt hXl,i , Zq(k) i ≤ 3 A log(8m̃). Rk q=1 k=1 This means that there exists a vector z of the form Rk r X 1 X Zq(k) , z= Rk q=1 k=1 with kx − zkX √ p ≤ 3 A log(8m̃). In particular, kx − zkX ≤ t/2 provided √ p 3 A log(8m̃) ≤ t/2. (4.14) Note that z can take at most (4N )R1 +...+Rr values. Hence we have constructed a set of (4N )R1 +...+Rr points such that, for any x ∈ Ds,M , we have kx − zkX ≤ t/2 for some z in the set. To construct a cover, we need the points to belong to Ds,M . As in the usual way, for each z we can find a point z ′ ∈ Ds,M with kz − z ′ kX ≤ t/2. If no such point exists then we discard that z, since it will not be needed in the cover. After doing this, we then deduce that there exists a cover of size at most (4N )R1 +...+Rr such that for any x ∈ Ds,M we have kx − zkX ≤ t for some z in the cover. Thus ! r X log(2N (Ds,M , k·kX , t)) ≤ Rk log(8N ), k=1 19 provided R1 , . . . , Rr are chosen so that (4.14) holds. To do this, we set '  &  r X 2sk µl,k 72 36 = 2 Q log(8m̃) . R1 = . . . = Rr = 2 log(8m̃) max l=r0 +1,...,r t pl t k=1 Using these values, we obtain the following bound for the covering number: q p log(2N (Ds,M , k·kX , t)) ≤ r (72Q log(8m̃)/t2 + 1) log(8N ) p √ p p ≤ 12 r Q log(8N ) log(8m̃)/t, 0 < t ≤ Q/2. √ Note that in the last step we use the fact that t ≤ Q/2 in (4.12). 4.2.3 (4.15) Overall bound for E(δs,M ) With (4.13) and √ (4.15) in hand, we return √ to (4.12). Splitting the range of integration into (0, τR) and (τ, Q/2) for some 0 < τ < Q/2 to be determined and using the integral inequalp αp log(1 + 1/t) dt ≤ α log(exp(1)(1 + 1/α)) [24, Lem. C.9], we find that ity 0 ! r  mk r  X X p p √ √ ∗ ≤8 2R ǫk,i Xk,i Xk,i Eǫ 2s log(2 exp(1)N/s) + log exp(1)(1 + 2 Q/τ ) τ k=r0 +1 i=1 We now set τ = Eǫ s,M √ ! p  √ p p + 12 r Q log(8N ) log(8m̃) log Q/(2τ ) . √ Q/(3 s) to get mk r X X ∗ ǫk,i Xk,i Xk,i k=r0 +1 i=1 ≤ CR s,M p √ p Q r log(2m̃) log(2N ) log(2s), for some constant C > 0. Hence, by (4.5), (4.7) and Fubini’s theorem we arrive at the estimate v u mk r u X X p √ p u ∗ Xk,i Xk,i . (4.16) Eδs,M ≤ C Q r log(2m̃) log(2N ) log(2s)Et k=r0 +1 i=1 Recall from (4.2) that mk r X X s,M ∗ = U ∗ PN⊥r0 U, EXk,i Xk,i k=r0 +1 i=1 and therefore mk r X X = sup kPN⊥r0 U zk2 ≤ 1, ∗ EXk,i Xk,i k=r0 +1 i=1 z∈Ds,M s,M since U is an isometry. Hence, by the Cauchy–Schwarz inequality, we have v v u u m mk  r r k u X u X X  X u u ∗ ∗ − EX X ∗ ≤ Et Xk,i Xk,i Xk,i Xk,i Et k,i k,i k=r0 +1 i=1 s,M k=r0 +1 i=1 +1≤ s,M q E (δs,M ) + 1. Combining this with (4.16) now gives E (δs,M ) ≤ D + D 2 , D=C p √ p Q r log(2m̃) log(2N ) log(2s). 20 (4.17) 4.3 Estimate for δs,M Having estimated its expectation, we are now able to provide a probabilistic bound for δs,M itself. We shall use Theorem 8.42 of [24]. What follows below is a setup to apply this result. First, (4.1) and (4.2) give that δs,M = mk r X X k=r0 +1 i=1 ∗ Xk,i Xk,i − U ∗ PN⊥r U mk  r X X = 0 k=r0 +1 i=1 s,M and therefore δs,M = sup Re (z,w)∈Q∗s,M * [ ∆∈Es,M Yk,i w, z k=r0 +1 i=1 where Q∗s,M is a countable dense subset of Qs,M = mk r X X ∗ Xk,i Xk,i − 1 ∗ Nk−1 U PNk U mk  , s,M + {(z, w) : kzk = kwk = 1, supp(z) = supp(w) ⊆ ∆} . and ∗ − Yk,i = Xk,i Xk,i Hence δs,M = 1 ∗ Nk−1 U PNk U. mk mk r X X sup fz,w (Yk,i ), (4.18) (z,w)∈Q∗s,M k=r +1 i=1 0 where fz,w are the functions given by fz,w : CN ×N → R, Y 7→ Re hY w, zi. Observe that Efz,w (Yl,i ) = 0. Also we have 1 ∗ Nk−1 U PNk U )w, zi| mk 1 ∗ Nk−1 ∗ ≤ |hXk,i Xk,i w, zi| + |h U PNk U w, zi| mk Nk X 1 1 ≤ |hetk,i , U wi|hetk,i , U zi| + |hej , U wi||hej , U zi| pk mk ∗ − |fz,w (Yk,i )| ≤ |h(Xk,i Xk,i j=Nk−1 +1 ≤ 2 pk max j=Nk−1 +1,...,Nk |hej , U wi||hej , U zi| ≤ 2Q, since |hU ∗ ej , zi| ≤ and likewise for E mk r X X k=r0 +1 i=1 |hU ∗ ej , wi|. 2 Ml X r X l=1 i=Ml−1 +1 Furthermore, we have |fz,w (Yk,i )| ≤ mk r X X k=r0 +1 i=1 E  v u r uX µk,l sl , |Uji ||zi | ≤ t ∗ Xk,i Xk,i 21 l=1 1 ∗ Nk−1 − U PNk U mk  2 w = S1 − S2 + S3 , where S1 = S2 = S3 = mk r X X k=r0 +1 i=1 mk r X X k=r0 +1 i=1 mk r X X k=r0 +1 i=1 EkXk,i P∆ k2 |hXk,i , P∆ wi|2 1 N 2Re EhXk,i , wihXk,i , U ∗ PNkk−1 U wi mk r X 1 1 N 2 ∗ Nk−1 kPNkk−1 U wk2 , U wk = kU P Nk 2 mk mk k=r0 +1 and ∆ is the support of w. Arguing as above, we note that r X |hetk,i , U ej i|2 X µk,l sl kXk,i P∆ k = ≤ ≤ Q. pk pk 2 j∈∆ k=1 Hence S1 ≤ Q mk r X X E|hXk,i , P∆ wi|2 = Q k=r0 +1 i=1 r X k=r0 +1 N kPNkk−1 U wk2 = QkPN⊥r U wk2 ≤ Q, 0 since U is an isometry. Also mk r X X 1 S2 = 2 m2k i=1 k=r0 +1 Therefore E Nk X j=Nk−1 +1 mk r X X k=r0 +1 i=1 N hej , U wihej , U U ∗ PNkk−1 U wi = 2S3 . |fz,w (Yk,i )|2 ≤ Q − S3 < Q. It now follows from [24, Thm. 8.42] (with values t = δ/2, K = 2Q, σ 2 = Q and recalling that 0 < δ < 1) and (4.18) that  P(δs,M ≥ δ) ≤ exp −3δ2 /(80Q) , provided E (δs,M ) ≤ δ/2. Rearranging and applying (4.17), we deduce that δs,M ≤ δ with probability at least 1 − ǫ, provided Qδ−2 log(ǫ−1 ) . 1, and Qδ−2 r log(2m̃) log(2N ) log 2 (2s) . 1. Recalling the definition of Q now completes the proof. 22 5 Conclusions In this paper we have established the first uniform recovery guarantee for subsampled isometries with the sparsity in levels class. This was done by deriving conditions under which the so-called restricted isometry property in levels (RIPL) holds. Interestingly, the resulting guarantees are simpler and less stringent than existing nonuniform recovery guarantees. In particular, they do not require relative sparsities (see Definition 2.10) and involve smaller local coherence factors (see Definition 2.8). For the particular case of Fourier sampling with Haar wavelets, this leads to a noticeably better recovery guarantee. There are a number of directions for future work. First, as discussed in §3.3 the quadratic scaling of the measurement condition with the number of levels r is unfortunate. Indeed, while r contributes only an additional logarithmic factor in the case of wavelets, in other problems it is crucial to have measurement conditions that are independent of r. This is case in applications to multi-sensor acquisition, for example (see [18].) We expect one power of r to be an artefact of the proof given in §4; specifically, it arises only in the estimate of the covering number for large t given in §4.2.2. Yet, as discussed in §2.5, the other power of r cannot in general be removed when considering the ℓ1 regularizer. Constructing a regularizer that avoids this factor is an interesting problem for future work. This aside, in this paper we have only considered sensing operators that arise as isometries on finite-dimensional vector spaces. Yet in a series of papers [2, 3, 34] so-called infinite-dimensional CS has been introduced. Therein the sampling operator U is an isometry on a separable, infinitedimensional Hilbert space, as opposed to CN . Nonuniform recovery guarantees for this setup were introduced in [2]. Future work will aim to extend the analysis of this paper to this infinitedimensional setup. Note that the RIPL was originally formulated in [8] only for finite-dimensional vector spaces. However, more recent work [36] has generalized this concept substantially to include possibly infinite-dimensional spaces. In terms of specific applications, in this paper we have examined the case of discrete, onedimensional Haar wavelets with Fourier sampling. Some possible extensions of this include to the multidimensional setting, to other types of wavelets, and to the continuous (as opposed to discrete) case. For the latter we refer to [3] for nonuniform recovery guarantees. Other extensions include to the setting of binary Walsh–Hadamard measurements, which are a practical alternative to multilevel subsampled Fourier measurements in compressive imaging applications [34], and to the case of redundant sparsifying transformations. See [30] for nonuniform recovery guarantees in the latter case. Furthermore, besides wavelet sparsity, the sparsity in levels model has also recently found use in so-called parallel sensing architectures, with nonuniform recovery guarantees being presented in [18]. Future work will look to generalize the results of this paper to this setting. Acknowledgements Both authors would like to thank Holger Rauhut and Mary Wootters for independently suggesting the problem tackled in this paper. BA wishes to acknowledge the support of Alfred P. Sloan Foundation and the Natural Sciences and Engineering Research Council of Canada through grant 611675. CL wishes to acknowledge the support of Professor Weiran Sun and Simon Fraser University during his research visit there from July to October 2015. 23 References [1] B. Adcock, A. Bao, J. D. Jakeman, and A. Narayan. Compressed sensing with sparse corruptions: Fault-tolerant sparse collocation approximations. arXiv:1703.00135, 2017. [2] B. Adcock and A. C. Hansen. Generalized sampling and infinite-dimensional compressed sensing. Found. Comput. Math., 16(5):1263–1323, 2016. [3] B. Adcock, A. C. Hansen, C. Poon, and B. Roman. Breaking the coherence barrier: A new theory for compressed sensing. Forum Math. Sigma, 5, 2017. [4] B. Adcock, A. C. Hansen, and B. Roman. The quest for optimal sampling: computationally efficient, structure-exploiting measurements for compressed sensing. In Compressed Sensing and Its Applications. Springer, 2015. [5] B. Adcock, A. C. Hansen, and B. Roman. A note on compressed sensing of structured sparse wavelet coefficients from subsampled Fourier measurements. IEEE Signal Process. Letters, 23(5):732–736, 2016. [6] J. Andersson and J.-O. Stromberg. On the theorem of uniform recovery of random sampling matrices. IEEE Trans. Inform. Theory, 60(3):1700–1710, 2014. [7] R. G. Baraniuk, V. Cevher, M. F. Duarte, and C. Hedge. Model-based compressive sensing. IEEE Trans. Inform. Theory, 56(4):1982–2001, 2010. [8] A. Bastounis and A. C. Hansen. On the absence of the RIP in real-world applications of compressed sensing and the RIP in levels. SIAM J. Imaging Sci., 2017 (to appear). [9] A. Bourrier, M. E. Davies, T. Peleg, P. Pérez, and R. Gribonval. Fundamental performance limits for ideal decoders in high-dimensional linear inverse problems. IEEE Trans. Inform. Theory, 60(12):7928– 7946, 2014. [10] C. Boyer, J. Bigot, and P. Weiss. Compressed sensing with structured sparsity and structured acquisition. arXiv:1505.01619, 2015. [11] T. Cai and A. Zhang. Sparse representation of a polytope and recovery of sparse signals and low-rank matrices. IEEE Trans. Inform. Theory, 60(1):122–132, 2014. [12] E. J. Candès and Y. Plan. A probabilistic and RIPless theory of compressed sensing. IEEE Trans. Inform. Theory, 57(11):7235–7254, 2011. [13] E. J. Candès and J. Romberg. Sparsity and incoherence in compressive sampling. Inverse Problems, 23(3):969–985, 2007. [14] M. Cheraghchi, V. Guruswami, and A. Velingker. Restricted isometry of fourier matrices and list decodability of random linear codes. In Proceedings of the Twenty-Fourth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 432–442. SIAM, 2013. [15] A. Chkifa, N. Dexter, H. Tran, and C. Webster. Polynomial approximation via compressed sensing of high-dimensional functions on lower sets. Math. Comp., 2017. [16] I. Y. Chun and B. Adcock. Optimal sparse recovery for multi-sensor measurements. In IEEE Inf. Theory Workshop (ITW) 2016, Cambridge, UK, Sept. 2016. [17] I.-Y. Chun and B. Adcock. arXiv:1610.05758, 2016. Uniform recovery from subgaussian multi-sensor measurements. [18] I.-Y. Chun and B. Adcock. Compressed sensing and parallel acquisition. IEEE Trans. Inform. Theory (to appear), 2017. [19] I. Y. Chun, C. Li, and B. Adcock. Sparsity and parallel acquisition: Optimal uniform and nonuniform recovery guarantees. In 1st Workshop on Sparsity and Compressive Sensing in Multimedia (MMSPARSE), IEEE Intl. Conf. on Multimedia and Expo (ICME) 2016, Seattle, WA, Jul. 2016. 24 [20] M. A. Davenport, M. F. Duarte, Y. C. Eldar, and G. Kutyniok. Introduction to compressed sensing. In Compressed Sensing: Theory and Applications. Cambridge University Press, 2011. [21] S. Dirksen. Dimensionality reduction with subgaussian matrices: a unified theory. Found. Comput. Math., 16:1367–1396, 2016. [22] D. Dorsch and H. Rauhut. Refined analysis of sparse mimo radar. J. Fourier Anal. Appl., pages 1–45, 2016. [23] M. F. Duarte and Y. C. Eldar. Structured compressed sensing: from theory to applications. IEEE Trans. Signal Process., 59(9):4053–4085, 2011. [24] S. Foucart and H. Rauhut. A Mathematical Introduction to Compressive Sensing. Birkhauser, 2013. [25] L. He and L. Carin. Exploiting structure in wavelet-based Bayesian compressive sensing. IEEE Trans. Signal Process., 57(9):3488–3497, 2009. [26] L. He, H. Chen, and L. Carin. Tree-structured compressive sensing with variational Bayesian analysis. IEEE Signal Process. Letters, 17(3):233–236, 2010. [27] F. Krahmer and H. Rauhut. Structured random measurements in signal processing. GAMM Mitt., 37(2):217–238, 2014. [28] X. Li. Compressed sensing and matrix completion with a constant proportion of corruptions. Constr. Approx., 37:73–99, 2013. [29] M. Lustig, D. L. Donoho, J. M. Santos, and J. M. Pauly. Compressed Sensing MRI. IEEE Signal Process. Mag., 25(2):72–82, March 2008. [30] C. Poon. Structure dependent sampling in compressed sensing: theoretical guarantees for tight frames. Appl. Comput. Harm. Anal., 42(3):402–451, 2017. [31] H. Rauhut. Compressive sensing and structured random matrices. In M. Fornasier, editor, Theoretical Foundations and Numerical Methods for Sparse Recovery, volume 9 of Radon Series in Computational and Applied Mathematics, pages 1–92. de Gruyter, Berlin, 2010. [32] H. Rauhut and R. Ward. Interpolation via weighted ℓ1 minimization. Appl. Comput. Harmon. Anal., 40(2):321–351, 2016. [33] B. Roman, A. Bastounis, B. Adcock, and A. C. Hansen. On fundamentals of models and sampling in compressed sensing. Preprint, 2015. [34] B. Roman, A. C. Hansen, and B. Adcock. arXiv:1406.4178, 2014. On asymptotic structure in compressed sensing. [35] S. Som and P. Schniter. Compressive imaging using approximate message passing and a markov-tree prior. IEEE Trans. Signal Process., 60(7):3439–3448, 2012. [36] Y. Traonmilin and R. Gribonval. Stable recovery of low-dimensional cones in Hilbert spaces: One RIP to rule them all. Appl. Comput. Harm. Anal. (to appear), 2017. [37] Q. Wang, M. Zenge, H. E. Cetingul, E. Mueller, and M. S. Nadar. Novel sampling strategies for sparse mr image reconstruction. Proc. Int. Soc. Mag. Res. in Med., 22, 2014. [38] Y. Wiaux, L. Jacques, G. Puy, A. M. M. Scaife, and P. Vandergheynst. Compressed sensing imaging techniques for radio interferometry. Mon. Not. R. Astron. Soc., 395(3):1733–1742, 2009. 25
7cs.IT
arXiv:1509.09292v2 [cs.LG] 3 Nov 2015 Convolutional Networks on Graphs for Learning Molecular Fingerprints David Duvenaud† , Dougal Maclaurin†, Jorge Aguilera-Iparraguirre Rafael Gómez-Bombarelli, Timothy Hirzel, Alán Aspuru-Guzik, Ryan P. Adams Harvard University Abstract We introduce a convolutional neural network that operates directly on graphs. These networks allow end-to-end learning of prediction pipelines whose inputs are graphs of arbitrary size and shape. The architecture we present generalizes standard molecular feature extraction methods based on circular fingerprints. We show that these data-driven features are more interpretable, and have better predictive performance on a variety of tasks. 1 Introduction Recent work in materials design used neural networks to predict the properties of novel molecules by generalizing from examples. One difficulty with this task is that the input to the predictor, a molecule, can be of arbitrary size and shape. Currently, most machine learning pipelines can only handle inputs of a fixed size. The current state of the art is to use off-the-shelf fingerprint software to compute fixed-dimensional feature vectors, and use those features as inputs to a fully-connected deep neural network or other standard machine learning method. This formula was followed by [28, 3, 19]. During training, the molecular fingerprint vectors were treated as fixed. In this paper, we replace the bottom layer of this stack – the function that computes molecular fingerprint vectors – with a differentiable neural network whose input is a graph representing the original molecule. In this graph, vertices represent individual atoms and edges represent bonds. The lower layers of this network is convolutional in the sense that the same local filter is applied to each atom and its neighborhood. After several such layers, a global pooling step combines features from all the atoms in the molecule. These neural graph fingerprints offer several advantages over fixed fingerprints: • Predictive performance. By using data adapting to the task at hand, machine-optimized fingerprints can provide substantially better predictive performance than fixed fingerprints. We show that neural graph fingerprints match or beat the predictive performance of standard fingerprints on solubility, drug efficacy, and organic photovoltaic efficiency datasets. • Parsimony. Fixed fingerprints must be extremely large to encode all possible substructures without overlap. For example, [28] used a fingerprint vector of size 43,000, after having removed rarely-occurring features. Differentiable fingerprints can be optimized to encode only relevant features, reducing downstream computation and regularization requirements. • Interpretability. Standard fingerprints encode each possible fragment completely distinctly, with no notion of similarity between fragments. In contrast, each feature of a neural graph fingerprint can be activated by similar but distinct molecular fragments, making the feature representation more meaningful. † Equal contribution. 1 Figure 1: Left: A visual representation of the computational graph of both standard circular fingerprints and neural graph fingerprints. First, a graph is constructed matching the topology of the molecule being fingerprinted, in which nodes represent atoms, and edges represent bonds. At each layer, information flows between neighbors in the graph. Finally, each node in the graph turns on one bit in the fixed-length fingerprint vector. Right: A more detailed sketch including the bond information used in each operation. 2 Circular fingerprints The state of the art in molecular fingerprints are extended-connectivity circular fingerprints (ECFP) [21]. Circular fingerprints [6] are a refinement of the Morgan algorithm [17], designed to encode which substructures are present in a molecule in a way that is invariant to atom-relabeling. Circular fingerprints generate each layer’s features by applying a fixed hash function to the concatenated features of the neighborhood in the previous layer. The results of these hashes are then treated as integer indices, where a 1 is written to the fingerprint vector at the index given by the feature vector at each node in the graph. Figure 1(left) shows a sketch of this computational architecture. Ignoring collisions, each index of the fingerprint denotes the presence of a particular substructure. The size of the substructures represented by each index depends on the depth of the network. Thus the number of layers is referred to as the ‘radius’ of the fingerprints. Circular fingerprints are analogous to convolutional networks in that they apply the same operation locally everywhere, and combine information in a global pooling step. 3 Creating a differentiable fingerprint The space of possible network architectures is large. In the spirit of starting from a known-good configuration, we designed a differentiable generalization of circular fingerprints. This section describes our replacement of each discrete operation in circular fingerprints with a differentiable analog. Hashing The purpose of the hash functions applied at each layer of circular fingerprints is to combine information about each atom and its neighboring substructures. This ensures that any change in a fragment, no matter how small, will lead to a different fingerprint index being activated. We replace the hash operation with a single layer of a neural network. Using a smooth function allows the activations to be similar when the local molecular structure varies in unimportant ways. Indexing Circular fingerprints use an indexing operation to combine all the nodes’ feature vectors into a single fingerprint of the whole molecule. Each node sets a single bit of the fingerprint to one, at an index determined by the hash of its feature vector. This pooling-like operation converts an arbitrary-sized graph into a fixed-sized vector. For small molecules and a large fingerprint length, the fingerprints are always sparse. We use the softmax operation as a differentiable analog of indexing. In essence, each atom is asked to classify itself as belonging to a single category. The sum of all these classification label vectors produces the final fingerprint. This operation is analogous to the pooling operation in standard convolutional neural networks. 2 Algorithm 1 Circular fingerprints 1: Input: molecule, radius R, fingerprint length S 2: Initialize: fingerprint vector f ← 0S 3: for each atom a in molecule 4: ra ← g(a) . lookup atom features 5: for L = 1 to R . for each layer 6: for each atom a in molecule 7: r1 . . . rN = neighbors(a) 8: v ← [ra , r1 , . . . , rN ] . concatenate 9: ra ← hash(v) . hash function 10: i ← mod(ra , S) . convert to index 11: fi ← 1 . Write 1 at index 12: Return: binary vector f Algorithm 2 Neural graph fingerprints 1: Input: molecule, radius R, hidden weights 5 H11 . . . HR , output weights W1 . . . WR 2: Initialize: fingerprint vector f ← 0S 3: for each atom a in molecule 4: ra ← g(a) . lookup atom features 5: for L = 1 to R . for each layer 6: for each atom a in molecule 7: r1 . . . rN =Pneighbors(a) 8: v ← ra + N . sum i=1 ri 9: ra ← σ(vHLN ) . smooth function 10: i ← softmax(ra WL ) . sparsify 11: f ←f +i . add to fingerprint 12: Return: real-valued vector f Figure 2: Pseudocode of circular fingerprints (left) and neural graph fingerprints (right). Differences are highlighted in blue. Every non-differentiable operation is replaced with a differentiable analog. Canonicalization Circular fingerprints are identical regardless of the ordering of atoms in each neighborhood. This invariance is achieved by sorting the neighboring atoms according to their features, and bond features. We experimented with this sorting scheme, and also with applying the local feature transform on all possible permutations of the local neighborhood. An alternative to canonicalization is to apply a permutation-invariant function, such as summation. In the interests of simplicity and scalability, we chose summation. Circular fingerprints can be interpreted as a special case of neural graph fingerprints having large random weights. This is because, in the limit of large input weights, tanh nonlinearities approach step functions, which when concatenated form a simple hash function. Also, in the limit of large input weights, the softmax operator approaches a one-hot-coded argmax operator, which is analogous to an indexing operation. Algorithms 1 and 2 summarize these two algorithms and highlight their differences. Given a fingerprint length L, and F features at each layer, the parameters of neural graph fingerprints consist of a separate output weight matrix of size F × L for each layer, as well as a set of hidden-to-hidden weight matrices of size F × F at each layer, one for each possible number of bonds an atom can have (up to 5 in organic molecules). 4 Experiments We ran two experiments to demonstrate that neural fingerprints with large random weights behave similarly to circular fingerprints. First, we examined whether distances between circular fingerprints were similar to distances between neural fingerprint-based distances. Figure 3 (left) shows a scatterplot of pairwise distances between circular vs. neural fingerprints. Fingerprints had length 2048, and were calculated on pairs of molecules from the solubility dataset [4]. Distance was measured using a continuous generalization of the Tanimoto (a.k.a. Jaccard) similarity measure, given by .X X distance(x, y) = 1 − min(xi , yi ) max(xi , yi ) (1) There is a correlation of r = 0.823 between the distances. The line of points on the right of the plot shows that for some pairs of molecules, binary ECFP fingerprints have exactly zero overlap. Second, we examined the predictive performance of neural fingerprints with large random weights vs. that of circular fingerprints. Figure 3 (right) shows average predictive performance on the solubility dataset, using linear regression on top of fingerprints. The performances of both methods follow similar curves. In contrast, the performance of neural fingerprints with small random weights follows a different curve, and is substantially better. This suggests that even with random weights, the relatively smooth activation of neural fingerprints helps generalization performance. 3 2.0 1.8 0.9 RMSE (log Mol/L) Neural fingerprint distances Neural vs Circular distances, r =0:823 1.0 0.8 0.7 0.6 0.5 0.5 Circular fingerprints Random conv with large parameters Random conv with small parameters 1.6 1.4 1.2 1.0 0.8 0 0.6 0.7 0.8 0.9 1.0 Circular fingerprint distances 1 2 3 4 Fingerprint radius 5 6 Figure 3: Left: Comparison of pairwise distances between molecules, measured using circular fingerprints and neural graph fingerprints with large random weights. Right: Predictive performance of circular fingerprints (red), neural graph fingerprints with fixed large random weights (green) and neural graph fingerprints with fixed small random weights (blue). The performance of neural graph fingerprints with large random weights closely matches the performance of circular fingerprints. 4.1 Examining learned features To demonstrate that neural graph fingerprints are interpretable, we show substructures which most activate individual features in a fingerprint vector. Each feature of a circular fingerprint vector can each only be activated by a single fragment of a single radius, except for accidental collisions. In contrast, neural graph fingerprint features can be activated by variations of the same structure, making them more interpretable, and allowing shorter feature vectors. Solubility features Figure 4 shows the fragments that maximally activate the most predictive features of a fingerprint. The fingerprint network was trained as inputs to a linear model predicting solubility, as measured in [4]. The feature shown in the top row has a positive predictive relationship with solubility, and is most activated by fragments containing a hydrophilic R-OH group, a standard indicator of solubility. The feature shown in the bottom row, strongly predictive of insolubility, is activated by non-polar repeated ring structures. Fragments most activated by pro-solubility feature O OH O NH O OH OH Fragments most activated by anti-solubility feature Figure 4: Examining fingerprints optimized for predicting solubility. Shown here are representative examples of molecular fragments (highlighted in blue) which most activate different features of the fingerprint. Top row: The feature most predictive of solubility. Bottom row: The feature most predictive of insolubility. 4 Toxicity features We trained the same model architecture to predict toxicity, as measured in two different datasets in [26]. Figure 5 shows fragments which maximally activate the feature most predictive of toxicity, in two separate datasets. Fragments most activated by toxicity feature on SR-MMP dataset Fragments most activated by toxicity feature on NR-AHR dataset Figure 5: Visualizing fingerprints optimized for predicting toxicity. Shown here are representative samples of molecular fragments (highlighted in red) which most activate the feature most predictive of toxicity. Top row: the most predictive feature identifies groups containing a sulphur atom attached to an aromatic ring. Bottom row: the most predictive feature identifies fused aromatic rings, also known as polycyclic aromatic hydrocarbons, a well-known carcinogen. [27] constructed similar visualizations, but in a semi-manual way: to determine which toxic fragments activated a given neuron, they searched over a hand-made list of toxic substructures and chose the one most correlated with a given neuron. In contrast, our visualizations are generated automatically, without the need to restrict the range of possible answers beforehand. 4.2 Predictive Performance We ran several experiments to compare the predictive performance of neural graph fingerprints to that of the standard state-of-the-art setup: circular fingerprints fed into a fully-connected neural network. Experimental setup Our pipeline takes as input the SMILES [30] string encoding of each molecule, which is then converted into a graph using RDKit [20]. We also used RDKit to produce the extended circular fingerprints used in the baseline. Hydrogen atoms were treated implicitly. In our convolutional networks, the initial atom and bond features were chosen to be similar to those used by ECFP: Initial atom features concatenated a one-hot encoding of the atom’s element, its degree, the number of attached hydrogen atoms, and the implicit valence, and an aromaticity indicator. The bond features were a concatenation of whether the bond type was single, double, triple, or aromatic, whether the bond was conjugated, and whether the bond was part of a ring. Training and Architecture Training used batch normalization [11]. We also experimented with tanh vs relu activation functions for both the neural fingerprint network layers and the fullyconnected network layers. relu had a slight but consistent performance advantage on the validation set. We also experimented with dropconnect [29], a variant of dropout in which weights are randomly set to zero instead of hidden units, but found that it led to worse validation error in general. Each experiment optimized for 10000 minibatches of size 100 using the Adam algorithm [13], a variant of RMSprop that includes momentum. Hyperparameter Optimization To optimize hyperparameters, we used random search. The hyperparameters of all methods were optimized using 50 trials for each cross-validation fold. The following hyperparameters were optimized: log learning rate, log of the initial weight scale, the log L2 penalty, fingerprint length, fingerprint depth (up to 6), and the size of the hidden layer in the fully-connected network. Additionally, the size of the hidden feature vector in the convolutional neural fingerprint networks was optimized. 5 Dataset Units Predict mean Circular FPs + linear layer Circular FPs + neural net Neural FPs + linear layer Neural FPs + neural net Solubility [4] log Mol/L Drug efficacy [5] EC50 in nM Photovoltaic efficiency [8] percent 4.29 ± 0.40 1.71 ± 0.13 1.40 ± 0.13 0.77 ± 0.11 0.52 ± 0.07 1.47 ± 0.07 1.13 ± 0.03 1.36 ± 0.10 1.15 ± 0.02 1.16 ± 0.03 6.40 ± 0.09 2.63 ± 0.09 2.00 ± 0.09 2.58 ± 0.18 1.43 ± 0.09 Table 1: Mean predictive accuracy of neural fingerprints compared to standard circular fingerprints. Datasets We compared the performance of standard circular fingerprints against neural graph fingerprints on a variety of domains: • Solubility: The aqueous solubility of 1144 molecules as measured by [4]. • Drug efficacy: The half-maximal effective concentration (EC50 ) in vitro of 10,000 molecules against a sulfide-resistant strain of P. falciparum, the parasite that causes malaria, as measured by [5]. • Organic photovoltaic efficiency: The Harvard Clean Energy Project [8] uses expensive DFT simulations to estimate the photovoltaic efficiency of organic molecules. We used a subset of 20,000 molecules from this dataset. Predictive accuracy We compared the performance of circular fingerprints and neural graph fingerprints under two conditions: In the first condition, predictions were made by a linear layer using the fingerprints as input. In the second condition, predictions were made by a one-hidden-layer neural network using the fingerprints as input. In all settings, all differentiable parameters in the composed models were optimized simultaneously. Results are summarized in Table 4.2. In all experiments, the neural graph fingerprints matched or beat the accuracy of circular fingerprints, and the methods with a neural network on top of the fingerprints typically outperformed the linear layers. Software Automatic differentiation (AD) software packages such as Theano [1] significantly speed up development time by providing gradients automatically, but can only handle limited control structures and indexing. Since we required relatively complex control flow and indexing in order to implement variants of Algorithm 2, we used a more flexible automatic differentiation package for Python called Autograd (github.com/HIPS/autograd). This package handles standard Numpy [18] code, and can differentiate code containing while loops, branches, and indexing. Code for computing neural fingerprints and producing visualizations is available at github.com/HIPS/neural-fingerprint. 5 Limitations Computational cost Neural fingerprints have the same asymptotic complexity in the number of atoms and the depth of the network as circular fingerprints, but have additional terms due to the matrix multiplies necessary to transform the feature vector at each step. To be precise, computing the neural fingerprint of depth R, fingerprint length L of a molecule with N atoms using a molecular convolutional net having F features at each layer costs O(RN F L + RN F 2 ). In practice, training neural networks on top of circular fingerprints usually took several minutes, while training both the fingerprints and the network on top took on the order of an hour on the larger datasets. Limited computation at each layer How complicated should we make the function that goes from one layer of the network to the next? In this paper we chose the simplest feasible architecture: a single layer of a neural network. However, it may be fruitful to apply multiple layers of nonlinearities between each message-passing step (as in [22]), or to make information preservation easier by adapting the Long Short-Term Memory [10] architecture to pass information upwards. 6 Limited information propagation across the graph The local message-passing architecture developed in this paper scales well in the size of the graph (due to the low degree of organic molecules), but its ability to propagate information across the graph is limited by the depth of the network. This may be appropriate for small graphs such as those representing the small organic molecules used in this paper. However, in the worst case, it can take a depth N2 network to distinguish between graphs of size N . To avoid this problem, [2] proposed a hierarchical clustering of graph substructures. A tree-structured network could examine the structure of the entire graph using only log(N ) layers, but would require learning to parse molecules. Techniques from natural language processing [25] might be fruitfully adapted to this domain. Inability to distinguish stereoisomers Special bookkeeping is required to distinguish between stereoisomers, including enantomers (mirror images of molecules) and cis/trans isomers (rotation around double bonds). Most circular fingerprint implementations have the option to make these distinctions. Neural fingerprints could be extended to be sensitive to stereoisomers, but this remains a task for future work. 6 Related work This work is similar in spirit to the neural Turing machine [7], in the sense that we take an existing discrete computational architecture, and make each part differentiable in order to do gradient-based optimization. Neural nets for quantitative structure-activity relationship (QSAR) The modern standard for predicting properties of novel molecules is to compose circular fingerprints with fully-connected neural networks or other regression methods. [3] used circular fingerprints as inputs to an ensemble of neural networks, Gaussian processes, and random forests. [19] used circular fingerprints (of depth 2) as inputs to a multitask neural network, showing that multiple tasks helped performance. Neural graph fingerprints The most closely related work is [15], who build a neural network having graph-valued inputs. Their approach is to remove all cycles and build the graph into a tree structure, choosing one atom to be the root. A recursive neural network [23, 24] is then run from the leaves to the root to produce a fixed-size representation. Because a graph having N nodes has N possible roots, all N possible graphs are constructed. The final descriptor is a sum of the representations computed by all distinct graphs. There are as many distinct graphs as there are atoms in the network. The computational cost of this method thus grows as O(F 2 N 2 ), where F is the size of the feature vector and N is the number of atoms, making it less suitable for large molecules. Convolutional neural networks Convolutional neural networks have been used to model images, speech, and time series [14]. However, standard convolutional architectures use a fixed computational graph, making them difficult to apply to objects of varying size or structure, such as molecules. More recently, [12] and others have developed a convolutional neural network architecture for modeling sentences of varying length. Neural networks on fixed graphs [2] introduce convolutional networks on graphs in the regime where the graph structure is fixed, and each training example differs only in having different features at the vertices of the same graph. In contrast, our networks address the situation where each training input is a different graph. Neural networks on input-dependent graphs [22] propose a neural network model for graphs having an interesting training procedure. The forward pass consists of running a message-passing scheme to equilibrium, a fact which allows the reverse-mode gradient to be computed without storing the entire forward computation. They apply their network to predicting mutagenesis of molecular compounds as well as web page rankings. [16] also propose a neural network model for graphs with a learning scheme whose inner loop optimizes not the training loss, but rather the correlation between each newly-proposed vector and the training error residual. They apply their model to a dataset of boiling points of 150 molecular compounds. Our paper builds on these ideas, with the 7 following differences: Our method replaces their complex training algorithms with simple gradientbased optimization, generalizes existing circular fingerprint computations, and applies these networks in the context of modern QSAR pipelines which use neural networks on top of the fingerprints to increase model capacity. Unrolled inference algorithms [9] and others have noted that iterative inference procedures sometimes resemble the feedforward computation of a recurrent neural network. One natural extension of these ideas is to parameterize each inference step, and train a neural network to approximately match the output of exact inference using only a small number of iterations. The neural fingerprint, when viewed in this light, resembles an unrolled message-passing algorithm on the original graph. 7 Conclusion We generalized existing hand-crafted molecular features to allow their optimization for diverse tasks. By making each operation in the feature pipeline differentiable, we can use standard neural-network training methods to scalably optimize the parameters of these neural molecular fingerprints end-toend. We demonstrated the interpretability and predictive performance of these new fingerprints. Data-driven features have already replaced hand-crafted features in speech recognition, machine vision, and natural-language processing. Carrying out the same task for virtual screening, drug design, and materials design is a natural next step. Acknowledgments We thank Edward Pyzer-Knapp, Jennifer Wei, and Samsung Advanced Institute of Technology for their support. This work was partially funded by NSF IIS-1421780. References [1] Frédéric Bastien, Pascal Lamblin, Razvan Pascanu, James Bergstra, Ian J. Goodfellow, Arnaud Bergeron, Nicolas Bouchard, and Yoshua Bengio. Theano: new features and speed improvements. Deep Learning and Unsupervised Feature Learning NIPS 2012 Workshop, 2012. [2] Joan Bruna, Wojciech Zaremba, Arthur Szlam, and Yann LeCun. Spectral networks and locally connected networks on graphs. arXiv preprint arXiv:1312.6203, 2013. [3] George E. Dahl, Navdeep Jaitly, and Ruslan Salakhutdinov. Multi-task neural networks for QSAR predictions. arXiv preprint arXiv:1406.1231, 2014. [4] John S. Delaney. ESOL: Estimating aqueous solubility directly from molecular structure. Journal of Chemical Information and Computer Sciences, 44(3):1000–1005, 2004. [5] Francisco-Javier Gamo, Laura M Sanz, Jaume Vidal, Cristina de Cozar, Emilio Alvarez, Jose-Luis Lavandera, Dana E Vanderwall, Darren VS Green, Vinod Kumar, Samiul Hasan, et al. Thousands of chemical starting points for antimalarial lead identification. Nature, 465(7296):305–310, 2010. [6] Robert C. Glem, Andreas Bender, Catrin H. Arnby, Lars Carlsson, Scott Boyer, and James Smith. Circular fingerprints: flexible molecular descriptors with applications from physical chemistry to ADME. IDrugs: the investigational drugs journal, 9(3):199–204, 2006. [7] Alex Graves, Greg Wayne, and Ivo Danihelka. Neural Turing machines. arXiv preprint arXiv:1410.5401, 2014. [8] Johannes Hachmann, Roberto Olivares-Amaya, Sule Atahan-Evrenk, Carlos Amador-Bedolla, Roel S Sánchez-Carrera, Aryeh Gold-Parker, Leslie Vogt, Anna M Brockway, and Alán Aspuru-Guzik. The Harvard clean energy project: large-scale computational screening and design of organic photovoltaics on the world community grid. The Journal of Physical Chemistry Letters, 2(17):2241–2251, 2011. [9] John R Hershey, Jonathan Le Roux, and Felix Weninger. Deep unfolding: Model-based inspiration of novel deep architectures. arXiv preprint arXiv:1409.2574, 2014. 8 [10] Sepp Hochreiter and Jürgen Schmidhuber. Long short-term memory. Neural computation, 9(8):1735–1780, 1997. [11] Sergey Ioffe and Christian Szegedy. Batch normalization: Accelerating deep network training by reducing internal covariate shift. arXiv preprint arXiv:1502.03167, 2015. [12] Nal Kalchbrenner, Edward Grefenstette, and Phil Blunsom. A convolutional neural network for modelling sentences. Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics, June 2014. [13] Diederik Kingma and Jimmy Ba. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980, 2014. [14] Yann LeCun and Yoshua Bengio. Convolutional networks for images, speech, and time series. The handbook of brain theory and neural networks, 3361, 1995. [15] Alessandro Lusci, Gianluca Pollastri, and Pierre Baldi. Deep architectures and deep learning in chemoinformatics: the prediction of aqueous solubility for drug-like molecules. Journal of chemical information and modeling, 53(7):1563–1575, 2013. [16] Alessio Micheli. Neural network for graphs: A contextual constructive approach. Neural Networks, IEEE Transactions on, 20(3):498–511, 2009. [17] H.L. Morgan. The generation of a unique machine description for chemical structure. Journal of Chemical Documentation, 5(2):107–113, 1965. [18] Travis E Oliphant. Python for scientific computing. Computing in Science & Engineering, 9(3):10–20, 2007. [19] Bharath Ramsundar, Steven Kearnes, Patrick Riley, Dale Webster, David Konerding, and Vijay Pande. Massively multitask networks for drug discovery. arXiv:1502.02072, 2015. [20] RDKit: Open-source cheminformatics. www.rdkit.org. [accessed 11-April-2013]. [21] David Rogers and Mathew Hahn. Extended-connectivity fingerprints. Journal of Chemical Information and Modeling, 50(5):742–754, 2010. [22] F. Scarselli, M. Gori, Ah Chung Tsoi, M. Hagenbuchner, and G. Monfardini. The graph neural network model. Neural Networks, IEEE Transactions on, 20(1):61–80, Jan 2009. [23] Richard Socher, Eric H Huang, Jeffrey Pennin, Christopher D Manning, and Andrew Y Ng. Dynamic pooling and unfolding recursive autoencoders for paraphrase detection. In Advances in Neural Information Processing Systems, pages 801–809, 2011. [24] Richard Socher, Jeffrey Pennington, Eric H Huang, Andrew Y Ng, and Christopher D Manning. Semi-supervised recursive autoencoders for predicting sentiment distributions. In Proceedings of the Conference on Empirical Methods in Natural Language Processing, pages 151–161. Association for Computational Linguistics, 2011. [25] Kai Sheng Tai, Richard Socher, and Christopher D Manning. Improved semantic representations from tree-structured long short-term memory networks. arXiv preprint arXiv:1503.00075, 2015. [26] Tox21 Challenge. National center for advancing translational sciences. http://tripod. nih.gov/tox21/challenge, 2014. [Online; accessed 2-June-2015]. [27] Thomas Unterthiner, Andreas Mayr, Günter Klambauer, and Sepp Hochreiter. Toxicity prediction using deep learning. arXiv preprint arXiv:1503.01445, 2015. [28] Thomas Unterthiner, Andreas Mayr, G ünter Klambauer, Marvin Steijaert, Jörg Wenger, Hugo Ceulemans, and Sepp Hochreiter. Deep learning as an opportunity in virtual screening. In Advances in Neural Information Processing Systems, 2014. [29] Li Wan, Matthew Zeiler, Sixin Zhang, Yann L. Cun, and Rob Fergus. Regularization of neural networks using dropconnect. In International Conference on Machine Learning, 2013. [30] David Weininger. SMILES, a chemical language and information system. Journal of chemical information and computer sciences, 28(1):31–36, 1988. 9
9cs.NE
THE STRUCTURE OF DGA RESOLUTIONS OF MONOMIAL IDEALS arXiv:1610.06526v1 [math.AC] 20 Oct 2016 LUKAS KATTHÄN Abstract. Let I ⊂ k[x1 , . . . , xn ] be a squarefree monomial ideal a polynomial ring. In this paper we study multiplications on the minimal free resolution F of a S/I. In particular, we characterize the possible vectors of total Betti numbers for such ideals which admit a differential graded algebra (DGA) structure on F. We also show that under these assumptions the maximal shifts of the graded Betti numbers are subadditive. On the other hand, we present an example of a strongly generic monomial ideal which does not admit a DGA structure on its minimal free resolution. In particular, this demonstrates that the Hull resolution and the Lyubeznik resolution do not admit DGA structures in general. Finally, we show that it is enough to modify the last map of F to ensure that it admits the structure of a DG algebra. Introduction Let S be a polynomial ring over a field, I ⊂ S be a monomial ideal, and let F denote the minimal free resolution of S/I over S. The multiplication map S/I ⊗S S/I → S/I can be lifted to a “multiplication” ∗ : F ⊗S F → F, which in general is associative and graded-commutative only up to homotopy. Moreover, ∗ is unique only up to homotopy. It is known that ∗ can always chosen to be graded-commutative “on the nose” (cf. [BE77, Prop 1.1]), but in general it is not possible to choose ∗ such that it is associative (cf. [Avr74, Appendix], [Avr81]). If ∗ is graded-commutative and associative, then it gives F the structure of a differential graded algebra (DGA). In this situation, we say that S/I admits a minimal DGA resolution. Starting with the work of Buchsbaum and Eisenbud [BE77], a lot of research has been devoted to the study of DGA resolutions, see for example [Avr81] or [Kus94] and the references therein. In the present paper, we study the case where I is generated by squarefree monomials and consider only multiplications which respect the multigrading. These restrictions allow us to prove much stronger statements than in the general situation. Our results can be organized along the following questions: (1) Which ideals admit a minimal DGA resolution? Which constructions of (not necessarily minimal) resolutions yield DGA resolutions? (2) What are the consequences if a given ideal admits a minimal DGA resolution? (3) How unique or non-unique are the DGA structures? (4) What can be said about the structure of DGA resolutions as algebras? 2010 Mathematics Subject Classification. Primary: 05E40; Secondary: 13D02,16W50,13F55. Key words and phrases. Monomial ideal; Free resolution; Differential graded Algebra. 1 2 LUKAS KATTHÄN There are a few classes of ideals in local rings which are known to admit minimal DGA resolutions, see [Kus94] for an overview. In the context of monomial ideals, this is the case for stable ideals [Pee96], matroidal ideals [Skö11] and edge ideals of cointerval graphs [Skö16]. Another class of ideals whose minimal free resolutions are well-understood are generic monomial ideals. However, in Theorem 5.1, we present an example of a (strongly) generic monomial ideal which does not admit a minimal DGA resolution. The example also demonstrates that the hull resolution [BS98] and the Lyubeznik resolution [Lyu88] do not admit a DGA structure in general. On the positive side, we show in Theorem 2.1 that for every monomial ideal I there always exists a monomial m ∈ S such that S/(mI) admits a minimal DGA resolution. Note that the minimal free resolutions of S/I and S/(mI) differ only in the last map. Therefore, one can interpret this result as saying that the other maps in the resolution to not contain obstructions to the existence of a DGA structure. This result actually holds in greater generality for homogeneous ideals in S and even for ideals in regular local domains. Concerning the second question, it is a beautiful result by Buchsbaum and Eisenbud [BE77, Proposition 1.4], that if I admits a minimal DGA resolution, then one can conclude certain lower bounds on the Betti numbers of S/I. In the context of squarefree monomial ideals, we sharpen this result by completely characterizing the possible total Betti numbers of ideals admitting a minimal DGA resolution (Theorem 4.1). Moreover, we show that if I is such an ideal, then its graded Betti numbers satisfy the subadditivity condition of [ACI15] (Proposition 4.4). It is well-known that DGA structures on minimal free resolutions do not need to be unique. Our Example 3.2 demonstrates that this even fails for squarefree monomial ideals, thus answering a question of Buchsbaum and Eisenbud [Pee10, Open Problem 31.4]. On the other hand, we show that at least a certain part of the multiplication is indeed unique, see Proposition 3.1 for the precise statement. Concerning the fourth questions, we show that F is essentially generated in degree 1 with respect to any multiplication. See Proposition 3.4 for the exact statement. As a consequence, whenever I admits a minimal DGA resolution F, then it is a quotient of the Taylor resolution (which has a canonical DGA structure) by a DG-ideal, see Theorem 3.6. Thus one can study the possible DGA structures on F by considering DG-ideals in the Taylor resolution. The key idea behind most of our results is the following simple observation: F is a free S-module which is generated in squarefree degrees, so for any homogeneous element f ∈ F, we can find an element f ′ ∈ F of squarefree degree, such that f = mf ′ for a monomial m ∈ S. We call f ′ the squarefree part of f . This paper is structured as follows. In Section 1 we recall some preliminaries about multiplicative structures on resolution, the Taylor resolution and the Scarf complex, and we introduce the squarefree part of an element f ∈ F. In the next section we prove Theorem 2.1 about the existence of minimal DGA resolutions after multiplication with an element. The following Section 3 is devoted to the study of the structure of multiplication on F. After that, in Section 4 we derive two consequences of the existence of a minimal DGA resolution, namely our characterization of the total Betti numbers and the subadditivity of syzygies. STRUCTURE OF DGA STRUCTURES 3 In the penultimate Section 5 we present an example of a generic monomial ideal which does not admit a minimal DGA resolution, and in the last section we study multiplication on resolutions of ideals which are not necessarily squarefree. 1. Preliminaries and notation Throughout the paper, let k be a field and S = k[x1 , . . . , xn ] be a polynomial ring over k, endowed with the fine Zn -grading. We denote by m := hx1 , . . . , xn i the maximal homogeneous ideal of S. Further, let I ⊂ S be a monomial ideal and let ∂ ∂ ∂ F : · · · → F2 → F1 → F0 → S/I → 0 denote the minimal free resolution of S/I. Note that F is Zn -graded and the differential ∂ respect the multigrading. The multigraded Betti numbers of S/I S are denoted by βi,a (S/I) = TorSi (S/I, k)a . We often identify F with the free L multigraded S-module i Fi . For an element f ∈ F we denote its multidegree by deg(f ) and its homological degree by |f |. We consider the componentwise order on Zn and write a ∧ b and a ∨ b for the componentwise minimum and maximum of a, b ∈ Zn , respectively. 1.1. Multiplications on resolutions. We recall the definition of a DGA structure. Definition 1.1. A differential graded algebra (DGA) structure on F is an S-linear map ∗ : F ⊗S F → F satisfying the following axioms for a, b, c ∈ F: (1) ∗ extends the usual multiplication on F0 = S, (2) ∂(a ∗ b) = ∂(a) ∗ b + (−1)|a| a ∗ ∂b (Leibniz rule), (3) |a ∗ b| = |a| + |b| (homogeneity with respect to the homological grading), (4) a ∗ b = (−1)|a|·|b| b ∗ a (graded commutativity), and (5) (a ∗ b) ∗ c = a ∗ (b ∗ c) (associativity). We will also consider non-associative multiplications. To make this precise, we call a map ∗ : F ⊗S F → F a multiplication if it satisfies all the axioms of a DGA except possibly the associativity. Moreover, we make the convention that in this paper, every multiplication respects the multigrading on F, unless specified otherwise. The only occasion when we consider more general multiplication is in Section 5. While F does not always admit a DGA structure, it always admits a multiplication, cf. [BE77, Prop 1.1], and the multiplication is unique up to homotopy. Explicitly, this means that when ∗1 , ∗2 are two multiplications, then there exist a map σ : F ⊗S F → F raising the homological degree by 1 such that a ∗1 b = a ∗2 b + ∂σ(a, b) + σ(∂a, b) + (−1)|a| σ(a, ∂b) for a, b ∈ F; 1.2. The Taylor resolution and the Scarf complex. We recall the definitions of the Taylor resolution and the Scarf complex of I. We refer the reader to p.67 and Section 6.2 of [MS05], respectively, for further information about these constructions. Let G(I) denote the set of minimal monomial generators of I and choose a total order ≺ on G(I). The choice of the order affects only the signs in the computations. 4 LUKAS KATTHÄN Definition 1.2. The Taylor resolution T of S/I is the complex of free S-modules with basis {gW : W ⊆ G(I)}. The basis elements are graded by |gW | := #W and deg gW := deg mW , where mW := lcm(m : m ∈ W ) for W ⊆ G(I). Further, the differential is given by X mW ∂gW = (−1)σ(m,W ) gW \{m} , mW \{m} m∈W where σ(m, W ) := #{m′ ∈ W, m′ ≺ m}. The Taylor resolution is a free resolution of S/I, but typically not a minimal one. It was shown by Gemeda [Gem76] (see also [Pee10, Proposition 31.3]) that it carries a DGA structure with the multiplication given by  (−1)σ(W,V ) mW mV gW ∗ gV =  0 mW ∪V gW ∪V if W ∩ V = ∅, otherwise, where σ(W, V ) := #{(m, m′ ) ∈ W × V : m′ ≺ m}. To simplify the notation we occasionally write gm1 m2 ... instead of g{m1 ,m2 ,... } for m1 , m2 , . . . ∈ G(I). Definition 1.3. The Scarf complex ∆I of S/I is the simplicial complex with vertex set G(I), where a set W ⊂ G(I) is contained in ∆I if and only if there does not exist another set V ⊂ G(I) with V 6= W and lcm(m : m ∈ W ) = lcm(m : m ∈ V ). Moreover, the algebraic Scarf complex F∆I is the subcomplex of the Taylor resolution generated by the generators gW , W ∈ ∆I . The algebraic Scarf complex is always a subcomplex of the minimal free resolution of S/I (cf. [MS05, Proposition 6.12]), but in general it is not acyclic. We will therefore use the notation gW for generators of F which lie in the Scarf complex. 1.3. The squarefree part. The following very basic observation turns out to be the key to many of our results: Lemma 1.4. Let F be a free S-module and a ∈ Nn . Assume that the degree of every generator of F is less or equal to a. Then every element f ∈ F with deg f  a can be written as f = mf ′ for a monomial m ∈ S and f ′ ∈ F with deg f ′ = (deg f ) ∧ a. Both m and f ′ are uniquely determined. This lemma is almost obvious, but we include a proof for completeness. Proof. Choose a basis of F and let G be the set of those basis elements whose degrees are less or equal than deg f . By assumption, f can be written as a linear combination of elements of G, and we write cg for the coefficient of g in this expansion. Then it holds that f= X g∈G cg xdeg(f )−deg(g) g = xdeg(f )−(a∧deg(f )) X cg x(a∧deg(f ))−deg(g) g. g∈G All exponents are non-negative by our hypothesis, so we have shown the existence of the claimed factorization. The uniqueness of m is trivial, because there is only one monomial of the correct multidegree. Using this, the uniqueness of f ′ follows from the fact that S is a domain and F is torsion-free.  STRUCTURE OF DGA STRUCTURES 5 Definition 1.5. Let F be a free S-module, such that the degree every generator is squarefree, i.e. less or equal than (1, . . . , 1) ∈ Nn . In the situation of Lemma 1.4, we call f ′ the squarefree part of f and denote it by |f |sqf . Note that the map f 7→ |f |sqf is k-linear, but not S-linear. We will apply this definition almost exclusively to the minimal free resolution F of a S/I for a squarefree monomial ideal I ⊂ S. 2. Existence of DGA structures up to multiplication with an element Our first result is the following theorem. It implies that it is enough modify the last map of a minimal free resolution to ensure the existence of a DGA structure. Theorem 2.1. Let S be a regular local ring, or a polynomial ring and I ⊆ S an ideal. There exists a homogeneous element s ∈ S, s 6= 0 such that the minimal free resolution of S/(sI) admits a DGA structure. If I is a monomial ideal (and S a polynomial ring), then s can be chosen to be the least common multiple of the generators of I. We need the following lemma for the proof of the Theorem. ± n Lemma 2.2. Let Q = k[t± 1 , . . . , tn ] be a Z -graded Laurent polynomial for n ≥ 0. Let F: 0 → Fp → · · · → F1 → F0 → 0 be an exact complex of graded Q-modules and assume that F0 = Q. Then the multiplication on F0 can be extended to a graded-commutative DGA structure on F. Proof. Let ∂ denote the differential of F. We claim that there exists a map σ : F → F of homological degree 1 such that ∂ ◦ σ + σ ◦ ∂ = idF and σ ◦ σ = 0. Indeed, every graded module over Q is free (cf. [GW78, Theorem 1.1.4]), so we can choose splittings Fi ∼ = Vi ⊕ ∂(Fi+1 ). We define σi |Vi = 0 and σi (∂(f )) = f for f ∈ Fi+1 . It is not difficult to see that this gives indeed a map σ with the claimed properties. We define the DGA structure on F inductively by the formula a ∗ b :=  ab   σ ∂(a) ∗ b + (−1)|a| a ∗ ∂(b) if |a| = 0 or |b| = 0 otherwise, where the multiplication in the first case is the one from F0 = Q. This multiplication clearly satisfies the Leibniz rule and it extends the multiplication on F0 . It remains to show that ∗ is graded-commutative and associative. Note that σ = σ ◦ ∂ ◦ σ. We proceed by induction on the homological degree, the 6 LUKAS KATTHÄN base case being clear. It holds for a, b, c ∈ F:  a ∗ (b ∗ c) = σ ∂(a ∗ (b ∗ c))   = σ ∂a ∗ (b ∗ c) + (−1)|a| a ∗ (∂b ∗ c) + (−1)|a|+|b| a ∗ (b ∗ ∂c) (#)   = σ (∂a ∗ b) ∗ c + (−1)|a| (a ∗ ∂b) ∗ c + (−1)|a|+|b| (a ∗ b) ∗ ∂c  = σ ∂((a ∗ b) ∗ c)   = (a ∗ b) ∗ c where in (#) we use the induction hypothesis. The commutativity is verified analogously.  Proof of Theorem 2.1. Let F be the minimal free resolution of S/I. Let Q be the subring of the field of fractions of S where we adjoin inverses for all homogeneous elements of S, and set FQ := F ⊗S Q. Note that Q is a multivariate Laurent polynomial ring over some field k. Moreover, Q is flat over S and hence FQ is exact. So by Lemma 2.2, it can be endowed with a DGA structure ∗. Choose a basis for each Fi . Then the multiplication on FQ can be represented as a matrix with entries in Q. Hence we can choose an element s ∈ S such that sq ∈ S for each entry q of this matrix. Let F′ be the subcomplex of F defined by F′0 := F0 and F′i := sFi for i ≥ 1. We claim that F′ is closed under multiplication. Indeed, for sa, ab ∈ F′ the choice of s implies that s(a ∗ b) ∈ F and thus (sa ∗ sb) ∈ F′ . Note that F′ is isomorphic to F except in degree 0, so in particular it is exact in every other degree. In degree 0, it holds that H0 (F′ ) = F0 /∂(sF1 ) = S/(sI). Thus F′ is the minimal free resolution of S/(sI). Finally, consider the case that I is a monomial ideal in a polynomial ring S = k[x1 , . . . , xn ]. Let a, b ∈ F be two homogeneous elements. The product a ∗ b ∈ FQ can be written as a sum X λg xdeg(a)+deg(b)−deg(g) g g∈B where B is an S-basis of F and λg ∈ k. Let now s be the lcm of all generators of I. Then the multidegrees of all elements of B are less or equal to deg(s), and hence s(a ∗ b) ∈ F. Now one can argue as above.  3. Properties of multiplications 3.1. Uniqueness. The multiplication on F is in general not unique. However, the part of the multiplication which lives on the algebraic Scarf complex is uniquely determined, as the next proposition shows. Proposition 3.1. Let I ⊂ S be a squarefree monomial ideal with minimal free resolution F, and let further ∗ be a multiplication on F. Then, for V, W ∈ ∆I with V ∪ W ∈ ∆I , it holds that gW ∗ gV =  (−1)σ(W,V ) mW mV mW ∪V 0 gW ∪V if W ∩ V = ∅, otherwise; STRUCTURE OF DGA STRUCTURES 7 where σ(W, V ) is defined as above. In particular, the product gW ∗ gV does not depend on the choice of ∗. Proof. Let B be an S-basis for F. For every g ∈ B there exists a (not necessarily unique) subset Ug ⊂ G(I) such that deg g = deg mUg and |g| = #Ug . This follows from the fact that F is a direct summand of the Taylor resolution. Expand gW ∗ gV in the basis B: gW ∗ gV = X cg g. g∈B Assume that cg 6= 0 for some g ∈ B. As I is squarefree, it holds that deg mUg = deg g ≤ deg |gW ∗gV |sqf = deg(gW )∨deg(gV ) = deg mW ∪V . Hence deg mUg ∪W ∪V = deg mW ∪V . But W ∪ V is contained in the Scarf complex, and hence it follows that Ug ∪ W ∪ V = W ∪ V and hence Ug ⊆ V ∪ W . On the other hand, it holds that #Ug = |g| = #W + #V ≥ #(W ∪ V ). So we can conclude that Ug = V ∪ W and that #W + #V = #(W ∪ V ). Hence if W and V intersect non-trivially then V gW ∗ gV is zero, and if they are disjoint, then gW ∗ gV = λ mmWWm gW ∪V for a scalar ∪V λ ∈ k. It is clear by induction that the scalars λ are uniquely determined by the Leibniz rule. Moreover, the values given in the claim satisfy the Leibniz rule, hence we have determined the product gW ∗ gV .  The following example show that the multiplication is not unique in general. This answers a question of Buchsbaum and Eisenbud [Pee10, Open Problems 31.4]. Example 3.2. Let I ⊂ S = Q[x1 , x2 , x3 , x4 , y, z] be the ideal with generators a := x1 x2 y, b := x2 x3 , c := x3 x4 z and d := x4 x1 . One can verify with Macaulay2 that the minimal free resolution F of S/I equals its algebraic Scarf complex. The Scarf complex ∆I is the following simplicial complex: c d a b Consider the product ga ∗ gc . Both a and c are vertices of ∆I , but {a, c} ∈ / ∆I , so the preceding Proposition does not apply. And indeed, for any λ ∈ k the choice ga ∗ gc := λ(x4 zgab + x1 ygbc ) (1 − λ)(x3 zgad − x2 ygcd ) satisfies the Leibniz rule. This can be extended to a multiplication on F, which is even a DGA structure, because the length of the resolution is three (cf. [BE77, Prop 1.3]) The next example illustrates that one cannot omit the assumption of I being squarefree from Proposition 3.1. Example 3.3. Consider the ideal I ⊂ S = k[x, y, z] generated by a := x2 , b := xy and c := xz. The algebraic Scarf complex of this ideal coincides with its Taylor resolution T. So if I were squarefree, then the DGA structure on T described above were the only possible multiplication. However, we can modify the multiplication by setting gb ∗ gc := zgab − ygac . The Leibniz rule requires that in addition we set gb ∗ gac := gc ∗ gab := 0. See Table 1 for the full multiplication table of this new multiplication. It is even a DGA structure, again because the projective dimension of S/I is less then four. 8 LUKAS KATTHÄN ∗ ga gb gc gab gac gbc gabc ga gb gc 0 xgab xgac −xgab 0 zgab − ygac −xgac −zgab + ygac 0 0 0 0 0 0 0 xgabc 0 0 0 0 0 Table 1. The multiplication table gab gac gbc gabc 0 0 xgabc 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 of Example 3.3. 3.2. Structure. The next result shows that if I is squarefree, then F is essentially generated in degree 1 for any multiplication on it: Proposition 3.4. Let I ⊂ S be a squarefree monomial ideal with minimal free resolution F. Let ∗ be a multiplication on F. Then every homogeneous element f ∈ F of squarefree degree can be written as f= X |g1,j ∗ (g2,j ∗ (· · · (g|f |−1,j ∗ g|f |,j ) · · · )|sqf , j for gℓ,j ∈ F1 for 1 ≤ ℓ ≤ |f | and all j. Proof. Let g1,1 ∈ F1 be a basis element with deg g1,1 ≤ f . Such an element exists, because f is a linear combination of basis elements, and the degree of each basis element is an lcm of degrees of basis elements of F1 . Note that deg g1,1 ≤ deg f implies that f = |∂(g1,1 ) ∗ f |sqf . Hence it holds that r := f − |g1,1 ∗ ∂f |sqf = |∂(g1,1 ∗ f )|sqf = ∂(|g1,1 ∗ f |sqf ) ∈ mF. In the last step we used that F is minimal, so ∂F ⊂ mF. Now, ∂f has a smaller homological degree than f , so it can be decomposed into a product by induction. Moreover, note that r ∈ mF implies that r is a S-linear combination of elements of Fi of strictly smaller degree than f . So these elements can be decomposed by induction as well. To conclude that f can be decomposed as claimed, we note the following fact: Whenever for f ′ ∈ F and a monomial m ∈ S it holds that m|f ′ |sqf is squarefree, then it follows that m|f ′ |sqf = |m(|f ′ |sqf )|sqf = |mf ′ |sqf .  The preceding result does not hold if I not squarefree. Example 3.5. Consider the multiplication constructed in Example 3.3. Under that multiplication, gbc cannot be written as a product of elements of degree one. We will see in Section 6 below that every monomial ideal admits at least one multiplication which satisfies the conclusion of Proposition 3.4. This is no longer true for more general ideals. Indeed, if I ⊂ S is a homogeneous ideal with three generators satisfying the conclusion of Proposition 3.4, then the third Betti number is bounded by the number of non-associative, graded-commutative products of three elements. On the other hand, it is a celebrated result of Bruns [Bru76] that any free resolution can be modified to yield a resolution of an ideal with three generators, so there does not exist a global bound on the third Betti number. The preceding proposition leads to the following structure theorem for DGA structures on F: STRUCTURE OF DGA STRUCTURES 9 Theorem 3.6. Let I ⊂ S be a squarefree monomial ideal. Assume that the minimal resolution F of S/I is a multigraded DGA. Then there exists a DG-ideal J ⊂ T in the Taylor resolution of S/I, such that ∼ F = T/J as multigraded DGAs over S. −1 Proof. Let Q := S[x−1 1 , . . . , xn ] denote the Laurent polynomial ring. As T ⊗S Q is an exterior algebra over Q, we can define a map ϕ : T ⊗S Q → F ⊗S Q of DGAs by setting ϕ(gm ) := gm , where the latter is interpreted as element of the algebraic Scarf complex of S/I. We need to show that ϕ restricts to a map ϕ : T → F, where we consider T and F as subalgebras of T ⊗ Q and F ⊗ Q in the natural way. For this, consider a subset A = {m1 < m2 < . . . < ms } ⊆ G(I). It holds that m1 ∨ · · · ∨ ms gA = gm1 ∗ gm2 ∗ · · · ∗ gms , m1 · · · ms and, consequently, that m1 ∨ · · · ∨ ms ϕ1 (gm1 ) ∗ ϕ1 (gm2 ) · · · ϕ(gms ) ϕ(gA ) = m1 · · · ms = |ϕ1 (gm1 ) ∗ ϕ1 (gm2 ) · · · ϕ(gms )|sqf . The last expression is clearly contained in F, and as T is generated by the elements (gA )A⊆G(I) it follows that ϕ maps T to F. It remains to show that the restriction of ϕ to T is surjective onto F. But this is clear from Proposition 3.4, because ϕ is surjective in homological degree 1 and it commutes with taking the squarefree part (the latter holds for any homogeneous morphism).  The following example shows that one cannot omit the assumption of squarefreeness in the preceding Theorem. Example 3.7. We continue with Example 3.3 and consider the DGAs structure on F constructed in that example. Let ϕ : T ⊗ Q → F ⊗ Q the map from the proof of Theorem 3.6. Then 1 1 z y ϕ(gbc ) = ϕ( gb ∗ gc ) = ϕ(gb ) ∗ ϕ(gc ) = − gab + gac , x x x x which is not contained in F. So ϕ does not restrict to a map T → F in this case. In fact, F is not the image of T under any map of DGAs, because F ⊗ Q is not generated in homological degree 1. The next example illustrates how one can use Theorem 3.6 to prove that a given ideal does not admit a (multigraded) minimal DGA resolution. Example 3.8. Let I ⊆ S = Q[x1 , x2 , x3 , x4 , x5 , x6 ] be the ideal generated by a := x1 x2 , b := x2 x3 , c := x3 x4 , d := x4 x5 and e := x5 x6 . This is a well-known example by Avramov which does not admit a minimal DGA resolution [Avr81, Example I]. Assume for the contrary that its minimal free resolution F admits a DGA structure. Then by Theorem 3.6 there exists a DG-ideal J ⊂ T in its Taylor S resolution such that F = T/J. We have that β3,(1,1,1,1,0,0) (S/I) = 0 and hence gabc ∈ J. As J is a DG-ideal, it also holds that (∂gabc ) ∗ ge ∈ J. Moreover, gabc ∗ gd = x3 gabcd ∈ J. As T/J is free, J is saturated with respect to the 10 LUKAS KATTHÄN S variables and hence also gabcd ∈ J. Similarly, β3,(0,0,1,1,1,1) (S/I) = 0 implies that ga ∗ (∂gcde ) ∈ J and gbcde ∈ J. It follows that f := (∂gabc ) ∗ ge − ga ∗ (∂gcde ) − x1 ∂gbcde − x4 ∂gabcd = x2 x23 gabe − x22 x3 gade + x1 x2 x3 gbde − x2 x3 x4 gabd is contained in J. On the other hand, the sets {a, b, e}, {a, d, e}, {b, d, e} and {a, b, d} lie in the Scarf complex of I, so the images of the corresponding generators of T are part of a basis of F. But this is a contradiction, because f is a relation between these elements. 4. Consequences of the existence 4.1. Betti numbers. In this section, we prove the following characterization of the possible Betti vectors of squarefree monomial ideals admitting minimal DGA resolutions. Theorem 4.1. Let f = (1, f1 , f2 , . . . ) ∈ Nν be a finite sequence of natural numbers. Then the following conditions are equivalent: (1) There exists a squarefree monomial ideal I in some polynomial ring S whose minimal free resolution is a DGA, such that βiS (S/I) = fi for all i. (2) f is the f -vector of a simplicial complex ∆ which is a cone. Recall that the f -vectors of simplicial complexes are characterized by the Kruskal-Katona theorem [Sta96, Theorem 2.1]. From this one can derive an explicit characterization of the f -vectors of cones, see also [Kal85]. For the implication “1) ⇒ 2)” we use the following general result. L Proposition 4.2. Let A = k≥0 Ak be a DGA over a field k. Assume that A0 = k, that A is generated in degree 1, that dimk A1 ≤ ∞ and finally that the differential of A is not identically zero. Then the Hilbert function of A equals the f -vector of a simplicial complex which is a cone. Aramova, Herzog and Hibi [AHH97, Theorem 4.1] characterize the Hilbert functions of graded-commutative algebras which are generated in degree one. These are indeed the same as f -vectors of simplicial complexes. Our result extends this, as we show showing that the existence of a non-zero differential yields a further restriction to the Hilbert series. Proof. Let C ⊂ A be the subalgebra of cycles. We claim that C is also generated in degree 1 and that A ∼ = C ⊕ C[−1] as k-vector space, where C[−1] denotes the vector space C with degrees shifted by one. These two claims are sufficient to prove our result. Indeed, by the above mentioned [AHH97, Theorem 4.1], the Hilbert function of C is the f -vector of some simplicial complex ∆. An elementary computation shows that in this case the Hilbert function of A ∼ = C ⊕ C[−1] is the f -vector of the cone over ∆. Now we turn to the proof of our claims. Let C1 ⊂ A1 be the space of cycles in A1 and write C ′ for the algebra generated by them. By assumption, the differential ∂ of A does not vanish identically. As A is generated in degree one, the Leibniz rule implies that the first component ∂1 : A1 → A0 = k is nonzero, hence there exists an element f ∈ A1 with ∂f = 1 and (thus) A1 = C1 ⊕ kf . The latter implies that A ∼ = C ′ + f C ′. STRUCTURE OF DGA STRUCTURES 11 Hence any element a ∈ A can be written as a = c1 + f c2 with c1 , c2 ∈ C ′ . In particular, if a ∈ C, then 0 = ∂a = c2 , so a = c1 ∈ C ′ and thus C = C ′ is generated in degree one. For the second claim, we first note that A ∼ = C ⊕ f C. Indeed, for any f c ∈ C ′ ∩ ′ f C it holds that 0 = ∂(f c) = c. Finally, it remains to show that f C ∼ = C(−1). For this it is sufficient to show that the multiplication by f is injective on C. But this is clear, because ∂(f c) = c for any c ∈ C, so the differential provides a left-inverse.  Proof of Theorem 4.1. 1) ⇒ 2) Let Q be the field of fractions of S and let F the minimal free resolution of I. It follows from Proposition 3.4 that F ⊗S Q is generated in degree 1 as Q-algebra. Hence the claim is immediate from Proposition 4.2, applied to F ⊗S Q. 2) ⇒ 1) Set k := f1 . Let ∆ ⊂ 2k be a simplicial complex whose f -vector equals f which is a cone with apex 1. We can find a monomial ideal I in some polynomial ring S, such that the lcm-lattice of I equals the face lattice of ∆, augmented by a maximal element (cf. [IKMF14, Theorem 3.4], [Map13]). Then ∆ is the Scarf complex of I. As ∆ is acyclic, its f -vector equals the Betti vector of I (this can be seen by computing the Betti numbers via the lcm lattice, see [GPW99, Theorem 2.1]). It remains to show that the minimal free resolution of I admits a DGA structure. Let T be Taylor resolution of I. We identify the set of generators of I with the set [k] of vertices of ∆. To construct the minimal free resolution of S/I we use discrete Morse theory [JW09; Skö06]. Let us recall the relevant aspects of this technique. Let G be the directed graph with vertex set 2[k] and edges from V to W whenever the coefficient of gV in the expansion of ∂gW is nonzero. A Morse matching M is a collection of edges (V, W ) in this graph with the following properties: (a) M is a matching, i.e. the edges are disjoint, (b) reversing all edges of M in G results in an acyclic graph, and (c) deg gV = deg gW for all (V, W ) ∈ M. Given such a Morse matching, define JM := spank {gW , ∂gW : ∃V ∈ 2[k] , (V, W ) ∈ M}. Then the complex TM := T/JM is a free resolution of S/I, and it has a k-basis is given by the images of gW for those W ∈ 2[k] which do not appear in the matching. In our situation we define the Morse matching: M := {(gW \{1} , gW ) : W ⊂ [k], W ∈ / ∆, 1 ∈ W } Recall that we assumed 1 to be the apex of ∆, so W ∈ / ∆ and 1 ∈ W imply that W \ {1} ∈ / ∆. This is clearly a matching, and it is easy to see that it satisfies property (b). For property (c), recall that the lcm lattice LI of I is ∆, together with an additional maximal element. We are only matching generators which are not in ∆, so the degrees of all those generators correspond to the maximal element of LI , and thus they are equal. Finally, the unmatched generators correspond exactly to the faces of ∆. As we know that the Betti vector of I equals the f -vector of ∆, we can conclude 12 LUKAS KATTHÄN that TM := T/JM is a minimal free resolution of S/I. On the other hand, by our choice of the matching M, JM is in fact a DG-ideal and hence TM is a DG-algebra.  We give an example to show that the assumptions of I being squarefree and admitting a minimal DGA resolution are both necessary in Theorem 4.1. Example 4.3. Consider the ideal I := hx1 x2 , x2 x3 , x3 x4 , x4 x5 , x5 x6 , x6 x1 i ⊂ Q[x1 , . . . , x6 ]. Using Macaulay2 [GS], one can compute that its total Betti numbers are (1, 6, 9, 6, 2). We claim that this is not the f -vector of any simplicial complex. Indeed, such a simplicial complex would have two 3-simplices. As each 3-simplex has three 2-faces, and the two 3-simplices can only share one 2-face, we would need a total of at least seven 2-faces, but we have only six. On the other hand, by Theorem 2.1 there exists a monomial m ∈ S such that mI admits a minimal DGA resolution. However, mI is not squarefree, and indeed its Betti vector still does not satisfy the conclusion of Theorem 4.1, as it conicides with the Betti vector of I. 4.2. Subadditivity of syzygies. For a monomial ideal I ⊂ S and 0 ≤ i ≤ pdim S/I we define S ti := max{j : βi,j (S/I) 6= 0}. We say that the syzygies of I are subadditive when tb ≤ ta + tb−a for all a, b such that 1 ≤ a < b ≤ pdim S/I. Not every ideal has this property [ACI15], but among monomial ideals no counterexample is known. Here, we show that for squarefree monomial ideals, the existence of a DGA structure on the minimal free resolution implies the subadditivity of syzygies. Proposition 4.4. If I ⊂ S is a squarefree monomial ideal which admits a minimal DGA resolution F, then its syzygies are subadditive. The following lemma is needed for the proof of this result. Lemma 4.5. Let f, g ∈ F be homogeneous. If |f ∗ g|sqf ∈ / mF, then there exist f ′ , g ′ ∈ F \ mF of the same homological degrees as f and g, respectively, such that deg(f ) ∨ deg(g) = deg(f ′ ) ∨ deg(g ′ ). P P Proof. By choosing a basis of F, we may write f = i λi ci fi and g = j µj dj gj , with λi , µi ∈ k, ci , dj ∈ S monomials and fi , gj ∈ F \ mF. By our assumption, P / mF. So at least one summand is not contained |f ∗g|sqf = i,j λi µj |cidj fi ∗gj |sqf ∈ in mF, say |c1 d1 f1 ∗ g1 |sqf . It follows easily from the definition of the squarefree part that there exists a monomial m ∈ S such that |c1 d1 f1 ∗ g1 |sqf = m|f1 ∗ g1 |sqf . But this does not lie in mF, so we can conclude that m = 1 and the claim follows with f ′ := f1 and g ′ := g1 .  Proof of Proposition 4.4. Let f ∈ Fb be an element of total degree tb and we may assume that f ∈ / mF. By Proposition 3.4, we can write f as f= X |g1,j ∗ (g2,j ∗ (· · · (gi−1,j ∗ gi,j ) · · · )|sqf , j for gℓ,j ∈ F1 for 1 ≤ ℓ ≤ i and all j. As f ∈ / mF, the same holds for at least one summand, say for j = 1. STRUCTURE OF DGA STRUCTURES 13 Using that the multiplication on F is associative, we may rewrite that summand as |(g1,1 · · · ga,1 ) ∗ (ga+1,1 · · · gb,1)|sqf . Now we apply Lemma 4.5 to this product to obtain f ′ ∈ Fa and g ′ ∈ Fb−a which are both not contained in mF and satisfy deg f = deg(f ′ ) ∨ deg(g ′). Thus we conclude that tb = deg(f ) = deg(f ′ ) ∨ deg(g ′ ) ≤ deg(f ′ ) + deg(g ′) ≤ ta + tb−a  If we do not assume that F admits a DGA structure, then our methods still suffice to show the case a = 1. This was first shown by Herzog and Srinivasan in [HS15, Corollary 4] using a different method. Corollary 4.6. For a monomial ideal I ⊂ S, it holds that ti ≤ t1 + ti−1 for all 2 ≤ i ≤ pdim S/I. Proof. We may replace I by its polarization and so assume it is squarefree. Further, choose any multiplication on F. Now we just note that the proof of Proposition 4.4 does not require the multiplication to be associative if a = 1.  5. Strongly generic ideals A monomial ideal is called strongly generic if no variable appears with the same nonzero exponent in two distinct generators of I. This class of ideals was introduced and studied by Bayer, Peeva and Sturmfels [BPS98] 1, see also Chapter 6 of [MS05]. Strongly generic ideals have a number of desirable properties, and in particular their minimal free resolution is given by the algebraic Scarf complex [BPS98, Theorem 3.2]. However, this condition is not sufficient to ensure that the ideal admits a minimal DGA resolution. Theorem 5.1. The ideal hx2 , xy, y 2z 2 , zw, w 2 i ⊂ k[x, y, z, w] is strongly generic, but its minimal free resolution does not admit the structure of a DGA, whose multiplication respects the standard Z-grading. This example is a variation of Example 3.8. The proof of Theorem 5.1 is very technical, so we postpone it and discuss the result first. Remark 5.2. Corollary 3.6 in [BPS98] states that strongly generic monomial ideals admit a minimal DGA resolution. I was informed by I. Peeva that the authors of that article are aware that the claim does not hold as stated and that the statement and the proof were supposed to include an additional combinatorial condition. Theorem 5.1 implies that various kinds of resolutions do not admit a DGA structure in general. Corollary 5.3. (1) There exists a monomial ideal whose hull resolution [BS98] does not admit a DGA structure. (2) There exists a monomial ideal whose Lyubeznik resolution [Lyu88] does not admit a DGA structure. 1In [BPS98] these ideals are called generic. In the later article [MSY00] a weaker notion of genericity was introduced and the original one is called strongly generic since then. 14 LUKAS KATTHÄN (3) There exists a monomial ideal whose minimal free resolution is supported on a simplicial complex (and in particular cellular) [BS98], but it does not admit a DGA structure. Proof. The ideal of Theorem 5.1 provides the counterexample in all three cases. This ideal is generic, so its minimal free resolution is supported in its Scarf complex and it coincides with its hull resolution [MS05, Theorem 6.13]. The Lyubeznik resolution depends on the choice of a total order on the generators. One can check that the Lyubeznik resolution with respect to the order xy ≺ zw ≺ x2 ≺ y 2z 2 ≺ w 2 is minimal.  In fact, the minimal free resolution of Avramov’s Example 3.8 can also be given the structure of a cellular resolution, though not with a simplicial complex as support. Proof of Theorem 5.1. In this proof we use both the multigrading and the standard Z-grading, so we refer to the latter as the total degree. Let S = k[x, y, z, w] and let I be the ideal of the statement. We give names to its generators as follows: a := x2 , b := xy, c := y 2z 2 , d := zw, e := w 2 The Scarf complex ∆I is the simplicial complex with the facets {b, c, d} and {a, b, d, e}. As mentioned above, the minimal free resolution F of S/I is given by its algebraic Scarf complex. The generators of F are listed in Table 2, together with their total degrees. Assume that F admits an associative multiplication which respects the Zgrading, which we denote by ∗. The map ∗ : F ⊗ F → F can be decomposed into its homogeneous components with respect to the Z4 -grading. We write × for the component of multidegree (0, 0, 0, 0). Because the differential on F respects the multigrading, × also satisfies the Leibniz rule and lifts the multiplication on S/I. Hence, by the uniqueness of the multiplication, there exists a map σ : F ⊗ F → F[1] such that a ∗ b = a × b + δσ(a, b) for a, b ∈ F, where δσ = ∂ ◦ σ + σ ◦ ∂. Moreover, the component of σ in multidegree (0, 0, 0, 0) vanishes, because ∗ and × coincide in this degree. We proceed by proving a series of claims. Claim 1. For i, j, k ∈ {a, b, d, e}, all products of the form gi × gj and gi × gjk coincide with the corresponding products from the Taylor resolution. If I were squarefree, then this would follow from Proposition 3.1. However, as I is not squarefree, we need to verify this. We start in homological degree 2. For any i, j ∈ {a, b, d, e}, i 6= j, one can verify that the product gi × gj is a multiple of gcd(i, j)gij , because there is no other element of the correct multidegree. Then the Leibniz rule implies that gi × gj = ± gcd(i, j)gij . Moreover gi × gi = 0, because ∗ and thus × was assumed to be graded-commutative. Next, gi ×gij = 0 for all i, j because it is clearly a cycle, and the only boundary of homological degree 3 is ∂gabde , which has a different multidegree. Moreover, for pairwise distinct i, j, k ∈ {a, b, d, e}, it follows again by inspection that gi × gjk is a multiple of gcd(i, lcm(j, k))gijk because this is the only element with the STRUCTURE OF DGA STRUCTURES ga , gb , gd , ge gc gab , gde gad , gae , gbd , gbe gbc , gcd gijk 6= gbcd gbcd gabde Table 2. The degrees of the 15 2 3 3 4 5 5 6 6 generators of F. required multidegree, and again the Leibniz rule determines the coefficient to be ±1. In fact, the other products in the subalgebra generated by ga , gb , gd and gd also coincide with the product from the Taylor resolution, but we do not need this. Claim 2. It holds that (ga × gc ) × ge − ga × (gc × ge ) = yz∂gabde By considering the multigrading and using the Leibnitz rule as above, one can show that ga × gc = yz 2 gab + xgbc and gc × ge = wgcd + y 2 zgde . Using this and Claim 1, one can compute that ∂(gbc × ge ) = ∂(wgbcd + yzgbde ). This implies that gbc × ge = wgbcd + yzgbde + ∂(f ) for some f ∈ F4 . But the x-component of the multidegree of every element in F4 is at least 2, hence f = 0. Now we can compute that (ga × gc ) × ge = yz 2 gab × ge + xgbc × ge = yz 2 gabe + xwgbcd + xyzgbde . Using essentially the same reasoning one can also show that ga × (gc × ge ) = y 2zgade + xwgbcd + yzwgabd . Hence it follows that (ga × gc ) × ge − ga × (gc × ge ) = yz∂gabde . Claim 3. For any f ∈ F it holds that σ(1k , f ) = σ(f, 1k ) = 0. For f ∈ F it holds that f = 1k ∗ f = 1k × f + ∂σ(1k , f ) + σ(∂1k , f ) +σ(1k , ∂f ) | {z =0 } and hence ∂σ(1k , f ) + σ(1k , ∂f ) = 0. We proceed now by induction on |f |. Consider the case |f | = 0, i.e f = 1k . Then σ(1k , 1k ) has multidegree (0, 0, 0, 0) and homological degree 1, which is only possible if σ(1k , 1k ) = 0. Assume now that |f | = i and σ(1k , g) = 0 for all g ∈ F with |g| < i. Then ∂σ(1k , f ) = −σ(1k , ∂f ) = 0 by the induction hypothesis. As F is acyclic, there exist an h ∈ F with |h| = |f | + 2 such that ∂h = σ(1k , f ). We may assume that f is a generator of F. Now, inspection of Table 2 shows that for no generator f of F there exist an element h with deg h = deg f and |h| = |f | + 2. Hence σ(1k , f ) = 0. Claim 4. It holds that σ(gi , gj ) = 0 for i, j 6= c. 16 LUKAS KATTHÄN If σ(gi , gj ) 6= 0 for i, j 6= c, then it is an element of total degree 4 and homological degree 3. But by Table 2, no such element exists. Claim 5. It holds that gi ∗ gj = gi × gj for i, j 6= c. In general we have that gi ∗ gj = gi × gj + ∂σ(gi , gj ) + σ(∂gi , gj ) + σ(gi , ∂gj ). All terms involving σ vanish because of Claim 3 and Claim 4. Claim 6. For i, j, k ∈ {a, b, d, e}, it holds that σ(gi , gjk ) = 0. First, assume that i = j or i = k. We only consider the case i = j, the other case is similar. For this, we compute that Cl. 5 Cl. 1 0 = (gi ∗ gi ) ∗ gj = gi ∗ (gi ∗ gj ) = gi ∗ (gi × gj ) = ±µgi ∗ gij Cl. 3 = ±µ(gi × gij +δσ(gi , gij )) = ±µ∂σ(gi , gij ), | {z =0 } where µ = gcd(i, j). The differential is injective in homological degree 4, hence ∂σ(gi , gij ) = 0 implies that σ(gi , gij ) = 0. Now we consider the case that i, j, k are all different. Then {i, j, k} contains either a and b, or d and e. We only consider the first case, the other one is similar. If {j, k} = {a, b} then σ(gi , gab ) = 0 holds for degree reasons, see Table 2. So assume that i ∈ {a, b}. Again, we assume without loss of generality that i = a. Then either j or k equals b, say j. We compute that Cl. 5 (ga ∗ gb ) ∗ gk = (ga × gb ) ∗ gk = xgab ∗ gk = xgab × gk + xδσ(gab , gk ) (∗) = xgabk + xδσ(gab , gk ) Cl. 4 = xgabk + x∂ σ(gab , gk ), | {z =0 } where in (∗) we used Claim 1 and that gcd(x, k) = 1 for k ∈ {d, e}. On the other hand, a similar computation shows that ga ∗ (gb ∗ gk ) = xgabk + ∂σ(ga , gbk ), where we use that gcd(b, k) = 1. The assumption that ∗ is associative implies that ∂σ(ga , gbk ) = 0 and thus σ(ga , gbk ) because ∂ is injective in homological degree 4. Claim 7. It holds that ga ∗ (gc ∗ ge ) − (ga ∗ gc ) ∗ ge 6= 0. Let us compute the associator of ga , gc and ge : ga ∗ (gc ∗ ge ) − (ga ∗ gc ) ∗ ge = ga × (gc × ge ) − (ga × gc ) × ge + δσ(ga , gc × ge ) − δσ(ga × gc , ge )+ ga × δσ(gc , ge ) − δσ(ga , gc ) × ge + δσ(ga , δσ(gc , ge )) − δσ(δσ(ga , gc ), ge ) We know that ga × (gc × ge ) − (ga × gc ) × ge = yz∂gabde and we want to show that this term does not cancel against any other term. For this we need to consider the component of ga ∗ (gc ∗ ge ) − (ga ∗ gc ) ∗ ge in multidegree (0, 0, 0, 0). As σ has no component in this multidegree, the summands having only one STRUCTURE OF DGA STRUCTURES 17 σ cannot contribute. This it remains to consider the last two terms, namely δσ(ga , δσ(gc , ge )) and δσ(δσ(ga , gc ), ge ). By Claim 3 it holds that δσ(ga , δσ(gc , ge )) = ∂σ(ga , ∂σ(gc , ge )). Further, σ(gc , ge ) has homological degree 3, hence it is of the form σ(gc , ge ) = λgbcd + r where λ ∈ S and r is a sum of terms not involving c. Now it holds that ∂σ(gc , ge ) =λ∂gbcd + ∂r =λxgcd + λwgbc + terms not involving c Using Claim 6 it follows that ∂σ(ga , ∂σ(gc , ge )) = λx∂σ(ga , gcd ) + λw∂σ(ga , gbc ) = λ(λ1 x + λ2 w)∂gabde , for some λ1 , λ2 ∈ S. Here we used that gabde is the only generator in homological degree 4. These terms cannot cancel against yz∂gabde , because they are multiples of x or w, respectively. The same arguments apply to δσ(δσ(ga , gc ), ge ).  Remark 5.4. Unfortunately, it does not seem possible to use Avramov’s obstructions from [Avr81] to prove the preceding theorem. At least, I could not find a suitable regular sequence f1 , . . . , fr in the ideal to consider R = S/(f1 , . . . , fs ). 6. The lcm lattice and non-sqarefree ideals The lcm lattice LI of a monomial ideal is the lattice of all least common multiples of subsets of the minimal generators of I. The lcm lattice was introduced in [GPW99], were it is also proven that its isomorphism type determines the minimal free resolution of I. So one might be led to conjecture that it also determines the possible multiplication on F. However, it is immediately clear from Theorem 2.1 that is not true. Nevertheless, we can identify a class of multiplications which is compatible with the lcm lattice: Definition 6.1. A multiplication ∗ on F is called supportive if for all a, b ∈ F there exists a c ∈ F with deg c ≤ (deg a) ∨ (deg b), such that a ∗ b = mc for a monomial m ∈ S. Example 6.2. The DGA structure on the Taylor resolution is supportive, but the multiplication constructed in Example 3.3 is not supportive. For squarefree monomial ideals, being supportive is not a restriction. Lemma 6.3. If I ⊆ S is a squarefree monomial ideal, then every multiplication on its minimal free resolution is supportive. Proof. Let F be the minimal free resolution of S/I and let B be an S-basis for it. Every element of B has a squarefree degree, we may apply Lemma 1.4. It follows that for any g1 , g2 ∈ B it holds that g1 ∗ g2 = mh for a monomial m and an element h ∈ F with deg h ≤ (deg g1 + deg g2 ) ∧ (1, . . . , 1) = deg g1 ∨ deg g2 .  The next result shows that supportive multiplications are essentially determined by the isomorphism type of the lcm-lattice of I. This is our main motivation for introducing this notion. Proposition 6.4. Let I and I ′ be two monomial ideals in two polynomial rings S and S ′ , respectively, whose lcm-lattices are isomorphic. Then every supportive multiplication on the minimal free resolution of S/I can be relabeled to a supportive multiplication on the minimal free resolution of S ′ /I ′ . 18 LUKAS KATTHÄN Proof. Let ν : LI → LI ′ be the isomorphism. We recall the “relabeling” construction, which was introduced in [GPW99]. Fix a basis B of the minimal free resolution F of S/I. We express the differential ∂ of F in this basis: ∂g = X chg xdeg(g)−deg(h) h h∈B with g ∈ B, chg ∈ k. The relabeled resolution ν(F) is the free S ′ -module with the basis {ḡ : g ∈ B} and deg ḡ = ν(deg g). Here, by ḡ we mean a new basis element. The differential on ν(F) is given by X h deg(ḡ)−deg(h̄) ¯ := ∂ḡ c x h̄. g h∈B This is well-defined because deg h ≤ deg g implies that deg h̄ = ν(deg h) ≤ ν(deg g) = deg ḡ. By [GPW99, Theorem 3.3], ν(F) is indeed a minimal free resolution of S ′ /I ′ . Our definition the relabeling of the multiplication is analogous: If X g1 ∗ g2 = chg1 ,g2 xdeg(g1 )+deg(g2 )−deg(h) h, h∈B then we set ḡ1 ∗ ḡ2 := X chg1 ,g2 xdeg(ḡ1 )+deg(ḡ2 )−deg(h̄) h̄. h∈B To see that this is well-defined, we compute that deg ḡ1 + deg ḡ2 ≥ deg ḡ1 ∨ deg ḡ2 = ν(deg g1 ) ∨ ν(deg g2 ) (1) (∗∗) (∗) = ν(deg g1 ∨ deg g2 ) ≥ ν(deg h) = deg h̄. Here, the equality marked with (∗) holds because ν is an isomorphism of lattices. Moreover, the equality marked with (∗∗) holds because the multiplication is supportive. It is clear that the relabeled multiplication is graded-commutative and satisfies the Leibniz rule, because the structure constants are the same as for the multiplication on F. Finally, the computation (1) also shows that it is supportive.  The last two results have a number of immediate corollaries. Corollary 6.5. Every monomial ideal admits a supportive multiplication on its minimal free resolution. Proof. Choose any multiplication on the minimal free resolution of the polarization of I and relabel it.  Corollary 6.6. Any supportive multiplication satisfies the conclusion of Proposition 3.4. Proof. The conclusion of Proposition 3.4 is clearly invariant under relabeling. Hence relabeling the supportive multiplication to the minimal free resolution of the polarization of I yields the claim.  Corollary 6.7. Let I and I ′ be two monomial ideals with isomorphic lcm lattices and assume that I is squarefree. If I admits a minimal DGA resolution, then so does I ′ . Proof. Associativity is invariant under relabeling.  REFERENCES 19 We close the section by giving an example which illustrates that the last corollary cannot be strengthened by considering the Betti poset [CM14a; TV15; CM14b]. Recall that the Betti poset of a monomial ideal is the subposet of the lcm lattice consisting of those multidegrees in which are nonzero Betti numbers. Example 6.8. The ideal hx2 , xy, y 2z 2 , zw, w 2i ⊂ k[x, y, z, w] from Theorem 5.1 does not admit a minimal DGA resolution. As argued in the proof of that theorem, its minimal free resolution is given by its algebraic Scarf complex, so in particular its Betti poset is the face poset of its Scarf complex. However, that Scarf complex is a cone (with apex b in the notation of that proof). Hence the construction in the proof of the second implication of Theorem 4.1 yields an example of a squarefree monomial ideal admitting a minimal DGA resolution but having the same Betti poset. Acknowledgments The author is indebted to Volkmar Welker for the suggestion to look for a Macaulay-type theorem for DGA resolutions, which eventually led to Theorem 4.1. References [AHH97] [Avr74] [Avr81] [ACI15] [BPS98] [BS98] [Bru76] [BE77] [CM14a] [CM14b] [GPW99] A. Aramova, J. Herzog, and T. Hibi. “Gotzmann theorems for exterior algebras and combinatorics”. In: Journal of Algebra 191.1 (1997), pp. 174–211. doi: 10.1006/jabr.1996.6903. L. L. Avramov. “The Hopf algebra of a local ring”. In: Izv. Akad. Nauk SSSR Ser. Mat. 38 (1974), pp. 253–277. L. L. Avramov. “Obstructions to the existence of multiplicative structures on minimal free resolutions”. In: Amer. J. Math. 103.1 (1981), pp. 1–31. doi: 10.2307/2374187. L. L. Avramov, A. Conca, and S. B. Iyengar. “Subadditivity of syzygies of Koszul algebras”. In: Mathematische Annalen 361.1 (2015), pp. 511–534. issn: 1432-1807. doi: 10.1007/s00208-014-1060-4. D. Bayer, I. Peeva, and B. Sturmfels. “Monomial resolutions”. In: Math. Res. Lett. 5.1-2 (1998), pp. 31–46. doi: 10.4310/MRL.1998.v5.n1.a3. D. Bayer and B. Sturmfels. “Cellular resolutions of monomial modules.” In: J. Reine Angew. Math. 502 (1998), pp. 123–140. doi: 10.1515/crll.1998.083 W. Bruns. ““Jede” endliche freie Auflösung ist freie Auflösung eines von drei Elementen erzeugten Ideals”. In: Journal of Algebra 39.2 (1976), pp. 429–439. doi: 10.1016/0021-8693(76)90047-8. D. A. Buchsbaum and D. Eisenbud. “Algebra structures for finite free resolutions, and some structure theorems for ideals of codimension 3”. In: Amer. J. Math. 99.3 (1977), pp. 447–485. T. B. Clark and S. Mapes. “Rigid monomial ideals”. In: Journal of Commutative Algebra 6.1 (2014), pp. 33–51. doi: 10.1216/JCA-2014-6-1-33. T. B. Clark and S. Mapes. “The Betti poset in monomial resolutions”. In: Preprint (2014). arXiv:1407.5702. V. Gasharov, I. Peeva, and V. Welker. “The LCM-lattice in monomial resolutions”. In: Mathematical Research Letters 6 (1999), pp. 521–532. doi: 10.4310/MRL.1999.v6.n5.a5. 20 [Gem76] REFERENCES D. Gemeda. “Multiplicative structure of finite free resolutions of ideals generated by monomials in an R-sequence”. Ph.D. Thesis. Brandeis University, 1976. [GW78] S. Goto and K. Watanabe. “On graded rings, II (Zn -graded rings)”. In: Tokyo J. Math 1.2 (1978), pp. 237–261. doi: 10.3836/tjm/1270216496. [GS] D. R. Grayson and M. E. Stillman. Macaulay2, a software system for research in algebraic geometry. url: http://www.math.uiuc.edu/Macaulay2/. [HS15] J. Herzog and H. Srinivasan. “On the subadditivity problem for maximal shifts in free resolutions”. In: Commutative Algebra and Noncommutative Algebraic Geometry II. Vol. 68. MSRI Publications, 2015. arXiv:1303.6214. [IKMF14] B. Ichim, L. Katthän, and J. J. Moyano Fernández. “Stanley depth and the lcm-lattice”. In: Preprint (2014). arXiv:1405.3602. [JW09] M. Jöllenbeck and V. Welker. Minimal resolutions via algebraic discrete Morse theory. Vol. 197. Memoirs of the AMS 923. American Mathematical Society, 2009. doi: 10.1090/memo/0923. [Kal85] G. Kalai. “f -Vectors of acyclic complexes”. In: Discrete mathematics 55.1 (1985), pp. 97–99. doi: 10.1016/S0012-365X(85)80024-8. [Kus94] A. Kustin. “The Minimal Resolution of a Codimension Four Almost Complete Intersection Is a DG-Algebra”. In: Journal of Algebra 168.2 (1994), pp. 371–399. doi: 10.1006/jabr.1994.1235. [Lyu88] G. Lyubeznik. “A new explicit finite free resolution of ideals generated by monomials in an R-sequence”. In: Journal of Pure and Applied Algebra 51.1 (1988), pp. 193–195. doi: 10.1016/0022-4049(88)90088-6. [Map13] S. Mapes. “Finite atomic lattices and resolutions of monomial ideals”. In: Journal of Algebra 379 (2013), pp. 259–276. doi: 10.1016/j.jalgebra.2013.01.005. [MS05] E. Miller and B. Sturmfels. Combinatorial commutative algebra. Springer, 2005. doi: 10.1007/b138602. [MSY00] E. Miller, B. Sturmfels, and K. Yanagawa. “Generic and Cogeneric Monomial Ideals”. In: Journal of Symbolic Computation 29.4 (2000), pp. 691–708. doi: 10.1006/jsco.1999.0290. [Pee96] I. Peeva. “0-Borel Fixed Ideals”. In: Journal of Algebra 184.3 (1996), pp. 945–984. doi: 10.1006/jabr.1996.0293. [Pee10] I. Peeva. Graded syzygies. Springer, 2010. doi: 10.1007/978-0-85729-177-6. [Skö06] E. Sköldberg. “Morse theory from an algebraic viewpoint”. In: Transactions of the American Mathematical Society 358.1 (2006), pp. 115– 129. doi: 10.1090/S0002-9947-05-04079-1. [Skö11] E. Sköldberg. “Resolutions of modules with initially linear syzygies”. In: Preprint (2011). arXiv:1106.1913. [Skö16] E. Sköldberg. “The minimal resolution of a cointerval edge ideal is multiplicative”. In: Preprint (2016). arXiv:1609.07356. [Sta96] R. P. Stanley. Combinatorics and commutative algebra. 2nd Ed. Vol. 41. Progress in Mathematics. Birkhäuser Boston, Inc., Boston, 1996. [TV15] A. Tchernev and M. Varisco. “Modules over categories and Betti posets of monomial ideals”. In: Proceedings of the American Mathematical Society 143.12 (2015), pp. 5113–5128. doi: 10.1090/proc/12643. REFERENCES FB 12 – Institut für Mathematik, Goethe-Universität Frankfurt, Germany E-mail address: [email protected] 21
0math.AC
arXiv:1602.06569v3 [math.AG] 3 Nov 2016 SMOOTH SCHEME MORPHISMS: A FRESH VIEW PETER M. JOHNSON Abstract. Relations between some kinds of formal and standard smoothness, for morphisms of schemes, are clarified in surprisingly simple and direct ways, bypassing much of the customarily employed machinery. Even the deep localto-global property of formal smoothness has a fairly elementary proof, under mild additional hypotheses. 1. Introduction Using methods as elementary as possible, accessible to those having only a basic understanding of scheme theory, we present efficient new proofs of the equivalence of some of the main kinds of smoothness of scheme morphisms. While smoothness is clearly important in algebraic geometry, there is no general agreement about which among several seemingly different definitions should be chosen as the basic one that best expresses the concept. In certain situations, one approach to smoothness can be distinctly easier to work with than others, so it is useful to make transitions whenever convenient. Our aim is to make such processes thoroughly transparent. We innovate by proving key results using machinery so limited that concepts such as dimension, tangent spaces, fibres, regularity and flatness do not appear. Discussion of those, as well as the important topic of étale morphisms, has been relegated to another article on consequences and further characterizations of smoothness. Only trivial facts will be cited, except in many non-essential comments where various concepts and results are presupposed in order to make comparisons with other work. Kähler differentials are treated as forming modules rather than sheaves, and will play an important role in proofs. Unlike much written in this area, there will be no assumptions or reductions involving Noetherianity. Although they are useful for clarifying some aspects of smoothness, Grothendieck topologies other than the Zariski topology will not be treated here. Stimulus for writing this article came from examining standard sources selected from a vast literature, notably Görtz and Wedhorn [3] and Vakil [12] as well as the encyclopedic Stacks Project book [11] and EGA [1]. The first two provide motivation and additional details, important for elucidating the significance of smoothness. Except where noted, our definitions coincide with those of [11]. Some of the most relevant will be repeated below. For reasons of stability, references to [11] are given in the form [Tag ....], and can be consulted on-line. In [11], as in [1] and many other Date: November 7, 2016. 1991 Mathematics Subject Classification. 14B25 (Primary); 13N05. Key words and phrases. scheme morphism, smoothness, formally smooth, standard smooth, smooth locus, Kähler differentials. 1 2 PETER M. JOHNSON works (one interesting survey being [8]), further variations on notions of smoothness appear, often phrased in terms of certain kinds of intersections or using I-adic topology. Homological methods yield deeper results, some presented in [7]. Our scope is far more limited. Formal smoothness and standard smoothness will be regarded as properties of morphisms between schemes, to be studied from Zariski-local and stalk-local points of view as properties of (homo)morphisms of commutative rings. The first of these notions of smoothness, due to Grothendieck, has an intrinsic (presentationindependent) definition well suited for formal diagrammatic demonstrations. The other notion, seemingly more concrete, asserts the existence of presentations by generators and relations of a certain form. Precise details are given in the next section. A different approach, adopted for example in [11], takes smoothness to be at heart a property of the sheaf of differentials. To properly formalize the idea, the naive cotangent complex of a morphism [Tag 00S0] is introduced. This object is shown in [Tag 031J] to be in some sense trivial precisely when the morphism is formally smooth. An example in [Tag 0635], with a morphism not locally of finite type, shows that the full cotangent complex need not behave as well. However, smooth morphisms are by definition required to be locally finitely presented. In that case, a refined approach to differentials allows formal smoothness to be exploited in a previously unknown way, yielding a proof of the first theorem below. It then becomes easy to bypass the naive cotangent complex in proofs of results about smoothness, if one is willing to take the foundation stone of the theory to be Grothendieck’s abstract definition rather than one based explicitly on differentials. In what follows, the non-standard term ‘around x’ pertains to local properties, those that hold on some restriction U → V to affine open subschemes with x ∈ U , and on further such restrictions. We also write ‘at x’ for properties that are are even more local, defined from a single map OY,ϕ(x) → OX,x to the stalk at x from the stalk at ϕ(x). Such maps are local homomorphisms Rp′ → Sp of local rings. In the terminology just introduced, and with the definitions of smoothness as given in the next section, the first fundamental result is: Theorem 1. Let ϕ : X → Y be a scheme morphism, locally of finite presentation. For each point x of X, the following are equivalent: (a) ϕ is formally smooth around x; (b) ϕ is standard smooth around x; (c) ϕ is formally smooth at x; (d) ϕ is standard smooth at x. The x ∈ X satisfying these conditions form the point set of an open subscheme of X, the smooth locus of ϕ. When this is X, ϕ is said to be smooth. As a byproduct of the proof techniques, the idea of studying smoothness from given generators and relations can be justified. It will be clear after the proof of 1 that it is straightforward to test at stalks. We even obtain a formula, too cumbersome to be of practical use, for the smooth locus. Some open subsets of Spec (S) needed just below will be principal open sets D(f ), f ∈ S, while others are complements of closed sets V (I), I an ideal of S. SMOOTH SCHEME MORPHISMS: A FRESH VIEW 3 Theorem 2. If S ∼ = R[x1 , . . . xn ]/(f1 , . . . , fc ), the smooth locus of ϕ : Spec (S) → Spec (R) is a union of n+c open sets D(∆) ∩ V (I)c . Each ∆, a Jacobian c determinant, and I, an ideal of the form (I0 : I1 ), is defined by an explicit formula ∂fi involving the given fi ∈ R[x1 , . . . xn ] and their formal partial derivatives ∂x . j The final section concerns a distinctly deeper fundamental result: an arbitrary scheme morphism ϕ : X → Y is formally smooth precisely when it is locally formally smooth, by which we mean this holds around all points of X, with ‘around’ as defined above. Under an assumption that includes the case where ϕ is locally of finite type, we show that elementary methods, carefully deployed, yield a proof technically simpler than previously known ones. 2. Definitions and notation All rings considered will be commutative algebras (with 1, and allowing the case 1 = 0) over a ring called R. Maps between rings, including derivations, are taken to be R-linear. As in [Tag 00TH], a ring morphism R → S is formally smooth if, in the category of R-algebras, every morphism S → A/I, where I is an ideal of A with I 2 = 0, lifts to (or factors through) a morphism S → A. In other words, the defining property is that all these A → A/I induce surjective functions HomR (S, A) → HomR (S, A/I). A simple observation, not needed below, motivates the definition. On dropping the assumption I 2 = 0, when S is formally smooth over R there is instead a lift S → A/I 2 , then in turn a lift S → A/I 4 , and so on. One can easily interpose A/I 3 and other terms. Thus, after countably many choices, the given S → A/I factors through S → Â, where  is the inverse limit lim A/I n, the I-adic completion of A. ←− Formal smoothness of a scheme morphism ϕ : X → Y has an analogous definition [Tag 02GZ], best stated relative to the category of schemes over Y [Tag 01JX]. We say ϕ : X → Y (or even just X) is formally smooth if every morphism Spec (A/I) → Spec (A) over Y , where I 2 = 0, induces a surjective function HomY (Spec (A), X) → HomY (Spec (A/I), X). Among various results that are trivial consequences of the definition, we note that of [Tag 02H3]: every restriction of ϕ : X → Y to a morphism U → V between open subschemes of X and Y is formally smooth if ϕ is. It is also clear that any such restriction U → V is formally smooth precisely when U → Y is. Further properties, not needed here, show the robustness of this notion. The really striking fact, mentioned earlier, is that the formal smoothness of a morphism turns out to be determined by local properties alone (it is local in the sense of [Tag 01SS]). One can find further details of interest, in the context of algebraic spaces, in [Tag 049R]. Given an explicit finite presentation of S over R, say S ∼ = P/(f1 , . . . , fc ), where P denotes the polynomial ring P = R[x1 , . . . xn ], the image in S of any f in P is also called f when the meaning is clear. We prefer to use the name I0 for the ideal (f1 , . . . , fc ) of S, reserving I for other uses. The cases c = 0 or n = 0 are allowed, rewording where necessary. 4 PETER M. JOHNSON Departing slightly from the presentation-dependent definition in [Tag 00T6], we say a ring morphism R → S, or S as an R-algebra, is standard smooth over R if S can be presented as above, where c ≤ n and the c × c matrix J with (i, j)-entry ∂fi ∂xj maps to an invertible matrix over S, or equivalently det(J) is invertible in S. Also say R → S is essentially standard smooth if S is isomorphic to a localization of some standard smooth R-algebra. This is of most interest when S arises from localizing at a prime ideal. At the other extreme, a principal localization S = Tg (g ∈ T ) of a standard smooth R-algebra T remains standard smooth, from the now commonplace Rabinowitsch trick: introduce a new variable x and relator x.g − 1. A morphism ϕ : X → Y of schemes is standard smooth around a point x ∈ X if there are affine open subsets U , V with x ∈ U such that the restriction of ϕ to U → V is induced from a standard smooth ring homomorphism. By definition {x ∈ X | ϕ is standard smooth around x} is open in X. On this, the smooth locus, ϕ is said to be locally standard smooth, a property with many desirable consequences. Maps between stalks cannot be expected to be finitely presented. Thus, when ϕ is said to be standard smooth at x, for some x ∈ X, we mean that the induced map OY,ϕ(x) → OX,x is essentially standard smooth. Here OY,ϕ(x) plays the role of R. Example 1. Suppose 2 is a unit of R and S = R[x, y]/(x2 + y 2 − 1). While R → S is not standard smooth (which could be verified later, from the module of differentials), the morphism Spec (S) → Spec (R) is locally standard smooth. This follows at once, using the open cover {D(x), D(y)} of Spec (S). 3. Derivations and differentials P ∂f The usual differential on P = R[x1 , . . . , xn ] is df = j ∂xj dxj , where to be definite the dxj (in order) are taken to be the elements of the canonical basis of the module P n . With S ∼ = P/I0 and I0 = (f1 , . . . , fc ) as before, there is a derivation d = dS : S → M (S), where M (S), the S-module of differentials, is the quotient of S n by the submodule generated by {df | f ∈ I0 }. It suffices P the relations dfi = 0 P to impose (1 ≤ i ≤ c), since all fi act as 0 on M (S), so d( i gi fi ) = i (gi .dfi + fi .dgi ) = 0. However, finiteness of the number of generators and relations is clearly non-essential here, and indeed throughout this whole section. Since M (S) is a concrete representative of the Kähler module [Tag 07BK], satisfying (with dS ) the universal property [Tag 00R0] of being the freest possible S-module of R-differentials of S, we adopt the standard notation ΩS/R in place of M (S). A different representative, visibly presentation-independent, is furnished in [Tag 00RN]. A more refined notion of universality will appear in the next lemma. The most subtle idea of the whole development is to compare certain derivations, as in [Tag 02HP] and [Tag 031I] (which includes a converse). These leave a few important details for readers to check. We follow roughly similar lines, placing more emphasis on universal concepts, proving exactly what is necessary for our purposes. To set notation, given an ideal I of an R-algebra S, write S = S/I, S ′ = S/I 2 , with s 7→ s′ 7→ s under the maps S → S ′ → S. Note that S-modules can be regarded as S-modules annihilated by I, or as S ′ -modules annihilated by I/I 2 . SMOOTH SCHEME MORPHISMS: A FRESH VIEW 5 Similar remarks apply to derivations d. The universal property in the next result should be clear from the way it will be used. As always, R-linearity is implicit. Lemma 1. The usual dS : S → Ω = ΩS/R , universal for derivations from S to S-modules, induces a d′S : S ′ → Ω = Ω/IΩ that is universal for derivations from S ′ to S-modules, where S ′ = S/I 2 and S = S/I. Proof. Let M be an arbitrary S-module, so I.M = 0 for M as an S-module. Every d : S → M must satisfy d(I 2 ) = 0, so induces some d′ : S ′ → M . This correspondence d 7→ d′ is bijective, since any d′ : S ′ → M lifts via S → S ′ to some d : S → M that in turn induces d′ . The bijection has a naturality property: given an S-module map α : M → M ′ , for every d : S → M we have (α ◦ d)′ = α ◦ d′ . The derivation called d′S : S ′ → Ω is the one induced from the composition of the universal dS : S → Ω and Ω → Ω. To verify the claimed universal property of d′S , start with any d′ : S ′ → M , where I.M = 0. This is induced from some d : S → M , which factors through dS as S → Ω → Ω → M for some unique S-linear map α : Ω → M . By naturality, uniqueness also holds for the factorization d′ : S ′ → Ω → M through d′S .  Proposition 1. With notation as above, assume that R → S is formally smooth. Then d′S : S ′ → Ω restricts to an isomorphism of S-modules between I/I 2 and a direct summand of Ω, giving a split exact sequence 0 → I/I 2 → Ω → ΩS/R → 0. In addition, ΩS/R is a projective S-module. Proof. Since S is formally smooth (over R) and isomorphic to S ′ /(I/I 2 ), where I/I 2 has square zero, some injective ring map β : S → S ′ is a right inverse of S ′ → S. Thus S ′ is a split extension (I/I 2 ) + β(S), a direct sum as R-modules. Projection yields an R-linear function D : S ′ → I/I 2 that satisfies s′ = D(s′ )+ β(s) (s′ ∈ S ′ ). A calculation of s′ .t′ in S ′ , using D(s′ ).D(t′ ) = 0, shows that D is a derivation: D(s′ .t′ ) = s′ .D(t′ ) + t′ .D(s′ ) (s′ , t′ ∈ S ′ ). By 1, D factors as d′S : S ′ → Ω followed by some S-linear γ : Ω → I/I 2 . However D, being a projection map, restricts to the identity function on I/I 2 . Thus d′S maps I/I 2 isomorphically to an S-submodule of Ω, with ker(γ) as a complementary direct summand. We have ker(γ) ∼ = Ω/d′S (I/I 2 ) ∼ = ΩS/R . To conclude, S can also be identified with a quotient P = P/I0 , where P is a polynomial ring over R or (for later use) a localization of some such ring. Then ΩS/R ∼ = ΩP /R . In the new split exact sequence, Ω is ΩP/R /I0 ΩP/R , which is a free P -module, using the following observation on localizations.  Differentials behave well under localization [Tag 00RT(2)]. In brief, if S ∼ = P/I0 is localized at a prime ideal p, with corresponding p′ ∈ Spec (R), p̃ ∈ Spec (P ), there is a well-defined d : Pp̃ → Pp̃ ⊗P ΩP/R , f /g 7→ (1/g)df − (f /g 2 )dg, which induces d : Sp → Sp ⊗S ΩS/R , clearly universal for Sp . The last module can be identified with ΩSp /Rp′ , as R acts through Rp′ . Similar results hold for any localization of S. 6 PETER M. JOHNSON 4. Local relations between formal and standard smoothness Arguments in this section rely crucially on finiteness of presentation. We start with the well-known fact that formal smoothness holds for presentations satisfying a version of the Jacobian criterion. The usual proof, given below, uses ideas from deformation theory closely related to iterative methods for approximating solutions of systems of equations. As often occurs, a desired result is obtained on restricting to an open subscheme, here Spec (S∆ ) within Spec (S). Renumberings of x1 , . . . , xn may alter ∆, producing various subschemes, some possibly empty. Proposition 2. Suppose S = P/I0 , where P = R[x1 , . . . , xn ], I0 = (f1 , . . . , fc ) ∂fi ∈ P , with ∆ the image and c ≤ n. Let J be the c × c matrix with (i, j)-entry ∂x j of det(J) in S. Then the principal localization S∆ is a formally smooth R-algebra. Proof. One can obtain a presentation for S∆ from that of S by adding a generator xn+1 and relator xn+1 .∆ − 1. This produces a new matrix whose determinant is the square of the original one. Thus, changing notation, it can and will be assumed that ∆ is already a unit (invertible in S). Given any map from S = P/I0 to Ā = A/Z, where Z is an ideal of square zero, for each generator xj of P choose aj ∈ A so that xj 7→ aj (1 ≤ j ≤ n). This defines a homomorphism P → A, xj 7→ aj . It will be deformed to one annihilating I0 , with xj 7→ aj + zj , for certain zj ∈ Z. The given map S → Ā will then lift to S → A. Since Z 2 = 0, each condition that fi maps to 0 is a linear (or affine) equation P ∂fi in the zj . Explicitly, in vector notation, fi (~a + ~z) = fi (~a) + j ∂x (~a).zj = 0. All j zj with j > c can be freely chosen, say set to 0. The coefficient matrix is then an image of J, defined above. The system can be solved because its determinant has the same image in Ā as ∆ = det(J), hence is a unit of A since Z is nilpotent.  To prepare for use in arguments, we refine previous notation. Given ideals I0 ⊆ I1 of P = R[x1 , . . . , xn ], define S = P/I0 , S = P/I1 , I = I1 /I0 . Then I is an ideal of S for which S/I ∼ = S. To fix notation, write I0 = (f1 , . . . , fc0 ) (so c0 = c) and I1 = (f1 , . . . , fc1 ). In practice, generators for I1 will be given and I0 will be defined by selecting a certain number c0 of these. There are Jacobian matrices J0 and ∂fi J1 , of sizes c0 × n, and c1 × n, each with (i, j)-entry the image of ∂x in S. Fix j p ∈ Spec (S), lifting it to p ∈ Spec (S) and p̃ ∈ Spec (P ). Let J 0 , J 1 denote the images of J0 , J1 with entries in κ(p), the field onto which S p maps. Proposition 3. With notation as just above, let c0 be the rank of J 1 over κ(p). After some reordering of the fi , the rows of J 0 , corresponding to generators f1 , . . . fc0 of I0 , form a basis for the rowspace of J 1 . The universal derivation dS : S → Ω, where S = P/I0 , maps the ideal I = I1 /I0 into pΩ. Proof. The rows of J 1 lie in k(p)n , so contain a maximal independent set of size c0 ≤ n. We work with polynomials, and derivations induced from d : P → P n , ∂f ∂f f 7→ ( ∂x , . . . ∂x ), where P = R[x1 , . . . , xn ]. Let i range over [1, c0 ]. By the choice 1 n P of generators fi of I0 , for each f ∈ I1 there are gi ∈ P for which df − i gi .dfi ∈ p̃n ⊂ P n . Recall that S = P/I0 , so the dfi are relators of the universal S-module Ω = ΩS/R , a quotient of P n (via S n ). Thus dS : S → Ω maps I1 /I0 into pΩ.  SMOOTH SCHEME MORPHISMS: A FRESH VIEW 7 The following basic result will also be needed. Lemma 2. Let M be a direct sum M1 ⊕M2 of modules over Sp , where p ∈ Spec (S). If the submodule M1 is finitely generated and contained in pM , then M1 = 0. Proof. Note that M = M/pM is a direct sum M 1 ⊕ M 2 , as pM is also a direct sum. Then pM1 = M1 since M 1 = 0. By Nakayama’s Lemma [Tag 00DV], M1 = 0.  Proof of 1. All parts reduce to assertions about ring morphisms. (b) ⇒ (a): This was done in 2. (a) ⇒ (c): Easy arguments with diagrams involving A → A/I, where I 2 = 0, show that formal smoothness of R → S is preserved under any localization of S, say Sp , then also for the induced Rp′ → Sp , where p 7→ p′ in Spec (S) → Spec (R). (b) ⇒ (d): This is trivial, from the definitions. (d) ⇒ (c): If the local ring Sp is the localization of a standard smooth R-algebra S1 , by previous steps R → S1 is formally smooth and, by localizing, so is Rp′ → Sp . (c) ⇒ (b): To retain consistency with earlier notation, we begin with an Ralgebra called S, finitely presented as P/I1 , and a formally smooth stalk map Rp′ → S p . It suffices to find some g ∈ S\p for which S g is standard smooth over R. After choosing an ideal I0 ⊂ I1 of P as in 3, write as before S = P/I0 , I = I1 /I0 , S ′ = S/I 2 , and note that S ∼ = S/I. By 3, dS : S → Ω maps I into pΩ and so, from 1, d′S : S ′ → Ω maps I/I 2 into p Ω. To localize, lift the given p to p̃ ∈ Spec (P ) and work with analogous definitions from Pp̃ in place of P . Let for example (I1 ) denote I1 .Pp̃ and (I) be (I1 )/(I0 ). To simplify notation, T in place of S signifies localization. Thus the given S p becomes T . We rename Ω as ΩT /Rp′ (isomorphic to Sp ⊗S ΩS/R ), and let Ω = Ω/(I)Ω. The result involving d′S now yields: d′T : T ′ → Ω maps (I)/(I)2 into pΩ. By hypothesis T ∼ = T /(I) is formally smooth over Rp′ , so 1 implies that (I)/(I)2 maps isomorphically onto a direct summand of Ω. By 2, (I) = (I).(I). As (I) = (I1 )/(I0 ) is a finitely-generated proper ideal of the local ring T = Pp̃ /(I0 ), a form of Nakayama’s Lemma implies that (I) is the zero ideal, so (I1 ) = (I0 ) in Pp̃ . Returning to ideals of P , finite generation of I1 now implies that gI1 ⊂ I0 for some g ∈ P \p̃. Thus S g ∼  = Pg /I0 Pg , a standard smooth R-algebra by 2. Recall that 3 shows how to choose a certain number c0 of polynomials from any given list of generators of I1 . Assuming a formally smooth stalk map, it was shown just above that all remaining relators in the list become redundant, after passing to a suitable principal localization. As a rough restatement, within each stalk a failure of redundancy in the additional relators is equivalent to the failure of smoothness for the map at that stalk. 8 PETER M. JOHNSON 5. A formula for the smooth locus Going beyond a test for the smoothness of individual stalk maps, we present a formula for the smooth locus of an open affine subscheme over R, now written as Spec (S), S ∼ = P/I1 , to conform with earlier conventions. Here P = R[x1 , . . . , xn ] and I1 = (f1 , . . . , fc ), so c = c1 . The idea is to study square submatrices J of the c × n Jacobian matrix defined from the given presentation of S. Proof of 2. Given any p ∈ Spec (S), let p be the lift to Spec (P ). Following 3, there is a largest c0 ≥ 0 for which one can choose c0 of the fi , generating an ideal I0 , then c0 of the variables xj , used to form a submatrix J of the Jacobian matrix such that det(J) ∈ / p. If p is in the smooth locus of S, we know from the end of the proof of 1 that gI1 ⊂ I0 for some g ∈ / p, or equivalently p ∈ / V ((I0 : I1 )), where (I0 : I1 ) = {g ∈ P | gI1 ⊂ I0 }. Conversely, if p satisfies this last condition then p is in the smooth locus, by 2 and preservation of smoothness (of either kind) under localization at prime ideals. Reversing the previous point of view, one now starts by choosing a natural number c0 ≤ min(c, n) and selecting c0 members from each of the lists f1 , . . . , fc and x1 , . . . , xn . From these one defines an ideal I0 ⊂ I1 and a c0 × c0 submatrix J of the Jacobian matrix. Let ∆ be the image in S of det(J). As just above, each p in D(∆) ∩ V ((I0 : I1 ))c lies in the smooth locus of S. Conversely, varying the choices, such open subsets of Spec (S) cover the whole smooth locus, by arguments in the previous paragraph. The number of open sets used is the number of square submatrices (including the empty matrix) of a general c × n matrix.PThis is symmetric tocount  Pc in c and  n, son+c c c we may suppose c ≤ n. The number is i=0 ni ci = i=0 ni c−i = c .  6. Local to global for formally smooth morphisms The nontrival direction of the following fundamental theorem is a remarkable local-to-global property of formal smoothness. It is basically a cohomological result from deformation theory, but we will show how it follows from a careful analysis using elementary methods. Instead of a local hypothesis of the form ‘R → S of finite type’, it suffices to require only ‘essentially of finite type’ [Tag 00QM]: S is a localization of an R-algebra of finite type. Examples of such morphisms, not locally finite, are easily found using transcendental extensions of fields. With ‘around’ in the sense defined in the introduction, the result we prove is: Theorem 3. For every scheme morphism ϕ : X → Y that is locally essentially of finite type, the following are equivalent: (a) ϕ is formally smooth; (b) ϕ is formally smooth around all points of X. The equivalence is in fact true for arbitrary ϕ, but the given hypothesis on ϕ is sufficiently general to include all situations that normally occur, and significantly simplifies the proof. In this context it is usual to cite a result on the triviality of Čech cohomology for quasicoherent sheaves on affine schemes, but we do not do so. SMOOTH SCHEME MORPHISMS: A FRESH VIEW 9 Some historical background is given for those interested. The very last (fourth) issue of [1], Vol. 4 states the equivalence in full generality as Proposition (17.1.6), but the proof cites something that requires ϕ to be locally of finite presentation. Grothendieck [4, Remarque 9.5.8] (also see [9]) discussed that gap, found soon after publication. He stated that there is no problem for locally finite morphisms, adding that the general result would follow from a proof of a conjecture on the structure of locally projective modules. A few years later, in 1971, the deep analysis carried out by Raynaud and Gruson [10], building on earlier work of Kaplansky [6], implied a full solution, once some technical details had been corrected in [5]. We ignore all this, and later related work, as the case we treat can be handled using only rudimentary machinery. This provides an instructive contrast to more conventional methods. At the end, adjustments are made via partitions of unity analogous to ones used in complex analysis to prove certain theorems of Dolbeault and de Rham—see for example [2, p. 311]. Just as in [Tab 01UP], a one-line calculation (omitted) yields: Lemma 3. Let Ā = A/I, where I 2 = 0. Given a ring morphism σ : R → A, regard I as an R-module via the induced map σ : R → Ā composed with the natural action of Ā on I. Then the morphisms R → A that induce σ are the functions of the form σ + δ for which δ : R → I is an R-derivation. Proof of 3. One direction is trivial, from observations made in Section 2. Given (b), one sees from the hypotheses that for each x ∈ X there are affine sets U ⊂ X and V ⊂ Y with x ∈ U such that f restricts to a formally smooth morphism U → V that is essentially of finite type. Using notation Ā = A/I, where I 2 = 0, and T ′ = Spec (Ā), with underlying set identified throughout with that of T = Spec (A), it must be shown that any morphism ψ : T ′ → X factors through the usual T ′ → T . The morphisms here are already over Y , via compositions with ϕ : X → Y . As a first step, in which notation will be defined and various choices made, each t ∈ T ′ lies in a principal affine open set contained in some ψ −1 (U ) with U as above. The affine scheme T ′ is covered by finitely many of these sets, henceforth called T1′ , . . . Tl′ , of the form Spec (Afi ). We write the localization Afi as Ai and use a similar convention for the Ā-module I, but not more generally. Variables i, j, k range over [1..l], the initial focus being on a single i. Also choose as above affine opens Ui ⊂ X, Vi ⊂ Y so that ψ and ϕ restrict to maps Ti′ → Ui → Vi . Each corresponding ring homomorphism Ri → Si → Āi is regarded as forming a morphism Si → Āi of Ri -algebras, with Si essentially finite over Ri . By the formal smoothness assumption, one can choose a lift σi : Si → Ai . To study morphisms on subschemes of T = Spec (A), notation will be extended in an obvious way and natural identifications made, so for example Tij denotes the scheme Spec (Aij ) on the set Ti ∩ Tj . The case j = i is not excluded but will be of no interest. The morphism Tij → Ui , obtained from composing σi with Ai → Aij , factors through Uij = Ui ∩ Uj , a scheme which need not be affine but is open in Ui and in Uj . Thus both σi and σj will induce scheme morphisms Tij → Uij . Composing with the inclusion Uij → Ui produces two lifts Si → Aij of the same morphism Si → Āi → Āij . By 3, their difference (in the order i, j) is an Ri -linear derivation δij : Si → Iij . Recall that δij then factors as Si → ΩSi /Ri → Iij . 10 PETER M. JOHNSON By assumption Si is a localization of the Ri -subalgebra generated by some finite N (γ,j) , for some set {sγ | γ ∈ Γi } of its elements. Each δij (sγ ) is of the form zγ,j /fj chosen zγ,j ∈ Ii that minimizes N (γ, j) ∈ N, with i implicitly determined by the index γ. We can then choose some upper bound N ∈ N for all the N (γ, j), letting i also vary. From the end of the proof of 1, ΩSi /Ri can be identified with a direct summand of ΩPi′ /Ri , where Pi′ is a suitable localization of the polynomial algebra with free generators xγ (γ ∈ Γi ), such that xγ 7→ sγ defines a surjective morphism Pi′ → Si . Passing to differentials, the dxγ form a P ′ -basis of ΩPi′ /Ri . The projection dxγ 7→ dsγ fixes ΩSi /Ri , and the above factorization of δij gives a map with dsγ 7→ N (γ,j) zγ,j /fj . A multiple of the composition lifts to a map ΩPi′ /Ri → Ii , dxγ 7→ (N ) N −N (γ,j) zγ,j . fj Si → ΩSi /Ri Restriction to ΩSi /Ri then yields an Ri -linear derivation δij : → Ii which, composed with Ii → Iij , is fjN δij : Si → Iij . As N may (M+N ) later be increased further, note that for M ∈ N we have δij (N ) = fjM δij . In much the same way that δij was defined, one can find a derivation Si → Iij that is the difference of two homomorphisms Si → Aij and, when calculated on the stalks of Uij , which are algebras over both Ri and Rj , has the formula (N ) (N ) δik − δjk − fkN δij . From the definitions, the image of each element of Si under this derivation lies in the kernel of Iij → Iijk , so is annihilated in Iij by some power of fk . The derivation is determined by its effect on the finite set {sγ | γ ∈ Γi }, and is multiplied by fkM if N is increased by M . Thus, for a sufficiently large N , all these derivations Si → Iij , with i, j, k now varying over 1..l, are identically zero. One then has a formula, valid on stalks of Uij : (N ) (N ) δik − δjk = fkN δij . P N The sets D(fk ) cover Spec (A), so there are hk ∈ A with k hk fk = 1. For ′ each i, define the ring morphism σi : Si → Ai , a new lift of the original map P (N ) Si → Āi , by σi′ = σi − k hk δik . To compare corresponding scheme morphisms Ti → Ui and Tj → Uj on the overlap Tij → Uij , one can take differences of the ring homomorphisms on stalks (or use suitable affine subschemes of Uij ). Using previous formulas, calculations taking values in stalks of Tij , then later just in Aij , give: X σi′ − σj′ = (σi − σj ) − hk fkN δij = δij − δij = 0. k Thus the new morphisms Ti → Ui → X patch together, forming a map T = Spec (A) → X through which the initially given ψ : T ′ = Spec (Ā) → X factors.  7. References [1] A. Grothendieck, J. Dieudonné, Éléments de Géométrie Algébrique, Publ. Math. IHES, Part I: 4(1960); Part II: 8(1961); Part III: 11(1961), 17(1963); Part IV: 20(1964), 24(1965), 28(1966), 32(1967). SMOOTH SCHEME MORPHISMS: A FRESH VIEW 11 [2] K. Fritzsche, H. Grauert, From Holomorphic Functions to Complex Manifolds, Springer, 2002. [3] U. Görtz, T. Wedhorn, Algebraic Geometry I, Vieweg, 2010. [4] A. Grothendieck, Catégories Cofibreés Additives et Complexe Cotangent Relatif, Lect. Notes Math. 79, Springer-Verlag, 1968. [5] L. Gruson, Dimension homologique des modules plats sur an anneau commutatif noethérien, Symposia Mathematica, Vol. XI (Convegno di Algebra Commutativa, INDAM, Rome, 1971), Academic Press, London, 1973, 243–254. [6] I. Kaplansky, Projective modules, Ann. Math. (2) 68 (1958), 37–377. [7] J. Majadas, A. Rodicio, Smoothness, Regularity and Complete Intersection, Cambridge University Press, 2010. [8] M. Maltenfort, A New Look at Smoothness, Expo. Math. 20 (2002), 59–93. [9] Answer (by mdeland) to “Possible formal smoothness mistake in EGA”, 2010, http://mathoverflow.net/questions/10731/ [10] M. Raynaud, L. Gruson, Critères de platitude e de projectivité, Techniques de «platification» d’un module, Inv. Math. 13, 1–89 (1971). [11] The Stacks Project Authors, Stacks Project, 2005–2016, http://stacks.math.columbia.edu [12] R. Vakil, The Rising Sea: Foundations of Algebraic Geometry, 2010–2015, http://math.stanford.edu/˜vakil/216blog/index.html Departamento de Matemática, UFPE, 50740–560, Recife–PE, Brazil E-mail address: [email protected]
0math.AC
Receive Spatial Modulation for Massive MIMO Systems Ahmed Raafat, Adrian Agustin and Josep Vidal arXiv:1705.03218v2 [cs.IT] 22 Mar 2018 Dept. of Signal Theory and Communications, Universitat Politecnica de Catalunya (UPC), Barcelona, Spain. Email: {ahmed.raafat, adrian.agustin, josep.vidal}@upc.edu Abstract—In this paper, we consider the downlink of a massive multiple-input-multiple-output (MIMO) single user transmission system operating in the millimeter wave outdoor narrowband channel environment. We propose a novel receive spatial modulation architecture aimed to reduce the power consumption at the user terminal, while attaining a significant spectral efficiency and low bit error rate. The energy consumption reduction is obtained through the use of analog devices (amplitude detector), which reduces the number of radio frequency chains and analogto-digital-converters (ADCs). The base station transmits spatial and modulation symbols per channel use. We show that the optimal spatial symbol detector is a threshold detector that can be implemented by using one bit ADC. We derive closed form expressions for the detection threshold at different signal-tonoise-ratio (SNR) regions. We derive expressions for the average bit error probability in the presence and absence of the threshold estimation error showing that a small number of pilot symbols is needed. A performance comparison is done between the proposed system and fully digital MIMO showing that a suitable constellation selection can reduce the performance gap. I. I NTRODUCTION The utilization of millimeter wave (mmWave) frequencies for cellular communication systems can allow high data rates links because of the availability of unused large bandwidths [1]. Millimeter wave signals suffer from severe path loss; however, the small wavelengths permit using massive arrays at the base stations (BSs) and user terminals (UTs). Massive arrays compensate the path loss through their own beamforming gain and enhance the spectral efficiency by boosting the multiplexing gain. The UT circuit structure per antenna of the fully digital (FD) multiple-input-multiple-output (MIMO) system comprises radio-frequency (RF) chain and analog to digital converter (ADC). Unfortunately, these devices are expensive and power consuming especially at mmWave frequencies. Thus, massive mmWave MIMO systems based FD architecture suffer from cost and power consumption problems [1]. Several low complexity MIMO transceiver designs have been developed. Hybrid analog and digital precoding techniques have been proposed with the aim of simplifying the architecture and reducing power consumption [2] . The spectral efficiency of the hybrid systems approach the FD MIMO [2]. Nevertheless, hybrid structures comprise large numbers of phase shifters (PSs), power splitters and power combiners The research leading to these results has been partially funded by the 5Gwireless project within the framework of H2020 Marie Skłodowska-Curie innovative training networks (ITNs) and the project 5G&B RUNNER-UPC (TEC2016-77148-C2-1-R) funded by AEI/FEDER-UE. for analog signal processing. These analog devices consume a large amount of power principally with large arrays [3]. MIMO transceivers-based low precision ADCs have been studied to reduce the cost and power consumption [4]. Nonetheless, the use of low bit ADCs hamper the availability of perfect channel knowledge and entails a reduction of the spectral efficiency. Spatial modulation (SM) schemes have been reported to reduce the number of RF chains and to achieve high throughput. In SM, the transmit antennas are exploited in transmitting extra information where part of the input data bits are used to select the set of active transmit antennas and the UT detects this set [5]. However, SM techniques suffer from small antennas gain because most of the transmit antennas are silent. Further, the UT cannot detect the set of active transmit antennas precisely if the channel vectors are correlated. In contrast, the receive SM (RSM) techniques exploit the receive antennas to transmit more information [6]. However, conventional RSM methods use FD receiver architecture and can suffer from high performance degradation under low rank channel matrices. Thus, traditional SM/RSM methods are not convenient for mmWave systems. In [7] a low complexity RSM system is introduced for indoor line of sight mmWave propagation. Unlike the previous RSM methods, this paper focuses on designing a new and simple RSM receiver based novel spatial detection method aimed to exploit the spatial dimension to transmit modulation symbols reliably. Moreover, we show that the proposed RSM system works efficiently in outdoor narrowband mmWave channels. We consider a massive MIMO single user operating in the mmWave outdoor narrowband channel environment. We present a RSM system where the BS transmits modulation symbol from M size constellation and spatial symbol per channel use. We show that the optimal spatial symbol detector is a threshold detector that can be implemented by using one bit ADC. We derive closed form expressions for the detection threshold at different signal-to-noise-ratio (SNR) regions showing that a simple threshold can be obtained at high SNR and its performance approaches the exact threshold. We derive expressions for the average bit error probability (ABEP) in the presence and absence of the threshold estimation error, and show that a small number of downlink pilot symbols is needed. Simulation results show that the performance of the proposed system with the appropriate constellation design approaches the FD MIMO system. where H ∈ CNr ×Nt is the channel matrix and n ∈ CNr ×1 is the generated noise vector where its coefficients are independent and identically distributed (i.i.d) zero mean circularly symmetric complex Gaussian random variables and each has variance σ 2 . Let us define the matrix Ha as the channel matrix from the BS to the selected ARAs. In order to direct the data vector to the ARA, we design the precoding matrix B as a zero forcing precoder that can be expressed as  H −1 B = HH (3) a Ha Ha The received signal by the k th active antenna can be expressed as √ (4) yk = αP sik xj + nk Fig. 1. Downlink (black) and uplink (red) MIMO UT circuits. II. S YSTEM M ODEL A. Signal Model and Precoder Design We consider the downlink of a large MIMO single user that operates in the mmWave outdoor narrowband channel environment. The BS and UT are equipped with Nt and Nr antennas respectively. Based on the properties of mmWave propagation, we consider reciprocal propagation environment. We exploit the channel reciprocity by considering time division duplex (TDD) system where the channel state information (CSI) is needed only at the BS. In Fig. 1, displayed in red, we consider a low complexity uplink UT circuit based on analog PSs. During the uplink training, the UT sends pilot symbols so that the BS can acquire the CSI. This can be achieved, since the optimal training pilot symbols matrix for the least squares channel estimation can be selected as a discretefourier-transform (DFT) basis [8] that can be implemented by PSs. Since massive mmWave MIMO systems suffer from high path loss and antenna correlation, antenna selection at the receiver is necessary. The BS selects the most suitable Na antennas based on the channel knowledge (assumed perfect in this paper). After that, the BS informs the UT by the Na active receive antennas (ARA). The BS transmits data vector to the ARA that comprises spatial and modulation symbols. The transmitted data vector can be written as √ xji = αP Bsi xj (1) where the spatial symbol si ∈ RNa ×1 contains Na bits from the input data bits, i ∈ {1, ..., 2Na − 1}, we assume that the all-zeros spatial symbol is not allowed, the modulation symbol xj is a symbol from certain constellation with size M , j ∈ {1, ..., M }, the number of transmitted bits per data vector are (Na +log2 M ), B ∈ CNt ×Na is the precoding matrix, P is the average transmit power and we adjust power  thetransmitted −1 by a normalization factor α ≈ Tr BH B where Tr{.} is the trace operator. The received signal vector is given by √ y = αP HBsi xj + n (2) where sik ∈ {0, 1}. For a given Na , the BS selects the best Na ARA such that the received power is maximized −1 that is, α is maximized, where α−1 = Tr (Ha HH . a ) The maximization of α can be done through the exhaustive search. A simple method for solving a similar problem was mentioned in [9]. Low complexity algorithms that exploit the sparse nature of the outdoor mmWave channel to maximize α are left for future work. We assume that the UT can be successfully informed by the ARA through a control channel. Imperfect detection to the ARA at the UT is a topic for future research. According to equation (4), all the ARA associated to a spatial bit sik = 1 receive the same modulation symbol. The k th ARA is connected to RF switch that passes the signal only if the estimated spatial bit ŝik = 1. All of the signals that pass through the switches are combined. After that, the combined signal passes through RF chain and a single ADC to detect the modulation symbol. The combined signal is given by yc = Na X √ sik ŝik αP xj + ŝik nk (5) k=1 where the optimal ŝik detection scheme is shown in section III. In order to avoid the case yc = 0, we assume that the all-zeros transmit spatial symbol is not allowed. The downlink circuit in Fig. 1 (displayed in black lines) shows that each receive antenna is connected to RF amplitude detector (AD). The AD works efficiently with high sensitivity and negligible power consumption at mmWave frequencies [10]. The signal provided by the AD at the k th active antenna is r 2 √ 2 √ ak = αP sik xjI + nkI + αP sik xjQ + nkQ (6) where the indices I and Q represent the in-phase and quadrature components. The probability density function (PDF) of the received amplitude at the k th active antenna follows either a Rice or Rayleigh distributions [11]. The PDF of the received amplitude can be expressed as   √  a2 +αP  2ak e− kσ2 I 2ak αP if sik = 1 2 0 σ2 f (ak ) = σ (7) a2  2ak − k2 σ e if s = 0 ik σ2 where I0 (x) is the zero order modified Bessel function of the first kind. B. Channel Model Millimeter wave channels have limited scattering clusters due to the high path loss. Moreover, using large arrays increases the antennas correlation. Therefore, we choose for system evaluation the narrowband clustered channel model that is widely used for outdoor mmWave channels [2]. In this model, the channel matrix can be expressed as s Ny Nc X Nt Nr X r r gil Λr (θil )Λt (φtil )vr (θil )vt (φtil )H (8) H= Nc Ny i=1 l=1 where Nc represents number of scattering clusters, Ny is the r number of rays per cluster, gil is the complex gain, θil , φtil are the elevation and azimuth angles of arrivals and deparr tures, Λr (θil ), Λt (φtil ) are the receive and transmit directional r antennas gains, vr (θil ), vt (φtil ) are the receive and transmit array response vectors. We consider uniform linear arrays where the N antennas normalized response vector can be expressed as iT 1 h jkd sin(φ) 1, e , ..., ej(N −1)kd sin(φ) (9) v(φ) = √ N where k = 2π λ and d is the inter-antenna spacing. The directional antennas gain can be expressed as ( 1 ∀φ ∈ [φmin , φmax ] (10) Λ(φ) = 0 else where φmin and φmax determine the transmission sector angle. C. Power Consumption The power consumption of the significant UT circuit components can be expressed in terms of reference power [3] as PRF chain = 2Pref PLNA = Pref PADC = 10Pref PBB = NRF Pref PSW = 0.25Pref PPS = 1.5Pref (11) where NRF is the number of the RF chains, PSW , PLNA and PBB are the switch, low noise amplifier and the base band power consumption respectively. The uplink and downlink power consumption at the UT with the proposed system PP and with FD MIMO PFD can be expressed as III. S YMBOL D ETECTION A. Spatial Symbol Detection In order to recover the spatial symbol, each ARA is connected to AD and one bit ADC as illustrated in Fig. 1. The AD measures the amplitude of the received signal and it is compared to a predefined threshold at the ADC. Thus, the output signals from the ADCs represent the spatial symbol. In the spatial symbol detection, we will show that both per antenna detection and joint detection lead to the same results. B. Separate Spatial Symbol Detection We consider maximum likelihood (ML) detector per ARA to decide if the received spatial bit is one or zero. The detection problem per the k th antenna can be formulated as ŝik =1 f (ak |sik = 1) ≷ f (ak |sik = 0) 2ak − σ2 e a2 k +αP σ2 αP ŝik =0  √ I0 2akσ2αP e− σ2 I0  √ 2ak αP σ2 (13)  ŝik =1 a2 k k − σ2 ≷ 2a σ2 e (14)  ŝik =1 ≷ 1 (15) ŝik =0 ŝik =0 According to the problem in (15), the estimated spatial bit for the k th antenna can be expressed as ( 1 if ak > γ ŝik = (16) 0 if ak < γ where γ is a threshold that results from solution of the problem in (15). In the following, we present three ways to determine γ based on the received SNR. 1) Exact Threshold: We can obtain the exact value of the threshold directly by solving (15) numerically at the expenses of increasing the UT circuit complexity. 2) Moderate SNR Approximation (MSA): At moderate x SNR, we can approximate I0 (x) ≈ √e2πx in problem (15) and calculate the threshold by solving the following equation 4γ σ2 √ e 4πγ αP √ αP −2αP σ2 =1 putting it in the form xex = c as √ √ −4γ αP −4γ 2 αP 1 2αP σ e = − e− σ2 2 σ π (17) (18) (12) The solution of the equation in (18) can be given by   αP −σ 2 1 γ= √ W−1 − e−2 σ2 (19) π 4 αP 0.9 The power consumption ratio PP /PFD ≈ (0.14 + N ). At r 60 GHz and 500 MHz bandwidth systems, Pref = 20mW [3], Nr = 16, PP = 1700mW and PFD = 8640mW, the hybrid MIMO architecture consumes 8000mW [3]. where W−1 (x) is one of the main branches of the Lambert W function [12]. Nevertheless, we have to calculate the threshold in (19) numerically and this leads to increase in the UT circuit complexity. PP =Nr (2PLNA + PPS + PSW ) + 2 (PRF chain + PADC ) + PBB PFD = 2Nr (PLNA + PRF chain + PADC ) + PBB 3) High SNR Approximation (HSA): At high SNR, the left hand side of equation (17) takes either infinity or zero values based on the sign of the term in the exponential power. Therefore, we can obtain a simple threshold that can be expressed as 1√ αP (20) γ= 2 Since the received modulation symbol may come from non-constant amplitude constellation, the exact, MSA and HSA thresholds should be designed based on the minimum received constellation symbol amplitude. This can be achieved by replacing the average power P by the minimum power Pmin = βP in thresholds expressions where β depends on the constellation. C. Joint Spatial Symbol Detection In order to jointly detect the spatial symbol bits, we apply the ML detector based on the received amplitudes from all of the active antennas. Since the received amplitudes are i.i.d, their joint PDF can be expressed as f (a) = Na Y f (ak ) (21) k=1 from the outputs of the ADs connected to the ARA. The joint PDF of the received amplitudes can be expressed as   N 2 Y 2ak1 ϑ 2ak1 − a2k1 +ϑ 2 σ f (a|1a ) = e I0 (27) σ2 σ2 k=1 √ where 1a is all-ones spatial symbol, ϑ = αP , ak1 is the measured amplitude at the k th active antenna according to sik = 1, N = Np Na and Np is the number of pilot symbols. We design the amplitude estimator ϑ̂ so as to maximize     N X a2k1 + ϑ2 2ak1 ϑ 2ak1 log f (a|1a ) = − + log I0 log σ2 σ2 σ2 k=1 (28) x By using the fact that I0 (x) = √e2πx for large x, we can simplify equation (28) as   2ak1 ϑ 2ak1 ϑ 1 4πak1 ϑ log I0 = − log (29) σ2 σ2 2 σ2 In order to find the ML amplitude estimator ϑ̂M L , we solve ∂ the problem, ∂ϑ log f (a|1a ) = 0, that can be expressed as  N  X −2ϑ 2ak1 1 =0 (30) + 2 − σ2 σ 2ϑ k=1 The joint ML detection problem can be formulated as ŝi = arg max{f (a|si )} (22) si For the sake of simplicity, let us consider the case when the number of the ARA is two. In this case, the joint ML detection problem can be expressed as ŝi = arg max{f01 , f10 , f11 } (23) where fnm = fA (a|si1 = n, si2 = m). As an illustrative example, we decide symbol [0 1]T if the following conditions are satisfied From (30), the ϑ̂M L can be expressed as v !2 u PN PN 1u t k=1 ak1 k=1 ak1 ϑ̂M L = + − σ2 2N 2 N (31) 2 The ML estimator of the noise variance σ̂M L can be ∂ obtained by solving ∂σ2 log f (a|1a ) = 0 as 2 σ̂M L = N 2 X 2 (ak1 − ϑ) N (32) k=1 f01 = f00 f2 > f10 = f00 f1 (24) f01 = f00 f2 > f11 = f00 f1 f2 (25) By solving the equations in (31,32) simultaneously, a closed form expression for the ϑ̂M L can be given as v !2 u PN PN N 2 k=1 ak1 1u 3 X 2 t k=1 ak1 ϑ̂M L = + 4 − ak1 3N 3 N N k=1 (33) (26) V. E RROR A NALYSIS where fk can be given by αP fk = e − σ 2 I 0  2ak √ αP σ2  Inequalities in (24) and (25) imply that a1 < γ and a2 > γ respectively. See equations (15) and (16) for more illustration. The analysis of the joint detection can be extended for any number of ARA. Therefore, the joint detection results are equal to the per antenna detection. We evaluate the proposed system performance based on the ABEP that can be expressed as ABEP = Na Pes + log2 M Pem Na + log2 M (34) where Pes and Pem are the spatial and modulation bit error probabilities respectively that can be given by IV. D OWNLINK T RAINING The BS has to send pilot symbols to allow the UT estimates the detection threshold. We consider that the entries of the transmitted spatial symbol are all ones. In order to estimate the detection threshold, the UT estimates the average received signal amplitude and the noise level Pes = 0.5 (P1 + P0 ) (35) where P1 = Pr (ak1 < γ) and P0 = Pr (ak0 > γ). Pem = a −1 2Na 2N X X i=1 n=1 BEP (xj ∈ CM |ŝn , si ) Pr (ŝn |si ) Pr (si ) (36) where BEP (xj ∈ CM ) is the bit error probability of M quadrature-amplitude-modulation (M-QAM), M -phase-shiftkeying (M-PSK) or M -amplitude-phase-shift-keying (MAPSK) with rings ratio r [13]. The probabilities in equation (36) can be expressed as BEP (xj ∈ CM |ŝn , si ) = BEP (xj ∈ CM |SNRc ) SNRc = b10 2 (b11 in ) 01 b11 in + bin 11 b01 αP σ2 (37) (38) 00 Pr (ŝn |si ) = P1 in (1 − P1 )bin P0 in (1 − P0 )bin 1 Pr (si ) = Na 2 −1 (39) (40) (m m ) where bin 1 2 is the number of entries in si that each one of them equals m1 and its corresponding entry in ŝn equals m2 P (m m ) and m1 ,m2 ∈{0,1} bin 1 2 = Na . A. Perfect Threshold If the UT knows the threshold γ perfectly, the probabilities P1 and P0 can be expressed by the cumulative density function of Rice and Rayleigh distributions [11] as   1√ 1√ P1 = 1 − Q1 2αP , 2γ σ σ γ2 P0 = e − σ 2 where Tδ,n and Tδ,n,l are the cumulative density functions of Non-central and Doubly-non-central t distributions [14]. In order to determine the probabilities in equation (44), we need the mean and the variance of γ̂. By relating equations (33) and (20), the estimated HSA threshold γ̂ is 1 γ̂ = ϑ̂M L (45) 2 From the asymptotic properties of the ML estimator [15], the mean and variance of γ̂ can be expressed as (41) where Q1 (x) is the first order Marcum Q-function. B. Estimated HSA Threshold The ML estimator is asymptotically gaussian so we consider the estimated HSA threshold γ̂ ∼ N (µγ̂ , σγ̂2 ) where µγ̂ and σγ̂2 are the mean and variance of γ̂. Since the received amplitudes are positive, we can express P1 and P0 as   γ̂ P1 = Pr >1 a  k1  γ̂ P0 = Pr <1 (42) ak0 In order to find the probabilities in equation (42), we put it in the following form   σ P1 = Pr tδ,n,l > σγ̂   σ (43) P0 = Pr tδ,n < σγ̂ where tδ,n is Non-central t distribution, tδ,n,l is Doubly-noncentral t distribution [14], n is the degrees of freedom, δ, l are µ the non-centrality parameters, δ = σγ̂γ̂ , n=2 and l = 2αP σ2 . A closed form expressions for P1 and P0 with threshold estimation error can be given as   σ P1 = 1 − Tδ,n,l σ   γ̂ σ P0 = Tδ,n (44) σγ̂ µγ̂ = 1 ϑ 2 (46) 1  −1  I (47) 4 θ 11 where Iθ is a 2 × 2 fisher information matrix [15] whose elements can be expressed as   2 2N N ∂ f (a|1a ) = 2 − 2 [Iθ ]11 = − E 2 ∂ϑ σ 2ϑ  2  ∂ f (a|1a ) 2N [Iθ ]12 = [Iθ ]21= − E = 4 (µ1 − ϑ) 2 ∂ϑ∂σ σ  2  ∂ f (a|1a ) [Iθ ]22 = − E ∂σ 2 ∂σ 2  N 2N = 6 µ2+ϑ2−2ϑµ1 − 4 (48) σ 2σ where  E[.] is the expectation operator, µ1 = E[ak1 ] and µ2 = E a2k1 . The inverse of the fisher information matrix can be expressed as   1 [Iθ ]22 − [Iθ ]12 (49) I−1 = θ 2 − [Iθ ]21 [Iθ ]11 [Iθ ] [Iθ ] − [Iθ ] σγ̂2 = 11 22 12 From equations (47,49), the variance σγ̂2 can be given as σγ̂2 = [Iθ ]22 1 4 [Iθ ]11 [Iθ ]22 − [Iθ ]212 (50) VI. S IMULATION R ESULTS In this section, we present simulation results that show the performance of the proposed system. In simulation en2 vironment, we consider that gil are i.i.d  CN (0, σg ) where 2 H σg is designed such that E Tr H H = Nt Nr , Nc = 8, Ny = 10 [2], the elevation and azimuth angles (θil , φil ) have Laplacian distributions with uniform random means (θi , φi ) and angular spreads σθ = σφ = 1, SNR = σP2 , the width of the transmission angle is 50◦ and the user has omnidirectional antenna array. We compare the performance of the proposed system with singular value decomposition (SVD) based precoding and decoding of the FD MIMO system. We allocate the power at SVD in such a way that all of the activated modes achieve the same received SNR [16]. Fig. 2 shows the ABEP of the proposed system with exact threshold compared to FD MIMO at 32 × 8 MIMO system. Clearly, the performance of the proposed system without receive antenna selection is inferior to that with antenna selection. Moreover, the proposed system performance with 10 -1 10 0 Exact γ Na = Nr = 8, only spatial Na = 4, 16-QAM Na = 6, 4-QAM Na = 4, 16-APSK, r=2 Na = 4, 16-APSK, r=1.8 Na = 4, 16-APSK, r=1.5 Na = 4, 16-PSK 1-Mode SVD, 256-QAM 2-Modes SVD, 16-QAM 4-Modes SVD, 4-QAM ABEP 10 -2 10 -3 MSA γ 10 -2 HSA γ HSA γ̂, Analytic ABEP 10 -1 HSA γ̂, Simulations 10 -3 10 -4 10 -4 Nr = 8 Nr = 16 10 -5 10 -5 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 SNR[dB] 0 1 2 3 4 5 6 7 8 SNR[dB] Fig. 2. Average bit error probability of the proposed system and FD MIMO at different constellation designs. 8 transmit bits are used in all cases. Fig. 3. Average bit error probability of the proposed system at Nt = 32, Na = 4, 16-PSK, perfect and estimated thresholds. constant amplitude constellation and 4 spatial bits approaches the FD MIMO. The optimal values of spatial, modulation bits and constellation design to minimize the ABEP are topics for future research. Fig. 3 represents the ABEP of the proposed system at different thresholds and different numbers of receive antennas. Applying HSA threshold leads to the lowest complexity and the performance gap is less than 1 dB with respect to the exact threshold. The ABEP with threshold estimation error is very close to that with perfect threshold by using only one downlink pilot symbol. Increasing the number of receive antennas while Na is fixed boosts the receive antennas gain and as a result the ABEP is improved. [2] O. El Ayach, S. Rajagopal, S. Abu-Surra, Z. Pi, and R. W. Heath, “Spatially sparse precoding in millimeter wave MIMO systems,” IEEE Transactions on Wireless Communications, vol. 13, no. 3, pp. 1499– 1513, March 2014. [3] R. Méndez-Rial, C. Rusu, N. González-Prelcic, A. Alkhateeb, and R. W. Heath, “Hybrid MIMO architectures for millimeter wave communications: Phase shifters or switches?,” IEEE Access, vol. 4, pp. 247–267, Jan. 2016. [4] J. Mo and R. W. Heath, “Capacity analysis of one-bit quantized MIMO systems with transmitter channel state information,” IEEE Transactions on Signal Processing, vol. 63, no. 20, pp. 5498–5512, Oct. 2015. [5] A. Younis, N. Serafimovski, R. Mesleh, and H. Haas, “Generalised spatial modulation,” 44rd Asilomar Conference on Signals, Systems and Computers, pp. 1498–1502, Nov. 2010. [6] R. Zhang, Lie-Liang Yang, and L. Hanzo, “Generalised pre-coding aided spatial modulation,” IEEE Transactions on Wireless Communications, vol. 12, no. 11, pp. 5434–5443, Nov. 2013. [7] N. S. Perovic, P. Liu, M. Di Renzo, and A. Springer, “Receive spatial modulation for los mmwave communications based on TX beamforming,” IEEE Communications Letters, Dec. 2016. [8] M. Biguesh and A. B. Gershman, “Training-based MIMO channel estimation: a study of estimator tradeoffs and optimal training signals,” IEEE Transactions on Signal Processing, vol. 54, no. 3, pp. 884–893, March 2006. [9] L. Dai, S. Sfar, and K. B. Letaief, “Receive antenna selection for MIMO systems in correlated channels,” IEEE International Conference on Communications, vol. 5, pp. 2944–2948, June 2004. [10] S. Rami, W. Tuni, and W. R. Eisenstadt, “Millimeter wave MOSFET amplitude detector,” Topical Meeting on Silicon Monolithic Integrated Circuits in RF Systems (SiRF), pp. 84–87, Jan. 2010. [11] M. K. Simon, Probability distributions involving Gaussian random variables: A handbook for engineers and scientists, Springer, May 2007. [12] D. Barry, J-Y Parlange, L. Li, H. Prommer, C. Cunningham, and F. Stagnitti, “Analytical approximations for real values of the Lambert W-function,” Mathematics and Computers in Simulation, vol. 53, no. 1, pp. 95–103, Aug. 2000. [13] J. W. Craig, “A new, simple and exact result for calculating the probability of error for two-dimensional signal constellations,” IEEE Military Communications Conference, pp. 571–575, Nov. 1991. [14] C. Walck, Handbook on statistical distributions for experimentalists, University of Stockholm Internal Report, 2007. [15] H. L. Van Trees, Optimum Array Processing, Detection, Estimation, and Modulation Theory, John Wiley & Sons, 2004. [16] B. Vrigneau, J. Letessier, P. Rostaing, L. Collin, and G. Burel, “Extension of the MIMO precoder based on the minimum Euclidean distance: a cross-form matrix,” IEEE Journal of selected topics in signal processing, vol. 2, no. 2, pp. 135–146, April 2008. VII. C ONCLUSION In this paper, we have considered the downlink of a massive MIMO single user operating in the mmWave outdoor narrowband channel environment. The proposed RSM architecture relies on one RF chain and one high resolution ADC at the UT that reduces the power consumption and can achieve high spectral efficiency as the ARA are exploited to transmit extra spatial symbols. The constellation choice affects the system performance as the detection threshold is designed based the minimum constellation symbol amplitude. Therefore, a constant amplitude constellation with balancing between number of spatial and modulation bits outperforms other constellation designs. The receive antenna selection is necessary for the proposed system to work efficiently. However, this paper considered exhaustive search algorithm to select the ARA. Low complexity algorithms for receive antenna selection and extending the proposed system to allow higher order spatial symbols transmission through using multiple-bit ADCs at the UT are future work topics. R EFERENCES [1] R. W. Heath, N. Gonzalez-Prelcic, S. Rangan, W. Roh, and A. M. Sayeed, “An overview of signal processing techniques for millimeter wave MIMO systems,” IEEE Journal of Selected Topics in Signal Processing, vol. 10, no. 3, pp. 436–453, Feb. 2016.
7cs.IT
Operator scaling: theory and applications Ankit Garg ∗ Leonid Gurvits† Rafael Oliveira ‡ Avi Wigderson § arXiv:1511.03730v3 [cs.CC] 13 Apr 2017 April 17, 2017 Abstract In this paper we present a deterministic polynomial time algorithm for testing if a symbolic matrix in non-commuting variables over Q is invertible or not. The analogous question for commuting variables is the celebrated polynomial identity testing (PIT) for symbolic determinants. In contrast to the commutative case, which has an efficient probabilistic algorithm, the best previous algorithm for the non-commutative setting required exponential time [IQS15b] (whether or not randomization is allowed). The algorithm efficiently solves the “word problem” for the free skew field, and the identity testing problem for arithmetic formulae with division over non-commuting variables, two problems which had only exponential-time algorithms prior to this work. The main contribution of this paper is a complexity analysis of an existing algorithm due to Gurvits [Gur04], who proved it was polynomial time for certain classes of inputs. We prove it always runs in polynomial time. The main component of our analysis is a simple (given the necessary known tools) lower bound on central notion of capacity of operators (introduced by Gurvits [Gur04]). We extend the algorithm to actually approximate capacity to any accuracy in polynomial time, and use this analysis to give quantitative bounds on the continuity of capacity (the latter is used in a subsequent paper on Brascamp-Lieb inequalities). We also extend the algorithm to compute not only singularity, but actually the (non-commutative) rank of a symbolic matrix, yielding a factor 2 approximation of the commutative rank. This naturally raises a relaxation of the commutative PIT problem to achieving better deterministic approximation of the commutative rank. Symbolic matrices in non-commuting variables, and the related structural and algorithmic questions, have a remarkable number of diverse origins and motivations. They arise independently in (commutative) invariant theory and representation theory, linear algebra, optimization, linear system theory, quantum information theory, approximation of the permanent and naturally in non-commutative algebra. We provide a detailed account of some of these sources and their interconnections. In particular we explain how some of these sources played an important role in the development of Gurvits’ algorithm and in our analysis of it here. ∗ Microsoft Research New England, email: [email protected]. This research was done when the author was a student at Princeton University and his research was partially supported by Mark Braverman’s NSF grant CCF1149888, Simons Collaboration on Algorithms and Geometry, Simons Fellowship in Theoretical Computer Science and a Siebel Scholarship. † Department of Computer Science, The City College of New York, email: [email protected] ‡ Department of Computer Science, Princeton University, email: [email protected]. Research supported by NSF Career award (1451191) and by CCF-1523816 award. § Institute for Advanced Study, Princeton, email: [email protected]. This research was partially supported by NSF grant CCF-1412958. 1 Contents . . . . . . . . 4 7 8 10 11 13 15 18 20 G . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 20 22 25 1 Introduction 1.1 The Free Skew Field . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.2 Word Problems and Identity Tests . . . . . . . . . . . . . . . . . . . . . . . . . 1.3 Commutative and Non-commutative Rank of Symbolic Matrices . . . . . . . . 1.4 Compression Spaces, Optimization and Gurvits’ Algorithm G . . . . . . . . . . 1.5 Permanents, Quantum Operators, Origins and Nature of Algorithm G . . . . . 1.6 Invariant Theory, Left-Right Action, Capacity and the Analysis of Algorithm G 1.7 Computation and Continuity of Capacity . . . . . . . . . . . . . . . . . . . . . 1.8 Organization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 Quantum Operators and Analysis of Algorithm 2.1 Completely Positive Operators and Capacity . . 2.2 Algorithm G and its convergence rate . . . . . . 2.3 Main Theorem: The Lower Bound on Capacity . . . . . . . . . . . . . . . . . 3 Properties of Capacity 29 3.1 Capacity of almost doubly stochastic operators . . . . . . . . . . . . . . . . . . . . . 29 3.2 Characterization of approximate optimizers for capacity . . . . . . . . . . . . . . . . 32 3.3 Multiplicativity of capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 4 Bit 4.1 4.2 4.3 Complexity Analysis of Algorithm G and Continuity of Capacity Evolution of the Operator through Scaling . . . . . . . . . . . . . . . . . . . . . . . . Bit Complexity Analysis of Algorithm G . . . . . . . . . . . . . . . . . . . . . . . . . Continuity of Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 38 40 43 5 Computing the Capacity of a Quantum Operator 46 5.1 Computing Capacity with Truncation . . . . . . . . . . . . . . . . . . . . . . . . . . 49 6 Problems solved by Algorithm G 6.1 Preliminary definitions . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.1 Free Skew Field . . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.2 Shrunk Subspace . . . . . . . . . . . . . . . . . . . . . . . . . 6.1.3 Invariant Theory . . . . . . . . . . . . . . . . . . . . . . . . . 6.2 Problem Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.1 SINGULAR . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.2 Computing the Non-Commutative Rank and Fullness Testing 6.2.3 Testing Shrunk Subspaces . . . . . . . . . . . . . . . . . . . . 6.2.4 Null-Cone of the Left-Right Action . . . . . . . . . . . . . . . 6.2.5 Testing Rank Decreasing Property of Quantum Operators . . 6.2.6 Matrix Inverse Identity Testing . . . . . . . . . . . . . . . . . 6.2.7 Non-commutative Rational Identity Testing . . . . . . . . . . 6.3 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Conclusion and Open Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 51 51 52 53 54 54 54 56 56 57 58 59 59 59 2 A Symbolic matrices with polynomial A.1 Higman’s Trick . . . . . . . . . . . A.2 Classical Reduction . . . . . . . . . A.3 The Quantum Reduction . . . . . entries and non-commutative rank 66 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 3 1 Introduction This introduction will be unusually long, due to the unusual number of settings in which the problems we study appear, and their interconnections and history. The main object of study in this paper are symbolic matrices whose entries are linear functions in variables x = {x1 , x2 , . . . , xm } over a field1 F. Any such matrix can be expressed as a linear combination of the variables with matrix coefficients L = x1 A1 + x2 A2 + · · · + xm Am where A1 , A2 . . . , Am are n × n matrices2 over F. The main computational problem we will be concerned with in this paper (which we call SINGULAR) is determining whether such a symbolic matrix is invertible or not (over the field of fractions in the given variables). This problem has a dual life, depending on whether the variables commute or don’t commute. In the commutative case this problem has an illustrious history and significance. It was first explicitly stated by Edmonds [Edm67], and shown to have a randomized polynomial time algorithm by Lovasz [Lov79]. The completeness of determinant for arithmetic formulas by Valiant [Val79] means that singularity captures the celebrated Polynomial Identity Testing (PIT) problem, and so in the commutative setting we will refer to it as PIT. The derandomization of the latter probabilistic algorithm for PIT (namely, proving PIT ∈ P) became all-important overnight when Kabanets and Impagliazzo [KI04] showed it would imply nontrivial arithmetic or Boolean lower bounds well beyond current reach. On the other hand, in the non-commutative case even the meaning of this problem SINGULAR is unclear. It took decades to fully define and understand the related notion of a “field of fractions” for non-commutative polynomials, namely the free skew field over which we (attempt to) invert the matrix3 . But as we will explain below, this non-commutative SINGULAR problem has many intuitive and clean equivalent formulations (some entirely commutative!). It captures a non-commutative version of identity testing for polynomials and rational functions, provides a possible avenue to attack the notorious commutative PIT version, and quite surprisingly, its different formulations arise naturally in diverse areas of mathematics, revealing surprising connections between them. We only note that unlike the commutative PIT, it is not even clear from its definition that the problem SINGULAR is decidable. It requires some of the very nontrivial characterizations above, and other important results in commutative algebra, to prove a deterministic exponential time upper bound on its complexity (see two very different proofs in [CR99, IQS15b]), the best known before this work. No better bound was known even allowing randomness. The main result of this paper is a deterministic polynomial time algorithm for this problem! Theorem 1.1. For non-commutative variables over Q, SINGULAR ∈ P. More specifically, there is a deterministic algorithm which, given m n×n integer matrices A1 , . . . Am 1 Our main results will be for the rationals Q (and will hold for the Reals and Complex numbers as well) but not for finite fields. However many of the questions are interesting for any field. 2 For all purposes we may assume that the matrices Ai are linearly independent, namely span a space of matrices of dimension exactly m. 3 For now, the reader may think of the elements of this “free skew field” simply as containing all expressions (formulas) built from the variables and constants using the arithmetic operations of addition, multiplication and division (we define it more formally a bit later). We note that while this is syntactically the same definition one can use for commuting variables, the skew field is vastly more complex, and in particular its elements cannot be described canonically as ratios of polynomials. 4 with entries of bit-size b, decides in time poly(n, m, b) if the matrix L = over the free skew field. Pm i=1 xi Ai is invertible We now formulate the problem SINGULAR for non-commuting variables in its various contexts and incarnations. We will keep throughout an analogy with the commutative case. To avoid confusion, we will switch to calling commuting variables y, and keep x to denote non-commuting variables. As is common let F[y] denote the algebra of polynomials in commuting variables y = {y1 , y2 , . . . , ym } over a field F, and F(y) the field of rational functions over these variables (every element of this field is a ratio of two polynomials in F[y]). For commuting variables there are many simple equivalent formulations of the problem. P Fact 1.2 (PIT). The following are equivalent for a matrix L = m i=1 yi Ai in commuting variables y. Some of these equivalences only hold for large enough fields F. (1) L is singular (namely not invertible) over F(y). (2) L has nontrivial factors in F(y). Namely, there exist r < n, matrices K, M of dimensions n × r, r × n (respectively) with entries in F(y) such that L = KM . The smallest r with this property is called the (commutative) rank of L, and is denoted rank(L). (3) The linear space defined by L is singular, namely contains no Pnon-singular matrix over F. In other words, for every choice of constants βi ∈ F the matrix m i=1 βi Ai is singular over F. P (4) Det( i yi Ai ) ≡ 0 as a polynomial over F[y], where Det is the determinant polynomial. Now consider the non-commutative situation. The algebra of polynomials over non-commutative variables x = {x1 , x2 , . . . , xm } is familiar enough, and denoted Fhxi. Its (skew) “field of fractions”4 , which we have yet to define, is denoted F <x ( >. ) As in the commutative case, its elements include all inverses of nonzero polynomials in Fhxi(but as mentioned above, these elements may be far more complex than ratios of polynomials in Fhxi). One can formally define, as we will, the noncommutative SINGULAR problem, exactly as (1) in Fact 1.2 for the commutative case. But then most analogs of these equivalences seem to break down if we take them literally. E.g. (3) clearly doesn’t make sense (as it will not distinguish commuting from non-commuting elements), and (4) is ill-defined due to the plethora of non-commutative variants of the determinant polynomial (see e.g. [GGRW02]). However, the beauty of the non-commutative setting is revealed in many more equivalences, which we collect in the following theorem (which in particular has interesting analogs of (2),(3),(4)). These equivalences illustrate some of the connections to optimization, (commutative) invariant theory, non-commutative algebra and quantum information theory. All of these equivalences will be discussed in this introduction, and elaborated on more formally later. We note that some of them are highly nontrivial theorems we shall later reference individually. To compare between the commutative and non-commutative worlds, and appreciate better the equivalences, it is instructive to have in mind the following example. Example 1.3. The following 3 × 3 skew symmetric matrix is singular over F(z, w) but not singular over F <z, ( w >. )   0 z w  −z 0 1  −w −1 0 4 Actually there are many, but only one “universal field of fractions” 5 P Theorem 1.4 (SINGULAR). The following are equivalent for a matrix L = m i=1 xi Ai in noncommuting variables x. Again some of these equivalences only hold for large enough fields F. 1. L is singular (namely not invertible) over F <x ( > ). 2. L has nontrivial polynomial factors in Fhxi. Namely, there exist r < n, matrices K, M of dimensions n × r, r × n (respectively) with entries in Fhxi5 such that L = KM . The smallest r with this property is called the non-commutative rank (and sometimes inner rank) of L, and is denoted nc-rank(L). 3. The linear space defined by L with matrix coefficients is singular. Namely, for Pmevery integer k and every tuple of k × k matrices (B1 , B2 , . . . , Bm ) over F, the matrix i=1 Bi ⊗ Ai is singular over F. P 4. For every integer k we have Det( Xi ⊗ Ai ) ≡ 0, where the Xi are k × k matrices of commutative variables, Det is still the commutative determinant polynomial, acting here on kn × kn matrices. 5. L has a shrunk subspace. Namely, there are subspaces U, W of Fn , with dim W < dim U , such that for all i Ai U ⊆ W . 6. L has a Hall-blocker (in analogy with the Hall theorem for perfect matchings). Namely, there exist nonsingular matrices B, C over F such that the symbolic matrix BLC has an all-zeros minor of size i × j, with i + j > n. 7. The completely positive quantum operator (or map) associated with L is rank-decreasing. P † Namely, there exist a positive semi-definite matrix P such that rank( m i=1 Ai P Ai ) < rank(P ). 8. The tuple of matrices (A1 , A2 , . . . , Am ) is in the null-cone of the Left-Right action of (SLn (F))2 on m n × n matrices, namely they evaluate to zero on every non-constant homogeneous invariant polynomial under this action6 . In the rest of this introduction we will try to explain how and why the problem SINGULAR arises in these different contexts, how are they related. We will discuss the algorithm that solves SINGULAR (which already appears in [Gur04]), its complexity analysis (which is the main result of this paper), and how they arise from these (and other!) sources. We will also discuss the extension of this algorithm to non-commutative rank computation, and the implications of these algorithms to the various settings. We also highlight the recurring analogs and connections between the commutative and non-commutative worlds. There are probably many ways to weave this meandering story due to the multiple connections between the topics; we chose one (some accounts of subsets of these connections appear e.g. in [Gur04, HW14, IQS15b]). Note that most descriptions will be informal or semi-formal; formal definitions for everything that is actually needed will be given in the technical sections, and for the rest we provide references. 5 Moreover, the polynomial entries of K, M in such a minimal decomposition can actually be taken to be polynomials of degree 1, namely affine combinations of the variables. 6 The Left-Right action and its invariant polynomials are defined as follows. Consider mn2 commuting variables (Y1 , Y2 , . . . Ym ), each a matrix, and consider polynomials in these variables. Every pair B, C of determinant 1 matrices over F defines a linear map of these variables by sending this tuple to (BY1 C, BY2 C, . . . BYm C). A polynomial in these variables is invariant if it remains unchanged by this action for every such pair B, C. 6 1.1 The Free Skew Field Polynomials, both in commuting and non-commuting variables, can always be uniquely defined by their coefficients. And so, while their computational complexity is of course interesting, it is not part of their description. For rational functions this persists in the commutative setting, as they are simply ratios of polynomials. It is perhaps amusing that in the non-commutative setting, the first definition of the free skew field of rational functions was computational, namely one whose objects are described by their computation via a sequence of arithmetic operations. Both this description, and the subsequent discovery of a syntactic representation play an important role in our story. Books on history and construction of the skew field include [Coh95, Row80], and a thorough discussion from the computational perspective is given in [HW14]. Here we will be relatively brief, highlighting the key roles played by matrices and symbolic matrices in these constructions of the free skew field. Fix a field F and a set of non-commuting variables x = {x1 , x2 , . . . , xm }. As before, let Fhxi denote the the (free) algebra of non-commutative polynomials. A major objective is to construct a (minimal) “skew field of fractions”, which contains this algebra and is a division ring, namely every non-zero element is invertible. As it happens, there can be many non-isomorphic ways of doing ( > ) , first defined by Amitsur [Ami66] that, but only one that is universal 7 , the free skew field F <x as follows (see a more detailed and precise description in [KVV10]). A rational expression r(x) is simply a formula whose inputs are variables and constants from F, over the standard arithmetic operations of addition, multiplication and division, e.g. x−1 1 − −1 8 −1 −1 (x1 + x2 ) and (x1 + x1 x2 x1 ) (note that inversions can be arbitrarily nested ). Essentially, the elements of the field will consist of these expressions, modulo an equivalence relation that we now define. Note that substituting d × d matrices for the variables of an expression r it becomes a (partial) function9 . Two expressions r, s are equivalent if they agree (output the same matrix) for all inputs for which they are defined (where we go over all tuples of matrices from Md (F) for all finite d. Theorem 1.5 ([Ami66]). The rational expressions under the above equivalence relation comprise the (universal) free skew field F <x ( >. ) One important complication (or perhaps a fountain of interesting problems) in the non-commutative setting is that a non-zero rational expression (or even a polynomial expression, namely one with no inverses) can be an identically zero function over the entire Md (F) for some finite d. The simple example x1 x2 − x2 x1 is a polynomial identity for d = 1, and more generally the standard polynomial P sgn(π) x (−1) π(1) xπ(2) · · · xπ(2d) is a polynomial identity for Md (F). By the celebrated Amitsurπ∈S2d Levitsky theorem, this example is tight in terms of the relation between the degree of the polynomial identity and dimension of matrices. Theorem 1.6 ([AL50]). A degree k polynomial cannot vanish on all inputs in Md (F) for d > ⌊k/2⌋. 7 This is a technical term which we will not define here. In general inversion height, the minimum amount of nesting needed, can be arbitrarily high. This is an important theorem of Reutenauer [Reu96]. However, in the example above the nested inversion can be eliminated, and in fact the two expressions are equal (a simple fact which the reader might try to prove)! This equality is called Hua’s identity [Hua49], underlying the fundamental theorem of projective geometry 9 when the expression attempts to invert a singular matrix it is undefined on that input. The domain of an expression is simply all input tuples on which it is defined 8 7 This theorem immediately implies a polynomial identity test in probabilistic polynomial time (just like in the commutative case) mentioned in the next subsection - simply plug random matrices of appropriate size for the variables. However, for rational expressions, which is our main interest here, such upper bounds on the sufficient dimension to exclude rational identities are much harder to prove, and what is known is much weaker. The best bounds (and only for some fields) are exponential, which seem to only provide probabilistic exponential time rational identity tests. The last subsection of this introduction shows how these exponential dimension bounds arise and obtained from invariant theory, and how we use them to nonetheless derive a deterministic, polynomial time identity test promised in our main theorem. A second construction of the free skew field which is somehow more concrete was developed by Cohn. In the notation we have already established of symbolic matrices Cohn proved: ( > ) is an entry of the inverse of Theorem 1.7 ([Coh71]). Every element of the free skew field F <x some (invertible) symbolic matrix whose entries are polynomials in Fhxi. For this definition not to be self-referential (and other reasons) Cohn proved some of the important characterizations of invertible matrices, including items (2) and (5) in Theorem 1.4. It is clear that (each entry of) the inverse of such a matrix can be given by a rational expression, and the question of whether a matrix is invertible again arises naturally, and it turns out to capture rational identity testing. 1.2 Word Problems and Identity Tests Word problems and their complexity are central throughout mathematics, arising whenever mathematical objects in a certain class have several representations. In such cases, a basic problem is whether two such representations describe the same object. Often, indeed, some problems of this form have served as early examples of decidable and undecidable problems10 . For us, the objects in question are polynomials and rational functions in commuting and noncommuting variables. Their standard representations will be arithmetic formulas and circuits, which take the variables (and constants in F) as inputs, and use plus, times and division gates. An excellent exposition of arithmetic complexity models and the state-of-art in the subject is [SY10] (which discusses at length the polynomial identity testing problem11 ). We stress that we will specifically allow division gates in our computational models, both because we want to consider rational functions, and because unlike for computing polynomials, in the non-commutative case there is no known analog of Strassen’s theorem [Str73] that divisions can be efficiently eliminated. This issue and partial results, many relevant to this paper, are discussed in [HW14]. The word problem in our arithmetic context is equivalent to an Identity Test, checking if a given representation of a polynomial or rational function describes the trivial element, the zero polynomial. As is well known, the main reason why PIT is so important in the commutative setting is that it captures the polynomial and rational function identity test for formulas, as proved by Valiant [Val79]. Combining it with the equivalences of Fact 1.2, we have 10 E.g. deciding if two knots diagrams describe the same knot was proved decidable by Haken [Hak61], and deciding if two presentations with generators and relations describe the same group was proved undecidable by Rabin [Rab58] 11 while this paper focuses on identity testing, we note that our interest is partly (and indirectly) motivated by the more basic problem of proving lower bounds for non-commutative circuits. We refer the reader to the papers [Nis91, HWY10, HWY11, LMS15] and their references for existing lower bounds on weaker models, some completeness results, and possible approaches to proving stronger lower bounds 8 Theorem 1.8 ([Val79]). There is an efficient algorithm which converts every arithmetic formula φ(y) in commuting variables y of size s to a symbolic matrix Lφ of size poly(s), such that the rational expression computed by φ is identically zero if and only if Lφ ∈ PIT (i.e., Lφ is singular). Theorem 1.7 of the previous subsection, showing that in the non-commutative setting as well SINGULAR captures polynomial and rational function identity test, is the analog Valiant’s completeness theorem. It was proved even earlier by Cohn (see also Malcolmson’s version [Mal78]), using similar linear algebraic ideas. Here is a more precise statement which gives the analogy. Theorem 1.9 ([Coh71] ). There is an efficient algorithm which converts every arithmetic formula φ(x) in non-commuting variables x of size s to a symbolic matrix Lφ of size poly(s), such that the rational expression computed by φ is identically zero if and only if Lφ ∈ SINGULAR. As mentioned, the structure of the free skew field is so complex that unlike the commutative case, even decidability of SINGULAR (and rational identity testing) is far from obvious. The first to prove decidability was Cohn in [Coh73, Coh75]. The first explicit bound on time was given by Cohn and Reutenauer in [CR99], reducing it to a system of commutative polynomial equations using characterization (5) of SINGULAR, proved earlier by Cohn, which puts it in PSPACE. The best upper bound before this work was singly exponential time, obtained by [IQS15b], and of course yields the same bound for rational identity testing. From our Theorem 1.1 we conclude a deterministic, polynomial identity test for non-commuting rational expressions. Corollary 1.10. The non-commutative rational identity testing problem is in P. Namely, there is an algorithm which for any non-commutative formula over Q of size s and bit complexity b determines in poly(s, b) steps if it is identically zero. It is important to stress that unlike the commutative case, where symbolic matrix inversion can be simulated by quasi-polynomial sized formulas, in the non-commutative case symbolic matrix inversion is exponentially more powerful than formulas (and so Theorem 1.1 is far more powerful than its corollary above). We state these two results formally below for contrast12 . Note that when saying “computing the inverse” we mean computing any entry in the inverse matrix. Theorem 1.11 ([Hya79, Ber84]). The inverse of a commutative n × n symbolic matrix in F(y) can be computed by formulas of size nO(log n) . ( > ) Theorem 1.12 ([HW14]). The inverse of a non-commutative n × n symbolic matrix in F <x requires formulas of size 2Ω(n) . Our algorithm of Theorem 1.1 and corollary 1.10 is a “white-box” identity test (namely one which uses the description of the given matrix or formula), in contrast to a “black-box” algorithm which only has input-output access to the function computed by them. The best-known “blackbox” identity test for these formulas, even if randomization is allowed(!), requires exponential time. It is a very interesting question to find a faster black-box algorithm. When division is not allowed, efficient deterministic identity tests of non-commutative polynomials were known in several models. The strongest is for arithmetic branching programs (ABPs). As this model is easily stimulable by matrix inversion (see Theorem 6.5 in [HW14], our algorithm provides an alternative (and very different) proof of the following theorem of Raz and Shpilka [RS05]. 12 Replacing formulas by circuits there is no contrast - in both the commutative and non-commutative setting matrix inverse has a polynomial size circuit (with division of course) [HW14] 9 Theorem 1.13 ([RS05]). There is a deterministic polynomial time white-box identity testing algorithm for non-commutative ABPs. For certain classes computing only polynomials even efficient black-box algorithms are known, and we mention two below; the first deterministic, for non-commutative ABPs, and the second probabilistic (but for circuits). Theorem 1.14 ([FS13b]). There is a deterministic quasi-polynomial time black-box identity testing algorithm for non-commutative ABPs. Theorem 1.15 ([BW05, AL50]). There is a probabilistic polynomial time black-box identity testing algorithm for non-commutative circuits. 1.3 Commutative and Non-commutative Rank of Symbolic Matrices There are many sources, motivations and results regarding invertibility, and more generally rank, of commutative symbolic matrices, which are much older than the complexity theory interest in it. These mathematical papers, like the ones in the computational complexity literature, regard it as a difficult problem, and attempt to understand a variety of special cases (of a different nature than restrictions of the computational power of the model). Some of the many references to this body of work can be found in the papers [FR04, GM02]. Often, the non-commutative rank (explicitly or implicitly) is used to give upper bound on the commutative rank, and their relationship becomes of interest. We focus on this connection here, and explain how our main result implies a deterministic approximation algorithm to the commutative rank. In this section we assume that the underlying field F is infinite. We will use the same notation L for both a symbolic matrix, as well as the subspace of matrices spanned by it (when fixing the variables to constants in the field). We repeat the definitions and elaborate on what is known regarding the commutative and non-commutative ranks, from now on denoted by rank(L) and nc-rank(L). Note that the characterizations allow thinking about both without reference to the respective fields of fractions (over which they are most naturally defined), but only to polynomials. Fact 1.16. The following are equivalent for a commutative matrix L(y). • rank(L(y)) = r over F(y) • r is the maximal rank of any matrix in the subspace L over F. While the characterization above is simple, the one below is very substantial, mostly developed by Cohn for his construction of the free skew field. The first characterization is due to him [Coh95] and the second is due to Fortin and Reutenauer [FR04] who heavily use Cohn’s techniques. Theorem 1.17. The following are equivalent for a non-commutative matrix L(x). • nc-rank(L(x)) = r over F <x ( > ) • The inner rank of L over Fhxi is r. Namely, r is the minimal number such there exists matrices K, M of dimensions n × r, r × n (respectively) with polynomial entries in Fhxi such that L = KM . Moreover, in this decomposition the factors K, M can be assumed to have affine linear entries. 10 • The space L is r-decomposable. Namely, r is the minimal number such that there exists invertible matrices B, C over F such that BLC has a minor of zeros of size i × j with i + j = 2n − r. We can extend our main Theorem 1.1 from testing singularity to efficiently computing the non-commutative rank over Q, this is done in Theorem A.4. Theorem 1.18. There is a deterministic algorithm which, given m n×n integer matrices A1 , . . . Am P x Ai ). with entries of bit-size b, computes nc-rank(L) in time poly(n, m, b) (where L = m i i=1 Remark 1.19. We note here that in some formulations of the problem, L is represented in affine form, namely where an additional constant matrix A0 is added to L (this may be viewed as a noncommutative analog of the rank-completion problem). However, the algorithm above works in this case as well , since nc-rank(L) remains unchanged if an additional variable x0 was added as well. So, we will stick with the linear formulation. It is not hard to see from the definitions that for every L we have rank(L) ≤ nc-rank(L). We have already seen that they can be different in Example 1.3. Taking many copies of that 3 × 3 matrix we see that there can be a factor 3/2 gap between the two: for any r there are matrices L with rank(L) = 2r and nc-rank(L) = 3r. However, Fortin and Reutenauer [FR04] proved that this gap is never more than a factor of 2. Theorem 1.20 ([FR04]). For every L we have nc-rank(L) ≤ 2rank(L). An immediate corollary of our main result is thus a factor 2 approximation of commutative rank. Corollary 1.21. There is a polynomial time algorithm which for every symbolic matrix in commuting variables over Q approximates rank(L) to within a factor of 2. We find the question of obtaining a better approximation ratio efficiently a very interesting problem, a different relaxation of the commutative PIT problem that as far as we are aware was not studied till now. 1.4 Compression Spaces, Optimization and Gurvits’ Algorithm G An important class of spaces of matrices L, which is studied in many of the papers mentioned above, is the class of compression spaces (this notation was apparently introduced by Eisenbud and Harris [EH88]). They are defined as those spaces L for which L is rank(L)-decomposable. A simpler definition follows the characterization of [FR04] above, namely a space L is a compression space iff rank(L) = nc-rank(L). The importance of compression spaces and their many origins will be surveyed below. A deterministic polynomial time commutative PIT for compression spaces (over Q) was discovered by Gurvits [Gur04], a paper which serves as the starting point for this work.13 Indeed Gurvits’ algorithm, which we will denote by Algorithm G, is the same one we use here for our main 13 It is interesting to note that most recent progress on deterministic PIT algorithms (e.g. [KS01, DS06, KS07, SV11, FS13b] among many others) are for polynomials computed by a variety of restricted classes of arithmetic circuits. Algorithm G seems to differ from all of them in solving PIT for a very different class of polynomials, which we do not know how to classify in arithmetic complexity terms. 11 Theorem 1.1; our main contribution here is the analysis of its performance for any input L, not necessarily a compression space. We will return to the algorithm and its analysis, but first lets discuss its extension from testing singularity to rank computation. Before that, we state Gurvits’ theorem, which actually proves more about Algorithm G. Theorem 1.22 ([Gur04]). There is a deterministic polynomial time algorithm, Algorithm G, which for every n and every n × n matrix L given by a set of integer matrices (A1 , A2 , . . . , Am ), outputs “singular” or “invertible”, and its output is guaranteed to be correct14 when either rank(L) = n or nc-rank(L) < n. In particular, the algorithm always gives the correct answer for compression spaces. Our result on efficient computation of the non-commutative rank implies that for compression spaces we can determine the commutative rank. Many natural spaces are compression spaces, and these arise from a variety of motivations and sources in linear algebra, geometry and optimization. One such source is the attempt to characterize singular spaces (namely when rank(L) < n) by relating the rank to the dimension of the space matrix L defines, denoted dim(L). Perhaps the earliest result of this type is due to Dieudonné [Die49] who proved that if L is singular and dim(L) = n2 − n, then for some nonsingular matrices B, C over F the matrix BLC has an all-zero row or all-zero column. In other words, it has a Hall-blocker as in condition (6) in Theorem 1.4, and so is in particular decomposable. Many other similar results appear in e.g. [Atk80, AL80, Bea87, EH88, GM02], which prove decomposability under more general conditions on the dimension, and study a variety of other properties of singular and rank-bounded spaces. Yet another source, elaborated on in [Gur04], is geometric duality theorems, such as the ones for matroid intersection and matroid parity problems. These sometimes give rise to compression spaces, with one prototypical example being spaces where the generating matrices Ai all have rank1; this follows from the Edmonds-Rado [Edm69, Rad42] duality theorem for matroid intersection15 . Another, simpler example are spaces generated by upper-triangular matrices. Other examples of compression spaces are given in [Gur04]. Following his paper, we note that our rank algorithm above can solve such optimization problems in the dark, namely when the given subspace has such structured spanning generators, but the generators Ai actually given to the algorithm may be arbitrary. This is quite surprising, and in general cannot work by uncovering the original structured generators from the given ones: an efficient algorithm is not known for the problem of deciding if a given space of matrices is spanned by rank-1 matrices and we believe it is hard. It would be interesting to explore which other optimization problems can be encoded as the rank of a compression space, and whether the fact that it can be computed “in the dark” has any applications. In recent related work, [IKQS15] give a different “in the dark” algorithm for computing the rank of certain compression spaces (including the ones spanned by rank-1 matrices) using so-called second Wong sequences, a linear algebraic analog of “augmenting paths for matchings”. Its main advantage is that it works not only over subfields of C as our algorithm, but also over large enough finite fields. This resolves an open problem in [Gur04]. 14 For both the commutative and non-commutative definitions. It is an interesting question whether a compression space naturally arises from matroid parity duality of Lovasz [Lov80, Lov89]. 15 12 1.5 Permanents, Quantum Operators, Origins and Nature of Algorithm G We will describe the algorithm formally in Section 2.2. Here we give an informal description, which makes it easy to explain its origins and nature. We find these aspects particularly interesting. One (which has very few parallels) is that while the problem SINGULAR solved by Algorithm G in Theorem 1.1 is purely algebraic, the algorithm itself is purely analytic; it generates from the input a sequence of complex-valued matrices and attempts to discover if it is convergent. Another is that the algorithm arises as a quantum analog of another algorithm with very different motivation that we now discuss. To give more insight to the working of algorithm G, let us describe another algorithm (for a different problem) which inspired it, which we call Algorithm S. This matrix scaling algorithm was developed by Sinkhorn [Sin64] for applications in numerical analysis, and has since found many other applications (see survey and references in [LSW98], who used it as a basis for their deterministic algorithm for approximating the permanent of non-negative matrices). Two different analyses of Sinkhorn’s algorithm S, one of [LSW98] and the other in the unpublished [GY98] inspire the analysis of Algorithm G in [Gur04]. We describe the [LSW98] analysis for Algorithm S. We need a few definitions. For a nonnegative matrix A, let R(A) denote the diagonal matrix whose (i, i)-entry is the inverse of the L1 norm of row i (which here is simply the sum of its entries as A is non-negative). Similarly C(A) is defined for the columns16 . Algorithm S gets as input a non-negative integer matrix A. For a fixed polynomial (in the input size) number of iterations it repeats the following two steps • Normalize rows: A ← R(A) · A • Normalize columns: A ← A · C(A) What does this algorithm do? It is clear that in alternate steps either R(A) = I or C(A) = I, where I is the identity matrix. Thus A itself alternates being row-stochastic and column-stochastic. The question is whether both converge to I together, namely, if this process converts A to a doubly stochastic matrix. In [LSW98] it is proved that this happens if and only if Per(A) > 0, where Per is the permanent polynomial. Moreover, convergence is easy to detect after a few iterations! If we define ds(A) = ||R(A) − I||2 + ||C(A) − I||2 as a notion of distance between A and the doubly stochastic matrices, then the convergence test is simply whether ds(A) < 1/n. If it is that small at the end of the algorithm then Per(A) > 0, otherwise Per(A) = 0. The analysis of convergence of Algorithm S in [LSW98] is extremely simple, using the permanent itself as a progress measure (or potential function). It has the usual three parts which makes a potential function useful: 1. The input size provides an exponential lower bound on the starting value of Per(A), 2. The arithmetic-geometric mean inequality guarantees that it grows by a factor of 1 + 1/n at every iteration, and 3. The permanent of any stochastic matrix is upper bounded by 1. 16 A “non-triviality” assumption is that no row or column in A is all zero. 13 We shall return to this analysis of Algorithm S soon. As it happens, Algorithm G is a quantum analog of Algorithm S! In quantum analogs of classical situations two things typically happen, diagonal matrices (which commute) become general matrices (which do not), and the L1 norm is replaced by L2 . This happens here as well, and we do so almost syntactically, referring the reader to [Gur04] for their quantum information theoretic intuition and meaning of all notions we mention. P The input to algorithm G is a symbolic matrix L = i xi Ai , given by the n × n integer matrices (A1 , A2 , . . . , Am ). Briefly, L is viewed as a completely positive (quantum) operator, or P map, on psd matrices, mapping such a (complex valued) matrix P to L(P ) = i Ai P A†i (P is typically a “density matrix” describing a quantum state, namely a psd matrix with unit trace, and the operator L will typically preserve trace or at least not increase it). The dual operator L∗ acts P (as you’d expect) by L∗ (P ) = i A†i P Ai . The analog “normalizing factors” for L, named R(L) and P P 1 1 1 C(L) are defined17 by R(L) = ( i Ai A†i )− 2 , and C(L) = ( i A†i Ai )− 2 . Note that R(L) = L(I)− 2 1 and C(L) = L∗ (I)− 2 . On input (A1 , A2 , . . . , Am ) Algorithm G repeats, for a fixed polynomial (in the input size) number of iterations, the following analogous two steps • Normalize rows: L ← R(L) · L • Normalize columns: L ← L · C(L) So again, row and column operations are performed alternately, simultaneously on all matrices Ai . It is clear, as above, that after each step either R(L) = I or C(L) = I. It is natural to define the case when both occur as “doubly stochastic”, and wonder under what conditions does this sequence converges, namely both R(L) and C(L) simultaneously approach I, and alternatively the limiting L simultaneously fixes the identity matrix I. A natural guess would be that it has to do with a “quantum permanent”. Indeed, Gurvits [Gur04] defines such a polynomial (in the entries of the Ai ) QPer(L), and proves several properties and characterizations (for example, it is always non-negative like the permanent, and moreover degenerates to the permanent when the operator L is actually a “classical” operator described by a single non-negative matrix A). One can similarly define in an analogous way to the classical setting a “distance from double stochastic” by ds(L) = ||R(L) − I||2 + ||C(L) − I||2 , and and test (after polynomially many iterations) if ds < 1/n. This is precisely what Algorithm G does. It is not hard to see that if L (with non-commuting variables) is singular, then there is no convergence, the test above fails (and indeed QPer(L) = 0). However, in contrast to Algorithm S, the analysis in [Gur04] falls short of proving that, otherwise we have convergence (and QPer(L) > 0). It does so only under the strong (commutative) assumption Det(L) 6= 0, namely when the symbolic matrix, viewed with commuting variables, is nonsingular. This result was stated above as Theorem 1.22. The 3-step complexity analysis proceeds exactly as in [LSW98] for the classical Algorithm S described above, using the quantum permanent as a progress measure. However, if Det(L) = 0 then QPer(L) = 0, and lower bounding the initial quantum permanent from below in part (1) of that analysis fails. To prove our main theorem, showing that convergence happens if and only if L is non-singular over the non-commutative skew field, we use another ingredient from Gurvits’ paper. He proposes another progress measure, called capacity and denoted cap(L). Capacity (defined in the next section) is a quantum analog of another classical progress measure, based on KL-divergence, which 17 Again using a “non-triviality” assumption these matrices are invertible. 14 was used in [GY98] for the analysis of Algorithm S. The advantage of capacity, as pointed out in [Gur04], is that it does not necessarily vanish when Det(L) = 0. Indeed, it is positive whenever L is non-singular! However Gurvits could only bound it sufficiently well from below as a function of the input size if Det(L) 6= 0. Thus, for a general input L, positive capacity only guarantees that Algorithm G converges in a finite number of steps, without providing an upper bound on that number. Our main contribution, which leads to a polynomial upper bound, is proving an explicit capacity lower bound for every L that is nonsingular over the skew field. The source of the proof turns out to be commutative algebra and invariant theory, as we discuss next. 1.6 Invariant Theory, Left-Right Action, Capacity and the Analysis of Algorithm G Invariant theory is a vast field; we will exposit here only the minimal background that is necessary for this paper. The books [CLO07, DK02, KP96] provide expositions on the general theory. More focused discussions towards our applications appear in the appendix of [HW14] and Section 1.2 of [FS13a]. Invariant theory deals with understanding the symmetries of mathematical objects, namely transformations of the underlying space which leave an object unchanged or invariant. Such a set of transformations always form a group (and every group arises this way). One major question in this field is, given a group acting on a space, characterize the objects left invariant under all elements of the group. Here we will only discuss very specific space and actions: polynomials (with commuting variables!) that are left invariant under certain linear transformations of the variables. The invariant polynomials under such action clearly form a ring (called the invariant ring). Important for us is the null-cone of the action, which is simply all assignments to variables which vanish on all non-constant homogeneous invariant polynomials. Here are two motivating examples surely familiar to the reader. The first example is given by polynomials in n variables y1 , . . . , yn invariant under the full group of permutations Sn ; here the invariant polynomials are (naturally) all symmetric polynomials. While this is an infinite set, containing polynomials of arbitrarily high degrees, note that this set of polynomials is generated (as an algebra) by the n + 1 elementary symmetric polynomials, with the largest degree being n. This finite generation is no coincidence! A general, important theorem of Hilbert [Hil93] assures us that for such linear actions there is always a finite generating set (and hence a finite upper bound on their maximum degree). Obtaining upper bounds on the degree of generating sets, finding descriptions of minimal generating sets for natural actions are the classical goals of this area, and a more modern one18 is obtaining succinct descriptions and efficient computation of these invariants (e.g. see [Mul12, FS13a]). The case of the action of the symmetric group is an excellent example of a perfect understanding of the invariant polynomial ring. Note that for this action the null-cone is simply the all-zero vector. The second example, much closer to our interest here, is the “Left-Right” action of the group (SLn (F))2 acting on n2 variables yij arranged in an n × n matrix Y . Specifically, two n × n matrices (of determinant 1) (B, C) take Y to BY C, changing the basis on the left and right 19 . It is not hard to see that all invariant polynomials under this action are generated by one - the determinant 18 Arising in particular in the GCT program of Mulmuley and Sohoni Note that for it to be a group action in the strict sense, one should study the action which takes Y to BY C −1 or BY C T but for simplicity, we will avoid this distinction. 19 15 Det(Y ) (which again has degree n). Note that the null-cone of this action is all singular matrices over the field. What we consider here is the left-right action on m n × n matrices, where a pair (B, C) as above takes (Y1 , Y2 , . . . , Ym ) to (BY1 C, BY2 C, . . . , BYm C). The study of the invariant ring of polynomials (in the mn2 variables sitting in the entries of these matrices) for this action was achieved20 by [DW00, DZ01, SdB01, ANS10], and will look very familiar from condition (4) in Theorem 1.4, as well as from Amitsur’s definition of the free skew field21 Theorem 1.23 ([DW00, DZ01, SdB01, ANS10]). Over algebraically closed fields, the invariant ring P of polynomials of the left-right action above is generated by all polynomials of the form Det ( i Di ⊗ Yi ), for all d and all d × d matrices Di . It is worthwhile to stress the connection forged between the commutative and non-commutative worlds by this theorem when combined with Amitsur’s and Cohn’s constructions of the skew field. A set of matrices (A1 ,P A2 , . . . , Am ) is in the null-cone of the left-right action if and only if the symbolic matrix L = i xi Ai is not invertible in the free skew field! In other words, the noncommutative SINGULAR problem (and thus rational identity testing, and the word problem in the skew field) arises completely naturally in commutative algebra. Of course, invertibility itself is invariant under the left-right action (indeed, even by any invertible matrices B, C, not necessarily of determinant 1), so one expects a connection in at least one direction. At any rate, one may hope now that commutative algebraic geometric tools will aid in solving these non-commutative problems, and they do! The generating set of the invariant ring given in the theorem is still an infinite set, and as mentioned above, Hilbert proved that some finite subset of it is already generating. Theorem 1.24 ([Hil93]). The invariant ring of polynomials of the action of a reductive group on a finite dimensional vector space is finitely generated. Hilbert proved his theorem for the actions of SLn (C) but his proof can be easily seen to be extendable to arbitrary reductive groups. Since (SLn (C))2 is reductive, Hilbert’s theorem implies that the invariant ring of polynomials of the left-right action is finitely generated. A natural definition to make now is β(n), the smallest integer such that taking only matrices with d ≤ β(n) generates the invariant ring22 . Hilbert did not give an explicit bound. The first to do so was Popov [Pop82], and this bound was significantly improved by Derksen [Der01]. A related quantity σ(n) is the smallest integer such that taking only matrices with d ≤ σ(n) suffice for testing membership in the null-cone. Derksen [Der01] proved that σ(n) and β(n) are polynomially related (over algebraically closed fields of characteristic zero) and that (for algebraically closed fields 2 of characteristic zero) σ(n) ≤ n2 4n . All bounds above hold for general reductive groups. For the specific left-right action further progress was made! First, Derksen’s bound was further improved to a smaller exponential by [IQS15b], and extended to finite fields. Theorem 1.25 ([IQS15b]). σ(n) ≤ (n + 1)! 20 We note that this is part of the larger project of understanding quiver representations, started by the works of Procesi, Razmysolov, and Formanek [Pro76, Raz74, For86]. 21 Note though that the roles of which matrices in the tensor product are variable, and which are constant, has switched! 22 This bound may a-priori depend on m, the number of matrices, but we already noted that m ≤ n2 . 16 This exponential upper bound was the state of art when we wrote our paper. Subsequent to it, this bound was greatly improved to linear! Theorem 1.26 ([DM15, IQS15a]). σ(n) ≤ n − 1 This much better bound gave rise to further important developments discussed below under “Subsequent Work”, that highlight even more how invariant theory informs algorithmic efficiency in certain problems. We conclude this section describing the idea behind our proof, which uncovers this connection. We plan to used the exact same 3-step complexity analysis of Algorithm G as the one for Algorithm S described in subsection 1.5, and which Gurvits [Gur04] used to analyze Algorithm G for a special subset of inputs. As mentioned, the only missing ingredient is step (1), namely an explicit lower bound on the capacity of an input operator L. Just like in the classical case of Algorithm S, an exponential lower bound (in terms of the size of L) is required to establish a polynomial convergence. This is a proper time to finally define this important parameter of positive operators23 . P Given L = (A1 , A2 , . . . , Am ), recall that L(P ) = i Ai P A†i and define cap(L) by cap(L) = inf Det(L(P )) where the infimum is taken over all psd matrices P with Det(P ) ≥ 1. First, observe that capacity is the solution to a non-convex optimization problem (over a convex domain). We will see in the next section that we can not only bound it, but actually compute it efficiently! Next, observe that capacity is an invariant (though not a polynomial invariant) of the left-right action; indeed the parameter P over which we optimize may be understood as acting on L, and thus capacity is also the infimum value Det(L′ ) can attain in the orbit of L under this action. What we know P is that cap(L) 6= 0. From this we infer that some polynomial invariant of the form above, Det ( i Ai ⊗ Di ) is nonzero, where the Di are d × d matrices for some d. This expression naturally suggests considering several new positive operators, and relating their capacities. The first, in dimension d, is the operator, M = (D1 , D2 , . . . , Dm ). Two others, in nd dimensions are LM = (A1 ⊗ D1 , A2 ⊗ D2 , . . . , Am ⊗ Dm ), and L ⊗ M = (A1 ⊗ D1 , . . . Ai ⊗ Dj , . . . , Am ⊗ Dm ). The non-vanishing of the determinant above proves that both cap(LM ) > 0 and cap(L ⊗ M ) > 0. And it is easy to obtain exponential lower bounds on both quantities, which however depends not only on the description size of L (which is given), but also of that of M which could be much larger. To facilitate our original capacity lower bound, which only used d ≤ σ(n) ≤ exp(poly(n)), we proved that the normalized24 capacity is multiplicative, a fact of independent interest (see details in Section 3.3): cap(L ⊗ M )1/nd = cap(L)1/n · cap(M )1/d Using only the easier direction, namely that the left hand side is at most the right hand side, it suggests that our lower bound on cap(L) will follow from a lower bound on cap(L ⊗ M ) and an upper bound on cap(M ). Both of these in turn follow from an upper bound on the entry sizes in M , namely in the Di , which easily follow from the given exponential upper bound on d. A key thing 23 24 We note that this notion of capacity seems to have nothing to do with the usual capacity of a quantum channel Taking the dimension’s root of capacity 17 to note is that even when d is exponential in n, and so these size bounds are doubly exponential, it is the d’th root of this bound that gives the required lower bound cap(L). For the new lower bound, presented in Section 2.3, we bound cap(L) using directly a bound on cap(L ⊗ M ). Using much more careful size bounds on the entries of M , which follow from Alon’s Nullstellensatz theorem, and tightening the reduction between the two capacities, we are able to derive the desired capacity lower bound using any finite bound on d ! This new proof eliminates the need for good degree upper bounds for the purpose of analyzing this algorithm (if one does not care about efficiency beyond having a polynomial bound). However good degree upper bounds (that are anyway an important goal in invariant theory) were essential for the original proof, and for general actions were useful for other algorithmic problems which arose in other contexts in computational complexity, for example in geometric complexity theory (GCT). Further, we believe they will be important for studying other problems in algebraic complexity and optimization. Indeed, in a work in progress, we need degree bounds for invariant rings whose generating sets are not understood as well as for the left-right action, but Derksen’s general exponential degree upper bound still holds and is useful. The capacity lower bound above implies, as mentioned, a polynomial upper bound on the number of iterations of Algorithm G, assuming we can perform exact arithmetic! To actually bound the running time the algorithm has to be refined, truncating numbers so that they can be represented by polynomially many bits, and so a careful analysis of the bit complexity is required to actually prove its running time. This issue naturally leads to the next section, in which we discuss how the algorithm can be extended to actually compute capacity of the input operator, as well as provide bounds on its continuity. These results in turn are essential in a follow-up work [GGOW17] we have done on the Brascamp-Lieb inequalities, where capacity arises naturally via a simple reduction to operator scaling. 1.7 Computation and Continuity of Capacity We also show that Algorithm G can be modified to compute the capacity of a completely positive operator L. Recall that the capacity of an operator L is defined to be cap(L) = inf Det(L(P )), where the infimum is taken over all psd matrices P with Det(P ) = 1. The following theorem is proven as Theorem 5.3 in Section 5. Theorem 1.27. There is a poly(n, b, 1/ǫ) time algorithm for computing a (1 + ǫ)-multiplicative approximation to cap(L). Here n is the dimension on which L acts and b denotes the bit-sizes involved in description of L. This is quite fascinating since we don’t know of a convex formulation for cap(L). The idea for the computation of capacity is quite simple. We know that the capacity of a doubly stochastic operator is exactly 1. We also know how operator scaling changes the capacity. If LB,C is a scaling of L i.e. LB,C (X) = B · L(C · X · C † ) · B † then cap(L) = |Det(B)|−2 · |Det(C)|−2 · cap(LB,C ) = |Det(B)|−2 · |Det(C)|−2 if LB,C is doubly stochastic. Thus if we can find a doubly-stochastic-scaling of L, then we can compute cap(L) exactly. Algorithm G helps in finding an approximately-doubly-stochastic-scaling of L, which results in an approximation scheme for computing cap(L). It is a very intriguing open 18 problem if a (1 + ǫ) approximation to cap(L) can be computed in time poly(n, b, log(1/ǫ)). In the aforementioned upcoming paper, we use this result (via a black-box reduction!) to approximating optimal constants in Brascamp-Lieb inequalities. Although, we don’t know of a convex formulation for capacity, it does have some nice properties. For example, any critical point is in fact a global minima! Let us look at the Lagrangian for log(cap(L)): f (X, λ) = log(Det(L(X))) + λ · log(Det(X)) It can proved  [Gur04] that a critical point C i.e. where the gradient ∇f (C, λ) = 0 should satisfy L∗ L(C)−1 = C −1 . It follows from    ∗ −1 −1 ∇f (C, λ) = L L(C) + λC , log (Det(C)) and the normalization condition i h   tr C · L∗ (L(C))−1 = tr L(C) · L(C)−1 = n This implies by Lemma 3.8 that cap(L) ≥ Det(L(C) Det(C) and hence C is a global minima for cap(L). It would be interesting to see if our techniques can help solve other non-convex optimization problems which share the same property. Algorithm G can also be thought of as an alternating minimization algorithm for computing capacity. First let us write capacity in an alternate way. n · cap(L)1/n = inf tr[L(X) · Y ] = inf tr[X · L∗ (Y )] s.t. Det(X) ≥ 1, Det(Y ) ≥ 1, X, Y ≻ 0 While the constraints are convex (by log-concavity of determinant), the objective is quadratic. However if, we fix X or Y , this program is convex. In fact, if we fix X, the optimum Y is Det(L(X))1/n · L(X)−1 . Similarly, if we fix Y , the optimum X is Det(L∗ (Y ))1/n · L∗ (Y )−1 . Starting from X0 = I, if we do alternate minimization, we get exactly Algorithm G and our results imply that this process converges in polynomial number of steps! From the description of capacity, it is not clear if it is continuous. The reason is that a priori, the optimizing matrices could be radically different for cap(L1 ) and cap(L2 ) even if L1 and L2 are quite close. We show that this not the case, essentially because cap(L) (as well as the optimizer) can be approximated by a simple iterative process namely Algorithm G! And Algorithm G is clearly continuous in L. We prove this formally in Theorem 4.5 of Section 4.3. In the aforementioned upcoming paper, we use this result to prove continuity of Brascamp-Lieb constants. Remark 1.28. The continuity of capacity can also be proven via other methods and is already mentioned in [Gur04]. But here we manage to get explicit bounds on the continuity parameter which we don’t know how to get by methods other than analyzing Algorithm G. Subsequent Work After our work, Derksen and Makam [DM15] obtained polynomial degree bounds for the left-right action over any field! Using this bound, Ivanyos, Qiao and Subrahmanyam [IQS15a] designed 19 a completely different deterministic polynomial time algorithm for SINGULAR that works over all fields. This algorithm has a combinatorial/linear algebraic flavor, and has several important advantages over our algorithm, but also some limitations in comparison. One clear advantage is of course that it works over every field. Another is that this algorithm can certify the non-commutative singularity of an input L over F <x ( > ) by outputting a shrunk subspace when one exists! On the other hand, over the rationals, our algorithm computes capacity, and finds an operator scaling which is doubly stochastic. Using some of the techniques developed in the IQS paper, Bläser, Jindal and Pandey [BJP16] designed a deterministic PTAS for the commutative rank i.e. a (1 + ǫ)-approximation algorithm which runs in deterministic nO(1/ǫ) time. This improves the factor-2 approximation algorithm given in this paper,. Finally, as mentioned above, in a subsequent paper [GGOW17], we use the techniques and results of this paper to give new algorithmic results in the theory of Brascamp-Lieb inequalities. This connection also further highlights the potential of the operator scaling algorithm in optimization. 1.8 Organization In Section 2, we describe Algorithm G for testing if quantum operators are rank-decreasing. We explain the notion of capacity of quantum operators, prove an explicit lower bound on the capacity of rank non-decreasing operators, and explain how it is used in the analysis to prove that Algorithm G runs in polynomial time. In Section 3, we study various properties of capacity, some of which are used in other places in the paper. In Section 4, we analyze the bit complexity of Algorithm G and also prove an explicit bound on the continuity of capacity. In Section 5, we will show how a modification of Algorithm G can be used to approximate capacity. In the appendix Section A, we show how to compute the non-commutative rank. We conclude in Section 7 with a short discussion and open problems. 2 Quantum Operators and Analysis of Algorithm G This section is devoted to Algorithm G and its analysis. We start with preliminaries about completely positive operators, their properties, and basic quantities associated with them. We then formally describe Algorithm G, and proceed to give a full analysis of its running time, proving the main theorem of this paper. Section 2.1 contains definitions and properties of completely positive operators and their capacity. Section 2.2 describes the Algorithm G and its analysis assuming an explicit lower bound on the capacity. Section 2.3 contains the main theorem concerning the lower bound on capacity of rank non-decreasing operators. 2.1 Completely Positive Operators and Capacity Given a complex matrix A, we will use A† to denote the conjugate-transpose of A. For matrices with real entries this will just be AT . For a matrix A, Im(A) will denote the image of A i.e. {v ∈ Cn |v = Au for some u ∈ Cn }. Definition 2.1 (Completely positive operators). An operator (or map) T : Mn (C) → Mn (C) is P † called completely positive if there are n×n complex matrices A1 , . . . , Am s.t. T (X) = m i=1 Ai XAi . 20 The matrices A1 , . . . , Am are called Kraus operators of T (and they are not unique). T is called P † completely positive trace preserving (cptp) if T ∗ (I) = m i=1 Ai Ai = I. Remark 2.2. The above is actually not the usual definition of completely positive operators. T is defined to be positive if T (X)  0 whenever X  0. T is completely positive if In ⊗ T is positive for all n ≥ 1. Choi [Cho75] proved that an operator is completely positive iff it is of the form stated above. Definition 2.3 (Tensor products of operators). Given operators T1 : Md1 (C) → Md1 (C) and T2 : Md2 (C) → Md2 (C), we define their tensor product T1 ⊗ T2 : Md1 d2 (C) → Md1 d2 (C) in the natural way (T1 ⊗ T2 )(X ⊗ Y ) = T1 (X) ⊗ T2 (Y ) and extend by linearity to the whole of Md1 d2 (C). P † ∗ Definition 2.4. If T (X) = m i=1 Ai XAi is a completely positive operator, we define its dual T P † ∗ ∗ by T ∗ (X) = m i=1 Ai XAi . If both T and T are trace preserving, namely T (I) = T (I) = I then we call T (and T ∗ ) doubly stochastic. Definition 2.5 (Rank Decreasing Operators). A completely positive operator T is said to be rankdecreasing if there exists an X  0 s.t. rank(T (X)) < rank(X). T is said to be c-rank-decreasing if there exists an X  0 s.t. rank(T (X)) ≤ rank(X) − c. Now that we defined completely positive operators, we define their capacity, which is a very important complexity measure of such operators suggested in [Gur04]. Its evolution will be central to the complexity analysis of our algorithm. Definition 2.6 (Capacity). [Gur04] The capacity of a completely positive operator T , denoted by cap(T ), is defined as cap(T ) = inf{Det(T (X)) : X ≻ 0, Det(X) = 1} This notion of capacity has a very interesting history. Some special cases of capacity were defined in [GS00] and [GS02]. It was then extended to hyperbolic polynomials and this also led to a resolution (and extremely elegant proofs) of the Van der Waerden Conjecture for Mixed Discriminants [Gur06]. The next proposition shows how capacity changes when linear transformations are applied (as in the algorithm) to the completely positive operator. Proposition 2.7 ([Gur04]). Let T be the operator defined by A1 , . . . , Am and let TB,C be the operator defined by BA1 C, . . . , BAm C, where B, C are invertible matrices. Then cap(TB,C ) = |Det(B)|2 |Det(C)|2 cap(T ) 21 Proof. ( m X cap(TB,C ) = inf Det i=1 2 BAi CXC †A†i B † ( m X = |Det(B)| · inf Det = |Det(B)|2 · inf Det m X Ai XA†i i=1 2 : X ≻ 0, Det(X) = 1 Ai CXC i=1 ( 2 ! † ! A†i ! ) ) : X ≻ 0, Det(X) = 1 : X ≻ 0, Det(X) = |Det(C)|2 ) = |Det(B)| · |Det(C)| · cap(T ) The next proposition gives a useful upper bound on the capacity of trace preserving completely positive operators; this will be used for the convergence analysis of the algorithm. Proposition 2.8 (Capacity Upper Bound). Let T be a completely positive operator with Kraus P † operators A1 , . . . , Am (which are n × n complex matrices). Also suppose that either m i=1 Ai Ai = I Pm or i=1 Ai A†i = I. Then cap(T ) ≤ 1. Proof. Note that tr(T (I)) = n in either case. cap(T ) ≤ Det(T (I)) ≤ (tr(T (I))/n)n =1 The second inequality follows from the AM-GM inequality. 2.2 Algorithm G and its convergence rate We now describe Algorithm G to test if a completely positive operator T (given in terms of Kraus operators A1 , . . . , Am ) is rank non-decreasing (equivalently properties (1) − (8) in Theorem 1.4 one of which is that A1 , . . . , Am admit no shrunk subspace). We will then analyze its convergence rate, namely the number of scaling iterations needed as a function of the input size. In section 4, we will continue with the finer analysis of the bit complexity of this algorithm. Since the property of A1 , . . . , Am having a shrunk subspace or not remains invariant if we replace A1 , . . . , Am by a basis spanning the subspace spanned by A1 , . . . , Am , we can always assume wlog that m ≤ n2 . Suppose the maximum bit size of the entries of A1 , . . . , Am is b. Since scaling the matrices A1 , . . . , Am doesn’t change the problem, we can assume that A1 , . . . , Am have integer entries of magnitude at most M = 2O(b) . Algorithm G below is essentially Gurvits’ algorithm [Gur04] for Edmonds’ problem for subspaces of matrices having Edmonds-Rado property. It is a non-commutative generalization of the Sinkhorn scaling procedure to scale non-negative matrices to doubly stochastic matrices (see for example [LSW98] and references therein). The algorithm alternates applying a “normalizing” basis change from the left and right to the given matrices, so as to alternately make the operator or its dual trace preserving. The idea is that this process will converge to a doubly stochastic operator iff it is not rank-decreasing, and furthermore, we can bound the number t of iterations by poly(n, log(M )). We will use the following to measure of our operator to being doubly stochastic. 22 Definition 2.9. i i h h ds(T ) = tr (T (I) − I)2 + tr (T ∗ (I) − I)2 We next prove that if a completely positive operator T is doubly stochastic, or close to being one in this measure, then it is rank non-decreasing. This will be important for the termination condition of Algorithm G. Theorem 2.10 ([Gur04]). If T is a completely positive operator which is right (or left) normalized such that ds(T ) ≤ 1/(n + 1), then T is rank non-decreasing. Proof. Wlog assume that T (I) = I and i h 2 ∗ tr (T (I) − I) ≤ 1/(n + 1) Suppose X  0 is a psd matrix s.t. Rank(X) = r. We would like to prove that Rank(T (X)) ≥ r. Let r X λi vi vi† X= i=1 be the eigenvalue decomposition of X where vi ’s are orthonormal and λi > 0. Then T (X) = r X i=1     λi T vi vi† Let us denote T vi vi† by Ri . Since T (I) = I, we get that Rank r X i=1 λ i Ri ! = Rank Pr i=1 Ri r X i=1 Ri !  T (I) = I. Also note that This is because Ri ’s are psd matricesPand hence a vector is in the kernel of the kernel of all the Ri ’s. Because of ri=1 Ri  I, we get that # ! " r r X X Ri Ri ≥ tr Rank (T (X)) = Rank i=1 Pr i=1 λi Ri iff it is in i=1 Suppose T ∗ (I) = I + ∆. We know that tr[∆2 ] ≤ 1/(n + 1). Then i i h h tr[Ri ] = tr T ∗ (I)vi vi† = 1 + tr ∆vi vi† Let P denote the projection onto {v1 , . . . , vr }. Adding the above equations for all i ∈ {1, . . . , r}, we get # " r X Ri = r + tr [∆P ] tr i=1 ≥ r − tr[∆2 ]1/2 tr[P 2 ]1/2 r r ≥r− n+1 23 Since r < n + 1, this gives us Rank (T (X)) > r − 1 which completes the proof since Rank (T (X)) is an integer. Definition 2.11. Given a completely positive operator T , define its right normalization TR as follows:   ∗ −1/2 ∗ −1/2 TR (X) = T T (I) XT (I) Note that TR∗ (I) = I. Definition 2.12. Given a completely positive operator T , define its left normalization TL as follows: TL (X) = T (I)−1/2 T (X)T (I)−1/2 Note that TL (I) = I. These operations are referred to as row and column operations in [Gur04]. We are now ready to present the algorithm. Input: Completely positive operator T given in terms of Kraus operators A1 , . . . , Am ∈ Zn×n . Each entry of Ai has absolute value at most M . Output: Is T rank non-decreasing? 1. Check if T (I) and T ∗ (I) are singular. If any one of them is singular, then output that the operator is rank decreasing, otherwise proceed to step 2. 2. Perform right and left normalizations on T alternatively for t steps. Let Tj be the operator after j steps. Also let ǫj = ds(Tj ). 3. Check if min{ǫj : 1 ≤ j ≤ t} ≤ 1/6n. If yes, then output that the operator is rank nondecreasing otherwise output rank decreasing. Algorithm 1: Algorithm G Remark 2.13. In algorithm G, the operators are maintained in terms of the Kraus operators and it is easy to see the effect of right and left normalizations on the Kraus operators. In fact, they are named such since for a right (left) normalization, the Kraus operators multiplied on the right (left) by T ∗ (I)−1/2 T (I)−1/2 . The main objective is to analyze the minimum number of steps t for which this algorithm terminates with the correct answer. The following theorem of [Gur04] gives the time analysis of the algorithm assuming an initial lower bound on the capacity of the input completely positive operator. In the next subsection we will prove our main result, an appropriate lower bound, which shows that the algorithm terminates with the correct answer in polynomial time. Theorem 2.14 ([Gur04]). Let T be a completely positive operator that is rank non-decreasing, whose Kraus operators are given by A1 , . . . , Am , which are n × n integer matrices such that each entry of Ai has absolute value at most M . Suppose TR is the right normalization of T . If cap(TR ) ≥ f (n, M ), then Algorithm G when applied for t = 2 + 36n · log(1/f (n, M )) steps is correct. 24 For completeness sake, we provide a full proof of this theorem. Again, this analysis follows similar ones for the classical Sinkhorn iterations, e.g. as in [LSW98, GY98]. Basically, capacity increases by a factor roughly 1 + 1/36n per iteration as long as it is not too close to 1. Proof. If either T (I) or T ∗ (I) is singular, then T decreases the rank of I. When T (I) is singular, ∗ ∗ this follows by definition.  When T (I) is singular, one way to see it is that Im(Ai ) ⊆ Im (T (I)) for  all i. Since Im Ai A†i = Im(Ai ), we get that Im (T (I)) ⊆ Im (T ∗ (I)) and hence T (I) is singular. If T (I) and T ∗ (I) are both non-singular, it is easy to verify that Tj (I) and Tj∗ (I) will remain non-singular for all j and hence step 2 is well defined. Also using Theorem 2.10 and the fact that right and left normalizations don’t change the property of being rank decreasing, Algorithm G will always output rank decreasing if T is rank-decreasing. So what is left to prove is if T is rank non-decreasing, then min{ǫj : 1 ≤ j ≤ t} ≤ 1/6n. Assume to the contrary that it is not. Denote by capj to be the capacity of the operator Tj . By Lemma 5.2 below (which essentially is a robust version of the AM-GM inequality), if ǫj > 1/6n, then capj+1 ≥ exp(1/36n) · capj . From the assumption of the theorem, we know that cap1 ≥ f (n, M ). Also it is easy to see that capj ≤ 1 for all j (Proposition 2.8). However by the assumption that min{ǫj : 1 ≤ j ≤ t} > 1/6n and the increase in capacity per iteration seen above, we get that     t−1 t−1 1 ≥ capt ≥ exp · cap1 = exp · f (n, M ) 36n 36n Plugging in t = 2 + 36n · log(1/f (n, M )) gives us the required contradiction. In the main Theorem 2.20 below we will prove that the quantity f (n, M ) used in the statement of Theorem 2.14 is ≥ exp(−4n log(M mn)), which will prove that the number of iterations needed in Algorithm G is O(n2 log(M mn)). But this alone doesn’t guarantee that the algorithm is actually polynomial time, since the bit sizes of numbers involved might get exponential. As it happens, simple truncation suffices to overcome this problem, as shown in [Gur04], and we reproduce this analysis in Subsection 4.2 for completeness. 2.3 Main Theorem: The Lower Bound on Capacity In this subsection we prove our main theorem, a lower bound on capacity of an operator in terms of its description size, in Theorem 2.20. Before diving into the proof we provide a high level plan. We will first prove that if a completely positive operator with integer entries is rank nondecreasing (that is has positive capacity), then the capacity is actually non-negligible. Our starting point (Theorem 1.4) is the statement of the equivalence between the rank non-decreasing property and an algebraic condition (non-vanishing of a certain determinant). Using Alon’s Combinatorial Nullstellensatz, we can ensure small coefficients in the algebraic condition above. We then state and prove (Lemma 2.17) a Cauchy-Schwartz inequality for matrices needed next. The main result (Theorem 2.18 ) proceeds by applying an appropriate scaling to the original integral operator, which reduces it to one that preserves the identity matrix. The latter property (which provides a trace bound), the integrality of the original operator (which provides an integral determinantal lower bound) and the multiplicativity of capacity under scaling combine (via the above inequality) to give the desired bound. We now proceed with the details of this plan. 25 We will need the fact that (nonzero) polynomials of degree d cannot vanish on all points with non-negative integer coordinates with sum ≤ d. This follows from Alon’s combinatorial nullstellensatz [Alo99, Theorem 1.2]. Lemma 2.15 ([Alo99]). If p(x1 , . . . , xn ) ∈ C[x1 , . . . , xn ] is a (nonzero) polynomial of degree d, where the individual degree of the variable xi is at most di , then there exists (a1 , . . . , an ) ∈ Zn≥0 n X ai ≤ d and ai ≤ di , for which p(a1 , . . . , an ) 6= 0. such that i=1 As a corollary of Theorem 1.4 and of Lemma 2.15, we get the following: Corollary 2.16. Let A1 , . . . , Am be n × n complex matrices s.t. the completely positive operator TA defined by A1 , . . . , Am is rank non-decreasing. Then there exist matrices D1 , . . . , Dm ∈ Md (C) for some d such that Det(D1 ⊗ A1 + · · · + Dm ⊗ Am ) 6= 0. Furthermore, D1 , . . . , Dm can be chosen to be matrices with non-negative integer entries s.t. d m X X j=1 k,l=1 Dj (k, l)2 ≤ n2 d Proof. By equivalences (3) and (7) of Theorem 1.4, we know that there exist matrices F1 , . . . , Fm ∈ Md (C), for some d, such that Det(F1 ⊗ A1 + · · · + Fm ⊗ Am ) 6= 0. This implies that the polynomial p(X1 , . . . , Xm ) = Det(X1 ⊗ A1 + · · · + Xm ⊗ Am ), where Xi are symbolic n × n matrices, is nonzero. Hence, by Lemma 2.15, we know that there exist matrices of positive integers D1 , . . . , Dm such that Det(D1 ⊗ A1 + · · · + Dm ⊗ Am ) 6= 0 and that m X d X j=1 k,l=1 Dj (k, l) ≤ deg(p) = nd Dj (k, l) ≤ n This is because the total degree of p is nd and the individual degree of each variable Xj (k, l) in p is at most n. This implies the desired upper bound. We will also need the following Cauchy-Schwarz like inequality: Lemma 2.17. Let C1 , . . . , Cm and D1 , . . . , Dm be d1 and d2 dimensional complex matrices, respectively. Then     "m ! m # m m X X X † X Dj Dj†  Ci Ci† · tr  Cj ⊗ Dj†  ≤ tr Ci ⊗ Di  tr  i=1 i=1 j=1 j=1 Proof. We start with the inequality: i h  0 ≤ tr (Ci ⊗ Dj − Cj ⊗ Di ) Ci† ⊗ Dj† − Cj† ⊗ Di† i i h h = tr Ci Ci† ⊗ Dj Dj† + Cj Cj† ⊗ Di Di† − tr Ci Cj† ⊗ Dj Di† + Cj Ci† ⊗ Di Dj† i i h i h i h i h i h h = tr Ci Ci† · tr Dj Dj† + tr Cj Cj† · tr Di Di† − tr Ci Cj† ⊗ Di Dj† − tr Cj Ci† ⊗ Dj Di† 26   The inequality is just tr Y Y † ≥ 0. The second equality follows from linearity of trace, tr [Y ⊗ Z] = tr[Y ] · tr[Z] and tr[XY † ] = tr[Y X † ]. Rearranging the above, we get the following inequality: i i h i h i h i h i h h (1) tr Ci Cj† ⊗ Di Dj† + tr Cj Ci† ⊗ Dj Di† ≤ tr Ci Ci† · tr Dj Dj† + tr Cj Cj† · tr Di Di† Summing Equation (1) over pairs (i, j) with i < j, we obtain the following: i i h i X h X h tr Ci Ci† · tr Dj Dj† tr Ci Cj† ⊗ Di Dj† ≤ i6=j i6=j Adding P i tr h i h i Ci Ci† · tr Di Di† to both sides completes the proof (due to linearity of trace). Now we are ready to prove our main theorem for integral operators. Theorem 2.18 (Capacity of Square Operators). Suppose TA is a completely positive operator which is rank non-decreasing and has Kraus operators A1 , . . . , Am ∈ Mn (Z). In this case: cap(TA ) ≥ exp(−2n log(n)) Proof. Since TA is rank non-decreasing, by Corollary 2.16, there exist non-negative integer matrices D1 , . . . , Dm of dimension d s.t. Det(D1 ⊗ A1 + · · · + Dm ⊗ Am ) 6= 0 and also d m X X j=1 k,l=1 Dj (k, l)2 ≤ n2 d (2) Since A1 , . . . , Am are also integer matrices, Det(D1 ⊗ A1 + · · · + Dm ⊗ Am ) is a non-zero integer and hence |Det(D1 ⊗ A1 + · · · + Dm ⊗ Am )| ≥ 1 (3) Let X ≻ 0 be such that Det(X) = 1. Consider the matrices Ci = TA (X)−1/2 Ai X 1/2 . This is a scaling intended so that the operator TC defined by the matrices Ci preserves identity i.e. satisfies ! m m X X † 1/2 1/2 † −1/2 Ai X X Ai TA (X)−1/2 Ci Ci = TA (X) TC (I) = i=1 i=1 = In Hence tr "m X Ci Ci† i=1 # =n (4) Let Y denote the matrix D1 ⊗ C1 + · · · + Dm ⊗ Cm . Then |Det(Y )| = |Det(D1 ⊗ C1 + · · · + Dm ⊗ Cm )| (5) = |Det(D1 ⊗ A1 + · · · + Dm ⊗ Am )| · Det(X)d/2 · Det (TA (X))−d/2 ≥ Det (TA (X))−d/2 (6) 27 The equality follows from multiplicativity of determinant and the fact that Det (Id ⊗ Y ) = Det(Y )d . The inequality follows from Det(X) = 1 and Equation (3). Hence we obtain   (7) Det Y Y † = |Det(Y )|2 ≥ Det (TA (X))−d On the other hand, by the AM-GM inequality   !nd tr Y Y † nd   Det Y Y † ≤ (8) Now consider h  i tr Y Y † = tr  ≤ tr " m X i=1 m X  ! m X † Dj ⊗ Cj†  Di ⊗ Ci  j=1 Di Di† i=1 #   m X Cj C †  · tr  j j=1   d m X X Di (k, l)2  · n = i=1 k,l=1 3 ≤n d (9) First inequality follows from Lemma 2.17. The second equality follows from Equation (4). The second inequality follows from Equation (2). Combining equations (7), (8) and (9), we obtain: Det (TA (X)) ≥ 1 n2n Since X was an arbitrary matrix s.t. X ≻ 0 and Det(X) = 1, we obtain the desired lower bound on cap(TA ). Remark 2.19. A slightly stronger bound can be obtained by using quantum permanents [Gur04] in the case when the Di ’s are of constant dimension. Theorem 2.18 immediately implies the following capacity lower bound that we need. Theorem 2.20. Suppose T is a cptp map which is rank non-decreasing and is obtained by right normalization of an operator with Kraus operators A1 , . . . , Am , which are n × n integer matrices such that each entry of Ai has absolute value at most M . Then cap(T ) ≥ exp(−4n log(M mn)). Proof. Let TA be the operator defined by A1 , . . . , Am . Since T is the right normalization of TA , by Proposition 2.7, we get that cap(T ) = cap(TA ) Det (T ∗ (I)) 28 (10) Note that T ∗ (I) is a psd matrix. Also tr [T ∗ (I)] = = m X i=1 m X i h tr A†i Ai n X i=1 k,l=1 2 2 |Ai (k, l)|2 ≤ M mn This implies (via the AM-GM inequality) that ∗ Det (T (I)) ≤  tr [T ∗ (I)] n ≤ (M 2 mn)n n (11) Combining Equations (10) and (11) gives the desired bound. 3 Properties of Capacity In this section, we prove some interesting properties of capacity. In subsection 3.1, we prove that the capacity of operators which are close to doubly stochastic is close to 1. This is used in the proof of Theorem 3.10. In subsection 3.2, we characterize the almost optimal points of capacity in terms of approximate fixed points of an operator. This will be used later in section 4 in the proof of continuity of capacity (theorem 4.5). In 3.3, we prove a multiplicativity property of capacity under tensor products of operators. This property was used in the lower bound on capacity in the previous version of this paper. While it is no longer needed for this purpose now, it is an interesting and intriguing fact by itself, so we include a proof. 3.1 Capacity of almost doubly stochastic operators The following definition of capacity for non-negative matrices is due to [GY98]. They used it to analyze Sinkhorn’s algorithm for matrix scaling. Definition 3.1 (Capacity of non-negative matrices). Given a non-negative matrix A, its capacity is defined as follows: ) ( n n Y Y xi = 1, x > 0 (Ax)i : cap(A) = inf i=1 i=1 The next lemma states that the capacity of almost doubly stochastic matrices is close to 1. Lemma 3.2. Let A be a non-negative n × n matrix s.t. the row sums of A are 1 and n X (ci − 1)2 ≤ ǫ i=1 where c1 , . . . , cn are the column sums of A. Then cap(A) ≥ (1 − 29 √ nǫ)n Proof. We start by proving that for doubly stochastic matrices B, cap(B) ≥ 1. This will follow Qn n from concavity of log. Indeed, let x ∈ R s.t. i=1 xi = 1 and x > 0. Then   n n n X X X Bi,j xj  log  log ((Bx)i ) = j=1 i=1 i=1 ≥ = = n n X X Bi,j log(xj ) i=1 j=1 n X log(xj ) j=1 n X n X Bi,j i=1 log(xj ) j=1 =0 For the inequality, we used concavity of log and the fact that row sums of B are 1. For the third equality, we used that the column sums of B are 1. Now we need to move on to A which is almost doubly stochastic. A direct argument like for the doubly stochastic case does not work. We need to first prove the following claim ([LSW98]): Claim 3.3. There exists a decomposition of A = λB + Z, where B is doubly stochastic, Z is √ non-negative and λ ≥ 1 − nǫ. Given the claim, it is easy to complete the proof of the lemma. √ cap(A) ≥ λn cap(B) ≥ (1 − nǫ)n So we end with a proof of the claim from [LSW98]. We will first prove that there is a decomposition A = D + Z where D is multiple of a doubly stochastic matrix and per(Z) = 0. Initially, we start with D = 0 and Z = A. As long as per(Z) > 0, there is an α > 0 and a permutation matrix P s.t. Z ′ = Z − αP is nonnegative and the number of non-zero entries in Z ′ is strictly less than that of Z. Replace D by D ′ = D + αP and Z by Z ′ . Note that D ′ is also a multiple of a doubly stochastic matrix. After at most n2 iterations, we will find a decomposition A = λB + Z, where per(Z) = 0 √ (and B is doubly stochastic). We will now prove that λ ≥ 1 − nǫ. If λ = 1, then we are already Z . Row sums of C are 1 and the done, so assume λ < 1. In this case, consider the matrix C = 1−λ c −λ th ′ i i column sum ci = 1−λ . Then n X (c′i − 1)2 = i=1 n X 1 ǫ (ci − 1)2 ≤ 2 (1 − λ) (1 − λ)2 i=1 Since per(C) = 0 and row sums are 1, it follows that (see Lemma 5.2 in [LSW98]) n X (c′i − 1)2 ≥ 1/n i=1 and hence which implies λ ≥ 1 − √ nǫ ǫ ≥ 1/n (1 − λ)2 30 The next lemma says that capacity of almost doubly stochastic operators is close to 1. The proof will by reducing the operator case to the non-negative matrix case established above. Lemma 3.4. Let T be a positive operator acting on n × n matrices such that tr[(T (I) − I)2 ] ≤ ǫ √ and T ∗ (I) = I (equivalently T is trace-preserving). Then cap(T ) ≥ (1 − nǫ)n . Proof. Let X be a positive definite matrix s.t. Det(X) = 1. Let X= n X λi vi vi† i=1 be an eigenvalue decomposition of X with v1 , . . . , vn forming a unitary basis. Then T (X) = n X λi T (vi vi† ) i=1 Let us denote T (vi vi† ) by Ri . Then since T is trace preserving, we have that tr(Ri ) = 1 for all i. Also let n X σi ui u†i T (X) = i=1 be an eigenvalue decomposition for T (X) with u1 , . . . , un forming a unitary basis. It follows that for all i, n X λj u†j Ri uj σi = j=1 Let A denote the non-negative matrix s.t. Ai,j = u†j Ri uj . Then σ = Aλ. Also the row sums of A are all 1 since tr(Ri ) = 1 for all i. We will also prove that n X (cj − 1)2 ≤ ǫ j=1 where c1 , . . . , cn denote the Then the lemma follows from Lemma 3.2 and the Q column sums of A. Q facts that Det(T (X)) = ni=1 σi and Det(X) = ni=1 λi . Now note that ! ! n n n n X X X X † † † † † vi vi uj = u†j T (I)uj u j Ri u j = u j T (vi vi ) uj = uj T Ai,j = cj = i=1 i=1 i=1 i=1 Hence n  n  n 2 2 X X X u†j (T (I) − I)uj u†j T (I)uj − 1 = (cj − 1)2 = j=1 j=1 j=1 ≤ n X j=1 u†j (T (I) − I)2 uj = tr[(T (I) − I)2 ] ≤ ǫ The first inequality can be proved via convexity of square. 31 We also prove an easy lemma for the other direction: operators with capacity almost 1 are almost doubly stochastic. Lemma 3.5. Let T be a positive operator acting on n × n matrices s.t. cap(T ) ≥ exp(−δ), δ ≤ 1/6 and also T ∗ (I) = I. Then ds(T ) = tr[(T (I) − I)2 ] ≤ 6δ. Proof. cap(T ) ≥ exp(−δ) implies that Det(T (I)) ≥ exp(−δ). Also tr[T (I)] = tr [T ∗ (I)] = n. Suppose tr[(T (I) − I)2 ] = α. Then Lemma 5.1 below implies that Det(T (I)) ≤ exp(−α/6) This implies that α ≤ 6δ. Remark 3.6. Note that the paramters in Lemmas 3.4 and 3.5 don’t match and that is because capacity and the distance to doubly stochasticity don’t characterize each other exactly. 3.2 Characterization of approximate optimizers for capacity The following definition will be useful. Definition 3.7. Let T be a completely positive operator. Define Fixed(T, ǫ) to be the set of hermitian positive-definite matrices which are ǫ-approximate fixed point of the operator X → T (T ∗ (X)−1 )−1 i.e. C ∈ Fixed(T, ǫ) if the following holds: " 2 #  ∗ −1 ≤ǫ tr C · T T (C) −I The following lemma essentially says that the elements of Fixed(T, ǫ) are approximate minimizers for cap(T ). Lemma 3.8. Suppose C ∈ Fixed(T, ǫ). If ǫ ≤ 1/(n + 1), then T is rank non-decreasing. Furthermore, √ Det(T (C)) Det(T (C)) ≤ cap(T ) ≤ (1 − nǫ)n · Det(C) Det(C) Here n is the size of matrices on which T acts. Similar statement also holds for the operator X → T ∗ (T (X)−1 )−1 . We will use a C ∈ Fixed(T, ǫ) to find a scaling of T which is almost doubly stochastic and then apply Theorem 2.10 (saying that almost doubly stochastic operators are rank non-decreasing) and Lemma 3.4 (giving a lower bound on capacity of almost doubly stochastic operators). Proof. Consider the operator Then Z(I) = I and also h tr (Z ∗ (I) − I)2 i   Z(X) = T (C)−1/2 · T C 1/2 · X · C 1/2 · T (C)−1/2 " 2 #   2    ≤ǫ = tr C · T ∗ T (C)−1 − I = tr C 1/2 · T ∗ T (C)−1/2 · C 1/2 − I 32 When ǫ ≤ 1/(n+1), by Theorem 2.10, Z is rank non-decreasing and hence T is rank non-decreasing. Also by Lemma 3.4, √ cap(Z) = cap(Z ∗ ) ≥ (1 − nǫ)n Then by Proposition 2.7 cap(T ) = cap(Z) · √ Det(T (C)) Det(T (C)) ≥ (1 − nǫ)n · Det(C) Det(C) The upper bund on cap(T ) is clear from the definition of capacity. Next we prove the other direction but again, not with matching parameters. Lemma 3.9. Suppose C ≻ 0 is s.t. cap(T ) ≥ exp(−δ) · Det(T (C)) Det(C) where δ ≤ 1/6. Then C ∈ Fixed(T, 6δ). Proof. As in the proof of Lemma 3.8, define the operator   Z(X) = T (C)−1/2 · T C 1/2 · X · C 1/2 · T (C)−1/2 Then Z(I) = I and by Proposition 2.7 cap(Z ∗ ) = cap(Z) ≥ 1 − δ Now by Lemma 3.5 (applied to Z ∗ ), ds(Z) = ds(Z ∗ ) = tr[(Z ∗ (I) − I)2 ] ≤ 6δ This implies that C ∈ Fixed(T, 6δ) because of the way operator Z is set up. 3.3 Multiplicativity of capacity In this subsection, we prove a curious multiplicativity property of capacity of completely positive operators. This is not required for the lower bound on capacity presented in this version but the easy direction of this theorem was required in the lower bound on capacity in the previous version. Theorem 3.10. Let T1 and T2 be completely positive operators where T1 acts on matrices of dimension d1 and T2 acts on matrices of dimension d2 . Then cap(T1 ⊗ T2 )1/d1 d2 = cap(T1 )1/d1 · cap(T2 )1/d2 We first prove the easy ≤ direction of the above theorem. If X and Y are the minimizers for cap(T1 ) and cap(T2 ), then looking at how much T1 ⊗ T2 shrinks the determinant of X ⊗ Y will give us the required statement. The infimum for cap(T1 ) and cap(T2 ) might not be achieved but that is fine. Lemma 3.11. Let T1 and T2 be completely positive operators where T1 acts on matrices of dimension d1 and T2 acts on matrices of dimension d2 . Then cap(T1 ⊗ T2 )1/d1 d2 ≤ cap(T1 )1/d1 · cap(T2 )1/d2 33 Proof. Suppose X, Y be d1 and d2 dimensional matrices respectively s.t. Det(X), Det(Y ) = 1. Then X ⊗ Y ≻ 0 and Det(X ⊗ Y ) = 1 as well. Also X, Y ≻ 0 and Det ((T1 ⊗ T2 )(X ⊗ Y )) = Det (T1 (X) ⊗ T2 (Y )) = Det(T1 (X))d2 · Det(T2 (Y ))d1 This proves that cap(T1 )d2 · cap(T2 )d1 ≥ cap(T1 ⊗ T2 ) (by taking X and Y to be sequences of matrices which approach cap(T1 ) and cap(T2 ) respectively). Taking 1/d1 d2 powers on both sides completes the proof of the easy direction. We are now ready to prove Theorem 3.10. The main ingredient is the duality between capacity being 0 and the existence of a scaling to almost doubly stochastic position. Proof. (Of Theorem 3.10) The easier ≤ direction was proved above in Lemma 3.11. Now we prove the harder ≥ direction. We can assume wlog that cap(T1 ) > 0 and cap(T2 ) > 0 (otherwise ≥ direction is trivial). Now by the analysis of Algorithm G (Theorem 2.14), we know that for any arbitrary ǫ > 0, there exist invertible matrices B, C ∈ Md1 (C) and D, E ∈ Md2 (C) s.t. the scaled operators S1 and S2 , defined below, are almost doubly stochastic. S1 (X) = B · T1 (C · X · C † ) · B † S2 (Y ) = D · T2 (E · Y · E † ) · D †     More formally, S1∗ (I) = I, S2∗ (I) = I and tr (S1 (I) − I)2 ≤ ǫ, tr (S2 (I) − I)2 ≤ ǫ. Now consider the operator S = S1 ⊗ S2 . Note that S(I) = S1 (I) ⊗ S2 (I) and S ∗ (I) = S1∗ (I) ⊗ S2∗ (I). Hence  ∗ 2 ′ S (I) = I and tr (S(I) − I) ≤ ǫ = 2(d1 + d2 + ǫ)ǫ. This can be seen from the following chain of inequalities (and equalities):     tr (S(I) − I)2 = tr (S1 (I) ⊗ S2 (I) − I)2   = tr (S1 (I) ⊗ S2 (I) − S1 (I) ⊗ I + S1 (I) ⊗ I − I)2 i i h h ≤ 2tr (S1 (I) ⊗ (S2 (I) − I))2 + 2tr ((S1 (I) − I) ⊗ I)2 ≤ 2(d1 + ǫ)ǫ + 2ǫd2 = 2(d1 + d2 + ǫ) · ǫ First inequality follows from the following Cauchy-Schwarz inequality for psd matrices:   tr (M1 + M2 )2 ≤ 2tr[M12 ] + 2tr[M22 ] Second inequality follows from tr[S1 (I)2 ] ≤ d1 +  ǫ, which follows from the fact  that tr[S1 (I)] = 2 2 ∗ tr[S1 (I)] = tr [Id1 ] = d1 and that tr (S1 (I) − I) ≤ ǫ, as well as tr (S2 (I) − I) ≤ ǫ. Note that the operator S is explicitly given as follows:          B † ⊗ D† C ⊗ E Z C † ⊗ E† S(Z) = B ⊗ D T1 ⊗ T2 Hence by Proposition 2.7, cap(S) = |Det(B ⊗ D)|2 · |Det(C ⊗ E)|2 · cap(T1 ⊗ T2 ) = |Det(B)|2d2 · |Det(D)|2d1 · |Det(C)|2d2 · |Det(E)|2d1 · cap(T1 ⊗ T2 ) 34 By Lemma 3.4, we have that cap(S) ≥ (1 − √ d1 d2 ǫ′ )d1 d2 and hence cap(T1 ⊗ T2 ) ≥ |Det(B)|−2d2 · |Det(D)|−2d1 · |Det(C)|−2d2 · |Det(E)|−2d1 · (1 − p d1 d2 ǫ′ )d1 d2 (12) Combining the fact that S1∗ (I) = I and S2∗ (I) = I along with Proposition 2.8, we get that cap(S1 ), cap(S2 ) ≤ 1. Also by Proposition 2.7,we have that cap(T1 ) = |Det(B)|−2 · |Det(C)|−2 · cap(S1 ) ≤ |Det(B)|−2 · |Det(C)|−2 cap(T2 ) = |Det(D)|−2 · |Det(E)|−2 · cap(S2 ) ≤ |Det(D)|−2 · |Det(E)|−2 (13) (14) Combining equations (12), (13) and (14), we get that cap(T1 ⊗ T2 )1/d1 d2 ≥ cap(T1 )1/d1 · cap(T2 )1/d2 · (1 − p d1 d2 ǫ′ ) Since ǫ′ = 2(d1 + d2 + ǫ)ǫ can be taken to be arbitrarily close to 0, this completes the proof. 4 Bit Complexity Analysis of Algorithm G and Continuity of Capacity In this section, we will provide the bit complexity analysis of Algorithm G and also provide explicit bounds on the continuity of capacity by a sensitivity analysis of Algorithm G. We start by analyzing a natural iterative sequence associated with an operator T that will be very useful, both, in the bit complexity and continuity analysis. Section 4.1 will describe how the operators Tj in Algorithm G evolve with respect this iterative sequence. Section 4.2 provides the bit complexity analysis of Algorithm G and Section 4.3 provides explicit bounds for continuity of capacity. Consider the sequence of matrices given by S0 = T ∗ (I), and ( −1 T (Sj−1 ) j odd, j ≥ 1 (15) Sj = −1 ∗ T (Sj−1 ) j even, j ≥ 1. The next proposition studies the stability properties of this sequence of matrices. Proposition 4.1. For a real symmetric positive definite matrix X, let l(X) denote its smallest eigenvalue and u(X) its largest. Define α = (M 2 n2 m)n−1 . 1. Suppose A is an n × n real symmetric positive definite matrix with integer entries s.t. the magnitude of any entry of A is at most M . Then l(A) ≥ (M n)1 n−1 and u(A) ≤ M n. 2. Let T be a completely positive operator whose Kraus operators A1 , . . . , Am are n × n integer matrices and each entry of Ai is of magnitude at most M . Also T (I), T ∗ (I) are both nonsingular. Then 1 (M 2 n2 m)I  T (I), T ∗ (I)  I 2 2 (M n m)n−1 3. Let T be as before. Let X be a real symmetric matrix. Then ||T (X)|| ≤ α||X||. Also if X is real symmetric positive definite, then l(T (X)) ≥ α−1 ·l(X) and u(T (X)) ≤ α·u(X). Similarly ||T ∗ (X)|| ≤ α||X||, l(T ∗ (X)) ≥ α−1 · l(X) and u(T ∗ (X)) ≤ α · u(X) 35 4. Sj are real symmetric positive definite matrices for all 0 ≤ j ≤ t. Also l(Sj ) ≥ α−(j+1) and u(Sj ) ≤ αj+1 for all 0 ≤ j ≤ t. 5. For all 1 ≤ k, l ≤ n, |Sj (k, l)| ≤ αj+1 . Proof. 1. Let us first prove that u(A) ≤ M n. u(A) = = ≤ = max v st. ||v||2 = 1 max v st. ||v||2 = 1 max v st. ||v||2 = 1 max v st. ||v||2 = 1 ||Av||2 v !2 u n n uX X t Ak,l vl k=1 l=1 k=1 l=1 v !2 u n n uX X t M |vl | √ n·M · ≤ nM n X l=1 ! |vl | The last inequality follows from Cauchy-Schwarz. Now since A is positive definite and the determinant is an integer, Det(A) ≥ 1. Then 1 ≤ Det(A) ≤ u(A)n−1 l(A) ≤ (M n)n−1 l(A) from which it follows that l(A) ≥ 1 . (M n)n−1 2. Follows from previous point by noting that each entry of T (I), T ∗ (I) is an integer of magnitude at most M 2 n2 m and T (I), T ∗ (I) are both symmetric matrices. 3. We know that αI  T (I), T ∗ (I)  α−1 I Suppose ||X|| = β. Then βI  X  −βI Then T (X + βI)  0 since T is completely positive and hence it maps psd matrices to psd matrices. Thus we get T (X) + βT (I) = T (X + βI)  0 This follows from linearity of T . Then T (X)  −βT (I)  −βαI Similarly one can prove that βαI  T (X) which would imply ||T (X)|| ≤ αβ = α||X||. Other statements can be proven in a similar manner. 36 4. We will prove this via induction on j. It is true for S0 by point 2 in the proposition. Suppose −1 −1 the statement holds for Sj−1 . Then Sj = T (Sj−1 ) or Sj = T ∗ (Sj−1 ). It does not really matter which case it is for the purpose of this proof. Lets assume the former. Then −1 )) l(Sj ) = l(T (Sj−1 −1 ≥ α−1 · l(Sj−1 ) = α−1 · u(Sj−1 )−1 ≥ α−1 · α−j = α−(j+1) The first inequality is by point 3 in the proposition. Second inequality is by induction hypothesis. Similarly we can also prove that u(Sj ) ≤ αj+1 , which would complete the induction step. 5. |Sj (k, l)| = |eTk Sj el | ≤ ||ek ||2 ||Sj el ||2 ≤ αj+1 Here ek and el are the standard basis vectors. Define another sequence of matrices defined by U0 = S0 and ( −1 T (Uj−1 ) + ∆j j odd, j ≥ 1 Uj = −1 ∗ T (Uj−1 ) + ∆j j even, j ≥ 1 where ∆j ’s are small perturbations. We now study the closeness of the sequences {Uj } and {Sj }. Lemma 4.2. If ||∆j || ≤ 2j ·α1j+1 for all j ≥ 1, then l(Uj ) ≥ j ≥ 0. Here α = (M 2 n2 m)n−1 . 1 2j ·αj+1 and u(Uj ) ≤ 2j · αj+1 , for all Proof. We will prove this using induction on j. It is true for j = 0 since U0 = S0 . Assume that l(Uj ) ≥ 2j ·α1j+1 and u(Uj ) ≤ 2j · αj+1 . Then Uj+1 = T (Uj−1 ) + ∆j+1 or Uj+1 = T ∗ (Uj−1 ) + ∆j+1 . Suppose it is T (Uj−1 ) + ∆j+1 . The other case is similar. l(Uj+1 ) ≥ l(T (Uj−1 )) − ||∆j+1 || ≥ α−1 · l(Uj−1 ) − ||∆j+1 || = α−1 · u(Uj )−1 − ||∆j+1 || 1 1 = α−1 · j j+1 − j+1 j+2 2 α 2 α 1 = j+1 j+2 2 α 37 Also u(Uj+1 ) ≤ u(T (Uj−1 )) + ||∆j+1 || ≤ α · u(Uj−1 ) + ||∆j+1 || = α · l(Uj )−1 + ||∆j+1 || 1 ≤ α · 2j αj+1 + j+1 j+2 2 α j+1 j+2 ≤2 ·α Note that there is a lot of slack in this part, but it wouldn’t matter for our purposes. Lemma 4.3. The following holds for every integer t: suppose ||∆j || ≤ δ for all 1 ≤ j ≤ t, where δ ≤ (2α)1t+1 . Then ||Sj − Uj || ≤ (2α)(2t+1)·(t+1) δ for all 0 ≤ j ≤ t. Here α = (M 2 n2 m)n−1 . Proof. −1 −1 ||Sj − Uj || = ||T (Sj−1 ) − T (Uj−1 ) − ∆j || −1 −1 )|| + δ − Uj−1 ≤ ||T (Sj−1 −1 −1 ≤ α · ||Sj−1 − Uj−1 || + δ −1 −1 = α · ||Sj−1 (Uj−1 − Sj−1 )Uj−1 || + δ −1 −1 ≤ α · ||Sj−1 || · ||Sj−1 − Uj−1 || · ||Uj−1 || + δ ≤ 2j−1 α2j+1 · ||Sj−1 − Uj−1 || + δ ≤ (2α)2t+1 · ||Sj−1 − Uj−1 || + δ For the fourth inequality we used Proposition 4.1 and Lemma 4.2. Note that value of δ is small enough so that conditions of Lemma 4.2 are satisfied. 4.1 Evolution of the Operator through Scaling In this subsection we compute succinct expressions for the operators Tj which appear in Algorithm G, together with expressions for their capacity and distance to doubly stochastic. These expressions will involve the matrices Sj defined in the previous subsection. These operators Tj are the intermediary operators in the scaling procedure, and the succinct expressions will be important for us when approximating capacity, or proving the stability of the capacity of a quantum operator. Starting from a completely positive operator T which satisfies T (I) = I, lets denote the sequence of operators obtained after right and left normalizations by {Tj } i.e. Tj is the operator obtained after j iterations of right and left normalizations (as in Algorithm G). Note that   ( ∗ (I)−1/2 · X · T ∗ (I)−1/2 j odd, j ≥ 1 Tj−1 Tj−1 j−1 Tj (X) = Tj−1 (I)−1/2 · Tj−1 (X) · Tj−1 (I)−1/2 j even, j ≥ 1 38 For each j, Tj is an operator scaling of T . So   Tj (X) = Cj · T Dj† · X · Dj · Cj† (16) Tj∗ (X) = Dj · T ∗ (Cj† · X · Cj ) · Dj† (17) for some non-singular matrices Cj and Dj . Let us denote Cj† Cj by Pj and Dj† Dj by Qj . It turns out Pj and Qj are the matrices that really matter for the purpose of analyzing Algorithm G and we will see next how these evolve. When j is odd, Tj∗ (I) = I. Note that So the condition Tj∗ (I) = I gives us that Qj = T ∗ (Pj )−1 . Also note that when j is odd, Pj = Pj−1 . When j is even, Tj (I) = I, which implies Pj = T (Qj )−1 and also Qj = Qj−1 holds. This can be summarized as follows: ( (Pj−1 , T ∗ (Pj−1 )−1 ) j odd, j ≥ 1 (Pj , Qj ) = (T (Qj−1 )−1 , Qj−1 ) j even, j ≥ 1 along with T0 = T and P0 , Q0 = I. Thus we can see that ( −1 −1 ) j odd, j ≥ 1 , Sj−1 (Sj−2 (Pj , Qj ) = −1 −1 (Sj−1 , Sj−2 ) j even, j ≥ 1 (18) with the convention S−1 = I. For Algorithm G, what matters is i  h 2  j odd, j ≥ 1 tr (T (I) − I) j    ǫj =  2     ∗ tr Tj (I) − I j even, j ≥ 1 Since and  −1   · Pj · T (Qj ) · Cj† Tj (I) = Cj · T Dj† Dj · Cj† = Cj†  −1 · Qj · T ∗ (Pj ) · Dj† Tj∗ (I) = Dj · T ∗ (Cj† Cj ) · Dj† = Dj† we get (because similar matrices have the same trace) that i  h 2  j odd, j ≥ 1 tr (P · T (Q ) − I) j j   ǫj = and hence i h   tr (Q · T ∗ (P ) − I)2 j j j even, j ≥ 1    2  2  −1 −1 −1   = tr Sj−2 · Sj − I  tr Sj−2 · T (Sj−1 ) − I   ǫj = 2  2    −1 −1 −1 ∗  tr Sj−2 · T (Sj−1 ) − I = tr Sj−2 · Sj − I 39 j odd, j ≥ 1 (19a) j even, j ≥ 1 (19b) For the computation of capacity, the determinants that matter are ( ∗ (I))−1 j odd, j ≥ 1 Det(Tj−1 dj = Det(Tj−1 (I))−1 j even, j ≥ 1 Then by Proposition 2.7, we have that cap(Tr ) = cap(T0 ) · r Y j=1 dj = cap(T ) · r Y dj j=1 By the discussion above and the fact that similar matrices have the same determinants, we get that    −1 −1 ∗  = Det(Sj−3 ) · Det(Sj−1 )−1 j odd, j ≥ 1 Det Q  j−1 · Det (T (Pj−1 ))  dj =     Det P −1 · Det (T (Q j−1 j−1 )) −1 = Det(Sj−3 ) · Det(Sj−1 )−1 j even, j ≥ 1 with the convention S−2 , S−1 = I. Thus we get cap(Tr ) = cap(T ) · = cap(T ) · r Y j=1 r Y j=1 dj Det(Sj−3 ) · Det(Sj−1 )−1 = cap(T ) · Det(S−2 ) · Det(S−1 ) · Det(Sr−2 )−1 · Det(Sr−1 )−1 = cap(T ) · Det(Sr−2 )−1 · Det(Sr−1 )−1 4.2 (20) Bit Complexity Analysis of Algorithm G We are now ready to analyze the bit complexity of Algorithm G. We will prove that if one runs Algorithm G while truncating the numbers to an appropriate polynomial number of bits there is essentially no change in the convergence and required number of iterations. We will call the algorithm working with truncated inputs Algorithm G′ . Given a matrix A, let Trn(A) be the matrix obtained by truncating the entries of A up to P (n, log(M )) bits after the decimal point. P (n, log(M )) is a polynomial which we will specify later. Note that ||A − Trn(A)||∞ ≤ 2−P (n,log(M )) . We now describe Algorithm G′ , which is the variant of Algorithm G with truncation. The parameter t will be chosen as before: t = 2 + 36n · log(1/f (n, M )). We now show that throughout the iterations, distances to double stochasticity is essentially the same for the original and truncated algorithms G and G′ . Lemma 4.4. For an appropriate choice of P (n, log(M )), |ǫj − ǫ̃j | ≤ 1/12n, for 1 ≤ j ≤ t = 2 + 36n · log(1/f (n, M )). Here ǫj = ds(Tj ) as defined in Algorithm G. Also note that by equations (19a) and (19b),  2  −1 ǫj = tr Sj−2 · Sj − I 40 Input: Completely positive operator T given in terms of Kraus operators A1 , . . . , Am ∈ Zn×n . Each entry of Ai has absolute value at most M . Output: Is T rank non-decreasing? 1. Check if T (I) and T ∗ (I) are singular. If any one of them is singular, then output that the operator is rank decreasing, otherwise proceed to step 2. 2. Let U−1 = S−1 = I and U0 = S0 = T ∗ (I). For(j = 1 to t): ( −1 Trn(T (Uj−1 )), if j odd and Uj = −1 ∗ Trn(T (Uj−1 )), if j even.   2 −1 · Uj − I Let ǫ̃j = tr Uj−2 . 3. Check if min{ǫ̃j : 1 ≤ j ≤ t} ≤ 1/6n. If yes, then output that the operator is rank nondecreasing otherwise output rank decreasing. Algorithm 2: Algorithm G′ (Algorithm G with truncation) Let us first prove the correctness of Algorithm G′ assuming Lemma 4.4. As before, we can assume that T (I) and T ∗ (I) are both non-singular. If min{ǫ̃j : 1 ≤ j ≤ t} ≤ 1/6n, then by Lemma 4.4, min{ǫj : 1 ≤ j ≤ t} ≤ 1/6n + 1/12n ≤ 1/3n Hence by Theorem 2.10, T is rank non-decreasing. Now assume, for the reverse direction, that T is rank non-decreasing. Then by the analysis in Section 2.2, min{ǫj : 1 ≤ j ≤ t} ≤ 1/12n. Hence by Lemma 4.4 min{ǫ̃j : 1 ≤ j ≤ t} ≤ 1/12n + 1/12n = 1/6n This proves the correctness of Algorithm G′ .   2  2  −1 −1 Proof. (Of Lemma 4.4) ǫj = tr Sj−2 · Sj − I and ǫ̃j = tr Uj−2 · Uj − I . Let Mj = −1 −1 Sj−2 · Sj and Nj = Uj−2 · Uj . Then −1 −1 −1 ||Mj ||∞ = ||Sj−2 · Sj ||∞ ≤ ||Sj−2 · Sj || ≤ ||Sj−2 || · ||Sj || ≤ α2j where the last inequality follows from Proposition 4.1. Also −1 −1 −1 ||Nj ||∞ = ||Uj−2 · Uj ||∞ ≤ ||Uj−2 · Uj || ≤ ||Uj−2 || · ||Uj || ≤ 22j−2 · α2j where the last inequality follows from Lemma 4.2 and the fact that P (n, log(M )) will be chosen to be a large enough polynomial so that the perturbations ∆j in the lemma satisfy the condition 41 ||∆j || ≤ 2−P (n,log(M )) ≤ 1 . 2j ·αj+1 Now |ǫj − ǫ˜j | ≤ |tr(Mj2 − Nj2 )| + 2|tr(Mj − Nj )| = |tr[(Mj + Nj )(Mj − Nj )]| + 2|tr(Mj − Nj )| n X 2j |(Mj − Nj )(k, l)| + 2n||Mj − Nj || ≤ (2α) · k,l=1 ≤ (2α)2j 2j ≤ (2α) v uX u n |(Mj − Nj )(k, l)|2 + 2n||Mj − Nj || ·n·t ·n· √ k,l=1 n · ||Mj − Nj || + 2n||Mj − Nj || In the first equality, we used the fact that tr(Mj Nj ) = tr(Nj Mj ). In the second inequality, we used the fact that the maximum magnitude of any entry in Mj + Nj is bounded by (2α)2j and that |tr(Mj − Nj )| is upper bounded by n||Mj − Nj ||. The third inequality is just Cauchy-Schwarz and the fourth is the fact that Frobenius norm of a matrix is upper bounded by n||Mj − Nj ||2 . Let us try to upper bound ||Mj − Nj || now. −1 −1 ||Mj − Nj || = ||Sj−2 · Sj − Uj−2 · Uj || −1 −1 −1 −1 = ||Sj−2 · Sj − Sj−2 · Uj + Sj−2 · Uj + Uj−2 · Uj || −1 −1 −1 −1 ≤ ||Sj−2 · Sj − Sj−2 · Uj || + ||Sj−2 · Uj + Uj−2 · Uj || −1 −1 −1 ≤ ||Sj−2 || · ||Sj − Uj || + ||Sj−2 − Uj−2 || · ||Uj || −1 −1 −1 = ||Sj−2 || · ||Sj − Uj || + ||Sj−2 (Uj−2 − Sj−2 ) Uj−2 || · ||Uj || −1 −1 −1 || · ||Uj || || · ||Uj−2 − Sj−2 || · |Uj−2 || · ||Sj − Uj || + ||Sj−2 ≤ ||Sj−2 ≤ αj−1 · (2α)(2t+1)·(t+1) δ + αj−1 · (2α)(2t+1)·(t+1) δ · 2j−2 αj−1 · 2j αj+1 2 ≤ (2α)10t · δ The second last inequality follows by application of Proposition 4.1 and Lemmas 4.2 and 4.3. Also δ here is at most n · 2−P (n,log(M )) since ||∆j ||∞ ≤ 2−P (n,log(M )) . Now α = (M 2 n2 m)n−1 = exp(Θ(n log(n) log(M ))) (since m ≤ n2 ). Hence 2 (2α)10t = exp(Θ(n log(n) log(M ) · t2 )) = exp Θ n3 log(n) log(M ) log2 (1/f (n, M )) Hence choosing  P (n, log(M )) = n4 log(M ) log2 (1/f (n, M )) suffices to get |ǫj − ǫ˜j | ≤ 1/12n We proved in Theorem 2.20 that log(1/f (n, M )) is poly(n, log(M )), so P (n, log(M )) is also a polynomial in n and log(M ). 42 4.3 Continuity of Capacity In this section, we prove the continuity of capacity. We prove the following theorem: Theorem 4.5. Suppose A1 , . . . , Am and B1 , . . . , Bm are two tuples of n × n matrices such that the bit-complexity of elements of Ai ’s is b and ||Ai − Bi || ≤ δ for all i. Let TA be the operator defined by A1 , . . . , Am and TB be the operator defined by B1 , . . . , Bm . Then there exists a polynomial P (n, b, log(m)) s.t. if δ ≤ exp(−P (n, b, log(m))), then cap(TA ) > 0 implies cap(TB ) > 0. Furthermore,     cap(TA ) P (n, b, log(m)) P (n, b, log(m)) ≤ ≤ 1+ 1− cap(TB ) log(1/δ)1/3 log(1/δ)1/3 The fact that capacity is continuous is already mentioned in [Gur04] and can be proved by other methods. But here we provide explicit bounds on the continuity parameters. Recall that Fixed(T, ǫ) (defined in subsection 3.2) is the set of hermitian positive-definite matrices C which are ǫ-approximate fixed point of the operator X → T (T ∗ (X)−1 )−1 i.e. satisfy the following condition: " 2 #  tr C · T ∗ T (C)−1 − I ≤ǫ The main insight is that by the analysis of Algorithm G, since cap(TA ) > 0, there exists a C ∈ Fixed(TA , ǫ) with low spectral norm. Since TB is close to TA , C ∈ Fixed(TB , ǫ′ ) for ǫ′ close to ǫ and then the proof is finished by applying Lemma 3.8. Proof. (Of Theorem 4.5) The proof of Theorem 2.14 can be modified to prove the following: there exists a polynomial Q(n, b) s.t. for all ǫ > 0, if we run t = Q(n, b)/ǫ iterations of Algorithm G starting from T0 = TA satisfying cap(TA ) > 0, then for some 1 ≤ j ≤ t, ǫj = ds(Tj ) ≤ ǫ. Essentially, at each step capacity increases by roughly exp(Ω(ǫ)) if ǫj > ǫ, capacity is lower bounded by exp(−Q(n, b)) initially and upper bounded by 1 always. By equations (19a) and (19b), we know that  2  −1 ǫj = tr Sj−2 Sj − I where {Si } is the sequence of matrices given by S0 = TA∗ (I), and ( −1 TA (Si−1 ) i odd, i ≥ 1 Si = −1 ∗ TA (Si−1 ) i even, i ≥ 1    −1 −1 Suppose 1 ≤ r ≤ t be such that ǫr ≤ ǫ. Wlog assume that r is odd. Then Sr = TA TA∗ Sr−2 . −1 −1 ∗ −1 . ǫr ≤ ǫ implies that Sr−2 is an ǫ-approximate fixed point of the operator X → TA TA (X) Hence by Lemma 3.8,   −1 −1 √ n Det TA Sr−2 Det TA Sr−2   (1 − nǫ) · ≤ cap(TA ) ≤ (21) −1 −1 Det Sr−2 Det Sr−2 43 −1 −1 We will prove now that Sr−2 is also an ǫ′ -approximate fixed point of the operator X → TB TB∗ (X)−1 −1 for an appropriate choice of ǫ′ . Let us denote Sr−2 by C. By an application of Proposition 4.1, it follows that the lowest and highest eigenvalues of C, l(C) and u(C) satisfy 1 , u(C) ≤ exp(O(n · b · r · log(nm))) ≤ exp(Q1 (n, b, log(m))/ǫ) l(C) (22) where Q1 (n, b, log(m)) is another polynomial s.t. Q1 (n, b, log(m)) = O(Q(n, b) · n · b · log(nm)). Let D be an arbitrary matrix. Then ||TA (D) − TB (D)|| = || ≤ ≤ ≤ m X i=1 m X i=1 m X i=1 Bi DBi†|| ||Ai DA†i − Bi DBi† || m  X i=1 m  X i=1 Ai DA†i −  ||Ai DA†i − Ai DBi†|| + ||Ai DBi† − Bi DBi† ||  ||Ai || · ||D|| · ||A†i − Bi† || + ||Ai − Bi || · ||D|| · ||Bi† || ≤ 2m · (n · exp(b) + δ) · ||D|| · δ = exp(Q2 (n, b, log(m)) · ||D|| · δ (23) The first two inequalities are just the triangle inequality. Third inequality follows from submultiplicativity of the spectral norm. Fourth inequality follows from the fact that ||Ai || ≤ n · ||Ai ||∞ ≤ n · exp(b) and that ||Bi† || = ||Bi || ≤ ||Ai || + ||Ai − Bi || ≤ ||Ai || + δ Similarly, we have that ||TA∗ (D) − TB∗ (D)|| ≤ exp(Q2 (n, b, log(m)) · ||D|| · δ (24)   We will now upper bound ||TA TA∗ (C)−1 − TB TB∗ (C)−1 ||:   ||TA TA∗ (C)−1 − TB TB∗ (C)−1 ||     ≤ ||TA TA∗ (C)−1 − TB TA∗ (C)−1 || + ||TB TA∗ (C)−1 − TB TB∗ (C)−1 ||     ≤ ||TA TA∗ (C)−1 − TB TA∗ (C)−1 || + ||TA TA∗ (C)−1 − TB∗ (C)−1 − TB TA∗ (C)−1 − TB∗ (C)−1 ||  + ||TA TA∗ (C)−1 − TB∗ (C)−1 || (25) Equation (22) along with Proposition 4.1 implies that the lowest and highest eigenvalues of TA∗ (C) satisfy the following: 1 l  , u (TA∗ (C)) ≤ exp(Q4 (n, b, log(m))/ǫ) TA∗ (C) 44 (26) Now applying equation (23) with D = TA∗ (C)−1 along with equation (26) gives us the following:   (27) ||TA TA∗ (C)−1 − TB TA∗ (C)−1 || ≤ exp(Q5 (n, b, log(m))/ǫ) · δ Now we will upper bound ||TA∗ (C)−1 − TB∗ (C)−1 ||. ||TA∗ (C)−1 − TB∗ (C)−1 || = ||TA∗ (C)−1 TB∗ (C)−1 (TA∗ (C) − TB∗ (C)) || ≤ ||TA∗ (C)−1 || · ||TB∗ (C)−1 || · ||TA∗ (C) − TB∗ (C)|| ≤ exp(Q6 (n, b, log(m))/ǫ) · δ (28) The last inequality follows from equations (26) and (24). Note that we need δ ≤ exp(−P (n, b, log(m))) for a sufficiently large polynomial P here to upper bound ||TB∗ (C)−1 || via equations (26) and (24). Now applying equation (23) with D = TA∗ (C)−1 − TB∗ (C)−1 along with equation (28) gives us that   (29) ||TA TA∗ (C)−1 − TB∗ (C)−1 − TB TA∗ (C)−1 − TB∗ (C)−1 || ≤ exp(Q7 (n, b, log(m))/ǫ) · δ2  We are left to upper bound ||TA TA∗ (C)−1 − TB∗ (C)−1 ||. This follows from Proposition 4.1 and equation (28).  (30) ||TA TA∗ (C)−1 − TB∗ (C)−1 || ≤ exp(Q8 (n, b, log(m))/ǫ) · δ Combining equations (25), (27), (29) and (30), we get the following   ||TA TA∗ (C)−1 − TB TB∗ (C)−1 || ≤ exp(Q9 (n, b, log(m))/ǫ) · δ (31)   Let us denote the matrix D1 = C · TA TA∗ (C)−1 and D2 = C · TB TB∗ (C)−1 . D1 determines whether C is an approximate-fixed point of TA and D2 determines whether C is an approximatefixed point of TB .   ||D1 − D2 || ≤ ||C|| · ||TA TA∗ (C)−1 − TB TB∗ (C)−1 || ≤ exp(Q10 (n, b, log(m))/ǫ) · δ (32) Second inequality follows from equations (22) and (31). We also have the following elementary inequality:     tr (D1 − I)2 − tr (D2 − I)2 ≤ (||D1 || + ||D2 || + 2n) · ||D1 − D2 || (33) The above inequality implies that C is an ǫ′ -approximate fixed point of TB for ǫ′ = ǫ + exp(Q11 (n, b, log(m))/ǫ) · δ We can now choose ǫ = 1 2(n+1) . exp(−Q11 (n,b,log(m))/ǫ) , then C is a 1/(n + 1)2(n+1)  −1 and by Lemma 3.8, TB is rank TB TB∗ (X)−1 Then as long as δ ≤ approximate fixed point of the operator X → non-decreasing and hence cap(TB ) > 0. This proves first part of the theorem. For the second part of the theorem, since C is an ǫ′ -approximate fixed point of TB for ǫ′ = ǫ + exp(Q11 (n, b, log(m))/ǫ) · δ 45 by Lemma 3.8, we have that (1 − √ nǫ′ )n · Det (TB (C)) Det (TB (C)) ≤ cap(TB ) ≤ Det (C) Det (C) (34) Also note that ||TA (C) · TB (C)−1 − I|| = || (TA (C) − TB (C)) · TB (C)−1 || ≤ || (TA (C) − TB (C)) || · ||TB (C)−1 || ≤ exp(Q12 (n, b, log(m))/ǫ) · δ by equation (23) and Proposition 4.1. Hence (1 − exp(Q12 (n, b, log(m))/ǫ) · δ)n ≤ Det(TA (C)) ≤ (1 + exp(Q12 (n, b, log(m))/ǫ) · δ)n Det(TB (C)) (35) Now, combining equations (21) and (21), we get that (1 − √ nǫ)n · Det(TA (C)) cap(TA ) 1 Det(TA (C)) √ · ≤ ≤ ′ n Det(TB (C)) cap(TB ) Det(T (1 − nǫ ) B (C)) Combining this with equation (35) gives us √ cap(TA ) 1 √ ·(1 + exp(Q12 (n, b, log(m))/ǫ) · δ)n (1− nǫ)n ·(1 − exp(Q12 (n, b, log(m))/ǫ) · δ)n ≤ ≤ cap(TB ) (1 − nǫ′ )n Now choose ǫ = 2 · max {Q11 (n, b, log(m)), Q12 (n, b, log(m))} / log(1/δ). This ensures that ǫ′ ≤ 2ǫ and elementary calculations can then finish the proof of the theorem. 5 Computing the Capacity of a Quantum Operator In this section, we show how algorithm G can be used to compute an approximation to the capacity of any quantum operator. For simplicity of exposition, we will present in this section an analysis of convergence of algorithm G without truncation. Afterwards, in subsection 5.1, we show how to adapt the analysis of algorithm G to handle the truncation. This corresponds to the analysis of algorithm G′ in the previous section. We begin with the following lemma, which is an adaptation of Lemma 3.10 from [LSW98]. Lemma 5.1. Let x1 , . . . , xn be positive real numbers such that Then n X i=1 ( n Y exp (−α/6) , if α ≤ 1,  xi ≤ exp −1 6 , otherwise. i=1 Proof. We have two cases to analyze: Case 1: α ≤ 1. 46 xi = n and n X i=1 (xi − 1)2 = α.  t2 t3 , which holds for all t ∈ R, we In this case, by using the inequality 1 + t ≤ exp t − + 2 3 have:   n n n Y Y Y (xi − 1)2 (xi − 1)3 + exp (xi − 1) − [1 + (xi − 1)] ≤ xi = 2 3 i=1 i=1 i=1 ! n n n X X 1 X 1 (xi − 1) − · (xi − 1)2 + · (xi − 1)3 = exp 2 3 i=1  i=1 i=1   1 1 α ≤ exp − · α + · α3/2 ≤ exp − 2 3 6 !3/2 n n X X 2 3 and α3/2 ≤ α. (xi − 1) (xi − 1) ≤ Where in the last inequalities we used the fact that  i=1 i=1 Case 2: α > 1. Q Consider the function f (λ) = ni=1 (1 + λ(xi − 1)). We will prove that f is a decreasing function of λ when λ ∈ [0, 1]. In that case  Y     n  n n Y Y xi − 1 1 1 1+ √ = ≤ exp − [1 + (xi − 1)] = f (1) ≤ f √ xi = α α 6 i=1 i=1 i=1 where the last inequality follows from Case 1. Now let us prove that f is decreasing.     n n X X xi − 1  ≤ f (λ) ·  (xi − 1) = 0 f ′ (λ) = f (λ) ·  1 + λ(xi − 1) j=1 j=1 This completes the proof. As a corollary of Lemma 5.1, we obtain the following quantitative progress measure towards computing capacity: Lemma 5.2 (Quantitative Progress). Let T be a right (left) normalized quantum operator such that ds(T ) = α. Additionally, let Te be the left (right) normalization of operator T . Then, ( cap(T ) · exp (α/6) , if α ≤ 1,  cap(Te) ≥ cap(T ) · exp 61 , otherwise. Proof. Suppose T is right normalized and Te is the left normalization of T . Proposition 2.7 tells us that cap(Te) = det(T (I))−1 · cap(T ). n X λi and α = ds(T ) = tr[(T (I) − Let λ1 , . . . , λn be the eigenvalues of T (I). As n = tr(T (I)) = I)2 ] = n X i=1 i=1 (λi − 1)2 , the conditions of Lemma 5.1 apply and we have det(T (I)) = n Y i=1 λi ≤ ( exp (−α/6) , if α ≤ 1,  exp −1 6 , otherwise. 47 This implies the desired lower bounds on cap(Te). Since the case where T is left normalized is analogous, we omit the argument. We now state a slight modification of Algorithm G, with a view towards computing the capacity of a quantum operator. Input: Quantum operator T given in terms of Kraus operators A1 , . . . , Am ∈ Zn×n and approximation parameter ǫ > 0. Each entry of Ai has absolute value at most M . Output: cap(T ) with multiplicative error of (1 ± ǫ). 1. Check if T (I) and T ∗ (I) are singular. If any one of them is singular, then output cap(T ) = 0, otherwise proceed to step 2. 2. Alternately perform right and left normalizations on T = T0 for t steps. Let Tj be the operator after j steps. Also let ǫj = ds(Tj ). Go to step 3. 3. If ǫj ≤ ǫ2 for any 0 ≤ j ≤ t, go to step 4. Otherwise, output cap(T ) = 0. n3 ǫ2 , output n3 ( j−1 Y Ti (I), if i is odd, det(Ri ), where Ri = cap(T ) = Ti∗ (I), otherwise. i=0 4. For the smallest 0 ≤ j ≤ t such that ǫj ≤ Algorithm 3: Algorithm G, computing capacity Theorem 5.3. Let T be a completely positive operator, whose Kraus operators are given by n × n integer matrices A1 , . . . , Am , such that each entry of Ai has absolute value at most M . Algorithm  n3 G when applied for t = 2 · 1 + 10n2 log(M n) steps approximates cap(T ) within a multiplicative ǫ factor of 1 ± ǫ. Proof. If either T (I) or T ∗ (I) is singular, then T decreases the rank of I. When T (I) is singular, ∗ rank decreasing follows by definition. When T (I) is singular, one way to see it is that Im(Ai ) ⊆  Im (T ∗ (I)) for all i. Since Im Ai A†i = Im(Ai ), we get that Im (T (I)) ⊆ Im (T ∗ (I)) and hence T (I) is singular. Therefore, the algorithm would be correct on step 1, by outputting cap(T ) = 0. If T (I) and T ∗ (I) are both non-singular, it is easy to verify that Tj (I) and Tj∗ (I) will remain non-singular for all j and hence step 3 is well defined. We now divide the proof into two cases: Case 1: T is rank decreasing. In this case, since right and left normalizations don’t change the property of being rank deǫ2 creasing, we have cap(Tj ) = 0 for all 0 ≤ j ≤ t. Hence, Lemma 3.4 implies that ds(Tj ) > 3 for all n 0 ≤ j ≤ t. In this case, step 3 of Algorithm G will correctly output cap(T ) = 0. Case 2: T is rank non-decreasing. 48 ǫ2 . Assume the conn3 trary, for the sake of contradiction. By Theorem 2.20, we know that cap(T1 ) ≥ exp(−10n2 log(M n)). ǫ2 Also Proposition 2.8 implies that cap(Tj ) ≤ 1 for all j. However by the assumption that ǫj > 3 , n Lemma 5.2 implies that cap(Tj+1 ) ≥ exp(ǫ2 /n3 ) · cap(Tj ) for all 0 ≤ j ≤ t. Hence, we obtain:  2  2 tǫ tǫ · cap(T ) ≥ exp · exp(−10n2 log(M n)) 1 ≥ cap(Tt+1 ) ≥ exp 1 3 n n3 In this case, we will show that there must exist 0 ≤ j ≤ t such that ǫj ≤  n3 · 1 + 10n2 log(M n) gives us the required contradiction. 2 ǫ ǫ2 Now that we showed the existence of 0 ≤ j ≤ t such that ǫj ≤ 3 , we will show that step 4 n ǫ2 indeed computes a good approximation to capacity. For the first ǫj such that ǫj ≤ 3 , Lemma 3.4 n !−1 j−1 Y √ n n det(Ri ) implies that cap(Tj ) ≥ (1 − nǫj ) ≥ (1 − ǫ/n) ≥ 1 − ǫ. Since cap(Tj ) = cap(T ) · , Plugging in t = i=0 we have cap(T ) = cap(Tj ) · j−1 Y det(Ri ). i=0 As 1 − ǫ ≤ cap(Tj ) ≤ 1, we obtain the correct approximation. 5.1 Computing Capacity with Truncation In this subsection, we analyze the computation of capacity when we truncate the input matrices. This analysis will be similar to the one in Section 4.2. We begin with some intuition on why truncation works. Notice that to approximate the capacity, all we need is to compute the determinants of the matrices Ui in Algorithm 2. The Ui ’s are the truncations of the matrices Si from equation (15), the latter matrices being important as they describe the scaled operator Tj in terms of the original operator T , see equations (16, 17, 18). The reason why truncating the input works is because the eigenvalues of Ui are very similar to the eigenvalues of Si . Therefore, we can show that det(Si ) ≈ det(Ui ). This will imply that the truncated capacity is a good approximation to the actual capacity. The analysis will rely mainly on Lemma 4.3, which gives a good bound on the spectral norm of Si − Ui . Now we state the truncated algorithm. Given a matrix A, let Trn(A) be the matrix obtained by truncating the entries of A up to P (n, 1/ǫ, log(M )) = 1ǫ · (n12 log4 (M n)) · log(n4 /ǫ2 ) bits after the decimal point. We now proceed to the analysis of Algorithm 4. In Theorem 5.3, we proved the correctness of Algorithm G without truncation. Thus, to prove correctness of Algorithm 4, it is enough to prove two statements: 1. if e ǫj ≤ ǫ2 /4n3 , then the operators Tj will satisfy the ǫj ≤ ǫ2 /n3 bounds 2. kUi − Si k ≤ 2−P (n,1/ǫ,log(M ))/2 . 49 Input: Quantum operator T given in terms of Kraus operators A1 , . . . , Am ∈ Zn×n and approximation parameter ǫ > 0. Each entry of Ai has absolute value at most M . Output: cap(T ) with multiplicative error of (1 ± ǫ). 1. Check if T (I) and T ∗ (I) are singular. If any one of them is singular, then output cap(T ) = 0, otherwise proceed to step 2. 2. Let U−1 = S−1 = In and U0 = S0 = T ∗ (I). Additionally, for 1 ≤ j ≤ t, let ( −1 Trn(T (Uj−1 )), if i is odd, Uj = −1 ∗ Trn(T (Uj−1 )), otherwise. i h −1 · Uj − In )2 . Go to step 3. Also let e ǫj = tr (Uj−2 3. If e ǫj ≤ ǫ2 for any 0 ≤ j ≤ t, go to step 4. Otherwise, output cap(T ) = 0. 4n3 4. For the first 0 ≤ j ≤ t such that e ǫj ≤ ǫ2 , output 4n3 cap(T ) = det(Uj−1 ) · det(Uj−2 ). Algorithm 4: Algorithm G with truncation, computing capacity The first item implies that steps 1 to 3 of the algorithm above are correct, and the second item will tell us that step 4 indeed computes an 1 ± ǫ approximation to capacity. More formally, we have the following theorem. Theorem 5.4. Let T be a completely positive operator, whose Kraus operators are given by n × n matrices A1 , . . . , Am ∈ Zn×n , such that each entry of Ai has absolute value at most M . Algorithm 4, with truncation parameter P (n, 1/ǫ, log(M )) = 1ǫ · (n12 log4 (M n)) · log(n4 /ǫ2 ) when applied for  4n3 t = 2 · 1 + 10n2 log(M n) steps approximates cap(T ) within a multiplicative factor of 1 ± ǫ. ǫ Proof. By applying Lemma 4.4 with parameters t and P (n, 1/ǫ, log(M )) as above, we get that |e ǫi − ǫi | < ǫ2 for all 0 ≤ i ≤ t. n4 Therefore, steps 1 to 3 of Algorithm 4 work just as if we had not done any truncation (as in Algorithm 3). This implies that we will always output cap(T ) = 0 whenever the operator T is rank decreasing. We are now left with the computation of capacity when T is rank non-decreasing, which is done in step 4. By applying Lemma 4.3 with parameter δ = 2−P (n,1/ǫ,log(M )) , we get kUi − Si k ≤ 2−P (n,1/ǫ,log(M ))/2 , for all 0 ≤ i ≤ t. Let 0 ≤ µi1 ≤ µi2 ≤ · · · ≤ µin be the eigenvalues of Ui and 0 ≤ λi1 ≤ λi2 ≤ · · · ≤ λin be the 50 eigenvalues of Si . From kUi − Si k ≤ 2−P (n,1/ǫ,log(M ))/2 and Lemma 4.2, we have   ǫµiℓ ǫ  ǫ  |µiℓ − λiℓ | ≤ 2−P (n,1/ǫ,log(M ))/2 ≤ ≤ λiℓ ≤ µiℓ 1 + . ⇒ µiℓ 1 − 4n 4n 4n Hence, we have that det(Sj−1 ) · det(Sj−2 ) = j−1 Y n Y i=j−2 ℓ=1 λi,ℓ ≥ j−1 Y n Y i=j−2 ℓ=1  ǫ  µi,ℓ 1 − 4nt j−1 n  ǫ 2n Y Y ≥ 1− µi,ℓ · 4n i=j−2 ℓ=1 ≥ (1 − ǫ/2) · j−1 Y n Y i=j−2 ℓ=1 µi,ℓ = (1 − ǫ/2) · det(Uj−1 ) · det(Uj−2 ) Similarly, we have that det(Sj−1 ) · det(Sj−2 ) ≤ (1 + ǫ/2) · det(Uj−1 ) · det(Uj−2 ). ǫ2 ǫ2 ǫ2 As e ǫj ≤ 3 implies that ǫj ≤ 3 + 4 , by Lemma 3.4 we have cap(Tj ) ∈ [(1 − ǫ/2), 1]. Thus, 4n 4n n equation (20) yields cap(T ) = cap(Tj ) det(Sj−1 ) det(Sj−2 ) ⇒ (1 − ǫ/2) det(Sj−1 ) det(Sj−2 ) ≤ cap(T ) ≤ det(Sj−1 ) det(Sj−2 ) ⇒ (1 − ǫ/2)2 det(Uj−1 ) det(Uj−2 ) ≤ cap(T ) ≤ (1 + ǫ/2) det(Uj−1 ) det(Uj−2 ). The inequalities above imply that det(Uj−1 ) · det(Uj−2 ), that is, the output of Algorithm 4, lies in the interval [(1 − ǫ)cap(T ), (1 + ǫ)cap(T )]. 6 Problems solved by Algorithm G In this section we define more formally the various reincarnations, in different mathematical areas, of the problem SINGULAR solved by algorithm G. We start in Subsection 6.1 with more formal definitions of the necessary concepts from these various areas (many given semi-formally in the introduction), proceed in Subsection 6.2 with formal definitions of the problem in each area, and conclude with a formal statement of what Algorithm G achieves for all. 6.1 6.1.1 Preliminary definitions Free Skew Field Let x = {x1 , . . . , xm } be a set of non-commuting variables. We will denote by Fhxi, the ring of polynomials in non-commuting variables x1 , . . . , xm over the (commuting) field F. We will denote by F <x ( >, ) the free skew (non-commutative) field of rational functions in non-commuting variables x1 , . . . , xm over the (commuting) field F. We will describe below the original construction of Amitsur [Ami66] to describe this skew field. A non-commutative circuit Φ (with inversions) over a (commutative) field F and non-commuting variables x1 , . . . , xm is a directed acyclic graph. Nodes of in-degree zero are labelled by a variable 51 or a field element from F. Nodes of in-degree one are labelled by −1 and nodes of in-degree two are labelled by a + or ×. The two edges going into a node labelled by × are labelled left and right to specify the order of multiplication. The nodes are called input gates, inverse gates and sum and product gates respectively. The nodes of out-degree zero are called output gates. The size of a circuit Φ is the number of gates in it. A formula is a circuit all of whose nodes/gates have out-degree at most one. A node v ∈ Φ is supposed to compute a non-commutative rational function v̂ ∈ F <x ( >. ) However Φ may contain division by zero, in which case v̂ would be undefined. The definition of v̂ is the following: 1. If v is an input gate, labelled by a (variable or a field element), then v̂ := a. 2. If v is a sum or a product gate and v = v1 + v2 or v = v1 × v2 , then v̂ := vˆ1 + vˆ2 or v̂ := vˆ1 × vˆ2 respectively and assuming that vˆ1 and vˆ2 are both defined. 3. If v is an inverse gate and v = u−1 , then v̂ := û−1 if û is defined and û 6= 0. We say that Φ is a correct circuit if û is defined for every gate u ∈ Φ. Note that unlike the commutative case, a non-commutative rational expression might not be expressible as a ratio of two polynomials and in fact, there could be an unbounded number of nested inversions in such expressions [Reu96]. But still there are nontrivial rational identities in the noncommutative setting. One example is Hua’s identity [Hua49], (x + xy −1 x)−1 is equivalent to the expression x−1 − (x + y)−1 . So it is highly nontrivial to even define the free skew field. The first construction of the free skew field was given by Amitsur [Ami66]. Subsequently, alternate constructions were given by Bergman [Ber70], Cohn [Coh71], Malcolmson [Mal78]. Let Φ be a circuit and (B1 , . . . , Bm ) be a tuple of matrices. Then we will say that Φ is defined on (B1 , . . . , Bm ) if all the inversions in Φ are possible when evaluated on B1 , . . . , Bm . Amitsur proved that the set of all circuits (or equivalently formulas) modulo this equivalence relation form a skew field. Definition 6.1. Let Φ be a non-commutative circuit with inversions. Dom(Φ) := {(B1 , . . . , Bm ) : Φ defined on (B1 , . . . , Bm )} Two circuits Φ1 and Φ2 are said to be equivalent if Φ̂1 (B1 , . . . , Bm ) = Φ̂2 (B1 , . . . , Bm ) for all (B1 , . . . , Bm ) ∈ Dom(Φ1 ) ∩ Dom(Φ2 ) (and Dom(Φ1 ) ∩ Dom(Φ2 ) 6= φ). We refer the reader to [KVV10, HW14] and references therein for further information about the free skew field. 6.1.2 Shrunk Subspace The notion of a shrunk subspace will be very crucial for us. Definition 6.2. Let A1 , . . . , Am ∈ Mn (F). A1 , . . . , Am are said to admit a shrunk subspace if there exist subspaces V, W ⊆ Fn s.t. dim(W ) < dim(V ) and Ai (V ) ⊆ W for 1 ≤ i ≤ m (V is the shrunk subspace here, shrunk to W simultaneously by all Ai ). A1 , . . . , Am are said to admit a c-shrunk subspace if there exist subspaces V, W ⊆ Fn s.t. dim(W ) ≤ dim(V ) − c and Ai (V ) ⊆ W for 1 ≤ i ≤ m. 52 6.1.3 Invariant Theory In this section, we give the relevant background from Invariant Theory. We will give only a high level overview needed to understand the problems and the results in this paper. One can find much more in the books [KP96, DK02]. In this section, all the variables commute! Fix a field F. Let G be a group and V be its representation, namely a vector space on which G acts. The group G then also acts on the polynomial functions on V , F[V ], which is also called the coordinate ring of V . In our case V will be finite dimensional (say m), so F[V ] will be simply be F[y], where y = {y1 , . . . , ym }. For a polynomial p(y) ∈ F[y], we will denote by gp the action of g ∈ G on p. A polynomial is said to be invariant if gp = p for all g ∈ G. The following is a well studied example: Example 6.3. Let G = Sm acts on the set of formal variables y (and hence on the vector spaces defined by them) by permuting them. Then the set of invariant polynomials are all the symmetric polynomials. The null-cone of an action is the set of all common zeroes of the non-constant invariant polynomials of the action. We will be interested in the so called left-right action. Here a pair of matrices (B, C) ∈ SLn (F) × SLn (F) acts on (X1 , . . . , Xm ) to give (BX1 C, . . . , BXm C). The variables are the entries of X1 , . . . , Xm , so there are mn2 variables in total. Explicit generating sets for the invariant ring of polynomials of the left-right action have been well studied and the following is known about them: Theorem 6.4 ([DW00, DZ01, SdB01, ANS10]). Over algebraically closed fields F, the set ! ) ( m X Xi ⊗ Bi : k ∈ N, Bi ∈ Mk (F) Det i=1 is a generating set for the ring of invariant polynomials of the left-right action. These are in fact special cases of more general results on invariant rings of arbitrary quivers. Explicit exponential bounds on the degree of polynomials required to generate the ring of invariant polynomials are known. It is in fact a very important open problem to obtain polynomial degree bounds for the generating set. See [HW14] for some applications which include eliminating divisions from non-commutative circuits. The null-cone of the left-right action (over algebraically closed fields of arbitrary characteristic) was studied in [BD06, ANS10], who proved the following theorem: Theorem 6.5 ([BD06, ANS10]). (A1 , . . . , Am ) is in the null-cone of the left-right action iff A1 , . . . , Am admit a shrunk subspace. We state the degree bounds for the generating set of invariant polynomials in terms of the dimension of matrices required to test the null-cone property. But these are essentially equivalent to the degree bounds by [Der01] (over algebraically closed fields of characteristic zero). Theorem 6.6 ([Der01]). Let A1 , . . . , Am be n × n complex matrices such that they are not in the 2 null-cone of the left-right action. Then there exist matrices B1 , . . . , Bm of dimension n2 4n s.t. Det (A1 ⊗ B1 + · · · Am ⊗ Bm ) 6= 0 53 Theorem 6.7 ([IQS15b]). Let A1 , . . . , Am be n × n complex matrices that are not in the null-cone of the left-right action. Then there exist matrices B1 , . . . , Bm of dimension (n + 1)! s.t. Det (A1 ⊗ B1 + · · · Am ⊗ Bm ) 6= 0 There has been remarkable progress on this problem recently. Theorem 6.8 ([DM15, IQS15a]). Let A1 , . . . , Am be n × n complex matrices that are not in the null-cone of the left-right action. Then there exist matrices B1 , . . . , Bm of dimension n − 1 s.t. Det (A1 ⊗ B1 + · · · Am ⊗ Bm ) 6= 0 By combining Theorem 6.23 and Theorem 6.8, we get the following theorem: Theorem 6.9. Let A1 , . . . , Am be n × n complex matrices such that they do not admit a shrunk subspace. Then there exist matrices B1 , . . . , Bm of dimension n − 1 s.t. Det (A1 ⊗ B1 + · · · Am ⊗ Bm ) 6= 0 6.2 Problem Definitions In this section, we formally state and give some background to all incarnations of the problems solved by Algorithm G. These problems arise from several disparate fields which are all magically interconnected. In most of these problems, the inputs will essentially be a tuple of n × n matrices with rational entries A1 , . . . , Am . We will denote the maximum bit size of the entries of these matrices by b. We give deterministic poly(n, m, b) time algorithms for all of these problems. 6.2.1 SINGULAR In the (non-commutative) SINGULAR problem, the input is a matrix L ∈ Mn (Fhxi) whose entries are linear polynomials and the question is to check whether L is singular (not invertible) over F <x ( >. ) The problem makes sense over any field but our results will hold when F = Q (most of the theory works over C but to account for input size, we only work over the rationals). Problem 6.10. SINGULAR P Input: A1 , . . . , Am ∈ Mn (Q) interpreted as L = m i=1 xi Ai Output: Is L singular over the free skew field Q <x ( >? ) 6.2.2 Computing the Non-Commutative Rank and Fullness Testing We also study the problem of computing the rank of a matrix over the free skew field. It turns out that there are various interesting notions of rank which coincide. The two main ones for us will be the inner rank and the rank over the free skew field (which is unambiguously defined). Definition 6.11 (Inner Rank). Suppose L is a matrix in Fhxin×p . The inner rank of L is defined as the minimum r such that L = KM , where K ∈ Fhxin×r and M ∈ Fhxir×p . It is clear that the inner rank of L is at most min(n, p), since we can write L = In · L and L = L · Ip . When the inner rank of L is equal to min(n, p), we say that L is a full matrix. The more formal definition is given below: 54 Definition 6.12 (Fullness). A matrix L ∈ Mn (Fhxi) is said to be full if it cannot be written as L = KM where K ∈ Fhxin×r , M ∈ Fhxir×n , for some r < n. The other way to define the non-commutative rank of a matrix L is by defining its rank over the free skew field, which we do now. Definition 6.13. [Non-Commutative Rank] Given a matrix L in Fhxin×p , nc-rank(L) is defined to be the rank of L over F <x ( >. ) It is important to notice that even over skew fields, the rank of a matrix is defined unambiguously as the row rank or the column rank. Now that we have defined the non-commutative rank of a matrix, we state the general problem of determining the non-commutative rank of matrices over Fhxi. Problem 6.14. Computing Noncommutative rank Input: Matrix L in Qhxin×p . Each entry is given by a formula computing it which is of size s and uses field elements (rational numbers) of bit size at most b. Output: nc-rank(L) Input size: n + p + b + s. Since we can compute the non-commutative rank of L, we can also determine whether L is full. Thus, by solving Problem 6.14 we have solved the following problem: Problem 6.15. General Fullness testing Input: Formulas computing the entries of a matrix M ∈ Mn (Fhxi). Output: Is M full? Due to the following theorem of Cohn, which works over all fields, by testing fullness of a matrix we can also decide whether a matrix is invertible over the free skew field: ( > ) if and only if L is Theorem 6.16 ([Coh95]). Let L ∈ Fhxin×n . Then L is invertible over F <x full. It is important to remark that the analogous statement for matrices of commutative polynomials is not true. The following skew symmetric matrix is a counterexample:   0 x y −x 0 1 −y −1 0 It is full but not invertible (when x and y are commuting variables). Going back to Definition 6.13, let us assume for the sake of simplicity that L is square, i.e. n = p, although the results hold for rectangular matrices as well. As stated in Theorem 1.17, Cohn proved that nc-rank(L) is equal to the inner rank of L (there it is stated for L which have linear polynomials as entries but it is in fact true for general L as seen by the Higman’s trick (see section A) of reducing general L to the linear case). Theorem 1.17 also states that a linear matrix L has nc-rank(L) ≤ r iff there exist invertible matrices B, C over F s.t. BLC has a block of zeroes of size i × j where i + j ≥ 2n − r. This can be easily translated into the following theorem: 55 Pm Theorem 6.17. A linear matrix L = i=1 xi Ai ∈ Mn (Fhx1 , . . . , xm i) has nc-rank(L) ≤ r iff A1 , . . . , Am admit a n − r-shrunk subspace. P By proposition 6.26, we also get that a linear matrix L = m i=1 xi Ai ∈ Mn (Fhxi) has nc-rank(L) ≤ r iff the operator defined by A1 , . . . , Am is (n − r)-rank-decreasing. In section A, we will give two different deterministic polynomial time algorithms for computing noncommutative rank, one by an algebraic reduction to fullness testing and the other via a “quantum” reduction from checking if an operator is c-rank-decreasing to checking if an operator is rank-decreasing. 6.2.3 Testing Shrunk Subspaces Problem 6.18. Testing shrunk subspaces Input: A1 , . . . , Am ∈ Mn (Q). Output: Do A1 , . . . , Am admit a shrunk subspace? Another theorem due to Cohn is the following (works over all fields): P Theorem 6.19 ([Coh95]). A matrix L = m i=1 xi Ai ∈ Mn (Fhxi) is not full if and only if there are invertible matrices U, V ∈ Mn (F) s.t. U LV has a r × s block of zeroes for some r, s with r + s > n. The above theorem is an analogue of Hall’s bipartite matching theorem where the r × s block of zeroes corresponds to a set of size r on one side of the bipartition and set of size s on the other side of the bipartition with no edges between them. If r + s > n, this prevents the graph from having a perfect matching. The following theorem is an easy corollary of Theorem 6.19. P Theorem 6.20. A matrix L = m i=1 xi Ai ∈ Mn (Fhxi) is not full if and only if A1 , . . . , Am admit a shrunk subspace. So an extremely hard looking problem about inverting matrices in the free skew field is equivalent to a simply stated problem in (commutative) linear algebra! Remark 6.21. A1 , . . . , Am shrink a subpace of Cn iff A1 , . . . , Am shrink a subspace of Qn since Pm ( > ) iff it is invertible over Q <x ( >. ) i=1 xi Ai is invertible over C <x 6.2.4 Null-Cone of the Left-Right Action Problem 6.22. Testing membership in the null-cone of the left-right action Input: A1 , . . . , Am ∈ Mn (Q). Output: Does (A1 , . . . , Am ) lie in the null-cone of the left-right action? As we saw in section 6.1.3, testing if (A1 , . . . , Am ) is in the null-cone of the left-right action is the same as testing if A1 , . . . , Am admit a shrunk subspace (over algebraically closed fields). Theorem 6.23 ([BD06, ANS10]). (A1 , . . . , Am ) is in the null-cone of the left-right action iff A1 , . . . , Am admit a shrunk subspace. 56 The above theorem can also be obtained in a round-about manner through infinite generating sets of the left-right action. The tuple (A1 , . . . , Am ) is in the null-cone of the left-right action iff ! m X Ai ⊗ Bi = 0 Det i=1 P for all k ∈ N, Bi ∈ Mk (F). This is equivalent to the matrix m i=1 xi Ai being singular over the free skew field F <x ( > ) (this essentially follows from Amitsur’s construction of the free skew field [Ami66], see [HW14]) which is equivalent to A1 , . . . , Am admitting a shrunk subspace, because of Theorem 6.16 and Theorem 6.20. In [ANS10], several fundamental problems about the left-right action were connected to Geometric Complexity Theory. Most of these problems seem to require polynomial degree bounds for the generating set of the invariant ring of polynomials. However, we are able to bypass proving these polynomial degree bounds for determining membership in the null-cone over Q, and it is plausible that our methods can solve other problems for the left-right action, e.g. the orbit closure intersection problem. 6.2.5 Testing Rank Decreasing Property of Quantum Operators This problem will only make sense over Q (or more generally over C). Definition 6.24. A completely positive operator is called rank decreasing if there exists a X  0 s.t. Rank(T (X)) < Rank(X) We will restrict our attention quantum operators with Kraus operators having rational entries. Problem 6.25. Testing if quantum operators are rank decreasing Input: A1 , . . . , Am interpreted as a quantum operator T with Kraus operators A1 , . . . , Am . Output: Is T rank decreasing? Proposition 6.26 ([Gur04]). Suppose T is a cptp map whose Kraus operators are A1 , . . . , Am . Then T is c-rank-decreasing iff A1 , . . . , Am admit a c-shrunk subspace. The connection essentially is that if A1 , . . . , Am shrink a subspace V , then T will decrease the rank of the projector onto V , ΠV . Proof. First suppose that A1 , . . . , Am have a shrunk subspace V such that each Ai maps V into W , where dim(W ) ≤ dim(V ) − c. Suppose dim(V ) = p and v1 , . . . , vp be an orthonormal basis for V . Let ΠV be the projection onto V . Then Rank(ΠV ) = p. We will show that Rank(T (ΠV )) ≤ p − c which will show that T is c-rank-decreasing. T (ΠV ) = p m X X Ai vj vj† A†i i=1 j=1 Since for all i, j, Ai vj ∈ W , it is clear that Im(T (ΠV )) ⊆ W and hence Rank(T (ΠV )) ≤ p − c. 57 Now suppose that T is c-rank-decreasing i.e. there exists a hermitian X, X  0 s.t. Rank(T (X)) ≤ Rank(X) − c. We will show that Im(X) is a c-shrunk subspace for A1 , . . . , Am . For this it suffices to show that for all i, Ai (Im(X)) ⊆ Im(T (X)). This is true because: Ai (Im(X)) = Ai (Im(X 1/2 )) = Im(Ai X 1/2 ) = Im(Ai XA†i )   m X Aj XA†j  ⊆ Im  j=1 = Im(T (X)) The third equality follows from the fact that Im(A) = Im(AA† ) for any matrix A. The containment follows from the following claim: Claim 6.27. Let A and B be two psd matrices. Then Im(A) ⊆ Im(A + B). Proof. Suppose Im(A) ⊆ Im(A + B) is not true. Then there exists a vector u s.t. u† Au > 0 but u† (A + B)u = 0, which is clearly not possible since u† Bu ≥ 0. Remark 6.28. Because of Remark 6.21, T decreases the rank of a psd matrix with rational entries iff it decreases the rank of a psd matrix with complex entries. 6.2.6 Matrix Inverse Identity Testing INVERSE is the following computational model: Given a matrix L ∈ Mn (Fhxi) whose entries Pm are linear polynomials (L = A1 + i=2 xi Ai ), the output is the top right entry of L−1 (A should be invertible over the free skew field F <x ( >). ) Note that the output is a rational function in the non-commuting variables x = x1 , . . . , xm . This model is exponentially more powerful than non-commutative formulas with divisions [HW14], can (efficiently) simulate non-commutative algebraic branching programs (without division) [HW14] and can be (efficiently) simulated by noncommutative circuits with division [HW14]. However it is not known whether INVERSE can simulate non-commutative circuits (with or without division) or not. We are interested in the identity testing of INVERSE, namely given an invertible (over F <x ( >) ) −1 linear matrix L as input, check whether the top right entry of L is zero. It is worth noting that the word problem for this computational model, whether, given two linear matrices L and M , the top right entries of L−1 and M −1 are the same or not, can be reduced to the identity testing problem. The difference between the top right entries of L−1 and M −1 can be written as the top right entry of N −1 for a slightly larger linear matrix N [HW14]. The problem makes sense for any underlying field F. However our results will hold for F = Q. Problem 6.29. INVERSE identity testing P Input: A1 , . . . , Am interpreted as L = A1 + m i=2 xi Ai . Ouput: Is the top right entry of L−1 zero? 58 In [HW14], it was shown that INVERSE identity testing can be reduced to SINGULAR. Let u be the 1 × n vector (1, 0, . . . , 0) and v be (0, 0, . . . , 1). Proposition 6.30 ([HW14]). Suppose L ∈ Mn (Fhxi) is invertible (over F <x ( > ) ). Then the top −1 right entry of L is zero iff  T  v L M= 0 −u is singular. P Previously we only considered singularity the form m i=1 xi Bi but now Pmwe are Pm testing for matrices of P x B is singular iff looking at matrices of the form B1 + i=2 xi Bi . However B1 + m i i i=1 xi Bi i=2 is singular. This is best seen from the shrunk subspace perspective, these matrices are singular iff B1 , . . . , Bm admit a shrunk subspace. 6.2.7 Non-commutative Rational Identity Testing In this section, we look at the problem of non-commutative rational identity testing (RIT) of formulas. Given an element of the free skew field F <x ( >, ) represented as a formula over noncommutative variables with addition, multiplication and inversion gates, we want to check if the element is zero or not. Note that the word problem over the free skew field, where we are given two rational expressions (represented as formulas) and want to check if they represent the same element in the free skew field, can be easily reduced to non-commutative RIT. Problem 6.31. Non-commutative RIT Input: Non-commutative formula Φ (with inversion gates) of size s. Output: Does Φ represents zero or not? Input size: s + b, where b is the maximum bit size of field elements (rational numbers) used in the formula. Non-commutative RIT can be reduced to INVERSE identity testing because of the following theorem. Theorem 6.32 ([HW14]). For each non-commutative formula (with inversions) Φ whose size is s and uses rational numbers of bit size at most b, there exists s′ ≤ 2s and a s′ × s′ matrix LΦ , whose entries are either variables or rational numbers of bit size at most b such that the rational functions computed by Φ and the top right entry of L−1 Φ are the same. 6.3 Results Theorem 6.33. There are deterministic polynomial time algorithms for Problems 6.10, 6.18, 6.22, 6.25, 6.14, 6.29, 6.31. For problems 6.10, 6.15, 6.18, 6.22, 6.25, 6.29, the complexity is poly(n, b). For 6.14, the complexity is poly(n, p, s, b), whereas for 6.31, it is poly(s, b). 7 Conclusion and Open Problems In this paper we gave a polynomial time algorithm for computing the non-commutative rank of a symbolic matrix over any subfield of the complex numbers. We stated its different incarnations and 59 implications to the many different areas in which this problem arises (indeed we feel that expositing these many connections, some essential to the present result, may yield better future interaction between them with possible more benefits). We note that our algorithm bypasses the fact that the best degree bound on the left-right action is exponential, and yet how the fact that it is not more than exponential is essential to guarantee a polynomial run-time of our algorithm (after our work, [DM15] got polynomial degree bounds but this doesn’t affect our analysis much). We further note again that despite the purely algebraic nature of the problem our algorithm is purely analytic, generating a sequence of complex matrices and testing its convergence. We collect now the most obvious directions for future research, some of them already mentioned in the paper. • Find more applications of this algorithm to optimization problems. • Can we use these techniques to design an efficient deterministic algorithm for the orbit-closure intersection problem for the Left-Right action? In terms of invariants, this is equivalent to asking if two tuples of matrices can be separated by invariants of the Left-Right action (over algebraically closed fields of characteristic 0). More formally given two tuples of matrices, (A1 , . . . , Am ) and (B1 , . . . , Bm ), check whether for all (T1 , . . . , Tm ) of arbitrary dimension, Det (T1 ⊗ A1 + · · · Tm ⊗ Am ) = Det (T1 ⊗ B1 + · · · Tm ⊗ Bm ) The results of [DM15] give a randomized polynomial time algorithm for this problem (over algebraically closed fields of characteristic 0): just plug in random (T1 , . . . , Tm ) of polynomial dimension. • Find a black-box algorithm for SINGULAR. That is, efficiently produce (deterministically) a P polynomial size set S of tuples of polynomial dimension matrices s.t. for all L = m x A i=1 i i s.t. L is non-singular, it holds that for some (T1 , . . . , Tm ) ∈ S, Det (T1 ⊗ A1 + · · · Tm ⊗ Am ) 6= 0 Due to the recent polynomial dimension bounds of [DM15], it can be proved that a random set S works. The challenge is to produce it deterministically. As a special case, this captures deterministic parallel algorithms for the decision version of bipartite perfect matching (when A1 , . . . , Am are elementary matrices Ei,j representing the edges of a bipartite graph). So perhaps, techniques from the recent breakthrough work [FGT16] can be useful. • Explore further the connection between commutative and non-commutative PIT problems. We feel that beyond the many connections between commutative and non-commutative settings that arise here, this different angle of looking at the commutative PIT problem, relating it to its non-commutative cousin, may help in the major quest of finding an efficient deterministic algorithm for it. As mentioned above, this viewpoint has already resulted in a deterministic PTAS for the commutative rank [BJP16]. • We design an efficient algorithm for checking if a completely positive operator is rankdecreasing. Can we do the same for positive operators? Algorithm G in fact works for positive operators as well and all that is needed is to prove an effective lower bound on the capacity cap(T ) of a positive operator T which is rank non-decreasing (similar to Theorem 2.20). It was already proven in [Gur04] that cap(T ) > 0 for a positive operator T which is rank non-decreasing. 60 • Design a strongly polynomial time algorithm for operator scaling. Strongly polynomial time algorithms for matrix scaling were given by [LSW98]. Can they be extended to the operator case? • Can we compute (1 + ǫ) approximation to cap(T ) in time poly(n, b, log(1/ǫ))? For computing capacity of non-negative matrices, such algorithms exist. One of the algorithms in [LSW98] has this stronger convergence rate. Also for matrices, capacity can be formulated as a convex program and hence the Ellipsoid algorithm also gives this stronger convergence rate [GY98]. • Can we design efficient algorithms for testing the null-cone of general quivers? There is reduction from general quivers to Kronecker-quiver or the left-right action (e.g. see [DM15]) but the reduction is not always efficient. What about the general problem of testing the null-cone of actions of reductive groups? Acknowledgments We would like to thank Harm Derksen, Pavel Hrubes, Louis Rowen and K. V. Subrahmanyam for helpful discussions. We would also like to thank Oded Regev for suggesting us that operator scaling could be used for approximating capacity. References [AL50] S. A. Amistur and J. Levitzki. Minimal identities for algebras. Proceedings of the of the American Mathematical Society, 1:449–463, 1950. [AL80] M. D. Atkinson and S. Lloyd. Large spaces of matrices of bounded rank. Quarterly Journal of Math. Oxford, 31:253–262, 1980. [Alo99] Noga Alon. Combinatorial Nullstellensatz. Combinatorics, Probability and Computing, 8(1-2):7–29, 1999. [Ami66] Shimshon Amitsur. Rational identities and applications to algebra and geometry. Journal of Algebra, 3:304–359, 1966. [ANS10] Bharat Adsul, Suresh Nayak, and K. V. Subrahmanyam. A geometric approach to the kronecker problem ii : rectangular shapes, invariants of n n matrices, and a generalization of the artin-procesi theorem. Manuscript, available at http://www.cmi.ac.in/ kv/ANS10.pdf, 2010. [Atk80] M. D. Atkinson. Spaces of matrices with several zero eigenvalues. Bulletin of the London Mathematical Society, 12(89-95), 1980. [BD06] Matthias Bürgin and Jan Draisma. The hilbert null-cone on tuples of matrices and bilinear forms. Math Z, 254(4):785–809, 2006. [Bea87] L. B. Beasley. Nullspaces of spaces of matrices of bounded rank. Current trends in matrix theory, 1987. 61 [Ber70] G. M. Bergman. Skew fields of noncommutative rational functions, after amitsur. Seminaire Schutzenberger–Lentin–Nivat, Annee 1969/70, (16), 1970. [Ber84] Stuart J. Berkowitz. On computing the determinant in small parallel time using a small number of processors. Information Processing Letters, 18(3):147–150, 1984. [BJP16] Markus Bläser, Gorav Jindal, and Anurag Pandey. Greedy strikes again: A deterministic PTAS for commutative rank of matrix spaces. Electronic Colloquium on Computational Complexity (ECCC), 23:145, 2016. [BW05] Andrej Bogdanov and Hoeteck Wee. More on noncommutative polynomial identity testing. Computational Complexity, pages 92–99, 2005. [Cho75] M. Choi. Completely positive linear maps on complex matrices. Linear Algebra and Its Applications, pages 285–290, 1975. [CLO07] D. Cox, J. Little, and D. O’Shea. Ideals, Varieties, and Algorithms. Undergraduate Texts in Mathematics. Springer, New York, third edition edition, 2007. [Coh71] P. M. Cohn. The embedding of firs in skew fields. Proceedings of the London Mathematical Society, 23:193–213, 1971. [Coh73] P. M. Cohn. The word problem for free fields. The Journal of Symbolic Logic, 38(2):309– 314, 1973. [Coh75] P. M. Cohn. The word problem for free fields: A correction and an addendum. Journal of Symbolic Logic, 40(1):69–74, 1975. [Coh95] P. M. Cohn. Skew Fields, Theory of General Division Rings. Cambridge University Press, 1995. [CR99] P. M. Cohn and C. Reutenauer. On the construction of the free field. International journal of Algebra and Computation, 9(3):307–323, 1999. [Der01] Harm Derksen. Polynomial bounds for rings of invariants. Proceedings of the American Mathematical Society, 129(4):955–964, 2001. [Die49] J. Dieudonné. Sur une généralisation du groupe orthogonal à quatre variables. Arch. Math., 1:282–287, 1949. [DK02] H. Derksen and G. Kemper. Computational Invariant Theory, volume 130. SpringerVerlag, Berlin, 2002. [DM15] Harm Derksen and Visu Makam. Polynomial degree bounds for matrix semi-invariants. arXiv preprint arXiv:1512.03393, 2015. [DS06] Z. Dvir and A. Shpilka. Locally decodable codes with 2 queries and polynomial identity testing for depth 3 circuits. SIAM J. Comput, 2006. [DW00] Harm Derksen and Jerzy Weyman. Semi-invariants of quivers and saturation for littlewood-richardson coefficients. Journal of the American Mathematical Society, 13(3):467–479, 2000. 62 [DZ01] Mátyás Domokos and A. N. Zubkov. Semi-invariants of quivers as determinants. Transformation Groups, 6(1):9–24, 2001. [Edm67] Jack Edmonds. Systems of distinct representatives and linear algebra. Journal of research of the National Bureau of Standards, 71(241-245), 1967. [Edm69] Jack Edmonds. Submodular functions, matroids, and certain polyhedra. Lectures, Calgary International Symposium on Combinatorial Structures, 1969. [EH88] David Eisenbud and Joe Harris. Vector spaces of matrices of low rank. Advances in Math, 70:135–155, 1988. [FGT16] Stephen A. Fenner, Rohit Gurjar, and Thomas Thierauf. Bipartite perfect matching is in quasi-nc. STOC, 2016. [For86] Edward Formanek. Generating the ring of matrix invariants. Ring Theory, pages 73–82, 1986. [FR04] Marc Fortin and Christophe Reutenauer. Commutative/noncommutative rank of linear matrices and subspaces of matrices of low rank. 2004. [FS13a] Michael Forbes and Amir Shpilka. Explicit noether normalization for simultaneous conjugation via polynomial identity testing. RANDOM, 2013. [FS13b] Michael Forbes and Amir Shpilka. Quasipolynomial-time identity testing of noncommutative and read-once oblivious algebraic branching programs. FOCS, pages 243–252, 2013. [GGOW17] Ankit Garg, Leonid Gurvits, Rafael Oliveira, and Avi Wigderson. Algorithmic and optimization aspects of Brascamp-Lieb inequalities, via operator scaling. STOC, 2017. arXiv:1607.06711. [GGRW02] I. Gelfand, S. Gelfand, V. Retakh, and R. Wilson. http://arxiv.org/abs/math/0208146, 2002. Quasideterminants. [GM02] Boaz Gelbord and Roy Meshulam. Spaces of singular matrices and matroid parity. European Journal of Combinatorics, 23(4):389–397, 2002. [GS00] Leonid Gurvits and Alex Samorodnitsky. A deterministic polynomial-time algorithm for approximating mixed discriminant and mixed volume. STOC, 2000. [GS02] Leonid Gurvits and Alex Samorodnitsky. A deterministic algorithm approximating the mixed discriminant and mixed volume, and a combinatorial corollary. Discrete Computational Geometry, 27(531-550), 2002. [Gur04] Leonid Gurvits. Classical complexity and quantum entanglement. Journal of Computer and System Sciences, 69(3):448–484, 2004. [Gur06] Leonid Gurvits. Hyperbolic polynomials approach to van der waerden/schrijver-valiant like conjectures: sharper bounds, simpler proofs and algorithmic applications. STOC, pages 417–426, 2006. 63 [GY98] Leonid Gurvits and Peter N. Yianilos. The deflation-inflation method for certain semidefinite programming and maximum determinant completion problems. Technical Report, NECI, 1998. [Hak61] Wolfgang Haken. Theorie der normalflachen. Acta Math, 105:245–375, 1961. [Hig40] Graham Higman. Units in group rings. PhD thesis, Balliol College, 1940. [Hil93] David Hilbert. Uber die vollen invariantensysteme. Math. Ann., 42:313–370, 1893. [Hua49] Loo-Keng Hua. Some properties of a sfield. Proceedings of National Academy of Sciences USA, 35:533–537, 1949. [HW14] Pavel Hrubes and Avi Wigderson. Non-commutative arithmetic circuits with division. ITCS, 2014. [HWY10] Pavel Hrubes, Avi Wigderson, and Amir Yehudayoff. Relationless completeness and separations. In Computational Complexity (CCC), 2010 IEEE 25th Annual Conference on, pages 280–290. IEEE, 2010. [HWY11] Pavel Hrubes, Avi Wigderson, and Amir Yehudayoff. Non-commutative circuits and the sum-of-squares problem. Journal of the American Mathematical Society, 24(3):871– 898, 2011. [Hya79] Laurent Hyafil. On the parallel evaluation of multivariate polynomials. SIAM Journal on Computing, 8(2):120–123, 1979. [IKQS15] Gabor Ivanyos, Marek Karpinski, Youming Qiao, and Miklos Santha. Generalized wong sequences and their applications to edmonds’ problems. Journal of Computer and System Sciences, 81(7):1373–1386, 2015. [IQS15a] Gábor Ivanyos, Youming Qiao, and K. V. Subrahmanyam. Constructive noncommutative rank computation in deterministic polynomial time over fields of arbitrary characteristics. arXiv preprint arXiv:1512.03531, December 2015. [IQS15b] Gabor Ivanyos, Youming Qiao, and K. V. Subrahmanyam. Non-commutative edmonds’ problem and matrix semi-invariants. http://arxiv.org/abs/1508.00690, 2015. [KI04] Valentine Kabanets and Russell Impagliazzo. Derandomizing polynomial identity tests means proving circuit lower bounds. Computational Complexity, 13:1–46, 2004. [KP96] H. Kraft and C. Procesi. Classical invariant theory, https://math.unibas.ch/uploads/x4epersdb/files/primernew.pdf, 1996. [KS01] A. Klivans and D. Spielman. Randomness efficient identity testing of multivariate polynomials. In Proceedings of the 33rd Annual STOC, 2001. [KS07] N. Kayal and N. Saxena. Polynomial identity testing for depth 3 circuits. Computational Complexity, 2007. 64 a primer. [KVV10] D. S. Kaliuzhnyi-Verbovetskyi and Victor Vinnikov. Noncommutative rational functions, their difference-differential calculus and realizations. Multidimensional Systems and Signal Processing, 2010. [LMS15] Nutan Limaye, Guillaume Malod, and Srikanth Srinivasan. Lower bounds for noncommutative skew circuits. In Electronic Colloquium on Computational Complexity (ECCC), volume 22, page 22, 2015. [Lov79] Laszlo Lovasz. On determinants, matchings, and random algorithms. Fundamentals of Computation Theory, pages 565–574, 1979. [Lov80] Laszlo Lovasz. Selecting independent lines from a family of lines in a space. Acta Sci. Math., 42(121-131), 1980. [Lov89] Laszlo Lovasz. Singular spaces of matrices and their application in combinatorics. Bulletin of the Brazilian Mathematical Society, 20:87–99, 1989. [LSW98] Nati Linial, Alex Samorodnitsky, and Avi Wigderson. A deterministic strongly polynomial algorithm for matrix scaling and approximate permanents. STOC, pages 644–652, 1998. [Mal78] P. Malcolmson. A prime matrix ideal yields a skew field. Journal of the London Mathematical Society, 18(221-233), 1978. [Mul12] Ketan Mulmuley. Geometric complexity theory v: Equivalence between blackbox derandomization of polynomial identity testing and derandomization of noether’s normalization lemma. FOCS, pages 629–638, 2012. [Nis91] Noam Nisan. Lower bounds for non-commutative computation. In Proceedings of the twenty-third annual ACM symposium on Theory of computing, pages 410–418. ACM, 1991. [Pop82] Vladimir L Popov. The constructive theory of invariants. Izvestiya: Mathematics, 19(2):359–376, 1982. [Pro76] C. Procesi. The invariant theory of nn matrices. Advances in Mathematics, 19:306–381, 1976. [Rab58] Michael O. Rabin. Recursive unsolvability of group theoretic problems. Annals of Mathematics, 67(172-194), 1958. [Rad42] R. Rado. A theorem on independence relations. Quarterly Journal of Math. Oxford, 13:83–89, 1942. [Raz74] Ju. P. Razmyslov. Trace identities of full matrix algebras over a field of characteristic zero. Mathematics of the USSR-Izvestiya, 8(4):727, 1974. [Reu96] Christophe Reutenauer. Inversion height in free fields. Selecta Mathematica, 2(1):93– 109, 1996. 65 [Row80] Louis Halle Rowen. Polynomial identities in ring theory. Academic Press, New York, 1980. [RS05] Ran Raz and Amir Shpilka. Deterministic polynomial identity testing in non commutative models. Computational Complexity, 14:1–19, 2005. [SdB01] Aidan Schofield and Michel Van den Bergh. Semi-invariants of quivers for arbitrary dimension vectors. Indagationes Mathematicae, 12(1):125–138, 2001. [Sin64] R. Sinkhorn. A relationship between arbitrary positive matrices and doubly stochastic matrices. The Annals of Mathematical Statistics, 35:876–879, 1964. [Str73] V. Strassen. Vermeidung von divisionen. Journal of Reine Angew. Math, 264:182–202, 1973. [SV11] S. Saraf and I. Volkovich. Black-box identity testing of depth 4 multilinear circuits. In Proceedings of the 43rd annual STOC, 2011. [SY10] Amir Shpilka and Amir Yehudayoff. Arithmetic Circuits: A Survey of Recent Results and Open Questions, volume 5. NOW, Foundations and Trends in Theoretical Computer Science, 2010. [Val79] Leslie Valiant. The complexity of computing the permanent. Theoretical Computer Science, 8:189–201, 1979. A Symbolic matrices with polynomial entries and non-commutative rank In this section, we show how to compute the non-commutative rank of any (not necessarily square) matrix with linear entries over the free skew field Q <x ( >. ) This will be achieved in two ways: the first, in Subsection A.2, by reducing this problem to testing singularity of a certain square matrix with linear entries, and the second, in Subsection A.3, by a purely quantum approach which in a sense mimics the reduction from maximum matching to perfect matching. In fact, we solve a more general problem. Subsection A.1 starts with a reduction of computing nc-rank of a matrix with polynomial entries (given by formulae), to the problem of computing the nc-rank of a matrix with linear entries, via the so-called “Higman’s trick” (Proposition A.2). We give the simple quantitative analysis of this reduction, which as far as we know does not appear in the literature and may be useful elsewhere. This reduction, with the two above, allow computing the non-commutative rank of any matrix in time polynomial in the description of its entries. A.1 Higman’s Trick Before stating the full version of the effective Higman trick, we need to define the bit complexity of a formula computing a non-commutative polynomial. Definition A.1 (Bit Complexity of a Formula). Let Φ be a non-commutative formula without divisions such that each of its gates computes a polynomial in Qhxi (i.e., the inputs to the formula 66 are either rational numbers or non-commutative variables). The bit complexity of Φ is the maximum bit complexity of any rational input appearing in the formula Φ. With this definition in hand, we can state and in [Hig40]. In the proposition below, it will be useful direct sum of two matrices A and B:  A A⊕B = 0 prove Higman’s trick, which first appeared to have the following notation to denote the  0 , B where the zeros in the top right and bottom left corners are of appropriate dimensions. Before stating and proving Higman’s trick, let us work through a small example which showcases the essence of the trick.   1 x Suppose we want to know the nc-rank of matrix . The problem here is that this y z + xy matrix is not linear, and we need to have a linear matrix. How can we convert this matrix into a linear matrix while preserving the rank, or the complement of the rank? To do this, we need to remove the multiplication happening in z + xy. Notice that the complement of its rank does not change after the following transformation:     1 x 0 1 x 7→ y z + xy 0 . y z + xy 0 0 1 Since the complement of the rank does not change after we perform elementary row or column operations, we can first add x · (third row) to the second row, and then subtract (third column) · y to the second column, to obtain:       1 x 0 1 x 0 1 x 0 y z + xy 0 7→ y z + xy x 7→ y z x 0 −y 1 0 0 1 0 0 1 The complement of the rank of this last matrix is the same as the complement of the rank of our original matrix! In particular, if this last matrix is full rank, it implies that our original matrix is also full rank. This is the essence of Higman’s trick. We now proceed to its full version. Proposition A.2 (Effective Higman’s Trick). Let A ∈ Qhxim×n be a matrix where each entry aij is computed by a non-commutative formula of size ≤ s and bit complexity ≤ b without divisions. Let k be the total number of multiplication gates used in the computation of the entries of A. There exist matrices P ∈ GLm+k (Qhxi), Q ∈ GLn+k (Qhxi) such that P (A ⊕ Ik )Q is a matrix with linear entries and coefficients with bit complexity bounded by b. Moreover, given access to the formulas computing the entries, one can construct P and Q efficiently in time poly(m, n, s, b). Since P and Q are non-singular matrices, the co-rank and the co-nc-rank of P (A ⊕ Ik )Q are the same as the co-rank and the co-nc-rank of A. Proof. Let Mult(aij ) be the number of multiplication gates in the formula computing entry aij and X T = Mult(aij ). 1≤i≤m 1≤j≤n 67 That is, T is the total number of multiplication gates used to compute all entries of the matrix A. We prove this proposition by induction on T , for matrices of all dimensions. The base case, when T = 0, is trivial, as in this case A itself has linear entries. Suppose now that the proposition is true for all matrices (regardless of their dimensions) which can be computed by formulas using < T multiplication gates. Let A be our matrix, which can be computed using T multiplications. W.l.o.g., we can assume that Mult(amn ) ≥ 1. Then, by finding a multiplication gate in the formula for amn that has no other multiplication gate as an ancestor, we can write amn in the form amn = a + b · c, where Mult(amn ) = Mult(a) + Mult(b) + Mult(c) + 1. Hence, the matrix       1 0 1 b (A ⊕ 1) In−1 ⊕ B = Im−1 ⊕ −c 1 0 1 is such that   aij , if i ≤ m, j ≤ n and (i, j) 6= (m, n)       a, if (i, j) = (m, n)  b, if (i, j) = (m, n + 1) bij =  −c, if (i, j) = (m + 1, n)      1, if (i, j) = (m + 1, n + 1)    0 otherwise Therefore, the number of multiplications needed to compute B is given by   X 1≤i≤m+1 1≤j≤n+1  X   − Mult(amn ) + Mult(a) + Mult(b) + Mult(c) Mult(bij ) =  Mult(a ) ij   1≤i≤m 1≤j≤n = T − Mult(amn ) + Mult(a) + Mult(b) + Mult(c) =T −1 Since B is an (m+1)×(n+1) matrix which can be computed by using a total of T −1 multiplication gates, by the induction hypothesis, there exist P ′ ∈ GLm+1+(T −1) (Qhxi) = GLm+T (Qhxi) and Q′ ∈ GLn+1+(T −1) (Qhxi) = GLn+T (Qhxi) such that P ′ (B ⊕ IT −1 )Q′ is a linear matrix. Since         1 b 1 0 B ⊕ IT −1 = Im−1 ⊕ ⊕ IT −1 (A ⊕ IT ) In−1 ⊕ ⊕ IT −1 0 1 −c 1 = R(A ⊕ IT )S,        1 b 1 0 where R = Im−1 ⊕ ⊕ IT −1 ∈ GLm+T (Qhxi) and S = In−1 ⊕ ⊕ IT −1 ∈ 0 1 −c 1 GLn+T (Qhxi), we have that  P ′ (B ⊕ IT −1 )Q′ = (P ′ R)(A ⊕ IT )(SQ′ ). Setting P = P ′ R and Q = SQ′ proves the inductive step and completes the proof. Since we only use subformulas of the formulas computing the entries of A, the bound on the bit complexity does not change. 68 A.2 Classical Reduction Having shown the effective version of Higman’s trick, we can now compute the nc-rank of a matrix over Qhxi. We begin with a lemma which will tell us that we can reduce the problem of computing the nc-rank of a matrix by testing fullness of a smaller matrix with polynomial entries. Lemma A.3 (Reduction to Fullness Testing). Let M ∈ Fhxim×n be any matrix. In addition, let U = (uij ) and V = (vij ) be generic matrices in new, non-commuting variables uij and vij , of dimensions r × m and n × r, respectively. Then, nc-rank(M ) ≥ r iff the matrix U M V is full. Proof. Since nc-rank(M ) ≥ r, there exists an r × r minor of M of full rank. Let Q be such a minor of M . W.l.o.g.,25 we can assume that Q is the [r] × [r] principal minor of M . Hence, we have that     Q M2 V1 , U M V = U1 U2 V2 M3 M4 where U1 and V1 are r × r matricesand  the others are matrices with the proper dimensions.  I r Letting U ′ = Ir 0 and V ′ = , the equality above becomes: 0 U ′ M V ′ = Q. As r ≥ nc-rank(U M V ) ≥ nc-rank(U ′ M V ′ ) = nc-rank(Q) = r, we obtain that U M V is full, as we wanted. Notice that the second inequality comes from the fact that rank does not increase after restrictions of the new variables. Notice that we do not know the rank nc-rank(M ) a priori. Therefore, our algorithm will try all possible values of r ∈ [n] and output the maximum value of r for which we find a full matrix. For each r × r matrix U M V , we can use the effective Higman’s trick to convert U M V into a s × s matrix with linear entries. With this matrix, we can use the truncated Gurvits’ algorithm to check whether the matrix we just obtained is full. Since we have this test, we will be able to output the correct rank. Algorithm 5 is the precise formulation of the procedure just described. Theorem A.4. Let M ∈ Qhxim×n be s.t. each entry of M is a polynomial computed by a formula of size bounded by s and bit complexity bounded by b. There exists a deterministic algorithm that finds the non-commutative rank of M in time poly(m, n, s, b). Proof. To prove this theorem, it is enough to show that Algorithm 5 is correct and it runs with the desired runtime. Without loss of generality, we can assume that n ≤ m. Therefore we have that nc-rank(M ) ≤ n. By Lemma A.3, if r ≤ nc-rank(M ), then matrix Mr will be of full rank (and therefore will not have a shrunk subspace, by Theorem 1.4). Since Mr = Ur M Vr , from the formulas computing the entries of M we obtain formulas of size at most 2smn computing the entries of Mr . Moreover, the bit complexities of these formulas will still be bounded by b, as multiplication by generic matrices do not mix any of the polynomials of M . 25 Notice that we can make the following assumption just to simplify notation. In actuality, we do not know where the full rank minor is located in M . 69 Input: M ∈ Qhxim×n s.t. each entry of M is a polynomial computed by a formula of size bounded by s and bit complexity bounded by b. Output: nc-rank(M ) 1. For 1 ≤ r ≤ min(m, n), let Ur and Vr be r × m and n × r generic matrices in new, non(r) (r) commuting variables uij , vij . 2. Let Mr = Ur M Vr . 3. Apply the effective Higman’s trick to Mr to obtain a matrix Nr with linear entries on the (r) (r) variables x1 , . . . , xm and uij , vij . 4. Use Algorithm G′ to test whether Nr is full rank. 5. Output the maximum value of r for which Nr is full rank. Algorithm 5: Noncommutative Rank Algorithm By Proposition A.2 and the fact that the size of the formulas computing the entries of Mr are bounded by 2smn, we have that Nr is a linear matrix of dimensions (k + r) × (k + r), where k ≤ 2s(mn)2 and the bit complexity of the coefficients bounded by b. Moreover, Nr = P (Mr ⊕ Ik )Q implies that Nr is full if, and only if, Mr is full, which is true if, and only if, nc-rank(M ) ≥ r. Now, by Theorem 1.1, we have a deterministic polynomial time algorithm to determine whether Nr is full rank. If r ≤ nc-rank(M ), Nr will be full, and the maximum such r will be exactly when r = nc-rank(M ). Therefore, by outputting the maximum r for which Nr we compute nc-rank(M ). This proves that our algorithm is correct. Notice that the runtime is polynomial in the input size, as we perform at most n applications of the Higman trick and of Algorithm G′ . This completes the proof. A.3 The Quantum Reduction Here we present a different reduction from computing non-commutative rank to fullness testing from a quantum viewpoint. We will only work with square matrices though. As Pwe saw, by Higman’s trick, we can assume the matrices to be linear. So we are given a matrix L = m i=1 xi Ai ∈ Mn (Fhxi). A combination of Theorems 1.4 and 1.17 shows that nc-rank(L) ≤ r iff the operator defined by A1 , . . . , Am is n − r-rank-decreasing. So we just want to check whether a completely positive operator is c-rank-decreasing and we will do this by using an algorithm for checking if an operator is rank-decreasing as a black box using the following lemma: Lemma A.5. Let T : Mn (C) → Mn (C) be a completely positive operator. Define an operator T : Mn+c−1 (C) → Mn+c−1 (C) as follows:     X1,1 X1,2 T (X1,1 ) + tr(X2,2 )In 0 T = X2,1 X2,2 0 tr(X1,1 )Ic−1 Here X1,1 , X1,2 , X2,1 , X2,2 are n × n, n × c − 1, c − 1 × n, c − 1 × c − 1 matrices respectively. Then T is completely positive and T is c-rank-decreasing iff T is rank-decreasing. Note that we are considering c ≤ n. 70 Proof. Pn+c−1A well known characterization due to Choi [Cho75] states that T is completely positive iff i,j=1 Ei,j ⊗ T (Ei,j ) is psd. Here Ei,j is the matrix with 1 at i, j position and 0 everywhere else. Now " #  T (E ) 0  i,j  1≤i=j≤n    0 I  c−1       " #    T (E ) 0  i,j  1 ≤ i, j ≤ n, i 6= j    0 0        # "   0 0 1 ≤ i ≤ n, n + 1 ≤ j ≤ n + c − 1 or n + 1 ≤ i ≤ n + c − 1, 1 ≤ j ≤ n T (Ei,j ) =  0 0        # "    I 0 n   n+1≤i=j ≤n+c−1    0 0        " #    0 0   n + 1 ≤ i, j ≤ n + c − 1, i 6= j   0 0 Pn+c−1 P From here it is easy to verify that i,j=1 Ei,j ⊗ T (Ei,j ) is psd given that ni,j=1 Ei,j ⊗ T (Ei,j ) is psd. Now suppose that T is rank-decreasing. This can only happen if X1,1 = 0 or X2,2 = 0, otherwise     X1,1 X1,2 T (X1,1 ) + tr(X2,2 )In 0 T = X2,1 X2,2 0 tr(X1,1 )Ic−1 is full rank. If X1,1 = 0, then  0 X1,2 X2,1 X2,2  can be psd (and hermitian) only if X1,2 = X2,1 = 0. In this case a c − 1 ranked matrix is mapped to rank n matrix. So X2,2 has to be zero. Then again by the psd condition X1,2 = X2,1 = 0. So     X1,1 0 T (X1,1 ) 0 T = 0 0 0 tr(X1,1 )Ic−1 and X1,1 6= 0 and Rank  X1,1 0 0 0  > Rank  T (X1,1 ) 0 0 tr(X1,1 )Ic−1  Hence Rank(T (X1,1 )) ≤ Rank(X1,1 ) − c. This proves one direction. Now suppose that T is c-rankdecreasing and Rank(T (X)) ≤ Rank(X) − c, then        X 0 T (X) 0 X 0 = Rank < Rank Rank T 0 0 0 tr(X)Ic−1 0 0 This proves the lemma. 71 Remark A.6. This seems to be the “quantum” analogue of obtaining a maximum matching oracle based on a perfect matching oracle: add c-1 dummy vertices to both sides of the bipartite graph and connect them to everything. Then the new graph has a perfect matching iff the original graph had a matching of size ≥ n − c + 1. Remark A.7. Here we didn’t specify a set of Kraus operators for the operator T which seem to be needed to run Algorithms 1 and 2 but Kraus operators can be obtained by looking at the eigenvectors Pn+c−1 of i,j=1 Ei,j ⊗ T (Ei,j ). Alternatively Algorithms 1 and 2 can also be interpreted as acting directly Pn+c−1 on the Choi-Jamiolkowski state of T i.e. i,j=1 Ei,j ⊗ T (Ei,j ). 72
0math.AC
INFORMS MATHEMATICS OF OPERATIONS RESEARCH arXiv:1503.02244v3 [math.OC] 22 Sep 2016 Vol. 00, No. 0, Xxxxx 0000, pp. 000–000 issn 0364-765X | eissn 1526-5471 | 00 | 0000 | 0001 doi 10.1287/xxxx.0000.0000 c 0000 INFORMS On the Asymptotic Optimality of Finite Approximations to Markov Decision Processes with Borel Spaces Naci Saldi Coordinated Science Laboratory, University of Illinois,Urbana, IL 61801-2307, USA. {[email protected]} Serdar Yüksel, Tamás Linder Department of Mathematics and Statistics, Queen’s University, Kingston, ON, Canada, K7L 3N6. {yuksel,[email protected]} Calculating optimal policies is known to be computationally difficult for Markov decision processes (MDPs) with Borel state and action spaces. This paper studies finite-state approximations of discrete time Markov decision processes with Borel state and action spaces, for both discounted and average costs criteria. The stationary policies thus obtained are shown to approximate the optimal stationary policy with arbitrary precision under quite general conditions for discounted cost and more restrictive conditions for average cost. For compact-state MDPs, we obtain explicit rate of convergence bounds quantifying how the approximation improves as the size of the approximating finite state space increases. Using information theoretic arguments, the order optimality of the obtained convergence rates is established for a large class of problems. We also show that, as a pre-processing step the action space can also be finitely approximated with sufficiently large number points; thereby, well known algorithms, such as value or policy iteration, Q-learning, etc., can be used to calculate near optimal policies. Key words : Markov decision processes, stochastic control, finite state approximation, quantization. MSC2000 subject classification : 93E20, 90C40, 90C39 OR/MS subject classification : Primary: Dynamic programming/optimal control, probability ; secondary: Infinite state, Markov processes 1. Introduction. In this paper, our goal is to study the finite-state approximation problem for computing near optimal policies for discrete time Markov decision processes (MDPs) with Borel state and action spaces, under discounted and average costs criteria. Although the existence and structural properties of optimal policies have been studied extensively in the literature, computing such policies is generally a challenging problem for systems with uncountable state spaces. This situation also arises in the fully observed reduction of a partially observed Markov decision process even when the original system has finite state and action spaces (see, e.g., Yu and Bertsekas [45]). As has been extensively studied in the literature (see, e.g., Chow and Tsitsiklis [11] and the literature review below), one way to compute approximately optimal solutions for such MDPs is to construct a reduced model with a new transition probability and a one-stage cost function by quantizing the state/action spaces, i.e., by discretizing them on a finite grid. We exhibit that under quite general continuity conditions on the one-stage cost function and the transition probability for the discounted cost and under some additional restrictions on the ergodicity properties of Markov chains induced by deterministic stationary policies for the average cost, the optimal policy for the approximating finite model applied to the original model has cost that converges to the optimal cost, as the discretization becomes finer. Moreover, under additional continuity conditions on the transition probability and the one stage cost function we also obtain bounds for a rate of 1 2 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS approximation in terms of the number of points used to discretize the state space, thereby providing a tradeoff between the computation cost and the performance loss in the system. In particular, we study the following two problems. (Q1) Under what conditions on the components of the MDP do the true costs corresponding to the optimal policies obtained from finite models converge to the optimal value function as the number of grid points goes to infinity? For this problem, we are only concerned with the convergence of the approximation; that is, we do not establish bounds for a rate of approximation. (Q2) Can we obtain explicit bounds on the performance loss due to the discretization in terms of the number of grid points if we strengthen the conditions sufficient in (Q1)? Combined with our recent works Saldi et al. [33, 34], where we investigated the asymptotic optimality of the quantization of action sets, the results in this paper lead to a constructive algorithm for obtaining approximately optimal solutions. First the action space is quantized with small error, and then the state space is quantized with small error, which results in a finite model that well approximates the original MDP. When the state space is compact, we also obtain rates of convergence for both approximations, and using information theoretic tools we establish that the obtained rates of convergence are order-optimal for a given class of MDPs. Since there exist various computational algorithms for finite-state Markov decision problems, the analysis in this paper can be considered to be constructive. Various methods have been developed to compute approximate value functions and near optimal policies. A partial list of these techniques is as follows: approximate dynamic programming, approximate value or policy iteration, simulation-based techniques, neuro-dynamic programming (or reinforcement learning), state aggregation, etc. For rather complete surveys of these techniques, we refer the reader to Fox [17], Whitt [42, 43], Langen [28], Bertsekas and Tsitsiklis [6], Ren and Krogh [32], Ortner [30], White [40, 41], Bertsekas [4], Dufour and Prieto-Rumeau [14, 15] and references therein. With the exception of Dufour and Prieto-Rumeau [15], Ortner [30], these papers in general study either the finite horizon cost or the discounted infinite horizon cost. Also, the majority of these results are for MDPs with discrete (i.e., finite or countable) state and action spaces, or a bounded one-stage cost function (e.g., Fox [17], Whitt [42, 43], Van Roy [37], White [40, 41], Cavazos-Cadena [9], Bertsekas and Tsitsiklis [6], Ren and Krogh [32], Ortner [30], Bertsekas [4]). Those that consider general state and action spaces (see, e.g., Dufour and Prieto-Rumeau [13, 14, 15], Bertsekas [4], Chow and Tsitsiklis [11]) assume in general Lipschitz type continuity conditions on the components of the control model, in order to provide a rate of convergence analysis for the approximation error. Some of the results only consider approximating the value function and do not provide a procedure to compute near optimal policies (e.g., Langen [28], Whitt [43], Dufour and Prieto-Rumeau [14]). Our paper differs from these results in the following ways: (i) we consider a general setup, where the state and action spaces are Borel (with the action space being compact), and the one-stage cost function is possibly unbounded, (ii) since we do not aim to provide rate of convergence result in the first problem (Q1), the continuity assumptions we impose on the components of the control model are weaker than the conditions imposed in prior works that considered general state and action spaces, (iii) we also consider the challenging average cost criterion under reasonable assumptions. The price we pay for imposing weaker assumptions in (Q1) is that we do not obtain explicit performance bounds in terms of the number of grid points used in the approximations. However, such bounds can be obtained under further assumptions on the transition probability and the one-stage cost functions; this is considered in problem (Q2) for compact-state MDPs. Our approach to solve problem (Q1) can be summarized as follows: (i) first, we obtain approximation results for the compact-state case, (ii) we find conditions under which a compact representation leads to near optimality for non-compact state MDPs, (iii) we prove the convergence of the finite-state models to non-compact models. As a by-product of this analysis, we obtain Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 3 compact-state-space approximations for an MDP with non-compact Borel state space. In particular, our findings directly lead to finite models if the state space is countable; similar problems in the countable context have been studied in the literature for the discounted cost; see Puterman [31, Section 6.10.2]. We note that the proposed method for solving the approximation problem for compact-state MDPs with the discounted cost is partly inspired by Van Roy [37]. Specifically, we generalize the operator proposed for an approximate value iteration algorithm in Van Roy [37] to uncountable state spaces. Then, unlike in Van Roy [37], we use this operator as a transition step between the original optimality operator and the optimality operator of the approximate model. In Ortner [30], a similar construction was given for finite state-action MDPs. Our method to obtain finite-state MDPs from the compact-state model can be regarded as a generalization of this construction. We note that a related work of Dufour and Prieto-Rumeau [15] develops a sequence of approximations using empirical distributions of an underlying probability measure with respect to which the transition probability of the MDP is absolutely continuous. By imposing Lipschitz type continuity conditions on the components of the control model, Dufour and Prieto-Rumeau [15] obtains a concentration inequality type upper bound on the accuracy of the approximation based on the Wasserstein distance of order 1 between the probability measure and its empirical estimate. These conditions are stronger than what we impose for the problem (Q1). We note that Dufour and Prieto-Rumeau [15] adopts a simulation based approximation leading to probabilistic guarantees on the approximation, whereas we adopt a quantization based approach leading to deterministic approximation guarantees. For a review of further simulation based methods, see e.g., Chang et al. [10], Jain and Varaiya [25]. The approach developed in the paper is also useful in networked control applications where transmission of real-valued actions to an actuator is not realistic when there is an information transmission constraint between a plant, a controller, and an actuator (see, e.g., Yüksel and Başar [46]). On the other hand, the elements of a finite action set can be transmitted across a finite capacity information channel. Even though the problem of optimal quantization for information transmission from a plant/sensor to a controller has been studied extensively (see, e.g. references in Yüksel and Başar [46]), these type of results appear to be new in the networked control literature when the problem of transmitting signals from a controller to an actuator is considered. Furthermore, tools from information theory allow for obtaining lower bounds on the approximation performance; using such an argument we show that the construction in this paper is order-optimal for a large class of models. The rest of the paper is organized as follows. In Section 2 we study the approximation problem (Q1) for MDPs with compact state space. In Section 3 an analogous approximation result is obtained for MDPs with non-compact state space. Discretization of the action space is considered in Section 4 for a general state space. In Section 5 we derive quantitative bounds on the approximation error in terms of the number of points used to discretize the state space for the compact-state case. In Section 6 the order optimality of the obtained bounds on the approximation errors is established. In Section 7 we present an example to numerically illustrate our results. Section 8 concludes the paper. 1.1. Notation and Conventions. For a metric space E, the Borel σ-algebra (the smallest σ-algebra that contains the open sets of E) is denoted by B (E). We let B(E) and Cb (E) denote the set of all bounded Borel measurable and continuous real functions on E, respectively. For any u ∈ Cb (E) or u ∈ B(E), let kuk := supe∈E |u(e)| which turns Cb (E) and B(E) into Banach spaces. Given any Borel measurable function w : E → [1, ∞) and any real valued Borel measurable function u on E, we define the w-norm of u as kukw := sup e∈E |u(e)| , w(e) 4 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS and let Bw (E) denote the Banach space of all real valued measurable functions u on E with finite w-norm; see Hernández-Lerma and Lasserre [22]. Let P (E) denote the set of all probability measures on E. A sequence {µn } of probability measures on E is said to convergeR weakly (resp., Rsetwise) (see Hernández-Lerma and Lasserre [23]) to a probability measure µ if E g(e)µn (de) → g(e)µ(de) for all g ∈ Cb (E) (resp., for all g ∈ B(E)). For any µ, ν ∈ P (E), the total variation disE tance between µ and ν, denoted as kµ − ν kT V , is equivalently defined as Z Z g(e)µ(de) − g(e)ν(de) . kµ − ν kT V := 2 sup |µ(D) − ν(D)| = sup D∈B(E) kgk≤1 E E Unless otherwise specified, the term ‘measurable’ will refer to Borel measurability in the rest of the paper. 1.2. Markov Decision Processes. described by a five-tuple A discrete-time Markov decision process (MDP) can be  X, A, {A(x) : x ∈ X}, p, c , where Borel spaces (i.e., Borel subsets of complete and separable metric spaces) X and A denote the state and action spaces, respectively. The collection {A(x) : x ∈ X} is a family of nonempty subsets A(x) of A, which give the admissible actions for the state x ∈ X. The stochastic kernel p( · |x, a) denotes the transition probability of the next state given that previous state-action pair is (x, a); see Hernández-Lerma and Lasserre [21]. Hence, it satisfies: (i) p( · |x, a) is an element of P (X) for all (x, a), and (ii) p(D | · , · ) is a measurable function from X × A to [0, 1] for each D ∈ B (X). The one-stage cost function c is a measurable function from X × A to R. In this paper, it is assumed that A(x) = A for all x ∈ X. Define the history spaces H0 = X and Ht = (X × A)t × X, t = 1, 2, . . . endowed with their product Borel σ-algebras generated by B (X) and B (A). A policy is a sequence π = {πt } of stochastic kernels on A given Ht . The set of all policies is denoted by Π. Let Φ denote the set of stochastic kernels ϕ on A given X, and let F denote the set of all measurable functions f from X to A. A randomized Markov policy is a sequence π = {πt } of stochastic kernels on A given X. A deterministic Markov policy is a sequence of stochastic kernels π = {πt } on A given X such that πt ( · |x) = δft (x) ( · ) for some ft ∈ F, where δz denotes the point mass at z. The set of randomized and deterministic Markov policies are denoted by RM and M, respectively. A randomized stationary policy is a constant sequence π = {πt } of stochastic kernels on A given X such that πt ( · |x) = ϕ( · |x) for all t for some ϕ ∈ Φ. A deterministic stationary policy is a constant sequence of stochastic kernels π = {πt } on A given X such that πt ( · |x) = δf (x) ( · ) for all t for some f ∈ F. The set of randomized and deterministic stationary policies are identified with the sets Φ and F, respectively. According to the Ionescu Tulcea theorem (see Hernández-Lerma and Lasserre [21]), an initial distribution µ on X and a policy π define a unique probability measure Pµπ on H∞ = (X × A)∞. The expectation with respect to Pµπ is denoted by Eπµ . If µ = δx , we write Pxπ and Eπx instead of Pδπx and Eπδx . The cost functions to be minimized in this paper are the β-discounted cost and the average cost, respectively given by J (π, x) = Eπx X ∞ t=0  β c(xt , at ) , t  T −1 1 π X c(xt , at ) . V (π, x) = lim sup Ex T →∞ T t=0 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 5 With this notation, the discounted and average value functions of the control problem are defined as J ∗ (x) := inf J (π, x), π∈Π V ∗ (x) := inf V (π, x). π∈Π A policy π ∗ is said to be optimal if J (π ∗ , x) = J ∗ (x) (or V (π ∗ , x) = V ∗ (x) for the average cost) for all x ∈ X. Under fairly mild conditions, the set F of deterministic stationary policies contains an optimal policy for discounted cost (see, e.g., Hernández-Lerma and Lasserre [21], Feinberg et al. [16]) and average cost optimal control problems (under somewhat stronger continuity/recurrence conditions, see, e.g., Feinberg et al. [16]). P∞ Remark 1.1. We note that the path-wise infinite sum t=0 β t c(xt , at ) may not be well-defined in the definition of J if c is only assumed to be measurable. However, further assumptions that will be imposed in later sections ensure that J is a well-defined function. 1.3. Auxiliary Results To avoid measurability problems associated with the operators that will be defined for the approximation problem in the discounted cost case, it is necessary to enlarge the set of functions on which these operators can act. To this end, in this section we review the notion of analytic sets and lower semi-analytic functions, and state the main results that will be used in the sequel to tackle these measurability problems. For a detailed treatment of analytic sets and lower semi-analytic functions, we refer the reader to Shreve and Bertsekas [36], Blackwell et al. [7], Kuratowski [27, Chapter 39], and Bertsekas and Shreve [3, Chapter 7]. Let N∞ be the set of sequences of natural numbers endowed with the product topology. With this topology, N∞ is a complete and separable metric space. A subset A of a Borel space E is said to be analytic if it is a continuous image of N∞ . Note that Borel sets are always analytic. A function g : E → R is said to be universally measurable if for any µ ∈ P (E), there is a Borel measurable function gµ : E → R such that g = gµ µ almost everywhere. It is said to be lower semianalytic if the set {e : g(e) < c} is analytic for any c ∈ R. Any Borel measurable function is lower semi-analytic and any lower semi-analytic function is universally measurable. The latter property implies that the integral of any lower semi-analytic function with respect to any probability measure is well defined. We let B l (E) and Bwl (E) denote the set of all bounded lower semi-analytic functions and lower semi-analytic functions with finite w-norm, respectively. Since any pointwise limit of a sequence of lower semi-analytic functions is lower semi-analytic (see Kuratowski [27, Theorem 1, p. 512]), (B l (E), k · k) and (Bwl (E), k · kw ) are Banach spaces. We now state the results that will be used in the sequel. Proposition 1.1. (Bertsekas and Shreve [3, Proposition 7.47, p. 179]) Suppose E1 and E2 are Borel spaces. Let g : E1 × E2 → R be lower semi-analytic. Then, g ∗ (e1 ) := inf e2 ∈E2 g(e1 , e2 ) is also lower semi-analytic. Proposition 1.2. (Bertsekas and Shreve [3, Proposition 7.48, p. 180]) Suppose E1 and E2 as in Proposition 1.1. Let g : E1 × E2 → R be lower semi-analytic and q(de2 |e1 ) be a stochastic kernel on E2 given E1 . Then, the function Z g(e2 )q(de2|e1 ). h(e1 ) := E2 is lower semi-analytic. 6 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 2. Finite State Approximations of MDPs with Compact State Space. In this section we consider (Q1) for the MDPs with compact state space. To distinguish compact-state MDPs from non-compact ones, the state space of the compact-state MDPs will be denoted by Z instead of X. We impose the assumptions below on the components of the Markov decision process; additional new assumptions will be made for the average cost problem in Section 2.2. Assumption 2.1. (a) The one-stage cost function c is in Cb (Z × A). (b) The stochastic kernel p( · |z, a) is weakly continuous in (z, a), i.e., for all z and a, p( · |zk , ak ) → p( · |z, a) weakly when (zk , ak ) → (z, a). (c) Z and A are compact. Before proceeding with the main results, we first describe the procedure used to obtain finitestate models. Let dZ denote the metric on Z. Since the state  space Z is assumed to be compact and n thus totally bounded, one can find a sequence {zn,i }ki=1 of finite grids in Z such that for all n, n≥1 min i∈{1,...,kn } dZ (z, zn,i ) < 1/n for all z ∈ Z. n The finite grid {zn,i }ki=1 is called an 1/n-net in Z. Let Zn := {zn,1 , . . . , zn,kn } and define function Qn mapping Z to Zn by Qn (z) := arg min dZ (z, zn,i ), zn,i ∈Zn where ties are broken so that Qn is measurable. In the literature, Qn is often called a nearest neighborhood quantizer with respect to distortion measure dZ ; see Gray and Neuhoff [19]. For each n n, Qn induces a partition {Sn,i }ki=1 of the state space Z given by Sn,i = {z ∈ Z : Qn (z) = zn,i }, with diameter diam(Sn,i ) := supz,y∈Sn,i dZ (z, y) < 2/n. Let {νn } be a sequence of probability measures on Z satisfying νn (Sn,i ) > 0 for all i, n. (2.1) We let νn,i be the restriction of νn to Sn,i defined by νn,i ( · ) := νn ( · ) . νn (Sn,i ) The measures νn,i will be used to define a sequence of finite-state MDPs, denoted as MDPn (n ≥ 1), to approximate the original model. To this end, for each n define the one-stage cost function cn : Zn × A → R and the transition probability pn on Zn given Zn × A by Z c(z, a)νn,i (dz), cn (zn,i , a) := ZSn,i Qn ∗ p( · |z, a)νn,i (dz), pn ( · |zn,i , a) := Sn,i where Qn ∗ p( · |z, a) ∈ P (Zn ) is the pushforward of the measure p( · |z, a) with respect to Qn ; that is,  Qn ∗ p(zn,j |z, a) = p Sn,j |z, a , for all zn,j ∈ Zn . For each n, we define MDPn as a Markov decision process with the following components: Zn is the state space, A is the action space, pn is the transition probability and cn is the one-stage cost function. History spaces, policies and cost functions are defined in a similar way as in the original model. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 7 2.1. Discounted Cost. Here we consider (Q1) for the discounted cost criterion with a discount factor β ∈ (0, 1). Throughout this section, it is assumed that Assumption 2.1 holds. Define the operator T on B(Z) by   Z (2.2) T u(z) := min c(z, a) + β u(y)p(dy |z, a) . a∈A Z In the literature T is called the Bellman optimality operator. It can be proved that under Assumption 2.1-(a)(b), T is a contraction operator with modulus β mapping Cb (Z) into itself (see Hernández-Lerma [20, Theorem 2.8, p. 23]); that is, T u ∈ Cb (Z) for all u ∈ Cb (Z) and kT u − T v k ≤ β ku − v k for all u, v ∈ Cb (Z). The following theorem is a widely known result in the theory of Markov decision processes (see again Hernández-Lerma [20, Theorem 2.8, p. 23]) which also holds without a compactness assumption on the state space. Theorem 2.1. operator T , i.e., The value function J ∗ is the unique fixed point in Cb (Z) of the contraction J ∗ = T J ∗. Furthermore, a deterministic stationary policy f ∗ is optimal if and only if it satisfies the optimality equation, i.e., Z ∗ ∗ (2.3) J (z) = c(z, f (z)) + β J ∗ (y)p(dy |z, f ∗ (z)). Z Finally, there exists a deterministic stationary policy f ∗ which is optimal, so it satisfies (2.3). Define, for all n ≥ 1, the operator Tn , which is the Bellman optimality operator for MDPn , by   kn X u(zn,j )pn (zn,j |zn,i , a) , Tn u(zn,i ) := min cn (zn,i , a) + β a∈A j=1 or equivalently, Tn u(zn,i ) = min a∈A Z Sn,i   Z c(z, a) + β û(y)p(dy |z, a) νn,i (dz), Z where u : Zn → R and û is the piecewise constant extension of u to Z given by û(z) = u ◦ Qn (z). For each n, under Assumption 2.1, Hernández-Lerma [20, Theorem 2.8, p. 23] implies the following: (i) Tn is a contraction operator with modulus β mapping B(Zn ) = Cb (Zn ) into itself, (ii) the fixed point of Tn is the value function Jn∗ of MDPn , and (iii) there exists an optimal stationary policy fn∗ for MDPn , which therefore satisfies the optimality equation. Hence, we have Jn∗ = Tn Jn∗ = Tn Jn (fn∗ , · ) = Jn (fn∗ , · ), where Jn denotes the discounted cost for MDPn . Let us extend the optimal policy fn∗ for MDPn to X by letting fˆn (z) = fn∗ ◦ Qn (z) ∈ F. The following theorem is the main result of this section. It states that the cost function of the policy fˆn converges to the value function J ∗ as n → ∞. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 8 fn∗ Theorem 2.2. The discounted cost of the policy fˆn , obtained by extending the optimal policy of MDPn to Z, converges to the optimal value function J ∗ of the original MDP lim kJ (fˆn , · ) − J ∗ k = 0. n→∞ Hence, to find a near optimal policy for the original MDP, it is sufficient to compute the optimal policy of MDPn for sufficiently large n, and then extend this policy to the original state space. To prove Theorem 2.2 we need a series of technical results. We first define an operator T̂n on B l (Z) by extending Tn to B l (Z):   Z Z (2.4) c(x, a) + β u(y)p(dy |x, a) νn,in (z) (dx), T̂n u(z) := inf a∈A Sn,in (z) Z where in : Z → {1, . . . , kn } maps z to the index of the partition {Sn,i } it belongs to. To see that this operator is well defined, let the stochastic kernel rn (dx|z) on Z given Z be defined as rn (dx|z) := kn X νn,i (dx)1Sn,i (z), i=1 where 1B denotes the indicator function of the set B. Then, we can write the right hand side of (2.4) as  Z  Z inf c(x, a) + β u(y)p(dy |x, a) rn (dx|z). a∈A Z Z Therefore, by Propositions 1.1 and 1.2, we can conclude that T̂n maps B l (Z) into B l (Z). Furthermore, it is a contraction operator with modulus β which can be shown using Hernández-Lerma [20, Proposition A.2, p. 122]. Hence, it has a unique fixed point Jˆn∗ that belongs to B(Z), and this fixed point must be constant over the sets Sn,i because of the averaging operation on each Sn,i . Furthermore, since T̂n (u ◦ Qn ) = (Tn u) ◦ Qn for all u ∈ B(Zn ), we have T̂n (Jn∗ ◦ Qn ) = (Tn Jn∗ ) ◦ Qn = Jn∗ ◦ Qn . Hence, the fixed point of T̂n is the piecewise constant extension of the fixed point of Tn , i.e., Jˆn∗ = Jn∗ ◦ Qn . Remark 2.1. In the rest of this paper, when we take the integral of any function with respect to νn,in (z) , it is tacitly assumed that the integral is taken over all set Sn,in (z) . Hence, we can drop Sn,in (z) in the integral for the ease of notation. We now define another operator Fn on B l (Z) by simply interchanging the order of the infimum and the integral in (2.4), i.e.,   Z Z Fn u(z) := inf c(x, a) + β u(y)p(dy |x, a) νn,in (z) (dx) a∈A Z = Γn T u(z), where Γn u(z) := Z u(x)νn,in (z) (dx). Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 9 We note that Fn is the extension (to infinite state spaces) of the operator defined in Van Roy [37, p. 236] for the proposed approximate value iteration algorithm. However, unlike in Van Roy [37], Fn will serve here as an intermediate point between T and T̂n (or Tn ) to solve (Q1) for the discounted cost. To this end, we first note that Fn is a contraction operator on B l (Z) with modulus β. Indeed it is clear that Fn maps B l (Z) into itself by Propositions 1.1 and 1.2. Furthermore, for any u, v ∈ B l (Z), we clearly have kΓn u − Γn v k ≤ ku − v k. Hence, since T is a contraction operator on B l (Z) with modulus β, Fn is also a contraction operator on B l (Z) with modulus β. Remark 2.2. Since we only assume that the stochastic kernel p is weakly continuous, it is not true that T̂n and Fn map B(Z) into itself (see Hernández-Lerma and Lasserre [21, Proposition D.5, p. 182]). This is the point where we need to enlarge the set of functions on which these operators act. The following theorem states that the fixed point, say u∗n , of Fn converges to the fixed point J ∗ (i.e., the value function) of T as n goes to infinity. Note that although T is originally defined on Cb (Z), it can be proved that T , when acting on B l (Z), maps B l (Z) into itself. Theorem 2.3. If u∗n is the unique fixed point of Fn , then limn→∞ ku∗n − J ∗ k = 0. The proof of Theorem 2.3 requires two lemmas. Lemma 2.1. For any u ∈ B l (Z), we have ku − Γn uk ≤ 2 inf ku − Φr k, r∈Zkn n where Φr (z) = Σki=1 ri 1Sn,i (z), r = (r1 , · · · , rkn ). Proof. Fix any r ∈ Zkn . Then, using the identity Γn Φr = Φr , we obtain ku − Γn uk ≤ ku − Φr k + kΦr − Γn uk = ku − Φr k + kΓn Φr − Γn uk ≤ ku − Φr k + kΦr − uk. Since r is arbitrary, this completes the proof.  Notice that because of the operator Γn , the fixed point u∗n of Fn must be constant over the sets Sn,i . We use this property to prove the next lemma. Lemma 2.2. We have ku∗n − J ∗ k ≤ 2 inf kJ ∗ − Φr k. 1 − β r∈Zkn Proof. Note that Γn u∗n = u∗n since u∗n is constant over the sets Sn,i . Then, we have ku∗n − J ∗ k ≤ ku∗n − Γn J ∗ k + kΓn J ∗ − J ∗ k = kFn u∗n − Γn T J ∗ k + kΓn J ∗ − J ∗ k = kΓn T u∗n − Γn T J ∗ k + kΓn J ∗ − J ∗ k (by the definition of Fn ) ≤ kT u∗n − T J ∗ k + kΓn J ∗ − J ∗ k (since kΓn u − Γn v k ≤ ku − v k) ≤ β ku∗n − J ∗ k + kΓn J ∗ − J ∗ k. 1 kΓn J ∗ − J ∗ k. The result now follows from Lemma 2.1.  Hence, we obtain ku∗n − J ∗ k ≤ 1−β Proof of Theorem 2.3. Recall that since Z is compact, the function J ∗ is uniformly continuous and diam(Sn,i ) < 2/n for all i = 1, . . . , kn . Hence, limn→∞ inf r∈Zkn kJ ∗ − Φr k = 0 which completes the proof in view of Lemma 2.2.  The next step is to show that the fixed point Jˆn∗ of T̂n converges to the fixed point J ∗ of T . To this end, we first prove the following result. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 10 For any u ∈ Cb (Z), kT̂n u − Fn uk → 0 as n → ∞. R Proof. Note that since Z u(x)p(dx|y, a) is continuous as a function of (y, a) by Assumption 2.1(b), it is sufficient to prove that for any l ∈ Cb (Z × A) Z Z min l(y, a)νn,in (z) (dy) − min l(y, a)νn,in (z) (dy) a a Z Z := sup min l(y, a)νn,in (z) (dy) − min l(y, a)νn,in (z) (dy) → 0 Lemma 2.3. a a z∈Z S ∞ as n → ∞. Fix any ε > 0. Define {zi }∞ i=1 := n Zn and let {ai }i=1 be a sequence in A such that mina∈A l(zi , a) = l(zi , ai ); such ai exists for each zi because l(zi , · ) is continuous and A is compact. Define g(y) := mina∈A l(y, a), which can be proved to be continuous, and therefore uniformly continuous since Z is compact. Thus by the uniform continuity of l, there exists δ > 0 such that dZ×A (y, a), (y ′ , a′ ) < δ implies |g(y) − g(y ′)| < ε/2 and |l(y, a) − l(y ′ , a′ )| < ε/2. Choose n0 such that 2/n0 < δ. Then for all n ≥ n0 , maxi∈{1,...,kn } diam(Sn,i ) < 2/n < δ. Hence, for all y ∈ Sn,i we have |l(y, ai ) − mina∈A l(y, a)| ≤ |l(y, ai ) − l(zi , ai )| + | mina∈A l(zi , a) − mina∈A l(y, a)| = |l(y, ai ) − l(zi , ai )| + |g(zi ) − g(y)| < ε. This implies Z Z min l(y, a)νn,in (z) (dy) − min l(y, a)νn,in (z) (dy) a a Z Z ≤ l(y, ai )νn,in (z) (dy) − min l(y, a)νn,in (z) (dy) a Z ≤ sup sup l(y, ai ) − min l(y, a) νn,in (z) (dy) < ε. z∈Z This completes the proof. a y∈Sn,in (z)  The fixed point Jˆn∗ of T̂n converges to the fixed point J ∗ of T . Theorem 2.4. Proof. We have kJˆn∗ − J ∗ k ≤ kT̂n Jˆn∗ − T̂n J ∗ k + kT̂n J ∗ − Fn J ∗ k + kFn J ∗ − Fn u∗n k + kFn u∗n − J ∗ k ≤ β kJˆn∗ − J ∗ k + kT̂n J ∗ − Fn J ∗ k + β kJ ∗ − u∗n k + ku∗n − J ∗ k. Hence kJˆn∗ − J ∗ k ≤ kT̂n J ∗ − Fn J ∗ k + (1 + β)kJ ∗ − u∗n k . 1−β The theorem now follows from Theorem 2.3 and Lemma 2.3.  Recall the optimal stationary policy fn∗ for MDPn and its extension fˆn (z) = fn∗ ◦ Qn (z) to Z. Since Jˆn∗ = Jn∗ ◦ Qn , it is straightforward to prove that fˆn is the optimal selector of T̂n Jˆn∗ ; that is, T̂n Jˆn∗ = Jˆn∗ = T̂fˆn Jˆn∗ , where T̂fˆn is defined as T̂fˆn u(z) := Z  c(x, fˆn (x)) + β Z Z  ˆ u(y)p(dy |x, fn (x)) νn,in (z) (dx). Define analogously Tfˆn u(z) := c(z, fˆn (z)) + β Z u(y)p(dy |z, fˆn (z)). Z Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 11 It can be proved that both T̂fˆn and Tfˆn are contraction operators on B l (Z) with modulus β, and it is known that the fixed point of Tfˆn is the true cost function of the stationary policy fˆn (i.e., J (fˆn , z)). Lemma 2.4. kT̂fˆn u − Tfˆn uk → 0 as n → ∞, for any u ∈ Cb (Z). RProof. The statement follows from the uniform continuity of the function c(z, a) + β Z u(y)p(dy |z, a) and the fact that fˆn is constant over the sets Sn,i .  Now, we prove the main result of this section. Proof of Theorem 2.2. We have kJ (fˆn , · ) − J ∗ k ≤ kTfˆn J (fˆn , · ) − Tfˆn J ∗ k + kTfˆn J ∗ − T̂fˆn J ∗ k + kT̂fˆn J ∗ − T̂fˆn Jˆn∗ k + kJˆn∗ − J ∗ k ≤ β kJ (fˆn , · ) − J ∗ k + kTfˆn J ∗ − T̂fˆn J ∗ k + β kJ ∗ − Jˆn∗ k + kJˆn∗ − J ∗ k. Hence, we obtain kJ (fˆn , · ) − J ∗ k ≤ kTfˆn J ∗ − T̂fˆn J ∗ k + (1 + β)kJˆn∗ − J ∗ k . 1−β The result follows from Lemma 2.4 and Theorem 2.4.  2.2. Average Cost. In this section we impose some new conditions on the components of the original MDP in addition to Assumption 2.1 to solve (Q1) for the average cost. A version of the first two conditions was imposed in Vega-Amaya [38], Jaśkiewicz and Nowak [26] to show the existence of the solution to the Average Cost Optimality Equation (ACOE) and the optimal stationary policy. Assumption 2.2. Suppose Assumption 2.1 holds with item (b) replaced by condition (f ) below. In addition, there exist a non-trivial finite measure ζ on Z, a nonnegative measurable function θ on Z × A, and a constant λ ∈ (0, 1) such that for all (z, a) ∈ Z × A (d) p(B |z, a) ≥ ζ(B)θ(z, a) for all B ∈ B (Z), (e) 1−λ ≤ θ(z, a), ζ(Z) (f ) The stochastic kernel p( · |z, a) is continuous in (z, a) with respect to the total variation distance. Throughout this section, it is assumed that Assumption 2.2 holds. Observe that any deterministic stationary policy f defines a stochastic kernel p( · |z, f (z)) on Z given Z which is the transition probability of the Markov chain {zt }∞ t=1 (state process) induced by f . For any t ≥ 1, let us write pt ( · |z, f (z)) to denote the t-step transition probability of this Markov chain given the initial point z; that is, pt ( · |z, f (z)) is recursively defined as Z t+1 p ( · |z, f (z)) = p( · |x, f (x))pt(dx|z, f (z)). Z To study average cost optimal control problems, it is in general assumed that there exists an invariant distribution under any stationary control policy, so that the average cost of any stationary policy can be written as an integral of the one-stage cost function with respect to this invariant distribution. With this representation, one can then deduce the optimality of stationary policies using the linear programming or the convex analytic methods (see Hernández-Lerma and Lasserre [21], Borkar [8]). However, to solve the approximation problem for the average cost, we need, in addition to the existence of an invariant distribution, the convergence of t-step transition probabilities to the invariant distribution, at some rate, for both the original and the reduced problems. Therefore, it is crucial to impose proper conditions on the original model so that, on the one hand, 12 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS they guarantee the convergence of t-step transition probabilities to the invariant distribution for all stationary policies for the original system and, on the other hand, one is able to show that similar conditions are satisfied by the reduced problems. Conditions (d) and (e) in Assumption 2.2 are examples of such conditions which were also used in the literature extensively. Indeed, if we define the weight function w ≡ 1, then condition (e) corresponds to the so-called ‘drift inequality’: for all (z, a) ∈ Z × A Z w(y)p(dy |z, a) ≤ λw(z) + ζ(w)θ(z, a), Z and condition (d) corresponds to the so-called ‘minorization’ condition, both of which were used in literature for studying geometric ergodicity of Markov chains (see Hernández-Lerma and Lasserre [22], Meyn and Tweedie [29], and references therein). The following theorem is a consequence of Vega-Amaya [38, Theorem 3.3], Gordienko and Hernandez-Lerma [18, Lemma 3.4], and Jaśkiewicz and Nowak [26, Theorem 3], which also holds with Assumption 2.2-(f) replaced by Assumption 2.1-(b). Theorem 2.5. For any f ∈ F, the stochastic kernel p( · |z, f (z)) is positive Harris recurrent with unique invariant probability measure µf . Therefore, we have Z V (f, z) = c(z, f (z))µf (dz) =: ρf . Z The Markov chain {zt }∞ t=1 induced by f is geometrically ergodic; that is, there exist positive real numbers R and κ < 1 such that for every z ∈ Z sup kpt ( · |z, f (z)) − µf kT V ≤ Rκt , f ∈F where R and κ continuously depend on ζ(Z) and λ. Finally, there exist f ∗ ∈ F and h∗ ∈ B(Z) such that the triplet (h∗ , f ∗ , ρf ∗ ) satisfies the average cost optimality equality (ACOE), i.e.,   Z ∗ ∗ ρf ∗ + h (z) = min c(z, a) + h (y)p(dy |z, a) a∈A Z Z ∗ = c(z, f (z)) + h∗ (y)p(dy |z, f ∗(z)), Z and therefore, inf V (π, z) =: V ∗ (z) = ρf ∗ . π∈Π For each n, define the one-stage cost function bn : Z × A → [0, ∞) and the stochastic kernel qn on Z given Z × A as Z bn (z, a) := c(x, a)νn,in (z) (dx), Z qn ( · |z, a) := p( · |x, a)νn,in (z) (dx). Observe that cn (i.e., the one stage cost function of MDPn ) is the restriction of bn to Zn , and pn (i.e., the stochastic kernel of MDPn ) is the pushforward of the measure qn with respect to Qn ; that is, cn (zn,i , a) = bn (zn,i , a) for all i = 1, . . . , kn and pn ( · |zn,i , a) = Qn ∗ qn ( · |zn,i , a). \n be defined as a Markov decision process with the following components: For each n, let MDP Z is the state space, A is the action space, qn is the transition probability, and c is the one-stage Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 13 ^n be defined as a Markov decision process with the following cost function. Similarly, let MDP components: Z is the state space, A is the action space, qn is the transition probability, and bn is the one-stage cost function. History spaces, policies and cost functions are defined in a similar \n and MDP ^n are used as transitions between the original MDP way as before. The models MDP and MDPn in a similar way as the operators Fn and T̂n were used as transitions between T and Tn for the discounted cost. We note that a similar technique was used in the proof of Ortner [30, Theorem 2], which studied the approximation problem for finite state-action MDPs. In Ortner [30] the one-stage cost function is first perturbed and then the transition probability is perturbed. We first perturb the transition probability and then the cost function. However, our proof method is otherwise quite different from that of Ortner [30, Theorem 2] since Ortner [30] assumes finite state and action spaces. ^n reveals that its Bellman optimality operator is essenWe note that a careful analysis of MDP ^n is the piecewise constant extension of tially the operator T̂n . Hence, the value function of MDP the value function of MDPn for the discounted cost. A similar conclusion will be made for the average cost in Lemma 2.5. First, notice that if we define Z θn (z, a) := θ(y, a)νn,in(z) (dy), ζn := Qn ∗ ζ (i.e., pushforward of ζ with respect to Qn ), \n and MDP ^n satisfy Assumption 2.2then it is straightforward to prove that for all n, both MDP (d),(e) when θ is replaced by θn , and Assumption 2.2-(d),(e) is true for MDPn when θ and ζ are replaced by the restriction of θn to Zn and ζn , respectively. \n , MDP ^n , and MDPn for all n. Hence, Theorem 2.5 holds (with the same R and κ) for MDP \n , MDP ^n , and MDPn Therefore, we denote by fˆn∗ , f˜n∗ and fn∗ the optimal stationary policies of MDP n n n with the corresponding average costs ρ̂fˆ∗ , ρ̃f˜∗ and ρfn∗ , respectively. n n Furthermore, we also write ρ̂nf , ρ̃nf , and ρnf to denote the average cost of any stationary policy f \n , MDP ^n , and MDPn , respectively. The corresponding invariant probability measures are for MDP also denoted in a similar manner, with µ replacing ρ. ^n are not very different. The following lemma essentially says that MDPn and MDP Lemma 2.5. The stationary policy given by the piecewise constant extension of the optimal ] n with the same cost function ρnf∗ . Hence, policy fn∗ of MDPn to Z (i.e., fn∗ ◦ Qn ) is optimal for MDP n f˜n∗ = fn∗ ◦ Qn and ρ̃nf˜∗ = ρnfn∗ . n Proof. Note that by Theorem 2.5 there exists h∗n ∈ B(Zn ) such that the triplet (h∗n , fn∗ , ρnfn∗ ) satisfies the ACOE for MDPn . But it is straightforward to show that the triplet (h∗n ◦ Qn , fn∗ ◦ ^n . By Gordienko and Hernandez-Lerma [18, Lemma 5.2], Qn , ρnfn∗ ) satisfies the ACOE for MDP ^n with cost function ρnf∗ . Hence this implies that fn∗ ◦ Qn is an optimal stationary policy for MDP n f˜∗ = f ∗ ◦ Qn and ρ̃n˜∗ = ρn∗ .  n n fn fn The following theorem is the main result of this section. It states that if one applies the piecewise constant extension of the optimal stationary policy of MDPn to the original MDP, the resulting cost function will converge to the value function of the original MDP. ] n , obtained by extending the Theorem 2.6. The average cost of the optimal policy f˜n∗ for MDP ∗ optimal policy fn of MDPn to Z, converges to the optimal value function J ∗ = ρf ∗ of the original MDP, i.e., lim |ρf˜n∗ − ρf ∗ | = 0. n→∞ Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 14 Hence, to find a near optimal policy for the original MDP, it is sufficient to compute the optimal policy of MDPn for sufficiently large n, and then extend this policy to the original state space. To show the statement of Theorem 2.6 we will prove a series of auxiliary results. Lemma 2.6. For all t ≥ 1 we have lim sup n→∞ (y,f )∈Z×F pt ( · |y, f (y)) − qnt ( · |y, f (y)) TV = 0. Proof. We will prove the lemma by induction. Note that if one views the stochastic kernel p( · |z, a) as a mapping from Z × A to P (Z), then Assumption 2.2-(f) implies that this mapping is continuous, and therefore uniformly continuous, when P (Z) is equipped with the metric induced by the total variation distance. For t = 1 the claim holds by the following argument: p( · |y, f (y)) − qn( · |y, f (y)) sup (y,f )∈Z×F TV := 2 ≤2 sup p(D |y, f (y)) − qn(D |y, f (y)) sup (y,f )∈Z×F D∈B(Z)Z sup sup (y,f )∈Z×F Z D∈B(Z) sup ≤ p(D |y, f (y)) − p(D |z, f (y)) νn,in (y) (dz) p( · |y, f (y)) − p( · |z, f (y)) TV νn,in (y) (dz) p( · |y, a) − p( · |z, a) TV . (y,f )∈Z×F ≤ sup sup y∈Z (z,a)∈Sn,in (y) ×A As the mapping p( · |z, a) : Z × A → P (Z) is uniformly continuous with respect to the total variation distance and maxn,i diam(Sn,i ) → 0 as n → ∞, the result follows. Assume the claim is true for t ≥ 1. Then we have sup pt+1 ( · |y, f (y)) − qnt+1( · |y, f (y)) T V Z Z t+1 := sup sup g(x)p (dx|y, f (y)) − g(x)qnt+1 (dx|y, f (y)) (y,f )∈Z×F kgk≤1 Z Z Z Z Z Z t g(x)p(dx|z, f (z))qnt (dz |y, f (y)) g(x)p(dx|z, f (z))p (dz |y, f (y)) − ≤ sup sup (y,f )∈Z×F kgk≤1 Z Z  Z ZZ Z Z Z t t g(x)qn (dx|z, f (z))qn(dz |y, f (y)) g(x)p(dx|z, f (z))qn(dz |y, f (y)) − + sup (y,f )∈Z×F ≤ sup (y,f )∈Z×F kgk≤1 t Z Z Z p ( · |y, f (y)) − qnt ( · |y, f (y)) + sup TV (z,f )∈Z×F Z p( · |z, f (z)) − qn( · |z, f (z)) TV (2.5) where the last inequality follows from the of the total variation distance: for R following property R any h ∈ B (Z) and µ, ν ∈ P (Z) we have Z h(z)µ(dz) − Z h(z)ν(dz) ≤ khkkµ − ν kT V . By the first step of the proof and the induction hypothesis, the last term converges to zero as n → ∞. This completes the proof.  Remark 2.3. This is the point where we need the continuity of the transition probability p with respect to the total variation distance. If we assume that the stochastic kernel p is only weakly or setwise continuous, then it does not seem possible to prove a result similar to Lemma 2.6 for the weak and the setwise topologies. Using Lemma 2.6 we prove the following result. Lemma 2.7. We have supf ∈F |ρ̂nf − ρf | → 0 as n → ∞, where ρ̂nf is the cost function of the policy [ n and ρf is the cost function of the policy f for the original MDP. f for MDP Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 15 Proof. For any t ≥ 1 and y ∈ Z we have Z Z n n sup |ρ̂f − ρf | = sup c(z, f (z))µ̂f (dz) − c(z, f (z))µf (dz) f ∈F f ∈F ZZ ZZ n ≤ sup c(z, f (z))µ̂f (dz) − c(z, f (z))qnt (dz |y, f (y)) f ∈F Z Z Z Z t + sup c(z, f (z))qn(dz |y, f (y)) − c(z, f (z))pt (dz |y, f (y)) f ∈F Z Z Z Z t + sup c(z, f (z))p (dz |y, f (y)) − c(z, f (z))µf (dz) f ∈F ≤ 2Rκt kck + kck sup (y,f )∈Z×F Z qnt ( · |y, f (y)) − pt( · |y, f (y)) Z TV (by Theorem 2.5-(ii)), where R and κ are the constants in Theorem 2.5. Then, the result follows from Lemma 2.6.  \n converges to the value function The following theorem states that the value function of MDP of the original MDP. Lemma 2.8. We have |ρ̂nfˆ∗ − ρf ∗ | → 0 as n → ∞. n Proof. Notice that |ρ̂nfˆ∗ − ρf ∗ | = max(ρ̂nfˆ∗ − ρf ∗ , ρf ∗ − ρ̂nfˆ∗ ) n n n ≤ max(ρ̂nf∗ − ρf ∗ , ρfˆn∗ − ρ̂nfˆ∗ ) n ≤ sup |ρ̂nf − ρf |. f Then, the result follows from Lemma 2.7. Lemma 2.9. We have supf ∈F |ρ̃nf − ρ̂nf |  → 0 as n → ∞. Proof. It is straightforward to show that bn → c uniformly. Since the probabilistic structure of ^n and MDP \n are the same (i.e., µ̂nf = µ̃nf for all f ), we have MDP Z Z n n n sup |ρ̃f − ρ̂f | = sup bn (z, f (z))µ̂f (dz) − c(z, f (z))µ̂nf(dz) f ∈F f ∈F Z Z Z ≤ sup |bn (z, f (z)) − c(z, f (z))|µ̂nf(dz) f ∈F Z ≤ kbn − ck. This completes the proof.  ^n and MDP \n The next lemma states that the difference between the value functions of MDP converges to zero. Lemma 2.10. We have |ρ̃nf˜∗ − ρ̂nfˆ∗ | → 0 as n → ∞. n n Proof. See the proof of Lemma 2.8.  ^n to MDP \n , then the The following result states that if we apply the optimal policy of MDP \ resulting cost converges to the value function of MDPn . Lemma 2.11. We have |ρ̂nf˜∗ − ρ̂nfˆ∗ | → 0 as n → ∞. n n Proof. Since |ρ̂nf˜∗ − ρ̂nfˆ∗ | ≤ |ρ̂nf˜∗ − ρ̃nf˜∗ | + |ρ̃nf˜∗ − ρ̂nfˆ∗ |, then the result follows from Lemmas 2.9 and n n n n n n 2.10.  Now, we are ready to prove the main result of this section. Proof of Theorem 2.6. We have |ρf˜n∗ − ρf ∗ | ≤ |ρf˜n∗ − ρ̂nf˜∗ | + |ρ̂nf˜∗ − ρ̂nfˆ∗ | + |ρ̂nfˆ∗ − ρnf∗ |. The result now n n n n follows from Lemmas 2.7, 2.11 and 2.8.  Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 16 3. Finite State Approximations of MDPs with Non-Compact State Space. In this section we consider (Q1) for noncompact state MDPs with unbounded one-stage cost. To solve (Q1), we use the following strategy: (i) first, we define a sequence of compact-state MDPs to approximate the original MDP, (ii) we use Theorems 2.2 and 2.6 to approximate the compact-state MDPs by finite-state models, and (iii) we prove the convergence of the finite-state models to the original model. In fact, steps (ii) and (iii) will be accomplished simultaneously. We impose the assumptions below on the components of the Markov decision process; additional assumptions will be imposed for the average cost problem. With the exception of the local compactness of the state space, these are the usual assumptions used in the literature for studying Markov decision processes with unbounded cost. Assumption 3.1. (a) The one-stage cost function c is continuous. (b) The stochastic kernel p( · |x, a) is weakly continuous in (x, a). (c) X is locally compact and A is compact. (d) There exist nonnegative real numbers M and α ∈ [1, β1 ), and a continuous weight function w : X → [1, ∞) such that for each x ∈ X, we have sup |c(x, a)| ≤ M w(x), sup a∈A and R X Z (3.1) a∈A w(y)p(dy |x, a) ≤ αw(x), (3.2) X w(y)p(dy |x, a) is continuous in (x, a). Since X is locally compact separable metric S∞ space, there exists a nested sequence of compact sets {Kn } such that Kn ⊂ int Kn+1 and X = n=1 Kn Aliprantis and Border [1, Lemma 2.76, p. 58]. Lemma 3.1. For any compact subset K of X and for any ε > 0, there exists a compact subset Kε of X such that Z w(y)p(dy |x, a) < ε, sup (x,a)∈K×A Kεc where D c denotes the complement of the set D. Proof. We prove the lemma by contradiction. Assume the claim is wrong. Since every compact subset K of X is a subset of Kn for some n, the negation of the above lemma is equivalent to the following statement: there exists a compact set K ⊂ X and ε > 0 such that for all n ≥ 1 we have Z w(y)p(dy |x, a) ≥ ε. sup (x,a)∈K×A c Kn  Note that w is integrable with respect to the probability measures in the set p( · |x, a) : (x, a) ∈ K × A since Z w(y)p(dy |x, a) ≤ α sup w(x) < ∞. sup (x,a)∈K×A X x∈K R For each n, we prove that (int Kn )c w(y)p(dy |x, a) is an upper semi-continuous function on K × A. R function of (x, Recall that X w(y)p(dy |x, a) is a continuous R a). Let (xk , ak ) → (x, a) in K × A. Then R p( · |xk , ak ) → p( · |x, a) weakly and X w(y)p(dy |xk , ak ) → X w(y)p(dy |x, a) by our assumption. If we Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 17 take fk = gk = f = g = w in Serfozo [35, Theorem 3.3], this result implies that νk ( · ) → ν( · ) weakly, where Z νk (D) = w(y)p(dy |xk , ak ) ZD w(y)p(dy |x, a), ν(D) = D for all D ∈ B (X). Then, by Bartoszynski [2, Theorem A] we have Z  w(y)p(dy |x, a) := ν (int Kn )c (int Kn )c Z  ≥ lim sup νk (int Kn )c := lim sup k→∞ k→∞ w(y)p(dy |xk , ak ). (int Kn )c R Hence, (int Kn )c w(y)p(dy |x, a) is upper semi-continuous. Since K × A is compact, there exists (xn , an ) ∈ K × A such that Z Z w(y)p(dy |xn , an ). w(y)p(dy |x, a) = sup (x,a)∈K×A (int Kn )c (int Kn )c The sequence {(xn , an )} (being a sequence in a compact set K × A) has an converging subsequence {(xnk , ank )} with the limit (x, a) ∈ K × A. Then, for all m ≥ 2, we have Z Z w(y)p(dy |x, a) w(y)p(dy |x, a) ≥ c (int Km )c Km−1 Z ≥ lim sup w(y)p(dy |xnk , ank ) k→∞ Z(int Km )c w(y)p(dy |xnk , ank ) ≥ ε, ≥ lim sup k→∞ (int Knk )c where the third inequality follows from the fact that (int Km )c ⊃ (int Knk )c for k sufficiently large. But this is a contradiction because w is p( · |x, a) integrable.  Let {νn } be a sequence of probability measures such that for each n ≥ 1, νn ∈ P (Knc ) and Z w(x)νn (dx) < ∞, (3.3) γn := c Kn   Z  γn − w(y) p(dy |x, a) < ∞. (3.4) γ = sup τn := sup max 0, sup n n (x,a)∈X×A c Kn For example, such probability measures can be constructed by choosing xn ∈ Knc such that w(xn ) < inf x∈Knc w(x) + n1 and letting νn ( · ) = δxn ( · ). Similar to the finite-state MDP construction in Section 2, we define a sequence of compactstate MDPs, denoted as c-MDPn , to approximate the original model. To this end, for each n let Xn = Kn ∪ {∆n }, where ∆n ∈ Knc is a so-called pseudo-state. We define the transition probability pn on Xn given Xn × A and the one-stage cost function cn : Xn × A → [0, ∞) by    ∩ Kn |x, a + p Knc |x, a δ∆n , if x ∈ Kn p ·   R   pn ( · |x, a) =  K c p · ∩ Kn |z, a + p Knc |z, a δ∆n νn (dz), if x = ∆n , ( n c(x, a), if x ∈ Kn cn (x, a) = R c(z, a)νn (dz), if x = ∆n . Kc n Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 18 With these definitions, c-MDPn is defined as a Markov decision process with the components  Xn , A, pn , cn . History spaces, policies, and cost functions are defined in a similar way as in the original model. Let Πn , Φn , and Fn denote the set of all policies, randomized stationary policies and deterministic stationary policies of c-MDPn , respectively. For each policy π ∈ Πn and initial distribution µ ∈ P (Xn ), we denote the cost functions for c-MDPn by Jn (π, µ) and Vn (π, µ). To obtain the main result of this section, we introduce, for each n, another MDP, denoted by MDPn , with the components X, A, qn , bn ) where ( p( · |x, a), if x ∈ Kn qn ( · |x, a) = R p · |z, a)νn (dz), if x ∈ Knc , ( Knc c(x, a), if x ∈ Kn bn (x, a) = R c(z, a)νn (dz), if x ∈ Knc . Kc n For each policy π ∈ Π and initial distribution µ ∈ P (X), we denote the cost functions for MDPn by J¯n (π, µ) and V̄n (π, µ). 3.1. Discounted Cost. In this section we consider (Q1) for the discounted cost criterion with a discount factor β ∈ (0, 1). Throughout this section, it is assumed that Assumption 3.1 holds. The following result states that c-MDPn and MDPn are equivalent for the discounted cost. Lemma 3.2. We have J¯n∗ (x) ( Jn∗ (x), = Jn∗ (∆n ), if x ∈ Kn if x ∈ Knc , (3.5) where J¯n∗ is the discounted value function of MDPn and Jn∗ is the discounted value function of cMDPn , provided that there exist optimal deterministic stationary policies for MDPn and c-MDPn . Furthermore, if, for any deterministic stationary policy f ∈ Fn , we define f¯(x) = f (x) on Kn and f¯(x) = f (∆n ) on Knc , then ( Jn (f, x), if x ∈ Kn (3.6) J¯n (f¯, x) = Jn (f, ∆n ), if x ∈ Knc . In particular, if the deterministic stationary policy fn∗ ∈ Fn is optimal for c-MDPn , then its extension f¯n∗ to X is also optimal for MDPn . Proof. The proof of (3.6) is a consequence of the following facts: bn (x, a) = bn (y, a) and qn ( · |x, a) = qn ( · |y, a) for all x, y ∈ Knc and a ∈ A. In other words, Knc in MDPn behaves like the pseudo state ∆n in c-MDPn when f¯ is applied to MDPn . Let Fn denote the set of all deterministic stationary policies in F which are obtained by extending policies in Fn to X. If we can prove that minf ∈F J¯n (f, x) = minf ∈Fn J¯n (f, x) for all x ∈ X, then (3.5) follows from (3.6). Let f ∈ F \ Fn . We have two cases: (i) J¯n (f, z) = J¯n (f, y) for all z, y ∈ Knc or (ii) there exists z, y ∈ Knc such that J¯n (f, z) < J¯n (f, y). For the case (i), if we define the deterministic Markov policy π 0 as π 0 = {f0 , f, f, . . .}, where f0 (x) = f (z) on Knc for some fixed z ∈ Knc and f0 (x) = f (x) on Kn , then using the expression Z 0 ¯ (3.7) Jn (π , x) = bn (x, f0 (x)) + β J¯n (f, x′ )qn (dx′ |x, f0 (x)), X it is straightforward to show that J¯n (π 0 , x) = J¯n (f, x) on Kn and J¯n (π 0 , x) = J¯n (f, z) on Knc . Therefore, J¯n (π 0 , x) = J¯n (f, x) for all x ∈ X since J¯n (f, x) = J¯n (f, z) for all x ∈ Knc . For all t ≥ 1 define Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 19 the deterministic Markov policy π t as π t = {f0 , π t−1 }. Analogously, one can prove that J¯n (π t , x) = J¯n (π t+1 , x) for all x ∈ X. Since J¯n (π t , x) → J¯n (f0 , x) as t → ∞, we have J¯n (f0 , x) = J¯n (f, x) for all x ∈ X, where f0 ∈ Fn . For the second case, if we again consider the deterministic Markov policy π 0 = {f0 , f, f, . . .}, then by (3.7) we have J¯n (π 0 , y) = J¯n (f, z) < J¯n (f, y). Since minf ∈F J¯n (f, y) ≤ J¯n (π 0 , y), this completes the proof.  R For each n, let us define wn by letting wn (x) = w(x) on Kn and wn (x) = K c w(z)νn (dz) =: γn on n Knc . Hence, wn ∈ B(X) by (3.3). Lemma 3.3. For all n and x ∈ X, the components of MDPn satisfy the following: sup |bn (x, a)| ≤ M wn (x) sup a∈A Z (3.8) a∈A wn (y)qn (dy |x, a) ≤ αwn (x) + γ, (3.9) X where γ is the constant in (3.4). Proof. It is straightforward to prove (3.8) by using the definitions of bn and wn , and the equation (3.1). To prove (3.9), we have to consider two cases: x ∈ Kn and x ∈ Knc . For the first case, qn ( · |x, a) = p( · |x, a), and therefore, we have  Z Z Z  γn − w(y) p(dy |x, a) w(y)p(dy |x, a) + sup wn (y)p(dy |x, a) = sup c a∈A Z X a∈A X Kn ≤ sup w(y)p(dy |x, a) + γ (by (3.4)) a∈A X ≤ αw(x) + γ = αwn (x) + γ (as wn = w on Kn ). For x ∈ Knc , we have Z  wn (y)p(dy |z, a) νn (dz) sup wn (y)qn (dy |x, a) = sup a∈A X  Za∈A Knc ZX sup wn (y)p(dy |z, a) νn (dz) ≤ ZKnc a∈A X  αw(z) + γ νn (dz) ≤ Z Z (3.10) c Kn = αwn (x) + γ, where (3.10) can be proved following the same arguments as for the case x ∈ Kn . This completes the proof.  R Note that if we define cn,0 (x) = 1 + supa∈A |bn (x, a)| and cn,t (x) = supa∈A X cn,t−1 (y)qn (dy |x, a), by (3.8) and (3.9), and an induction argument, we obtain (see Hernández-Lerma and Lasserre [22, p. 46]) cn,t (x) ≤ Lwn (x)αt + Lγ t−1 X αj for all x ∈ X, j=0 where L = 1 + M . Let β0 > β be such that αβ0 < 1 and let Cn : X → [1, ∞) be defined by Cn (x) = ∞ X t=0 β0t cn,t (x). (3.11) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 20 Then, for all x ∈ X, by (3.11) we have Cn (x) := ∞ X L Lβ0 wn (x) + γ 1 − β0 α (1 − β0 )(1 − β0 α) := L1 wn (x) + L2 . β0t cn,t (x) ≤ t=0 (3.12) Hence Cn ∈ B(X) as wn ∈ B(X). Moreover, for all (x, a) ∈ X × A, Cn satisfies (see Hernández-Lerma and Lasserre [22, p. 45]) Z Z ∞ X t β0 cn,t (y)qn (dy |x, a) Cn (y)qn (dy |x, a) = X X t=0 ≤ ∞ X t=0 β0t cn,t+1 (x) ∞ 1 X t ≤ β cn,t (x) = α0 Cn (x), β0 t=0 0 where α0 := β10 and α0 β < 1 since β0 > β. Therefore, for all x ∈ X, components of MDPn satisfy sup |bn (x, a)| ≤ Cn (x) sup a∈A Z (3.13) a∈A Cn (y)qn (dy |x, a) ≤ α0 Cn (x). (3.14) X Since Cn ∈ B(X), the Bellman optimality operator T n of MDPn maps B l (X) into B l (X) and is given by   Z T n u(x) = inf bn (x, a) + β u(y)qn (dy |x, a) a∈A X R (   if x ∈ Kn inf a∈A c(x, a) + β X u(y)p(dy |x, a) , R   R = inf a∈A K c c(z, a) + β X u(y)p(dy |z, a) νn (dz), if x ∈ Knc . n Then successive approximations to the discounted value function of MDPn are given by vn0 = 0 and vnt+1 = T n vnt (t ≥ 1). Since α0 β < 1, it can be proved as in Hernández-Lerma and Lasserre [22, Theorem 8.3.6, p. 47] and Hernández-Lerma and Lasserre [22, (8.3.34), p. 52] that Cn (x) for all x, |vnt (x)|, |J¯n∗ (x)| ≤ 1 − σ0 t σ0 kvnt − J¯n∗ kCn ≤ , 1 − σ0t (3.15) (3.16) where σ0 = βα0 < 1. Similar to vnt , let us define v 0 = 0 and v t+1 = T v t , where T : Bw (X) → Bw (X), the Bellman optimality operator for the original MDP, is given by   Z T u(x) = inf c(x, a) + β u(y)p(dy |x, a) . a∈A X Then, again by Hernández-Lerma and Lasserre [22, Theorem 8.3.6, p. 47] and Hernández-Lerma and Lasserre [22, (8.3.34), p. 52] we have w(x) for all x, 1 −t σ σ , kv t − J ∗ kw ≤ M 1−σ |v t (x)|, |J ∗ (x)| ≤ M where σ = βα < 1. (3.17) (3.18) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS Lemma 3.4. 21 For any compact set K ⊂ X, we have lim sup |vnt (x) − v t (x)| = 0 n→∞ x∈K (3.19) for all t ≥ 1. Proof. We prove (3.19) by induction on t. For t = 1, the claim trivially holds since any compact set K ⊂ X is inside Kn for sufficiently large n, and therefore, bn = c on K for sufficiently large n (recall vn0 = v 0 = 0). Assume the claim is true for t ≥ 1. Fix any compact set K. Recall the definition of compact subsets Kε of X in Lemma 3.1. By definition of qn , bn , and wn , there exists n0 ≥ 1 such that for all n ≥ n0 , qn = p, bn = c, and wn = w on K. With these observations, for each n ≥ n0 we have     Z Z t t t+1 t+1 sup |vn (x) − v (x)| = sup inf c(x, a) + β vn (y)p(dy |x, a) − min c(x, a) + β v (y)p(dy |x, a) A x∈K x∈K A X X Z Z t t vn (y)p(dy |x, a) − v (y)p(dy |x, a) ≤ β sup (x,a)∈K×A X X Z Z   t t vnt (y) − v t (y) p(dy |x, a) vn (y) − v (y) p(dy |x, a) + = β sup (x,a)∈K×A Kε Kεc   Z  t t t t vn (y) − v (y) p(dy |x, a) ≤ β sup |vn (x) − v (x)| + sup x∈Kε (x,a)∈K×A Kεc w Note that we have |v | ≤ M 1−σ by (3.17). Since wn ≤ γmax w, where γmax := max{1, γ }, (L1 γmax +L2 )w L1 γmax w+L2 t ≤ by (3.12) and (3.15) (as w ≥ 1). Let us define |vn | ≤ 1−σ0 1−σ0 t R := we also have M L1 γmax + L2 + . 1 − σ0 1−σ Then by Lemma 3.1 we have sup |vnt+1 (x) − v t+1 (x)| ≤ β sup |vnt (x) − v t (x)| + βRε. x∈K x∈Kε Since the first term converges to zero as n → ∞ by the induction hypothesis, and ε is arbitrary, the claim is true for t + 1. This completes the proof.  The following theorem states that the discounted value function of MDPn converges to the discounted value function of the original MDP uniformly on each compact set K ⊂ X. Theorem 3.1. For any compact set K ⊂ X we have lim sup |J¯n∗ (x) − J ∗ (x)| = 0. n→∞ x∈K (3.20) Proof. Fix any compact set K ⊂∗X. Since w is continuous and therefore bounded on K, it is ∗ ¯ (x)| . Let n be chosen such that K ⊂ Kn , and so, wn = w sufficient to prove limn→∞ supx∈K |Jn (x)−J w(x) on K. Then we have |J¯∗ (x) − J ∗ (x)| |J¯∗ (x) − vnt (x)| |v t (x) − v t (x)| |v t (x) − J ∗ (x)| sup n ≤ sup n + sup n + sup w(x) w(x) w(x) w(x) x∈K x∈K x∈K x∈K |J¯n∗ (x) − vnt (x)| Cn (x) |vnt (x) − v t (x)| σt ≤ sup + sup +M (by (3.18)) Cn (x) w(x) x∈K w(x) 1 − σt x∈K |v t (x) − v t (x)| M σt |J¯∗ (x) − vnt (x)| (L1 wn (x) + L2 ) + sup n + (by (3.12)) ≤ sup n Cn (x) w(x) w(x) 1 − σt x∈K x∈K t t t t ∗ |v (x) − v (x)| Mσ |J¯ (x) − vn (x)| + sup n + (wn = w on K) ≤ (L1 + L2 ) sup n Cn (x) w(x) 1 − σt x∈K x∈K σt |v t (x) − v t (x)| M σt ≤ (L1 + L2 ) 0 + sup n + (by (3.16)). 1 − σ0 x∈K w(x) 1 − σt Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 22 t t (x)| Since w ≥ 1 on X, supx∈K |vn (x)−v → 0 as n → ∞ for all t by Lemma 3.4. Hence, the last w(x) expression can be made arbitrarily small. This completes the proof.  In the remainder of this section, we use the above results and Theorem 2.2 to compute a near optimal policy for the original MDP. It is straightforward to check that for each n, c-MDPn satisfies the assumptions in Theorem 2.2. Let {εn } be a sequence of positive real numbers such that limn→∞ εn = 0. By Theorem 2.2, for each n ≥ 1, there exists a deterministic stationary policy fn ∈ Fn , obtained from the finite state approximations of c-MDPn , such that sup |Jn (fn , x) − Jn∗ (x)| ≤ εn , x∈Xn  where for each n, finite-state models are constructed replacing Z, A, p, c with the components  Xn , A, pn , cn of c-MDPn in Section 2. By Lemma 3.2, for each n ≥ 1 we also have sup |J¯n (fn , x) − J¯n∗ (x)| ≤ εn , (3.21) x∈X where, with an abuse of notation, we also denote the extended (to X) policy by fn . Let us define operators R̄n : BCn (X) → BCn (X) and Rn : Bw (X) → Bw (X) by ( R if x ∈ Kn c(x, fn (x)) + β X u(y)p(dy |x, fn(x)),  R R̄n u(x) = R  if x ∈ Knc , c c(z, fn (z)) + β X u(y)p(dy |z, fn (z)) νn (dz), Kn Z Rn u(x) = c(x, fn (x)) + β u(y)p(dy |x, fn(x)). X By Hernández-Lerma and Lasserre [22, Remark 8.3.10, p. 54], R̄n is a contraction operator with modulus σ0 and Rn is a contraction operator with modulus σ. Furthermore, the fixed point of R̄n is J¯n (fn , x) and the fixed point of Rn is J (fn , x). For each n ≥ 1, let us define ū0n = u0n = 0 and ūt+1 = R̄n ūtn , ut+1 = Rn utn (t ≥ 1). One can prove that (see the proof of Hernández-Lerma and n n Lasserre [22, Theorem 8.3.6, p. 51]) Cn (x) |ūtn (x)|, |J¯n (fn , x)| ≤ 1 − σ0 σ0t t ¯ kūn − Jn (fn , · )kCn ≤ 1 − σ0 w(x) t |un (x)|, |J (fn, x)| ≤ M 1 −t σ σ . kutn − J (fn, · )kw ≤ M 1−σ Lemma 3.5. For any compact set K ⊂ X, we have lim sup |ūtn (x) − utn (x)| = 0. n→∞ x∈K Proof. The lemma can be proved using the same arguments as in the proof of Lemma 3.4 and so we omit the details.  Lemma 3.6. For any compact set K ⊂ X, we have lim sup |J¯n (fn , x) − J (fn, x)| = 0. n→∞ x∈K Indeed, this is true for all sequences of policies in F. (3.22) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 23 Proof. The lemma can be proved using the same arguments as in the proof of Theorem 3.1.  The following theorem is the main result of this section which states that the true cost functions of the policies obtained from finite state models converge to the value function of the original MDP. Hence, to obtain a near optimal policy for the original MDP, it is sufficient to compute the optimal policy for the finite state model that has sufficiently large number of grid points. Theorem 3.2. For any compact set K ⊂ X, we have lim sup |J (fn , x) − J ∗ (x)| = 0. n→∞ x∈K Therefore, lim |J (fn , x) − J ∗ (x)| = 0 for all x ∈ X. n→∞ Proof. The result follows from (3.20), (3.21), and (3.22).  3.2. Average Cost. In this section we obtain approximation results, analogous to Theorems 3.1 and 3.2, for the average cost criterion. To do this, we impose some new assumptions on the components of the original MDP in addition to Assumption 3.1. These assumptions are the unbounded counterpart of Assumption 2.2. With the exception of Assumption 3.2-(j), versions of these assumptions were imposed in Vega-Amaya [38], Gordienko and Hernandez-Lerma [18], and Jaśkiewicz and Nowak [26] to study the existence of the solution to the Average Cost Optimality Equality (ACOE) and Inequality (ACOI). RIn what follows, for any finite signed measure ϑ and measurable function h on X, we let ϑ(h) := X h(x)ϑ(dx) and Z g(x)ϑ(dx) . kϑkw := sup kgkw ≤1 X Here kϑkw is called the w-norm of ϑ. Assumption 3.2. Suppose Assumption 3.1 holds with item (b) and (3.2) replaced by conditions (j) and (e) below, respectively. In addition, there exist a probability measure η on X and a positive measurable function φ : X × A → (0, ∞) such that for all (x, a) ∈ X × A R (e) X w(y)p(dy |x, a) ≤ αw(x) + η(w)φ(x, a), where α ∈ (0, 1). (f ) p(D |x, a) ≥ η(D)φ(x, a) for all D ∈ B (X). (g) The weight function w is η-integrable, i.e., η(w) < ∞. (h) For each n ≥ 1, inf (x,a)∈Kn×A φ(x, a) > 0. (j) The stochastic kernel p( · |x, a) is continuous in (x, a) with respect to the w-norm. Throughout this section, it is assumed that Assumption 3.2 holds. Conditions (e), (f), and (g) of Assumption 3.2 are unbounded counterparts of conditions (d) and (e) in Assumption 2.2. Recall that condition (e) corresponds to the so-called ‘drift inequality’ and condition (f) corresponds to the so-called ‘minorization’ condition which guarantee the geometric ergodicity of Markov chains induced by stationary policies (see Hernández-Lerma and Lasserre [22], Meyn and Tweedie [29] and references therein). These assumptions are quite general for studying average cost problems with unbounded one-stage costs. In addition, they are proper for the approximation problem in the sense that it can be shown that if the original problem satisfies these, then the reduced models constructed in the sequel satisfy similar conditions. There is only one minor difference between Assumption 3.2-(f) and the standard minorization condition: in the literature φ is in general required to be nonnegative instead of positive. Note that although Assumption 3.2-(j) seems to be restrictive, it is weaker than the assumptions imposed in the literature for studying approximation of average cost problems with unbounded 24 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS cost (see Dufour and Prieto-Rumeau [15]). Indeed, it is assumed in Dufour and Prieto-Rumeau [15] that the transition probability p is Lipschitz continuous in (x, a) with respect to w-norm. The reason for imposing such a strong condition on the transition probability is to obtain convergence rate for the approximation problem. Since we do not aim to provide rate of convergence result in this section, it is natural to impose continuity instead of Lipschitz continuity of the transition probability. However, it does not seem possible to replace continuity with respect to the w-norm by a weaker convergence notion. One reason is that with a weaker continuity notion it is not possible to prove that the transition probability of c-MDPn is continuous with respect to the total variation distance, which is needed if one wants to use Theorem 2.6 and cannot be relaxed as explained in Remark 2.3. Analogous with Theorem 2.5, the following theorem is a consequence of Vega-Amaya [38, Theorems 3.3], Gordienko and Hernandez-Lerma [18, Lemma 3.4] (see also Hernández-Lerma and Lasserre [22, Proposition 10.2.5, p. 126]), and Jaśkiewicz and Nowak [26, Theorem 3], which also holds with Assumption 3.2-(j) replaced by Assumption 3.1-(b). Theorem 3.3. For each f ∈ F, the stochastic kernel p( · |x, f (x)) is positive Harris recurrent with unique invariant probability measure µf . Furthermore, w is µf -integrable, and therefore, ρf := R c(x, f )µf (dx) < ∞. There exist positive real numbers R and κ < 1 such that X sup kpt ( · |x, f (x)) − µf kw ≤ Rw(x)κt (3.23) f ∈F for all x ∈ X, where R and κ continuously depend on α, η(w), and inf f ∈F η(φ(y, f (y))). Finally, there exist f ∗ ∈ F and h∗ ∈ Bw (X) such that the triplet (h∗ , f ∗ , ρf ∗ ) satisfies the average cost optimality equality (ACOE), and therefore, inf V (π, x) := V ∗ (x) = ρf ∗ , π∈Π for all x ∈ X. Note that (3.23) implies that for each f ∈ F, the average cost is given by V (f, x) = R c(y, f (y))µf (dy) for all x ∈ X (instead of µf -a.e.); that is, the average cost is independent of the X initial point. Recall that Vn and V̄n denote the average costs of c-MDPn and MDPn , respectively. The value functions for average cost are denoted analogously to the discounted cost case. Similar to Lemma 3.2, the following result states that MDPn and MDPn are not too different for the average cost. Lemma 3.7. we have Suppose Theorem 3.3 holds for MDPn and Theorem 2.5 holds for MDPn . Then V̄n∗ (x) ( Vn∗ (x), = Vn∗ (∆n ), if x ∈ Kn if x ∈ Knc . (3.24) Furthermore, if, for any deterministic stationary policy f ∈ Fn , we define f¯(x) = f (x) on Kn and f¯(x) = f (∆n ) on Knc , then ( Vn (f, x), if x ∈ Kn (3.25) V̄n (f¯, x) = Vn (f, ∆n ), if x ∈ Knc . In particular, if the deterministic stationary policy fn∗ ∈ Fn is optimal for MDPn , then its extension f¯n∗ to X is also optimal for MDPn . Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 25 Proof. Let the triplet (h∗n , fn∗ , ρnfn∗ ) satisfy the ACOE for c-MDPn , so that fn∗ is an optimal policy and ρnfn∗ is the average value function for c-MDPn . It is straightforward to show that the triplet ^n , where (h̄∗ , f¯∗ , ρn∗ ) satisfies the ACOE for MDP n n fn h̄∗n (x) = ( h∗n (x), h∗n (∆n ), if x ∈ Kn if x ∈ Knc , f¯n∗ (x) ( fn∗ (x), fn∗ (∆n ), if x ∈ Kn if x ∈ Knc . and = By Gordienko and Hernandez-Lerma [18, Lemma 5.2] (see also Hernández-Lerma and Lasserre [21, Section 5.2]), this implies that f¯n∗ is an optimal stationary policy for MDPn with cost function ρnfn∗ . This completes the proof of the first part. For the second part, let f ∈ Fn with an unique invariant probability measure µf ∈ P (Xn ) and let f¯ ∈ F denote its extension to X with an unique invariant probability measure µf¯. It can be proved that µf ( · ) = µf¯( · ∩ Kn ) + µf¯(Knc )δ∆n ( · ). Then we have V̄n (f, x) = = = Z bn (x, f¯(x))µf¯(dx) ZX ZKn cn (x, f¯(x))µf¯(dx) + µf¯(Knc )cn (∆n , f¯(∆n )) cn (x, f (x))µf (dx) Xn = Vn (f, x). This completes the proof.  By Lemma 3.7, in the remainder of this section we need only consider MDPn in place of MDPn . Later we will show that Theorem 3.3 holds for MDPn for n sufficiently large and that Theorem 2.5 holds for c-MDPn for all n. Recall the definition of constants γn and τn from (3.3) and (3.4). For each n ≥ 1, we define φn : X × A → (0, ∞) and ςn ∈ R as ( φ(x, a), if x ∈ Kn φn (x, a) := R φ(y, a)νn (dy), if x ∈ Knc , Z Knc w(y)η(dy). ςn := c Kn Since η(w) < ∞ and τn can be made arbitrarily small by properly choosing νn , we assume, without loss of generality, the following. Assumption 3.3. holds The sequence of probability measures {νn } is chosen such that the following lim (τn + ςn ) = 0. n→∞ (3.26) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 26 Let αn := α + ςn + τn . Lemma 3.8. For all n and (x, a) ∈ X × A, the components of MDPn satisfy the following: sup |bn (x, a)| ≤ M wn (x) a∈A Z wn (y)qn (dy |x, a) ≤ αn wn (x) + η(wn )φn (x, a), X (3.27) qn (D |x, a) ≥ η(D)φn (x, a) for all D ∈ B (X). Proof. The proof of the first inequality follows from Assumption 3.2 and definitions of bn and wn . To prove the remaining two inequalities, we have to consider the cases x ∈ Kn and x ∈ Knc separately. Let x ∈ Kn , and therefore, qn ( · |x, a) = p( · |x, a). The second inequality holds since Z Z Z  wn (y)p(dy |x, a) = w(y)p(dy |x, a) + γn − w(y) p(dy |x, a) c X Kn ZX ≤ w(y)p(dy |x, a) + τn X ≤ αw(x) + η(w)φ(x, a) + τn ≤ αwn (x) + η(wn )φn (x, a) + ςn φn (x, a) + τn (as wn = w and φn = φ on Kn ) ≤ αn wn (x) + η(wn )φn (x, a), (as φn ≤ 1 and wn ≥ 1). For the last inequality, for all D ∈ B (X), we have qn (D |x, a) = p(D |x, a) ≥ η(D)φ(x, a) = η(D)φn (x, a) (as φn = φ on Kn ). Hence, inequalities hold for x ∈ Kn . For x ∈ Knc , we have  Z Z Z wn (y)p(dy |z, a) νn (dz) wn (y)qn (dy |x, a) = X ZKnc X  αw(z) + η(wn )φ(x, a) + ςn φ(x, a) + τn νn (dz) ≤ (3.28) c Kn = αwn (x) + η(wn )φn (x, a) + ςn φn (x, a) + τn ≤ αn wn (x) + η(wn )φn (x, a), (since φn ≤ 1 and wn ≥ 1) where (3.28) can be obtained following the same arguments as for the case x ∈ Kn . The last inequality holds for x ∈ Knc since Z p(D |z, a)νn (dz) qn (D |x, a) = ZKnc η(D)φ(z, a)νn (dz) ≥ c Kn = η(D)φn (x, a). This completes the proof.  We note that by (3.26), there exists n0 ≥ 1 such that αn < 1 for n ≥ n0 . Hence, for each n ≥ n0 , Theorem 3.3 holds for MDPn with w replaced by wn for some Rn > 0 and κn ∈ (0, 1), and we have Rmax := supn≥n0 Rn < ∞ and κmax := supn≥n0 κn < 1. In the remainder of this section, it is assumed that n ≥ n0 . Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 27 Lemma 3.9. Let g : X × A → R be any measurable function such that supa∈A |g(x, a)| ≤ Mg w(x) for some Mg ∈ R. Then, for all t ≥ 1 and any compact set K ⊂ X we have Z Z gn (x, f (x))qnt (dx|y, f (y)) − g(x, f (x))pt(dx|y, f (y)) → 0 sup (y,f )∈K×F X X as n → ∞, where gn (x, a) = g(x, a) on Kn × A and gn (x, a) = R c Kn g(z, a)νn (dz) on Knc × A. Proof. We will prove the lemma by induction. Fix any compact set K ⊂ X. We note that in the inequalities below, we repeatedly use the fact φ, φn ≤ 1 without explicitly referring to this fact. Recall the definition of the compact subsets Kε of X in Lemma 3.1 and the constant γmax = max{1, γ }. Note that supa∈A |gn (x, a)| ≤ Mg wn (x) ≤ Mg γmax w(x) for all x ∈ X. The claim holds for t = 1 by the following argument: Z Z gn (x, f (x))qn(dx|y, f (y)) − g(x, f (x))p(dx|y, f (y)) sup (y,f )∈K×F X X Z Z = sup gn (x, f (x))p(dx|y, f (y)) − g(x, f (x))p(dx|y, f (y)) (for n sufficiently large) (y,f )∈K×F X X Z Z g(x, f (x))p(dx|y, f (y)) (for n sufficiently large) gn (x, f (x))p(dx|y, f (y)) − = sup Kεc Kεc (y,f )∈K×F ≤ Mg (1 + γmax )ε, where the last inequality follows from Lemma 3.1. Since ε isR arbitrary, the result follows. t n R Assume the tclaim is true for t ≥ 1. Let us define lf (z) := X g(x, f (x))p (dx|z, f (z)) and lf (z) := g (x, f (x))qn(dx|z, f (z)). By recursively applying the inequalities in Assumption 3.2-(e) and in X n (3.27) we obtain t sup |lf (z)| ≤ Mg α w(z) + Mg η(w) f ∈F t−1 X αj j=0 and sup |lfn (z)| ≤ Mg αtn wn (z) + Mg η(wn ) f ∈F t−1 X αjn j=0 ≤ Mg αtmax γmax w(z) + Mg η(w)γmax t−1 X αjmax , j=0 where αmax := supn≥n0 αn < 1. Then we have sup (y,f )∈K×F Z X = sup (y,f )∈K×F = sup (y,f )∈K×F ≤ sup (y,f )∈K×F Z g(x, f (x))pt+1(dx|y, f (y)) X Z Z n lf (z)qn (dz |y, f (y)) − lf (z)p(dz |y, f (y)) ZX Z X n lf (z)p(dz |y, f (y)) − lf (z)p(dz |y, f (y)) (for n sufficiently large) X Z ZX n lf (z)p(dz |y, f (y)) + sup |lfn (z) − lf (z)| lf (z)p(dz |y, f (y)) − gn (x, f (x))qnt+1 (dx|y, f (y)) − Kεc ≤ Rε + sup (z,f )∈Kε ×F |lfn (z) − lf (z)|, Kεc (z,f )∈Kε ×F (3.29) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 28 where R is given by   t−1 t−1 X X j j t t αmax α + η(w)γmax R := Mg α + αmax γmax + η(w) j=0 j=0 and the last inequality follows from Lemma 3.1. Since the claim holds for t and Kε , the second term in (3.29) goes to zero as n → ∞. Since ε is arbitrary, the result follows.  In the remainder of this section the above results are used to compute a near optimal policy for the original MDP. Let {εn } be a sequence of positive real numbers converging to zero. For each f ∈ F, let µnf denote the unique invariant probability measure of the transition n n Rkernel qn ( · |x, nf (x)) and let ρf denote the associated average cost; that is, ρf := V̄n (f, x) = b (y, f (y))µf (dy) for all initial points x ∈ X. Therefore, the value function of MDPn , denoted by X n V̄n∗ , is given by Vn∗ (x) = inf f ∈F ρnf , i.e., it is constant on X. Before making the connection with Theorem 2.6, we prove the following result. Lemma 3.10. The transition probability pn of c-MDPn is continuous in (x, a) with respect to the total variation distance. Proof. To ease the notation, we define M (Xn ), M (X), and Mw (X) as the subsets of B(Xn ), B(X), and Bw (X), respectively, whose elements have (corresponding) norm less than one. Let (xk , ak ) → (x, a) in Xn × A. Since the pseudo state ∆n is isolated and Kn is compact, we have two cases: (i) xk = x = ∆n for all k large enough, or (ii) xk → x in Kn . For the first case we have Z Z g(y)pn (dy |∆n , a) g(y)pn (dy |∆n , ak ) − kpn ( · |∆n , ak ) − pn ( · |∆n , a)kT V = sup g∈M(Xn ) Xn Z Xn Z ≤ sup (3.30) g(y)qn (dy |∆n , ak ) − g(y)qn (dy |∆n , a) g∈M(X) X Z XZ  Z g(y)p(dy |z, ak ) − g(y)p(dy |z, a) νn (dz) = sup c g∈M(X) Kn Z Z X Z X sup ≤ g(y)p(dy |z, ak ) − g(y)p(dy |z, a) νn (dz) ZX ZKnc g∈M(X) ZX g(y)p(dy |z, ak ) − g(y)p(dy |z, a) νn (dz) sup ≤ X ZKnc g∈Mw (X) X kp( · |z, ak ) − p( · |z, a)kw νn (dz), (3.31) = c Kn c where (3.30) follows since R if for any g ∈ M (XRn ) we define ḡ = g on Kn and ḡ = g(∆n ) on Kn , then we have ḡ ∈ M (X) and Xn g(y)pn (dy |x, a) = X ḡ(y)qn (dy |x, a) for all (x, a) ∈ Xn × A. Note that we have Z Z Z Z g(y)p(dy |z, ak ) − g(y)p(dy |z, a) ≤ w(y)p(dy |z, ak ) + w(y)p(dy |z, a) sup g∈Mw (X) X X X X  ≤ 2 α + η(w) w(z) by Assumption 3.2-(e), φ ≤ 1, and w ≥ 1. Since w (restricted to Knc ) is νn -integrable, by the dominated convergence theorem (3.31) goes to zero as k → ∞. For the second case we have Z Z g(y)pn (dy |x, a) g(y)pn (dy |xk , ak ) − kpn ( · |xk , ak ) − pn ( · |x, a)kT V = sup g∈M(Xn ) Xn Xn Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS ≤ sup g∈M(X) = sup g∈M(X) Z Z g(y)qn (dy |xk , ak ) − g(y)qn (dy |x, a) Z X g(y)p(dy |xk , ak ) − g(y)p(dy |x, a) (since xk , x ∈ Kn ) ZX ZX g(y)p(dy |xk , ak ) − g(y)p(dy |x, a) ZX ≤ sup g∈Mw (X) 29 X X = kp( · |xk , ak ) − p( · |x, a)kw . By Assumption 3.2-(j) the last term goes to zero as k → ∞.  Thus we obtain that for each n ≥ 1, c-MDPn satisfies the assumption in Theorem 2.6 for c ζ( · ) = η( ( · ∩ Kn ) + η(Kn )δ∆n ( · ), φ(x, a), if x ∈ Kn θ(x, a) = R φ(y, a)νn (dy), if x = ∆n , Kc n and some λ ∈ (0, 1), where the existence of λ follows from Assumption 3.2-(h) and the fact that φ > 0. Consequently, there exists a deterministic stationary policy fn ∈ Fn , obtained from the finite state approximations of c-MDPn , such that sup |Vn (fn , x) − Vn∗ (x)| ≤ εn , (3.32) x∈Xn   where finite-state models are constructed replacing Z, A, p, c with the components Xn , A, pn , cn of c-MDPn in Section 2. By Lemma 3.7, we also have |ρnfn − V̄n∗ | ≤ εn , (3.33) where, by an abuse of notation, we also denote the policy extended to X by fn . Lemma 3.11. We have sup |ρnf − ρf | → 0 (3.34) f ∈F as n → ∞. Proof. Fix any compact set K ⊂ X. For any t ≥ 1 and y ∈ K, we have Z Z n n sup |ρf − ρf | = sup bn (x, f (x))µf (dx) − c(x, f (x))µf (dx) f ∈F f ∈F ZX ZX ≤ sup bn (x, f (x))µnf(dx) − bn (x, f (x))qnt (dx|y, f (y)) f ∈F X X Z Z t + sup bn (x, f (x))qn(dx|y, f (y)) − c(x, f (x))pt(dx|y, f (y)) f ∈F X X Z Z t + sup c(x, f (x))p (dx|y, f (y)) − c(x, f (x))µf (dx) f ∈F X ≤ M Rmax w(y)κtmax + MZRw(y)κt + bn (x, f (x))qnt (dx|y, f (y)) − sup (y,f )∈K×F X X Z c(x, f (x))pt(dx|y, f (y)) , X where the last inequality follows from Theorem 3.3-(ii) and (3.1) in Assumption 3.1. The result follows from Lemma 3.9.  Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 30 Theorem 3.4. The value function of MDPn converges to the value function of the original MDP, i.e., |V̄n∗ − V ∗ | → 0, as n → ∞. Proof. Since |V̄n∗ − V ∗ | = | inf ρnf − inf ρf | ≤ sup |ρnf − ρf |, f ∈F f ∈F f ∈F the result follows from Lemma 3.11.  The following is the main result of this section which states that the true average cost of the policies fn obtained from finite state approximations of c-MDPn converges to the average value function V ∗ of the original MDP. Theorem 3.5. We have |ρfn − V ∗ | → 0, as n → ∞. Proof. We have |ρfn − V ∗ | ≤ |ρfn − ρnfn | + |ρnfn − V̄n∗ | + |V̄n∗ − V ∗ | ≤ sup |ρf − ρnf | + εn + |V̄n∗ − V ∗ | (by (3.33)) f ∈F The result follows from Lemma 3.11 and Theorem 3.4.  4. Discretization of the Action Space. For computing near optimal policies using well known algorithms, such as value iteration, policy iteration, and Q-learning, the action space must be finite. In this section, we show that, as a pre-processing step, the action space can taken to be finite if it has sufficiently large number of points for accurate approximation. Throughout this section, it is assumed that Assumption 3.1 holds for the discounted cost and Assumption 3.2 holds for the average cost. It was shown in Saldi et al. [33] and Saldi et al. [34] that any MDP with (infinite) compact action space can be well approximated by an MDP with finite action space under assumptions that are satisfied by c-MDPn , for both the discounted cost and the average cost cases. Specifically, let dA denote the metric on A. Since A is compact, one can find a sequence of finite subsets {Λk } of A such that for all k min dA (a, â) < 1/k for all a ∈ A. â∈Λk  We define c-MDPn,k as the Markov decision process having the components Xn , Λk , pn , cn and we let Fn (Λk ) denote the set of all deterministic stationary policies for c-MDPn,k . Note that Fn (Λk ) is the set of policies in Fn taking values only in Λk . Therefore, in a sense, c-MDPn,k and c-MDPn can be viewed as the same MDP, where the former has constraints on the set of policies. For each n and ∗ k, by an abuse of notation, let fn∗ and fn,k denote the optimal stationary policies of c-MDPn and c-MDPn,k , respectively, for both the discounted and average costs. Then Saldi et al. [34, Theorem 3.2] and Saldi et al. [33, Theorem 3.2] show that for all n, we have ∗ lim Jn (fn,k , x) = Jn (fn∗ , x) := Jn∗ (x) k→∞ ∗ lim Vn (fn,k , x) = Vn (fn∗ , x), := Vn∗ (x) k→∞ for all x ∈ Xn . In other words, the discounted and average value functions of c-MDPn,k converge to the discounted and average value functions of c-MDPn as k → ∞. We note that although Saldi et al. [34, Theorem 3.2] and Saldi et al. [33, Theorem 3.2] are proved for nonnegative one-stage cost function, it is straightforward to check that these theorems are also valid for any real valued one-stage cost function. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS Theorem 4.1. 31 For any x ∈ X, there exists a subsequence {kn } such that ∗ , x) = J ∗ (x) lim J (fn,k n n→∞ ∗ lim V (fn,k , x) = V ∗ (x), n n→∞ ∗ ∈ F(Λkn ) is the optimal stationary policy of c-MDPn,kn . where fn,k n ∗ , x) − Proof. Let us fix x ∈ X. For n sufficiently large (so x ∈ Kn ), we choose kn such that |Jn (fn,k n ∗ ∗ ∗ Jn (fn , x)| < 1/n (or |Vn (fn,kn , x) − Vn (fn , x)| < 1/n for the average cost). We note that if A is a compact subset of a finite dimensional Euclidean space, then by using Saldi et al. [33, Theorems 4.1 and 4.2] one can obtain an explicit expression for kn in terms of n under further continu∗ ∗ , x)| → 0 and , x) − J (fn,k ity conditions on c and p. By Lemmas 3.6 and 3.11, we have |J¯n (fn,k n n ∗ ∗ |V̄n (fn,kn , x) − V (fn,kn , x)| → 0 as n → ∞, where again by an abuse of notation, the policies extended ∗ ∗ ∗ ∗ ∗ , x), using , x) = Vn (fn,k , x) and V̄n (fn,k , x) = Jn (fn,k . Since J¯n (fn,k to X are also denoted by fn,k n n n n n Theorems 3.1 and 3.4 one can immediately obtain ∗ , x) = J ∗ (x) lim J (fn,k n n→∞ ∗ lim V (fn,k , x) = V ∗ (x). n n→∞  Theorem 4.1 implies that before discretizing the state space to compute the near optimal policies, one can discretize, without loss of generality, the action space A in advance on a finite grid using sufficiently large number of grid points. 5. Rate of Convergence Analysis for Compact-State MDPs. In this section we consider (Q2) for MDPs with compact state space; that is, we derive an upper bound on the performance loss due to discretization in terms of the cardinality of the set Zn (i.e., number of grid points) . To do this, we will impose some new assumptions on the components of the MDP in addition to Assumptions 2.1 and 2.2. First, we present some definitions that are needed in the development. For each g ∈ Cb (Z), let kg kLip := |g(z) − g(y)| . dZ (z, y) (z,y)∈Z×Z sup If kg kLip is finite, then g is called Lipschitz continuous with Lipschitz constant kg kLip . Lip(Z) denotes the set of all Lipschitz continuous functions on Z, i.e., Lip(Z) := {g ∈ Cb (Z) : kg kLip < ∞} and Lip(Z, K) denotes the set of all g ∈ Lip(Z) with kg kLip ≤ K. The Wasserstein distance of order 1 Villani [39, p. 95] between two probability measures ζ and ξ over Z is defined as Z  Z W1 (ζ, ξ) := sup gdζ − gdξ : g ∈ Lip(Z, 1) . Z Z W1 is also called the Kantorovich-Rubinstein distance. It is known that if Z is compact, then W1 (ζ, ξ) ≤ diam(Z)kζ − ξ kT V ; see Villani [39, Theorem 6.15, p. 103]. For compact Z, the Wasserstein distance of order 1 is weaker than total variation distance. Furthermore, for compact Z, the Wasserstein distance of order 1 metrizes the weak topology on the set of probability measures P (Z) (see Villani [39, Corollary 6.13, p. 97]) which also implies that convergence in this sense is weaker than setwise convergence. In this section we impose the following supplementary assumptions in addition to Assumption 2.1 and Assumption 2.2. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 32 Assumption 5.1. (g) The one-stage cost function c satisfies c( · , a) ∈ Lip(Z, K  1 ) for all a ∈ A for some K1 . (h) The stochastic kernel p satisfies W1 p( · |z, a), p( · |y, a) ≤ K2 dZ (z, y) for all a ∈ A for some K2 . (j) Z is an infinite compact subset of Rd for some d ≥ 1, equipped with the Euclidean norm. We note that Assumption 5.1-(j) implies the existence of a constant α > 0 and finite subsets Zn ⊂ Z with cardinality n such that max min dZ (z, y) ≤ α(1/n)1/d (5.1) z∈Z y∈Zn for all n, where dZ is the Euclidean distance on Z. In the remainder of this section, we replace Zn defined in Section 2 with Zn satisfying (5.1) in order to derive explicit bounds on the approximation error in terms of the cardinality of Zn . 5.1. Discounted Cost. Assumptions 2.1 and 5.1 are imposed throughout this section. Additionally, we assume that K2 β < 1. The last assumption is the key to prove the next result which states that the value function J ∗ of the original MDP for the discounted cost is in Lip(Z). Although this result is known in the literature (see Hinderer [24]), we give a short proof for the sake of completeness using a simple application of the value iteration algorithm. Theorem 5.1. 1 . K1 1−βK 2 The value function J ∗ for the discounted cost is in Lip(Z, K), where K = u Proof. Let u ∈ Lip(Z, K) for some K > 1. Then g = K ∈ Lip(Z, 1) and therefore, for all a ∈ A and z, y ∈ Z we have Z Z Z Z g(x)p(dx|z, a) − g(x)p(dx|y, a) u(x)p(dx|z, a) − u(x)p(dx|y, a) = K Z Z Z Z ≤ KW1 p( · |z, a), p( · |y, a) ≤ KK2 dZ (z, y), by Assumption 5.1-(h). Hence, the contraction operator T defined in (2.2) maps u ∈ Lip(Z, K) to T u ∈ Lip(Z, K1 + βKK2), since, for all z, y ∈ Z   Z Z |T u(z) − T u(y)| ≤ max |c(z, a) − c(y, a)| + β u(x)p(dx|z, a) − u(x)p(dx|y, a) a∈A Z Z  ≤ K1 dZ (z, y) + βKK2dZ (z, y) = K1 + βKK2 dZ (z, y). Now we apply T recursively to obtain the sequence {T n u} by letting T n u = T (T n−1 u), which converges to the value function J ∗ by the Banach fixed point theorem. Clearly, by induction we have for all n ≥ 1 T n u ∈ Lip(Z, Kn ), Pn−1 where Kn = K1 i=0 (βK2 )i + K(βK2)n . If we choose K < K1 , then Kn ≤ Kn+1 for all n and 1 1 since K2 β < 1. Hence, T n u ∈ Lip(Z, K1 1−βK ) for all n, and therefore, therefore, Kn ↑ K1 1−βK 2 2 1 1 ∗ J ∈ Lip(Z, K1 1−βK2 ) since Lip(Z, K1 1−βK2 ) is closed with respect to the sup-norm k · k.  The following theorem is the main result of this section. Recall that the policy fˆn ∈ F is obtained by extending the optimal policy fn∗ of MDPn to Z. Theorem 5.2. We have kJ (fˆn , · ) − J ∗ k ≤ 2 2K1 1 τ (β, K2 )K1 1−βK + 1−β 2 1−β 2α(1/n)1/d, +4β+2 where τ (β, K2 ) = (2 + β)βK2 + β(1−β) and α is the coefficient in (5.1). 2 Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 33 Proof. To prove the theorem, we obtain upper bounds on the expressions derived in Section 2.1 in terms of the cardinality n of Zn . The proof of Theorem 2.2 gives kJ (fˆn , · ) − J ∗ k ≤ kTfˆn J ∗ − T̂fˆn J ∗ k + (1 + β)kJˆn∗ − J ∗ k . 1−β To prove the theorem we upper bound kTfˆn J ∗ − T̂fˆn J ∗ k and kJˆn∗ − J ∗ k in terms n. For the first term we have kTfˆn J ∗ − T̂fˆn J ∗ k = sup Tfˆn J ∗ (z) − T̂fˆn J ∗ (z)| z∈Z Z Z Z ∗ ˆ ˆ ˆ ≤ sup c(z, fn (z)) + β J (y)p(dy |z, fn (z)) − c(x, fn (x)) − β J ∗ (y)p(dy |x, fˆn (x)) νn,in (z) (dx) z∈Z Z  Z ZZ  Z ∗ ∗ ˆ ˆ ≤ sup K1 dZ (x, z) + β J (y)p(dy |z, fn(z)) − J (y)p(dy |x, fn(z)) νn,in (z) (dx) z∈Z ≤ sup z∈Z Z Z Z (since fˆn (x) = fˆn (z) for all x ∈ Sn,in (z) ) (K1 + β kJ ∗ kLip K2 )dZ (x, z)νn,in (z) (dx) ≤ (K1 + β kJ ∗ kLip K2 ) max diam(Sn,i) i∈{1,...,n} ≤ (K1 + β kJ ∗ kLip K2 )2α(1/n)1/d. (5.2) For the second term, the proof of Theorem 2.4 gives kJˆn∗ − J ∗ k ≤ kT̂n J ∗ − Fn J ∗ k + (1 + β)kJ ∗ − u∗n k . 1−β First consider kT̂n J ∗ − Fn J ∗ k. Define l(z, a) := c(z, a) + β Z J ∗ (y)p(dy |z, a), X so that J ∗ (z) = min l(z, a). a∈A It is straightforward to show that l( · , a) ∈ Lip(Z, Kl ) for all a ∈ A, where Kl = K1 + β kJ ∗ kLip K2 . By adapting the proof of Lemma 2.3 to the value function J ∗ , we obtain Z Z kT̂n J ∗ − Fn J ∗ k = sup min l(x, a)νn,in (z) (dx) − min l(x, a)νn,in (z) (dx) a∈A z∈Z Z a∈A sup l(y, ai ) − J ∗ (y) νn,in (z) (dy) ≤ sup y∈Sn,in (z) z∈Z Z  sup |l(y, ai ) − l(zi , ai )| + |J ∗ (zi ) − J ∗ (y)| νn,i (dy) ≤ max i∈{1,...,n} Z y∈Sn,i  sup Kl dZ (y, zi ) + kJ ∗ kLip dZ (zi , y) νn,i (dy) ≤ max i∈{1,...,n} y∈Sn,in ≤ (Kl + kJ ∗ kLip ) max diam(Sn,i ) i∈{1,...,n} ≤ (Kl + kJ ∗ kLip )2α(1/n)1/d. For the expression kJ ∗ − u∗n k, by Lemma 2.2 we have ku∗n − J ∗ k ≤ 2 inf kJ ∗ − Φr k, 1 − β r∈Zkn (5.3) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 34 n where Φr (z) = Σki=1 ri 1Sn,i (z), r = (r1 , . . . , rkn ). Since kJ ∗ kLip < ∞, we have inf r∈Zkn kJ ∗ − Φr k ≤ kJ ∗ kLip maxi∈{1,...,n} diam(Sn,i ) ≤ kJ ∗ kLip 2α(1/n)1/d . Hence ku∗n − J ∗ k ≤ 2 kJ ∗ kLip 2α(1/n)1/d . 1−β Hence, by (5.3) and (5.4) we obtain   K1 β +3  ∗ ∗ ∗ ˆ kJ kLip + 2α(1/n)1/d. kJn − J k ≤ βK2 + (1 − β)2 1−β (5.4) (5.5) 1 Then, the result follows from (5.2) and (5.5), and the fact kJ ∗ kLip ≤ K1 1−βK .  2 Remark 5.1. It is important to point out that if we replace Assumption 5.1-(h) with the uniform Lipschitz continuity of p( · |z, a) in z with respect to total variation distance, then Theorem 5.2 remains valid (with possibly different constants in front of the term (1/n)1/d). However, in this case, we do not need the assumption K2 β < 1. Remark 5.2. For the average cost case, instead of assuming from the outset the uniform Lipschitz continuity of c and p in the z variable, we first derive a rate of convergence result in terms of the moduli of continuity of the functions ωc and ωp in the z variable of c(z, a) and p( · |z, a), where the total variation distance is used to define ωp . Then, we state that explicit rate of convergence result can be given if we impose some structural assumptions on ωc and ωp such as linearity, which corresponds to the uniform Lipschitz continuity of c(z, a) and p( · |z, a) in z. However, this is not the right approach for the discounted cost case as the modulus of continuity function ωp is calculated using the Wasserstein distance of order 1. Indeed, to obtain a similar result as in the average cost case, we must relate ωc and ωp to the modulus of continuity ωJ ∗ of the value function J ∗ . This can be established if ωc and ωp are affine functions (i.e., ωc (r) = K1 r + L1 and ωp (r) = K2 r + L2 ) using the dual formulation of the Wasserstein distance of order 1 [39, Theorem 5.10]: Z Z W1 (µ, ν) = sup ψ(z)µ(dz) − ϕ(z)ν(dz) . (ψ,ϕ)∈Cb (Z)×Cb (Z) ψ(x)−ϕ(y)≤dZ(x,y) Z Z However, in this situation we can explicitly compute the convergence rate only if L1 = L2 = 0 which is the uniform Lipschitz continuity case. 5.2. Average Cost. In this section, we suppose that Assumptions 2.2 and 5.1-(j) hold. We define the modulus of continuity functions in the z variable of c(z, a) and p( · |z, a) as follows ωc (r) := sup sup a∈A z,y∈Z:dZ (z,y)≤r ωp (r) := sup sup |c(z, a) − c(y, a)| kp( · |z, a) − p( · |y, a)kT V . a∈A z,y∈Z:dZ (z,y)≤r Since c(z, a) and p( · |z, a) are uniformly continuous, we have limr→0 ωc (r) = 0 and limr→0 ωp (r) = 0. Note that when ωc and ωp are linear, c(z, a) and p( · |z, a) are uniformly Lipschitz in z. In the remainder of this section, we first derive a rate of convergence result in terms of ωc and ωp . Then, we explicitly compute the convergence rate for the Lipschitz case as a corollary of this result. To obtain convergence rates for the average cost, we first prove a rate of convergence result for Lemma 2.6. To this end, for each n ≥ 1, let dn := 2α(1/n)1/d, where α is the coefficient in (5.1). Lemma 5.1. For all t ≥ 1, we have sup (y,f )∈Z×F kpt ( · |y, f (y)) − qnt ( · |y, f (y))kT V ≤ tωp (dn ). Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 35 Proof. Similar to the proof of Lemma 2.6, we use induction. For t = 1, recalling the proof of Lemma 2.6, the claim holds by the following argument: sup kp( · |y, f (y)) − qn( · |y, f (y))kT V ≤ sup sup kp( · |y, a) − p( · |x, a)kT V y∈Z (x,a)∈Sn,in (y) ×A (y,f )∈Z×F ≤ ωp (dn ). Now, assume the claim is true for t ≥ 1. Again recalling the proof of Lemma 2.6, we have sup (y,f )∈Z×F kpt+1 ( · |y, f (y)) − qnt+1( · |y, f (y))kT V ≤ sup (y,f )∈Z×F pt ( · |y, f (y)) − qnt ( · |y, f (y)) + sup TV p( · |z, f (z)) − qn( · |z, f (z)) (z,f )∈Z×F TV ≤ tωp (dn ) + ωp (dn ) = (t + 1)ωp (dn ). This completes the proof.  The following theorem is the main result of this section. A somewhat similar result was obtained in Hernández-Lerma [20, Section 3.5], where identical assumptions are imposed on both the original model and the approximating model (see Hernández-Lerma [20, Assumption 5.1]). Moreover, the approximating transition probability and one-stage cost function are assumed to converge to the original transition probability and one-stage cost function with respect to some rate; that is, ρ(n) := sup(x,a)∈X×A |bn (x, a) − c(x, a)| and π(n) := sup(x,a)∈X×A kqn ( · |x, a) − p( · |x, a)kT V with ρ(n), π(n) → 0 as n → ∞. Although our result may appear to be a special case of the results in Hernández-Lerma [20, Section 3.5], there are several differences: (i) our assumptions are only imposed for the the original model, and (ii) in Hernández-Lerma [20, Section 3.5] the approximating models do not have finite state space while our approximating models are obtained by extending finite state models to the original state space, thereby, allowing for constructive numerical method to calculate near optimal policies. ^n is obtained by extending the optimal policy fn∗ for Recall that the optimal policy f˜n∗ for MDP MDPn to Z, and R and κ are the constants in Theorem 2.5. Theorem 5.3. For all t ≥ 1, we have |ρf˜n∗ − ρf ∗ | ≤ 4kckRκt + 2ωc (dn ) + 2kcktωp (dn ). Proof. The proof of Theorem 2.6 gives |ρf˜n∗ − ρf ∗ | ≤ |ρf˜n∗ − ρ̂nf˜∗ | + |ρ̂nf˜∗ − ρ̂nfˆ∗ | + |ρ̂nfˆ∗ − ρf ∗ |. n n n n Hence, to prove the theorem we obtain an upper bounds on the three terms in the sum. Consider the first term (recall the proof of Lemma 2.7) |ρf˜n∗ − ρ̂nf˜∗ | ≤ sup |ρ̂nf − ρf | n f ∈F ≤ 2Rκt kck + kck sup (y,f )∈Z×F kqnt ( · |y, f (y)) − pt( · |y, f (y))kT V ≤ 2Rκt kck + kcktωp (dn ) (by Lemma 5.1). (5.6) For the second term, the proof of Lemma 2.11 gives |ρ̂nf˜∗ − ρ̂nfˆ∗ | ≤ |ρ̂nf˜∗ − ρ̃nf˜∗ | + |ρ̃nf˜∗ − ρ̂nfˆ∗ | n n n n n n ≤ sup |ρ̂nf − ρ̃nf | + | inf ρ̃nf − inf ρ̂nf | f ∈F f ∈F f ∈F ≤ 2 sup |ρ̂nf − ρ̃nf | f ∈F ≤ 2kbn − ck Z(see the proof of Lemma 2.9) ≤2 sup |c(x, a) − c(z, a)|νn,in (z) (dx) (z,a)∈Z×A ≤ 2ωc (dn ). (5.7) Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 36 For the last term, we have |ρ̂nfˆ∗ − ρf ∗ | = | inf ρ̂nf − inf ρf | ≤ sup |ρ̂nf − ρf | n f ∈F f ∈F f ∈F ≤ 2Rκt kck + kcktωp (dn ) (by (5.6)). (5.8) Combining (5.6), (5.7), and (5.8) implies the result.  To explicitly calculate a convergence rate, we need to impose some structural assumptions on ωc and ωp . One such assumption is linearity, which corresponds to the uniform Lipschitz continuity of c(z, a) and p( · |z, a) in z. This means that ωc (r) = K1 r and ωp (r) = K2 r, or equivalently, |c(z, a) − c(y, a)| ≤ K1 dZ (z, y) and kp( · |z, a) − p( · |y, a)k ≤ K2 dZ (z, y) for all z, y ∈ Z and a ∈ Z. In this case, by Theorem 5.3, for all t ≥ 1 we have |ρf˜n∗ − ρf ∗ | ≤ 4kckRκt + 4K1 α(1/n)1/d + 4kckK2 α(1/n)1/d t. (5.9) To obtain a proper rate of convergence result (i.e., an upper bound that only depends on n) the dependence of the upper bound on t has to be written as a function of n. This can be done by (approximately) minimizing the upper bound in (5.9) with respect to t for each n. Let us define the constants I1 := 4kckR, I2 := 4K1 α, and I3 := 4kckK2 α. Then the upper bound in (5.9) becomes I1 κt + I2 (1/n)1/d + I3 (1/n)1/dt. (5.10) For each n, it is straightforward to compute that t′ (n) := ln n1/d  1 I4 ln( κ1 ) is the zero of the derivative of the convex term in (5.10), where I4 := (5.10), we obtain the following result. I3 1). I1 ln( κ Letting t = ⌈t′ (n)⌉ in Corollary 5.1. Suppose that c(z, a) and p( · |z, a) are uniformly Lipschitz continuous in z in addition to the assumptions imposed at the beginning of this section. Then, we have |ρf˜n∗ − ρf ∗ | ≤ (I1 I4 + I2 )(1/n)1/d + n1/d  I3 . (1/n)1/d ln ln(1/κ) I4 6. Order Optimality for Approximation Errors in the Rate of Quantization. The following example demonstrates that the order of the performance losses in Theorem 5.2 and 1 Corollary 5.1 cannot be better than O(( n1 ) d ). More precisely, we exhibit a simple standard example where we can lower bound the performance loss by L(1/n)1/d , for some positive constant L. A similar result was obtained in Saldi et al. [33, Section IV] for the case of quantization of action space, where the action space was a compact subset of Rm for some m ≥ 1. Therefore, when both state and action spaces are quantized, then the resulting construction is order optimal in the above sense as the approximation error, in this case, is bounded by the sum of the approximation errors in quantization of state space and quantization of action space. In what follows h( · ) and h( · | · ) denote differential and conditional differential entropies, respectively; see Cover and Thomas [12, Chapter 8]. Consider the additive-noise system: zt+1 = F (zt , at ) + vt , t = 0, 1, 2, . . . , (z,a)k < 1/2. The noise process {vt } is a sewhere zt , at , vt ∈ Rd . We assume that sup(z,a)∈Rd ×Rd kF kzk+kak quence of i.i.d. random vectors whose common distribution has density g supported on some Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 37 compact subset V of Rd . We choose V such that Z = A can be taken to be compact subsets of Rd . For simplicity suppose that the initial distribution µ has the same density g. It is assumed R that the differential entropy h(g) := − Z g(z) log g(z)dz is finite. Let the one stage cost function be c(z, a) := kz − ak. Clearly, the optimal stationary policy f ∗ is induced by the identity f ∗ (z) = z, having the optimal cost J (f ∗, µ) = 0 and V (f ∗ , µ) = 0. Let fˆn be the piece-wise constant extension  ˆ  of the optimal policy fn∗ of the MDPn to the set Z. Fix n ≥ 1 and define Dt := Eµfn c(zt , at ) for all t. Then, since at = fˆn (zt ) can take at most n values in A, by the Shannon lower bound (SLB) (see Yamada et al. [44, p. 12]) we have for t ≥ 1 log n ≥ R(Dt ) ≥ h(zt ) + θ(Dt ) = h(F (zt−1 , at−1 ) + vt−1 ) + θ(Dt) ≥ h(F (zt−1, at−1 ) + vt−1 |zt−1 , at−1 ) + θ(Dt) (6.1) = h(vt−1 ) + θ(Dt), (6.2)    d d 1 where θ(Dt ) = −d + log dV Γ(d) Dt , R(Dt ) is the rate-distortion function of zt , Vd is the volume d of the unit sphere Sd = {z : kz k ≤ 1}, and Γ is the gamma function. Here, (6.1) follows from the fact that conditioning reduces the entropy (see Cover and Thomas [12, Theorem 2.6.5, p. 29]) and (6.2) follows from the independence of vt−1 and the pair (zt−1 , at−1 ). Note that h(vt−1 ) = h(g) for all t. h(g) 1/d . Since we have obtained stage-wise error bounds, Thus, Dt ≥ L(1/n)1/d, where L := d2 dV2 Γ(d) d L ∗ 1/d ˆ these give |J (f , µ) − J (fn, µ)| ≥ 1−β (1/n) and |V (f ∗ , µ) − V (fˆn , µ)| ≥ L(1/n)1/d. Remark 6.1. We note that if h(xt+1 |xt , at ) can be lower bounded by some constant k for all t ≥ 1, above analysis still holds by replacing h(g) with k. For instance, this is the case if the transition probability p( · |x, a) admits a density which is bounded from above uniformly in (x, a). 7. Numerical Examples. In this section, we consider two examples, the additive noise model and fisheries management problem, in order to illustrate our results numerically. Since computing true costs of the policies obtained from the finite models is intractable, we only compute the value functions of the finite models and illustrate their converge to the value function of the original MDP as n → ∞. Before proceeding to the examples, we note that all results in this paper apply with straightforward modifications for the case of maximizing reward instead of minimizing cost. 7.1. Additive Noise System. In this example, the additive noise system is given by xt+1 = F (xt , at ) + vt , t = 0, 1, 2, . . . where xt , at , vt ∈ R and X = R. The noise process {vt } is a sequence of R-valued i.i.d. random variables with common density g. Hence, the transition probability p( · |x, a) is given by Z g(v − F (x, a))m(dv) for all D ∈ B (R), p(D |x, a) = D where m is the Lebesgue measure. The one-stage cost function is c(x, a) = (x − a)2 , the action space is A = [−L, L] for some L > 0, and the cost function to be minimized is the discounted cost. We assume that (i) g is a Gaussian probability density function with zero mean and variance σ 2 , (ii) supa∈A |F (x, a)|2 ≤ k1 x2 + k2 for some k1 , k2 ∈ R+ , (ii) β < 1/α for some α ≥ k1 , and (iv) F is 2 continuous. Hence, Assumption 3.1 holds for this model with w(x) = k + x2 and M = 4 Lk + x2 , for some k ∈ R+ . For the numerical results, we use the following parameters: F (x, a) = x + a, β = 0.3, L = 0.5, and σ = 0.1. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 38  15 We selected a sequence [−ln , ln ] n=1 of nested closed intervals, where ln = 0.5 + 0.25n, to approximate R. Each interval is uniformly discretized using ⌈2k⌈ n3 ⌉ ln ⌉ grid points, where km = 5m for m = 1, . . . , 5 and ⌈q ⌉ denotes the smallest integer greater than or equal to q ∈ R. Therefore, the n discretization is gradually refined. For each n, the finite state space is given by {xn,i }ki=1 ∪ {∆n }, kn where {xn,i }i=1 are the representation points in the uniform quantization of the closed interval [−ln , ln ] and ∆n is a pseudo state. We also uniformly discretize the action space A = [−0.5, 0.5] by using 2k⌈ n3 ⌉ grid points. For each n, the finite state models are constructed as in Section 2 by replacing Z with [−ln , ln ] and by setting νn ( · ) = 21 mn ( · ) + 12 δ∆n ( · ), where mn is the Lebesgue measure normalized over [−ln , ln ]. We use the value iteration algorithm to compute the value functions of the finite models. Figure 1 displays the graph of these value functions corresponding to the different values for the number of grid points, when the initial state is x = 0.7. The figure illustrates that the value functions of the finite models converge to the value function of the original model. Optimal costs 1.2 0.8 0.4 35 120 200 Number of grid points Figure 1. Optimal costs of the finite models when the initial state is x = 0.7 7.2. Fisheries Management Problem. In this example we consider the following population growth model, called a Ricker model, see Hernández-Lerma and Lasserre [21, Section 1.3]: xt+1 = θ1 at exp{−θ2 at + vt }, t = 0, 1, 2, . . . (7.1) where θ1 , θ2 ∈ R+ , xt is the population size in season t, and at is the population to be left for spawning for the next season, or in other words, xt − at is the amount of fish captured in the season t. The one-stage ‘reward’ function is u(xt − at ), where u is some utility function. In this model, the goal is to maximize the average reward. The state and action spaces are X = A = [κmin , κmax ], for some κmin , κmax ∈ R+ . Since the population left for spawning cannot be greater than the total population, for each x ∈ X, the set of admissible actions is A(x) = [κmin , x] which is not consistent with our assumptions. However, we can (equivalently) reformulate above problem so that the admissible actions A(x) will become A for all x ∈ X. In this case, instead of dynamics in equation (7.1) we have xt+1 = θ1 min(at , xt ) exp{−θ2 min(at , xt ) + vt }, t = 0, 1, 2, . . . and A(x) = [κmin , κmax ] for all x ∈ X. The one-stage reward function is u(xt − at )1{xt ≥at } . Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 39 Since X is already compact, it is sufficient to discretize [κmin , κmax ]. The noise process {vt } is a sequence of independent and identically distributed (i.i.d.) random variables which have common density g supported on [0, λ]. Therefore, the transition probability p( · |x, a) is given by    p D |x, a = Pr xt+1 ∈ D xt = x, at = a   = Pr θ1 min(a, x) exp{−θ2 min(a, x) + v } ∈ D  Z  1 g log(v) − log(θ1 min(a, x)) + θ2 min(a, x) m(dv), = v D for all D ∈ B (R). To make the model consistent, we must have θ1 y exp{−θ2 y + v } ∈ [κmin , κmax ] for all (y, v) ∈ [κmin , κmax ] × [0, λ]. We assume that (i) g > ǫ for some ǫ ∈ R+ on [0, λ], (ii) g is continuous on [0, λ], and (iii) the  utility function u is continuous. Define h(v, x, a) := g log(v) − log(θ1 min(a, x)) + θ2 min(a, x) v1 , and for each (x, a) ∈ X × A, let Sx,a denote the support of h( · , x, a). Then, Assumption 2.2 holds for this model with θ(x, a) = inf v∈Sa h(v, x, a) (provided that it is measurable), ζ = mκ (Lebesgue measure restricted on [κmin , κmax ]), and for some λ ∈ (0, 1). For the numerical results, we use the following values of the parameters: θ1 = 1.1, θ2 = 0.1, κmax = 7, κmin = 0.005, λ = 0.5. We assume that the noise process is distributed uniformly over [0, 0.5]. Hence, g ≡ 1 on [0, 0.5] and otherwise zero. The utility function u is taken to be the shifted isoelastic utility function (see Dufour and Prieto-Rumeau [13, Section 4.1])  u(z) = 3 (z + 0.5)1/3 − (0.5)1/3 . We selected 25 different values for the number n of grid points to discretize the state space: n = 10, 20, 30, . . . , 250. The grid points are chosen uniformly over the interval [κmin , κmax ]. We also uniformly discretize the action space A by using the following number of grid points: 5n = 50, 100, 150, . . . , 1250. We use the relative value iteration algorithm (see Bertsekas [5, Chapter 4.3.1]) to compute the value functions of the finite models. For each n, the finite state models are constructed as in Section 2 by replacing Z with [κmin , κmax ] and by setting νn ( · ) = mκ ( · ). Figure 2 shows the graph of the value functions of the finite models corresponding to the different values of n (number of grid points), when the initial state is x = 2. It can be seen that the value functions converge (to the value function of the original model). 8. Conclusion. The approximation of a discrete time MDP by finite-state MDPs was considered for discounted and average costs for both compact and non-compact state spaces. Under usual conditions imposed for studying Markov decision processes, it was shown that if one uses a sufficiently large number of grid points to discretize the state space, then the resulting finite-state MDP yields a near optimal policy. Under the Lipschitz continuity of the transition probability and the one-stage cost function, explicit bounds were derived on the performance loss due to discretization in terms of the number of grid points for the compact state case. These results were then illustrated numerically by considering two different MDP models. Acknowledgments. This research was supported in part by the Natural Sciences and Engineering Research Council (NSERC) of Canada. Parts of this work were presented at the American Control Conference in July 2015, Chicago, IL. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 40 0.4 Optimal rewards 0.3 0.2 0.1 50 150 Number of grid points 250 Figure 2. Optimal rewards of the finite models when the initial state is x = 2 References [1] Aliprantis, C.D., K.C. Border. 2006. Infinite Dimensional Analysis. Springer. [2] Bartoszynski, R. 1961. A characterization of the weak convergence of measures. Ann. Math. Statist. 32(2) 561–576. [3] Bertsekas, D. P., S. E. Shreve. 1978. Stochastic optimal control: The discrete time case. Academic Press New York. [4] Bertsekas, D.P. 1975. Convergence of discretization procedures in dynamic programming. IEEE Trans. Autom. Control 20(3) 415–419. [5] Bertsekas, D.P. 1995. Dynamic Programming and Optimal Control: Volume II . Athena Scientific. [6] Bertsekas, D.P., J.N. Tsitsiklis. 1996. Neuro-Dynammic Programming. Athena Scientific. [7] Blackwell, D., D. Freedman, M. Orkin. 1974. The optimal reward operator in dynamic programming. Ann. Probab. 2(2) 926–941. [8] Borkar, V. 2002. Convex analytic methods in Markov decision processes. E.A. Feinberg, A. Shwartz, eds., Handbook of Markov Decision Processes. Kluwer Academic Publisher. [9] Cavazos-Cadena, R. 1986. Finite-state approximations for denumerable state discounted Markov decision processes. Appl. Math. Optim. 14 1–26. [10] Chang, H.S., M.C. Fu, J. Hu, S.I. Marcus. 2007. A survey of some simulation-based methods in Markov decision processes. Communications in Information System 7 59–92. [11] Chow, C-S., J. N. Tsitsiklis. 1991. An optimal one-way multigrid algorithm for discrete-time stochastic control. IEEE Transactions on Automatic Control 36(8) 898–914. [12] Cover, T.M., J.A. Thomas. 2006. Elements of Information Theory. 2nd ed. Wiley. [13] Dufour, F., T. Prieto-Rumeau. 2012. Approximation of Markov decision processes with general state space. J. Math. Anal. Appl. 388 1254–1267. [14] Dufour, F., T. Prieto-Rumeau. 2013. Finite linear programming approximations of constrained discounted Markov decision processes. SIAM J. Control Optim. 51(2) 1298–1324. [15] Dufour, F., T. Prieto-Rumeau. 2014. Approximation of average cost Markov decision processes using empirical distributions and concentration inequalities. Stochastics 1–35. [16] Feinberg, E.A., P.O. Kasyanov, N.V. Zadioanchuk. 2012. Average cost Markov decision processes with weakly continuous transition probabilities. Math. Oper. Res. 37(4) 591–607. [17] Fox, B.L. 1971. Finite-state approximations to denumerable state dynamic programs. J. Math. Anal. Appl. 34 665–670. Saldi, Yüksel, and Linder: Asymptotic Optimality of Finite Approximations to MDPs Mathematics of Operations Research 00(0), pp. 000–000, c 0000 INFORMS 41 [18] Gordienko, E., O. Hernandez-Lerma. 1995. Average cost Markov control processes with weighted norms: Existence of canonical policies. Appl. Math. 23(2) 199–218. [19] Gray, G.M., D.L. Neuhoff. 1998. Quantization. IEEE Trans. Inf. Theory 44(6) 2325–2383. [20] Hernández-Lerma, O. 1989. Adaptive Markov Control Processes. Springer-Verlag. [21] Hernández-Lerma, O., J.B. Lasserre. 1996. Discrete-Time Markov Control Processes: Basic Optimality Criteria. Springer. [22] Hernández-Lerma, O., J.B. Lasserre. 1999. Further Topics on Discrete-Time Markov Control Processes. Springer. [23] Hernández-Lerma, O., J.B. Lasserre. 2003. Markov Chains and Invariant Probabilities. Birkhauser. [24] Hinderer, K. 2005. Lipschitz continuity of value functions in Markovian desision processes. Math. Meth. Oper. Res. 62 3–22. [25] Jain, R., P.P. Varaiya. 2006. Simulation-based uniform value function estimates of Markov decision processes. SIAM J. Control Optim. 45(5) 1633–1656. [26] Jaśkiewicz, A., A.S. Nowak. 2006. On the optimality equation for average cost Markov control processes with Feller transition probabilities. J. Math. Anal. Appl. 316 495–509. [27] Kuratowski, K. 1966. Topology: Volume I . Academic Press Inc. [28] Langen, H.J. 1981. Convergence of dynamic programming models. Math. Oper. Res. 6(4) 493–512. [29] Meyn, S.P., R.L. Tweedie. 1993. Markov chains and stochastic stability. New York: Springer-Verlag. [30] Ortner, R. 2007. Pseudometrics for state aggregation in average reward Markov decision processes. Algorithmic Learning Theory. Springer-Verlag. [31] Puterman, M.L. 2005. Markov Decision Processes. Wiley-Interscience. [32] Ren, Z., B.H. Krogh. 2002. State aggregation in Markov decision processes. IEEE Conf. Decision Control . Las Vegas, 3819 – 3824. [33] Saldi, N., T. Linder, S. Yüksel. 2015. Asymtotic optimality and rates of convergence of quantized stationary policies in stochastic control. IEEE Trans. Autom. Control 60(2) 553–558. [34] Saldi, N., S. Yüksel, T. Linder. 2016. Near optimality of quantized policies in stochastic control under weak continuity conditions. J. Math. Anal. Appl. 435 321–337. [35] Serfozo, R. 1982. Convergence of Lebesgue integrals with varying measures. Sankhya Ser.A 380–402. [36] Shreve, S.E., D.P. Bertsekas. 1979. Universally measurable policies in dynamic programming. Math. Oper. Res. 4(1) 15–30. [37] Van Roy, B. 2006. Performance loss bounds for approximate value iteration with state aggregation. Math. Oper. Res. 31(2) 234–244. [38] Vega-Amaya, O. 2003. The average cost optimality equation: a fixed point approach. Bol. Soc. Mat. Mexicana 9(3) 185–195. [39] Villani, C. 2009. Optimal transport: old and new . Springer. [40] White, D.J. 1980. Finite-state approximations for denumerable state infinite horizon discounted Markov decision processes. J. Math. Anal. Appl. 74 292–295. [41] White, D.J. 1982. Finite-state approximations for denumerable state infinite horizon discounted Markov decision processes with unbounded rewards. J. Math. Anal. Appl. 186 292–306. [42] Whitt, W. 1978. Approximations of dynamic programs I. Math. Oper. Res. 3(3) 231–243. [43] Whitt, W. 1979. Approximations of dynamic programs II. Math. Oper. Res. 4(2) 179–185. [44] Yamada, Y., S. Tazaki, R.M. Gray. 1980. Asymptotic performance of block quantizers with difference distortion measures. IEEE Trans. Inf. Theory 26 6–14. [45] Yu, H., D.P. Bertsekas. 2004. Discretized approximations for POMDP with average cost. The 20th Conf. UAI . Banff, Canada. [46] Yüksel, S., T. Başar. 2013. Stochastic Networked Control Systems: Stabilization and Optimization under Information Constraints. Boston, MA, Birkhauser.
3cs.SY
arXiv:1503.08895v5 [cs.NE] 24 Nov 2015 End-To-End Memory Networks Sainbayar Sukhbaatar Dept. of Computer Science Courant Institute, New York University [email protected] Arthur Szlam Jason Weston Rob Fergus Facebook AI Research New York {aszlam,jase,robfergus}@fb.com Abstract We introduce a neural network with a recurrent attention model over a possibly large external memory. The architecture is a form of Memory Network [23] but unlike the model in that work, it is trained end-to-end, and hence requires significantly less supervision during training, making it more generally applicable in realistic settings. It can also be seen as an extension of RNNsearch [2] to the case where multiple computational steps (hops) are performed per output symbol. The flexibility of the model allows us to apply it to tasks as diverse as (synthetic) question answering [22] and to language modeling. For the former our approach is competitive with Memory Networks, but with less supervision. For the latter, on the Penn TreeBank and Text8 datasets our approach demonstrates comparable performance to RNNs and LSTMs. In both cases we show that the key concept of multiple computational hops yields improved results. 1 Introduction Two grand challenges in artificial intelligence research have been to build models that can make multiple computational steps in the service of answering a question or completing a task, and models that can describe long term dependencies in sequential data. Recently there has been a resurgence in models of computation using explicit storage and a notion of attention [23, 8, 2]; manipulating such a storage offers an approach to both of these challenges. In [23, 8, 2], the storage is endowed with a continuous representation; reads from and writes to the storage, as well as other processing steps, are modeled by the actions of neural networks. In this work, we present a novel recurrent neural network (RNN) architecture where the recurrence reads from a possibly large external memory multiple times before outputting a symbol. Our model can be considered a continuous form of the Memory Network implemented in [23]. The model in that work was not easy to train via backpropagation, and required supervision at each layer of the network. The continuity of the model we present here means that it can be trained end-to-end from input-output pairs, and so is applicable to more tasks, i.e. tasks where such supervision is not available, such as in language modeling or realistically supervised question answering tasks. Our model can also be seen as a version of RNNsearch [2] with multiple computational steps (which we term “hops”) per output symbol. We will show experimentally that the multiple hops over the long-term memory are crucial to good performance of our model on these tasks, and that training the memory representation can be integrated in a scalable manner into our end-to-end neural network model. 2 Approach Our model takes a discrete set of inputs x1 , ..., xn that are to be stored in the memory, a query q, and outputs an answer a. Each of the xi , q, and a contains symbols coming from a dictionary with V words. The model writes all x to the memory up to a fixed buffer size, and then finds a continuous representation for the x and q. The continuous representation is then processed via multiple hops to output a. This allows backpropagation of the error signal through multiple memory accesses back to the input during training. 1 2.1 Single Layer We start by describing our model in the single layer case, which implements a single memory hop operation. We then show it can be stacked to give multiple hops in memory. Input memory representation: Suppose we are given an input set x1 , .., xi to be stored in memory. The entire set of {xi } are converted into memory vectors {mi } of dimension d computed by embedding each xi in a continuous space, in the simplest case, using an embedding matrix A (of size d×V ). The query q is also embedded (again, in the simplest case via another embedding matrix B with the same dimensions as A) to obtain an internal state u. In the embedding space, we compute the match between u and each memory mi by taking the inner product followed by a softmax: pi = Softmax(uT mi ). where Softmax(zi ) = ezi / P j (1) ezj . Defined in this way p is a probability vector over the inputs. Output memory representation: Each xi has a corresponding output vector ci (given in the simplest case by another embedding matrix C). The response vector from the memory o is then a sum over the transformed inputs ci , weighted by the probability vector from the input: X p i ci . (2) o= i Because the function from input to output is smooth, we can easily compute gradients and backpropagate through it. Other recently proposed forms of memory or attention take this approach, notably Bahdanau et al. [2] and Graves et al. [8], see also [9]. Generating the final prediction: In the single layer case, the sum of the output vector o and the input embedding u is then passed through a final weight matrix W (of size V × d) and a softmax to produce the predicted label: â = Softmax(W (o + u)) (3) The overall model is shown in Fig. 1(a). During training, all three embedding matrices A, B and C, as well as W are jointly learned by minimizing a standard cross-entropy loss between â and the true label a. Training is performed using stochastic gradient descent (see Section 4.2 for more details). W Softmax {xi} A2 Input mi A1 Embedding B Question q (a) u1 Predicted Answer o1 C1 Inner Product u u2 ^ a o2 C2 Sentences Embedding A u3 Out1 In1 Weights pi Sentences {xi} C3 Out2 In2 ci W o3 A3 Output Embedding C Predicted Answer ^ a Out3 In3 u Weighted Sum Softmax o B (b) Question q Figure 1: (a): A single layer version of our model. (b): A three layer version of our model. In practice, we can constrain several of the embedding matrices to be the same (see Section 2.2). 2.2 Multiple Layers We now extend our model to handle K hop operations. The memory layers are stacked in the following way: • The input to layers above the first is the sum of the output ok and the input uk from layer k (different ways to combine ok and uk are proposed later): uk+1 = uk + ok . 2 (4) • Each layer has its own embedding matrices Ak , C k , used to embed the inputs {xi }. However, as discussed below, they are constrained to ease training and reduce the number of parameters. • At the top of the network, the input to W also combines the input and the output of the top memory layer: â = Softmax(W uK+1 ) = Softmax(W (oK + uK )). We explore two types of weight tying within the model: 1. Adjacent: the output embedding for one layer is the input embedding for the one above, i.e. Ak+1 = C k . We also constrain (a) the answer prediction matrix to be the same as the final output embedding, i.e W T = C K , and (b) the question embedding to match the input embedding of the first layer, i.e. B = A1 . 2. Layer-wise (RNN-like): the input and output embeddings are the same across different layers, i.e. A1 = A2 = ... = AK and C 1 = C 2 = ... = C K . We have found it useful to add a linear mapping H to the update of u between hops; that is, uk+1 = Huk + ok . This mapping is learnt along with the rest of the parameters and used throughout our experiments for layer-wise weight tying. A three-layer version of our memory model is shown in Fig. 1(b). Overall, it is similar to the Memory Network model in [23], except that the hard max operations within each layer have been replaced with a continuous weighting from the softmax. Note that if we use the layer-wise weight tying scheme, our model can be cast as a traditional RNN where we divide the outputs of the RNN into internal and external outputs. Emitting an internal output corresponds to considering a memory, and emitting an external output corresponds to predicting a label. From the RNN point of view, u in Fig. 1(b) and Eqn. 4 is a hidden state, and the model generates an internal output p (attention weights in Fig. 1(a)) using A. The model then ingests p using C, updates the hidden state, and so on1 . Here, unlike a standard RNN, we explicitly condition on the outputs stored in memory during the K hops, and we keep these outputs soft, rather than sampling them. Thus our model makes several computational steps before producing an output meant to be seen by the “outside world”. 3 Related Work A number of recent efforts have explored ways to capture long-term structure within sequences using RNNs or LSTM-based models [4, 7, 12, 15, 10, 1]. The memory in these models is the state of the network, which is latent and inherently unstable over long timescales. The LSTM-based models address this through local memory cells which lock in the network state from the past. In practice, the performance gains over carefully trained RNNs are modest (see Mikolov et al. [15]). Our model differs from these in that it uses a global memory, with shared read and write functions. However, with layer-wise weight tying our model can be viewed as a form of RNN which only produces an output after a fixed number of time steps (corresponding to the number of hops), with the intermediary steps involving memory input/output operations that update the internal state. Some of the very early work on neural networks by Steinbuch and Piske[19] and Taylor [21] considered a memory that performed nearest-neighbor operations on stored input vectors and then fit parametric models to the retrieved sets. This has similarities to a single layer version of our model. Subsequent work in the 1990’s explored other types of memory [18, 5, 16]. For example, Das et al. [5] and Mozer et al. [16] introduced an explicit stack with push and pop operations which has been revisited recently by [11] in the context of an RNN model. Closely related to our model is the Neural Turing Machine of Graves et al. [8], which also uses a continuous memory representation. The NTM memory uses both content and address-based access, unlike ours which only explicitly allows the former, although the temporal features that we will introduce in Section 4.1 allow a kind of address-based access. However, in part because we always write each memory sequentially, our model is somewhat simpler, not requiring operations like sharpening. Furthermore, we apply our memory model to textual reasoning tasks, which qualitatively differ from the more abstract operations of sorting and recall tackled by the NTM. 1 Note that in this view, the terminology of input and output from Fig. 1 is flipped - when viewed as a traditional RNN with this special conditioning of outputs, A becomes part of the output embedding of the RNN and C becomes the input embedding. 3 Our model is also related to Bahdanau et al. [2]. In that work, a bidirectional RNN based encoder and gated RNN based decoder were used for machine translation. The decoder uses an attention model that finds which hidden states from the encoding are most useful for outputting the next translated word; the attention model uses a small neural network that takes as input a concatenation of the current hidden state of the decoder and each of the encoders hidden states. A similar attention model is also used in Xu et al. [24] for generating image captions. Our “memory” is analogous to their attention mechanism, although [2] is only over a single sentence rather than many, as in our case. Furthermore, our model makes several hops on the memory before making an output; we will see below that this is important for good performance. There are also differences in the architecture of the small network used to score the memories compared to our scoring approach; we use a simple linear layer, whereas they use a more sophisticated gated architecture. We will apply our model to language modeling, an extensively studied task. Goodman [6] showed simple but effective approaches which combine n-grams with a cache. Bengio et al. [3] ignited interest in using neural network based models for the task, with RNNs [14] and LSTMs [10, 20] showing clear performance gains over traditional methods. Indeed, the current state-of-the-art is held by variants of these models, for example very large LSTMs with Dropout [25] or RNNs with diagonal constraints on the weight matrix [15]. With appropriate weight tying, our model can be regarded as a modified form of RNN, where the recurrence is indexed by memory lookups to the word sequence rather than indexed by the sequence itself. 4 Synthetic Question and Answering Experiments We perform experiments on the synthetic QA tasks defined in [22] (using version 1.1 of the dataset). A given QA task consists of a set of statements, followed by a question whose answer is typically a single word (in a few tasks, answers are a set of words). The answer is available to the model at training time, but must be predicted at test time. There are a total of 20 different types of tasks that probe different forms of reasoning and deduction. Here are samples of three of the tasks: Sam walks into the kitchen. Sam picks up an apple. Sam walks into the bedroom. Sam drops the apple. Q: Where is the apple? A. Bedroom Brian is a lion. Julius is a lion. Julius is white. Bernhard is green. Q: What color is Brian? A. White Mary journeyed to the den. Mary went back to the kitchen. John journeyed to the bedroom. Mary discarded the milk. Q: Where was the milk before the den? A. Hallway Note that for each question, only some subset of the statements contain information needed for the answer, and the others are essentially irrelevant distractors (e.g. the first sentence in the first example). In the Memory Networks of Weston et al. [22], this supporting subset was explicitly indicated to the model during training and the key difference between that work and this one is that this information is no longer provided. Hence, the model must deduce for itself at training and test time which sentences are relevant and which are not. Formally, for one of the 20 QA tasks, we are given example problems, each having a set of I sentences {xi } where I ≤ 320; a question sentence q and answer a. Let the jth word of sentence i be xij , represented by a one-hot vector of length V (where the vocabulary is of size V = 177, reflecting the simplistic nature of the QA language). The same representation is used for the question q and answer a. Two versions of the data are used, one that has 1000 training problems per task and a second larger one with 10,000 per task. 4.1 Model Details Unless otherwise stated, all experiments used a K = 3 hops model with the adjacent weight sharing scheme. For all tasks that output lists (i.e. the answers are multiple words), we take each possible combination of possible outputs and record them as a separate answer vocabulary word. Sentence Representation: In our experiments we explore two different representations for the sentences. The first is the bag-of-words (BoW) representation that takes P the sentence xi = {xi1 , xi2 , ..., xin }, embeds each word and sums the resulting vectors: e.g mi = j Axij and P ci = j Cxij . The input vector u representing the question is also embedded as a bag of words: P u = j Bqj . This has the drawback that it cannot capture the order of the words in the sentence, which is important for some tasks. We therefore propose a second representation that encodes the position of words within the P sentence. This takes the form: mi = j lj · Axij , where · is an element-wise multiplication. lj is a 4 column vector with the structure lkj = (1 − j/J) − (k/d)(1 − 2j/J) (assuming 1-based indexing), with J being the number of words in the sentence, and d is the dimension of the embedding. This sentence representation, which we call position encoding (PE), means that the order of the words now affects mi . The same representation is used for questions, memory inputs and memory outputs. Temporal Encoding: Many of the QA tasks require some notion of temporal context, i.e. in the first example of Section 2, the model needs to understand that Sam is in the bedroom after he is in the P kitchen. To enable our model to address them, we modify the memory vector so that mi = j Axij + TA (i), where TA (i) is the ith row of a special matrix TA that encodes temporal information. The output embedding is augmented in the same way with a matrix Tc P (e.g. ci = j Cxij + TC (i)). Both TA and TC are learned during training. They are also subject to the same sharing constraints as A and C. Note that sentences are indexed in reverse order, reflecting their relative distance from the question so that x1 is the last sentence of the story. Learning time invariance by injecting random noise: we have found it helpful to add “dummy” memories to regularize TA . That is, at training time we can randomly add 10% of empty memories to the stories. We refer to this approach as random noise (RN). 4.2 Training Details 10% of the bAbI training set was held-out to form a validation set, which was used to select the optimal model architecture and hyperparameters. Our models were trained using a learning rate of η = 0.01, with anneals every 25 epochs by η/2 until 100 epochs were reached. No momentum or weight decay was used. The weights were initialized randomly from a Gaussian distribution with zero mean and σ = 0.1. When trained on all tasks simultaneously with 1k training samples (10k training samples), 60 epochs (20 epochs) were used with learning rate anneals of η/2 every 15 epochs (5 epochs). All training uses a batch size of 32 (but cost is not averaged over a batch), and gradients with an `2 norm larger than 40 are divided by a scalar to have norm 40. In some of our experiments, we explored commencing training with the softmax in each memory layer removed, making the model entirely linear except for the final softmax for answer prediction. When the validation loss stopped decreasing, the softmax layers were re-inserted and training recommenced. We refer to this as linear start (LS) training. In LS training, the initial learning rate is set to η = 0.005. The capacity of memory is restricted to the most recent 50 sentences. Since the number of sentences and the number of words per sentence varied between problems, a null symbol was used to pad them all to a fixed size. The embedding of the null symbol was constrained to be zero. On some tasks, we observed a large variance in the performance of our model (i.e. sometimes failing badly, other times not, depending on the initialization). To remedy this, we repeated each training 10 times with different random initializations, and picked the one with the lowest training error. 4.3 Baselines We compare our approach2 (abbreviated to MemN2N) to a range of alternate models: • MemNN: The strongly supervised AM+NG+NL Memory Networks approach, proposed in [22]. This is the best reported approach in that paper. It uses a max operation (rather than softmax) at each layer which is trained directly with supporting facts (strong supervision). It employs n-gram modeling, nonlinear layers and an adaptive number of hops per query. • MemNN-WSH: A weakly supervised heuristic version of MemNN where the supporting sentence labels are not used in training. Since we are unable to backpropagate through the max operations in each layer, we enforce that the first memory hop should share at least one word with the question, and that the second memory hop should share at least one word with the first hop and at least one word with the answer. All those memories that conform are called valid memories, and the goal during training is to rank them higher than invalid memories using the same ranking criteria as during strongly supervised training. • LSTM: A standard LSTM model, trained using question / answer pairs only (i.e. also weakly supervised). For more detail, see [22]. 2 MemN2N source code is available at https://github.com/facebook/MemNN. 5 4.4 Results We report a variety of design choices: (i) BoW vs Position Encoding (PE) sentence representation; (ii) training on all 20 tasks independently vs jointly training (joint training used an embedding dimension of d = 50, while independent training used d = 20); (iii) two phase training: linear start (LS) where softmaxes are removed initially vs training with softmaxes from the start; (iv) varying memory hops from 1 to 3. The results across all 20 tasks are given in Table 1 for the 1k training set, along with the mean performance for 10k training set3 . They show a number of interesting points: • The best MemN2N models are reasonably close to the supervised models (e.g. 1k: 6.7% for MemNN vs 12.6% for MemN2N with position encoding + linear start + random noise, jointly trained and 10k: 3.2% for MemNN vs 4.2% for MemN2N with position encoding + linear start + random noise + non-linearity4 , although the supervised models are still superior. • All variants of our proposed model comfortably beat the weakly supervised baseline methods. • The position encoding (PE) representation improves over bag-of-words (BoW), as demonstrated by clear improvements on tasks 4, 5, 15 and 18, where word ordering is particularly important. • The linear start (LS) to training seems to help avoid local minima. See task 16 in Table 1, where PE alone gets 53.6% error, while using LS reduces it to 1.6%. • Jittering the time index with random empty memories (RN) as described in Section 4.1 gives a small but consistent boost in performance, especially for the smaller 1k training set. • Joint training on all tasks helps. • Importantly, more computational hops give improved performance. We give examples of the hops performed (via the values of eq. (1)) over some illustrative examples in Fig. 2 and in Appendix B. Baseline Task 1: 1 supporting fact 2: 2 supporting facts 3: 3 supporting facts 4: 2 argument relations 5: 3 argument relations 6: yes/no questions 7: counting 8: lists/sets 9: simple negation 10: indefinite knowledge 11: basic coreference 12: conjunction 13: compound coreference 14: time reasoning 15: basic deduction 16: basic induction 17: positional reasoning 18: size reasoning 19: path finding 20: agent’s motivation Mean error (%) Failed tasks (err. > 5%) Strongly Supervised MemNN [22] 0.0 0.0 0.0 0.0 2.0 0.0 15.0 9.0 0.0 2.0 0.0 0.0 0.0 1.0 0.0 0.0 35.0 5.0 64.0 0.0 6.7 4 LSTM [22] 50.0 80.0 80.0 39.0 30.0 52.0 51.0 55.0 36.0 56.0 38.0 26.0 6.0 73.0 79.0 77.0 49.0 48.0 92.0 9.0 51.3 20 MemNN WSH 0.1 42.8 76.4 40.3 16.3 51.0 36.1 37.8 35.9 68.7 30.0 10.1 19.7 18.3 64.8 50.5 50.9 51.3 100.0 3.6 40.2 18 BoW 0.6 17.6 71.0 32.0 18.3 8.7 23.5 11.4 21.1 22.8 4.1 0.3 10.5 1.3 24.3 52.0 45.4 48.1 89.7 0.1 25.1 15 PE 0.1 21.6 64.2 3.8 14.1 7.9 21.6 12.6 23.3 17.4 4.3 0.3 9.9 1.8 0.0 52.1 50.1 13.6 87.4 0.0 20.3 13 PE LS 0.2 12.8 58.8 11.6 15.7 8.7 20.3 12.7 17.0 18.6 0.0 0.1 0.3 2.0 0.0 1.6 49.0 10.1 85.6 0.0 16.3 12 PE LS RN 0.0 8.3 40.3 2.8 13.1 7.6 17.3 10.0 13.2 15.1 0.9 0.2 0.4 1.7 0.0 1.3 51.0 11.1 82.8 0.0 13.9 11 On 10k training data Mean error (%) Failed tasks (err. > 5%) 3.2 2 36.4 16 39.2 17 15.4 9 9.4 6 7.2 4 6.6 4 MemN2N 1 hop 2 hops PE LS PE LS joint joint 0.8 0.0 62.0 15.6 76.9 31.6 22.8 2.2 11.0 13.4 7.2 2.3 15.9 25.4 13.2 11.7 5.1 2.0 10.6 5.0 8.4 1.2 0.4 0.0 6.3 0.2 36.9 8.1 46.4 0.5 47.4 51.3 44.4 41.2 9.6 10.3 90.7 89.9 0.0 0.1 25.8 15.6 17 11 24.5 16 10.9 7 3 hops PE LS joint 0.1 14.0 33.1 5.7 14.8 3.3 17.9 10.1 3.1 6.6 0.9 0.3 1.4 8.2 0.0 3.5 44.5 9.2 90.2 0.0 13.3 11 PE LS RN joint 0.0 11.4 21.9 13.4 14.4 2.8 18.3 9.3 1.9 6.5 0.3 0.1 0.2 6.9 0.0 2.7 40.4 9.4 88.0 0.0 12.4 11 PE LS LW joint 0.1 18.8 31.7 17.5 12.9 2.0 10.1 6.1 1.5 2.6 3.3 0.0 0.5 2.0 1.8 51.0 42.6 9.2 90.6 0.2 15.2 10 7.9 6 7.5 6 11.0 6 Table 1: Test error rates (%) on the 20 QA tasks for models using 1k training examples (mean test errors for 10k training examples are shown at the bottom). Key: BoW = bag-of-words representation; PE = position encoding representation; LS = linear start training; RN = random injection of time index noise; LW = RNN-style layer-wise weight tying (if not stated, adjacent weight tying is used); joint = joint training on all tasks (as opposed to per-task training). 5 Language Modeling Experiments The goal in language modeling is to predict the next word in a text sequence given the previous words x. We now explain how our model can easily be applied to this task. 3 4 More detailed results for the 10k training set can be found in Appendix A. Following [17] we found adding more non-linearity solves tasks 17 and 19, see Appendix A. 6 Story (1: 1 supporting fact) Support Hop 1 Hop 2 Daniel went to the bathroom. 0.00 0.00 Mary travelled to the hallway. 0.00 0.00 John went to the bedroom. 0.37 0.02 John travelled to the bathroom. yes 0.60 0.98 Mary went to the office. 0.01 0.00 Where is John? Answer: bathroom Prediction: bathroom Hop 3 0.03 0.00 0.00 0.96 0.00 Story (2: 2 supporting facts) John dropped the milk. John took the milk there. Sandra went back to the bathroom. John moved to the hallway. Mary went back to the bedroom. Where is the milk? Answer: hallway Support Hop 1 0.06 0.88 0.00 yes 0.00 0.00 Prediction: hallway Story (16: basic induction) Support Hop 1 Hop 2 Brian is a frog. yes 0.00 0.98 Lily is gray. 0.07 0.00 Brian is yellow. yes 0.07 0.00 Julius is green. 0.06 0.00 Greg is a frog. yes 0.76 0.02 What color is Greg? Answer: yellow Prediction: yellow Hop 3 0.00 0.00 1.00 0.00 0.00 Story (18: size reasoning) Support Hop 1 Hop 2 Hop 3 The suitcase is bigger than the chest. yes 0.00 0.88 0.00 The box is bigger than the chocolate. 0.04 0.05 0.10 The chest is bigger than the chocolate. yes 0.17 0.07 0.90 The chest fits inside the container. 0.00 0.00 0.00 The chest fits inside the box. 0.00 0.00 0.00 Does the suitcase fit in the chocolate? Answer: no Prediction: no yes Hop 2 0.00 1.00 0.00 0.00 0.00 Hop 3 0.00 0.00 0.00 1.00 0.00 Figure 2: Example predictions on the QA tasks of [22]. We show the labeled supporting facts (support) from the dataset which MemN2N does not use during training, and the probabilities p of each hop used by the model during inference. MemN2N successfully learns to focus on the correct supporting sentences. Model RNN [15] LSTM [15] SCRN [15] MemN2N # of hidden 300 100 100 150 150 150 150 150 150 150 150 150 150 150 150 150 Penn Treebank # of memory Valid. hops size perp. 133 120 120 2 100 128 3 100 129 4 100 127 5 100 127 6 100 122 7 100 120 6 25 125 6 50 121 6 75 122 6 100 122 6 125 120 6 150 121 7 200 118 Test perp. 129 115 115 121 122 120 118 115 114 118 114 114 115 112 114 111 # of hidden 500 500 500 500 500 500 500 500 500 500 500 500 500 500 500 - # of hops 2 3 4 5 6 7 6 6 6 6 6 6 - Text8 memory size 100 100 100 100 100 100 25 50 75 100 125 150 - Valid. perp. 122 152 142 129 123 124 118 131 132 126 124 125 123 - Test perp. 184 154 161 187 178 162 154 155 147 163 166 158 155 157 154 - Table 2: The perplexity on the test sets of Penn Treebank and Text8 corpora. Note that increasing the number of memory hops improves performance. Figure 3: Average activation weight of memory positions during 6 memory hops. White color indicates where the model is attending during the k th hop. For clarity, each row is normalized to have maximum value of 1. A model is trained on (left) Penn Treebank and (right) Text8 dataset. We now operate on word level, as opposed to the sentence level. Thus the previous N words in the sequence (including the current) are embedded into memory separately. Each memory cell holds only a single word, so there is no need for the BoW or linear mapping representations used in the QA tasks. We employ the temporal embedding approach of Section 4.1. Since there is no longer any question, q in Fig. 1 is fixed to a constant vector 0.1 (without embedding). The output softmax predicts which word in the vocabulary (of size V ) is next in the sequence. A cross-entropy loss is used to train model by backpropagating the error through multiple memory layers, in the same manner as the QA tasks. To aid training, we apply ReLU operations to half of the units in each layer. We use layer-wise (RNN-like) weight sharing, i.e. the query weights of each layer are the same; the output weights of each layer are the same. As noted in Section 2.2, this makes our architecture closely related to an RNN which is traditionally used for language 7 modeling tasks; however here the “sequence” over which the network is recurrent is not in the text, but in the memory hops. Furthermore, the weight tying restricts the number of parameters in the model, helping generalization for the deeper models which we find to be effective for this task. We use two different datasets: Penn Tree Bank [13]: This consists of 929k/73k/82k train/validation/test words, distributed over a vocabulary of 10k words. The same preprocessing as [25] was used. Text8 [15]: This is a a pre-processed version of the first 100M million characters, dumped from Wikipedia. This is split into 93.3M/5.7M/1M character train/validation/test sets. All word occurring less than 5 times are replaced with the <UNK> token, resulting in a vocabulary size of ∼44k. 5.1 Training Details The training procedure we use is the same as the QA tasks, except for the following. For each mini-batch update, the `2 norm of the whole gradient of all parameters is measured5 and if larger than L = 50, then it is scaled down to have norm L. This was crucial for good performance. We use the learning rate annealing schedule from [15], namely, if the validation cost has not decreased after one epoch, then the learning rate is scaled down by a factor 1.5. Training terminates when the learning rate drops below 10−5 , i.e. after 50 epochs or so. Weights are initialized using N (0, 0.05) and batch size is set to 128. On the Penn tree dataset, we repeat each training 10 times with different random initializations and pick the one with smallest validation cost. However, we have done only a single training run on Text8 dataset due to limited time constraints. 5.2 Results Table 2 compares our model to RNN, LSTM and Structurally Constrained Recurrent Nets (SCRN) [15] baselines on the two benchmark datasets. Note that the baseline architectures were tuned in [15] to give optimal perplexity6 . Our MemN2N approach achieves lower perplexity on both datasets (111 vs 115 for RNN/SCRN on Penn and 147 vs 154 for LSTM on Text8). Note that MemN2N has ∼1.5x more parameters than RNNs with the same number of hidden units, while LSTM has ∼4x more parameters. We also vary the number of hops and memory size of our MemN2N, showing the contribution of both to performance; note in particular that increasing the number of hops helps. In Fig. 3, we show how MemN2N operates on memory with multiple hops. It shows the average weight of the activation of each memory position over the test set. We can see that some hops concentrate only on recent words, while other hops have more broad attention over all memory locations, which is consistent with the idea that succesful language models consist of a smoothed n-gram model and a cache [15]. Interestingly, it seems that those two types of hops tend to alternate. Also note that unlike a traditional RNN, the cache does not decay exponentially: it has roughly the same average activation across the entire memory. This may be the source of the observed improvement in language modeling. 6 Conclusions and Future Work In this work we showed that a neural network with an explicit memory and a recurrent attention mechanism for reading the memory can be successfully trained via backpropagation on diverse tasks from question answering to language modeling. Compared to the Memory Network implementation of [23] there is no supervision of supporting facts and so our model can be used in a wider range of settings. Our model approaches the same performance of that model, and is significantly better than other baselines with the same level of supervision. On language modeling tasks, it slightly outperforms tuned RNNs and LSTMs of comparable complexity. On both tasks we can see that increasing the number of memory hops improves performance. However, there is still much to do. Our model is still unable to exactly match the performance of the memory networks trained with strong supervision, and both fail on several of the 1k QA tasks. Furthermore, smooth lookups may not scale well to the case where a larger memory is required. For these settings, we plan to explore multiscale notions of attention or hashing, as proposed in [23]. Acknowledgments The authors would like to thank Armand Joulin, Tomas Mikolov, Antoine Bordes and Sumit Chopra for useful comments and valuable discussions, and also the FAIR Infrastructure team for their help and support. 5 In the QA tasks, the gradient of each weight matrix is measured separately. They tuned the hyper-parameters on Penn Treebank and used them on Text8 without additional tuning, except for the number of hidden units. See [15] for more detail. 6 8 References [1] C. G. Atkeson and S. Schaal. Memory-based neural networks for robot learning. Neurocomputing, 9:243–269, 1995. [2] D. Bahdanau, K. Cho, and Y. Bengio. Neural machine translation by jointly learning to align and translate. In International Conference on Learning Representations (ICLR), 2015. [3] Y. Bengio, R. Ducharme, P. Vincent, and C. Janvin. A neural probabilistic language model. J. Mach. Learn. Res., 3:1137–1155, Mar. 2003. [4] J. Chung, Ç. Gülçehre, K. Cho, and Y. Bengio. Empirical evaluation of gated recurrent neural networks on sequence modeling. arXiv preprint: 1412.3555, 2014. [5] S. Das, C. L. Giles, and G.-Z. Sun. Learning context-free grammars: Capabilities and limitations of a recurrent neural network with an external stack memory. In In Proceedings of The Fourteenth Annual Conference of Cognitive Science Society, 1992. [6] J. Goodman. A bit of progress in language modeling. CoRR, cs.CL/0108005, 2001. [7] A. Graves. Generating sequences with recurrent neural networks. arXiv preprint: 1308.0850, 2013. [8] A. Graves, G. Wayne, and I. Danihelka. Neural turing machines. arXiv preprint: 1410.5401, 2014. [9] K. Gregor, I. Danihelka, A. Graves, and D. Wierstra. DRAW: A recurrent neural network for image generation. CoRR, abs/1502.04623, 2015. [10] S. Hochreiter and J. Schmidhuber. Long short-term memory. Neural computation, 9(8):1735– 1780, 1997. [11] A. Joulin and T. Mikolov. Inferring algorithmic patterns with stack-augmented recurrent nets. NIPS, 2015. [12] J. Koutnı́k, K. Greff, F. J. Gomez, and J. Schmidhuber. A clockwork RNN. In ICML, 2014. [13] M. P. Marcus, M. A. Marcinkiewicz, and B. Santorini. Building a large annotated corpus of english: The Penn Treebank. Comput. Linguist., 19(2):313–330, June 1993. [14] T. Mikolov. Statistical language models based on neural networks. Ph. D. thesis, Brno University of Technology, 2012. [15] T. Mikolov, A. Joulin, S. Chopra, M. Mathieu, and M. Ranzato. Learning longer memory in recurrent neural networks. arXiv preprint: 1412.7753, 2014. [16] M. C. Mozer and S. Das. A connectionist symbol manipulator that discovers the structure of context-free languages. NIPS, pages 863–863, 1993. [17] B. Peng, Z. Lu, H. Li, and K. Wong. Towards Neural Network-based Reasoning. ArXiv preprint: 1508.05508, 2015. [18] J. Pollack. The induction of dynamical recognizers. Machine Learning, 7(2-3):227–252, 1991. [19] K. Steinbuch and U. Piske. Learning matrices and their applications. IEEE Transactions on Electronic Computers, 12:846–862, 1963. [20] M. Sundermeyer, R. Schlüter, and H. Ney. LSTM neural networks for language modeling. In Interspeech, pages 194–197, 2012. [21] W. K. Taylor. Pattern recognition by means of automatic analogue apparatus. Proceedings of The Institution of Electrical Engineers, 106:198–209, 1959. [22] J. Weston, A. Bordes, S. Chopra, and T. Mikolov. Towards AI-complete question answering: A set of prerequisite toy tasks. arXiv preprint: 1502.05698, 2015. [23] J. Weston, S. Chopra, and A. Bordes. Memory networks. In International Conference on Learning Representations (ICLR), 2015. [24] K. Xu, J. Ba, R. Kiros, K. Cho, A. Courville, R. Salakhutdinov, R. Zemel, and Y. Bengio. Show, Attend and Tell: Neural Image Caption Generation with Visual Attention. ArXiv preprint: 1502.03044, 2015. [25] W. Zaremba, I. Sutskever, and O. Vinyals. Recurrent neural network regularization. arXiv preprint arXiv:1409.2329, 2014. 9 Appendix A Results on 10k QA dataset Baseline Task 1: 1 supporting fact 2: 2 supporting facts 3: 3 supporting facts 4: 2 argument relations 5: 3 argument relations 6: yes/no questions 7: counting 8: lists/sets 9: simple negation 10: indefinite knowledge 11: basic coreference 12: conjunction 13: compound coreference 14: time reasoning 15: basic deduction 16: basic induction 17: positional reasoning 18: size reasoning 19: path finding 20: agent’s motivation Mean error (%) Failed tasks (err. > 5%) Strongly Supervised MemNN 0.0 0.0 0.0 0.0 0.3 0.0 3.3 1.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 24.6 2.1 31.9 0.0 3.2 2 LSTM 0.0 81.9 83.1 0.2 1.2 51.8 24.9 34.1 20.2 30.1 10.3 23.4 6.1 81.0 78.7 51.9 50.1 6.8 90.3 2.1 36.4 16 MemNN WSH 0.1 39.6 79.5 36.6 21.1 49.9 35.1 42.7 36.4 76.0 25.3 0.0 12.3 8.7 68.8 50.9 51.1 45.8 100.0 4.1 39.2 17 BoW 0.0 0.6 17.8 31.8 14.2 0.1 10.7 1.4 1.8 1.9 0.0 0.0 0.0 0.0 12.5 50.9 47.4 41.3 75.4 0.0 15.4 9 PE 0.0 0.4 12.6 0.0 0.8 0.2 5.7 2.4 1.3 1.7 0.0 0.0 0.1 0.2 0.0 48.6 40.3 7.4 66.6 0.0 9.4 6 PE LS 0.0 0.5 15.0 0.0 0.6 0.1 3.2 2.2 2.0 3.3 0.0 0.0 0.0 0.0 0.0 0.1 41.1 8.6 66.7 0.0 7.2 4 PE LS RN 0.0 0.3 9.3 0.0 0.8 0.0 3.7 0.8 0.8 2.4 0.0 0.0 0.0 0.0 0.0 0.4 40.7 6.7 66.5 0.0 6.6 4 PE LS LW RN∗ 0.0 0.3 2.1 0.0 0.8 0.1 2.0 0.9 0.3 0.0 0.1 0.0 0.0 0.1 0.0 51.8 18,6 5.3 2.3 0.0 4.2 3 MemN2N 1 hop PE LS joint 0.0 62.0 80.0 21.4 8.7 6.1 14.8 8.9 3.7 10.3 8.3 0.0 5.6 30.9 42.6 47.3 40.0 9.2 91.0 0.0 24.5 16 2 hops PE LS joint 0.0 1.3 15.8 0.0 7.2 0.7 10.5 4.7 0.4 0.6 0.0 0.0 0.0 0.2 0.0 46.4 39.7 10.1 80.8 0.0 10.9 7 3 hops PE LS joint 0.0 2.3 14.0 0.0 7.5 0.2 6.1 4.0 0.0 0.4 0.0 0.0 0.0 0.2 0.0 0.4 41.7 8.6 73.3 0.0 7.9 6 PE LS RN joint 0.0 1.0 6.8 0.0 6.1 0.1 6.6 2.7 0.0 0.5 0.0 0.1 0.0 0.0 0.2 0.2 41.8 8.0 75.7 0.0 7.5 6 PE LS LW joint 0.0 0.8 18.3 0.0 0.8 0.1 8.4 1.4 0.2 0.0 0.4 0.0 0.0 1.7 0.0 49.2 40.0 8.4 89.5 0.0 11.0 6 Table 3: Test error rates (%) on the 20 bAbI QA tasks for models using 10k training examples. Key: BoW = bag-of-words representation; PE = position encoding representation; LS = linear start training; RN = random injection of time index noise; LW = RNN-style layer-wise weight tying (if not stated, adjacent weight tying is used); joint = joint training on all tasks (as opposed to per-task training); ∗ = this is a larger model with non-linearity (embedding dimension is d = 100 and ReLU applied to the internal state after each hop. This was inspired by [17] and crucial for getting better performance on tasks 17 and 19). 10 Appendix B Visualization of attention weights in QA problems Story (1: 1 supporting fact) Daniel went to the bathroom. Mary travelled to the hallway. John went to the bedroom. John travelled to the bathroom. Mary went to the office. Sandra journeyed to the kitchen. Where is John? Answer: bathroom Support Hop 1 0.00 0.00 0.37 yes 0.60 0.01 0.01 Prediction: bathroom Hop 2 0.00 0.00 0.02 0.98 0.00 0.00 Hop 3 0.03 0.00 0.00 0.96 0.00 0.00 Story (2: 2 supporting facts) John dropped the milk. Daniel travelled to the bedroom. John took the milk there. Sandra went back to the bathroom. John moved to the hallway. Mary went back to the bedroom. Where is the milk? Answer: hallway Support yes yes Hop 1 0.06 0.00 0.88 0.00 0.00 0.00 Hop 2 0.00 0.00 1.00 0.00 0.00 0.00 Hop 3 0.00 0.00 0.00 0.00 1.00 0.00 Hop 1 0.84 0.16 Hop 2 1.00 0.00 Hop 3 0.92 0.08 Hop 2 0.00 0.00 0.45 0.39 0.16 0.00 0.00 Hop 3 0.01 0.00 0.16 0.04 0.00 0.00 0.00 Prediction: hallway Story (3: 3 supporting facts) Support Hop 1 Hop 2 John moved to the hallway. 0.00 0.00 John grabbed the football. yes 0.00 1.00 John journeyed to the garden. 0.35 0.00 Sandra moved to the hallway. 0.00 0.00 John went back to the hallway. yes 0.00 0.00 John journeyed to the garden. yes 0.62 0.00 Where was the football before the garden? A: hallway P: hallway Hop 3 0.00 0.00 0.00 0.00 1.00 0.00 Story (4: 2 argument relations) The garden is north of the kitchen. The kitchen is north of the bedroom. Story (5: 3 argument relations) Support Hop 1 Jeff travelled to the bedroom. 0.00 Jeff journeyed to the garden. 0.00 Fred handed the apple to Jeff. yes 1.00 Mary went to the garden. 0.00 Fred went back to the bathroom. 0.00 Fred got the milk there. 0.00 Mary journeyed to the kitchen. 0.00 Who gave the apple to Jeff? Answer: Fred Prediction: Fred Hop 2 0.00 0.00 1.00 0.00 0.00 0.00 0.00 Hop 3 0.00 0.00 0.98 0.00 0.00 0.00 0.00 Story (6: yes/no questions) Sandra travelled to the bedroom. John took the football there. Sandra travelled to the office. Sandra went to the bedroom. Daniel went back to the kitchen. John took the apple there. Mary got the milk there. Is Sandra in the bedroom? Answer: yes Story (7: counting) Support Hop 1 Hop 2 Daniel moved to the office. 0.00 0.00 Mary moved to the office. 0.00 0.00 Sandra picked up the apple there. yes 0.14 0.00 Sandra dropped the apple. yes 0.12 0.00 Sandra took the apple there. yes 0.73 1.00 John went to the bedroom. 0.00 0.00 How many objects is Sandra carrying? Answer: one Prediction: one Hop 3 0.00 0.00 0.92 0.00 0.08 0.00 Story (8: lists/sets) Support Hop 1 John moved to the hallway. 0.00 John journeyed to the garden. 0.00 Daniel moved to the garden. 0.00 Daniel grabbed the apple there. yes 0.03 Daniel got the milk there. yes 0.97 John went back to the hallway. 0.00 What is Daniel carrying? Answer: apple,milk Prediction: apple,milk Hop 2 0.00 0.00 0.01 0.00 0.02 0.00 Hop 3 0.00 0.00 0.00 0.98 0.00 0.00 Story (9: simple negation) Support Hop 1 Sandra is in the garden. 0.60 Sandra is not in the garden. yes 0.37 John went to the office. 0.00 John is in the bedroom. 0.00 Daniel moved to the garden. 0.00 Is Sandra in the garden? Answer: no Prediction: no Hop 2 0.99 0.01 0.00 0.00 0.00 Hop 3 0.00 1.00 0.00 0.00 0.00 Story (10: indefinite knowledge) Julie is either in the school or the bedroom. Julie is either in the cinema or the park. Bill is in the park. Bill is either in the office or the office. Hop 1 0.00 0.00 0.00 1.00 Hop 2 0.00 0.00 0.00 1.00 Hop 3 0.00 0.00 0.00 1.00 Story (11: basic coherence) Support Mary journeyed to the hallway. After that she journeyed to the bathroom. Mary journeyed to the garden. Then she went to the office. Sandra journeyed to the garden. yes Then she went to the hallway. yes Where is Sandra? Answer: hallway Prediction: hallway Hop 1 0.00 0.00 0.00 0.01 0.97 0.00 Hop 2 0.01 0.00 0.00 0.06 0.42 0.50 Hop 3 0.00 0.00 0.00 0.00 0.00 1.00 Story (12: conjunction) Support John and Sandra went back to the kitchen. Sandra and Mary travelled to the garden. Mary and Daniel travelled to the office. Mary and John went to the bathroom. Daniel and Sandra went to the kitchen. yes Daniel and Mary journeyed to the office. Where is Sandra? Answer: kitchen Prediction: kitchen Hop 1 0.08 0.05 0.00 0.01 0.74 0.06 Hop 2 0.00 0.00 0.00 0.00 1.00 0.00 Hop 3 0.00 0.00 0.00 0.00 1.00 0.00 Story (13: compound coherence) Support Hop 1 Sandra and Daniel travelled to the bathroom. 0.13 Afterwards they went back to the office. 0.01 Daniel and Mary travelled to the hallway. 0.01 Following that they went back to the office. 0.06 Mary and Sandra moved to the hallway. yes 0.59 Then they went to the kitchen. yes 0.02 Where is Sandra? Answer: kitchen Prediction: kitchen Hop 2 0.00 0.00 0.00 0.04 0.02 0.94 Hop 3 0.00 0.00 0.00 0.00 0.00 1.00 Story (14: time reasoning) Support Hop 1 Hop 2 This morning Julie went to the cinema. 0.00 0.03 Julie journeyed to the kitchen yesterday. 0.00 0.04 Fred travelled to the cinema yesterday. 0.00 0.05 Bill travelled to the office yesterday. 0.00 0.07 This morning Mary travelled to the bedroom. yes 0.97 0.27 Yesterday Mary journeyed to the cinema. yes 0.01 0.33 Where was Mary before the bedroom? Answer: cinema Prediction: cinema Hop 3 0.00 0.01 0.01 0.01 0.01 0.96 Story (15: basic deduction) Cats are afraid of wolves. Sheep are afraid of wolves. Winona is a sheep. Emily is a sheep. Gertrude is a cat. Wolves are afraid of mice. Mice are afraid of wolves. Jessica is a mouse. What is gertrude afraid of? Answer: wolf Support Hop 1 yes 0.00 0.00 0.00 0.00 yes 0.99 0.00 0.00 0.00 Prediction: wolf Hop 2 0.99 0.00 0.00 0.00 0.00 0.00 0.00 0.00 Hop 3 0.62 0.31 0.00 0.00 0.00 0.00 0.07 0.00 Story (16: basic induction) Lily is a swan. Brian is a frog. Lily is gray. Brian is yellow. Julius is a swan. Bernhard is yellow. Julius is green. Greg is a frog. What color is Greg? Answer: yellow Hop 2 0.00 0.98 0.00 0.00 0.00 0.00 0.00 0.02 Hop 3 0.00 0.00 0.00 1.00 0.00 0.00 0.00 0.00 Support Hop 1 yes 0.37 yes 0.63 Hop 2 0.95 0.05 Hop 3 0.58 0.43 Hop 2 0.88 0.05 0.07 0.00 0.00 Hop 3 0.00 0.10 0.90 0.00 0.00 Is the triangle above the red square? Answer: yes Prediction: no Story (18: size reasoning) Support Hop 1 The suitcase is bigger than the chest. yes 0.00 The box is bigger than the chocolate. 0.04 The chest is bigger than the chocolate. yes 0.17 The chest fits inside the container. 0.00 The chest fits inside the box. 0.00 Does the suitcase fit in the chocolate? Answer: no Prediction: no Story (19: path finding) Support Hop 1 Hop 2 Hop 3 The hallway is north of the kitchen. 1.00 1.00 1.00 The garden is south of the kitchen. yes 0.00 0.00 0.00 The garden is east of the bedroom. yes 0.00 0.00 0.00 The bathroom is south of the bedroom. 0.00 0.00 0.00 The office is east of the garden. 0.00 0.00 0.00 How do you go from the kitchen to the bedroom? Answer: s,w Prediction: n,n Story (20: agent's motivation) Support Hop 1 Hop 2 Yann journeyed to the kitchen. 0.00 0.00 Yann grabbed the apple there. 0.00 0.00 Antoine is thirsty. yes 0.17 0.00 Jason picked up the milk there. 0.01 0.00 Antoine travelled to the kitchen. 0.77 1.00 Why did antoine go to the kitchen? Answer: thirsty Prediction: thirsty Hop 3 0.00 0.00 0.98 0.00 0.00 Story (17: positional reasoning) The red square is below the red sphere. The red sphere is below the triangle. Support yes What is north of the kitchen? Answer: garden Prediction: garden Support yes Hop 1 0.06 0.00 0.00 0.89 0.00 0.00 0.00 Prediction: Yes Support yes Is Bill in the office? Answer: maybe Prediction: maybe Support yes yes yes Prediction: yellow Hop 1 0.00 0.00 0.07 0.07 0.00 0.04 0.06 0.76 Figure 4: Examples of attention weights during different memory hops for the bAbi tasks. The model is PE+LS+RN with 3 memory hops that is trained separately on each task with 10k training data. The support column shows which sentences are necessary for answering questions. Although this information is not used, the model succesfully learns to focus on the correct support sentences on most of the tasks. The hop columns show where the model put more weight (indicated by values and blue color) during its three hops. The mistakes made by the model are highlighted by red color. 11
9cs.NE
From Maxout to Channel-Out: Encoding Information on Sparse Pathways Qi Wang Department of ECE and Institute for Advanced Computer Studies University of Maryland College Park, MD Joseph JaJa Department of ECE and Institute for Advanced Computer Studies University of Maryland College Park, MD [email protected] [email protected] Abstract searchers have come up with what can be perceived as a similar principle from years of study of the human brain: It is not the shape of the signal, but the pathway along which the signal flows, that determines the functionality [10]. We use this principle as an important clue to explore the encoding capabilities of deep networks. In this paper we provide a new insight into a possible reason for the success of maxout, namely that it partially takes advantage of what we call “sparse pathway coding”, a much more robust way of encoding categorical information than encoding by magnitudes. In sparse pathway encoding, the pathway selection itself carries significant amount of the categorical information. With a carefully designed scheme, the network can extract pattern-specific pathways during training time and recognize the correct pathway at inference time. Guided by this principle, we propose a new class of network architectures called “channel-out networks”. Unlike the maxout network, this type of networks does not only form sparse input pathways a posteriori, but it also actively selects outgoing pathways. We run experiments on channel-out networks using several image classification benchmarks, all of which show similar or better performance results compared with maxout. In fact, the channelout network sets new state-of-the-art performance on some image classification datasets that are on the “harder” end of the spectrum (i.e., those with lower current state-of-theart performance), namely CIFAR-100 and STL-10, demonstrating its potential to encode large amounts of information with higher level of complexity. Channel-out is just one example of using the sparse pathway encoding principle, which we believe is a promising research direction for designing other types of deep network architectures. Motivated by an important insight from neural science, we propose a new framework for understanding the success of the recently proposed “maxout” networks. The framework is based on encoding information on sparse pathways and recognizing the correct pathway at inference time. Elaborating further on this insight, we propose a novel deep network architecture, called “channel-out” network, which takes a much better advantage of sparse pathway encoding. In channel-out networks, pathways are not only formed a posteriori, but they are also actively selected according to the inference outputs from the lower layers. From a mathematical perspective, channel-out networks can represent a wider class of piece-wise continuous functions, thereby endowing the network with more expressive power than that of maxout networks. We test our channel-out networks on several well-known image classification benchmarks, setting new state-of-the-art performance on CIFAR-100 and STL-10, which represent some of the “harder” image classification benchmarks. 1. Introduction Most of the recent work on deep learning has focused on ways to regularize network behavior to avoid over-fitting. Dropout [8] has been widely accepted as an effective way for deep network regularization. Dropout was initially proposed to avoid co-adaptation of feature detectors, but it turns out it can also be regarded as an efficient ensemble model. The maxout network [7] is a newly proposed micro architecture of deep networks, which works well with the dropout technique. It sets the state-of-the-art performance on many popular image classification datasets. In retrospect, both methods follow the same approach: they restrict updates triggered by a training sample to affect only a sparse sub-graph of the network. We note that neural science re- 2. Dropout vs Maxout: Ensemble of SubModels vs Recognizable Sub-Models In this section we briefly review the concepts of dropout [8] and maxout [7], and introduce the concept of sparse 1 pathway encoding. Dropout regularizes the network during the training phase by randomly crossing out some of the nodes upon the processing of each training sample. Therefore it restricts the updates to happen only along a relatively sparse subnetwork. As has been pointed out in a number of papers [8, 18, 20], dropout networks can be regarded as performing efficient model averaging of a large ensemble of models randomly sampled from the original network, so that each model learns a different representation of the data. The maxout network is a recently proposed microarchitecture that is significantly different from traditional networks: the activation function does not take a normal single-input-single-output form, but instead the maximum of the activations from several candidate nodes. In [7], the advantage of maxout over normal differentiable activation functions (such as tanh) was attributed to its better approximation to the exact model averaging, and the advantage of maxout over the rectified linear activation function was attributed to easier optimization on maxout networks. Here we propose another insight of the power of the maxout network. The maxout node activates only one of the candidate input pathways depending on the input, and when the gradient (the novel information discovered from the current training sample) is back-propagated, only that selected pathway is updated with the information, which it encodes (Figure 1). Therefore the information conveyed by each training sample is compactly encoded onto a local portion of the network, instead of being disseminated across the entire network. We call this behavior as “sparse pathway coding”. Moreover, due to the local invariance of the max-linear function, the network can “remember” the correct pathway selection for the same or similar test sample. At inference time, if a test sample is similar to a certain pattern encoded, then it is more likely to activate a pathway that is similar to the one activated by this pattern. Correct inference can therefore be made with awareness of that pattern-specific pathway. To sum up, The maxout network encodes information sparsely on distinct pathways, and has the capability of retrieving the correct pathway at inference time. This observation is well in line with the famous principle in neural science, “The information conveyed by an action potential is determined not by the form of the signal but by the pathway the signal travels in the brain” [10]. max-out node winner max(·) Figure 1: Sparse pathway coding by maxout networks. Effective information flows only along the red links. link selection is ever made. Higher layer pathway selections are not aware of the selections made in lower layers. A natural extension is to endow the network with the capability of active output pathway selection, which may result in a more efficient pathway coding. Along this line, we propose a class of new deep network architectures called “channelout networks”. A channel-out network is characterized by channel-out groups (Figure 2). At the end of the linear portion in a typical layer (can be fully connected, convolutional, or locally connected), output nodes are arranged into groups, and for each group, a special channel selection function is performed to decide which channel opens for further information flow. Only the activation of the selected channel is passed through, all other channels are blocked off (this is realized by masking the corresponding channel output by 0). When the gradient is back-propagated through this channel-out layer, it only passes through the open channels selected during forward propagation. Formally, we first define a vector-valued channel selection function f (a1 , a2 , ..., ak ) which takes as input a vector of length k and outputs an index set of length l (l < k). Elements of the index set are selected from the domain {1, 2, ..., k}. Then with an input vector (typically the previous layer output) a = (a1 , a2 , ..., ak ) ∈ Rk , a channel-out group implements the following activation functions: hi = I{i∈f (a1 ,a2 ,...,ak )} ai (1) where I(·) is the indicator function, i indexes the candidates in the channel-out group, ai is the ith candidate input, and hi is the output (Figure 2). There are many possible choices of the channel selection function f (·). To ensure good performance, we require that the channel selection function possesses the following properties: 3. Channel-Out Networks 3.1. Pushing the sparse pathway concept further Although maxout networks implement the concept of sparse pathway coding, the pathways are formed “a posteriori”, meaning that a pathway selection is only implicitly implemented with already-formed input paths, but no active • The function must be piece-wise constant, and the piece-wise constant regions should not be too small. Intuitively, the function has to be “regular enough” to ensure robustness against the noise in the data. 2 ... maxout node layer n+1 0 a2 0 a4 x n1 (h) Maxout network channel selection func: f (a1 , a2 , a3 , a4 )  {2, 4} a1 a2 a3 a4 channel selection func f(·) arg max(·) Channel-out network channel-out group Figure 3: Difference between maxout and channel-out: A maxout node is attached to a set of FIXED output links, resulting in same output pathway for different input pathways; A channel-out group is connected to a set of different output links, resulting in distinct output pathways. layer n ... xn Figure 2: Operation performed by a channel-out group • The pre-image size of each possible index output must be of almost the same size. In other words, each channel in the channel-out group should be equally likely to be selected as we process the training examples (so that the information capacity of the network is fully utilized). (a) Automobile (b) Frog Figure 4: Pathway patterns for two classes in CIFAR-10 • The computation cost for evaluating the function must be as low as possible. can potentially make the computation very fast. Training a channel-out network that has a similar number of parameters as a maxout network, assuming a scalar channel selection function, can in theory be done k times faster than the maxout network, where k is the size of channel-out/maxout groups. We are currently working on this fast implementation. To confirm that pathway selection is indeed indicative of the patterns in the data, we record the pathway selections of a well-trained maxout model and a channel-out model (with max(·) channel selection function) using the CIFAR-10 dataset. For ease of visualization and analysis, we set the size of maxout/channel-out groups to 2, so that we can use 0/1 to represent the pathway selection at each maxout/channel-out group. Figure 4 shows the channel-out pathway patterns of two classes, where each row records the pathway selections of all channel-out groups (only part of them are shown in the window) when performing inference on a specific test sample. We can clearly observe many class-specific string patterns, indicating that pathway selection patterns indeed subsume important clue of categorization. Some of the salient patterns have been marked with red rectangles. To better visualize the space of pathway patterns, we perform PCA analysis on the pathway pattern vectors and project them into the three dimensional space. Figures 5 and 6 show the results for channel-out and maxout, respectively. We can see that clusters have been well formed. Some examples of good channel selection functions are: arg max(·), arg min(·), arg median(·), indices of the l largest candidates, and the absolute-max arg max(| · |). The test results reported in this paper all used the arg max(·) function. The characteristics of a channel-out network is better illustrated through a comparison with the maxout network (Figure 3). In a maxout network, a maxout node only takes the maximum value of the candidates, without the outgoing links being aware of the index. In contrast, in the channelout network, the channel-out group knows about the index of the open channel, and output link selection is made possible by this extra piece of information. In summary, the main characteristic of a channel-out network is that a channel-out group uses channel selection information to determine future inference pathways. In a deep convolutional network for 2D image classification, channel-out groups can be implemented by performing the channel selection function across groups of feature maps after convolution/multiplication. Similar to maxout networks, channel-out can be regarded as a special kind of cross-feature pooling. Moreover, in addition to the channel output value, hf (a) , the index vector itself f (a) should also be recorded into an index matrix, so that the open pathway can be retrieved during back-propagation. We can further take advantage of the index vector to implement sparse convolution and sparse matrix multiplication, avoiding wasteful computations of multiplications by zeros. This 3 25 airplane automobile bird cat deer dog frog horse ship truck 20 15 10 5 Theorem: Any piece-wise continuous function defined on a compact domain in Euclidean space can be approximated arbitrarily well by a max(·) two-layer channelout network with one hidden channel-out group with finite number of candidate nodes. That is, denote the target function to be approximated as T (x), then ∀� > 0, we can find a two-layer channel-out network with one hidden channel-out group that implements a function F (·) such � that |T (x) − F (x)|2 dx < �. Here by a “piece-wise continuous function” we refer to a function that is constituted of finite number of continuous segments. The proof is straightforward and is not of much technical significance. It is listed in the Appendix section. airplane automobile bird cat deer dog frog horse ship truck 30 20 10 0 0 −5 −10 −20 −10 30 −30 0 −15 20 10 0 −10 −20 −10 −20 −20 −25 0 −20 −40 30 20 10 0 −10 −20 −30 −30 −30 Figure 5: 3D visualization of the pathway pattern: channelout airplane automobile bird cat deer dog frog horse ship truck 40 30 20 airplane automobile bird cat deer dog frog horse ship truck 40 30 20 10 0 10 −10 0 −20 −10 −30 −20 −40 −40 −20 −30 −100 −50 0 −40 −40 −30 −20 −10 0 10 20 30 40 50 3.3. Channel-out network does more efficient pathway switching 0 20 40 60 −15 −20 −25 −30 −35 −40 −45 −50 −55 Local learning behaviors on maxout and channel-out networks can be categorized into two classes: activation tuning (mild change) and pathway switching (critical change). Activation tuning happens when the desired parameter update is not significant enough to change the pathway selection, otherwise pathway switching occurs. Channel-out and maxout networks show very different behaviors upon pathway switching. We discuss it under a simple scenario in which we repeatedly present the same training sample to the network. For a maxout node, when pathway switching happens, the gradient propagated to the maxout node must be to decrease the activation. However, the effective activation decrease will be thresholded by the activation level of the second largest candidate activation, which slows down, but does not steer away the decreasing trend (we are assuming that the network structure above this maxout node is relatively invariant across different presentations of the training sample). Under this scenario, updates will typically alternate between candidate pathways, reducing the overall efficiency of updates. In contrast, for a channel-out network, whenever a pathway switches in a channel-out group, the effective structure above the channel-out group is drastically changed due to the distinct output links selected by the channel-out group, resulting in significant change in the desired direction of the activation update. In other words, when current pathway is too far from fitting the data well, the channel-out group tends to switch and start training a new pathway from scratch. Clearly this is a more desired behavior for pathway switching. Figure 6: 3D visualization of the pathway pattern: maxout Although these clusters are not perfect, they still demonstrate that considerable amount of categorical information has been encoded by pathway patterns. We can also see that the channel-out model results in better clusters than those generated by maxout. For example, the frog class (yellow stars) is better separated from the other classes in the channel-out case. Another interesting observation is that, while the channel-out and maxout models have been trained independently with completely random parameter initialization, the relative 3D positions of the classes in the visualization show very similar spatial structures. This implies that the pathway pattern provides a very robust representation of the underlying patterns in the data. In the next few sub-sections we argue from different perspectives why the channel-out network manifests the concept of sparse pathway selection better than maxout, and why it can potentially exhibit better performances on classification tasks. 3.2. Expressive power of the channel-out network Universal representation/approximation property is a good indication of the expressive power of a model. The fact that a two-layer circuit of logic gates can represent any boolean function [14] implies the nonlinear expressive power of early shallow neural networks. Existence of functions that are computable with polynomial-size networks with k layers while requiring exponential-size networks with k − 1 layers implies the benefit of using deep architectures [1]. More recently, the fact that maxout networks are universal approximator of any continuous function is an indication of its good performance [7]. Channel-out networks also have strong universal approximation properties. Take the max(·) channel selection function as an example, we can prove the following theorem: 4. Sparse Pathway Selection as a Regularization Method In this section we consider different principles underlying sparse pathway methods (channel-out/maxout) and dropout in terms of regularizing network training. We argue that the strengths of sparse pathway selection and dropout complement each other. This explains the main reason 4 that sparse pathway methods, when combined with dropout, outperforms traditional neural network models. We believe that sparse pathway encoding is a general direction that is well worth pursuing in future research for designing deep network architectures. Maxout and channel-out networks are just two examples along this direction. Prototypes: Network capacity: Encoding pattern on traditional deep networks Dropout encoding pattern 4.1. Dropout regularization: squeezing all information into each sub-network Channel-out/Maxout encoding pattern Dropout + Channel-out/Maxout encoding pattern Recall that dropout, with each presentation of a training sample, samples a sub-network and encodes the information revealed by the training sample onto this sub-network. Since the sampling of data and sub-networks are independent processes, in a statistical sense the information provided by each training sample will eventually be “squeezed” into all these sub-networks (third row of Figure 7). The advantage of such scheme, as has been pointed out in various papers [8, 18, 20], is that the same piece of information is encoded into many different representations, adding to the robustness at inference time. The side-effect, which has not been highlighted before, is that encoding conflicting pieces of information densely into sub-networks with small capacities causes interference problem. Data samples of different patterns (classes) attempt to build different, maybe highly conflicting network representations. When the sub-network is not large enough to hold all the information, conflicting parts tend to cancel each other, resulting in significant information loss. An extreme case is the practice of training several networks independently (on the same dataset) and combine them by naive averaging of the link weights, which clearly does not make much sense in general. Note that although dropout is disseminating the training set information over the entire network, it is significantly different from a normal deep network without any regularization. For the latter, retrieval of information relies on overall cooperation of the entire network, where each subnetwork only encodes PART of the information (second row of Figure 7). In contrast the dropout network tries to encode the entire information in EACH sub-network. Subnetworks interact with each other more by averaging (or voting), rather than by cooperation. Figure 7: Information encoding patterns. Each bin of the network capacity represents a certain size sub-network. Dropout tends to encode all patterns to each capacity bin, resulting in efficient use of network capacity but high level of interference; Sparse pathway methods tend to encode each pattern to a specific sparse sub-network, resulting in least interference but waste of network capacity; The best approach is the combination of the two schemes. sparse path way regularization, however, is that network capacity could be under-utilized. Since sub-networks are highly pattern-specific, and there are only a few fundamental patterns in the data, only a small subset of the entire network is selected and trained, leaving the rest of the network capacity in an “idle” state. This is a waste of the network capacity. Now it is not hard to understand why combining dropout and sparse pathway encoding could result in better performance: the combination takes advantage of the strengths of both methods to do more efficient information coding, as illustrated in the last row of Figure 7. Notice that encoding data pattern(s) into sparse pathways is also different from encoding partial patterns into sub-networks, as is done in a normal network without regularization. In a non-regularized network, the information encoded on a sub-network is not likely to form complete patterns, while in sparse pathway methods a certain subnetwork always tries to encode complete patterns. Here we note also the significant difference between sparse pathway methods and standard sparse feature learning techniques [3, 13, 16], which is that a sparse pathway model must also possess the ability of RECOGNIZING the correct pathway during inference time. An empirical observation in support of our arguments about dropout/sparse pathway encoding pattern is seen when we take extremes of either of the regularization directions in our experiments. We observe that when dropout rate is set too high (number of alive nodes too few for each training sample), the dominating problem is under-fitting, where we see both training and test set precision cease to 4.2. Sparse pathway regularization: encoding different patterns into different sub-networks In contrast to dropout, sparse pathway regularization methods tend to encode information in a more specialized way. Each pattern of the training data is likely to be encoded onto one or a few specialized sub-networks (for the simplest case, readers can consider each class as of one pattern). This is illustrated in the fourth row of Figure 7. Clearly, sparse pathway methods mitigate the interference problem caused by dropout. The problem with pure 5 Method Maxout+Dropout [7] Channel-out+Dropout CNN+Spearmint [17] Stochastic Pooling [21] improve at very early epochs. When no dropout is applied, the dominating problem is over-fitting, where we see training set precision growing very fast while test set precision is not catching up with the improvement of training set fitness. This is in line with our major assumption about deficiencies of each method: dropout causes interference, while pure sparse pathway encoding forgoes using redundant network capacity to enhance robustness, thus is more vulnerable to over-fitting. Precision 88.32% 86.80% 85.02% 84.87% Table 1: Best methods on CIFAR-10 3 convolutional channel-out layers, followed by a fully connected channel-out layer, and then the softmax layer. The best model has 64-192-192 filters for the corresponding convolutional layers, and 1210 nodes in the fully connected layer. Each convolutional layer consists of a linear convolution portion, a max pooling portion and the channel-out portion. The fully-connected layer has a fully-connected linear portion and a channel-out portion. The channel-out group sizes are set as 2-2-2-5 for corresponding layers. Dropout with probability 0.5 is applied to the inputs of layers 2,3,4, and dropout with probability 0.2 is applied to the input of the first layer - the image itself. Here we would like to thank Goodfellow, etc. for providing an opensource for the maxout code in pylearn2, since many of our hyper-parameters for the CIFAR-10 dataset were tuned with the help of the .yaml configuration files in the pylearn2 repository. The best test precision of the channel-out network is 86.80%, which is not as good as the state-of-the-art reported in [7] using the maxout network (88.32%), but is better than any of the other previous methods (as far as we know). The best results on CIFAR-10 without data augmentation are summarized in Table 1. We believe that the channel-out performance could be further improved if we use a larger network and the hyper-parameters are better tuned. Aware of the fact that the performance can be highly dependent on hyper-parameter settings, we implemented our own code for maxout networks and compared them with our model using two different control settings: similar number of parameters or similar number of feature maps. For the former case, the maxout network is of size 96-256-2561210 (number of filters/feature maps in each layer). A maxout network of this size has a similar total number of parameters (weights) as our channel-out network. For the latter case, it is of size 64-192-192-1210, i.e. having exactly same number of feature maps as the channel-out network. Note that this results in significantly less parameters in the maxout network. The results are shown in Table 2. We can see that the channel-out network has nearly same performance as a maxout network with similar number of parameters, but is significantly better than a maxout network with same number of feature maps. We argue that the second comparison is reasonable in the sense that although having different numbers of parameters, their implementations require the same number of multiplication/addition 5. Benchmark Results 5.1. Overview of results In this section we show the performance of the channelout network on several image classification benchmarks. For all the channel-out networks used in our experiments, the channel selection function is the max(·) function. We run tests on CIFAR-10, CIFAR-100 [11] and STL-10 [4], significantly outperforming the state-of-the-art results on the last two datasets. Our implementation is built on top of the efficient convolution CUDA kernels developed by Alex Krizhevsky [11]. Most experiments are done using a Tesla C2050 GPU. Due to the time limit, we had to control the size of our networks, and we could only put a limited effort on optimizing the hyper-parameters (totally relying on manual trials). Despite of these constraints, we still managed to get state-of-the-art performance on CIFAR-100 (63.4%) and STL-10 (69.5%), indicating the great potential of channel-out networks on difficult classification tasks. We believe that we can further improve our current result of channel-out networks on CIFAR-10 (86.80%) if parameters are better tuned. We did not put our effort on developing optimized channel-out networks for easier image classification tasks, such as MNIST [12] and SVHN [15] (digit images) since we believe these tasks will not demonstrate the strengths of channel-out networks, which is better at encoding a large amount of highly variant patterns. 5.2. CIFAR-10 The CIFAR-10 dataset[11] consists of 32 × 32 × 3 small color images of 10 object classes. There are 5000 training images and 1000 test images for each class. There are significant variations in the images regarding shape and pose, and the images are not well centered. Previous experiments on CIFAR-10 typically take two methodologies: with or without data augmentation. To better compare the generalization power of different models, we focus on the non-augmented version, namely using the whole images without any translation, flipping or rotation. However, we did perform ZCA whitening using the make cifar10 gcn whitened.py code in the pylearn2 repository [6]. The network used for CIFAR-10 experiment consists of 6 Precision 86.80% 86.73% 84.35% 80 channel−out precision maxout precision 75 classification precision Network Channel-out+Dropout Maxout with similar number of parameters Maxout with same number of feature maps Table 2: Comparison between channel-out and maxout with different settings Method Channel-out+Dropout Maxout+Dropout [7] Stochastic Pooling [21] Receptive Field Learning [9] 70 65 60 55 50 10 Precision 63.41% 61.43% 57.49% 54.23% 20 30 40 50 60 70 number of classes 80 90 100 Figure 8: Comparison of channel-out and maxout on 4 tasks of different difficult levels: channel-out does better on harder tasks. STL-10 dogs Table 3: Best methods on CIFAR-100 CIFAR-10 dogs STL-10 horses operations, resulting in a similar training time. The faster version of the channel-out network is still under construction, which will take advantage of the structured sparseness of outputs of channel-out groups. We predict that it will be at least significantly faster than the maxout network with a similar number of parameters. CIFAR-10 horses Figure 9: Example images in STL-10 and CIFAR-10 datasets: STL-10 dataset has more variations. The results justify our claim that channel-out is not best suited for the case when there is relatively a small amount of information that needs to be stored (the 10-class task). In such a case, interference between patterns is less of a problem. As the patterns become more complex, channelout surpasses maxout due to its better implementation of sparse pathway encoding. Notice the unusual fact that both methods perform better for the 100-class task than for the 50-class task. This may be due to uneven distribution of difficulty among the data. The first 50 classes seem to be more difficult to discriminate. 5.3. CIFAR-100 The CIFAR-100 dataset [11] is similar to CIFAR-10, but with 100 classes. There are 500 training images and 100 test images for each class. Both the larger number of labels and the smaller training sets make the task much more difficult than the CIFAR-10 dataset. The channel-out network developed for the CIFAR-100 has 3 convolutional layers followed by a fully connected layer and the softmax layer, with feature maps 80-176-1761210. The channel-out group sizes are 2-2-2-5. Similar to the CIFAR-10 experiment, we applied 0.2 dropout probability to the input layer and 0.5 dropout to all other layers. Images are pre-whitened and when presented to the network each time, they are horizontally flipped with probability 0.5. The test set precision was 63.41%, improving the current state-of-the-art by nearly 2 percentage points. Table 3 shows the best results on CIFAR-100. Motivated by the better performance on the CIFAR-100, we perform another experiment to illustrate the fact that channel-out networks are better at harder tasks where the data patterns show more variances. We extract 10, 20, 50, 100 classes from the original dataset (both training and testing) to generate 4 training-testing pairs. We train a channelout and a maxout network with a similar number of parameters for each of the four classification tasks. The performance results are shown in Figure 8. Note that to facilitate faster experimentation, we have deliberately used much smaller networks for this series of experiments. 5.4. STL-10 STL-10 [4] contains images from 10 classes, typically with more variant shapes and more complex backgrounds than CIFAR-10 images. Figure 9 shows the comparison between STL-10 and CIFAR-10 images. The original images are of size 96 × 96 × 3. There are 500 training and 800 test images for each class. There are additional 100,000 unlabeled images for unsupervised learning. Our best channel-out network for STL-10 consists of three convolutional layers followed a fully-connected layer and the softmax layer, with feature maps 64-176-256-1212. The channel-out group sizes are set as 4-4-4-4. Dropout is applied same way as before. To reduce the complexity, we down-sampled all images to 32 × 32. Images are pre-whitened, and horizontally flipped with probability 0.5 when presented to the network. We got the state-of-the-art test precision of 69.5%, which improves the current state7 Method Channel-out+Dropout Hierarchical Matching Pursuit [2] Discriminative Learning of SPN [5] Precision 69.5% 64.5% 62.3% [5] [6] Table 4: Best methods on STL-10 [7] of-the-art by 5%. Best results on STL-10 are shown in Table 4. Note that in our experiments the network is trained with the training set only. The unsupervised corpus is only involved in the whitening process. The good performance on STL-10 shows that channelout network does a better job at discriminating more variant patterns, and ruling out the interference of complex backgrounds. This further demonstrates that information is stored more efficiently in a channel-out network. [8] [9] 6. Conclusions [10] We have introduced the concept of sparse pathway coding and argued that this can be a robust and efficient way for encoding categorical information in a deep network. Using sparse pathway encoding, the interference between conflicting patterns is mitigated, and therefore when combined with dropout, the network can utilize the network capacity in a more effective way. Along this direction we have proposed a novel class of deep networks, the channel-out networks. Our experiments show that channel-out networks perform very well on image classification tasks, especially for the harder tasks with more complex patterns. We believe that the concept of sparse pathway coding is well worth pursuing further for designing robust deep networks. [11] [12] [13] [14] [15] 7. Acknowledgements [16] Upon finishing this paper, we found that a recent work from the IDSIA lab [19] proposed a similar model as the max(·) version of the channel-out network. Our work was independently developed. Compared to their work, our model was motivated and analysed from a different perspective. We have also provided new theoretical and experimental results regarding the max(·) channel-out model. [17] [18] References [19] [1] Y. Bengio. Learning deep architectures for AI. Foundations R in Machine Learning, 2(1):1–127, 2009. and trends� [2] L. Bo, X. Ren, and D. Fox. Unsupervised feature learning for rgb-d based object recognition. ISER, June, 2012. [3] Y.-l. Boureau, Y. L. Cun, et al. Sparse feature learning for deep belief networks. In Advances in neural information processing systems, pages 1185–1192, 2007. [4] A. Coates, A. Y. Ng, and H. Lee. An analysis of singlelayer networks in unsupervised feature learning. In Inter- [20] [21] 8 national Conference on Artificial Intelligence and Statistics, pages 215–223, 2011. R. Gens and P. Domingos. Discriminative learning of sumproduct networks. In Advances in Neural Information Processing Systems, pages 3248–3256, 2012. I. J. Goodfellow, D. Warde-Farley, P. Lamblin, V. Dumoulin, M. Mirza, R. Pascanu, J. Bergstra, F. Bastien, and Y. Bengio. Pylearn2: a machine learning research library. arXiv preprint arXiv:1308.4214, 2013. I. J. Goodfellow, D. Warde-Farley, M. Mirza, A. Courville, and Y. Bengio. Maxout networks. arXiv preprint arXiv:1302.4389, 2013. G. E. Hinton, N. Srivastava, A. Krizhevsky, I. Sutskever, and R. R. Salakhutdinov. Improving neural networks by preventing co-adaptation of feature detectors. arXiv preprint arXiv:1207.0580, 2012. Y. Jia, C. Huang, and T. Darrell. Beyond spatial pyramids: Receptive field learning for pooled image features. In Computer Vision and Pattern Recognition (CVPR), 2012 IEEE Conference on, pages 3370–3377. IEEE, 2012. E. R. Kandel, J. H. Schwartz, T. M. Jessell, et al. Principles of neural science, volume 4. McGraw-Hill New York, 2000. A. Krizhevsky, I. Sutskever, and G. Hinton. ImageNet classification with deep convolutional neural networks. In Advances in Neural Information Processing Systems 25, pages 1106–1114, 2012. Y. LeCun, L. Bottou, Y. Bengio, and P. Haffner. Gradientbased learning applied to document recognition. Proceedings of the IEEE, 86(11):2278–2324, 1998. H. Lee, C. Ekanadham, and A. Ng. Sparse deep belief net model for visual area V2. In Advances in neural information processing systems, pages 873–880, 2007. E. Mendelson. Introduction to mathematical logic. CRC press, 1997. Y. Netzer, T. Wang, A. Coates, A. Bissacco, B. Wu, and A. Y. Ng. Reading digits in natural images with unsupervised feature learning. In NIPS Workshop on Deep Learning and Unsupervised Feature Learning, volume 2011, 2011. C. Poultney, S. Chopra, Y. L. Cun, et al. Efficient learning of sparse representations with an energy-based model. In Advances in neural information processing systems, pages 1137–1144, 2006. J. Snoek, H. Larochelle, and R. P. Adams. Practical Bayesian optimization of machine learning algorithms. arXiv preprint arXiv:1206.2944, 2012. N. Srivastava. Improving neural networks with dropout. PhD thesis, University of Toronto, 2013. R. K. Srivastava, J. Masci, S. Kazerounian, F. Gomez, and J. Schmidhuber. Compete to compute. technical report, 2013. L. Wan, M. Zeiler, S. Zhang, Y. L. Cun, and R. Fergus. Regularization of neural networks using dropconnect. In Proceedings of the 30th International Conference on Machine Learning (ICML-13), pages 1058–1066, 2013. M. D. Zeiler and R. Fergus. Stochastic pooling for regularization of deep convolutional neural networks. arXiv preprint arXiv:1301.3557, 2013. Appendix Proof of the universal approximation theorem Theorem: Any piece-wise continuous function defined on a compact domain in Euclidean space can be approximated arbitrarily well by a max(·) two-layer channel-out network with one hidden channel-out group with finite number of candidate nodes. I.e., denote the target function to be approximated as T (x), ∀� > 0, we can find a two-layer channel-out network with one hidden channel-out group that implements a function T̂ (·) such that � � �2 � � �T (x) − T̂ (x)� dx < � Here by a “piece-wise continuous function” we refer to a function that is constituted of finite number of continuous segments. Proof 1) It’s obvious that any (continuous) convex piece-wise linear function defined on a compact domain in Euclidean space can be expressed as a max-of-linear function max(Wx). 2) Select an arbitrary infinite number series that is positive, (strictly) monotonically increasing and bounded {g1 , g2 , g3 , ...}. Suppose 0 < gi < G. 3) We inductively construct a prototype function P (·), which is piece-wise linear, continuous and convex, defined on a hypercube centered at the origin and covering the domain of the target function. We first segment the domain of P (·) (n-dimensional) into lattices as integer multiples � � � of� some �� with corner coordinates δ, k δ, ..., k δ , (k + 1)δ, k δ, ..., k δ , ..., (k1 + δ > 0, i.e., the corner coordinates of a lattice can be written as k 1 2 n 1 2 n �� 1)δ, (k2 + 1)δ, ..., (kn + 1)δ (totally 2n corner points). For convenience, we refer to such lattice as Lattice(k1 , k2 , ..., kn ). In each Lattice(k1 , k2 , ..., kn ), P (·) is defined as a linear function plus a constant shift c > 0: P (x) = f(k1 ,k2 ,...,kn ) (·) + c (2) c > 0, x ∈ Lattice(k1 , k2 , ..., kn ) The linear segments f(k1 ,k2 ,...,kn ) (·) are defined inductively. For a lattice where ∀i, ki > 0, it is defined as following: f(1,1,...,1) (0, 0, ..., 0) = 0 (3) f(k1 ,k2 ,...,kn ) ((k1 − 1)δ, (k2 − 1)δ, ..., (kn − 1)δ) = f(k1 −1,k2 −1,...,kn −1) ((k1 − 1)δ, (k2 − 1)δ, ..., (kn − 1)δ) (4) And the gradient in this lattice is defined as � f(k1 ,k2 ,...,kn ) (x) = (gk1 , gk2 , ..., gkn ) (5) For all other lattices, the regional function is defined symmetrically with respect to its all-positive counterpart: f(k1 ,k2 ,...,kn ) (x) = f(|k1 |,|k2 |,...,|kn |) (x) (6) It’s easy to verify that P (·) constructed in this way is convex and piece-wise continuous. Thus it can be expressed as a max-linear function max(Wx). Furthermore, P (x) ≥ c. Assign the linear weights W to the input weights of the channel-out group. The channel selection function is then constructed as arg max(Wx). 4) Properly scale each f (·) + c to match the target function T (·). Define the approximation T̂ (x) = γ(k1 ,k2 ,...,kn ) P (x), if x ∈ Lattice(k1 , k2 , ..., kn ) 9 (7) where γ(k1 ,k2 ,...,kn ) = T ((k1 − 1)δ, (k2 − 1)δ, ..., (kn − 1)δ) f(k1 ,k2 ,...,kn ) ((k1 − 1)δ, (k2 − 1)δ, ..., (kn − 1)δ) + c (8) � � Since T (·) is bounded, γ(k1 ,k2 ,...,kn ) is also bounded, say ∀(k1 , k2 , ..., kn ), �γ(k1 ,k2 ,...,kn ) � < r. If T is continuous in Lattice(k1 , k2 , ..., kn ), then ∀�0 > 0, we can choose δ such that � � � � � max T (x) − min T (x)�� < �0 (9) � x∈Lattice(k1 ,k2 ,...,kn ) x∈Lattice(k1 ,k2 ,...,kn ) Since P (·) is piece-wise linear, we also know that � � � max P (x) − min � x∈Lattice(k1 ,k2 ,...,kn ) and therefore Hence x∈Lattice(k1 ,k2 ,...,kn ) � � � P (x)�� ≤ (gk21 + gk22 + ... + gk2n ) · nδ 2 < nGδ � � � � � � � � < �γ(k ,k ,...,k ) � nGδ < rnGδ max T̂ (x) − min T̂ (x) 1 2 n �x∈Lattice(k1 ,k2 ,...,kn ) � x∈Lattice(k1 ,k2 ,...,kn ) � � � � �T (x) − T̂ (x)� < �0 + rnGδ (10) (11) (12) Since T has a limit number of continuous segments, the set of discontinuous points has zero measure. Let M be the number of non-continuous lattices, then lim M δ n = 0 (13) δ→0 Since T must be bounded, suppose max T (x) − min T (x) < B, then in these non-continuous lattices x x � � � � �T (x) − T̂ (x)� < B + rnGδ Suppose the total volume of Domain(T ) is V , In summary we’ll have � � �2 � � �T (x) − T̂ (x)� dx < (V − M δ n )(�0 + rnGδ)2 + M δ n (B + rnGδ)2 and with (13) we have � � �2 � � lim �T (x) − T̂ (x)� dx = 0 δ→0 (14) (15) (16) i.e. the function constructed as T̂ (·) can approximate T (·) to arbitrary precision (in l2 sense). Let K be the total number of lattices, construct the output weights of the channel-out network as Γ = (γ1 , γ2 , ..., γK ) (where each γi is some γ(k1 ,k2 ,...,kn ) previously defined). We can easily see that the channel-out network implements the function K � γi · I{i=arg max(Wx)} · (Wx)i (17) T̂ (x) = i=1 where (Wx)i denotes the ith component of vector Wx. Q.E.D. 10
9cs.NE
1 Skip-Sliding Window Codes Ting-Yi Wu, Anshoo Tandon, Lav R. Varshney, Senior Member, IEEE, and Mehul arXiv:1711.09494v2 [cs.IT] 11 Jan 2018 Motani, Fellow, IEEE Abstract Constrained coding is used widely in digital communication and storage systems. In this paper, we study a generalized sliding window constraint called the skip-sliding window. A skip-sliding window (SSW) code is defined in terms of the length L of a sliding window, skip length J, and cost constraint E in each sliding window. Each valid codeword of length L + kJ is determined by k + 1 windows of length L where window i starts at (iJ + 1)th symbol for all non-negative integers i such that i ≤ k; and the cost constraint E in each window must be satisfied. In this work, two methods are given to enumerate the size of SSW codes and further refinements are made to reduce the enumeration complexity. Using the proposed enumeration methods, the noiseless capacity of binary SSW codes is determined and observations such as greater capacity than other classes of codes are made. Moreover, some noisy capacity bounds are given. SSW coding constraints arise in various applications including simultaneous energy and information transfer. I. I NTRODUCTION Constrained coding losslessly maps a set of unconstrained sequences into a set of sequences that satisfy certain constraints, and has been extensively used in several applications. To alleviate timing errors due to the rapid change of stored bits in magnetic and optical storage, binary runlength-limited codes [1], [2] are employed to insert a run of zeros between consecutive ones. In simultaneous information and energy transmission [3], a minimal number of ones in subsequences of transmitted codewords is required so as to carry enough energy while transmitting information [4]–[8]. Asynchronous communication necessitates codes with heavy/light Hamming weight [9], [10]. Two basic constrained coding strategies have been developed for simultaneous information and energy communication: sliding window constraint (SWC) codes [4]–[6] and subblock-energy constraint (SEC) T.-Y. Wu and L. R. Varshney are with the Coordinated Science Laboratory, University of Illinois at Urbana-Champaign, Urbana, IL 61801, USA (e-mail: {tywu, varshney}@illinois.edu). A. Tandon and M. Motani are with the Department of Electrical and Computer Engineering, National University of Singapore, Singapore 117583 (e-mail: {[email protected]; [email protected]}). 2 codes [7], [8]. As Fig. 1 shows, SWC codes restrict the energy of every consecutive L symbols to be no less than E to guarantee enough energy is conveyed after transmitting any symbol. The slidingwindow constraint enables SWC codes to convey energy to meet real-time delivery requirements, but also reduces the number of valid SWC codewords and therefore the information capacity. When there are energy buffers (batteries), energy transmission need not be so constrained at the level of individual transmitted symbols, and so SEC codes only restrict the energy of non-overlapping subblocks to be no less than E ; this leads to more allowable codewords and capacity. This work introduces a new intermediate type of constrained code that generalizes both SWC and SEC codes. Instead of assuring the energy constraint on consecutive L symbols for all sliding windows, the proposed constrained code that we call skip-sliding window (SSW) codes loosen the SWC constraint by lifting the energy constraint for those sliding windows that do not start at (iJ + 1)th symbols, where J is a fixed integer and i is any non-negative integer. It is immediate that an SSW code reduces to an SWC code when J = 1, and to an SEC code when J = L. In this sense, SWC and SEC codes are two ends of a spectrum of SSW codes as Fig. 1 shows. Note that although SSW codes are inspired by constrained codes for simultaneous information and energy transmission, they may also be useful in several other areas where sliding window constraints arise. Genome sequences may be assembled using de Bruijn graphs [11], [12], in which constrained overlapped genome subsequences form a graph that can be related to a sliding window constraint. Several task scheduling problems state that machines process jobs in a sliding-window manner when loading is limited [13]; sequencing of tasks to satisfy the loading constraint forms an SSW code. Other topics, such as Rauzy graphs [14], [15, Sec. 3.4.2] in formal languages and regular constraints [16] in constraint programming [17] may also be treated from an SSW code perspective. The main contributions of this paper are as follows. 1) We define SSW codes and characterize basic properties to build the mathematical foundation for SSW-related applications. 2) We introduce two methods to enumerate valid codewords of binary SSW codes where the cost constraint E is defined as the least Hamming weight W : one is based on the adjacency matrix of a  P   L L 2 modified de Bruijn graph [12] which enumerates the SSW code in complexity O , i=W i whereas the other uses the Goulden-Jackson cluster method [18] which enumerates the SSW code  P  W −1 L2 with L = ℓJ for some positive integer ℓ in complexity O . A modified Gouldeni=0 i Jackson cluster method is further proposed which is proved to be equivalent to the first method when L = ℓJ for some positive integer ℓ. 3) When L = ℓJ for some positive integer ℓ, refinements of both enumeration methods are given to 3 Fig. 1. Sliding window constraint codes, skip-sliding window codes, and subblock-energy constraint codes. As the intensity of the coding constraint increase (J decrease), it is expected that the capacity (noiseless or noisy) of the code will decrease. However, the skip-sliding window codes may violate this intuition. lower the complexity. The refinement of the first enumeration method reduces its complexity to  be O min{J + 1, W + 1}ℓ−1 , and the refinement of the second enumeration method reduces its  complexity to be O min{J, W − 1}ℓ−1 . 4) Properties of the noiseless capacity of SSW are proven, and some interesting and useful observations from numerical simulations are given. In particular, SSW codes can surprisingly achieve higher noiseless capacity than SEC codes do. 5) Several noisy capacity bounds over the binary symmetric channel (BSC) and the binary erasure channel (BEC) are given for comprehensiveness. The rest of this paper is organized as follows. Section II introduces SSW codes and their noiseless capacity. Enumeration methods are given in Section III and refined enumeration methods are further derived in Section IV. Section V gives properties and numerical results on SSW codes in the noiseless case. Some noisy capacity bounds and their numerical evaluations are given in Section VI. Section VII summarizes and concludes. 4 II. S KIP -S LIDING W INDOW C ODES Let us consider q -ary sequences where each symbol in the sequence is drawn from Q , {0, 1, . . . , q−1} and define a cost function E(·) which maps each symbol to a real value as E : Q → R. A q -ary SSW sequence with a window length L, a skip length J , and a minimal cost E , denoted as an (L, J, E)q -SSW sequence, guarantees the sum of the cost of the L consecutive symbols which start at the (iJ + 1)th symbol to be no less than E for all non-negative integers i. Definition 1. Given positive integers L and J such that L ≥ J , a cost function E : Q → R, and the minimal cost E , a q -ary sequence of length n = L + kJ is said to be an (L, J, E)q -SSW sequence if L X E (c(i + mJ)) ≥ E for all 0 ≤ m ≤ k, (1) i=1 where c(i) denotes the ith symbol of the sequence c. Definition 2. The collection of all (L, J, E)q -SSW sequences of length n form the (L, J, E)q -SSW code of length n. Since binary sequences are of particular interest, we largely focus on (L, J, E)2 -SSW sequences in the sequel. For simplicity, the cost function is taken as the Hamming weight of the binary symbol, E(c(i)) = c(i), and the cost constraint E is replaced by W to specifically denote the Hamming weight. Definition 3. Given positive integers L, J , and W , such that L ≥ W and L ≥ J , a binary sequence c of length n = L + kJ is said to be an (L, J, W )-SSW sequence if L X c(i + mJ) ≥ W for all 0 ≤ m ≤ k, (2) i=1 where c(i) denotes the ith bit value of the binary sequence c. (L,J,W ) Let Mssw (L + kJ) denote the number of the (L, J, W )-SSW sequences of length L + kJ for some (L,J,W ) non-negative integer k. Our interest is in finding Mssw (L + kJ), but especially the noiseless capacity of binary skip-sliding codes, (L,J,W ) log Mssw (L + kJ) . k→∞ L + kJ (L,J,W ) Cssw , lim (L,J,W ) The next two sections will introduce several ways to enumerate Mssw (3) (L + kJ). Before closing this section, we present the following theorem which states that any (L, J, W )-SSW sequence with L = ℓJ for some ℓ > 0 is equivalent to a q -ary (ℓ, 1, E)q -SSW sequence such that q = 2J . 5 Fig. 2. Extending an (L, J, W )-SSW sequence c. Theorem 1. For any binary (L, J, W )-SSW code where L = ℓJ for some positive integer ℓ, there is an equivalent 2J -ary (ℓ, 1, E)2J -SSW code. Proof: Let w(c) be the Hamming weight of the binary string c and (i)J be the binary representation of length J for the non-negative integer i.1 Then we can construct a 2J -ary (ℓ, 1, E)2J -SSW code such that E = W , Q = {0, 1, . . . , 2J − 1} and E(i) = w ((i)J ) for all i ∈ Q. Hence, any 2J -ary (ℓ, 1, E)2J -SSW sequence of length n can be transformed to be a binary (L, J, W )-SSW sequence of length nJ by representing each symbol in binary, i.e., c ∈ (ℓ, 1, E)2J -code of length n if and only if (c(1))J (c(2))J · · · (c(n))J ∈ (L, J, W )-code of length nJ . III. E NUMERATION M ETHODS (L,J,W ) To enumerate Mssw (n), we consider its generating function g(x), such that g(x) = ∞ X (L,J,W ) Mssw (n)xn . (4) n=0 (L,J,W ) Note that Mssw (n) = 0 if n 6= L + kJ for any non-negative integer k. A. Finite State Machine To extend an (L, J, W )-SSW sequence c, as Fig. 2 shows, the incoming J bits and the last L − J bits of c must contain at least W ones. Hence, the incoming J bits and the last L − J bits of c can determine if the extended sequence is a valid (L, J, W )-SSW sequence, which indicates that the finite state machine (FSM) with L-bit states can represent all possible (L, J, W )-SSW sequences. Let us consider a directed graph G(V, E) with vertex set V and directed edge set E , which contains all L-bit vertices, i.e., V = {[b1 · · · bL ] : bi ∈ {0, 1} for all 1 ≤ i ≤ L}, and the vertex [b1 · · · bL ] can transit to the vertex [b′1 · · · b′L ] if bi+1 = b′i for all 1 ≤ i ≤ L − 1, i.e., ([a b1 · · · bL−1 ], [b1 · · · bL−1 a′ ]) ∈ E 1 For example, (5)4 = 0101, hence the w ((5)4 ) = w(0101) = 2. 6 Fig. 3. An example of de Bruijn graph of order 3, which is also the FSM of the (3, 1, 0)-SSW code. Fig. 4. The FSM of the (3, 2, 0)-SSW code, in which each path denotes a valid walk of length 2 in Fig. 3. for all a, a′ , and bi ∈ {0, 1}. Such a graph G(V, E) is called the de Bruijn graph of order L [12]. An example of a de Bruijn graph of order 3 is depicted as Fig. 3. Since the states in the de Bruijn graph of order L represent the latest L bits of the incoming path, the de Bruijn graph of order L can be treated as an FSM of an (L, 1, 0)-SSW code. Hence Fig. 3 is also the FSM of an (3, 1, 0)-SSW code. To obtain the FSM of the (L, J, 0)-SSW code with a skip length J > 1, walks of length J in the de Bruijn graph need to be extracted. An example of the FSM of the (3, 2, 0)-SSW code is depicted in P Fig. 4. Furthermore, letting w([b1 · · · bL ]) = L i=1 bi be the Hamming weight of the vertex [b1 · · · bL ] in G(V, E), the FSM of an (L, J, 0)-SSW code can be transformed into the FSM of an (L, J, W )-SSW code by discarding vertices whose Hamming weights are less than W . An example of the FSM of the (3, 2, 2)-SSW code is given in Fig. 5. Based on the transformation of the FSM of the (L, J, W )-SSW code mentioned above, the adjacency matrix of the FSM corresponding to an (L, J, W )-SSW code can be derived as the following theorem. We use an operator that eliminates rows and columns of a matrix: [B]≥W is defined as the submatrix of B which deletes the rows and the columns of B corresponding to those vertices whose Hamming weights are less than W . 7 Fig. 5. The FSM of the (3, 2, 2)-SSW code, which is a modified FSM of (3, 2, 0)-SSW code in Fig. 4 by simply removing those vertices whose Hamming weight is less than 2. Lemma 1. Let G(V, E) be the de Bruijn graph of order L and the corresponding adjacency matrix be A. The FSM of the (L, J, W )-SSW code can be constructed as the adjacency matrix [AJ ]≥W . Proof: By [19, Theorem 1.1], the element at the ith row and j th column of the adjacency matrix AJ is the number of valid walks from vertex i to vertex j . Therefore, the adjacency matrix AJ corresponds to the FSM of the (L, J, 0)-SSW code. As Fig. 5 depicts, the FSM of the (L, J, W )-SSW code is the FSM of the (L, J, 0)-SSW code without those vertices whose Hamming weight is less than W . Hence, the adjacency matrix of the (L, J, W )-SSW code can be obtained simply by removing the rows and columns of AJ whose corresponding Hamming weight is less than W , i.e. [AJ ]≥W . It should be noted that elements in matrix [AJ ]≥W are either 0 or 1 when L ≥ J , and the size of the P L square matrix [AJ ]≥W is b × b, where b = L i=W i . By Lemma 1, the following theorem calculates the generating function (4). Theorem 2. The generating function of the (L, J, W )-SSW code is  −1 T J J 1xL , g(x) = 1 + 1 I − [A ]≥W · x where A is the adjacency matrix corresponding to the de Bruijn graph of order L. Proof: Letting B = [AJ ]≥W and 1 be the b-length column vector of ones, the number of (L, J, W )SSW sequences of length L + kJ for some non-negative integer k is (L,J,W ) Mssw (L + kJ) = 1T Bk 1. 8 Therefore, the generating function g(x) can be derived as g(x) = 1 + ∞ X 1T Bk 1xL+kJ (5) k=0 = 1 + 1T where I is the identity matrix of size b × b.  I − Bx J −1 1xL , (6) : As per [20, Lemma 3.5], the logarithm of the largest absolute eigenvalue of [AJ ]≥W equals JCssw  k log2 1T [AJ ]≥W 1 (L,J,W ) Cssw = lim (7) k→∞ L + kJ  log2 λ [AJ ]≥W , (8) = J  (L,J,W ) where λ [AJ ]≥W is the largest absolute value of all eigenvalues of [AJ ]≥W . Finding Cssw is (L,J,W ) equivalent to finding the eigenvalue of the square matrix [AJ ]≥W of size b × b. B. Goulden-Jackson Cluster Method with Bad Words When the window length of the (L, J, W )-SSW sequences is a multiple of J , i.e., L = ℓJ for some positive integer ℓ, we can apply Goulden-Jackson cluster method [18] to find the generating function g(x). The Goulden-Jackson cluster method is a technique to enumerate the valid sequences without any “bad” words within it. The Goulden-Jackson cluster method states that, given a set of letters V and a set of bad words B such that B ∈ V ∗ , the generating function f (x) for enumerating sequences containing no bad words within them can be expressed as f (x) = 1 , 1 − |V|x − clusterB (x) (9) where the clusterB (x) is the generating function of the sequences of overlapped bad words. Since the sequences of overlapped bad words can be categorized by their last bad word, clusterB (x) can be computed by summing the generating function of all overlapped bad words ending with a different bad word, i.e., clusterB (x) = X clusterB (x|b) (10) b∈B where clusterB (x|b) is the generating function of the overlapped bad words ending with bad word b. Based on Goulden-Jackson cluster method, the clusterB (x|b) can be uniquely determined by solving the following |B| linear equations: clusterB (x|b) = −xkbk − X ′ X ′ b ∈B y∈O(b ,b) xkbk−kyk clusterB (x|b′ ), for all b ∈ B, (11) 9 where k · k denotes number of bits and  O(b′ , b) , y : there exist y, u, u′ ∈ {V ∗ \ ∅} such that b′ = u′ y and b = yu . (12) Thus (L, J, W )-SSW sequences such that L = ℓJ for some positive integer ℓ can be enumerated by the Goulden-Jackson cluster method and its generating function can be calculated by the following theorem. Theorem 3. The generating function of the (ℓJ, J, W )-SSW code for some positive integer ℓ is g(x) = 1− |V|xJ 1 , − clusterB (xJ ) where V = {0, 1}J , B = {b : b ∈ {0, 1}ℓJ and w([b]) < W }, clusterB (x) = clusterB (x|b) = −xℓ − X X (13) P b∈B clusterB (x|b), xℓ−(kyk/J) clusterB (x|b′ ), for all b ∈ B, (14) b′ ∈B y∈O(b′ ,b) and O(b′ , b) is as in (12). Proof: Since the (ℓJ, J, W )-SSW code is simply the language with alphabet V such that no bad word in B is included, the Goulden-Jackson cluster method can be used directly. Also, since f (x) in (9) enumerates the sequences from the alphabet V instead of the binary alphabet, the generating function of (ℓJ, J, W )-SSW sequences can be computed as g(x) = f (xJ ) which yields (13). (ℓJ,J,W ) Hence, finding Mssw (n) is equivalent to solving a linear system with |B| = in (14). PW −1 i=0 ℓJ i  unknowns C. Goulden-Jackson Cluster Method with Good Words Conceptually, the FSM approach in Section III-A enumerates the (L, J, W )-SSW sequences by listing all legitimate sequences whereas the Goulden-Jackson cluster method enumerates the (ℓJ, J, W )-SSW sequences by excluding all invalid ones. The efficiency of the Goulden-Jackson cluster method for (ℓJ, J, W )-SSW sequences depends on the number of bad words. The linear system (14) is not easy PW −1 ℓJ  to solve when |B| = is large. Borrowing from the FSM approach, the Goulden-Jackson i=0 i cluster method with good words can be considered as an alternative, which computes the generating function by enumerating all valid sequences. Ultimately, the Goulden-Jackson cluster method with good words converges to the FSM approach as the following theorem shows, providing a further interpretation of the Goulden-Jackson cluster method. Theorem 4. To enumerate the (ℓJ, J, W )-SSW sequences for some positive integer ℓ, the FSM approach is equivalent to the Goulden-Jackson cluster method for enumerating overlapped good words. 10 Proof: Let V = {0, 1}J and G be the set of good words, G = {0, 1}ℓJ \ B . Any (ℓJ, J, W )-SSW sequence must be composed of consecutive good words and each good word must overlap with its neighbors with (ℓ − 1)J bits. Hence, the generating function by Goulden-Jackson cluster method can be derived as f (x) = 1 + clusterG (x), where clusterG (x) = P b∈G (15) clusterG (x|b). Similar to (14), clusterG (x|b) for all b ∈ G can be obtained by solving the following linear system clusterG (x|b) = xℓ + X ′ X x · clusterG (x|b′ ), for all b ∈ G, (16) b ∈G y∈OG (b′ ,b) where n o OG (b′ , b) , y : there exist y ∈ V ℓ−1 , u and u′ ∈ V such that b′ = u′ y and b = yu . Since the linear system in (16) can be rewritten in matrix form, h i h i T ℓ ′ = 1 B x + x clusterG (x|b) clusterG (x|b) b∈G b∈G , which can be solved as i h clusterG (x|b) =  g(x) = f (xJ ) = 1 + 1T  Combining (15) and (17), which coincides with (6) since b∈G I − B′ x −1 I − B′ xJ 1xℓ . −1 (17) 1xℓJ , B = B′ . Therefore, FSM enumeration can be interpreted as the Goulden- Jackson cluster method for good words. IV. R EFINED E NUMERATION M ETHODS The methods proposed in the previous section find the generating function with computational complexity governed by the size of good word or bad word sets, which can be exceedingly large in most practical cases. For example, to enumerate (40, 20, 20)-SSW sequences, the FSM approach must find  P 40 11 and the Goulden-Jackson method needs eigenvalues of the square matrix of size 40 i=20 i ≈ 6.2 × 10 P 40 11 unknowns. Here, we refine the methods of Section to solve a linear system with 19 i=0 i ≈ 4.8 × 10 III to reduce computational complexity. Just a heads-up, in the case of enumerating (40, 20, 20)-SSW sequences, the refined FSM approach and the Goulden-Jackson method need to solve the linear systems with at most 21 and 20 unknowns, respectively. 11 A. Refined Finite State Machine Considering the FSM G(V, E) of the (ℓJ, J, W )-SSW code for some positive integer ℓ, each state [b] = [b1 · · · bℓJ ] ∈ V can be segmented into ℓ subblocks, i.e., [bk ] = [b(k−1)J+1 b(k−1)J+2 · · · bkJ ] for 1 ≤ k ≤ ℓ. Let w([bk ]) be the Hamming weight of the subblock [bk ], which is w([bk ]) = w([b(k−1)J+1 · · · bkJ ]), for all 1 ≤ k ≤ ℓ. The following theorem shows that, for any two states [b] and [b′ ] in G(V, E) whose last ℓ − 1 subblocks have the same Hamming weight, respectively, i.e. w([bk ]) = w([b′k ]) for all 2 ≤ k ≤ ℓ, their outgoing edges are the same. Lemma 2. Let G(V, E) be the FSM of the (ℓJ, J, W )-SSW code for some positive integer ℓ and let any two states [b] and [b′ ] be in V . If w([bk ]) = w([b′k ]) for all 2 ≤ k ≤ ℓ, then both edges ([b], [b2 · · · bℓ y])  and [b′ ], [b′2 · · · b′ℓ y] are in E for all y ∈ {0, 1}J such that w(y) ≥ W − w([b]) + w([b1 ]). Proof: Since both states [b2 · · · bℓ y] and [b′2 · · · b′ℓ y] have the same Hamming weight: w([b2 · · · bℓ y]) = w([b′2 · · · b′ℓ y]) = ℓ X (18) w([bk ]) + w([y]) (19) k=2 = w([b]) − w([b1 ]) + w([y]) ≥ W, (20)  and both edges ([b], [b2 · · · bℓ y]) and [b′ ], [b′2 · · · b′ℓ y] are valid edges in E . By Lemma 2, the size of G(V, E) can be reduced by grouping those states whose last ℓ − 1 subblocks have the same Hamming weights, respectively. Let w = (w1 , w2 , . . . , wℓ−1 ) be a vector of ℓ−1 Hamming weights and define R(w) as n o R(w) , b = [b1 · · · bℓJ ] : w([b]) ≥ W and w([bk ]) = wk−1 for all 2 ≤ k ≤ ℓ , which is the set of all valid states in G(V, E) such that the Hamming weights of the last ℓ − 1 subblocks equal w. The size of R(w), denoted as |R(w)|, is " ℓ−1  #  Y J |R(w)| = × wk k=1 J X i=W − Pℓ−1 j=1 wj    J  . i We further define the set   ℓ−1 X wi ≥ W − J , W , w : 0 ≤ wk ≤ min{J, W } for all 1 ≤ k ≤ ℓ − 1, and i=1 which is the set of all valid Hamming weight vectors for (ℓJ, J, W )-SSW sequences. The following theorem provides an efficient way to calculate the generating function (4). 12 Fig. 6. Converting the FSM G of (4, 2, 3)-SSW code to its reduced FSM GR . The weights of edges in GR are given as m([w, w′ ]) for all w, w′ ∈ W. Theorem 5. The generating function of the (ℓJ, J, W )-SSW code for some positive integer ℓ is g(x) = 1 + ∞ X 1T ARk−ℓv × xkJ , (21) k=ℓ where AR = [m(w, w ′ )](w,w′ )∈W 2 and m(w, w′ ) = J wℓ′  . ′ for all 2 ≤ k ≤ ℓ − 1 Proof: Any state in R(w) can transit to another state in R(w′ ) if wk = wk−1 and the edge can be represented as J bits with wℓ′ ones. Therefore, we can construct the reduced FSM GR (VR , ER ) as VR = {w : w ∈ W} and ′ for all 2 ≤ k ≤ ℓ − 1}. ER = {(w, w′ ) : w, w′ ∈ W and wk = wk−1 The weight of edge (w, w′ ) ∈ ER is m(w, w′ ) = transitions from vertex w to vertex w′ . Let J wℓ′ , which denotes the total number of possible v be the column vector of |R(w)| for all w ∈ W , which is v = [|R(w)|]w∈W , and let the adjacency matrix AR of GR (VR , ER ) be AR = [m(w, w′ )](w,w )∈W . ′ 2 13 Then k−ℓ (ℓJ,J,W ) Mssw (kJ) = 1T AR v, (22) and the generating function can be derived as (21). An example of converting the FSM of (4, 2, 3)-SSW code to its reduced FSM is given in Fig. 6, where the reduced FSM is a weighted digraph. As shown, grouping all states in G(V, E) yields a reduced FSM GR (VR , ER ) with a size of |W|, which is at most min{J + 1, W + 1}ℓ−1 . Hence, the GR (VR , ER ) for the (40, 20, 20)-SSW code has at most 21 states, a significant reduction compared to the 6.2 × 1011 states for G(V, E). Further, using (22), the noiseless capacity for skip-sliding window codes can efficiently be computed as (lJ,J,W ) Cssw where λ  log2 λ AR = , J (23) AR is the largest positive eigenvalue of AR.  B. Refined Goulden-Jackson Cluster Method with Bad Words Similar to the reduced FSM, we can apply the Goulden-Jackson cluster method to enumerate the (ℓJ, J, W )-SSW sequences by considering only the Hamming weight of the subblocks of each window. The following theorem refines Theorem 3. Theorem 6. The generating function of the (ℓJ, J, W )-SSW code for some positive integer ℓ is g(x) = 1− xJ 1 Pmin{J,W −1} J i i=0  − clusterB (xJ ) , (24)   Pℓ−1 where V = 0, 1, . . . , min{J, W − 1} , B = w : w = w1 · · · wℓ ∈ V ℓ−1 and i=1 wi < W , P clusterB (x) = w∈B clusterB (x|w), clusterB (x|w) = −xℓ " ℓ−1  # Y J k=1 − ( ℓ−1 X o=1 wk xℓ−o  W− Pℓ−1 × j=1 X i=0 " ℓ−1  # Y J k=o wk wj −1  ×   J  i " W −Pℓ−1 j=1 wj −1 X i=0 X #) clusterB (x|w ′ ) w′ ∈O(i,o,w) , (25) and ′ ′ = wk for all 1 ≤ k ≤ o − 1}. = i and wℓ−o+k O(i, o, w) , {w′ : w′ ∈ B, wℓ−o (26) Proof: Similar to Theorem 5, a bit sequence of length ℓJ can be divided into ℓ subblocks and the Hamming weight of each subblock is at most min{J, W − 1} to be a valid (ℓJ, J, W )-SSW sequence. Hence, the (ℓJ, J, W )-SSW code can be translated to be a language with alphabet V such that no sum 14 of ℓ consecutive weights is less than W . Since the number of binary sequences of length J whose total Pmin{J,W −1} J  Hamming weight is less than W is i=0 i , equation (9) can be replaced by (24). As stated in the Goulden-Jackson cluster method, the clusterB (x) is the generating function of the overlapped bad words and clusterB (x|w) denotes the generating function of those overlapped bad words that end with a bad word corresponding to w ∈ B . It should be noted that, for each ℓ consecutive weights, only the last ℓ−1 weights w1 · · · wℓ−1 is used to denote the element in B since the first weight can be any n o Pℓ−1 integer in 0, 1, . . . , W − i=1 wi − 1 . The number of binary sequences that are bad words of length i h PW −Pℓ−1 w −1 i hQ j ℓ−1 J  J j=1 × ℓJ corresponding to w = w1 · · · wℓ−1 ∈ B can be computed as i=0 k=1 wk i , which is the coefficient of −xℓ in (25). We can further enumerate those binary sequences which are overlapped by the bad words in the same way to derive the clusterB (x|w) as in (25). Hence, the refined Goulden-Jackson cluster method can enumerate the (ℓJ, J, W )-SSW sequences by solving (25) with |B| unknowns, where |B| ≤ min{J + 1, W }ℓ−1 . For the example of (40, 20, 20)-SSW sequences, the refined Goulden-Jackson cluster method can find the generating function by solving the linear system with at most 20 unknowns, which is much smaller than the original 4.8 × 1011 unknowns. Since Theorem 4 shows the Goulden-Jackson cluster method for good words is an alternative interpretation of the FSM approach, and since the derivation of the refinement is similar to that of the bad words setting, it is omitted here. V. P ROPERTIES OF (L, J, W )-SSW CODES In this section, we explore some properties of SSW codes. Let (L,J,W ) (L,J,W ) Cssw (L + kJ) , (L,J,W ) and let Sssw log2 Mssw (L + kJ) , L + kJ (27) (L + kJ) be the set of all (L, J, W )-SSW sequences of length L + kJ . Two trivial inequalities of the noiseless capacity are given as the following lemmas, which show that the noiseless capacity increases as W decreases and the noiseless capacity decreases if the skip length J is multiplied by a constant. Lemma 3. Given positive integers L, J , W and W ′ such that L > J and L > W ≥ W ′ > 0, ′ (L,J,W ) (L,J,W ) Cssw ≤ Cssw . (28) (L,J,W ) Proof: Since any sequence in (L, J, W )-SSW is also in (L, J, W ′ )-SSW, Cssw (L,J,W ′ ) ≤ Cssw . Lemma 4. Given positive integers L, J , W and k such that L > kJ > 0, (L,kJ,W ) (L,J,W ) Cssw ≥ Cssw . (29) 15 (L,kJ,W ) Proof: Since any sequence in (L, J, W )-SSW is also in (L, kJ, W )-SSW, Cssw (L,J,W ) ≥ Cssw . We further examine finite blocklength properties in the noiseless case. The following lemma shows the size of skip-sliding window codes can be upper-bounded by dividing into subblocks. Lemma 5. Assume L = ℓJ for some integer ℓ > 0. Let k, h ∈ Z+ such that h ≥ ℓ and k ≥ ℓ, then (L,J,W ) (L,J,W ) (L,J,W ) Mssw ((h + k)J) ≤ Mssw (hJ) × Mssw (kJ), (30) where equality holds if and only if L = J . Proof: Let o n (L,J,W ) (L,J,W ) (hJ), b′ ∈ Sssw (kJ) , S ′ = bb′ : b ∈ Sssw (L,J,W ) which is the set of all sequences which are the concatenations of any sequence in Sssw sequence in (L,J,W ) Sssw (kJ). Since (L,J,W ) Sssw ((h (hJ) and any + k)J) ⊆ S ′ , (L,J,W ) Mssw ((h + k)J) ≤ |S ′ | (31) (L,J,W ) (L,J,W ) = Mssw (hJ) × Mssw (kJ). (32) Since an (L, J, W )-SSW code reduces to an SEC code when L = J , the equality of (30) always holds when L = J [7], [8]. Moreover, letting b = 1hJ−L+W 0L−W and b′ = 0L−W 1(kJ−L+W , it is clear that (L,J,W ) b ∈ Sssw (L,J,W ) (hJ), b′ ∈ Sssw (L,J,W ) (kJ), but bb′ ∈ / Sssw ((h + k)J) when L > J . Hence the equality of (30) holds if and only if L = J . (L,J,W ) Lemma 5 provides a lower bound for Mssw (L,J,W ) (hJ) × Mssw (kJ). We further find an upper bound. Lemma 6. Assume L = ℓJ for some integer ℓ > 0. Let h, k ∈ Z+ such that h ≥ ℓ and k ≥ ℓ, then (L,J,W ) (L,J,W ) (L,J,W ) Mssw ((h + k)J + (L − J)) ≥ Mssw (hJ) × Mssw (kJ), (33) where equality holds if and only if L = W . Proof: Let (L,J,W ) Since S ′ ⊆ Sssw n o (L,J,W ) (L,J,W ) S ′ = b1L−J b′ : b ∈ Sssw (hJ) and b′ ∈ Sssw (kJ) , ((h + k)J + (L − J)), we have (L,J,W ) Mssw ((h + k)J + (L − J)) ≥ |S ′ | (L,J,W ) (L,J,W ) = Mssw (hJ) × Mssw (kJ). (34) 16 When L = W , it is trivial that the equality of (33) holds since both sides equal 1. However, when L > W , (L,J,W ) a binary sequence b = 1hJ 01L−J−1 1kJ is in Sssw ((h + k)J + (L − J)) but not in S ′ . Hence the equality of (33) holds if and only if L = W . Let us consider the concatenation of subblocks with equal length. Lemmas 5 and 6 can be extended to the following lemma. Lemma 7. Assume L = ℓJ for some integer ℓ > 0. Let h ∈ Z+ such that h ≥ ℓ, then h ik  (L,J,W ) (L,J,W ) (L,J,W ) Mssw (khJ) ≤ Mssw (hJ) ≤ Mssw khJ + (k − 1)(L − J) , (35) for all integers k > 0. The left equality holds if and only if L = J and the right equality holds if and only if L = W . Proof: The proof is a direct extension of Lemmas 5 and 6. To understand the properties of the noiseless capacity (3), we further investigate properties of the rate as defined in (27) when L is a multiple of J . Based on Lemma 7, the following lemma provides a lower bound and an upper bound on the rate. Lemma 8. Assume L = ℓJ for some integer ℓ > 0. Let h ∈ Z+ such that h ≥ ℓ, then   kh + (k − 1)(ℓ − 1) (L,J,W ) (L,J,W ) (L,J,W ) Cssw (khJ) ≤ Cssw (hJ) ≤ kh + (k − 1)(ℓ − 1) J , Cssw kh (36) for all integers k > 0. The left equality holds if and only if L = J and the right equality holds if and only if L = W . Proof: We first verify the left side of (36). (L,J,W ) (L,J,W ) Cssw (khJ) log2 Mssw (khJ) = khJ (L,J,W ) k log2 Mssw ≤ khJ (L,J,W ) log2 Mssw = hJ (L,J,W ) = Cssw (hJ), (hJ) (hJ) (37) (38) (39) (40) where equality of (38) holds if and only if L = J . Hence the left side of of (36) is proven. The right 17 side of (36) is further verified as the following. 1 (L,J,W ) log2 Mssw (khJ) khJ  1 (L,J,W ) ≤ log2 Mssw khJ + (k − 1)(L − J) khJ    1 (L,J,W ) kh + (k − 1)(ℓ − 1) J log2 Mssw = khJ   kh + (k − 1)(ℓ − 1) (L,J,W ) kh + (k − 1)(ℓ − 1) J , Cssw = kh (L,J,W ) Cssw (khJ) = (41) (42) (43) (44) where equality of (42) holds if and only if L = W . Hence the right side of (36) is proven. From Lemma 8, the left side of (36) indicates that the rate of SSW codes decreases when its length is multiplied by a constant. Moreover, the right side of (36) implies that, when h ≫ k, the rate loss in multiplying the length by k can be very small. The following lemma further shows that the rate of the (L, J, W )-SSW code is lower-bounded by its capacity. Lemma 9. Assume L = ℓJ for some integer ℓ > 0, then (L,J,W ) (L,J,W ) Cssw (L + kJ) ≥ Cssw , (45) for all integers k ≥ 0. The equality of (45) holds if and only if L = J . Proof: By Lemma 8, (L,J,W ) (L,J,W ) Cssw (L + kJ) ≥ Cssw (2(L + kJ)) (46) (L,J,W ) n ≥ lim Cssw (2 (L + kJ)) (47) (L,J,W ) = Cssw , (48) n→∞ where the equalities of (46) and (47) hold if and only if L = J . (L,J,W ) The rate of convergence of Cssw Lemma 10. Let (L,J,W ) (L + kJ) to Cssw can be given as the following lemma. B be the matrix of size b × b associated to the (L, J, W )-SSW code. The rate of the (L, J, W )-SSW code is upper-bounded as (L,J,W ) Cssw (L + kJ) < (L,J,W ) Cssw σb (k) νb (k) + log2 (2b − 1) + log2 kJ kJ for all k > 0, where  (1B1)b 1Bb 1  (49) σb (k) =    1 (log2 k + 1) (log2 k + 2) for b = 2, 2 (50) νb (k) =   log2 k + 1 (51) log2 (b−1)   (b−1)23 k log 2b for b > 2, (b−2) for b = 2, log2 (b−1)   (b−1)2 k log 2b for b > 2. (b−2) 18 Proof: Let B be the transition matrix corresponding to the (L, J, W )-SSW code. (L,J,W ) Cssw k log2 1T B 1 = lim k→∞ L + kJ k log2 1T B 1 σb (k) ≥ − log2 (2b − 1) + kJ kJ k log2 1T B 1 σb (k) − log2 (2b − 1) + > L + kJ kJ (52) νb (k) log2 kJ  νb (k) log2 kJ  (1B1)b 1Bb 1 (1B1)b  (53)  (54) 1Bb 1   σb (k) (1B1)b νb (k) (L,J,W ) b = Cssw (L + kJ) − log2 (2 − 1) + log2 kJ kJ 1Bb 1 (55) where inequality (53) is from [21, Thm. 1]. Based on Lemmas 8, 9, and 10, the rate of SSW codes seems to be non-increasing along the length when L = ℓJ for some ℓ ∈ Z+ and it converges to its capacity asymptotically; however, we have been unable to prove this. We leave the non-increasing properties as the following conjecture. Conjecture 1. Assume L = ℓJ for some integer ℓ > 0. Let h ∈ Z+ such that h ≥ ℓ, then we conjecture that the rate of the SSW code decreases if the length of the code is multiplied by a positive integer as (L,J,W ) (L,J,W ) Cssw ((k + 1)hL) ≤ Cssw (khL), (56) for all integers k > 0. It should be noted that the conjecture is only stated for the case where L is a multiple of J . In fact, the next section presents counterexamples where (56) does not hold when L 6= ℓJ . Remark: The following stronger statement is not true, even when L = ℓJ . For all integers k ≥ 0 (L,J,W ) (L,J,W ) Cssw (L + (k + 1)J) ≤ Cssw (L + kJ). (10,5,9) This can be seen from a counterexample, i.e., for k = 2, Cssw (57) (10,5,9) (25) = 0.3293 > Cssw (20) = 0.3292. A. Numerical results Here, some numerical computations are performed to give more insights into the performance of (L, J, W )-SSW codes in the noiseless case. Moreover, some counterintuitive observations are made. Fig. 7 compares the capacities and the rates of (6, J, 3)-SSW codes for different J , in which capacity is plotted as dotted lines and rate is plotted as solid lines. Since an (L, J, W )-SSW code reduces to an SEC code when L = J , the curve of J = 6 has a constant rate as a function of length because the rate of the SEC code does not depend on length [7]. Some further remarks can be made from Fig. 7. First, higher capacity can be achieved by lengthening the skip length J for (6, J, 3)-SSW codes, which coincides with the intuition that shorter J will strengthen the sliding constraint and the stronger constraint should lower Capacities and rates of (6, J, 3)-SSW code of length 6 + kJ. 19 J =6 0.9 0.89 J =5 0.88 J =4 0.87 J =3 0.86 0.85 J =2 0.84 J =1 0.83 0.82 10 20 30 40 50 60 70 80 90 100 k Fig. 7. The capacities and rates of (6, J, 3)-SSW codes for different J. Capacities are drawn with dotted lines and rates with solid lines. the size of the code. Second, the rates of (6, J, 3)-SSW codes seem to be non-increasing with length, which provide support for the conjecture in the previous section. The (8, J, 7)-SSW codes, however, have completely different performance properties from (6, J, 3)SSW codes. Similar to Fig. 7, Fig. 8 plots capacities and rates for (8, J, 7)-SSW codes. We list some important points from Fig. 8 as follows. First, the rates of (8, J, 7)-SSW codes are no longer non-increasing as a function of the length. The J = 5 and J = 3 curves show that their rates are non-increasing except when K is close to 1. In particular, the curve for J = 7 even shows non-decreasing rate as a function of the length. Due to this observation, the case of L 6= ℓJ has been ruled out from Conjecture 1. Second, comparing the curves for J = 8 and J = 7, we surprisingly see that an (L, J, W )-SSW code with a longer J does not guarantee a higher capacity, contrary to intuition. Fig. 1 had suggested that an (L, J, W )-SSW code with a shorter J implies a stronger constraint is applied, which means the capacity of the (L, J, W )-SSW code should be higher than the (L, J − 1, W )-SSW code. However, this numerical computation shows the contrary result and is useful in applications of SSW codes. For simultaneous information and energy transmission, this observation implies that some SSW codes can have higher capacity than SEC codes while also guaranteeing smoother energy transmission. 20 Capacities and rates of (8, J, 7)-SSW code of length 8+kJ 0.42 J =7 0.4 J =8 0.38 J =5 0.36 J =3 0.34 0.32 J =1 0.3 0.28 0 10 20 30 40 50 60 70 80 90 k Fig. 8. The capacities and rates of (8, J, 7)-SSW codes for different J. Capacities are drawn with dotted lines and rates with solid lines. VI. N OISY C APACITY BOUNDS OF S KIP -S LIDING W INDOW C ODES In this section, we present bounds on the noisy capacity of binary SSW codes. In particular, we consider binary symmetric channels (BSCs) and binary erasure channels (BECs). (L,J,W ) We first discuss lower bounds on the noisy capacity. Let Cssw, BSC(p) denote the capacity of SSW codes over a BSC with crossover probability p. Then using Mrs. Gerber’s Lemma (MGL) [22], the noisy (L,J,W ) channel capacity Cssw, BSC(p) can be lower bounded as follows. Lemma 11. We have (L,J,W ) Cssw, BSC(p) ≥ h(α ⋆ p) − h(p), (58) where the binary operator ⋆ is defined as a ⋆ b , a(1 − b) + (1 − a)b, h(·) is the binary entropy function, (L,J,W ) and α is chosen such that h(α) = Cssw with 0 ≤ α ≤ 0.5. The bound (58) is tight for p → 0. Proof: Let X1n = (X1 , X2 , . . . , Xn ) denote a sequence satisfying the (L, J, W )-SSW constraint, and let Y1n = (Y1 , Y2 , . . . , Yn ) be the corresponding output from a BSC with crossover probability p. Then (L,J,W ) H(Y1n ) − H(Y1n |X1n ) , n→∞ Q(X n ) n 1 Cssw, BSC(p) = lim sup 21 where the supremum is taken over all input probability distributions Q(X1n ) of the sequences X1n (L,J,W ) satisfying the (L, J, W )-SSW constraint (2). A lower bound on Cssw, BSC(p) is obtained when X1n is uniformly distributed over the set of n-length sequences satisfying the (L, J, W )-SSW constraint. Thus, for uniformly distributed X1n , the constrained capacity over BSC can be lower bounded as follows. (L,J,W ) H(Y1n ) H(Y1n |X1n ) − n→∞ n n H(Y1n ) = lim − H(Y1 |X1 ) n→∞ n H(Y1n ) = lim − h(p). n→∞ n Cssw, BSC(p) ≥ lim (L,J,W ) Now, the noiseless capacity Cssw (59) = h(α), denotes the entropy rate of a binary source which produces sequences satisfying the (L, J, W )-SSW constraint, when the feasible input sequences are uniformly distributed. When these constrained sequences are transmitted over a BSC with crossover probability p, then using Mrs. Gerber’s Lemma (MGL), the output entropy rate is lower bounded as [23] H(Y1n ) ≥ h(α ⋆ p), n→∞ n lim (60) and we obtain (58) by combining (59) and (60). The tightness of the lower bound (58) follows as (L,J,W ) (L,J,W ) . lim Cssw, BSC(p) = h(α) = Cssw p→0 (L,J,W ) Let Cssw, BEC(ǫ) denote the capacity of SSW codes over a BEC with erasure probability ǫ. Using (L,J,W ) an extension of MGL for binary input symmetric channels [24], Cssw, BEC(ǫ) can be lower bounded as follows. Lemma 12. We have (L,J,W ) (L,J,W ) , Cssw, BEC(ǫ) ≥ (1 − ǫ)Cssw (61) and this bound is tight for ǫ → 0. Proof: Let X1n = (X1 , X2 , . . . , Xn ) denote a sequence satisfying the (L, J, W )-SSW constraint, and let Y1n = (Y1 , Y2 , . . . , Yn ) be the corresponding output from a BEC with erasure probability ǫ. Then, (L,J,W ) H(Y1n ) H(Y1n |X1n ) − n→∞ Q(X n ) n n 1 Cssw, BEC(ǫ) = lim sup H(Y1n ) − h(ǫ), n→∞ Q(X n ) n 1 = lim sup 22 where the supremum is taken over all input probability distributions Q(X1n ) of the sequences X1n satisfying the (L, J, W )-SSW constraint. When X1n is uniformly distributed over the set of feasible input sequences, we get (L,J,W ) H(Y1n ) − h(ǫ), n→∞ n Cssw, BEC(ǫ) ≥ lim (L,J,W ) Now, the noiseless capacity Cssw (62) denotes the entropy rate of a binary source which produces se- quences satisfying the (L, J, W )-SSW constraint, when feasible input sequences are uniformly distributed. When these constrained sequences are transmitted over a BEC with erasure probability ǫ, then using an extension of MGL for binary-input symmetric channels, the output entropy rate is lower bounded as [24] H(Y1n ) (L,J,W ) ≥ (1 − ǫ)Cssw + h(ǫ), n→∞ n lim (63) and we obtain (61) by combining (62) and (63). The tightness of the bound follows as (L,J,W ) (L,J,W ) . lim Cssw, BEC(ǫ) = Cssw ǫ→0 Remark: The noiseless capacity provides a trivial upper bound on the capacity of noisy channels. Therefore, Lemmma 11 (resp. Lemma 12) implies that if the noiseless capacity of two different SSW (L ,J1 ,W1 ) codes satisfies Cssw1 (L ,J2 ,W2 ) > Cssw2 , then for sufficiently small crossover probability p (resp. erasure   (L2 ,J2 ,W2 ) (L1 ,J1 ,W1 ) (L2 ,J2 ,W2 ) (L ,J1 ,W1 ) > C resp. C > Cssw, probability ǫ), we have the inequality Cssw,1 BSC(p) ssw, BEC(ǫ) . ssw, BEC(ǫ) BSC(p) Alternate lower bounds on the noisy capacity of skip-sliding window codes can be obtained using a generic bound by Zehavi and Wolf [23, Lemma 4] on the noisy capacity of constrained sequences generated by a Markov source. As shown in Sec. III-A, an (L, J, W )-SSW code can be represented via a finite state machine (FSM). Thus, a source producing SSW constrained sequences can be modeled as a stationary Markov source with non-zero probabilities associated with feasible state transitions in the corresponding FSM. As shown in Sec. III-A, a binary (L, J, W )-SSW code forms a FSM, in which J consecutive uses of the channel can be viewed as a single use of a vector channel with super-letter input alphabet X = {0, 1}J and super-letter output alphabet Y = {0, 1}J . Let S = {s1 , s2 , . . . , sk } be the set of k distinct states in a FSM associated with the corresponding (L, J, W )-SSW code. For 1 ≤ i, j ≤ k, let qi,j be the probability that FSM transitions to state sj , given that the current state is si . Let Q = [qi,j ] denote the state-transition probability matrix, and let xij be the super-letter symbol produced when FSM transitions from state si to sj . Further, let P r(S = si ) denotes the steady-state probability that FSM will be in state si . Then the (L,J,W ) capacity Cssw, BSC(p) over BSC with crossover probability p is lower bounded as follows. 23 Lemma 13. We have (L,J,W ) Cssw, BSC(p) ≥ sup Q k X P r(S = si ) i=1 H(Y |S = si ) − h(p), J (64) where the conditional distribution for output super-letter Y , is given by k X P r(y|S = si ) = qi,j P r(y|xij ), 1 ≤ i ≤ k, xij ∈ X J , y ∈ Y J j=1 P r(y|xij ) = pd(y,xij ) (1 − p)J−d(y,xij ) , (65) with X = Y = {0, 1} and d(y, xij ) denotes the Hamming distance between super-letters y and xij . Proof: For a given (L, J, W )-SSW constraint, consider the corresponding FSM with state space S = {s1 , s2 , . . . , sk }. The transition probability from state si to state sj is qi,j . Let S denote the previous state, and let S̃ denote the current state. When 2J -ary super-letters produced from this Markov source are transmitted over a memoryless channel, then the super-letter capacity is lower bounded by the conditional mutual information term [23, Lemma 4] supP r(S,S̃) I(Y , S̃|S). Because the super-letter capacity corresponds to J uses of the channel, the scalar capacity per channel use can therefore be lower bounded as follows. I(Y , S̃|S) J P r(S,S̃) (L,J,W ) Cssw, BSC(p) ≥ sup ! H(Y |S) H(Y |S, S̃) = sup − J J P r(S,S̃)   k k X X H(Y |S = si ) H(Y |X = xij )  P r(S = si )  = sup qi,j − J J Q i=1 j=1   k k X H(Y |S = si ) X (i) qi,j h(p) − P r(S = si )  = sup J Q j=1 i=1 = sup Q k X i=1 P r(S = si ) H(Y |S = si ) − h(p), J where (i) follows from the memoryless property of BSC. Now, consider a BEC with input alphabet X = {0, 1}, output alphabet Y = {0, 1, e}, where e denotes the erasure symbol and let the erasure probability be denoted ǫ. Then J consecutive uses of this BEC will induce a vector-channel with input super-letter alphabet X J and output super-letter alphabet Y J . Further, (m) for 1 ≤ m ≤ J , let xij (1) (2) (J) denote the m-th letter of super-letter xij ∈ X J with xij = (xij xij . . . xij ). 24 Similarly, for y ∈ Y J , let y = (y (1) y (2) . . . y (J) ). Then, for this induced vector channel, the probability of receiving super-letter y ∈ Y J , given that super-letter xij ∈ X J is transmitted, is given by   (m) 0, if y (m) 6= xij and y (m) 6= e, for 1 ≤ m ≤ J, P r(y|xij ) =  ǫty (1 − ǫ)J−ty , otherwise, (66) where ty denotes the number of erasure symbols in output super-letter y . The following lemma provides a lower bound to the capacity of (L, J, W )-SSW codes over BEC with erasure probability ǫ. Lemma 14. We have (L,J,W ) Cssw, BEC(ǫ) ≥ sup Q k X P r(S = si ) i=1 H(Y |S = si ) − h(ǫ), J (67) where the distribution for output super-letter Y , given that the transmitted input super-letter is X = xij , P is given by (66), and P r(y|S = si ) = kj=1 qi,j P r(y|xij ). The proof of the above lemma follows using steps similar to those used in the proof of Lemma 13, and is hence omitted. We now provide upper bounds to the noisy capacity of (ℓJ, J, W )-SSW codes. Lemma 15. We have o n (ℓJ,ℓJ,W ) (ℓJ,J,W ) (ℓJ,J,W ) , Cssw, BSC(p) . Cssw, BSC(p) ≤ min Cssw (ℓJ,J,W ) (68) (ℓJ,J,W ) Proof: The noisy capacity Cssw, BSC(p) is obviously upper bounded by the noiseless capacity Cssw . Further, as every (ℓJ, J, W )-SSW sequence is also an (ℓJ, ℓJ, W )-SSW sequence, we have the inequality (ℓJ,ℓJ,W ) (ℓJ,J,W ) Cssw, BSC(p) ≤ Cssw, BSC(p) . (ℓJ,ℓJ,W ) Note that Cssw, BSC(p) corresponds to the capacity of subblock energy-constrained (SEC) codes with subblock length ℓJ and subblock weight at least W , over a BSC with crossover probability p. This capacity term can numerically be computed for reasonable subblock lengths using the Blahut-Arimoto algorithm [25], [26], by applying the super-letter approach for characterizing the capacity of SEC codes over arbitrary discrete memoryless channels in [7]. Similar to Lemma 15, the following lemma provides an upper bound to the capacity of (ℓJ, J, W )-SSW codes over BEC. Lemma 16. We have o n (ℓJ,ℓJ,W ) (ℓJ,J,W ) (ℓJ,J,W ) , Cssw, BEC(ǫ) . Cssw, BEC(ǫ) ≤ min Cssw (69) 25 0.6 Lower Bound: (51) Lower Bound: (57) Upper Bound: (61) 0.5 (3,1,2) Cssw, BSC(p) 0.4 0.3 0.2 0.1 0 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 BSC crossover probability, p Fig. 9. Bounds on the noisy channel capacity of (3, 1, 2)-SSW codes over BSC. 0.41 (8,7,7) Lower Bound of CSSW,BSC(p) : (51) (8,8,7) Capcity over BSC(p) 0.405 CSSW,BSC(p) (equivalent to SEC code) 0.4 0.395 0.39 0.385 0.38 0.375 0.37 0 0.5 1 1.5 2 2.5 3 3.5 BSC crossover probability, p (8,7,7) (8,8,7) 4 4.5 5 ×10 -3 Fig. 10. Comparison between the lower bound of Cssw, BSC(p) and the exact Cssw, BSC(p) . The latter one is also an SEC code. 26 0.6 Lower Bound: (54) Lower Bound: (60) Upper Bound: (62) 0.5 (3,1,2) Cssw, BEC(ǫ) 0.4 0.3 0.2 0.1 0 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 BEC erasure probability, ǫ Fig. 11. Bounds on the noisy channel capacity of (3, 1, 2)-SSW codes over BEC. A. Numerical Results In this subsection, we plot bounds on the noisy channel capacity of SSW codes. Fig. 9 plots bounds on capacity of (L, J, W )-SSW codes over a BSC with crossover probability p, for L = 3, J = 1, and W = 2. The blue dotted line plots the lower bound on the noisy capacity given by (58), while the red line depicts the lower bound given by (64). In this case, it is seen that the lower bound (64) is uniformly better than the lower bound obtained using Mrs. Gerber’s Lemma (MGL) in (58). The black curve, providing an upper bound on the capacity, is obtained using (68). Further, it is seen that the bounds are tight for cases when p → 0 and p → 0.5. We further examine the surprising observation from Fig. 8 that SSW codes may outperform SEC codes. Fig. 10 compares the (8, 7, 7)-SSW code and (8, 8, 7)-SSW code over a BSC with a small crossover (8,8,7) probability (0 ≤ p ≤ 0.005). Here, the SEC capacity Cssw, BSC(p) is numerically computed [7] using the Blahut-Arimoto algorithm. For the (8, 7, 7)-SSW code, the capacity lower bound is plotted using (58). It can be seen that the noisy capacity of SSW codes may be larger than that of SEC codes when p is small, just like the noiseless case. Fig. 11 plots bounds on capacity of (3, 1, 2)-SSW codes over a BEC with erasure probability ǫ. The 27 lower bounds on the capacity are given by (61) and (67), while the upper bound is obtained using (69). In this case, it is observed that the two lower bounds coincide, and the bounds become tight for ǫ → 0 and ǫ → 1. VII. C ONCLUSION This paper proposed a new kind of constrained code, the skip-sliding window code, which is potentially useful in diverse applications. Efficient enumeration methods were proposed to calculate its noiseless capacity and properties were discussed. Numerical results showed counterintuitive performance characterizations, such as the fact there can be skip-sliding window codes that outperform subblockenergy constraint codes [7], [8] in both the capacity and the smoothness of energy transmission in simultaneous information and energy transmission. Based on the numerical results, a conjecture on the noiseless capacity was also raised. With the help of noiseless capacity results, some noisy capacity bounds were further investigated; counterintuitive ordering of performance still holds. R EFERENCES [1] K. A. S. Immink, “Runlength-limited sequences,” Proceedings of the IEEE, vol. 78, no. 11, pp. 1745–1759, Nov. 1990. [2] ——, Codes for Mass Data Storage Systems. Shannon Foundation Publisher, 2004. [3] S. Ulukus, A. Yener, E. Erkip, O. Simeone, M. Zorzi, P. Grover, and K. Huang, “Energy harvesting wireless communications: a review of recent advances,” IEEE Journal on Selected Areas in Communications, vol. 33, no. 3, pp. 360–381, Mar. 2015. [4] E. Rosnes, Á. I. Barbero, and Ø. Ytrehus, “Coding for inductively coupled channels,” IEEE Transactions on Information Theory, vol. 58, no. 8, pp. 5418–5436, Aug. 2012. [5] A. M. Fouladgar, O. Simeone, and E. Erkip, “Constrained codes for joint energy and information transfer,” IEEE Transactions on Communications, vol. 62, no. 6, pp. 2121–2131, Jun. 2014. [6] A. Tandon, M. Motani, and L. R. Varshney, “On code design for simultaneous energy and information transfer,” in Proceedings of the 2014 Information Theory and Applications Workshop, Feb. 2014. [7] ——, “Subblock-constrained codes for real-time simultaneous energy and information transfer,” IEEE Transactions on Information Theory, vol. 62, no. 7, pp. 4212–4227, Jul. 2016. [8] A. Tandon, H. M. Kiah, and M. Motani, “Binary subblock energy-constrained codes: Bounds on code size and asymptotic rate,” in Proceedings of the 2017 IEEE International Symposium on Information Theory, Jun. 2017, pp. 1480–1484. [9] G. Cohen, P. Solé, and A. Tchamkerten, “Heavy weight codes,” in Proceedings of the 2010 IEEE International Symposium on Information Theory, Jun. 2010, pp. 1120–1124. [10] C. Bachoc, V. Chandar, G. Cohen, P. Solé, and A. Tchamkerten, “On bounded weight codes,” IEEE Transactions on Information Theory, vol. 57, no. 10, pp. 6780–6787, Jul. 2011. [11] P. E. C. Compeau, P. A. Pevzner, and G. Tesler, “How to apply de Bruijn graphs to genome assembly,” Nature Biotechnology, vol. 29, no. 11, pp. 987–991, Nov. 2011. [12] N. G. De Bruijn, “A combinatorial problem,” Proceedings of the Section of Sciences, vol. 49, no. 7, pp. 758–764, Jun. 1946. [13] N. Beldiceanu and S. Demassey, “Sliding time window sum,” Jan. 2010. 28 [14] P. V. Salimov, “On Rauzy graph sequences of infinite words,” Journal of Applied and Industrial Mathematics, vol. 4, no. 1, pp. 127–135, Jan. 2010. [15] M. Rigo, Formal Languages, Automata and Numeration Systems. New York: John Wiley & Sons, 2014. [16] W.-J. van Hoeve et al., “Revisiting the sequence constraint,” in Proceedings of the 2006 International Conference on Principles and Practice of Constraint Programming, Sep. 2006, pp. 620–634. [17] K. R. Apt, Principles of Constraint Programming. Cambridge: Cambridge University Press, 2003. [18] I. P. Goulden and D. M. Jackson, “An inversion theorem for cluster decompositions of sequences with distinguished subsequences,” Journal of the London Mathematical Society, vol. 2, no. 3, pp. 567–576, Dec. 1979. [19] R. P. Stanley, Algebraic Combinatorics: Walks, Trees, Tableaux, and More. New York: Springer-Verlag, 2013. [20] B. Marcus, R. Roth, and P. Siegel, “Introduction to coding for constrained systems,” Oct. 2001. [Online]. Available: http://www.math.ubc.ca/%7Emarcus/Handbook/ [21] V. Kozyakin, “On accuracy of approximation of the spectral radius by the Gelfand formula,” Linear Algebra and its Applications, vol. 431, no. 11, pp. 2134–2141, Nov. 2009. [22] A. D. Wyner and J. Ziv, “A theorem on the entropy of certain binary sequences and applications–I,” IEEE Transactions on Information Theory, vol. IT-19, no. 6, pp. 769–772, Nov. 1973. [23] E. Zehavi and J. K. Wolf, “On runlength codes,” IEEE Transactions on Information Theory, vol. 34, no. 1, pp. 45–54, 1988. [24] N. Chayat and S. Shamai, “Extension of an entropy property for binary input memoryless symmetric channels,” IEEE Transactions on Information Theory, vol. 35, no. 5, pp. 1077–1079, Sept. 1989. [25] R. E. Blahut, “Computation of channel capacity and rate-distortion functions,” IEEE Transactions on Information Theory, vol. IT-18, no. 4, pp. 460–473, Jul. 1972. [26] S. Arimoto, “An algorithm for computing the capacity of arbitrary discrete memoryless channels,” IEEE Transactions on Information Theory, vol. IT-18, no. 1, pp. 14–20, Jan. 1972.
7cs.IT
arXiv:1507.03307v2 [math.AC] 9 Mar 2016 ALMOST GORENSTEIN HOMOGENEOUS RINGS AND THEIR h-VECTORS AKIHIRO HIGASHITANI Abstract. In this paper, for the development of the study of almost Gorenstein graded rings, we discuss some relations between almost Gorensteinness of Cohen–Macaulay homogeneous rings and their h-vectors. Concretely, for a Cohen–Macaulay homogeneous ring R, we give a sufficient condition for R to be almost Gorenstein in terms of the h-vector of R (Theorem 3.1) and we also characterize almost Gorenstein homogeneous domains with small socle degrees in terms of the h-vector of R (Theorem 4.4). Moreover, we also provide the examples of almost Gorenstein homogeneous domains arising from lattice polytopes. 1. Introduction Recently, for the study of a new class of local or graded rings which are Cohen–Macaulay but not Gorenstein, almost Gorenstein local or graded rings were defined and have been studied. In this paper, for the further study of almost Gorenstein rings, we concentrate on almost Gorenstein homogeneous rings and investigate the h-vectors of almost Gorenstein homogeneous rings. Originally, the notion of almost Gorenstein local rings of dimension one was introduced by Barucci and Fröberg [1] in the case where the local rings are analytically unramified. After this work, Goto, Matsuoka and Phuong [5] modified the definition of one-dimensional almost Gorenstein local rings, which also works well in the case where the rings are analytically ramified. As a further investigation of almost Gorenstein local rings, the definition of almost Gorenstein local or graded rings of higher dimension suggested by Goto, Takahashi and Taniguchi [6]. We refer the reader to [1, 5, 6] for the detailed information on almost Gorenstein rings. In addition, Matsuoka and Murai [10] have studied the almost Gorenstein Stanley– Reisner rings. They introduce the notion “uniformly Cohen–Macaulay” and they prove that a simplicial complex ∆ is uniformly Cohen–Macaulay if and only if there exists an injection from the Stanley–Reisner ring k[∆] to its canonical module ωk[∆]. This is a necessary condition for k[∆] to be almost Gorenstein (with a-invariant 0). They also characterize the almost Gorenstein∗ simplicial complexes of dimension at most 2. See [10, Section 3.3]. Inspired by these works (especially [6] and [10]), we will study higher dimensional almost Gorenstein homogeneous rings. The main goal of this paper is to give a characterization of 2010 Mathematics Subject Classification: Primary 13H10; Secondary 13D40, 13H15. Keywords: Almost Gorenstein, Cohen–Macaulay, Gorenstein, h-vector, homogeneous domain. 1 almost Gorensteinness in terms of the Hilbert series, namely, the h-vector of the Cohen– Macaulay homogeneous ring. For a Cohen–Macaulay homogeneous domain and the h-vector (h0 , h1 , . . . , hs ) of R, it is known by the work of Stanley [13, Theorem 4.4] that R is Gorenstein if and only if hi = hs−i for i = 0, 1, . . . , ⌊s/2⌋. (See, also [2, Corollary 4.4.6].) This says that the “symmetry” of the h-vector of R characterizes the Gorensteinness of R. Hence, it is natural to think of some “almost symmetry” of the h-vector of R may characterize the almost Gorensteinness of R. Although to give a complete characterization might be impossible, we will prove that a certain almost symmetry of the h-vector of a Cohen–Macaulay homogeneous ring can be a sufficient condition to be almost Gorenstein (Theorem 3.1). In addition, in the case where the ring is a domain and the socle degree is small, we will characterize the almost Gorensteinness in terms of its h-vector (Theorem 4.4). The structure of this paper is as follows. In Section 2, we recall the definition of almost Gorenstein graded rings and prepare some propositions for the discussions later. In Section 3, we prove that a certain almost symmetry of the h-vector of the Cohen– Macaulay homogeneous ring implies the almost Gorensteinness. More precisely, let R be a Cohen–Macaulay homogeneous ring and (h0 , h1 , . . . , hs ) its h-vector. We prove that if hi = hs−i for i = 0, 1, . . . , ⌊s/2⌋ − 1, then R is almost Gorenstein (Theorem 3.1). In Section 4, we characterize the almost Gorenstein homogeneous domain in terms of its hvector. More precisely, for a Cohen–Macaulay homogeneous domain R, let (h0 , h1 , . . . , hs ) be the h-vector of R. When s = 2, the following three conditions are equivalent: (i) R is almost Gorenstein; (ii) R is Gorenstein; (iii) h2 = 1. Moreover, when s = 3, R is almost Gorenstein if and only if h3 = 1. (See Theorem 4.4.) Finally, in Section 5, we supply some examples of almost Gorenstein homogeneous domains arising from lattice polytopes. Acknowledgements. The authors would like to be grateful to Shiro Goto, Naoyuki Matsuoka and Naoki Taniguchi for their helpful comments and instructive discussions. The author is partially supported by JSPS Grant-in-Aid for Young Scientists (B) ♯26800015. 2. Preliminaries Let R be a Cohen–Macaulay homogeneous ring of dimension d over an algebraically closed field k with characteristic 0. Let a = a(R) be the a-invariant of R and let ωR be a canonical module of R. Note that a(R) = − min{j : (ωR )j 6= 0}. 2.1. Definitions. We collect some notation used throughout this paper. • For a graded R-module M , – let µ(M ) denote the number of elements in a minimal system of generators of M as an R-module; – let e(M ) denote the multiplicity of M ; – note that we have in general the inequality (2.1) e(M ) ≥ µ(M ); – let M (−ℓ) denote the R-module whose underlying R-module is the same as that of M and whose grading is given by (M (−ℓ))n = Mn−ℓ for all n ∈ Z; 2 – let [[M ]] denote the Hilbert series of M , i.e., X [[M ]] = (dimk Mn )tn . n∈Z • We denote the Cohen–Macaulay type of R by r(R). Note that r(R) = µ(ωR ). • We say that (h0 , h1 , . . . , hs ) is the h-vector of R if X h0 + h1 t + · · · + hs ts [[R]] = (dimk Rn )tn = (1 − t)d n≥0 with hs 6= 0. It is well known that each hi is a nonnegative integer (since R is Cohen–Macaulay) and h0 = 1. When (h0 , h1 , . . . , hs ) is the h-vector of R, the index s is called the socle degree of R. Let us recall the definition of the almost Gorenstein graded ring. Definition 2.1 ([6, Definition 1.5]). We say that a Cohen–Macaulay graded ring R is almost Gorenstein if there exists an exact sequence (2.2) φ 0→R− → ωR (−a) → C → 0 of graded R-modules with µ(C) = e(C), where φ is an injection of degree 0. 2.2. Properties on C. For a while, we consider the condition: (2.3) there exists an injection φ : R → ωR (−a) of degree 0. This is a necessary condition for R to be almost Gorenstein. Let C = coker(φ). Then C is a Cohen–Macaulay R-module of dimension d − 1 if C 6= 0 (see [6, Lemma 3.1]). First, we see that the condition (2.3) is satisfied in some cases. For example: Proposition 2.2. When R is a domain, R always satisfies the condition (2.3). Proof. When R is a domain, a canonical module ωR can be taken as an ideal IR ⊂ R ([2, Section 3.3]). Replace ωR by a canonical ideal IR of R. Consider any R-homomorphism φ : R → IR (−a) of degree 0 with φ 6= 0. Take x ∈ ker(φ). Then φ(x) = x · φ(1) = 0. Since x ∈ R and φ(1) ∈ IR ⊂ R and R is a domain, we see x = 0 or φ(1) = 0. Since φ(1) 6= 0, we obtain x = 0, i.e., ker(φ) = 0, as desired.  Next, we would like to describe µ(C) and e(C) in terms of some invariants on R. Proposition 2.3. Assume that R satisfies (2.3). Then µ(C) = r(R) − 1. Proof. Since φ is a degree 0 injection and all elements of (ωR (−a))0 can be its minimal generators, φ(1) can be an element of minimal generators of ωR (−a). Hence, the assertion follows from the exact sequence (2.2).  Proposition 2.4. Assume that R satisfies (2.3). Let (h0 , h1 , . . . , hs ) be the h-vector of R. Then we have Ps−1 j j=0 ((hs + · · · + hs−j ) − (h0 + · · · + hj ))t (2.4) . [[C]] = (1 − t)d−1 Ps−1 In particular, we have e(C) = j=0 ((hs + · · · + hs−j ) − (h0 + · · · + hj )). 3 Proof. We know that [[R]] = 4.4.6]) that Ps j=0 hj t j /(1−t)d [[ωR (−a)]] = and it is also known (e.g., see [2, Corollary Ps j=0 hs−j t (1 − t)d j . From the exact sequence (2.2), we obtain [[C]] = [[ωR (−a)]] − [[R]]. On the other hand, P since M is a Cohen–Macaulay module of dimension d − 1, [[C]] looks like j≥0 h′j tj /(1 − t)d−1 , where each h′j is a nonnegative integer. Hence we obtain the equality  P Ps ′ tj (1 − t) j h j≥0 j j=0 (hs−j − hj )t = . d (1 − t) (1 − t)d This implies that h′j = (hs + · · · + hs−j ) − (h0 + · · · + hj ) for j = 0, 1, . . . , s, as required.  From this proposition, we obtain: Corollary 2.5. Assume that R satisfies (2.3). Let (h0 , h1 , . . . , hs ) be the h-vector of R. Then we have the inequality hs + · · · + hs−j ≥ h0 + · · · + hj for each j = 0, 1, . . . , ⌊s/2⌋, and R is Gorenstein if and only if all the equalities hold, namely, hj = hs−j for each j = 0, 1, . . . , ⌊s/2⌋. Proof. The above inequality directly follows from (2.4) and the Cohen–Macaulayness of C. Moreover, since R is Gorenstein if and only if C = 0, the second assertion also follows.  Remark 2.6. Corollary 2.5 is just an analogy of Stanley’s inequality for the h-vectors of semi-standard Cohen–Macaulay domains ([14, Theorem 2.1]). In the case of Stanley– Reisner ring of a uniformly Cohen–Macaulay simplicial complex, this inequality is also shown in [10, Proposition 2.7]. Corollary 2.7. The following four conditions are equivalent: (a) there exists an injection φ : R → ωR (−a) of degree 0 such that C = coker(φ) satisfies µ(C) = e(C), namely, R is almost Gorenstein; (b) every injection φ : R → ωR (−a) of degree 0 satisfies µ(C) = e(C); (c) we have r(R) − 1 = s−1 X ((hs + · · · + hs−j ) − (h0 + · · · + hj )); j=0 (d) we have (2.5) dimk (ωR ⊗ k)−a+j = (hs + · · · + hs−j ) − (h0 + · · · + hj ) for each j = 1, . . . , s − 1. In particular, φ does not matter for the almost Gorensteinness of R. 4 Proof. First, we observe that all the elements of ωR (−a) of degree 0 can be an element of minimal system of generators of ωR (−a). Thus, by Proposition 2.3 and Proposition 2.4, we obtain the equivalence of (a) and (b) and (c). Ps−1 Next, the implication (d) ⇒ (c) easily follows from the facts r(R) = j=0 dimk (ωR ⊗ k)−a+j and hs = dimk (ωR ⊗ k)−a . Finally, consider the implication (c) ⇒ (d). From the exact sequence (2.2), we obtain the exact sequence R ⊗ k → ωR (−a) ⊗ k → C ⊗ k → 0. Since (R ⊗ k)j = 0 for j ≥ 1, by taking (−)j with j ≥ 1 for this sequence, we obtain the isomorphism (ωR ⊗ k)−a+j ∼ = (C ⊗ k)j for j ≥ 1. In general, for a graded R-module M of dimension e, we see that dimk (M ⊗k)j ≤ P h′j if [[M ]] = j∈Z h′j tj /(1 − t)e . Hence, we obtain the inequality dimk (ωR ⊗ k)−a+j ≤ (hs + · · · + hs−j ) − (h0 + · · · + hj ) for each j = 1, . . . , s − 1 by Proposition 2.4. Therefore, if dimk (ωR ⊗ k)−a+j < (hs + Ps−1 · · · + hs−j ) − (h0 + · · · + hj ) for some j, since r(R) = j=0 dimk (ωR ⊗ k)−a+j and hs = Ps−1 dimk (ωR ⊗ k)−a , we conclude that r(R) − 1 < j=0 ((hs + · · · + hs−j ) − (h0 + · · · + hj )), as desired.  3. A sufficient condition to be almost Gorenstein in terms of h-vectors Let R be a Cohen–Macaulay homogeneous ring of dimension d satisfying the condition (2.3) and let (h0 , h1 , . . . , hs ) be the h-vector of R. One of the main results of this paper is the following: Theorem 3.1. If hi = hs−i for i = 0, 1, . . . , ⌊s/2⌋ − 1, then R is almost Gorenstein. This theorem should be compared with the following Stanley’s theorem: Theorem 3.2 ([13, Theorem 4.4]). Assume that R is a domain. Then R is Gorenstein if and only if hi = hs−i for i = 0, 1, . . . , ⌊s/2⌋. This theorem says that under the assumption R is a domain, the symmetry of the hvector of R can be a necessary and sufficient condition for R to be Gorenstein. On the other hand, Theorem 3.1 says that a certain “almost symmetry” of the h-vector of R can be a sufficient condition for R to be almost Gorenstein. Proof of Theorem 3.1. When s is even, h⌊s/2⌋ = hs−⌊s/2⌋ is automatically satisfied. Hence, R is Gorenstein by Theorem 3.2, in particular, almost Gorenstein. Assume that s is odd. Let C = coker φ, where φ is an injection in (2.3). We may show that µ(C) = e(C). By Proposition 2.4, we have (h(s+1)/2 − h(s−1)/2 )t(s−1)/2 . [[C]] = (1 − t)d−1 Hence, it is easy to see that C satisfies µ(C) = e(C)(= h(s+1)/2 −h(s−1)/2 ), as required.  5 4. Almost Gorenstein homogeneous domains with small socle degrees Assume that R satisfies the condition (2.3). Let (h0 , h1 , . . . , hs ) be the h-vector of R. In this section, we discuss the condition for R to be almost Gorenstein in terms of h-vectors in the case where s is small. First, we observe the case s = 1. Theorem 4.1 ([6, Theorem 10.4]). In the case s = 1, R is always almost Gorenstein. Moreover, in this case, R is Gorenstein if and only if h1 = 1. Proof. In the statement of [6, Theorem 10.4], the condition a = 1− d is equivalent to s = 1 and the condition “Q(R) is a Gorenstein ring” is automatically satisfied since R satisfies (2.3) ([6, Lemma 3.1]). Thus, [6, Theorem 10.4] directly implies the assertion. Moreover, the condition for R to be Gorenstein follows from Theorem 3.2.  Next, let us discuss the case s > 1. It is well known that the inequality hs ≤ r(R) holds in general. We say that R is level if hs = r(R). (See, e.g., [8]). One can see from [6, Lemma 10.2] that if R is level and s > 1, then R is almost Gorenstein if and only if R is Gorenstein. Before considering the almost Gorensteinness of R, we give an upper bound for the Cohen–Macaulay types of Cohen–Macaulay homogeneous domains in Theorem 4.2. We will use this for the proof of Theorem 4.4. The most part of the discussions for Theorem 4.2 is derived from [11, Section 3]. Theorem 4.2. Let R be a Cohen–Macaulay homogeneous domain. Then s X (4.1) hi − (s − 2)h1 . r(R) ≤ i=2 Proof. Take a nonzero divisor x of R. Then we have r(R) = r(R/(x)) and the h-vectors of R and R/(x) are equal. Hence, by the similar argument to [11, Lemma 3.1], it suffices to show that for any set of points in uniform position X ⊂ Pr (r ≥ 2) and the homogeneous coordinate ring R of X, the inequality (4.1) holds. Assume that R is the coordinate ring of a set of points in uniform position X ⊂ Pr (r ≥ 2). Let s be the socle degree of R. For i = 1, . . . , s − 1, let ϕi : S1 ⊗ (ωR )−s+i −→ (ωR )−s+i+1 be the multiplication map, where S = Symk R1 is the coordinate ring of Pr . Then this map ϕi is 1-generic ([11, Proposition 1.5]). By the theory of 1-generic map, we have dimk Im ϕi ≥ dimk S1 + dimk (ωR )−s+i − 1 for each i = 1, . . . , s − 1 (see [3]). Hence dimk Im ϕi ≥ dimk S1 + dimk (ωR )−s+i − 1 = h1 + 1 + (hs + hs−1 + · · · + hs−i+1 ) − 1 = h1 + hs + hs−1 + · · · + hs−i+1 . On the other hand, we have dimk (ωR )−s+i+1 = hs + hs−1 + · · · + hs−i . Thus, we see that dimk (ωR )−s+i+1 − dimk Im ϕi ≤ hs−i − h1 . By dimk (ωR ⊗ k)−s+i+1 ≤ dimk (ωR )−s+i+1 − dimk Im ϕi , we obtain the inequality (4.2) dimk (ωR ⊗ k)−a+i ≤ hs−i − h1 6 for i = 1, . . . , s − 1. (Note that −a = −s + 1 in this setting.) Since we can see that (ω ⊗k)i = 0 for each i ≥ 1 and i ≤ −s ([11, Lemma 3.9]), we have µ(ωR ) ≤ dimk (ωR )−a + PR s−1 i=1 (dimk (ωR )−a+i − dimk Im ϕi ). Therefore, r(A) = µ(ωR ) ≤ dimk (ωR )−a + s−1 X (dimk (ωR )−a+i − dimk Im ϕi ) i=1 s s−1 X X hi − (s − 2)h1 . (hs−i − h1 ) = ≤ hs + i=2 i=1  As an immediate corollary of Theorem 4.2, we see the following. Note that the following has been already obtained in [11]. Corollary 4.3 ([11, Corollary 3.11]). If the socle degree of R is 2, then R is level. Proof. In this case, the inequality (4.1) implies r(R) ≤ h2 . On the other hand, as mentioned above, we always have r(R) ≥ h2 . Hence, r(R) = h2 .  When s = 2 or s = 3 and R is a domain, we can characterize the almost Gorensteinness of R in terms of the h-vector as follows: Theorem 4.4. Assume that R is a domain. (a) When s = 2, the following conditions are equivalent: (i) R is almost Gorenstein; (ii) R is Gorenstein; (iii) h2 = 1. (b) When s = 3, R is almost Gorenstein if and only if h3 = 1. Proof. (a) When s = 2, R is always level by Corollary 4.3. Hence, the equivalence (i) ⇔ (ii) follows. Moreover, (ii) ⇔ (iii) also holds by Theorem 3.2. (b) Let C = coker φ in (2.3). From Proposition 2.3 and Proposition 2.4, we have µ(C) = r(R) − 1 and e(C) = 3(h3 − h0 ) + h2 − h1 , respectively. By the inequality (4.1) given in Theorem 4.2, we see that e(C) − µ(C) = 3(h3 − h0 ) + h2 − h1 − (r(R) − 1) ≥ 3(h3 − 1) + h2 − h1 − (h2 + h3 − h1 − 1) = 2(h3 − 1). Hence, if h3 > 1, then R is never almost Gorenstein by e(C) − µ(C) > 0. On the other hand, if h3 = 1, then R is almost Gorenstein by Theorem 3.1, as required.  Remark 4.5. In the case s ≥ 4, we do not know any characterization of almost Gorensteinness in terms of h-vectors. However, any characterization of almost Gorensteinness using h-vectors might be impossible. For example, whether R is level or not cannot be determined by h-vectors. See [8, Section 3]. The examples described in [8, Section 3] say that the Cohen–Macaulay type cannot be determined in terms of h-vectors in general. 7 Hence, by considering Corollary 2.7, it is natural to think of we cannot characterize almost Gorensteinness in terms of h-vectors, either. We remain the following: Problem 4.6. If exists, find examples of Cohen–Macaulay homogeneous domains R and R′ such that • the h-vectors of R and R′ are equal; • R is almost Gorenstein; • R′ is not almost Gorenstein. Moreover, we are also interested in the question: if R is an almost Gorenstein homogeneous domain with s ≥ 2, then does hs = 1 holds? This is true when s = 2 and s = 3 by Theorem 4.4. On the other hand, when R is not a domain, this is not true even in the case s = 2. In fact, by taking the ridge sum of Gorenstein simplicial complexes, we can obtain an almost Gorenstein Stanley–Reisner ring with hs ≥ 2. For the detail, see [10]. Actually, this is true in general. Theorem 4.7. Let R be an almost Gorenstein homogeneous domain and (h0 , h1 , . . . , hs ) its h-vector with s ≥ 2. Then hs = 1. Proof. From Corollary 2.7 (d), the inequality (2.5) holds. In particular, we see that dimk (ωR ⊗ k)−a+1 = (hs + hs−1 ) − (h0 + h1 ). On the other hand, since R is a domain, we also obtain dimk (ωR ⊗ k)−a+1 ≤ hs−1 − h1 by (4.2) for i = 1. Therefore, we conslude that hs ≤ h0 = 1, i.e., hs = 1.  5. Examples : Almost Gorenstein Ehrhart rings In this section, we provide some examples of almost Gorenstein homogeneous domains which are given by Ehrhart rings of lattice polytopes. Before giving examples, let us recall what the Ehrhart ring of a lattice polytope is. Let P ⊂ Rd be a lattice polytope, which is a convex polytope all of whose vertices belong to the standard lattice Zd , of dimension d. Let k be a field. Then we define the k-algebra k[P ] as follows: k[P] = k[Xα Z n : α ∈ nP ∩ Zd , n ∈ Z≥0 ], where for α = (α1 , . . . , αd ) ∈ Zd , Xα Z n = X1α1 · · · Xdαd Z n denotes a Laurent monomial in k[X1± , . . . , Xd± , Z] and nP = {nv : v ∈ P}. This k[P] is a normal Cohen–Macaulay graded domain of dimension d + 1, where a grading is defined by deg(Xα Z n ) = n for α ∈ nP ∩ Zd . The ring k[P] is called the Ehrhart ring of P. Note that the Ehrhart ring is not necessarily standard graded, but is semi-standard graded, i.e., k[P] is a finitely generated module over 8 the subring of k[P ] generated by all the elements of degree 1. Hence, the Hilbert series of k[P] (called the Ehrhart series of P) is of the form: Ps h∗i ti [[ k[P] ]] = i=0 d+1 , h∗i ∈ Z≥0 . (1 − t) The sequence of the coefficiens h∗ (P) = (h∗0 , h∗1 , . . . , h∗s ) appearing in the numerator of the Ehrhart series is called the h∗ -vector (or the δ-vector) of P. It is known that the socle degree s of the Ehrhart ring of P can be written as follows: (5.1) s = d + 1 − min{m ∈ Z>0 : m int(P) ∩ Zd 6= ∅}, where int(P) denotes the interior of P. Thus, in particular, s ≤ d. For more details on Ehrhart rings or h∗ -vectors, we refer [9, Part 2]. First, we supply examples of Ehrhart rings whose almost Gorensteinness can be guaranteed by Theorem 3.1. Let e1 , . . . , ed ∈ Zd be the standard basis for Rd , where each ei is the ith unit vector, and let conv(X) denote the convex hull of a set X ⊂ Rd . Example 5.1. Let P1 = conv({±e1 , ±e2 , ±e3 , e1 + e2 + 2e3 }) ⊂ R3 . Then P1 is a lattice polytope of dimension 3 and we see that k[P1 ] is standard graded and h∗ (P1 ) = (1, 4, 7, 1). Hence, by Theorem 3.1, k[P1 ] is almost Gorenstein, while this is not Gorenstein. Moreover, let P2 = conv({±e1 , . . . , ±e5 , e1 + · · · + e4 + 2e5 }) ⊂ R5 be a lattice polytope of dimension 5. Then we see that k[P2 ] is standard graded and h∗ (P2 ) = (1, 6, 16, 26, 6, 1). Hence, by Theorem 3.1 again, k[P2 ] is also almost Gorenstein but not Gorenstein. In general, let d = 2e+ 1 with e ≥ 1 and let Pe be the convex hull of {±e1 , . . . , ±ed , e1 + · · ·+ed−1 +2ed } ⊂ Rd . We compute h∗ (Pe ) for small e’s and the following show the results. e = 3 : h∗ (P3 ) = (1, 8, 29, 64, 99, 29, 8, 1), e = 4 : h∗ (P4 ) = (1, 10, 46, 130, 256, 382, 130, 46, 10, 1), e = 5 : h∗ (P5 ) = (1, 12, 67, 232, 562, 1024, 1486, 562, 232, 67, 12, 1), e = 6 : h∗ (P6 ) = (1, 14, 92, 378, 1093, 2380, 4096, 5812, 2380, 1093, 378, 92, 14, 1). The Ehrhart rings of these polytopes are standard graded and these are almost Gorenstein by Theorem 3.1. We expect that k[Pe ] is always standard graded and almost Gorenstein for every e, although it seems difficult to give a precise proof. Next, we provide other examples of almost Gorenstein Ehrhart rings. The examples which we will give are obtained from the lattice polytopes arising from finite partially ordered sets (posets, for short). Let P = {x1 , . . . , xn } be a poset with a partial order ≺ and let O(P ) = {(a1 , . . . , an ) ∈ Rn : ai ≥ aj if xi  xj in P, 0 ≤ ai ≤ 1 for i = 1, . . . , n}. This convex polytope O(P ) is called the order polytope of P . It is known that O(P ) is a lattice polytope and the Ehrhart ring k[O(P )] is often called the Hibi ring of P . It is known that: • dim O(P ) = ♯P ; • k[O(P )] is standard graded and an algebra with straightening laws on P ([7]); 9 • the socle degree of k[O(P )] is equal to ♯P − max{♯C : C is a chain in P }, where a chain is a totally ordered subset of P . For more detailed information on order polytopes, please consult [12], or on Hibi rings, please consult [4, 7, 8] and the references therein. We describe the h∗ -vector of O(P ) in terms of P . Let P = {x1 , . . . , xn } be a poset with a natural partial order ≺, i.e., if xi ≺ xj , then i < j. We say that a map σ : P → [n] from P to the n-elements chain order-preserving if x  y impliesσ(x) ≤ σ(y). We can  identify 1 ··· n an order-preserving map σ : P → [n] with a permutation ∈ Sn . σ −1 (1) · · · σ −1 (n) The set of all the permutations obtained in this way is denoted by Q(P ). For example, if P = {x1 , x2 , x3 , x4 } is a poset having a natural partial order x1 ≺ x3 , x2 ≺ x3 and x2 ≺ x4 , then Q(P ) = {1234,2134, 1243, 2143,  2413} ⊂ S4 . Here, we denote a1 a2 · · · an 1 2 ··· n ∈ Sn . Moreover, for π ∈ Sn , let d(π) = instead of the usual notation a1 a2 · · · an ♯{i ∈ {1, . . . , n − 1} : π(i) > π(i + 1)} and let D(π) = {i ∈ {1, . . . , n − 1} : π(i) > π(i + 1)}. (Clearly, d(π) = ♯D(π).) Proposition 5.2 (cf. [12, Theorem 4.5.14]). Let P = {x1 , . . . , xn } be a poset with a natural partial order and let h∗ (O(P ))(= h(k[O(P )])) = (h0 , h1 , . . . , hs ). Then hi = ♯{π ∈ Q(P ) : d(π) = i} for each i = 0, 1, . . . , s. Now, we will consider the following poset: For m ≥ 3, let Pm = {x1 , x2 , . . . , x2m−1 , x2m } be the poset with the natural partial order x1 ≺ x3 ≺ · · · ≺ x2m−1 , x2 ≺ x4 ≺ · · · ≺ x2m and x1 ≺ x2m . Figure 1 below is the Hasse diagram of Pm . x2m-1 x2m x2m-3 x2m-2 x3 x4 x1 x2 Figure 1. the poset Pm Theorem 5.3. Let Pm be as above. Then k[O(Pm )] is an almost Gorenstein homogeneous domain whose h-vector (h0 , h1 , . . . , hm ) satisfies hi = hm−i for i = 0, 2, 3, . . . , ⌊m/2⌋ and hm−1 = h1 + 1. Theorem 5.3 says that there is an almost Gorenstein homogeneous ring having a “different almost symmetry” h-vector. 10 5.1. The h-vector of Rm . Let Rm = k[O(Pm )]. Then we can compute by (5.1) that the socle degree of Rm is equal to m. First, for the proof of Theorem 5.3, let us observe the set Q(Pm ) in detail. Let S = {σ ∈ S2m : σ(1) < σ(3) < · · · < σ(2m − 1), σ(2) < σ(4) < · · · < σ(2m), σ(1) < σ(2m)} and let S −1 = {σ −1 : σ ∈ S}. Then S −1 = Q(Pm ). Let τ = 1325476 · · · (2m − 4)(2m − 1)(2m − 2)2m ∈ S2m . Then we see that τ ∈ S −1 . Let T = S −1 \ {τ } and let Ti = {π ∈ T : d(π) = i} for i = 0, 1, . . . , m. We construct a map ξi : Ti → Tm−i for each i = 0, 1, . . . , m as follows: Fix π ∈ Ti . • Let A = {x1 , x3 , . . . , x2m−1 }\{xπ(j) , xπ(j+1) : j ∈ D(π)} and B = {x2 , x4 , . . . , x2m }\ {xπ(j) , xπ(j+1) : j ∈ D(π)}. Since the parities of π(j) and π(j + 1) are different for each j ∈ D(π) and j ′ + 1 6∈ D(π) for each j ′ ∈ D(π), we obtain that ♯A = ♯B = m − i. Let p1 , p2 , . . . , pm−i (resp. q1 , q2 , . . . , qm−i ) be the positive integers with A = {xpj : 1 ≤ j ≤ m − i} (resp. B = {xqj : 1 ≤ j ≤ m − i}) such that p1 < p2 < · · · < pm−i (resp. q1 < q2 < · · · < qm−i ). • We construct the permutation π e = a1 a2 · · · a2m by defining each ai inductively as follows: Let a1 = 1 if p1 > 1 or let a1 = 2 if p1 = 1, and – for 1 ≤ ℓ < (p1 + q1 + 1)/2, let   a + 1, if aℓ ≤ min{p1 , q1 } − 2,   ℓ  p , if aℓ = q1 > p1 , 1 aℓ+1 =  q1 , if aℓ = p1 > q1 ,     aℓ + 2, otherwise; – for (pj−1 + qj−1 + 1)/2 ≤ ℓ < (pj + qj + 1)/2 with some j ∈ {2, . . . , m − i}, let aℓ+1 =   aℓ + 1,     pj−1 + 2,    q + 2, j−1  pj ,      q ,    j  aℓ + 2, if max{pj−1 , qj−1 } + 1 ≤ aℓ ≤ min{pj , qj } − 2, if aℓ ≤ pj−1 , pj−1 > qj−1 and aℓ + 2 = qj , if aℓ ≤ qj−1 , qj−1 > pj−1 and aℓ + 2 = pj , if aℓ = qj > pj , if aℓ = pj > qj , otherwise; – for ℓ ≥ (pm−i + qm−i + 1)/2, let ( aℓ + 1, if aℓ ≥ max{pm−i , qm−i } + 1, aℓ+1 = aℓ + 2, otherwise. See Example 5.4 below for this construction. • We define ξi (π) = π e. Example 5.4. Let m = 4 and consider π = 13246857. Then d(π) = 2 and D(π) = {2, 6}. Thus A = {x1 .x7 }, B = {x4 , x6 } and p1 = 1, p2 = 7, q1 = 4, q2 = 6. We construct 11 π e = a1 a2 · · · a8 as follows: a1 = 2 since p1 = 1, a2 = a1 + 2 = 4, a3 = p1 = 1, a4 = a3 + 2 = 3, a5 = a4 + 2 = 5, a6 = a5 + 2 = 7, a7 = q2 = 6 (since a6 = p2 > q2 ), a8 = a7 + 2 = 8. Actually, for π ∈ T2 , we have π e = 24135768 ∈ T4−2 . Lemma 5.5. For this construction, (a) π e ∈ S2m with d(e π ) = m − i; −1 e−1 (j) is order-preserving; (b) the map π : P → [2m] defined by π −1 (xj ) = π (c) ξi is bijective. Proof. (a) For (pj−1 + qj−1 + 1)/2 ≤ ℓ < (pj + qj + 1)/2 with some j ∈ {2, . . . , m − i}, by the definition of aℓ , we can observe that pj−1 ≤ aℓ ≤ pj when aℓ is odd or qj−1 ≤ aℓ ≤ qj when aℓ is even. Moreover, we can also observe that for (pj−1 + qj−1 + 1)/2 ≤ ℓ, ℓ′ < (pj + qj + 1)/2 with ℓ 6= ℓ′ , when the parities of aℓ and aℓ′ are equal, aℓ < aℓ′ if and only if ℓ < ℓ′ . Similar assertions also hold in the cases where ℓ < (p1 + q1 + 1)/2 and ℓ ≥ (pm−i + qm−i + 1)/2. Thus, a1 , a2 , . . . , a2m are all different integers with 1 ≤ aℓ ≤ 2m for each ℓ. Hence, π e should define a permutation, i.e., π e ∈ S2m . In addition, we also have D(e π ) = {(pj + qj − 1)/2 : j = 1, . . . , m − i}. In particular, d(e π ) = m − i. (b) As in (a) above, we know that when the parities of aℓ and aℓ′ are equal, aℓ < aℓ′ if and only if ℓ < ℓ′ . Moreover, one has π e−1 (aℓ ) = ℓ for each ℓ. On the other hand, we know that if aℓ = 1 and aℓ′ = 2m, then ℓ < ℓ′ . In fact, the situation aℓ = 1, aℓ′ = 2m and ℓ > ℓ′ may happen if (p1 , q1 ) = (1, 2m) and m − i = 1. However, this never happens because π 6= 1325476 · · · (2m − 4)(2m − 1)(2m − 2)2m = τ . Hence, the map π −1 : P → [2m] defined by π −1 (xaℓ ) = ℓ is order-preserving. (c) Since π e is uniquely determined by p1 , . . . , pm−i , q1 , . . . , qm−i , it is obvious that ξi is injective. By the injectivities of ξi : Ti → Tm−i and ξm−i : Tm−i → Ti for each i = 0, 1, . . . , m, we obtain the bijectivity of ξi for each i, as required.  5.2. The Cohen–Macaulay type of Rm . Next, let us estimate the Cohen–Macaulay type of Rm by considering its canonical ideal. Given a poset P , let P̂ = P ∪{0̂, 1̂} with 0̂ < x < 1̂ for every x ∈ P . A map v : P̂ → Z≥0 is called order-reversing (resp. strictly order-reversing) if v(x) ≤ v(y) (resp. v(x) < v(y)) for each x, y ∈ P̂ with x  y (resp. x ≻ y). Let S(P̂ ) (resp. T (P̂ )) denote the set of all order-reversing (all strictly order-reversing) maps v : P̂ → Z≥0 with v(1̂) = 0. It is shown in [7] that k[O(P )] has a k-basis consisting of the monomials which look like Y Xpv(p) , v ∈ S(P̂ ) Z v(0̂) p∈P and it is also shown there that the monomials which look like Y Xpv(p) , v ∈ T (P̂ ) Z v(0̂) p∈P 12 form a k-basis of the canonical ideal Ik[O(P )] ⊂ k[O(P )]. Let T0 (P̂ ) ⊂ T (P̂ ) denote the subset corresponding to the minimal set of generators of Ik[O(P )] . Note that k[O(P )] is Q v(p) standard graded by the grading deg(Z v(0̂) p∈P Xp ) = v(0̂). On the Cohen–Macaulay type of Rm , we see the following: Lemma 5.6. We have ♯T0 (Pc m ) ≥ m − 1, i.e., r(Rm ) = µ(IRm ) ≥ m − 1. Proof. For i = 1, . . . , m − 1, let vi : Pm → Z≥0 be the map defined by ( if j is odd, m + 1 − j+1 2 , vi (xj ) = j m + i − 2, if j is even for j = 1, . . . , 2m. Then each vi is a strictly order-reversing map. We will show that vi ∈ T0 (Pc m ) for each i = 1, . . . , m − 1. Assume that vi can be written c as a sum of v ∈ T (Pm ) and w ∈ S(Pc m ), i.e., vi (x) = v(x) + w(x) for each x ∈ P . Then we have vi (xj ) − v(xj ) = w(xj ) ≥ 0 for each j. Moreover, since 1̂ ≻ x2m−1 ≻ x2m−3 ≻ · · · ≻ x1 ≻ 0̂, v ∈ T (Pc m ) and v(1̂) = 0, we have v(x2q−1 ) ≥ m + 1 − q = vi (x2q−1 ), equivalently, vi (x2q−1 ) − v(x2q−1 ) ≤ 0 for each q = 1, 2, . . . , m. Hence, we obtain vi (xj ) = v(xj ) for each j = 1, 3, . . . , 2m − 1. On the other hand, if there is 1 ≤ r < m with v(x2r ) − v(x2r+2 ) ≥ 2, then we see that w(x2r+2 ) = vi (x2r+2 ) − v(x2r+2 ) = (vi (x2r+2 ) + 1) − (v(x2r+2 ) + 1) ≥ vi (x2r ) − (v(x2r ) − 1) > w(x2r ), a contradiction to w ∈ S(Pc m ). Hence, v(x2r ) − v(x2r+2 ) ≤ 1 for each 1 ≤ r < m, i.e., v(x2r ) − v(x2r+2 ) = 1 for each r because v ∈ T (Pc m ). Let v(x2m ) = α ∈ Z>0 . • Suppose that α > i. Then we have w(x2m ) = vi (x2m ) − v(x2m ) = i − α < 0, a contradiction. • Suppose that α < i. Then we have w(x2m ) > 0. However, as observed above, we also have w(x1 ) = vi (x1 ) − v(x1 ) = 0. Since x1 ≺ x2m in Pm , we should have w(x1 ) ≥ w(x2m ), a contradiction. Thus, v(x2m ) = i. By v(x2r ) − v(x2r+2 ) = 1 for each 1 ≤ r < m, we also have v(x2r ) = m + i − r. Therefore, v = vi and w = 0. This implies that vi ∈ T0 (Pc  m ), as required. 5.3. Proof of Theorem 5.3. We are now in the position to give a proof of Theorem 5.3. Work with the same notation as above. Let C = coker φ, where φ : Rm → IRm (−a) is an injection, and let (h0 , h1 , . . . , hm ) be the h-vector of Rm . By the above discussions and Lemma 5.5, there exists a bijection ξi between Ti and Tm−i . In particular, we have ♯Ti = ♯Tm−i . On the other hand, by Proposition 5.2, we have S hi = ♯{π ∈ S −1 : d(π) = i} for each i = 0, 1, . . . , m. Since we have S −1 = m i=0 Ti ∪ {τ } and d(τ ) = m − 1, we conclude that (h0 , h1 , . . . , hm ) satisfies that hi = hm−i for i = 0, 2, 3, . . . , ⌊m/2⌋ and hm−1 = h1 + 1. Therefore, by Proposition 2.4, we obtain that e(C) = m X ((hm + · · · + hm−j ) − (h0 + · · · + hj )) = m−2 X (hm−1 − h1 ) = m − 2. j=1 j=0 13 In addition, it follows from Proposition 2.3 and Lemma 5.6 that µ(C) = r(Rm ) − 1 ≥ m − 2. Hence, we see that e(C) − µ(C) ≤ 0. Since e(C) − µ(C) ≥ 0 is also satisfied by (2.1), we conclude that C satisfies e(C) = µ(C). Therefore, by Corollary 2.7, Rm is almost Gorenstein, as desired.  Example 5.7. Let Qm = {x1 , . . . , x2m } be the poset with the partial order x1 ≺ x3 ≺ · · · ≺ x2m−1 , x2 ≺ x4 ≺ · · · ≺ x2m , x1 ≺ x2m and x2 ≺ x2m−1 . By the similar discussions as above, we see that k[O(Qm )] is also almost Gorenstein with r(k[O(Qm )]) = 2m − 3. References [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] V. Barucci and R. Froberg, One-dimensional almost Gorenstein rings, J. Algebra 188 (1997), 418–442. W. Bruns and J. Herzog, “Cohen–Macaulay rings,” Cambridge University Press, 1993. D. Eisenbud, Linear sections of determinantal varieties, Amer. J. Math. 110 (1988), 541–575. V. Ene, J. Herzog, T. Hibi and S. S. Madani, Pseudo-Gorenstein and level Hibi rings, J. Algebra 431 (2015), 138–161. S. Goto, N. Matsuoka and T. T. Phuong, Almost Gorenstein rings, J. Algebra 379 (2013), 355–381. S. Goto, R. Takahashi and N. Taniguchi, Almost Gorenstein rings –Towards a theory of higher dimension–, J. Pure Appl. Algebra 219 (2015), 2666–2712. T. Hibi, Distributive lattices, affine semigroup rings and algebras with straightening laws, In:“Commutative Algebra and Combinatorics” (M. Nagata and H. Matsumura, Eds.), Adv. Stud. Pure Math. 11, North–Holland, Amsterdam, (1987), 93–109. T. Hibi, Level rings and algebras with straightening laws, J. Algebra 117 (1988), 343–362. T. Hibi, “Algebraic Combinatorics on Convex Polytopes,” Carslaw Publications, Glebe NSW, Australia, 1992. N. Matsuoka and S. Murai, Uniformly Cohen-Macaulay simplicial complexes, arXiv:1405.7438v1. K. Yanagawa, Castelnuovo’s Lemma and h-vectors of Cohen–Macaulay homogeneous domains, J. Pure and Appl. Algebra 105 (1995), 107–116. R. P. Stanley, “Enumerative Combinatorics, Volume 1,” Wadsworth & Brooks/Cole, Monterey, Calif., 1986. R. P. Stanley, Hilbert functions of Graded Algebras, Adv. Math. 28 (1978), 57–83. R.P. Stanley, On the Hilbert function of a graded Cohen-Macaulay domain, J. Pure Appl. Algebra 73 (1991), 307–314. Akihiro Higashitani, Department of Mathematics, Kyoto Sangyo University, Motoyama, Kamigamo, Kita-Ku, Kyoto, Japan, 603-8555 E-mail address: [email protected] 14
0math.AC
VLSI Computational Architectures for the Arithmetic Cosine Transform Nilanka Rajapaksha Arjuna Madanayake∗ Renato J. Cintra† Jithra Adikari‡ Vassil S. Dimitrov§ arXiv:1710.11200v1 [cs.AR] 30 Oct 2017 Abstract The discrete cosine transform (DCT) is a widely-used and important signal processing tool employed in a plethora of applications. Typical fast algorithms for nearly-exact computation of DCT require floating point arithmetic, are multiplier intensive, and accumulate round-off errors. Recently proposed fast algorithm arithmetic cosine transform (ACT) calculates the DCT exactly using only additions and integer constant multiplications, with very low area complexity, for null mean input sequences. The ACT can also be computed non-exactly for any input sequence, with low area complexity and low power consumption, utilizing the novel architecture described. However, as a trade-off, the ACT algorithm requires 10 non-uniformly sampled data points to calculate the 8-point DCT. This requirement can easily be satisfied for applications dealing with spatial signals such as image sensors and biomedical sensor arrays, by placing sensor elements in a non-uniform grid. In this work, a hardware architecture for the computation of the null mean ACT is proposed, followed by a novel architectures that extend the ACT for non-null mean signals. All circuits are physically implemented and tested using the Xilinx XC6VLX240T FPGA device and synthesized for 45 nm TSMC standard-cell library for performance assessment. Keywords Discrete cosine transform, Arithmetic cosine transform, fast algorithms, VLSI 1 sults. A prominent example is the arithmetic Fourier transform (AFT) proposed by Reed et al. [17, 18]. The AFT allows multiplication-free calculation of Fourier coefficients using number-theoretic methods and non-uniformly sampled inputs. A feature of the AFT is its suitability for parallel implementation [17, 18]. Introduction The discrete cosine transform (DCT) was first proposed by Ahmed et al. in 1974 and published in IEEE Transactions on Computers [1]. It has since attracted much attention in the computer engineering community [2, 3, 4, 5]. In particular, the 8-point DCT and its variants, in the form of fast algorithms, has been widely adopted in several image and video coding standards [6] such as JPEG, MPEG-1/2, and H.261-5 [7]. Some applications which use image and video compression include automatic surveillance [8], geospatial remote sensing [9], traffic cameras [10], homeland security [11], satellite based imaging [12], unmanned aerial vehicles [13], automotive [14], multimedia wireless sensor networks [15], the solution of partial differential equations [16] etc. A particular class of fast algorithms is constituted by the arithmetic transforms. An arithmetic transform is an algorithm for low-complexity computation of a given trigonometric transform, based on number-theoretical re- Recently, an arithmetic transform method for the computation of the DCT, called the arithmetic cosine transform (ACT) was proposed in [19]. The ACT can provide a multiplication-free framework and leads to the exact computation of the DCT—provided that the input signal has null-mean and is non-uniformly sampled [19]. The computational gains of the ACT are only possible when its prescribed non-uniformly sampled data is available. Classically the required non-uniform samples are derived by means of interpolation over uniformly sampled data [19]. Such interpolation implies a computational overhead. Another aspect of the ACT is that, for arbitrary input signal, it requires the computation of the input signal mean value [19]. Usually, the mean value is computed from uniformly sampled data [19]. In fact, this dependence on uniformly sampled data has been precluding the implementation of the ACT based exclusively on non-uniformly sampled data. ∗ N. Rajapaksha and A. Madanayake are with the Department of Electrical and Computer Engineering, The University of Akron, Akron, OH, USA. E-mail: {ntr3,arjuna}@uakron.edu † R. J. Cintra is with the Signal Processing Group, Departamento de Estatı́stica, Universidade Federal de Pernambuco, Recife, PE, Brazil. E-mail: [email protected] ‡ J. Adikari is with the Elliptic Technologies Inc., Ottawa, ON, Canada. E-mail: [email protected] § V. S. Dimitrov are with the Department of Electrical and Computer Engineering, University of Calgary, Calgary, AB, Canada. Email: [email protected] On the other hand, the requirement for non-uniform samples can be satisfied when spatial input signals are considered. In spatial signal processing, non-uniformly sampled signals can be directly obtained, without interpolation using a non-uniform placement of sensors [20, 7]. This moti1 follows. First, let the ACT averages Sk , k = 1, 2, . . . , N − 1, of the non-uniform sampled inputs be defined as [19]: vates the search for architectures which could solely rely on non-uniformly sampled inputs. In this paper we address two main problems: (i) the proposition of a method to obtain the mean value of a given input signal from its non-uniform samples as prescribed by the ACT and (ii) the introduction of efficient architectures for calculation of the 8-point DCT based on the ACT, operating on non-uniformly sampled data only. This leads to designs with low computational complexity. Having ACT architectures that compute 1-D DCT can be utilized as a building block to implement such 2-D DCT architectures that take inputs from sensors placed on a non uniform grid. Two architectures based on the ACT are sought, being referred as Architectures I and II. Architecture I provides the hardware implementation of the ACT algorithm proposed in [19], and calculates the DCT with exact precision for null mean 8-point sequences. The proposed Architecture I is designed to require only additions and multiplications by integers. Thus, no source of intrinsic computation error is present, such as rounding-off and truncation. Therefore, area consuming hardware multipliers are not necessary. We propose Architecture II that implements the novel modified ACT algorithm for DCT calculation of arbitrary, nonnull-mean input signals, using 11 hardware multiplications. Both architectures require only non-uniformly sampled inputs. This paper unfolds as follows. In Section 2, the fundamental mathematical operations of the ACT are briefly described. Section 3 details how to compute the mean value from non-uniformly sampled data and provides a matrix formalism for the 8-point ACT. In Section 4 the proposed architectures are detailed. Section 5 brings the implementation results as well as comparisons with competing structures. Conclusions and final remarks are furnished in Section 6. 2 Sk , Vk = (2) r ⌊ Nk−1 ⌋ N X µ(l) · Skl , 2 l=1 k = 1, 2, . . . , N − 1, (3) where µ(·) is the Möbius function [17, 18, 19]. The derivation of the ACT [19] utilizes the Möbius inversion formula. Because the Möbius function values are limited to {−1, 0, +1}, (3) results in no additional multiplicative complexity. In practice, input sequences are not always null mean, therefore a correction term is necessary to (3). In [19] an expression suitable for the non-null mean signals is given as: Vk = r r  ⌊ Nk−1 ⌋  N X N N −1 v̄ · M µ(l) · Skl − , (4) 2 2 k l=1 Pn where M(n) , m=1 µ(m) is the Mertens function [19] and v̄ is the mean value of the uniformly sampled input sequence. 3 Proposed Algorithm with Only Non-uniformly Sampled Inputs 3.1 Mean Value Calculation Although (4) leads to the DCT coefficients of non-null mean input signals, it requires the knowledge of quantity v̄, which could be calculated straightforwardly from the N uniform samples in v. Since uniform samples are not available, v̄ should be directly calculated from non-uniform samples. The non-uniform samples are related to the uniform samples according to the interpolation scheme given by [19]: The usual input sequence to the DCT can be considered as uniform samples of a continuous input signal v(t). −1 This results in an N -point column vector v = {vn }N n=0 which has its DCT denoted by the N -point column vec−1 tor V = {Vk }N k=0 . To calculate V, the ACT algorithm requires non-uniformly sampled points of the continuous input signal v(t) [19]. These points are given by vr = N −1 X n=0 wn (r) · vn , r ∈ R, (5) where wn (r) is the interpolation weight function expressed by  π  1 DN −1 (n + r + 1) + wn (r) = 2N N  π (n − r) , n = 0, 1, . . . , N − 1, DN −1 N 1 2mN − , k 2 where k = 1, 2, . . . , N − 1, and m = 0, 1, . . . , k − 1 [19]. We can define the set R as: R = {Set of all values of r} k = 1, 2, . . . N − 1. The ACT averages can be employed to computed DCT coefficients according to [19]: The arithmetic cosine transform r= k−1 1 X v N 1, k m=0 2m k − 2 (1) It is important to notice that the values of r are not necessarily integer. In fact, they are expected to be fractional. If the signal of interest has zero mean, then the ACT algorithm can be used to calculate the DCT coefficients as and DN (x) = 2 sin((N + 1/2)x) sin(x/2) denotes the Dirichlet kernel [21, p. 312]. Here, the set R is where  defined in (1). More compactly, (5) can be put in matrix form. Indeed, we can write vr = W · v, where vr = [vr ]r∈R   is a column vector containing the required non-uniform   samples, and W = {wn (r)}, n = 0, 1, . . . , N − 1, r ∈ R, Mo =   is the implied interpolation matrix.   For the particular case of the 8-point ACT, the follow ing 10 non-uniform sampling instants are required [19]: r∈R=  1 25 13 27 7 57 29 59 89 15 − , , , , , , , , , 2 14 6 10 2 14 6 10 14 2  . (6) 1 0  0  D1 =  0 0  0 0 v = W+ · vr . Consequently, the mean value of v can be determined exclusively from the non-uniform samples, according to: 1 w · vr , 8  −1 −1 0 −1 1 −1 1 0 −1 0 −1 0   0 1 0 0 −1 0   0 0 1 0 0 0  , 0 0 0 1 0 0   0 0 0 0 1 0  0 0 0 0 0 1  Moreover, matrix W is found to possess full column rank. Thus, its Moore-Penrose pseudo-inverse W+ is the left inverse of W [22, p. 93]. Therefore, we obtain v̄ = 1 0 0 0 0 0 0  1 1  1  S= 1 1  1 1 (7) where w is the 8-point vector of the sums of each column of W+ . Scaled vector w/8 has constant elements given by: 0 0 0 0 0 0 2 0 0 0 1 2 1 3 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 1 4 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 2 0 0 0 0 1 5 0 0 0 0 2 0 0 2 0 0 0 0 0 0 1 6 0 0 0 0 0 2 0 0  0 0  0  0 , 0  0 1 7 0 0 0 0 0 0 2  0 1  0  1 , 0  1 0 and Me is the implied matrix by the Mertens function in (4). This last matrix is furnished by  1 0 0 0 0 0 0 2 0 1 0 0 0 0 0  4   0 0 0 0 0 0 0    1 0 0 0  Me =   · 17 , 0 0 0 − 4  0 0 0 0 − 1 0 0 4   1 0 0 0 0 0 −4 0  0 0 0 0 0 0 − 14  0.131763492716950  0.498388117552161   −0.313306526814540    0.018837637958148   1 ⊤  0.389746948996966  w = −0.178465262210960 , 8    0.166302458810496    0.269801852271683   −0.131541981375149 0.148473262094246  where 17 is the 7×7 matrix of ones. In (8), matrix D1 and S are related to (2). Matrix Mo contains the values of the Möbius functions as required in (3). The second term in the right-hand side of (8) ac3.2 Matrix Factorization of ACT counts for the Mertens functions and the mean value calcuIn view of (2) and (7), (4) can be interpreted as the sought lation as required in (4) and (7). relation between V and vr . Thus, we can consider a transformation matrix T relating these two vectors. Notice 4 VLSI Architectures that T is not a square matrix. Since k = 1, 2, . . . , N − 1, the size of T is (N − 1) × |R|, where |R| is the number of In this section, above discussed methods are employed to elements of R. This transformation matrix returns all the furnish two novel low complexity architectures, which take DCT components, except the zeroth one, according to: only non-uniformly sampled inputs. Integer multiplications, which are exact in nature, are realized using simple ⊤  shift-add structures. The designs are fully pipelined by juV1 V2 · · · VN −1 = T · vr . dicious insertion of registers at internal nodes, leading to √ low critical path delay at the cost of latency. Notice that V0 = N · v̄. were the superscript ⊤ denotes the transposition operation. For N = 8, matrix T has size 7×10 and admits the following matrix factorization: T = 2 · Mo · D1 · S + Me · W+ , 4.1 Architecture I The ACT expressions for null mean signals in (2) and (3) can be implemented for N = 8 as shown in Fig. 1(a). (8) 3 Table 2: Fixed point word-length increase ∆L at each quantization point of the ACT signal flow graph. Fixed point word-length is L + ∆L Architecture I Architecture II Points ∆L Points ∆L 1–10 0 36–55 0 11–18 2 56 1 We refer to this design as Architecture I. The 8-point null 57, 59, 61, 19–22, 24 3 13 mean ACT block admits the 10 non-uniformly sampled in62 puts corresponding to (6). Constant multiplications by two 23 1 58 11 are implemented as left-shift operations; and the fractional 25, 26, 31 10 60 14 constant multipliers 1/2, 1/3, 1/4, . . . are converted to inte27, 32, 34 12 63–66 12 gers by scaling them by the least common multiple of their 28–30 11 denominators: 420. The integer constant multipliers can 33, 35 13 be implemented as Booth encoded shift-and-add structures making the architecture multiplier p free, and the outputs of of ∆L are listed in Table 2 for both proposed architectures. the block are scaled by 420 · 2/N = 210. This archi- The referred quantization points are shown in Fig. 1 and tecture is useful in applications that have null mean input Fig. 2. The number of fractional bits are maintained consequences, and can be implemented with very low compu- stant throughout the design and is equal to L − 1. tational and area complexity. Accuracy of the results from Architectures I and II were Table 1: Computational complexity of proposed Architecture I and Architecture II. Architecture I Architecture II Constant 0 11 multipliers Two-input Adders 36 54 4.2 tested with varying values of L by using average percentage error and peak signal to noise ratio (PSNR) as figures of merit. Adopted figures of merit employed the DCT coefficients calculated from the floating point implementation of the DCT available in Matlab as reference. Results given in Table 3 are taken from the simulation of Architectures I and II using 104 random input signals. The reduction of the input word-length L degrades the results furnished by the considered figures of merit. However, for small wordlengths, the errors incurred are tolerable for most applications. Table 4 shows the resource utilization, power consumption and operational frequency on the Xilinx Virtex-6 XC6VLX240T FPGA device for input fixed point wordlengths (L) 8 and 12. Information about the Xilinx FPGA resources that are listed in Table 4 including slices, slice FFs and 4-input look-up tables (LUTs) can be found in the device datasheet. Architecture I is multiplier-free and possesses the lower complexity, but it is only suitable for null mean signals. To remove the dependence of power consumption to operating frequency the normalized power metric (dynamic power normalized to operating frequency) is given in Table 4. The total power consumption in the FPGA is dominated by the static power since both architectures only occupied roughly 1% of the available area. Architecture II The proposed method in Section 3 for the computation of v̄ from the non-uniformly sampled 10-point signal can be implemented as shown in Fig. 1(b). We will refer to it as the mean calculation block, which computes (7). The correction term associated to the Mertens function required in (4) is shown in Fig. 2(a). A combination of (i) this particular block, (ii) the Architecture I block, and (iii) the mean calculation block yields the proposed Architecture II as shown in Fig. 2(b). Note that calculation of the DCT coefficients using the null mean ACT block can also be achieved by subtracting the mean v̄ from its inputs. However, Architecture II has a lower computational complexity when compared to such alternative. Computation complexity of both Architecture I and Architecture II are listed in Table 1 in terms of constant multipliers and two-input adders. Integer constant multiplications are implemented as shift-and-add structures, therefore are not counted as multipliers. Note that the adder count also include the adders required for the Booth encoded structures. 5 5.1 Implementation and Results FPGA Implementation 5.2 We implemented both architectures described in the previous section. These architectures were tested on Xilinx Virtex-6 XC6VLX240T FPGA using the stepped hardware co-simulation feature in ML605 evaluation platform. They were also fully pipelined to achieve the maximum throughput. Word-length is L at the inputs, which are assumed to be in the range [−1, 1]. Throughout the fixed point implementation the word-length increases to avoid overflow. Depending on the particular quantization point, the actual allocated word-length is given by L + ∆L, where the values ASIC Synthesis Results The proposed architecture Architecture I and II are synthesized for application specific integrated circuits (ASIC) using the Cadence RTL Compiler for 45 nm technology. The freePDK45 standard-cell library is used in synthesis with optimization goal set to maximize the speed. Our synthesis was performed at operating voltage of 1.1 V. The area, power, operational frequency, and normalized power metric (dynamic power normalized to operating frequency and square of the supply voltage) for the ASIC synthesis are 4 (a) Architecture I (b) Mean calculation block Figure 1: (a) Null mean ACT and (b) mean calculation block. (a) Mertens correction block (b) Non-null mean ACT Figure 2: Architecture II: Non-null mean DCT calculation using the Mertens correction block. 5 Table 3: Average percentage error and average peak signal to noise ratio (PSNR) of ACT implementations with fixed point input word-length L, when tested with 10,000 input vectors Architecture I Architecture II L % error PSNR (dB) % error PSNR (dB) 8 4.594 × 10−1 50.3 2.262 × 10−1 38.8 12 1.977 × 10−2 74.3 2.149 × 10−1 63.0 16 −1.840 × 10−3 98.4 −1.550 × 10−2 87.1 20 2.943 × 10−4 122.4 2.565 × 10−3 110.8 24 −1.001 × 10−5 145.6 9.462 × 10−6 135.4 −6 28 1.167 × 10 170.6 3.137 × 10−6 159.4 32 −2.274 × 10−8 194.7 3.207 × 10−7 183.4 Table 4: Speed of operation resource utilization and power consumption of the XC6VLX240T FPGA device used for input fixed point word-lengths L and for Architectures I and II Fixed Dyn. Norm. point Architecture Slice Slice Op. freq. Slices power power wordtested FF LUTs (MHz) (W) (W/MHz) length (L) 930 756 Architecture 8 263 (1%) 1.37 500 2.74 × 10−3 (1%) (1%) I 1205 1019 12 329 (1%) 1.16 333.33 3.49 × 10−3 (1%) (1%) 1276 1386 Architecture 8 443 (1%) 0.54 166.66 3.22 × 10−3 (1%) (1%) II 1678 1639 12 495 (1%) 0.53 133.33 3.97 × 10−3 (1%) (3%) presented in Table 5. Table 6 shows the comparison of results between proposed ACT Architectures I and II and other published 8-point DCT implementations. Ideally, a fair comparison requires all implementations to be of the same process, operating frequency, and supply voltage. However, the published literature contains varying technology and operational conditions. Hence in Table 6 a normalized power consumption value is given, where the power consumption is normalized to the corresponding operational frequency and square of supply voltage. From the normalized power consumption given in Table 6 it’s apparent that the proposed architectures consume lower power than architectures in [23],[24] and [25]. We emphasize that the proposed Architecture I has the distinct advantage of having exact computation. Thus approximate DCT methods as suggested in [26, 27] were not taken into consideration for comparison purposes. 6 to assess the measured results. Results show that even for lower fixed point word-lengths, the implementations lead to acceptable margins of error. The resource utilization for various fixed point implementations indicate a trade-off between accuracy and device resources (chip area, speed, and power). It is the first step towards new research on low power and low complexity computation of the DCT by means of the recently proposed ACT. References [1] N. Ahmed, T. Natarajan, and K. R. Rao, “Discrete cosine transform,” Computers, IEEE Transactions on, vol. 100, no. 1, pp. 90–93, 1974. [2] C. Chakrabarti and J. JáJá, “Systolic architectures for the computation of the discrete Hartley and the discrete cosine transforms based on prime factor decomposition,” Computers, IEEE Transactions on, vol. 39, no. 11, pp. 1359–1368, 1990. Conclusions [3] F. A. Kamangar and K. R. Rao, “Fast algorithms for the 2-D discrete cosine transform,” Computers, IEEE Transactions on, vol. 100, no. 9, pp. 899–906, 1982. The ACT algorithm is suitable for calculating the 8-point DCT coefficients exactly using only adders and integer constant multiplications, also with low computational complexity. ACT architectures for null mean inputs as well as for non-null mean inputs are proposed, implemented and tested on Xilinx Virtex-6 XC6VLX240T FPGA. The average percentage error and PSNR were adopted as figures of merit [4] H. Kitajima, “A symmetric cosine transform,” Computers, IEEE Transactions on, vol. 100, no. 4, pp. 317–323, 1980. [5] S. Yu and E. Swartziander Jr, “DCT implementation with distributed arithmetic,” Computers, IEEE Transactions on, vol. 50, no. 9, pp. 985–991, 2001. 6 Table 5: Speed of operation, critical path delay, power consumption and area utilization in ASIC synthesis results for fixed point word-lengths L for Architecture I (45 nm technology) Fixed Norm. point Static Dynamic Total Op. Architecture Area Freq. wordpower power power Freq. Synthesized (µm2 ) (mW length (mW) (mW) (mW) (GHz) /GHz·V2 ) (L) 8 39007.27 0.27 67.31 67.59 1.11 50.12 Architecture I 12 53961.52 0.37 90.32 90.70 1.11 67.25 Architecture 8 65314.36 0.46 60.34 60.80 0.625 79.78 II 12 96087.77 0.63 79.29 79.92 0.588 111.45 Table 6: Comparison of the proposed implementation with published DCT implementations. Some implementations are 2-D but since they are implemented with 1-D DCT module with row column decomposition, results can be taken that can be compared with the proposed architectures. Shams et al. [28] Gosh et al. [24] Livramento et al. [25] 1D/2D DCT 2D but 1D results available 1D 2D but 1D results available Replicated and measured results by authors No No Precision Non-exact Method Gong et al. [23] Proposed architectures Arch. I Arch. I Arch. II Arch. II 2D but 1D results available 1D 1D 1D 1D No No Yes Yes Yes Yes Non-exact Non-exact Non-exact Exact Exact Nonexact Nonexact Vector matrix DCT core New distributed arithmetic based DCT Coefficient arithmetic based DCT LLM algorithm ACT, null mean ACT, null mean ACT, Mertens function ACT, Mertens function Multipliers 8 0 0 11 0 0 11 11 Input word-length 12 9 9 8 8 12 8 12 1.11 1.11 0.625 0.588 8.88 8.88 5.00 4.70 Operating frequency (GHz) 0.125 (2D) 1.5 0.05 (2D) 0.00489 (2D) Pixel rate (×109 s−1 ) 0.125 12 0.4 1.792 Power consumption (mW) N/A 210 12.45 (1D) 6.08 (2D) Normalized power consumption (mW/GHz·V2 ) N/A 12.86 110.67 114.17 50.11 67.25 79.79 111.44 67.31 ‡ 90.32 ‡ 60.34 ‡ 79.29 Gate count 30290 N/A N/A N/A 11491 16478 17673 25197 Implementation technology 0.25 µm CMOS 0.35 µm CMOS 0.12 µm CMOS 0.35 µm CMOS 45 nm CMOS 45 nm CMOS 45 nm CMOS 45 nm CMOS Supply voltage (V) 2.5 3.3 1.5 3.3 1.1 1.1 1.1 1.1 [‡] Dynamic power. 7 ‡ use of the Möbius inversion formula,” IEEE Transactions on Acoustics, Speech and Signal Processing, vol. ASSP-38, no. 3, pp. 458–470, Mar. 1990. [6] V. Britanak, P. Yip, and K. R. Rao, Discrete cosine and sine transforms. Amsterdam: Academic Press, 2007. [7] N. Roma and L. Sousa, “Efficient hybrid DCT-domain algorithm for video spatial downscaling,” EURASIP Journal on Advances in Signal Processing, vol. 2007, no. 2, pp. 30–30, 2007. [18] I. S. Reed, M. T. Shih, T. K. Truong, E. Hendon, and D. W. Tufts, “A VLSI architecture for simplified arithmetic Fourier transform algorithm,” IEEE Transactions on Signal Processing, vol. 40, no. 5, pp. 1122–1133, May 1992. [8] H. Lin and W. Chang, “High dynamic range imaging for stereoscopic scene representation,” in Proceedings of the 16th IEEE International Conference on Image Processing (ICIP), Nov. 2009, pp. 4305–4308. [19] R. J. Cintra and V. S. Dimitrov, “The arithmetic cosine transform: Exact and approximate algorithms,” IEEE Transactions on Signal Processing, vol. 58, no. 6, pp. 3076– 3085, Jun. 2010. [9] E. Magli and D. Taubman, “Image compression practices and standards for geospatial information systems,” in Proceedings of the 2003 IEEE International Geoscience and Remote Sensing Symposium, vol. 1, Jul. 2003, pp. 654–656. [20] E. J. Tan, Z. Ignjatovic, and M. F. Bocko, “A CMOS image sensor with focal plane discrete cosine transform computation,” in Proceedings of the IEEE International Symposium on Circuits and Systems, May 2007, pp. 2395–2398. [21] S. G. Krantz, Real Analysis and Foundations. Boca Raton, FL: Chapman & Hall/CRC, 2005. [10] M. Bramberger, J. Brunner, B. Rinner, and H. Schwabach, “Real-time video analysis on an embedded smart camera for traffic surveillance,” in Proceedings of the 10th IEEE RealTime and Embedded Technology and Applications Symposium, May 2004, pp. 174–181. [22] I. C. F. Ipsen, Numerical Matrix Analysis: Linear Systems and Least Squares. Philadelphia, PA: SIAM, 2009. [11] C. F. Chiasserini and E. Magli, “Energy consumption and image quality in wireless video-surveillance networks,” in Proceedings of the 13th IEEE International Symposium on Personal, Indoor and Mobile Radio Communications, vol. 5, Sep. 2002, pp. 2357–2361. [23] D. Gong, Y. He, and Z. Cao, “New cost-effective VLSI implementation of a 2-D discrete cosine transform and its inverse,” IEEE Transactions on Circuits and Systems for Video Technology, vol. 14, no. 4, pp. 405–415, Apr. 2004. [24] S. Ghosh, S. Venigalla, and M. Bayoumi, “Design and implementaion of a 2D-DCT architecture using coefficient distributed arithmetic [implementaion read implementation],” in Proceedings. IEEE Computer Society Annual Symposium on VLSI, May 2005, pp. 162–166. [12] T. Tada, K. Cho, H. Shimoda, T. Sakata, and S. Sobue, “An evaluation of JPEG compression for on-line satellite images transmission,” in Proceedings of the International Geoscience and Remote Sensing Symposium (IGARSS), Aug. 1993, pp. 1515–1518. [13] B. Bennett, C. Dee, and C. Meyer, “Emerging methodologies in encoding airborne sensor video and metadata,” in Proceedings of the 2009 IEEE Military Communications Conference, Oct. 2009, pp. 1–6. [25] V. S. Livramento, B. G. Moraes, B. A. Machado, and J. L. Guntzel, “An energy-efficient 8×8 2-D DCT VLSI architecture for battery-powered portable devices,” in IEEE International Symposium on Circuits and Systems (ISCAS), 2011, pp. 587–590. [14] S. Marsi, G. Impoco, A. Ukovich, S. Carrato, and G. Ramponi, “Video enhancement and dynamic range control of HDR sequences for automotive applications,” EURASIP Journal on Advances in Signal Processing, vol. 2007, p. MISSING PAGES, 2007. [26] J. Liang and T. D. Tran, “Fast multiplierless approximations of the DCT with the lifting scheme,” IEEE Transactions on Signal Processing, vol. 49, no. 12, pp. 3032–3044, Dec. 2001. [15] I. F. Akyildiz, T. Melodia, and K. R. Chowdhury, “A survey on wireless multimedia sensor networks,” Computer Networks, vol. 51, no. 4, pp. 921–960, 2007. [27] T. D. Tran, “The binDCT: fast multiplierless approximation of the DCT,” IEEE Signal Processing Letters, vol. 7, no. 6, pp. 141–144, Jun. 2000. [16] J. G. Proakis and D. G. Manolakis, Digital signal processing. Upper Saddle River, NJ: Pearson Prentice-Hall, 2007. [28] A. Shams and M. Bayoumi, “A 108 Gbps, 1.5 GHz 1D-DCT architecture,” in Proceedings. IEEE International Conference on Application-Specific Systems, Architectures, and Processors, 2000, pp. 163–172. [17] I. S. Reed, D. W. Tufts, X. Yu, T. K. Truong, M. T. Shih, and X. Yin, “Fourier analysis and signal processing by 8
8cs.DS
arXiv:1711.06241v1 [cs.IT] 16 Nov 2017 Deceptiveness of internet data for disease surveillance Reid Priedhorsky*,§ Dave Osthus* Ashlynn R. Daughton*,† Kelly R. Moran* Aron Culotta‡ * Los Alamos National Laboratory University of Colorado, Boulder ‡ Illinois Institute of Technology § corresponding author: [email protected] † November 16, 2017 / LA-UR 17-24564 Abstract Quantifying how many people are or will be sick, and where, is a critical ingredient in reducing the burden of disease because it helps the public health system plan and implement effective outbreak response. This process of disease surveillance is currently based on data gathering using clinical and laboratory methods; this distributed human contact and resulting bureaucratic data aggregation yield expensive procedures that lag real time by weeks or months. The promise of new surveillance approaches using internet data, such as web event logs or social media messages, is to achieve the same goal but faster and cheaper. However, prior work in this area lacks a rigorous model of information flow, making it difficult to assess the reliability of both specific approaches and the body of work as a whole. We model disease surveillance as a Shannon communication. This new framework lets any two disease surveillance approaches be compared using a unified vocabulary and conceptual model. Using it, we describe and compare the deficiencies suffered by traditional and internet-based surveillance, introduce a new risk metric called deceptiveness, and offer mitigations for some of these deficiencies. This framework also makes the rich tools of information theory applicable to disease surveillance. This better understanding will improve the decision-making of public health practitioners by helping to leverage internet-based surveillance in a way complementary to the strengths of traditional surveillance. 1 1 Introduction Despite advances in medicine and public health, infectious disease still causes substantial morbidity and mortality [25]. Disease surveillance provides the data required to combat disease by identifying new outbreaks, monitoring ongoing outbreaks, and forecasting future outbreaks [19]. However, traditional surveillance relies on in-person data gathering for clinical evaluations and laboratory tests, making it costly, difficult, and slow to cover the necessary large geographic areas and population. Disease surveillance using internet data promises to reach the same goals faster and at lower cost. This promise is based on a two-part conjecture: that people leave traces of their own and others’ health status online, and that these traces can be extracted and used to accurately estimate disease incidence. Data sources include search queries [15], social media messages [7], reference work usage [12], and blog posts [6].1 The first half of this conjecture is compelling, but the second is more elusive. For example, Google Flu Trends, a web system based on [15], opened to great fanfare but proved to be inaccurate in many situations [23] and shut down in the summer of 2015 [10]. The field has also encountered difficulty answering criticisms from the public health community on how it deals with demographic bias, media coverage of outbreaks, high noise levels, and other issues. Because the field’s successes are based on observational studies in specific contexts, it is hard to know how robust or generalizable these approaches are or what unsuccessful alternatives remain unpublished. This paper argues that a necessary part of the solution is a mathematical model of the disease surveillance information flow. We offer such a model, describing both internet-based and traditional disease surveillance as a Shannon communication [34] (Figure 1). This lets us discuss the two approaches with unified vocabulary and mathematics. In particular, we show that they face similar challenges, but these challenges manifest and are addressed differently. For example, both face concept drift [11]: Google search volume is sometimes, but not always, predictive of influenza incidence (Figure 2), and traditional estimates of autism spectrum disorder are impacted by changing interpretations of changing case definitions [37] (Figure 3). Using this model, we introduce a new quality metric, deceptiveness, in order to quantify how much a surveillance system is giving the right answer for the wrong reasons, i.e., to put a number on “past performance is no guarantee of future results”. For example, basketball-related web searches correlate with some influenza seasons, and are then predictive of flu, but should not be included in flu estimation models because this correlation is a coincidence [15]. This approach lets us do three things. First, we show that neither approach 1 One review of this body of research is our previous work [29]. 2 INFORMATION SOURCE population at risk ENCODER DECODER care provider assignment internet system and users weighted average statistical model DESTINATION public health leadership + MESSAGE w disease incidence SIGNAL systematic δ random ε U ŵ incidence estimate RECEIVED MESSAGE NOISE RECEIVED SIGNAL incidence by sub-population some internet activity traces X diagnoses by sub-population all internet activity traces NOISE SOURCE health care system internet system and users Figure 1: Schematic diagram of disease surveillance as a Shannon communication, patterned after Figure 1 of [34] and using the notation in this paper. This formulation lets one compare any two disease surveillance approaches with unified vocabulary and apply the rich tools of information theory. is perfect nor has fully addressed its challenges. Second, we show that the two approaches are complementary; internet-based disease surveillance can add value to but not replace traditional surveillance. Finally, we identify specific improvements that internet-based surveillance can make, in order to become a trusted complement, and show how such improvements can be quantified. In the body of this paper, we first describe a general mapping of disease surveillance to the components of Shannon communication, along with its challenges and evaluation metrics in terms of this mapping. We then cover the same three aspects of traditional and internet-based surveillance more specifically. We close with a future research agenda in light of this description. 2 Disease surveillance in general Many aspects of traditional and internet-based disease surveillance are similar. This section lays out the bulk of our model in common and highlights the aspects that will be treated specifically later. We first describe disease surveillance as a Shannon communication, then use these concepts to discuss the challenges of surveillance and metrics to assess performance. 3 Google searches for flu vs. U.S. ILI ILI % 6 ILI search 4 2 0 2013-Jul 2014-Jan 2014-Jul 2015-Jan Figure 2: Google Trends U.S. search volume for query string “flu” fitted to U.S. influenza-like-illness (ILI) data. The plot shows that search volume fails to track ILI early in the season, perhaps due to vaccination publicity schedules, demonstrating concept drift. We call this query deceptive during these periods. Parent-diagnosed autism spectrum disorder definition 3 prevalence 2% definition 2 case definition 1 1% 0% 1997 2000 2005 year 2011 2014 Figure 3: Prevalence of autism spectrum disorder as reported by parents has increased by a factor of 30 between 1997 and 2015 in a survey-based traditional surveillance approach [26, 37], but actual prevalence probably has not [37]. This plot shows drift both gradually as parental interpretations of diagnostic criteria change over time and suddenly when diagnostic criteria were revised. 4 information source message 25 people in population 5 infected this week (20%)                       noise source encoder received message decoder 2/6 are diagnosed (33%) 10 use Clinic A 1 infected (10%) 6 visit clinic 15 use Clinic B 4 infected (27%) 8 visit clinic  Incidence estimate is weighted mean: 2/6 × 10/25 + 3/8 × 15/25 = 36% 3/8 are diagnosed (38%)    received signal signal        Wikipedia article Influenza " "" "" " 3 visits from infection observations 6 visits total 3 visits for other reasons Update coefficients for next time Article coefficients trained on previous reference data 𝛽₃ = 0.023 Influenza 𝛽₂ = 0.016 Fever 𝛽₁ = 0.000 Basketball 𝛽₀ = 0.090 intercept destination # Wikipedia article Fever × """ " "" "" 3 visits from infection observations 7 visits total 4 visits for other reasons Apply statistical model 6𝛽₃ + 7𝛽₂ + 5𝛽₁ + 𝛽₀ 6×0.024 + 7×0.016 + 5×0 + 0.090 = 34% Wikipedia article Basketball " "" "" signal 1 visits from infection observations 5 visits total decoder received message 4 visits for other reasons encoder and noise source received signal Figure 4: Example population of 25 people and how information about this population’s disease status flows to public health decision makers. By traditional means (top flow), incidence information is encoded by the assignment of people to providers, added to noise introduced by the health care system, and decoded by a weighted average. By internet-based means (bottom flow), information is encoded and made noisy by Wikipedia use and decoded by a statistical model. (Note that encyclopedia article visits resulting from infection observations contain both signal and random noise, as illustrated by the extra visit to “Influenza” and the missed visit to “Fever”.) Because quantitative internet-based surveillance needs reference data for training, it both depends on and reflects problems in traditional surveillance 2.1 As a Shannon communication Our model of disease surveillance as a Shannon communication is illustrated in schematic form in Figure 1 and as an example population in Figure 4. This section walks through the key Shannon concepts and vocabulary, detailing how they fit a disease surveillance process. The information source is a real-world phenomenon with a quantitative property we want to measure over some sequence of time intervals. Specifically, we assume that for each interval v, there exists a well-defined quantity of interest (QOI) wv . In our disease surveillance context, we might ask, of United States residents (information source), what fraction become infected with influenza (QOI) during 5 each week of the flu season (interval):2 wv = people newly infected during v total population at risk (1) Each wv comprises one symbol, and the message W is the sequence of all wv ; i.e., W = {w1 , w2 , ..., w|V | }. Here, W comprises the true, unobservable epidemic curve [27] that public health professionals strive for. Next, each symbol is transformed by an encoder function to its corresponding encoded symbol, Uv (wv ). This transformation is distributed, so Uv is not a scalar quantity but rather a set of sub-symbols uvi : Uv (wv ) = {uv1 (wv ), uv2 (wv ), . . . , uv|U | (wv )} (2) (Note that when clear from context, we use unadorned function names like Uv and uv to refer to their output, not the function itself, with the argument implied.) For traditional disease surveillance, the encoder is the partitioning of the population at risk into sub-populations. For example, uvi might be the fraction of people served by clinic i who became infected during interval v. For internet-based surveillance, the encoder is an internet system along with its users. Individuals with health concerns search, click links, write messages, and create other activity traces related to their health status or observations. For example, uvi might be the noise-free number of web searches for query i motivated by observations of infection. Both types of disease surveillance are noisy. Thus, Uv is unobservable by the decoder. Instead, the received symbol at each interval is a set Xv of noisy features: xvi (wv ) = uvi (wv ) + δvi + εvi (3) Xv (wv ) = {xv1 (wv ), xv2 (wv ), . . . , xv|U | (wv )} (4) Each observable feature xvi is composed of unobservable signal uvi , systematic noise δvi , and random noise εvi . For traditional disease surveillance, the noise source is the front-line health care system along with individuals’ choices on whether to engage with this system. For example, there is random variation in whether an individual chooses to seek care and systematically varying influence on those choices. Also, diagnostic criteria can be over- or under-inclusive, and providers make both random and systematic diagnosis errors. Considering these and other influences, xvi might be the fraction of individuals visiting clinic i who are diagnosed positive during 2 This is known as incidence. An alternate measure is prevalence, which is the number of active infections at any given time and which may be more observable by laypeople. Despite this, we illustrate our model with incidence because it is more commonly used by public health professionals. The two are roughly interchangeable unless the interval duration is considerably shorter than the typical duration of infection. 6 interval v, which is not the same as the fraction of individuals in sub-population i who become infected. For internet-based surveillance, the noise source is entangled with the encoder: the internet system and its users serves both roles. For example, whether a given individual with health observations makes a given search contains random variation and systematic biases; also, health-related articles are visited by individuals for non-health reasons. Technical effects such as caching also affect the data. xvi might be the number of number of searches for query i, which is different than the number of searches for query i motivated by observations of infection and unaffected by noise. The decoder function ŵv (Xv ) transforms the received symbol into an estimate of the QOI. For traditional disease surveillance, this is typically a weighted average of xvi ; for internet-based surveillance, it is a statistical model trained against available traditional surveillance estimates, which lag real time. Further details of encoding, noise, and decoding are specific to the different surveillance methods and will be explored below. Finally, the destination of the communication is the people who act on the knowledge contained in ŵv , in our case those who make public health decisions, such as public health professionals and elected or appointed leadership. The problem is that ŵv 6= wv for both traditional and internet surveillance. This leads to the questions why and by how much, which we address next. 2.2 Challenges QOI estimates ŵv are inaccurate for specific reasons.3 Feature i might be nonuseful because (a) uvi (Xv ) is too small, (b) δvi is too large, (c) the function uvi is changing, and/or (d) δvi is changing. These problems can be exacerbated by model misspecification, e.g. if the “true” relationship is quadratic but a linear model is used; we assume a reasonably appropriate model. The following subsections describe these four challenges. 2.2.1 uvi (Xv ) too small: Signal to noise ratio Disease surveillance can miss useful information because the signal uvi is too small: either it does not exist (uvi = 0) or is swamped by noise (uvi  δvi + εvi ). 3 This ontology of errors is related to that of survey statistics, which classifies on two dimensions [22]. Sampling error is random when the whole population is not observed and systematic when the selected sample is non-representative (selection bias). Non-sampling error is everything else, such as measurement and transcription error, and can also be random or systematic. 7 For example, many diseases have high rates of asymptomatic infection; about half of influenza cases have no symptoms [4]. Asymptomatic infections are very hard to measure because they do not motivate internet traces and infected individuals do not seek care. Thus, correction factors tend to be uncertain, particularly for specific outbreaks. An example of the latter is diseases that have low incidence but are well-known and interesting to the public, such as rabies, which had two U.S. cases in 2013 [1]. These diseases tend to produce many internet activity traces, but few are related to actual infections. 2.2.2 δvi too large: Static sample bias The populations sampled by disease surveillance differ from the population at large in systematic ways. For example, those who seek care at clinics, and are thus available to traditional surveillance, tend to be sicker than the general population [17], and internet systems invariably have different demographics than the general population [9]. This problem increases systematic noise δvi for a given feature i by the same amount in each interval v. 2.2.3 uvi changing: Encoding drift The encoder function can change over time, i.e., uvi 6= uti for different intervals v 6= t. For example, internet systems often grow rapidly; this increases the number of available observers, in turn increasing the average number of traces per infection. This is a form of concept drift and reduces estimate accuracy when models erroneously assume function uvi = uti . 2.2.4 δvi changing: Sample bias drift Systematic noise can also change over time, i.e., δvi 6= δti . A commonly cited cause is the “Oprah Effect”, where public interest in an outbreak rises due to media coverage, in turn driving an increase in internet activity related to this coverage rather than disease incidence [3]. Traditional surveillance can have similar problems, dubbed the “Jolie Effect”; some scholars believe the actress’ well-publicized preemptive mastectomy caused a significant change in the population of women seeking breast cancer-related genetic tests [8]. This is another form of concept drift and reduces estimate accuracy when models erroneously assume δvi = δti . 8 Some phenomena can be a mix of the two types of drift. For example, internet systems actively manipulate activity [23], such as Google’s search recommendations that update live while a query is being typed [16]. This can lead users to create disease-related activity traces they might not have, whether motivated by an observed infection (encoding drift) or not (sample bias drift). 2.3 Accuracy metrics Epidemiologists evaluate disease surveillance systems on a variety of qualitative and quantitative dimensions [35]. One of these is accuracy: how close is the estimated incidence to the true value? This can be considered from two perspectives. Error is the difference between the estimated and true QOI values, while deceptiveness is the fraction of an estimate that is based on coincidental rather than informative evidence. The latter is important because it quantifies the risk that future applications of a model will give less accurate estimates. This section defines the two metrics. 2.3.1 Error We quantify error E in the usual way, as the difference between the QOI and its estimate: Ev = ŵv − wv (5) Perfectly accurate estimates yield Ev = 0, overestimates Ev > 0, and underestimates Ev < 0. Importantly, Ev is unobservable, because wv is unobservable. As we discuss below, traditional surveillance acknowledges that Ev = 6 0 but its methods often assume Ev = 0, and this finds its way into internet surveillance via the latter’s training. 2.3.2 Deceptiveness Our second metric, deceptiveness, addresses the issue that an estimate can be accurate for the wrong reasons. A deceptive search query is illustrated in Figure 2. Another example for internet-based surveillance is the sport of basketball, whose season of play roughly coincides with the flu season. A naı̈ve model can notice this correlation and build a decoder that uses basketball-related activity traces to accurately estimate flu incidence. Philosophers might say this model has a justified true belief — it has a correct, evidence-based assessment of the flu — but this belief is not knowledge because it is not based on relevant evidence, creating a Gettier problem [13]. This flu model relies on a coincidental, rather than real, relationship [15]. We call such a model, based on deceptive features, also deceptive. 9 We quantify deceptiveness g as the fraction of the total influence within the estimate contributed by noise. The most basic application is to a specific feature i at interval v:4 |δvi | + |εvi | ∈ [0, 1] (6) gvi = |uvi | + |δvi | + |εvi | One can also define systematic and random deceptiveness gs and gr if the two types of noise should be considered separately. We summarize the deceptiveness of a feature by its maximum deceptiveness over all intervals: gi = max(gvi ) (7) v The deceptiveness of a complete estimate or model depends on the decoder function ŵ, because a decoder that is better able to exclude noise (e.g., by giving deceptive features small coefficients) will reduce the deceptiveness of its estimates. Thus, we partition ŵ into functions that depend on signal ŵs , systematic noise ŵns , and random noise ŵnr : ∆v = {δv1 , δv2 , ..., δv|U | } (8) Ev = {εv1 , εv2 , ..., εv|U | } ŵv (Xv ) = ŵvs (Uv ) + ŵvns (∆v ) (9) + ŵvnr (Ev ) (10) The deceptiveness of an estimate G is therefore: Gv = |ŵvns (∆v )| + |ŵvnr (Ev )| s |ŵv (Uv )| + |ŵvns (∆v )| + |ŵvnr (Ev )| G = max(Gv ) ∈ [0, 1] (11) (12) v A deceptive feature is an example of a spurious relationship. These typically arise due to omitted variable bias: there is some confounding variable (e.g., day of year) that jointly influences both a deceptive feature and the QOI, creating a model mis-specification [2]. Corrections include adding confounds to the model as control variables and data de-trending. These effects can be captured by our approach in ŵns and ŵnr . Like error, deceptiveness is unobservable, and more pernicious because quantifying it relies on the causality of the relationship between a feature and the QOI. This makes it easy and tempting to discount. However, as we discuss below, additional factors such as semantic relatedness can help estimate deceptiveness. We turn next to a specific analysis of traditional disease surveillance as a Shannon communication. 4 This formulation ignores the fact that a feature can have multiple, offsetting sources of noise. One could correct this problem by summing the absolute value of each noise source independently. In general, the specific definition of g should be adapted as the application warrants. 10 3 Traditional disease surveillance Traditional disease surveillance is based on in-person gathering of clinical or laboratory data. These data feed into a reporting chain that aggregates them and computes the corresponding QOI estimates. This section completes the Shannon model for traditional surveillance by detailing the encoding, noise, and decoding steps. We then explore the implications of this model for the surveillance challenges and accuracy metrics. 3.1 Shannon communication model As a concrete example to illustrate the encoding and decoding components of the traditional surveillance communication, we use the United States’ seasonal influenza reporting system, ILInet, because it is one of the most featureful traditional surveillance systems. ILInet produces incidence estimates of influenza-like-illness (ILI): symptoms consistent with influenza that lack a nonflu explanation [5]. Other well-known surveillance systems include the European Surveillance System (TESSy) [28], the Foodborne Diseases Active Surveillance Network (FoodNet) [18], and the United States’ arboviral surveillance system (ArboNET) [24]. Data for ILInet is collected at roughly 2,800 voluntarily reporting sentinel provider clinics [5]. During each one-week interval, reporting providers count (a) the total number of patients seen and (b) the number of patients diagnosed with ILI. These numbers are aggregated via state health departments and the CDC to produce the published ILI estimates. This procedure suggests a hierarchical partition of the population at risk, as illustrated in Figure 5. The observable sets are: • Pv : All members of the population at risk. • Pvv : People who visit a sentinel provider. • Pvnv : People who do not visit a sentinel provider. • Pvd : People who visit a provider and meet the surveillance criteria, in this case because they are diagnosed with ILI. • Pvnd : People who visit a provider but do not meet the surveillance criteria. The sizes of these sets are observable: |Pv | from census data; |Pvv |, |Pvd |, and |Pvnd | from provider reports; and |Pvnv | = |Pv | − |Pvv | by subtraction. These sets are defined by provider visits and diagnosis, which is not the same as infection status. Thus, each is further partitioned into two unobservable subsets: those who acquire a flu infection during interval v and those who do not (though 11 P observable desired population at risk visit provider do not visit Pv Pnv positive diagnosis negative Pd sick Pd+ sick not sick Pnd not sick Pd– not sick sick Pnd+ Pnd– Pnv+ Pnv– Figure 5: Hierarchical partition of the population at risk P into sets whose size is observable or not by traditional disease surveillance. This illustrates the mismatch between the information available to traditional surveillance and the quantity it is trying to measure. they may have an active infection acquired during a previous interval). We denote these with superscript + and − respectively, e.g., Pv = Pv+ ∪ Pv− ; Pv+ ∩ Pv− = ∅. We add a final, orthogonal partitioning into |U | sub-populations served by provider i. For example, the members of sub-population i who visited a send tinel provider during interval v and met the surveillance criteria comprise Pvi . Each individual is a member of exactly one sub-population, and we assume for simplicity that members of sub-population i visit either provider i or none at all.5 We can now model the encoding function that creates vector Xv . Recall that the symbol that we wish to encode is the fraction of the population at risk that became infected during the interval: wv = |Pv+ | |Pv | (13) |Pv+ | = |Pvd+ | + |Pvnd+ | + |Pvnv+ | (14) 5 How individuals select providers does not affect our exposition. Real-world selections are typically driven by geography, socioeconomic status, demographics, and insurance. 12 This can be partitioned by sub-population i: + |Pvi | |Pvi | |Pvi | βi = |Pv | uvi (wv ) = wv = |U | X βi uvi (15) (16) (17) i=1 Note that wv is defined in terms of infection status. On the other hand, surveillance can observe only whether someone visits a sentinel provider and whether they are diagnosed with the surveillance criteria. Each feature xvi ∈ Xv is the fraction of patients visiting provider i who are diagnosed:6 xvi = d |Pvi | v |Pvi | (18) Decoding to produce the estimate ŵv is accomplished as in Equation 17, using the population-derived β as above:7 ŵ(Xv ) = |U | X βi xvi (19) i=1 In short, the traditional surveillance communication is purpose-built to collect only disease-relevant information and thus couples with a simple decoder. Nonetheless, this communication does face the challenges enumerated above and is not noise-free. This we address next. 3.2 Challenges This section details the four challenges outlined above in the context of traditional surveillance. The key issue is sample bias, both static and dynamic. 3.2.1 Signal to noise ratio Traditional surveillance generally does not have meaningful problems with signal to noise ratio. While there are noise sources, as discussed below, these tend to be a nuisance rather than a cause of lost information. 6 In reality, providers report the numerator and denominator of x vi separately, but we omit this detail for simplicity. 7 This corresponds to the ILInet product weighted ILI, which weights by state population. A second product, plain ILI, gives each reporting provider equal weight. For simplicity, this paper uses unadorned ILI to refer to weighted ILI. 13 This is due largely to the purpose-built nature of the surveillance system, which works hard to measure only what is of interest. To avoid missing cases of important rare diseases, where signal to noise ratio is of greatest concern, monitoring is more focused. For example, any provider who sees a case of rabies must report it [1], in contrast to ILInet, which captures only a sample of seasonal flu cases. 3.2.2 Static sample bias Patient populations (P v ) differ systematically from the general population (P ). For example, patients in the Veteran Health Administration tend to be sicker and older than the general population [17], and traditional influenza systems tend to over-represent severe cases that are more common in children and the elderly [32]. Sampling bias can in principle be mitigated by adjusting measurement weights to account for the ways in which the populations differ, for example by age [32], triage score [32], and geography [5]. This, however, requires quantitative knowledge of the difference, which is not always available or accurate. ILInet uses the number of sites that report each week, state-specific baselines, and age [5]. For influenza, age is particularly important for mitigating sample bias, because severity and attack rate differ widely between age groups [32]. 3.2.3 Encoding drift In our model, traditional surveillance is immune to encoding drift because the encoder functions contain only wv (Equation 15); there are no other parameters to effect drift. 3.2.4 Sample bias drift Traditional surveillance is designed to be consistent over time, but it does not reach this goal perfectly and is not immune to drifting sample bias. One source of drift is that case definitions change. Figure 3 illustrates this for autism spectrum disorder, and the definition of ILI has also varied over time [21]. Another is that individuals’ decisions on whether to seek care drift; for example, media coverage of an outbreak [31] or a celebrity editorial [8] can affect these decisions. These and others do not affect the newly infected and non-newlyinfected equally, so the sample bias and associated systematic noise changes. This suggests that traditional surveillance might be improved by better addressing sample bias. Bias could be reduced by sampling those not seeking care, e.g., by random telephone surveys of the general population for flu symptoms, and it could be better corrected with improved static and dynamic bias models. 14 3.3 Accuracy d− d Traditional surveillance features include patients not newly infected (Pvi ⊂ Pvi ) and exclude people who are newly infected but receive a negative diagnosis or do nd+ nv+ d v not visit a sentinel provider (Pvi ∩ Pvi = ∅ and Pvi ∩ Pvi = ∅, respectively). Causes include lack of symptoms, diagnosis errors by individual or provider, and access problems. That is: xvi = d |P + | |Pvi | 6= vi = uvi v |Pvi | |Pvi | (20) In practice, this problem is addressed by essentially assuming it away. That is, consumers of traditional surveillance assume that the fraction of patients diagnosed with the surveillance criteria does in fact equal the new infection rate among the general population: + d |Pvi | |Pvi | = v| |Pvi |Pvi | (21) xvi = uvi (22) Some recent work extends this to assume that the quantities are proportional, independent of v [33, e.g.]. Epidemiologists know this assumption is dubious. They are careful to refer to “ILI” rather than “influenza”, do not claim that ILI is equal to incidence, and give more consideration to changes over time rather than specific estimate values. Under these caveats, the measure serves well the direct goals of surveillance, such as understanding when an outbreak will peak and its severity relative to past outbreaks [5]. Both error and deceptiveness in traditional surveillance depend on noise. This can be quantified by rewriting Equation 18: xvi = uvi + δvi + εvi = + d | |Pvi | |Pvi − v |Pvi | |Pvi | + d |Pvi | |Pvi | − v |Pvi | |Pvi | (23) (24) As one might expect, the noise in feature xvi is the difference between the fraction of clinic-visiting, diagnosed patients and the fraction of the general population newly infected. One challenge is separating the noise into systematic and random components. For example, if a newly infected person chooses to seek care, how much of that decision is random chance and how much is systematic bias? The present work does not address this, but one can imagine additional parameters to quantify this distinction. 15 3.3.1 Error Recall that error is the difference between the true QOI and its estimate: Ev = ŵv − |Pv+ | |Pv | (25) |P + | The unobservable ratio |Pvv | can be estimated, but with difficulty, because one must test the entire population, not just those who seek care or are symptomatic. One way to do this is a sero-prevalence study, which looks for antibodies in the blood of all members of a population; this provides direct evidence of past infection rates [14]. The adjustments discussed above under challenges also reduce error by improving ŵv . 3.3.2 Deceptiveness One can write the deceptiveness of a specific feature as follows: gvi = d |Pvi | v | |Pvi uvi + − uvi d | |Pvi v | |Pvi (26) − uvi Note that because we only know δvi and εvi as a sum, we must use |δvi +εvi | rather than |δvi | + |εvi |, making the metric less robust against offsetting systematic and random error. This again depends on an unobservable ratio, meaning that in practice it must be estimated rather than measured. wv 6= ŵv in traditional disease surveillance due to unavoidable systematic and random noise. Despite this, it frequently provides high-quality data of great social value. For example, the distinction between a case of influenza and a case of non-influenza respiratory disease with flu-like symptoms is often immaterial to clinical resource allocation and staffing decisions, because the key quantity is volume of patients rather than which specific organism is at fault. ŵv provides this. Thus, traditional surveillance is an example of a situation where the quantity of interest wv is elusive, but a noisy and biased surrogate ŵv is available and sufficient for many purposes. Accordingly, traditional surveillance has much in common with internet-based surveillance, as we next explore. 4 Internet-based disease surveillance In contrast to traditional surveillance, which is based on data gathered by direct observation of individual patients, internet-based disease surveillance conjectures 16 that traces of people’s internet activity can drive a useful incidence estimation model. Thus, its Shannon communication differs, as do the corresponding implications for its challenges and accuracy. 4.1 Shannon communication model Internet-based surveillance leverages found features optimized for unrelated purposes,8 instead of purpose-built ones as in traditional surveillance. Rather than diagnosis counts made by health care providers, features in internet surveillance arise by counting defined classes of activity traces; thus, they are much more numerous. For example, Wikipedia contains 40 million encyclopedia articles across all its languages [38], versus 2,800 ILInet providers. As a corollary, while traditional features offer useful information by design, internet-based features are the result of complex guided and emergent human behavior and thus overwhelmingly non-informative. That is, most internet features provide no useful information about flu incidence, but a few might. For example, the number of times the Wikipedia article “Influenza” was requested in a given week plausibly informs a flu estimate, while “Basketball” and “George H. W. Bush” do not. Raw traces such as access log lines are converted into counts, such as the number of requests for each article, searches for each query string, or n-gram mentions per unit time. In the case of Wikipedia, xvi ∈ Z ≥ 0 is the number of requests for Wikipedia article i during interval v. These trace counts comprise the features. For example, for each new infection during interval v, some number of requests uvi for every Wikipedia article i is generated. Added to this signal is systematic noise δvi (article requests made for other reasons), and random noise εvi (random variation in article traffic). Thus, the features observable to the decoder are the familiar mix of signal and noise: xvi = uvi + δvi + εvi . (3) Internet features use a different unit than traditional features. For traditional surveillance, the symbol and feature units are both the person, who has a specific infection status and can be assigned a positive or negative diagnosis. For internet surveillance, the unit is activity traces. These include traces of information seeking activity such as Wikipedia article requests [12] or Google searches [15] as well as information sharing activity such as n-grams in Twitter messages [7]. This mismatch between feature units (trace counts) and encoded symbol units (people) is a challenge for internet-based surveillance that is not shared with traditional surveillance. Like traditional surveillance, the decoder is a function of the observable data (features). Often, this is a parameterized model, such as a linear model, that 8 For example, looking at illustrations of cats [30]. 17 contains parameters that must be estimated. This is done by fitting the model against a reference data set, which is usually incidence estimates from a traditional surveillance system. We denote these reference data as yv . For a linear model, the fit is set up as: yv = |U | X βi xvi + β0 + εv (27) i=1 The slopes βi are estimated in two steps. The first is a filter: because including the very large number of irrelevant internet features in a regression would be noisy and inefficient, most of them are removed by setting βi = 0. This procedure might be a context analysis (i.e., all features semantically unrelated to the outbreak of interest are removed), a correlation analysis (features where the correlation between y and xi is below a threshold are removed), or something else. The goal is to greatly reduce the number of features, e.g. from 40 million to tens or hundreds in the case of Wikipedia, implementing the modelers’ prior belief over which features are relevant and not deceptive. Next, β0 and the remaining βi are estimated by fitting the collection of xi to y using some kind of regression. These estimated coefficients constitute a fitted model that can be applied to a previously unseen set of features Xt , producing an estimate of the reference ŷv and in turn the QOI ŵv . This approach illustrates how internet-based disease surveillance is inextricably bound to traditional surveillance. Quantitative statistical estimates require quantitative reference data, and some form of traditional surveillance is what is available. Internet surveillance thus inherits many of traditional surveillance’s flaws; for example, if the reference data are biased, the internet estimates will share this bias. However, internet estimates do have important advantages of timeliness and cost because the information pipeline, once configured, is entirely automated. While for contexts like U.S. ILI, which has a lag of 1–2 weeks [5], this speed advantage is modest, in other contexts traditional surveillance lags by months or an entire season, a critical flaw [20]. 4.2 Challenges Internet-based disease surveillance faces a new set of challenges derived from its use of a non-purpose-built encoder. 4.2.1 Signal to noise ratio This is a significant problem for internet-based surveillance. For example, the English Wikipedia article “Rabies” was requested 1.6 million times in 2013 [36], 18 but there were only two U.S. cases that year [1]. Thus, it’s certain that u  δ + ε and plausible that u = 0, making requests for this article a deceptive feature. This limits the applicability of internet-based surveillance. Outbreaks likely occur having no features with sufficiently low deceptiveness, making them impossible to surveil reliably with internet data. This may be true even if fitting yields a low-error model, because fitting seeks out correlation rather than causality; recall the basketball problem. Models can address this by estimating deceptiveness and down-weighting features with high deceptiveness. Thus, accurately estimating deceptiveness is important. We explore this further below. 4.2.2 Static sample bias Internet surveillance suffers from sample bias in multiple ways. First, diseaserelated activity traces in a given internet system reflect people’s responses to the real world, including reflections of their own health status or that of people they observe (who are likely to be similar to them). Internet use varies systematically based on factors related to health status, such as age and other demographics; in turn, activity traces vary systematically by those same factors. For example, social media tends to be modestly skewed on most demographic variables studied, including gender, age, race, education, income, and urban/rural [9]. Second, the unit mismatch between the message (people) and signal (trace counts) can increase this bias. For example, one might hypothesize that a younger person with respiratory symptoms might post more messages about the situation than an older person with the same symptoms. If this is systematically true, then the the number of activity traces is additionally biased on top of the user bias noted above. This opportunity for bias is not shared with traditional surveillance. However, the fitting process compensates for these biases. For example, if women are overrepresented among a systems’ users and this is evident in their activity traces, the gendered traces will be down-weighted, correcting for the overrepresentation. Thus, the resulting estimates will be roughly as biased as the reference data. 4.2.3 Encoding drift This issue can be a problem for internet surveillance, because the assumption that uvi = uti for all intervals v and t (Equation 27) is false. For example, modern search sites use positive feedback: as more people search for flu, the system notices and offers more suggestions to search for flu [23], thus increasing the number of searches per infection. Models can address this by incorporating more realistic assumptions about how u changes over time, for example that it varies smoothly. 19 4.2.4 Sample bias drift This is perhaps the most pernicious problem for internet surveillance. That is, the assumption that δvi = δti ∀ v, t (also Equation 27) is simply false, sometimes very much so. Causes can include gradual user and activity pattern drift over time as well as sudden “Oprah Effect” shifts. Models can address this by treating δ over time more realistically. Opportunities include explicit model terms such as smooth variation, leveraging deceptiveness estimates to exclude deceptive features, and including data sources to estimate current sample bias, though taking advantage of such opportunities well may be challenging. We argue that in order for any internet-based surveillance proposal to be credible, it must address signal-to-noise ratio and drift issues using careful, quantitative, and application-aware methods. On the other hand, static sample bias can be addressed by simply following best practices. We propose some assessment options in the next section. 4.3 Accuracy Error for internet-based models can be easily computed against the reference data y, but because the QOI w is not observable even after the passage of time, true error is not observable either. This has two consequences. First, any imperfections in the traditional surveillance are not evident in the error metric; thus, it is prudent to evaluate against multiple reference data. Second, simulation studies where w is known are important for properly evaluating a proposed approach. Deceptiveness adds an additional problem: it depends not only on the quantitative relationship between features and the QOI but their causal relationship as well. This makes it fundamentally unknowable, even with perfect reference data. However, the situation is not quite so grim, as proxies are often available. For example, our previous work showed that limiting Wikipedia models to semantically related articles reduced error [29]. Models can also reduce risk by monitoring carefully for the breakdown in coincidental correlation that makes deceptive features troublesome. Our point is not that the situation is hopeless but that that effective internet-based models must grapple quantitatively with deceptiveness. We argue that doing so successfully is plausible; compare the features in Figure 6 to the one in Figure 2. Properly designed internet-based surveillance might be almost as accurate as traditional surveillance but available faster, providing similar value in a more nimble, and thus actionable, fashion. 20 ILI % 6 Google searches for flu (interpolated) vs. U.S. ILI ILI search 4 2 0 2013-Jul ILI % 6 2014-Jan 2014-Jul 2015-Jan Searches for influenza (Google topic) vs. U.S. ILI 4 ILI search 2 0 2013-Jul 2014-Jan 2014-Jul 2015-Jan Figure 6: Alternatives to the deceptive feature in Figure 2. These examples show that additional information can sometimes be used to reduce deceptiveness in internet features. At top, expert knowledge about the patterns of seasonal flu is used to identify and remove the deceptive period, replacing it with a linear interpolation. At bottom, Google’s proprietary machine learning algorithms are used to identify and count searches likely related to the disease, rather than occurrences of a raw search string. 21 5 A path forward Traditional disease surveillance is not perfect. It has problems with static sample bias and, to a lesser degree, drifting bias. These are consequences of the fact that traditional surveillance can only gather information from people in contact with the health care system. Thus, expanding access to health care, outreach, and further work on compensating for these biases can improve incidence estimates produced by traditional surveillance. Internet-based surveillance is not perfect either. In addition to inheriting most of the problems of traditional surveillance, with which it is necessarily entangled for training data, it adds signal-to-noise problems, further sample bias issues, and further drift as a consequence of its found encoder. Yet because it is more timely, it holds great promise. So what is to be done? We propose three things. 1. In order to select model features with both high correlation to reference data and low deceptiveness, additional reference data must be added, such as semantic relatedness. 2. The feasibility of an internet-based approach in a given situation must be modeled, not just tested. This can be done by (a) defining bounds on acceptable estimate error and deceptiveness, (b) working backwards to derive the necessary accuracy of input features, and (c) comparing to available features. 3. The presence of unobservables in the accuracy metrics means that no model can be completely evaluated only on real data. One must also evaluate it in simulation where all quantities are known. Internet-based disease surveillance cannot replace traditional surveillance, but it can be an important complement because it is faster and cheaper with broader reach. By better understanding the deficiencies of both along with their commonalities and relationship, using the tools proposed above, we can build quantitative arguments describing the added value of internet-based surveillance in specific situations. Only then can it be relied on for life-and-death public health decisions [12]. Acknowlegements This work was supported in part by the U.S. Department of Energy through the LANL/LDRD Program. A.C. was funded in part by the National Science Foundation under awards IIS-1526674 and IIS-1618244. Sara Y. Del Valle, John Szymanski, and Kyle Hickmann provided important feedback. 22 References [1] Deborah Adams, Kathleen Fullerton, Ruth Jajosky, Pearl Sharp, Diana Onweh, Alan Schley, Willie Anderson, Amanda Faulkner, and Kiersten Kugeler. Summary of notifiable infectious diseases and conditions — United States, 2013. MMWR, 62(53), October 2015. doi:10.15585/mmwr.mm6253a1. [2] Joshua D. Angrist and Jörn-Steffen Pischke. Mostly harmless econometrics: An empiricist’s companion. 2009. [3] Declan Butler. When Google got flu wrong. Nature, 494(7436), February 2013. doi:10.1038/494155a. [4] Centers for Disease Control and Prevention. MMWR morbidity tables. Dataset, 2015. URL: http://wonder.cdc.gov/mmwr/mmwrmorb.asp. [5] Centers for Disease Control and Prevention. Overview of influenza surveillance in the United States. Fact sheet, October 2016. URL: https: //www.cdc.gov/flu/pdf/weekly/overview-update.pdf. [6] Courtney D. Corley, Diane J. Cook, Armin R. Mikler, and Karan P. Singh. Text and structural data mining of influenza mentions in web and social media. Environmental Research and Public Health, 7(2), February 2010. doi:10.3390/ijerph7020596. [7] Aron Culotta. Lightweight methods to estimate influenza rates and alcohol sales volume from Twitter messages. Language Resources and Evaluation, 47(1), March 2013. doi:10.1007/s10579-012-9185-0. [8] Sunita Desai and Anupam B. Jena. Do celebrity endorsements matter? Observational study of BRCA gene testing and mastectomy rates after Angelina Jolie’s New York Times editorial. BMJ, 355, December 2016. doi:10.1136/bmj.i6357. [9] Maeve Duggan, Nicole B. Ellison, Cliff Lampe, Amanda Lenhart, and Mary Madden. Social media update 2014. Technical report, Pew Research Center, January 2015. URL: http://www.pewinternet.org/2015/01/09/ demographics-of-key-social-networking-platforms-2/. [10] Flu Trends Team. The next chapter for Flu Trends, August 2015. URL: http://googleresearch.blogspot.com/2015/08/the-nextchapter-for-flu-trends.html. [11] João Gama, Indrė Žliobaitė, Albert Bifet, Mykola Pechenizkiy, and Abdelhamid Bouchachia. A survey on concept drift adaptation. ACM Computing Surveys, 46(4), March 2014. doi:10.1145/2523813. [12] Nicholas Generous, Geoffrey Fairchild, Alina Deshpande, Sara Y. Del Valle, and Reid Priedhorsky. Global disease monitoring and forecasting with Wikipedia. PLOS Computational Biology, 10(11), November 2014. doi: 10.1371/journal.pcbi.1003892. 23 [13] Edmund L. Gettier. Is justified true belief knowledge? Analysis, 23(6), June 1963. URL: http://www.jstor.org/stable/3326922. [14] Cheryl L Gibbons, Marie-Josée J Mangen, Dietrich Plass, Arie H Havelaar, Russell John Brooke, Piotr Kramarz, Karen L Peterson, Anke L Stuurman, Alessandro Cassini, Eric M Fèvre, and Mirjam EE Kretzschmar. Measuring underreporting and under-ascertainment in infectious disease datasets: A comparison of methods. BMC Public Health, 14(1), December 2014. doi: 10.1186/1471-2458-14-147. [15] Jeremy Ginsberg, Matthew H. Mohebbi, Rajan S. Patel, Lynnette Brammer, Mark S. Smolinski, and Larry Brilliant. Detecting influenza epidemics using search engine query data. Nature, 457(7232), November 2008. doi: 10.1038/nature07634. [16] Google, Inc. Search using autocomplete - Search Help, 2016. URL: https: //support.google.com/websearch/answer/106230?hl=en. [17] Nicholas M. Halzack and Thomas R. Miller. Patients cared for by the Veterans Health Administration present unique challenges to health care providers. Policy brief Vol 2. Issue 3, American Society of Anesthesiologists, April 2014. [18] Olga L. Henao, Timothy F. Jones, Duc J. Vugia, and Patricia M. Griffin. Foodborne diseases active surveillance network — 2 decades of achievements, 1996–2015. Emerging Infectious Diseases, 21(9), September 2015. doi: 10.3201/eid2109.150581. [19] Dorothy M. Horstmann. Importance of disease surveillance. Preventive Medicine, 3(4), December 1974. doi:10.1016/0091-7435(74)90003-6. [20] Ruth Ann Jajosky and Samuel L Groseclose. Evaluation of reporting timeliness of public health surveillance systems for infectious diseases. BMC Public Health, 4(1), July 2004. doi:10.1186/1471-2458-4-29. [21] L Jiang, V Lee, W Lim, M Chen, Y Chen, L Tan, R Lin, Y Leo, I Barr, and A Cook. Performance of case definitions for influenza surveillance. Eurosurveillance, 20(22), June 2015. doi:10.2807/1560-7917.ES2015.20. 22.21145. [22] Graham Kalton. Introduction to survey sampling, volume 07-035. 1983. [23] David Lazer, Ryan Kennedy, Gary King, and Alessandro Vespignani. The parable of Google Flu: Traps in big data analysis. Science, 343(6176), March 2014. URL: http://science.sciencemag.org/content/343/6176/1203. [24] Nicole P. Lindsey, Jennifer A. Brown, Lon Kightlinger, Lauren Rosenberg, and Marc Fischer. State health department perceived utility of and satisfaction with ArboNET, the U.S. national arboviral surveillance system. Public Health Reports, 127(4), 2012. URL: http://www.ncbi.nlm.nih.gov/pmc/ articles/PMC3366375/. 24 [25] Colin D. Mathers and Dejan Loncar. Projections of global mortality and burden of disease from 2002 to 2030. PLOS Medicine, 3(11), November 2006. doi:10.1371/journal.pmed.0030442. [26] National Center for Health Statistics. 2015 data release. Dataset, January 2017. URL: https://www.cdc.gov/nchs/nhis/nhis_2015_data_ release.htm. [27] Kenrad E. Nelson and Carolyn Williams. Infectious disease epidemiology. March 2013. [28] Gordon L. Nichols, Yvonne Andersson, Elisabet Lindgren, Isabelle Devaux, and Jan C. Semenza. European monitoring systems and data for assessing environmental and climate impacts on human infectious diseases. Environmental Research and Public Health, 11(4), April 2014. doi:10.3390/ijerph110403894. [29] Reid Priedhorsky, David A. Osthus, Ashlyn R. Daughton, Kelly Moran, Nicholas Generous, Geoffrey Fairchild, Alina Deshpande, and Sara Y. Del Valle. Measuring global disease with Wikipedia: Success, failure, and a research agenda. In Computer Supported Cooperative Work (CSCW), 2017. doi:10.1145/2998181.2998183. [30] Rathergood. The internet is made of cats, January 2010. URL: https: //www.youtube.com/watch?v=zi8VTeDHjcM. [31] G.J. Rubin, H.W.W. Potts, and S. Michie. The impact of communications about swine flu (influenza A H1N1v) on public responses to the outbreak: Results from 36 national telephone surveys in the UK. Health Technology Assessment, 14(34), July 2010. doi:10.3310/hta14340-03. [32] N. Savard, L. Bedard, R. Allard, and D. L. Buckeridge. Using age, triage score, and disposition data from emergency department electronic records to improve Influenza-like illness surveillance. Journal of the American Medical Informatics Association, February 2015. doi:10.1093/jamia/ocu002. [33] Jeffrey Shaman, Alicia Karspeck, Wan Yang, James Tamerius, and Marc Lipsitch. Real-time influenza forecasts during the 2012–2013 season. Nature Communications, 4(2387), December 2013. doi:10.1038/ncomms3837. [34] Claude E. Shannon. A mathematical theory of communication. Bell System Technical Journal, 27(3), July 1948. doi:10.1002/j.1538-7305.1948. tb01338.x. [35] S. B. Thacker, R. G. Parrish, and F. L. Trowbridge. A method for evaluating systems of epidemiological surveillance. World Health Statistics Quarterly, 41(1), 1988. [36] User:Henrik. Wikipedia article traffic statistics, 2014. URL: http://stats. grok.se/. 25 [37] Benjamin Zablotsky, Lindsey I. Black, Matthew J. Maenner, Laura A. Schieve, and Stephen J. Blumberg. Estimated prevalence of autism and other developmental disabilities following questionnaire changes in the 2014 National Health Interview survey. National Health Statistics Reports, 87, November 2015. URL: https://www.cdc.gov/nchs/data/nhsr/nhsr087. pdf. [38] Erik Zachte. Wikipedia statistics all languages, November 2016. URL: https://stats.wikimedia.org/EN/TablesWikipediaZZ.htm. 26
7cs.IT
Approximating Betweenness Centrality in Fully-dynamic Networks∗ Elisabetta Bergamini† Henning Meyerhenke† arXiv:1510.07971v1 [cs.DS] 27 Oct 2015 Abstract Betweenness is a well-known centrality measure that ranks the nodes of a network according to their participation in shortest paths. Since an exact computation is prohibitive in large networks, several approximation algorithms have been proposed. Besides that, recent years have seen the publication of dynamic algorithms for efficient recomputation of betweenness in networks that change over time. In this paper we propose the first betweenness centrality approximation algorithms with a provable guarantee on the maximum approximation error for dynamic networks. Several new intermediate algorithmic results contribute to the respective approximation algorithms: (i) new upper bounds on the vertex diameter, (ii) the first fully-dynamic algorithm for updating an approximation of the vertex diameter in undirected graphs, and (iii) an algorithm with lower time complexity for updating single-source shortest paths in unweighted graphs after a batch of edge actions. Using approximation, our algorithms are the first to make in-memory computation of betweenness in dynamic networks with millions of edges feasible. Our experiments show that our algorithms can achieve substantial speedups compared to recomputation, up to several orders of magnitude. Moreover, the approximation accuracy is usually significantly better than the theoretical guarantee in terms of absolute error. More importantly, for reasonably small approximation error thresholds, the rank of nodes is well preserved, in particular for nodes with high betweenness. Keywords: betweenness centrality, algorithmic network analysis, vertex diameter, approximation algorithms, shortest paths 1 Introduction The algorithmic analysis of complex networks has become a highly active research area. One important task in network analysis is to rank nodes by their structural importance using centrality measures. Betweenness centrality (BC) is among the widely used measures; it ranks the importance of nodes based on their participation in the shortest paths of the network. More formally, let the graph G represent a network with n nodes and m edges. Naming σst the number of shortest paths from a node s to a node t and σst (v) the number of shortest paths from P σst (v) 1 s to t that go through v, the (normalized) BC of v is defined as [12]: cB (v) = n(n−1) s6=v6=t σst . Nodes with high betweenness can be important in routing, spreading processes and mediation of interactions. Depending on the context, this can mean, for example, finding the most influential persons in a social network, the key infrastructure nodes in the internet, or super spreaders of a disease. Since BC depends on all shortest paths, its exact computation is expensive: the best known algorithm [7] is quadratic in the number of nodes for sparse networks and cubic for dense networks, which is prohibitive for networks with hundreds of thousands of nodes. Many graphs of interest, however, such as web graphs or social ∗ Parts of this paper have been published in a preliminary form in the Proceedings of the Seventeenth Workshop on Algorithm Engineering and Experiments (ALENEX 2015) [5] and the Proceedings of the 23rd Annual European Symposium on Algorithms (ESA 2015) [4]. † Institute of Theoretical Informatics, Karlsruhe Institute of Technology (KIT), Germany. networks, have millions or even billions of nodes and edges. Thus, recent years have seen the publication of several approximation algorithms that aim to reduce the computational effort, while finding BC values that are as close as possible to the exact ones. Good results have been obtained in this regard; in particular, a recent algorithm by Riondato and Kornaropoulos (RK) [25] gives probabilistic guarantees on the quality of the approximation. It is described in more detail in Section 3 since we build our algorithms on this method. Motivation. Large graphs of interest, such as the Web and social networks, change continuously. Thus, in addition to the identification of important nodes in a static network, an issue of great interest is the dynamic behavior of centrality values in networks that change over time. So far, there have been no approximation algorithms that efficiently update BC scores rather than recomputing them from scratch. Several methods have been proposed to update the BC values after a graph modification, which for some of the algorithms can only be one edge insertion and for others can also be one edge deletion. However, all of these approaches are exact and have a worst-case time complexity which is the same as Brandes’s algorithm (BA) [7] on general graphs and a memory footprint of Ω(n2 ). Contribution. In this paper, as our main contribution, we present the first approximation algorithms for BC in graphs that change over time. Such graphs may be directed or undirected, weighted or unweighted. We consider two dynamic scenarios, an incremental one (i. e. only edge insertions or weight decreases are allowed) and a fully-dynamic one, which also handles edge deletions or weight increase operations. After each batch of edge actions, we assert the same guarantee as the static RK algorithm: the approximated BC values differ by at most  from the exact values with probability at least 1 − δ, where  and δ can be arbitrarily small constants. Running time and memory required depend on how tightly the error should be bounded. Besides resampling as few shortest paths as possible, several new intermediate algorithmic results contribute to the speed of the respective new approximation algorithms: (i) In Section 4 we propose new upper bounds on the vertex diameter VD (i. e. number of nodes in the shortest path(s) with the maximum number of nodes). These bounds vary depending on the graph type (weighted vs unweighted, directed vs undirected). Their usefulness stems from the fact that the new bounds can often improve the one used in the RK algorithm [25] and thereby significantly reduce the number of samples necessary for the error guarantee. (ii) In Section 5, besides detailing the BC approximation algorithms, we also present the first fully-dynamic algorithms for updating an approximation of VD in undirected graphs. (iii) As part of the BC approximation algorithms, we propose an algorithm with lower time complexity for updating single-source shortest paths in unweighted graphs after a batch of edge actions. Our experimental study shows that our algorithms are the first to make in-memory computation of a betweenness ranking practical for large dynamic networks. With approximation we achieve a much improved scaling behavior compared to exact approaches (also dynamic ones), enabling us to update approximate betweenness scores in a network with 36 million edges in a few seconds on typical workstation hardware. Moreover, processing batches of edge actions, our algorithms yield significant speedups (several orders of magnitude) compared to restarting the approximation with RK. Regarding accuracy, our experiments show that the estimated absolute errors are always lower than the guaranteed ones. For nodes with high betweenness, also the rank of nodes is well preserved, even when relatively few shortest paths are sampled. 2 Related work Static BC algorithms - exact and approximation. The fastest existing method for the exact BC computation, BA, requires Θ(nm) operations for unweighted graphs and Θ(nm+n2 log n) for graphs with positive edge weights [7]. BA computes for every node s ∈ V a slightly modified version of a single-source shortest-path tree (SSSP tree), producing for each s the directed acyclic graph (DAG) of all shortest paths starting at s. Using the information contained in the DAGs, BA computes the dependency δs (v) for each node v, that is the sum over all nodes t of the fraction of shortest paths between s and t that v is internal to. The betweenness of each node v is simply the sum over all sources s ∈ V of the dependencies δs (v). Therefore, we can see the dependency δs (v) as a contribution that s gives to the computation of cB (v). Based on this concept, some algorithms for an approximation of BC have been developed. Brandes and Pich [8] propose to approximate cB (v) by extrapolating it from the contributions of a subset of source nodes, also called pivots. Selecting the pivots uniformly at random, the approximation can be proven to be an unbiased estimator for cB (v) (i.e. its expectation is equal to cB (v)). In a subsequent work, Geisberger et al. [14] notice that this can overestimate BC scores of nodes close to the pivots. To limit this bias, they introduce a scaling function which gives less importance to contributions from pivots that are close to the node. Bader et al. [1] approximate the BC of a specific node only, based on an adaptive sampling technique that reduces the number of pivots for nodes with high centrality. Chehreghani [9] proposes alternative sampling techniques that try to minimize the number of samples. Different from the previous approaches is the approximation algorithm by Riondato and Kornaropoulos [25], which samples a single random shortest path at each iteration. This approach allows a theoretical guarantee on the quality of approximation (see Section 3). Because of this guarantee, we use it as a building block of our new approach and refer to it as RK. Exact dynamic algorithms. Dynamic algorithms update the betweenness values of all nodes in response to a modification on the graph, which might be an edge/node insertion, an edge/node deletion or a change in an edge’s weight. The first published approach is QUBE by Lee et al. [20], which relies on the decomposition of the graph into biconnected components. The approach has been extended to node updates in [15]. The approach proposed by Green et al. [16] for unweighted graphs maintains a structure with the previously calculated BC values and additional information, like the distance of each node v from every source s ∈ V and the list of predecessors, i.e. the nodes immediately preceding v in all shortest paths from s to v. Using this information, it tries to limit the recomputations to the nodes whose betweenness has actually been affected. Kourtellis et al. [18] modify the approach by Green et al. [16] in order to reduce the memory requirements. Instead of storing the predecessors of each node v from each possible source, they recompute them every time the information is required. Kas et al. [17] extend an existing algorithm for the dynamic APSP problem by Ramalingam and Reps [24] to also update BC scores. The recent work by Nasre et al. [22] contains the first dynamic algorithm for BC (NPR) which is asymptotically faster than recomputing from scratch on certain inputs. In particular, when only edge insertions are allowed and the considered graph is sparse and weighted, their algorithm takes O(n2 ) operations, whereas BA requires O(n2 log n) on sparse weighted graphs. Pontecorvi and Ramachandran [23] extend existing fully-dynamic APSP algorithms with new data structures to update all shortest paths (APASP) and then recompute dependencies as in BA. All dynamic algorithms mentioned perform better than recomputation on certain inputs. Yet, none of them has a worst-case complexity better than BA on all graphs since all require an update of an APSP problem. For this problem, no algorithm exists which has better worst-case running time than recomputation [26]. In addition, the problem of updating BC seems even harder than the dynamic APSP problem. Indeed, the dependencies (and therefore BC) might need to be updated even on nodes whose distance from the source has not changed, as they could be part of new shortest paths or not be part of old shortest paths any more. Batch dynamic SSSP algorithms. Dynamic SSSP algorithms recompute distances from a source node after a single edge update or a batch of edge updates. Algorithms for the batch problem have been published [24, 13, 3] and compared in experimental studies [3, 10]. The experiments show that the tuned algorithm T-SWSF [3] performs well on many types of graphs and edge updates. Therefore we use T-SWSF as a building block in our fully-dynamic BC approximation algorithm. 3 RK algorithm In this section we briefly describe the static BC approximation algorithm by Riondato and Kornaropoulos (RK) [25], the foundation for our incremental approach. The idea of RK is to sample a set S = {p(1) , ..., p(r) } 3 of r shortest paths between randomly sampled source-target pairs (s, t). Then, RK computes the approximated betweenness centrality c̃B (v) of a node v as the fraction of sampled paths p(k) ∈ S that v is internal to, by adding 1 r to the node’s score for each of these paths. Figure 1 illustrates an example where the sampling of two shortest paths leads to 2r and 1r being added to the score of u and v, respectively. Each possible shortest path pst has 1 the following probability of being sampled in each of the r iterations: πG (pst ) = n(n−1) · σ1st (Lemma 7 of [25]). The number r of samples required to approximate BC scores with the given error guarantee is calculated as t2 s1 (3.1) c r= 2   1 blog2 (VD − 2)c + 1 + ln δ  , where  and δ are constants in (0, 1), c ≈ 0.5 and VD is the vertex diameter of G, i.e. the number of nodes in the shortest path of G with maximum number of nodes. In unweighted graphs VD coincides with diam+1, where diam is the number of edges in the longest shortest path. In weighted graphs VD and the (weighted) diameter diam (i. e. the length of the longest shortest path) are unrelated quantities. The following error guarantee holds: + 1r v + 2r t1 u s2 Figure 1: Sampled paths and score update in the RK algorithm Lemma 3.1. [25] If r shortest paths are sampled according to the abovedefined probability distribution πG , then with probability at least 1 − δ the approximations c̃B (v) of the betweenness centralities are within  from their exact value: Pr(∃v ∈ V s.t. |cB (v) − c̃B (v)| > ) < δ. To sample the shortest paths according to πG , RK first chooses a node pair (s, t) uniformly at random and performs an SSSP search from s, keeping also track of the number σsv of shortest paths from s to v and of the list of predecessors Ps (v) for any node v. Then one shortest path is selected: Starting from t, a predecessor z ∈ Ps (t) P is selected with probability σsz / w∈Ps (t) σsw = σsz /σst . The sampling is repeated iteratively until node s is reached. Algorithm 1 is the pseudocode for RK. Function computeExtendedSSSP is an SSSP algorithm that keeps track of the number of shortest paths and of the list of predecessors while computing distances, as in BA. Approximating the vertex diameter. RK uses two upper bounds on VD that can be both computed in O(n + m). For unweighted undirected graphs, it samples a source node si for each connected component of G, computes a BFS from each si and sums the two shortest paths with maximum length starting in si . The VD approximation is the maximum of these sums over all components. For directed or weighted graphs, RK approximates VD with the size of the largest weakly connected component, which can be a significant overestimation for complex networks, possibly of orders of magnitude. In this paper, we present new approximations for directed and for weighted graphs, described in Section 4. 4 New upper bounds on the vertex diameter 4.1 Directed unweighted graphs. Let G be a directed unweighted graph. For now, let us assume G is strongly connected. Let s be any node in G and let u be the node with maximum forward distance from s (i. e. d(s, u) ≥ d(s, x) ∀x ∈ V ). Analogously, let v be the node with maximum backward distance (i. e. ˜ SC the sum d(s, u) + d(v, s) + 1: d(v, s) ≥ d(x, s) ∀x ∈ V ). Then, naming VD ˜ SC < 2VD. Lemma 4.1. VD ≤ VD Proof. Let x and y be two nodes such that the number of nodes in the shortest path from x to y is equal to VD. Due to the triangle inequality, d(x, y) ≤ d(x, s)+d(s, y). Therefore, d(x, y) ≤ d(v, s)+d(s, u). Since in unweighted ˜ SC . graphs d(x, y) = VD −1, the first inequality holds. By definition of VD, 2·VD ≥ (d(v, s)+1)+(d(s, u)+1) > VD t u Algorithm 1: RK algorithm 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 Input : Graph G = (V, E), , δ ∈ (0, 1) Output: Approximated BC values ∀v ∈ V foreach node v ∈ V do c̃B (v) ← 0; end VD (G)←getVertexDiameter(G); r ← (c/2 )(blog2 (VD(G) − 2)c + ln(1/δ)); for i ← 1 to r do (si , ti ) ← sampleUniformNodePair(V ); (dsi , σsi , Psi ) ← computeExtendedSSSP(G, si ); // Now one path from si to ti is sampled uniformly at random v ← ti ; p(i) ← empty list; while Psi (v) 6= {si } do sample z ∈ Psi (v) with Pr = σsi (z)/σsi (v); c̃B (z) ← c̃B (z) + 1/r; add z → p(i) ; v ← z; end end return {(v, c̃B (v)), v ∈ V } ˜ SC can be computed in O(n + m), simply by running a forward and a backward BFS from The upper bound VD any source node s. Let us now consider any directed unweighted graph G. We can define the directed acyclic graph G = (V, E) of strongly connected components (SCCs) (sometimes referred to as shrunken graph in the literature) similarly to Borassi et al. [6]. In G, the set of vertices is the set of SCCs of G and there is an edge from C ∈ V to C 0 ∈ V if and only if there is an edge in E from a node in C to a node in C 0 . (Notice that this also means that all the nodes in C 0 are reachable from the nodes in C.) More in general, the set of nodes reachable from any node in C is exactly the set of nodes in the SCCs reachable from C in G. We can now define an algorithm that computes an upper bound on VD for G. For each C in V, we compute ˜ SC (C) on VD in C (i. e., considering only paths that are contained in C) as described before an upper bound VD for strongly connected graphs. This can be done in linear time by running a backward and a forward BFS from a random source node s for each SCC and stopping the search when a visited node belongs to a different SCC from that of s. For each Ci , we know that the nodes reachable from nodes in Ci are only those in the SCCs Cj such that there is a path in G from Ci to Cj . We can compute a topological sorting {C1 , . . . , Ck } of V (that is, (Ci , Cj ) ∈ E ⇒ i < j). Let Ck be the last component in the topological ordering. Then, we know that no path from a node in Ck to any node that is not in Ck exists, which means that the node Ck in G has outdegree 0. ˜ DIR (C) the upper bound on VD restricted only to nodes that start in C (but may end somewhere We call VD ˜ DIR (Ck ) is equal to VD ˜ SC (Ck ). For the other components, we can compute it in the following else). For Ck , VD way: Starting from Ck , we process all the components in reverse topological ordering and set ˜ DIR (C) = VD ˜ DIR (C 0 ) + VD ˜ SC (C). max VD (C,C 0 )∈E ˜ DIR (C), i. e. we To get an upper bound on the whole graph, we can take the maximum over all upper bounds VD ˜ DIR := maxC∈V VD ˜ DIR (C). In other words: set VD ˜ DIR = max VD p∈P(G) 5 X Ci ∈p ˜ SC (Ci ) VD where P(G) is the set of paths in G. ˜ DIR < 2 · VD 2 . Proposition 4.1. VD ≤ VD Proof. Let us prove the first inequality. Let p = (u1 , . . . , uVD ) be a shortest path in G whose number |p| of nodes is equal to VD. Say p traverses l SCCs (C1 , ..., Cl ). Then p can be partitioned in l subpaths pi , i = 1, .., l, ˜ SC (Ci ), i = 1, ..., l. Therefore, such that pi ⊆ Ci and pi is a shortest path in Ci . By Lemma 4.1, |pi | ≤ VD P P ˜ ˜ ˜ DIR ). |p| = i=1,...,l |pi | ≤ i=1,...,l VD SC (Ci ) ≤ VD DIR (this last inequality holds by definition of VD ˜ DIR be in the worst case? Let now (C1 , ..., Cl ) denote the path in G such that How “bad” can VD P ˜ ˜ VD DIR = VD SC (Ci ). Let l be the number of components in this path. How large can l be? Since i=1,..,l there is at least one node of G in each Ci , there must be at least a shortest path of size l in G that goes ˜ SC (C). By Lemma 4.1, through the components C1 , ..., Cl . Therefore, l ≤ VD. Also, let k = maxC∈V VD k < 2 · VD(Ck ), where Ck is the SCC whose upper bound is equal to k. Clearly, k < 2 · VD. Then, by definition, 2 ˜ DIR = P ˜ VD t u i=1,..,l VD SC (Ci ) ≤ l · k < 2 · VD . The upper bound can be computed in O(n + m). Indeed, G can be computed in O(n + m), by finding the SCCs ˜ DIR (C) of the of G and scanning the edges in E. Then, the topological sorting and the accumulation of the VD different components can be done in O(|V| + |E|) = O(n + m). Notice that our new upper bound is never larger l ˜ SC(C1) VD ˜ SC(C2) VD C1 C2 ... ˜ SC(Cl ) VD Cl ˜ ˜ Figure 2: Path (C P1 , ..., Cl )˜ of the DAG G of SCCs. Each SCC Ci has its own upper bound VD SC (Ci ) and VD DIR is computed as i=1,..,l VD (C ). SC i than the size of the largest weakly connected component, the previous bound used in RK. Also, although the upper bound can be as bad as 2 · VD 2 in theory, our experimental results on real-world complex networks show that it is within a factor 4 from the exact VD and several orders of magnitude smaller than the size of the largest weakly connected components. 4.2 Undirected weighted graphs Let G be an undirected graph. For simplicity, let G be connected for now. If it is not, we compute an approximation for each connected component and take the maximum over all the approximations. Let T ⊆ G be an SSSP tree from any source node s ∈ V . Let pxy denote a shortest path between x and y in G and let pTxy denote a shortest path between x and y in T . Let |pxy | be the number of nodes in pxy and d(x, y) be the distance between x and y in G, and analogously for |pTxy | and dT (x, y). Let ω and ω be the maximum and minimum edge weights in G, respectively. Let u and v be the nodes with maximum distance from ˜ W := 1 + d(s,u)+d(s,v) . s, i. e. d(s, u) ≥ d(s, v) ≥ d(s, x) ∀x ∈ V, x 6= u. We define the VD approximation VD ω Then: ˜ W < 2 · VD · ω/ω. Proposition 4.2. VD ≤ VD Proof. To prove the first inequality, we can notice that dT (x, y) ≥ d(x, y) for all x, y ∈ V , since all the edges of T are contained in those of G. Also, since every edge has weight at least ω, d(x, y) ≥ (|pxy | − 1) · ω. Therefore, dT (x, y) ≥ (|pxy | − 1) · ω, which can be rewritten as |pxy | ≤ 1 + dT (x,y) , ω for all x, y ∈ V . Thus, VD = maxx,y |pxy | ≤ 1 + (maxx,y dT (x, y))/ω ≤ 1 + ˜ W by definition. equals VD dT (s,u)+dT (s,v) ω = 1+ d(s,u)+d(s,v) , ω where the last expression To prove the second inequality, we first notice that d(s, u) ≤ (|psu | − 1) · ω, and analogously d(s, v) ≤ ˜ W ≤ 1 + (|psu | + |psv | − 2) · ω/ω < 2 · |psu | · ω/ω, supposing that |psu | ≥ |psv | (|psv | − 1) · ω. Consequently, VD ˜ W < 2 · VD · ω/ω. without loss of generality. By definition of VD, |psu | ≤ VD. Therefore, VD t u ˜ W , we can simply compute an SSSP search from any node s, find the two nodes To obtain the upper bound VD ˜ W extends the upper bound with maximum distance and perform the remaining calculations. Notice that VD ˜ W becomes proposed for RK [25] for unweighted graphs: When the graph is unweighted and thus ω = ω, VD equal to the approximation used by RK. Complex networks are often characterized by a small diameter and in networks like coauthorship, friendship, communication networks, VD and ω/ω can be several order of magnitude smaller than the size of the largest component, though. In this case the new bound translates into a substantially improved VD approximation. 4.3 Directed weighted graphs. The upper bound for directed weighted graphs can be easily derived from ˜ SCW := 1 + d(s,u)+d(v,s) , those described in Sections 4.1 and 4.2. If G is strongly connected, we can define VD ω where s is any node, u is the node with maximum forward distance from s, v is the node with maximum backward distance and ω is the minimum edge weight. It can be easily proved that Proposition 4.2 holds also in this case, considering a forward SSSP tree from s (where distances are bounded by d(s, u)) and a backward SSSP tree (where distances are bounded by d(v, s)). For general directed weighted graphs, we can use the algorithm described in ˜ SCW (C) := 1 + d(s,u)+d(v,s) as an upper bound for each SCC C (where ω is the minimum Section 4.1 using VD c ωc edge weight in C). It is easy to prove that the resulting bound is an upper bound on VD and that it is always 2 C smaller than 2 · maxC∈G ω ω C · VD , using Propositions 4.1 and 4.2. Since it requires to compute an SSSP tree for each SCC, the complexity of computing the bound is O(m + n log n) (the other operations can be done in linear time, as described in Section 4.1). 5 Fully-dynamic approximation algorithms 5.1 Path subsitution. Our algorithms for dynamic BC approximation are composed of two phases: an initialization phase, s s which executes RK on the initial graph, and an update phase, which recomputes the approximated BC scores after a sequence − 1r of edge updates. Let us consider a batch β = {e1 , ..., ek } of edge − 1r updates ei = {ui , vi , ω(ui , vi )} applied to a graph G. Also, let us − 1r + 1r assume for the moment that β is composed of edge insertions only (or weight decreases) and β does not increase the vertex − 1r + 1r diameter of G and therefore also the number r of samples required t t by RK for the maximum error guarantee. We will discuss the general case in Section 5.2. Intuitively, our basic idea is to keep the Figure 3: Updating shortest paths and BC old sampled paths and update them only when necessary, instead scores of re-computing r shortest paths from scratch. Figure 3 shows an example to illustrate this idea: Assume several shortest paths between s and t exist, of which one has been sampled (with black nodes). An edge insertion (represented in red) shortens the distance between s and t, creating a new shorter path. Therefore, we simply subtract 1/r from each node in the old shortest path and add 1/r to each node in the new one. From this point on, we give a formal description and only consider edge insertions. We suppose the graph is undirected, but in this restricted semi-dynamic setting our results can be easily extended to weight decreases and 7 directed graphs. Let G0 = (V, E ∪ β) be the new graph, let d0s (t) denote the new distance between any node pair 0 0 (s, t) and let σst be the new number of shortest paths between s and t. Let Sst and Sst be the old and the new set 0 0 0 of shortest paths between s and t, respectively. A new set S = {p(1) , ..., p(r) } of shortest paths has to be sampled now in order to let Lemma 3.1 hold for the new configuration; in particular, the probability Pr(p0(k) = p0st ) of each 1 · σ10 . Clearly, one could rerun RK on the new shortest path p0st to be sampled must be equal to πG0 (p0st ) = n(n−1) st graph, but we can be more efficient: We recall that we are assuming that the VD and therefore also the number of samples for G0 is smaller than or equal to that of G. Given any old sampled path pst , we can keep pst if the set of shortest paths between s and t has not changed, and replace it with a new path between s and t otherwise. Then, the following lemma holds: Lemma 5.1. Let S be a set of shortest paths of G sampled according to πG . Let P be the procedure that creates S 0 by substituting each path pst ∈ S with a path p0st according to the following rules: 1. p0st = pst if 0 0 d0s (t) = ds (t) and σst = σst . 2. p0st selected uniformly at random among Sst otherwise. Then, p0st is a shortest path of G0 and the probability of any shortest path p0xy of G0 to be sampled at each iteration is πG0 (p0xy ), i.e. 1 · σ10 , k = 1, ..., r. Pr(p0(k) = p0xy ) = n(n−1) xy p0st Proof. To see that is a shortest path of G0 , it is sufficient to notice that, if d0s (t) = ds (t) and σs0 (t) = σs (t), then all the shortest paths between s and t in G are shortest paths also in G0 . Let p0xy be a shortest path of G0 between nodes x and y. Basically, there are two possibilities for p0xy 0 to be the k-th sample. Naming e1 the event {Sxy = Sxy } (the set of shortest paths between x and y does not change after the edge insertion) and e2 the complementary event of e1 , we can write Pr(p0(k) = p0xy ) as Pr(p0(k) = p0xy ∩ e1 ) + Pr(p0(k) = p0xy ∩ e2 ). Using conditional probability, the first addend can be rewritten as Pr(p0(k) = p0xy ∩ e1 ) = Pr(p0(k) = p0xy |e1 ) Pr(e1 ). As the procedure P keeps the old shortest path when e1 occurs, then Pr(p0(k) = p0xy |e1 ) = 1 1 1 1 0 Pr(p(k) = p0xy |e1 ) = n(n−1) 0 (y) , since σx (y) = σx (y) when we condition on σx (y) , which is also equal to n(n−1) σx 1 1 e1 . Therefore, Pr(p0(k) = p0xy ∩ e1 ) = n(n−1) 0 (y) · Pr(e1 ). σx 1 0 0 0 Analogously, Pr(p(k) = pxy ∩ e2 ) = Pr(p(k) = p0xy |e2 ) Pr(e2 ). In this case, Pr(p0(k) = p0xy |e2 ) = n(n−1) · σ0 1(y) , x since this is the probability of the node pair (x, y) to be the k-th sample in the initial sampling and of 1 0 . Then, Pr(p0(k) = p0xy ∩ e2 ) = n(n−1) p0xy to be selected among other paths in Sxy · σ0 1(y) · Pr(e2 ) = x 1 1 The probability Pr(p0(k) = p0xy ) can therefore be rewritten as Pr(p0(k) = p0xy ) = 0 (y) · (1 − Pr(e1 )). n(n−1) · σx 1 1 1 1 1 1 t u n(n−1) σ 0 (y) · Pr(e1 )+ n(n−1) σ 0 (y) ·(1-Pr(e1 )) = n(n−1) σ 0 (y) . x x x Since the set of paths is constructed according to πG0 , Theorem 5.1 follows directly from Lemma 3.1. Theorem 5.1. Let G = (V, E) be a graph and let G0 = (V, E ∪ β) be the modified graph after the the batch β. Let V D(G) ≥ V D(G0 ). Let S be a set of r shortest paths of G sampled according to πG and  r = c2 blog2 (VD(G) − 2)c + 1 + ln 1δ for some constants , δ ∈ (0, 1). Then, if a new set S 0 of shortest paths of G0 is built according to procedure P and the approximated values of betweenness centrality c̃0B (v) of each node v are computed as the fraction of paths of S 0 that v is internal to, then Pr(∃v ∈ V s.t. |c0B (v) − c̃0B (v)| > ) < δ, where c0B (v) is the new exact value of betweenness centrality of v after the edge insertion. Algorithm 2 shows the update procedure based on Theorem 5.1. For each sampled node pair (si , ti ), i = 1, ..., r, we first update the SSSP from si , a step which will be discussed in Sections 5.3 and 5.4. In case the distance or the number of shortest paths between si and ti has changed, a new shortest path is sampled uniformly as in RK. This means that 1r is subtracted from the score of each node in the old shortest path and the same quantity is added to the nodes in the new shortest path. On the other hand, if both distances and number of shortest paths between si and ti have not changed, nothing needs to be updated. Considering edges in a batch allows us to recompute the BC scores only once instead of doing it after each single edge update. Moreover, this gives us the possibility to use specific batch algorithms for the update of the SSSP DAGs, which process the nodes affected by multiple edges of β only once, instead of for each single edge. Differently from RK, in our dynamic algorithm we scan the neighbors every time we need the predecessors instead of storing them (Line 11). This allows us to use Θ(n) memory per sample (i. e., Θ(r · n) in total) instead of Θ(m) per sample, while our experiments show that the running time is hardly influenced. The number of samples depends on , so in theory this can be as large as |V |. However, our experiments show that relatively large values of  (e. g.  = 0.05) lead to a good ranking of nodes with high BC and for such values the number of samples is typically much smaller than |V |, making the memory requirements of our algorithms significantly less demanding than those of the dynamic exact algorithms (Ω(n2 )) for many applications. Algorithm 2: BC update after a batch β of edge insertions/weight decreases 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Input : Graph G = (V, E), source node s, number of iterations r, batch β of edge insertions/weight decreases Output: New approximated BC values ∀v ∈ V for i ← 1 to r do dold ← dsi (ti ); i σiold ← σsi (ti ); (dsi , σsi ) ←UpdateSSSP(G, dsi , σsi , β); if dsi (ti ) < dold or σsi (ti ) 6= σiold then i foreach w ∈ p(i) do c̃B (w) ← c̃B (w) − 1/r; end v ← ti ; p(i) ← empty list; Psi (v) ← {u ∈ V |(u, v) ∈ E ∧ dsi (u) + ω(u, v) = dsi (v)}; while Psi (v) 6= {si } do sample z ∈ Psi (v) with Pr = σsi (z)/σsi (v); c̃B (z) ← c̃B (z) + 1/r; add z to p(i) ; v ← z; end end end return {(v, c̃B (v)), v ∈ V } 5.2 Sampling new paths. In the previous section, we assumed that VD(G) ≥ VD(G0 ). Although many realworld networks exhibit a shrinking-diameter behavior [21], it is clearly possible that VD increases as a consequence of edge insertions/deletions or weight updates. If this happens, we can still update the old paths as described in 0 Section 5.1, but we also need to sample new additional paths, according to the probability distribution πG . The general algorithm to update the BC scores after a batch β could be described as follows: First, we update the old shortest paths as described in Section 5.1. Then, we recompute an upper bound on VD(G0 ) in linear time, using the algorithms described in Section 4. Using VD(G0 ), we compute the number of samples r(G0 ) defined in Eq. (3.1). If r(G0 ) > r(G), we sample new r(G0 ) − r(G) additional paths using RK. For undirected graphs, we also propose two fully-dynamic algorithms (one for weighted and one for unweighted graphs) to keep track of an upper bound on VD over time (Section 5.5). This saves additional time, allowing for a quick recomputation of the upper bound after the batch instead of recomputing it from scratch. 9 Notice that, if edge deletions are allowed, it is not sufficient to check whether the distance and the number of shortest paths between two nodes s and t has not changed (Line 5 of Algorithm 2), since they might remain unchanged even if the set of shortest paths is actually different. In this case, we always replace the old shortest path with a new one (we basically remove the if statement in Line 5). In the following, we present the fully-dynamic algorithms (for weighted and unweighted graphs) needed to update the shortest paths (updateSSSP in Algorithm 2) and the fully-dynamic algorithm that recomputes an upper bound on VD for undirected graphs. Finally, we show how these algorithms can be combined to obtain an even faster algorithm (than the one described in this section) for dynamic BC approximation in undirected graphs (Section 5.6). 5.3 SSSP update in weighted graphs. Our SSSP update is based on T-SWSF [3], which recomputes distances from a source node s after a batch β of weight updates (or edge insertions/deletions). For our purposes, we need two extensions of T-SWSF: an algorithm that also recomputes the number of shortest paths between s and the other nodes (updateSSSP-W) and one that also updates a VD approximation for the connected component of s (updateApprVD-W) (the latter is used in the fully-dynamic VD approximation for undirected graphs, described in Section 5.5). The VD approximation is computed as described in Sections 3 and 4.2. Thus, updateApprVD-W keeps track of the two maximum distances d0 and d00 from s and the minimum edge weight ω. We call affected nodes the nodes whose distance (or also whose number of shortest paths, in updateSSSP-W) from s has changed as a consequence of β. Basically, the idea is to put the set A of affected nodes w into a priority queue Q with priority p(w) equal to the candidate distance of w. When w is extracted, if there is actually a path of length p(w) from s to w, the new distance of w is set to p(w), otherwise w is reinserted into Q with a higher candidate distance. In both cases, the affected neighbors of w are inserted into Q. Algorithm 3 describes the SSSP update for weighted undirected graphs. The extension to directed graphs is trivial. The pseudocode updates both the VD approximation for the connected component of s and the number of shortest paths from s, so it basically includes both updateSSSP-W and updateApprVD-W. Initially, we scan the edges e = {u, v} in β and, for each e, we insert the endpoint with greater distance from s into Q (w.l.o.g., let v be such endpoint). The priority p(v) of v represents the candidate new distance of v. This is the minimum between the d(v) and d(u) plus the weight of the edge {u, v}. Notice that we use the expression “insert v into Q” for simplicity, but this can also mean update p(v) if v is already in Q and the new priority is smaller than p(v). When we extract a node w from Q, we have two possibilities: (i) there is a path of length p(w) and p(w) is actually the new distance or (ii) there is no path of length p(w) and the new distance is greater than p(w). In the first case (Lines 9 - 23), we set d(w) to p(w) and insert the neighbors z of w such that d(z) > d(w) + ω({w, z}) into Q (to check if new shorter paths to z that go through w exist). In the second case (Lines 24 - 40), there is no shortest path between s and w known anymore, so that we set d(w) to ∞. We compute p(w) as min{v,w}∈E d(v) + ω(v, w) (the new candidate distance for w) and insert w into Q. Also its neighbors could have lost one (or all of) their old shortest paths, so we insert them into Q as well. The update of ω can be done while scanning the batch and of d0 and d00 when we update d(w). The pseudocode also updates a global variable vis(w) that keeps track, for each node w, of the number of source nodes from which w is reachable. This is necessary for the fully-dynamic VD approximation and will be explained in Section 5.5. In particular, we decrease vis(w) when updating d(w) in case the old d(w) was equal to ∞ (i. e. w has become reachable) and we decrease vis(w) when we set d(w) to ∞ (i. e. w has become unreachable). We update the number of shortest paths after updating d(w), as the sum of the shortest paths of the predecessors of w (Lines 16 - 18). In updateApprVD-W, d0 and d00 are recomputed while updating the distances (Line 10) and ω is updated while scanning β (Line 5). Let |β| represent the cardinality of β and let ||A|| represent the sum of the nodes in A and of the edges that have at least one endpoint in A. Then, the following complexity derives from feeding Q with the batch and inserting into/extracting from Q the affected nodes and their neighbors. Algorithm 3: SSSP update for weighted graphs (updateSSSP-W) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 Input : Graph G = (V, E), vector d of distances from s, vector σ of number of shortest paths from s, batch β Output: New values of d(v) and σ(v) ∀v ∈ V Q ← empty priority queue; foreach e = {u, v} ∈ β, d(u) < d(v) do Q ← insertOrDecreaseKey(v, p(v) = min{d(u) + ω({u, v}), d(w)}); end ω ← min{ω, ω(e) : e ∈ β}; while there are nodes in Q do {w, p(w)} ← extractMin(Q); con(w) ← minz:(z,w)∈E d(z) + ω(z, w); if con(w) = p(w) then update d0 and d00 ; if d(w) = ∞ then vis(w) ← vis(w) + 1; end d(w) ← p(w); σ(w) ← 0; foreach incident edge (z, w) do if d(w) = d(z) + ω(z, w) then σ(w) ← σ(w) + σ(z); end if d(z) ≥ d(w) + ω(z, w) then Q ← insertOrDecreaseKey(z, p(z) = d(w) + ω(z, w)); end end end else if d(w) 6= ∞ then vis(w) ← vis(w) − 1; if vis(w)=0 then insert w into U ; end if con(w) 6= ∞ then Q ←insertOrDecreaseKey(w, p(w) = con(w)); foreach incident edge (z, w) do if d(z) = d(w) + ω(w, z) then Q ←insertOrDecreaseKey(z, p(z) = d(w) + ω(z, w)); end end d(w) ← ∞; end end end end ˜ (the number Lemma 5.2. The time required by updateApprVD-W (updateSSSP-W) to update the distances and VD of shortest paths) is O(|β| log |β| + ||A|| log ||A||). Proof. In the initial scan of the batch (Lines 2-4), we scan the nodes of the batch and insert the affected nodes into Q (or update their value). This requires at most one heap operation (insert or decrease-key) for each element of β, therefore O(|β| log |β|) time. When we extract a node w from Q, we have two possibilities: (i) con(w) = p(w) (Lines 9 - 23) or (ii) con(w) > p(w) (Lines 24 - 40). In the first case, we scan the neighbors of w and perform at most one heap operation for each of them (Lines 19 - 21). In the second case, we scan only if d(w) 6= ∞. Therefore, we can perform up to one heap operation per incident edge of w, for each extraction of w in which d(w) 6= ∞ or con(w) = p(w). How many times can an affected node w be extracted from Q with d(w) 6= ∞ or con(w) = p(w)? If the first time we extract w, con(w) is equal to p(w) (case (i)), then the final value of d(w) is 11 reached and w is not inserted into Q anymore. If the first time we extract w, con(w) is greater than p(w) (case (ii)), then w can be inserted into the queue again. However, its distance is set to ∞ and therefore no additional operations are performed, until d(w) becomes less than ∞. But this can happen only in case (i), after which d(w) reaches its final value. To summarize, each affected node w can be extracted from Q with d(w) 6= ∞ or con(w) = p(w) at most twice and, every time this happens, at most one heap operation per incident edge of w is performed. The complexity is therefore O(|β| log |β| + ||A|| log ||A||). t u 5.4 SSSP update in unweighted graphs. For unweighted graphs, we basically replace the priority queue Q of updateApprVD-W and updateSSSP-W with a list of queues. Each queue represents a level (distance from s) from 0 (which only the source belongs to) to the maximum distance d0 . The levels replace the priorities and also in this case represent the candidate distances for the nodes. Algorithm 4 describes the pseudocode for unweighted graphs. As in Algorithm 3, we first scan the batch (Lines 3 - 5) and insert the nodes in the queues. Then (Lines 6 - 44), we scan the queues in order of increasing distance from s, in a fashion similar to that of a priority queue. In order not to insert a node in the queues multiple times, we use colors: Initially we set all the nodes to white and then we set a node w to black only when we find the final distance of w (i. e. when we set d(w) to k) (Line 15). Black nodes extracted from a queue are then skipped (Line 10). At the end we reset all nodes to white. The replacement of the priority queue with the list of queues decreases the complexity of the SSSP update algorithms for unweighted graphs, which we call updateApprVD-U and updateSSSP-U, in analogy with the ones for weighted graphs. ˜ (the number Lemma 5.3. The time required by updateApprVD-U (updateSSSP-U) to update the distances and VD of shortest paths) is O(|β| + ||A|| + dmax ), where dmax is the maximum distance from s reached during the update. Proof. The complexity of the initialization (Lines 3 - 5) of Algorithm 4 is O(|β|), as we have to scan the batch. In the main loop (Lines 6 - 44), we scan all the list of queues, whose final size is dmax . Every time we extract a node w whose color is not black, we scan all the incident edges, therefore this operation is linear in the number of neighbors of w. If the first time we extract w (say at level k) con(w) is equal to k, then w will be set to black and will not be scanned anymore. If the first time we extract w, con(w) is instead greater than k, w will be inserted into the queue at level con(w) (if con(w) < ∞). Also, other inconsistent neighbors of w might insert w in one of the queues. However, after the first time w is extracted, its distance is set to ∞, so its neighbors will not be scanned unless con(w) = k, in which case they will be scanned again, but for the last time, since w will be set to black. To summarize, each affected node and its neighbors can be scanned at most twice. The complexity of the algorithm is therefore O(|β| + kAk + dmax ). t u 5.5 Fully-dynamic VD approximation. The algorithm keeps track of a VD approximation for an undirected graph G, i. e. for each connected component of G. It is composed of two phases. In the initialization, we compute an SSSP from a source node si for each connected component Ci . During the SSSP search from si , we also ˜ i for Ci , as described in Sections 3 and 4.2. In the update, we recompute the compute a VD approximation VD SSSPs and the VD approximations with updateApprVD-W (or updateApprVD-U). Since components might split or merge, we might need to compute new approximations, in addition to update the old ones. To do this, for each node, we keep track of the number vis(v) of times it has been visited. This way we discard source nodes that have already been visited and compute a new approximation for components that have become unvisited. Algorithm 5 describes the initialization. Initially, we put all the nodes in a queue and compute an SSSP from the nodes we extract (Line 18). During the SSSP search, we increase the number of visits vis(v) for all the nodes we traverse (Line 24). When extracting the nodes, we skip those that have already been visited (Line 8): this avoids computing multiple approximations for the same component. In the update (Algorithm 6), we recompute the SSSPs and the VD approximations with updateApprVD- Algorithm 4: SSSP update for unweighted graphs (updateSSSP-U) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 Input : Graph G = (V, E), vector d of distances from s, vector σ of number of shortest paths from s, batch β Output: New values of d(v) and σ(v) ∀v ∈ V Assumption: color(w) = white ∀w ∈ V ; Q[] ← array of empty queues; foreach e = {u, v} ∈ β, d(u) < d(v) do k ← d(v) + 1; enqueue v → Q[k]; end k ← 1; while there are nodes in Q[j], j ≥ k do while Q[k] 6= ∅ do dequeue w ← Q[k]; if color(w) = black then continue; con(w) ← minz:(z,w)∈E d(z) + 1; if con(w) = k then update d0 and d00 ; if d(w) = ∞ then vis(w) ← vis(w) + 1; d(w) ← k; σ(w) ← 0; color(w) ← black; foreach incident edge (z, w) do if d(w) = d(z) + 1 then σ(w) ← σ(w) + σ(z); end if d(z) > k then enqueue z → Q[k + 1]; end end end else if d(w) 6= ∞ then d(w) ← ∞; vis(w) ← vis(w) − 1; if vis(w)=0 then insert w into U ; end if con(w) 6= ∞ then enqueue w → Q[con(w)]; foreach incident edge (z, w) do if d(z) > k then enqueue z → Q[k + 1]; end end end end end end k ← k + 1; end Set to white all the nodes that have been in Q; 13 W (or updateApprVD-U) (Line 7). Since components might split, we might need to add VD approximations for some new subcomponents, in addition to recomputing the old ones. Also, if components merge, we can discard the superfluous approximations. To do this, we update vis(v) for each node within updateApprVD-W (or updateApprVD-U). Before the update, all the nodes are visited exactly once. While updating an SSSP from si , we increase (decrease) by one vis(v) of the nodes v that become reachable (unreachable) from si . This way we can skip the update of the SSSPs from nodes that have already been visited (Line 8). After the update, for all nodes v that have become unvisited (vis(v) = 0), we compute a new VD approximation from scratch (Lines 11 - 18). ˜ update in the single components, The complexity of the update of the VD approximation derives from the VD using updateApprVD-W and updateApprVD-U. Pnc ||A(i) || log ||A(i) ||) in Theorem 5.2. The time required to update the VD approximation is O(nc ·|β| log |β|+ i=1 Pnc (i) (i) weighted graphs and O(nc · |β| + i=1 ||A || + dmax ) in unweighted graphs, where nc is the number of components in G before the update and A(i) is the sum of affected nodes in Ci and their incident edges. Proof. In the first part (Lines 2 - 9 of Algorithm 6), we update an SSSP with updateApprVD-W or updateApprVDU for each source node si such that vis(si ) is not greater than 1. Therefore the complexity of the first part is Pnc Pnc (i) O(nc · |β| log |β| + i=1 ||A(i) || log ||A(i) ||) in weighted graphs and O(nc · |β| + i=1 ||A(i) || + dmax ) in unweighted, by Lemmas 5.2 and 5.3. Only some of the affected nodes (those whose distance from a source node becomes ∞) Pnc are inserted into the queue U . Therefore the cost of scanning U in Lines 11 - 18 is O( i=1 ||A(i) ||). New SSSP searches are computed for new components that are not covered by the existing source nodes anymore. However, also such searches involve only the affected nodes and each affected node (and its incident edges) is scanned at Pnc most once during the search. Therefore, the total cost is O(nc · |β| log |β| + i=1 ||A(i) || log ||A(i) ||) for weighted Pnc (i) graphs and O(nc · |β| + i=1 ||A(i) || + dmax ) for unweighted graphs. t u Lemma 5.4. At the end of Algorithm 5, vis(v) = 1 for all v ∈ V , and exactly one VD approximation is computed for each connected component of G. Proof. Let v be any node. Then v must be scanned by at least one source node si in the while loop (Lines 6 - 13): In fact, either v is visited by some si before v is extracted from U , or vis(v) = 0 at the moment of the extraction and v becomes a source node itself. This implies that vis(v) ≥ 1, ∀v ∈ V . On the other hand, vis(v) cannot be greater than 1. In fact, let us assume by contradiction that vis(v) > 1. This means that there are at least two source nodes si and sj (i < j, w.l.o.g.) that are in the same connected component as v. Then also si and sj are in the same connected component and sj is visited during the SSSP search from si . Then vis(sj ) = 1 before sj is extracted from U and sj cannot be a source node. Therefore, vis(v) is exactly equal to 1 for each v ∈ V , which means that exactly one VD approximation is computed for each connected component of G. t u Proposition 5.1. Let C 0 = {C10 , ..., Cn0 0c } be the set of connected components of G after the update. Algorithm 6 updates or computes exactly one VD approximation for each Ci0 ∈ C 0 . Proof. Let C = {C1 , ..., Cnc } be the set of connected components before the update. Let us consider three basic cases (then it is straightforward to see that the proof holds also for combinations of these cases): (i) Ci ∈ C is also a component of C 0 , (ii) Ci ∈ C and Cj ∈ C merge into one component Ck0 of C 0 , (iii) Ci ∈ C splits into two components Cj0 and Ck0 of C 0 . In case (i), the VD approximation of Ci is updated exactly once in the for loop (Lines 2 - 9). In case (ii), (assuming i < j, w.l.o.g.) the VD approximation of Ck0 is updated in the for loop from the source node si ∈ Ci . In its SSSP search, si visits also sj ∈ Cj , increasing vis(sj ). Therefore, sj is skipped and exactly one VD approximation is computed for Ck0 . In case (iii), the source node si ∈ Ci belongs to one of the components (say Cj0 ) after the update. During the for loop, the VD approximation is computed for Cj0 via si . Also, for all the nodes v in Ck0 , vis(v) is set to 0 and v is inserted into U . Then some source node s0k ∈ Ck0 must be extracted from U in Line 12 and a VD approximation is computed for Ck0 . Since all the nodes in Ck0 are set to visited during the search, no other VD approximations are computed for Ck0 . t u Algorithm 5: Dynamic VD approximation (initialization) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 Input : Graph G = (V, E) Output: Upper bound on VD U ← []; foreach node v ∈ V do vis(v) ← 0; insert v into U ; end i ← 1; while U 6= ∅ do extract s from U ; if vis(s) = 0 then si ← s; ˜ i ← initApprVD(G, si ); VD i ← i + 1; end end nC ← i − 1; ˜ ← maxi=1,...,n VD ˜ i; VD C ˜ return VD; ˜ and adds 1 to vis(v) of the nodes it visits // initApprVD computes VD Function initApprVD(G, s) SSSP(G, s); d0 ← max{d(s, u)|u ∈ V, d(u, v) 6= ∞}; d00 ← max{d(s, v)|v ∈ V, v 6= u, d(s, v) 6= ∞}; ω ← min{ω(x, y)|(x, y) ∈ E}; ˜ ← 1 + d0 +d00 ; VD ω foreach node w ∈ V s.t. d(s, w) 6= ∞ do vis(w) ← vis(w) + 1; end ˜ return VD; 5.6 Combined dynamic BC approximation. Let G be an undirected graph with nc connected components. In Section 5.2, we described an algorithm to update the betweenness approximations in fully-dynamic graphs. If ˜ after a batch, instead the graph is undirected, we can use the fully dynamic VD approximation to recompute VD ˜ (and of recomputing it from scratch. Then, we could update the r sampled paths with updateSSSP and, if VD therefore r) increases, we could sample new paths. However, since updateSSSP and updateApprVD share most of the operations, we can “merge” them and update at the same time the shortest paths from a source node s and the VD approximation for the component of s. We call this hybrid function updateSSSPVD. Instead of storing and updating nc SSSPs for the VD approximation and r SSSPs for the BC scores, we recompute a VD approximation for each of the r samples while recomputing the shortest paths with updateSSSPVD. This way we do not need to compute an additional SSSP for the components covered by the r sampled paths (i. e. the components in which the paths lie), saving time and memory. Only for components that are not covered by any of them (if they exist), we compute and store a separate VD approximation. We refer to such components as R0 (and to |R0 | as r0 ). In the initialization (Algorithm 7), we first compute the r SSSP, like in RK (Lines 4 - 18). However, we also check which nodes have been visited, as in Algorithm 5. While we compute the r SSSPs, in addition to the distances and number of shortest paths, we also compute a VD approximation for each of the r source nodes and increase vis(v) of all the nodes we visit during the sources with initApprVD (Line 8). Since it is possible that the r shortest paths do not cover all the components of G, we compute an additional VD approximation for nodes in the unvisited components, like in Algorithm 5 (Lines 21 - 28). Basically we can divide the SSSPs into two sets: 15 Algorithm 6: Dynamic VD approximation (updateApprVD) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 Input : Graph G = (V, E), vector vis Output: New VD approximation U ← []; foreach si do if vis(si ) > 1 then ˜ i ; decrease nC ; remove si and VD end else // updateApprVD updates vis, inserts all v for which vis(v) = 0 into U and recomputes a VD ˜ i approximation VD ˜ i ← updateApprVD(G, si ) ; VD end end i ← nC ; while U 6= ∅ do extract s0 from U ; if vis(s0 ) = 0 then s0i ← s0 ; ˜ i ← initApprVD(G, s0 ); VD i i ← i + 1; nC ← nC + 1; end end reset vis(v) to 1 for nodes v such that vis(v) > 1; ˜ ← maxi=1,...,n VD ˜ i; VD C ˜ return VD the set R of SSSPs used to compute the r shortest paths and the set R0 of SSSPs used for a VD approximation in the components that were not scanned by the initial R SSSPs. We call r0 the number of the SSSPs in R0 . The BC update after a batch is described in Algorithm 8. First (Lines 2 - 19), we recompute the shortest paths like in Algorithm 2: we update the SSSPs from each source node s in R and we replace the old shortest path with a new one (subtracting 1/r from the nodes in the old shortest path and adding 1/r to those in the new shortest path). To update the SSSPs, we use the fully-dynamic updateSSSPVD that updates also the VD approximation and keeps track of the nodes that become unvisited. Then (Lines 24 - 31), we add a new SSSP to R0 for each component that has become unvisited (by both R and R0 ). After this, we have at least a VD approximation for each component of G. We take the maximum over all these approximations and recompute the number of samples r (Lines 32 - 33). If r has increased, we need to sample new paths and therefore new SSSPs to add to R. Finally, we normalize the BC scores, i. e. we multiply them by the old value of r divided by the new value of r (Line 37). We refer to the algorithm for unweighted graphs as DA and the one for weighted as DAW. The difference between DA and DAW is the way the SSSPs and the VD approximation are updated: in DA we use updateApprVD-U and in DAW updateApprVD-W. Theorem 5.3. Algorithm 8 preserves the guarantee on the maximum absolute error, i. e. naming c0B (v) and c̃0B (v) the new exact and approximated BC values, respectively, Pr(∃v ∈ V s.t. |c0B (v) − c̃0B (v)| > ) < δ. Proof. Let G be the old graph and G0 the modified graph after the batch of edge updates. Let p0xy be a shortest path of G0 between nodes x and y. To prove the theoretical guarantee, we need to prove that the probability 1 1 of any sampled path p0(i) is equal to p0xy (i. e. that the algorithms adds 1/r0 to the nodes in p0xy ) is n(n−1) 0 (y) . σx Algorithm 8 replaces the first r shortest paths with other shortest paths p0(1) , ..., p0(r) between the same node pairs 1 1 (Lines 12 - 18) using Algorithm 2, for which we already proved that Pr(p0(k) = p0xy ) = n(n−1) 0 (y) (Lemma 5.1). σx The additional ∆r shortest paths (Line 35) are recomputed from scratch with RK, therefore also in this case 1 1 Pr(p0(k) = p0xy ) = n(n−1) t u σ 0 (y) by Lemma 7 of [25]. x Algorithm 7: BC initialization 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 Input : Graph G = (V, E), source node s, number of iterations r, batch β Output: Approximated BC values ∀v ∈ V foreach node v ∈ V do c̃B (v) ← 0; vis(v) ← 0; end ˜ ←getApproxVertexDiameter(G); VD ˜ − 2)c + ln(1/δ)); r ← (c/2 )(blog2 (VD for i ← 1 to r do (si , ti ) ← sampleUniformNodePair(V ); ˜ i ← initApprVD(G, si ,); VD v ← ti ; p(i) ← empty list; Psi (v) ← {z : {z, v} ∈ E ∩ dsi (v) = dsi (z) + ω({z, v})}; while Psi (v) 6= {si } do sample z ∈ Psi (v) with probability σsi (z)/σsi (v); c̃B (z) ← c̃B (z) + 1/r; add z → p(i) ; v ← z; Psi (v) ← {z : {z, v} ∈ E ∩ dsi (v) = dsi (z) + ω({z, v})}; end end U ←V; i ← r + 1; while U 6= ∅ do extract s0 from U ; if vis(s0 ) = 0 then s0i ← s0 ; ˜ i ← initApprVD(G, s0 ); VD i i ← i + 1; end end r0 ← r − i − 1; return {(v, c̃B (v)) : v ∈ V } 17 Algorithm 8: Dynamic update of BC approximation (DA) 40 Input : Graph G = (V, E), source node s, number of iterations r, batch β Output: New approximated BC values ∀v ∈ V U ← []; for i ← 1 to r do dold ← dsi (ti ); i σiold ← σsi (ti ); // updateSSSPVD updates vis, inserts all v : vis(v) = 0 into U and updates the VD approximation ˜ i ← updateSSSPVD(G, si , β); VD // we replace the shortest path between si and ti foreach w ∈ p(i) do c̃B (w) ← c̃B (w) − 1/r; end v ← ti ; p(i) ← empty list; Psi (v) ← {z : {z, v} ∈ E ∩ dsi (v) = dsi (z) + ω({z, v})}; while Psi (v) 6= {si } do sample z ∈ Psi (v) with probability = σsi (z)/σsi (v); c̃B (z) ← c̃B (z) + 1/r; add z to p(i) ; v ← z; Psi (v) ← {z : {z, v} ∈ E ∩ dsi (v) = dsi (z) + ω({z, v})}; end end for i ← r + 1 to r + r0 do ˜ i ← updateApprVD(G, si , β); VD end i ← r + r0 + 1; while U 6= ∅ do extract s0 from U ; if vis(s0 ) = 0 then s0i ← s0 ; ˜ i ← initApprVD(G, s0 ); VD i i ← i + 1; r0 ← r0 + 1; end end // compute the maximum over all the VD i computed by updateApprVD ˜ ← maxi=1,...,r+r0 VD ˜ i; VD 2 ˜ rnew ← (c/ )(blog2 (VD − 2)c + ln(1/δ)); if rnew > r then sample new paths; foreach v ∈ V do c̃B (v) ← c̃B (v) · r/rnew end r ← rnew ; end 41 return {(v, c̃B (v)) : v ∈ V } 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 5.7 Complexity of the dynamic BC algorithms. In this section we presented different algorithms for updating BC approximations after batches of edge updates. Algorithm 2 can be used on graphs for which we can be sure that the vertex diameter cannot increase after a batch of edge updates. This includes, for example, unweighted connected graphs on which only edge insertions are allowed. We refer to the unweighted version of this algorithm as IA (incremental approximation) and to the weighted version as IAW (incremental approximation weighted). On general directed graphs, we can use the algorithms described in Section 5.2. We name the unweighted version DAD (dynamic approximation directed) and the weighted one DADW. Finally, for undirected graphs, we can use the optimized algorithms presented in Section 5.6 (Algorithm 8), to which we refer as DA and DAW. Theorem 5.4 presents the complexities of all the BC update algorithms. In the following, we name ||A(i) || the sum of affected nodes and their incident edges in the ith sampled SSSP. We also name r the number of samples. In case we need to sample new additional paths after the update (in DAD, DADW, DA and DAW), we refer to the difference between the value of r before and after the batch as ∆r. In DA and DAW, we call r0 the number of additional samples necessary for the VD approximation. Theorem 5.4. Given a graph G = (V, E) with n nodes and m edges, the time required by the different algorithms to update the BC approximations after a batch β are the following: Pr (i) (i) IA: O(r · |β| + i=1 (||A(i) || + dmax ) Pr (ii) IAW: O(r · |β| log |β| + i=1 ||A(i) || log ||A(i) ||) Pr (i) (iii) DAD: O(r · |β| + i=1 (||A(i) || + dmax ) + (∆r + 1)(n + m)) Pr (iv) DADW: O((r · |β| log |β| + i=1 ||A(i) || log ||A(i) || + (∆r + 1)(n log n + m)) Pr+r0 (i) (v) DA: O((r + r0 )|β| + i=1 (||A(i) || + dmax ) + ∆r(n + m)) Pr+r0 (vi) DAW: O((r + r0 )|β| log |β| + i=1 ||A(i) || log ||A(i) || + ∆r(n log n + m)) Proof. We prove each case separately. (i) IA updates each sampled path with updateSSSP-U. Therefore, the total complexity is the sum of the times Pr (i) required to update each of the r paths, i. e. O(r · |β| + i=1 (||A(i) || + dmax ). (ii) Same as (i), with the only difference that we use updateSSSP-W for weighted graphs. (iii) In DAD, we need to update the existing r samples, exactly as in IA. In addition to that, we might need to sample new ∆r additional paths using a BFS, whose complexity is O(n + m). Also, we need to recompute the upper bound on VD, whose complexity is also O(n + m) (see Section 4.1). Therefore, in this case we have to add an additional O((∆r + 1)(n + m)) term to the complexity of IA. (iv) Similarly to (iii), we need to sample ∆r additional paths, but in weighted graphs the cost of a SSSP is O(n log n + m). Also the VD approximation described in Section 4.3 requires O(n log n + m) time. (v) Let ∆r0 be the difference between the values of r0 before and after the batch. After processing β, we might need to sample new paths for the betweenness approximation (∆r > 0) and/or sample paths in new components that are not covered by any of the sampled paths (∆r0 > 0). Then, the complexity for Pr (i) the betweenness approximation update is O(r · |β| + i=1 (||A(i) || + dmax )) + O(∆r(n + m)). The VD 0 P (i) r update requires O(r0 · |β| + i=1 (||A(i) || + dmax )) to update the VD approximation in the already covered P∆r components and i=1 (|Vi | + |Ei |) for the new ones, where Vi and Ei are nodes and edges of the ith component, respectively. From this derives the total complexity. 19 Graph ca-GrQc p2p-Gnutella09 ca-HepTh PGPgiantcompo as-22july06 Type coauthorship file sharing coauthorship social / web of trust internet Nodes 5 242 8 114 9 877 10 680 22 963 Edges 14 496 26 013 25 998 24 316 48 436 Type Unweighted, Unweighted, Unweighted, Unweighted, Unweighted, Undirected Directed Undirected Undirected Undirected Table 1: Overview of small real-world networks used in the experiments. Graph repliesDigg emailSlashdot emailLinux facebookPosts emailEnron facebookFriends arXivCitations englishWikipedia Type communication communication communication communication communication friendship coauthorship hyperlink Nodes 30,398 51,083 63,399 46,952 87,273 63,731 28,093 1,870,709 Edges 85,155 116,573 159,996 183,412 297,456 817,035 3,148,447 36,532,531 Type Weighted Weighted Weighted Weighted Weighted Unweighted Unweighted Unweighted Table 2: Overview of real dynamic graphs used in the experiments, taken from http://konect.uni-koblenz.de/. (vi) Same as (v), using updateSSSP-W, approxVD-W. t u ˜ does not increase, ∆r = 0 and the complexities of DA and DAD (DAW and DADW, respectively) Notice that, if VD are the same as the only-incremental algorithm IA (IAW, respectively). This case includes, for example, connected graphs subject to a batch of only edge insertions, or any batch that neither splits the graph into more components nor increases VD. Also, notice that in the worst case the complexity can be as bad as recomputing from scratch. However, no dynamic SSSP (and so probably also no BC approximation) algorithm exists that is faster than recomputation on all graphs. 6 Experiments Implementation and settings. For an experimental comparison, we implemented our six approaches IA, IAW, DAD, DADW, DA, DAW, as well as the static approximation RK [25]. In addition to that, we implemented the static exact BA and the dynamic exact algorithms GMB [16] and KDB [18], which were shown to have the best speedups on unweighted graphs. For a comparison on weighted graphs, we also implemented the algorithm by Nasre et al. [22] (NPR). In the implementation of RK, we used the optimization proposed in [25], stopping all the SSSP searches once the target node has been found. Also, we computed the number of samples using our new bounds on VD presented in Section 4. We implemented all algorithms in C++, building on the open-source NetworKit framework [27]. In all experiments we fix δ to 0.1 while the error bound  varies. The machine we employ is used for its 256 GB RAM – the comparison to exact approaches requires a substantial amount of memory. Of the machine’s 2 x 8 Intel(R) Xeon(R) E5-2680 cores running at 2.7 GHz we use only one; all computations are sequential to make the comparison to previous work more meaningful. Data sets. We use both real-world and synthetic networks. For our experiments on the accuracy and for comparison with the exact algorithms, we use relatively small networks, on which also the non-scalable algorithms can be executed. These networks are summarized in Table 1 and are publicly available from the collection compiled for the 10th DIMACS Challenge [2] (http://www.cc.gatech.edu/dimacs10/downloads.shtml) and from the SNAP collection (http://snap.stanford.edu). Due to a shortage of actual dynamic networks in this size range, we simulate dynamics by removing a small fraction of random edges and adding them back in batches. We also use synthetic networks obtained with the Dorogovtsev-Mendes generator, a simple model for networks 5.5 5.0 4.5 4.0 3.5 3.0 2.5 2.0 1.5 1.0 0 ² =0.01 ² =0.05 ² =0.1 2000 Relative rank error Relative rank error with power-law degree distribution [11]. To compare the running times of the scalable algorithms (RK and our dynamic algorithms), we use real dynamic networks, taken from The Koblenz Network Collection (KONECT) [19] and summarized in Table 2. All the edges of the KONECT graphs are characterized by a time of arrival. In case of multiple edges between two nodes, we extract two versions of the graph: one unweighted, where we ignore additional edges, and one weighted, where we replace the set Est of edges between two nodes with an edge of weight 1/|Est | (more tightly coupled nodes receive a smaller distance). In our experiments, we let the batch size vary from 1 to 1024 and for each batch size, we average the running times over 10 runs. Since the networks do not include edge deletions, we implement additional simulated dynamics. In particular, we consider the following experiments. (i) Real dynamics. We remove the x edges with the highest timestamp from the network and we insert them back in batches, in the order of timestamps. (ii) Random insertions and deletions. We remove x edges from the graph, chosen uniformly at random. To create batches of both edge insertions and deletions, we add back the deleted edges with probability 1/2 and delete other random edges with probability 1/2. (iii) Random weight changes. In weighted networks, we choose x edges uniformly at random and we multiply their weight by a random value in the interval (0, 2). To study the scalability of the methods, we also use synthetic graphs obtained with a generator based on a unit-disk graph model in hyperbolic geometry [28], where edge insertions and deletions are obtained by moving the nodes in the hyperbolic plane. The networks produced by the model were shown to have many properties of real complex networks, like small diameter and power-law degree distribution (for details and references the interested reader is referred to von Looz et al. [28]). We generate seven networks, with |E| ranging from about 2 · 104 to about 2 · 107 and |V | approximately equal to |E|/10. We also compare our new upper bound on VD for directed graphs presented in Section 4.1 with the one used in RK. For this, we use directed real-world graphs of different sizes taken from the SNAP collection. 4000 6000 Node rank 8000 10000 2.4 2.2 2.0 1.8 1.6 1.4 1.2 1.0 0 ² =0.01 ² =0.05 ² =0.1 20 40 Node rank 60 80 100 Figure 4: Relative rank error on PGPgiantcompo for nodes ordered by rank. Left: relative errors of all nodes. Right: relative errors of the 100 nodes with highest betweenness. Graph max. error ( = 0.1) max. error ( = 0.05) max. error ( = 0.01) avg. error ( = 0.1) avg. error ( = 0.05) avg. error ( = 0.01) ca-GrQc 1.70e-02 9.12e-03 1.67e-03 4.55e-04 2.42e-04 4.63e-05 ca-HepTh 1.69e-02 7.62e-03 1.41e-03 3.87e-04 2.10e-04 4.29e-05 PGPgiantcompo 3.10e-02 1.38e-02 2.99e-03 4.56e-04 2.54e-04 5.10e-05 as-22july06 3.22e-02 1.60e-02 3.45e-03 8.55e-05 5.35e-05 1.33e-05 p2p-Gnutella09 1.56e-02 6.55e-03 1.23e-03 5.92e-04 3.15e-04 6.55e-05 Table 3: Maximum and average absolute errors on real networks for different values of  (δ = 0.1). The values are averaged over 10 runs. 21 6.1 Accuracy. We consider the accuracy of the approximated centrality scores both in terms of absolute error and, more importantly, the preservation of the ranking order of nodes. Since we only replace the samples without changing their number, our dynamic algorithm has exactly the same accuracy as RK. The authors of [25] study the behavior of RK also experimentally, considering the average and maximum estimation error on a small set of real graphs. We study the experimental errors on additional graphs. For our tests we use the networks summarized in Table 1 and Dorogovtsev-Mendes graphs of several sizes. Our results confirm those of [25] in the sense that the measured absolute errors are always below the guaranteed maximum error  and the measured average error is often orders of magnitude smaller than . Table 3 shows the measured errors for the real networks. We also study the relative rank error introduced by Geisberger et al. [14] (i. e. max{ρ, 1/ρ}, denoting ρ the ratio between the estimated rank and the true rank), which we consider the most relevant measure of the quality of the approximations. Figure 4 shows the results for PGPgiantcompo, a similar trend can be observed on our other test instances as well. On the left, we see the errors for the whole set of nodes (ordered by exact rank) and, on the right, we focus on the top 100 nodes. The straight lines in the plot on the left correspond to nodes with betweenness 0, which are therefore undistinguishable. The plots show that for a small value of  (0.01), the ranking is very well preserved over all the positions. With higher values of , the rank error of the nodes with low betweenness increases, as they are harder to approximate. However, the error remains small for the nodes with highest betweenness, the most important ones for many applications. 6.2 New upper bound on VD for directed graphs. We compute the new upper bound on VD for directed graphs presented in Section 4.1 and compare it with the upper bound used in RK [25], i. e. the size of the largest weakly connected component. All the networks used in the experiment are real directed graphs. Since finding VD exactly would be expensive in most of the graphs we used, we also compute a lower bound on VD, by sampling nodes in the graph, computing their eccentricity (i. e., the maximum distance reachable from the node), and ˜ and the one used adding 1 to it. In Table 4, we report this lower bound (VD ? ), our new upper bound (VD) ˜ ˜ ˜ RK and never in RK (VD RK ). The results show that VD is always several orders of magnitude smaller than VD ? more than a factor 4 from the lower bound VD (and therefore also from VD). This difference is mitigated by the logarithm in the number of samples required for the approximation (see Eq. (3.1)). However, Table 4 shows ˜ is almost always more than 210 times smaller than VD ˜ RK , resulting in at least 10 times less samples that VD required for the theoretical guarantee. Graph p2p-Gnutella24 soc-Epinions1 slashdot081106 twitter-comb slashdot090216 amazon0302 email-EuAll Nodes 26 518 75 879 77 356 81 306 81 870 262 111 265 214 Edges 65 369 508 837 516 575 1 768 149 545 671 1 234 877 420 045 VD ? 20 13 14 9 14 71 9 ˜ VD 47 41 39 34 40 183 23 ˜ RK VD 26 498 75 877 77 349 81 306 81 866 262 111 224 832 ˜ and the one proposed in RK, VD ˜ RK ) Table 4: Lower bound on VD (VD ? ) and upper bounds (our new bound VD on real-world networks. 6.3 Running times. In this section, we discuss the running times of all the algorithms, the speedups of the exact incremental approaches (GMB, KDB) on BA and the speedups of our algorithms on RK. (Note that the term speedup is used in this paper to compare different algorithms, not sequential vs parallel execution.) In all of our tests on relatively small graphs (Table 1), KDB performs worse than GMB, therefore we only report the results of GMB. Figure 5 shows the behavior of the four algorithms on PGPgiantcompo. Since the graph is connected and we are considering batches of edge insertions, IA and DA are identical in this case (therefore in Figure 5 we refer to our algorithm as IA). On the left, the figure shows the running times of the four algorithms, whereas the plot on the right reports the speedups of GMB on BA and of IA on RK. GMB can only process edges one by one, therefore its running time increases linearly with the batch size, becoming slower than the static algorithm already with a batch size of 64. Our algorithm shows much better speedups and proves to be significantly faster than recomputation even with a batch of size 1024. The reasons for our high speedup are mainly two: First, we process the updates in a batch, processing only once the nodes affected by multiple edge insertions. Secondly, our algorithm does not need to recompute the dependencies, in contrast to all dynamic algorithms based on BA (i. e. all existing dynamic exact algorithms). For each SSSP, the dependencies need to be recomputed not only for nodes whose distance or number of shortest paths from the source has changed after the edge insertion(s), but also for all the intermediate nodes in the old shortest paths, even if their distance and number of shortest paths are not affected. This number is significantly higher, since for every node which changes its distance or increases its number of shortest paths, the dependencies of all the nodes in all the old shortest paths are affected. Results on the other small graphs and on synthetic Dorogovtsev-Mendes graphs are analogous to those shown in Figure 5. Figure 6 (left) shows the speedups of IA on RK and of GMB on BA, averaged over 10 synthetic graphs. We see in Figure 6 (right) that our algorithm is significantly faster than GMB, and the speedup of IA on GMB clearly increases with the batch size. We also compared NPR with IAW on small weighted graphs. Since NPR performs very poorly on all tested instances, we do not report the results here. However, they can be found in our conference paper [5]. GMB and NPR also have very high memory requirements (Θ(n2 + mn)), which makes the algorithms unusable on networks with more than a few thousand edges. The memory requirement is the same also for all other existing dynamic algorithms, with the exception of KDB, which requires Θ(n2 ) memory, still impractical for large networks. 4 3 10 3 S.A. (RK) S.E. (BA) Approximation Exact 2 10 Speed-up Time [s] 10 10 IA I.E. (GMB) 2 10 1 10 1 10 0 10 0 10 0 0 1 2 4 8 16 32 64 128 256 512 1024 1 Batch size 2 4 8 16 32 64 128 256 512 1024 Batch size Figure 5: Running times and speedups on PGPgiantcompo, with  = 0.05 and with batches of different sizes. Left: Running times of static exact (BA), static approximation (RK), incremental exact (GMB) and our incremental approximation IA. Right: Speedups of GMB on BA (exact) and of IA on RK (approximation). Since the exact algorithms are not scalable, for the comparison on larger networks (Table 2) we used only RK and our algorithms. Figure 7 (left) reports the speedups of DA on RK in real graphs using real dynamics. Although some fluctuations can be noticed, the speedups tend to decrease as the batch size increases. We can attribute fluctuations to two main factors: First, different batches can affect areas of G of varying sizes, influencing also the time required to update the SSSPs. Second, changes in the VD approximation can require to sample new paths and therefore increase the running time of DA (and DAW). Nevertheless, DA is significantly faster than recomputation on all networks and for every tested batch size. Analogous results are reported in Figure 8 (left) for random dynamics. Table 5 summarizes the running times of DA and its speedups on RK with batches of size 1 and 1024 in unweighted graphs, under both real and random dynamics. Even on the larger graphs 23 4 3 10 10 Approximation Exact 3 10 2 Speed-up Speed-up 10 1 10 0 10 2 10 1 10 0 10 0 0 1 2 4 8 16 32 64 128 256 512 1024 1 2 4 8 16 Batch size 32 64 128 256 512 1024 Batch size Figure 6: Speedups on Dorogovtsev-Mendes synthetic graphs (m = 40k), with  = 0.05 with batches of different sizes. Left: comparison of the speedups of GMB on BA (exact) and of IA on RK (approximation). Right: speedups of IA on GMB. Real Time [s] Speedups |β| = 1 |β| = 1024 |β| = 1 |β| = 1024 0.078 1.028 76.11 5.42 0.043 1.055 219.02 9.91 0.049 1.412 108.28 3.59 0.023 1.416 527.04 9.86 0.368 1.279 83.59 13.66 0.447 1.946 94.23 18.70 0.038 0.186 2287.84 400.45 1.078 6.735 3226.11 617.47 Graph repliesDigg emailSlashdot emailLinux facebookPosts emailEnron facebookFriends arXivCitations englishWikipedia Random Time [s] Speedups |β| = 1 |β| = 1024 |β| = 1 |β| = 1024 0.008 0.832 94.00 4.76 0.038 1.151 263.89 28.81 0.051 2.144 72.73 1.33 0.015 1.520 745.86 8.21 0.203 1.640 99.45 9.39 0.448 2.184 95.91 18.24 0.025 1.520 2188.70 28.81 0.877 5.937 2833.57 703.18 Table 5: Times and speedups of DA on RK in unweighted real graphs under real dynamics and random updates, for batch sizes of 1 and 1024. (arXivCitations and englishWikipedia) and on large batches, DA requires at most a few seconds to recompute the BC scores, whereas RK requires about one hour for englishWikipedia. The results on weighted graphs are shown in Table 6. In both real dynamics and random updates, the speedups vary between ≈ 50 and ≈ 6 · 103 for single-edge updates and between ≈ 5 and ≈ 75 for batches of size 1024. On hyperbolic graphs (Figure 7, right), the speedups of DA on RK increase with the size of the graph. Table 7 contains the precise running times and speedups on batches of 1 and 1024 edges. The speedups vary between ≈ 100 and ≈ 3 · 105 for single-edge updates and between ≈ 3 and ≈ 5 · 103 for batches of 1024 edges. Some graphs of Table 2 can also be interpreted as directed (i. e., repliesDigg, emailSlashdot, emailLinux, facebookPosts, emailEnron, arXivCitations). We therefore test DAD on the directed version of the networks, using real dynamics. Also on directed networks, using DAD is always faster than recomputation with RK, by orders of magnitude on small batches. Figure 8 (right) shows the speedups of DAD on RK on the facebookPosts graph. 6 10 4 repliesDigg emailSlashdot emailLinux facebookPosts emailEnron facebookFriends arXivCitations englishWikipedia 3 Speedup 10 2 10 1 10 0 10 0 m m m m m m m 5 10 4 10 Speedup 10 3 10 2 10 = = = = = = = 20000 50000 200000 500000 2000000 5000000 20000000 1 10 0 10 1 2 2 2 3 2 4 2 5 2 6 2 Batch size 7 2 8 2 9 2 10 2 0 1 2 2 2 3 2 4 2 5 2 6 2 7 2 8 2 9 2 10 2 Batch size Figure 7: Speedups of DA on RK, with  = 0.05 and with batches of different sizes. Left: real unweighted networks using real dynamics. Right: hyperbolic unit-disk graphs of different sizes. 4 3 repliesDigg emailSlashdot emailLinux facebookPosts emailEnron facebookFriends arXivCitations englishWikipedia 3 Speedup 10 2 10 1 10 2 10 1 10 0 10 0 10 0 10 Speed-up 10 1 2 2 2 3 2 4 2 5 2 6 2 7 2 8 2 9 2 0 10 2 1 2 4 8 16 32 64 128 256 512 1024 Batch size Batch size Figure 8: Left: speedups of DA on RK in real unweighted graphs under random updates. Right: Speedups of DAD on RK on the facebookPosts directed graph using real dynamics. Graph repliesDigg emailSlashdot emailLinux facebookPosts emailEnron Real Time [s] Speedups |β| = 1 |β| = 1024 |β| = 1 |β| = 1024 0.053 3.032 605.18 14.24 0.790 5.387 50.81 16.12 0.324 24.816 5780.49 75.40 0.029 6.672 2863.83 11.42 0.050 9.926 3486.99 24.91 Random Time [s] Speedups |β| = 1 |β| = 1024 |β| = 1 |β| = 1024 0.049 3.046 658.19 14.17 0.716 5.866 56.00 14.81 0.344 24.857 5454.10 75.28 0.029 6.534 2910.33 11.66 0.046 50.425 3762.09 4.90 Table 6: Times and speedups of DAW on RK in weighted real graphs under real dynamics and random updates, for batch sizes of 1 and 1024. Number of edges m = 20000 m = 50000 m = 200000 m = 500000 m = 2000000 m = 5000000 m = 20000000 Hyperbolic Time [s] Speedups |β| = 1 |β| = 1024 |β| = 1 |β| = 1024 0.005 0.195 99.83 2.79 0.002 0.152 611.17 10.21 0.015 0.288 422.81 22.64 0.012 0.339 1565.12 51.97 0.049 0.498 2419.81 241.17 0.083 0.660 4716.84 601.85 0.006 0.401 304338.86 5296.78 Table 7: Times and speedups of DA on RK in hyperbolic unit-disk graphs, for batch sizes of 1 and 1024. To summarize, our results show that our dynamic algorithms are faster than recomputation with RK in all the tested instances, even when large batches of 1024 edges are applied to the graph. With small batches, the algorithms are always orders of magnitude faster than RK, often with running times of fraction of seconds or seconds compared to minutes or hours. Such high speedups are made possible by the efficient update of the sampled shortest paths, which limits the recomputation to the nodes that are actually affected by the batch. Also, processing the edges in batches, we avoid to update multiple times nodes that are affected by several edges of the batch. 7 Conclusions Because betweenness centrality considers all shortest paths between pairs of nodes, its exact computation is out of reach for the large complex networks that come up in many applications today. However, approximate scores obtained by sampling paths are often sufficient to identify the most important nodes and rank nodes in an order that is very similar to exact BC. Since many applications are concerned with rapidly evolving networks, we have explored whether a dynamic approach – which updates paths when a batch of edges arrive or are deleted from the network – is more efficient than recomputing BC scores from scratch. We introduce the first dynamic betweenness 25 approximation algorithms with provable error guarantee. They work for weighted, unweighted, directed and undirected graphs. Our theoretical results are confirmed by experiments on a diverse set of real-world networks with both real and simulated dynamics, which show the effectiveness of our approach. The dynamic updating of paths implies a higher memory footprint, but also enables significant speedups compared to recomputation (e. g. factor 100 for a batch of 1024 edge insertions). The scalability of our algorithms is primarily limited by the available memory. Each sampled path requires O(n) memory and the number of required samples grows quadratically as the error bound  is tightened. This leaves the user with a tradeoff between running time and memory consumption on the one hand and BC score error on the other hand. However, our experiments indicate that even a relatively high error bound (e. g.  = 0.1) for the BC scores preserves the ranking for the more important nodes reasonably well. We studied sequential implementations for simplicity and comparability with related work, but parallelization is possible, part of future work, and can yield further speedups in practice. Our implementations are based on NetworKit 1 , the open-source framework for large-scale network analysis. Most of the source code used for this paper is already available in NetworKit, the remaining code will follow in upcoming releases of the package. An interesting open problem remains the update of BC approximations in scenarios where also nodes can be inserted and deleted. The presence of a new node (or the deletion of an existing one) would modify the probability distribution that regulates the path sampling, requiring the necessity of new techniques. Acknowledgements. This work is partially supported by DFG grant ME-3619/3-1 (FINCA) within the SPP 1736 Algorithms for Big Data and by DFG grant ME-3619/2-1 (TEAM). We thank Moritz von Looz for providing the synthetic dynamic networks and the numerous contributors to the NetworKit project. We also thank Matteo Riondato for his constructive comments on earlier versions of the material presented in this paper. References [1] D. A. Bader, S. Kintali, K. Madduri, and M. Mihail. Approximating betweenness centrality. In 5th Workshop on Algorithms and Models for the Web-Graph (WAW ’07), volume 4863 of Lecture Notes in Computer Science, pages 124–137. Springer, 2007. [2] D. A. Bader, H. Meyerhenke, P. Sanders, C. Schulz, A. Kappes, and D. Wagner. Benchmarking for graph clustering and partitioning. In Encyclopedia of Social Network Analysis and Mining, pages 73–82. 2014. [3] R. Bauer and D. Wagner. Batch dynamic single-source shortest-path algorithms: An experimental study. In 8th Int. Symp. on Experimental Algorithms (SEA ’09), volume 5526 of LNCS, pages 51–62. Springer, 2009. [4] E. Bergamini and H. Meyerhenke. Fully-dynamic approximation of betweenness centrality. In N. Bansal and I. Finocchi, editors, Algorithms - ESA 2015 - 23rd Annual European Symposium, Patras, Greece, September 14-16, 2015, Proceedings, volume 9294 of Lecture Notes in Computer Science, pages 155–166. Springer, 2015. [5] E. Bergamini, H. Meyerhenke, and C. Staudt. Approximating betweenness centrality in large evolving networks. In 17th Workshop on Algorithm Engineering and Experiments, ALENEX 2015, pages 133–146. SIAM, 2015. [6] M. Borassi, P. Crescenzi, and A. Marino. Fast and simple computation of top-k closeness centralities. http: //arxiv.org/abs/1507.01490, 2015. [7] U. Brandes. A faster algorithm for betweenness centrality. Journal of Mathematical Sociology, 25:163–177, 2001. [8] U. Brandes and C. Pich. Centrality estimation in large networks. I. J. Bifurcation and Chaos, 17(7):2303–2318, 2007. [9] M. H. Chehreghani. An efficient algorithm for approximate betweenness centrality computation. Comput. J., 57(9):1371–1382, 2014. [10] A. D’Andrea, M. D’Emidio, D. Frigioni, S. Leucci, and G. Proietti. Experimental evaluation of dynamic shortest path tree algorithms on homogeneous batches. In 13th Int. Symp. on Experimental Algorithms (SEA ’14), volume 8504 of LNCS, pages 283–294. Springer, 2014. [11] S. N. Dorogovtsev and J. F. Mendes. Evolution of networks: From biological nets to the Internet and WWW. Oxford University Press, 2003. [12] L. C. Freeman. A set of measures of centrality based on betweenness. Sociometry, 40(1):35–41, March 1977. 1 http://networkit.iti.kit.edu [13] D. Frigioni, A. Marchetti-Spaccamela, and U. Nanni. Semi-dynamic algorithms for maintaining single-source shortest path trees. Algorithmica, 22:250–274, 2008. [14] R. Geisberger, P. Sanders, and D. Schultes. Better approximation of betweenness centrality. In 10th Workshop on Algorithm Engineering and Experiments (ALENEX ’08), pages 90–100. SIAM, 2008. [15] K. Goel, R. R. Singh, S. Iyengar, and S. Gupta. A faster algorithm to update betweenness centrality after node alteration. Internet Mathematics, 11(4-5):403–420, 2015. [16] O. Green, R. McColl, and D. A. Bader. A fast algorithm for streaming betweenness centrality. In SocialCom/PASSAT, pages 11–20. IEEE, 2012. [17] M. Kas, M. Wachs, K. M. Carley, and L. R. Carley. Incremental algorithm for updating betweenness centrality in dynamically growing networks. In Advances in Social Networks Analysis and Mining 2013 (ASONAM ’13), pages 33–40. ACM, 2013. [18] N. Kourtellis, G. D. F. Morales, and F. Bonchi. Scalable online betweenness centrality in evolving graphs. IEEE Trans. Knowl. Data Eng., 27(9):2494–2506, 2015. [19] J. Kunegis. KONECT: the koblenz network collection. In 22nd Int. World Wide Web Conf., WWW ’13, pages 1343–1350, 2013. [20] M. Lee, J. Lee, J. Y. Park, R. H. Choi, and C. Chung. QUBE: a quick algorithm for updating betweenness centrality. In A. Mille, F. L. Gandon, J. Misselis, M. Rabinovich, and S. Staab, editors, Proceedings of the 21st World Wide Web Conference 2012, WWW 2012, Lyon, France, April 16-20, 2012, pages 351–360. ACM, 2012. [21] J. Leskovec, J. M. Kleinberg, and C. Faloutsos. Graphs over time: densification laws, shrinking diameters and possible explanations. In 11th Int. Conf. on Knowledge Discovery and Data Mining, pages 177–187. ACM, 2005. [22] M. Nasre, M. Pontecorvi, and V. Ramachandran. Betweenness centrality - incremental and faster. In Mathematical Foundations of Computer Science 2014 - 39th Int. Symp., MFCS 2014, volume 8635 of Lecture Notes in Computer Science, pages 577–588. Springer, 2014. [23] M. Pontecorvi and V. Ramachandran. A faster algorithm for fully dynamic betweenness centrality. CoRR, abs/1506.05783, 2015. [24] G. Ramalingam and T. Reps. An incremental algorithm for a generalization of the shortest-path problem. Journal of Algorithms, 21:267–305, 1992. [25] M. Riondato and E. M. Kornaropoulos. Fast approximation of betweenness centrality through sampling. In 7th ACM Int. Conf. on Web Search and Data Mining (WSDM ’14), pages 413–422. ACM, 2014. [26] L. Roditty and U. Zwick. On dynamic shortest paths problems. Algorithmica, 61(2):389–401, 2011. [27] C. Staudt, A. Sazonovs, and H. Meyerhenke. NetworKit: An interactive tool suite for high-performance network analysis. http://arxiv.org/abs/1403.3005, 2014. [28] M. von Looz, H. Meyerhenke, and R. Prutkin. Generating random hyperbolic graphs in subquadratic time. In Proc. 26th Int’l Symp. on Algorithms and Computation (ISAAC 2015), LNCS. Springer, 2015. To appear. 27
8cs.DS
Two-Sample Instrumental Variable Analyses using Heterogeneous Samples arXiv:1709.00081v1 [math.ST] 31 Aug 2017 Qingyuan Zhao∗ , Jingshu Wang, Jack Bowden, and Dylan S. Small Abstract: Instrumental variable analysis is a widely used method to estimate causal effects in the presence of unmeasured confounding. When the instruments, exposure and outcome are not measured in the same sample, Angrist and Krueger (1992) suggested to use two-sample instrumental variable (TSIV) estimators that use sample moments from an instrument-exposure sample and an instrument-outcome sample. However, this method is biased if the two samples are from heterogeneous populations so that the distributions of the instruments are different. In linear structural equation models, we derive a new class of TSIV estimators that are robust to heterogeneous samples under the key assumption that the structural relations in the two samples are the same. The widely used two-sample two-stage least squares estimator belongs to this class, but it is not asymptotically efficient. We then attempt to relax the linearity assumption. To identify the magnitude of the causal effect nonparametrically, we find that it is important that the noise variables in the instrument-exposure equation have the same distributions in the two samples. However, this assumption is in general untestable because the exposure is not observed in one sample. Nonetheless, we may still identify the sign of the causal effect in the absence of homogeneity of the noise variables. 1. Introduction When randomized controlled experiments are not feasible, instrumental variable (IV) analysis is a widely used method to estimate causal effect in the presence of unmeasured confounding. A typical instrumental variable estimator such as the two-stage least squares (TSLS) uses sample moments (e.g. covariance matrices) of the instrument-exposure relationship and the instrument-outcome relationship. In an influential article, Angrist and Krueger (1992) noticed that the two sets of moments can indeed be estimated from different samples. This method, often referred to as the two-sample instrumental variable (TSIV) estimator, is frequently used in econometrics (Inoue and Solon, 2010). One of the most exciting recent application of instrumental variable is in genetic epidemiology where genetic variants are used as the instruments (Davey Smith and Ebrahim, 2003, Lawlor et al., 2008, Burgess et al., 2015). This method is known as “Mendelian randomization” to epidemiologists, because the genotypes are governed by Mendel’s Second Law of independent assortment and thus are independent of any postnatal source of confounding. More recently, there has been growing interest in using two-sample Mendelian randomization that take advantage of large existing Genome-Wide Association Studies (GWAS), as it is often easier to find two GWAS in which one measures the genotypes and the exposure and the other one measures the genotypes and the disease than to find a single GWAS that measures all three types of variables (Pierce and Burgess, 2013, Smith and Hemani, 2014, Burgess et al., 2015, Gamazon et al., 2015, Lawlor, 2016). ∗ Address for correspondence: 400 Huntsman Hall, 3730 Walnut St, Philadelphia, PA 19104, USA, e-mail: [email protected] 1 Q. Zhao et al./Two-Sample IV SNP Gene rs12916 rs1564348 rs2072183 rs2479409 HMGCR LPA NPC1L1 PCSK9 Allele 2 Frequency Sample a Sample b 0.40 0.43 0.18 0.16 0.29 0.25 0.32 0.35 C C C G Table 1 The instrumental variables usually have different distributions in two-sample Mendelian randomization. In this Table we included four single nucleotide polymorphisms (SNPs) used in Hemani et al. (2016, Figure 2) to estimate the effect of low-density lipoprotein (LDL) cholesterol lowering on the risk of coronary heart disease. Sample a only records the genotypes and the LDL cholesterol levels and sample b only records the genotypes and the indicator of coronary heart disease. The alleles clearly have different frequencies in the two samples with tens of thousands of observations (the exact sample size of each SNP is not available in this dataset). Since Mendelian randomization is a special case of instrumental variable analysis in which genetic variants are used as instruments, one would expect that two-sample Mendelian randomization is merely a different application of the existing TSIV estimators. However, there is a subtle but important difference between two-sample Mendelian randomization and the existing applications of TSIV in economics. To the best of our knowledge, all the TSIV estimators previously proposed in econometrics assumed that the two datasets are sampled from the same population (Angrist and Krueger, 1992, Inoue and Solon, 2010, Pacini and Windmeijer, 2016). This is usually not a problem in the economic applications using timeinvariant instrumental variables (Jappelli et al., 1998) such as quarter of birth (Angrist and Krueger, 1992) and sex composition of the children in the household (Currie and Yelowitz, 2000). However, this assumption does not hold in two-sample Mendelian randomization, as the two GWAS usually consist of different cohort studies and thus represent different populations. Table 1 shows an example of two-sample Mendelian randomization in which the allele frequencies are clearly different in the two samples. The goal of this paper is to derive TSIV estimators that can utilize two heterogeneous samples and clarify when they can accurately estimate the causal effect. Assuming a linear structural equation model, we will derive a class of TSIV estimators using the generalized method of moments (GMM) and calculate their asymptotic variances in Section 2. To link the two heterogeneous samples, a key assumption is that their structural relations are the same. One of the interesting questions raised by epidemiologists and geneticists is how far we can get by using just public summary statistics of GWAS (Lawlor, 2016, Barbeira et al., 2016). Our results show that, without individual-level data, it is generally impossible to utilize overidentification by multiple instruments when the instrumental variables are correlated (e.g. the alleles are in linkage disequilibrium) and the two samples are heterogeneous. Then we will turn to relax the linearity assumption in Sections 3 to 5. Compared to the same problem in the one-sample setting, a key distinction is that we often need the distributions of the noise variables to be the same in the two samples. Unfortunately, this assumption is untestable using empirical data because we do not observe the exposure in both samples. In absence of this assumption, we show that one may still identify the sign of the causal effect. Simulations are performed in Section 6 to compare the asymptotic efficiency of two-sample two-stage least squares estimator with the optimal TSIV estimator and examine their biases when the instrument-exposure equation is misspecified or the above “homogeneous noise” assumption is violated. Finally, the identification results and the assumptions made in this Q. Zhao et al./Two-Sample IV 3 paper are summarized at the end in Section 7. We want to emphasize that although we are clearly motivated by the recent epidemiological applications, there is nothing special about Mendelian randomization. The methods and results obtained in this paper can be used in TSIV analyses in other fields. 2. TSIV estimators using heterogeneous samples For simplicity of exposition, throughout the paper we consider only one endogenous exposure variable and no exogenous covariates. Most of our analysis can be easily generalized to the case of multiple endogenous variables and multiple exogenous covariates. First we briefly describe the notational conventions in this paper. We use lower-case letters, bold lower-case letters, bold upper-case letters, and Greek letters to indicate, respectively, deterministic or random scalars, vectors, matrices, and parameters in the model. Superscripts s, a, b are reserved to indicate the sample. Subscripts are used to index the observations in each sample. Suppose we have independent samples (zsi , xsi , yis ), i = 1, 2, . . . , ns , from two populations, s = a and s = b, where z ∈ Rq is a vector of instrumental variables, x is the exposure variable, and y is the outcome variable. More compactly, we can write the data in each sample as a s s matrix Zs ∈ Rn ×q and two vectors xs , ys ∈ Rn . Next we describe the general setting in this paper. Assumption 1. The data are generated from the following nonparametric structural equation model (SEM). For s = a and s = b, yis = g s (xsi , usi ), (1) xsi (2) =f s (zsi , vis ), where the random variables (usi , vis , zsi ), i = 1, . . . , ns are independent and identically distributed within each sample. Hereafter, (1) will be called the exposure-outcome equation and (2) the instrument-exposure equation. The exposure variable x is called endogenous if v 6⊥ ⊥ u (so x 6⊥ ⊥ u). There are three necessary conditions for z to be valid instrumental variables: z must be correlated with x, z must be independent of the unmeasured confounder(s), and z must affect the outcome y only through x (exclusion restriction). These assumptions are usually stated in the potential outcome language (Angrist et al., 1996). Translating these into structural equation models, we need to assume Assumption 2. (Validity of IV) For s = a and s = b, zsi ⊥ ⊥ (usi , vis ) and f s is a non-trivial function in its first argument. The two-sample instrumental variable problem: Suppose only Za , xa , Zb , and yb are observed (in other words ya and xb are not observed). If x is endogenous, what can we learn about the outcome equation (1) by using the instrumental variables z? Even in the one-sample setting, the valid IV assumption (Assumption 2) is not sufficient to identify the causal effect of x on y. Further assumptions such as monotonicity or treatment effect homogeneity are commonly used in the IV literature. In this Section, we will consider the simplest situation where the instrument-exposure and exposure-outcome relations are both linear. Q. Zhao et al./Two-Sample IV 4 Assumption 3. (Linearity) g s (xi , ui ) = β s xi + ui , f s (zi , vi ) = (γ s )T zi + vi . Under Assumption 3, the structural equations (1) and (2) can be written in a more compact form: for s = a, b, ys = xs β s + us , (3) xs = Zs γ s + vs . So far we have been stating our assumptions separately for each sample. If their structural relationships can be arbitrarily different, it is obviously hopeless to solve the endogeneity problem with two partially observed samples. We use the next two assumptions link the structural equations in the two samples. Assumption 4. (Structural invariance) g a = g b , f a = f b . d Assumption 5. (Sampling homogeneity of the noise variables) (uai , via ) = (ubj , vjb ) for any i = 1, . . . , na , j = 1, . . . , nb . Assumption 5 is generally important because we do not specify the forms of the functions f and g in Assumptions 1 and 4. Under Assumptions 4 and 5, the only heterogeneity between the two samples comes from the distribution of the instruments. We will see Assumption 5 is not necessary in linear SEMs, but it is consequential in the general nonparametric SEMS. In the linear SEM (3), structural invariance (Assumption 4) implies that β a = β b = β, a γ = γ b = γ, and our inferential target is the parameter β. Without loss of generality, we assume the expected values of z, u and v in both samples are 0. Otherwise we can just add intercept terms to (3). Finally we introduce notations for the covariance parameters in the model. For s = a and s = b, denote the population covariances as Cov(Zs ) = Σszz , Cov(Zs , xs ) = Σszx , Var(us ) = s )2 , Var(vs ) = (σ s )2 , Cov(us , vs ) = σ s . Denote the sample covariance matrices as (σuu vv uv Sszy = (Zs )T ys /ns , Sszx = (Zs )T xs /ns , Sszz = (Zs )T Zs /ns . We use the generalized method of moments (GMM, Hansen (1982)) to estimate β under Assumptions 1 to 5. Define the following moment function of β mn (β) = (Sbzz )−1 Sbzy − (Sazz )−1 Sazx β. Compared to the moment function defined in Angrist and Krueger (1992), we added the normalization terms (Sazz )−1 and (Sbzz )−1 because Σazz and Σbzz can be different in the heterogeneous two-sample setting. d First, we check the moment conditions mn (β) = 0 identifies β by showing mn (β) → 0. To see this, notice that mn (β) = (Sbzz )−1 (Zb )T (Zb γβ + vb β + ub )/nb − (Sazz )−1 (Za )T (Za γ + va )β/na = [(Sbzz )−1 (Zb )T Zb /nb − (Sazz )−1 (Za )T Za /na ]γβ+ + (Sbzz )−1 (Zb )T (vb β + ub )/nb − (Sazz )−1 (Za )T va β/na = (Sbzz )−1 (Zb )T (vb β + ub )/nb − (Sazz )−1 (Za )T va β/na . (4) Q. Zhao et al./Two-Sample IV 5 It is easy to see that mn (β) has mean 0 and converges to 0 in probability. The key here is that the normalization by (Sazz )−1 and (Sbzz )−1 eliminates the first term in the right hand side of the second equality. Let W ∈ Rq×q be a positive definite weighting matrix. The class of TSIV estimators of β is given by β̂n,W = arg min mn (β)T Wmn (β) β = (5) [(Sazx )T (Sazz )−1 W(Sazz )−1 Sazx ]−1 [(Sazx )T (Sazz )−1 W(Sbzz )−1 Sbzy ]. Using the general theory for GMM, the asymptotic variance of β̂n,W is given by Var(β̂n,W ) ≈ [(Sazx )T (Sazz )−1 W(Sazz )−1 Sazx ]−1 (Sazx )T (Sazz )−1 WΩn W(Sazz )−1 Sazx [(Sazx )T (Sazz )−1 W(Sazz )−1 Sazx ]−1 , (6) where Ωn is the asymptotic variance of mn (β). The optimal W is given by W ∝ Ω−1 n . Next we compute Ωn . It is easy to see that Var(mn (β) | Za , Zb ) =Var((Sbzz )−1 Sbzy |Zb ) + Var((Sazz )−1 Sazx β|Za ) 1 1 b = (Sbzz )−1 [β 2 (σvb )2 + 2βσuv + (σub )2 ] + (Sazz )−1 [β 2 (σva )2 ]. nb na In other words, the conditional variance of mn (β) is the sum of the variance of the coefficient of the outcome-instrument regression (in sample b) and β 2 times the variance of the coefficient of the exposure-instrument regression (in sample a). Since the conditional expectation of mn (β) is E[mn (β) | Za , Zb ] = 0, by the law of total variance, 1 1 b (Σb )−1 [β 2 (σvb )2 + 2βσuv + (σub )2 ] + (Σazz )−1 [β 2 (σva )2 ] nb zz na 1 1 = (Σbzz )−1 Var(yib |zbi ) + (Σazz )−1 β 2 Var(xai |zai ). nb na Ωn = (7) (8) Equation (8) means that to estimate Ωn and the variance of β̂n,W for any given W, we just need to estimate the noise variances of the outcome-instrument and exposure-instrument regressions. The asymptotically efficient two-sample IV estimator is β̂n,Ω̂−1 . Its asymptotic variance is n given by a −1 a −1 Var(β̂n,Ω̂−1 ) ≈ [(Σazx )T (Σazz )−1 Ω−1 (9) n (Σzz ) Σzx ] , n a −1 which can be consistently estimated by [(γ̂ a )−1 Ω̂−1 n γ̂ ] . Next we make five remarks on the new class of TSIV estimators. Remark 1. When W = Sbzz , the estimator reduces to the two-sample two-stage least squares (TSTSLS) estimator. To see this, let γ̂ = (Sazz )−1 Sazx and x̂b = Zb γ̂ be the predicted values. Then the TSTSLS estimator is defined as β̂T ST SLS = [(x̂b )T x̂b ]−1 (x̂b )T yb . Q. Zhao et al./Two-Sample IV 6 It is easy to verify that β̂n,Sbzz = β̂T ST SLS . Also, notice that the conventional covariance estimator based on sample covariance matrices is generally biased. In the exact-identified case (q = 1), the two-sample covariance estimator is p b a β̂T SCOV = (sazx )−1 sbzy → β · (σzz /σzz ). Remark 2. Notice that Ωn is a weighted sum of (Σazz )−1 and (Σbzz )−1 . If Σazz = Σbzz (the scenario considered in Angrist and Krueger (1992), Inoue and Solon (2010)), we have Σbzz ∝ Ω−1 n and hence the TSTSLS estimator is efficient in the class of TSIV estimator (5). This is consistent with the conclusions of Inoue and Solon (2010, Theorem 1). In general, the efficiency of the TSTSLS estimator (relative to the most efficient TSIV estimator β̂n,Ω̂n−1 ) depends on the difference between (Σazz )−1 and (Σbzz )−1 and the ratio of na and nb . In most cases we expect the covariance structures of the instrumental variables are not too different in the two samples, so the TSTSLS estimator has good relative efficiency. Remark 3. A naive estimator of the asymptotic variance of β̂T ST SLS used by Gamazon et al. (2015) is simply the variance of the coefficient in the second-stage regression: 2 a −1 a −1 d ib |x̂bi ) → [(Σazx )T (Σazz )−1 Ω̃−1 σ̂naive (β̂T ST SLS ) = [(x̂b )T x̂b ]−1 Var(y n (Σzz ) Σzx ] where Ω̃n = 1 (Σb )−1 Var(yib |zbi ) > Ωn . nb zz Compared to (9), it is larger than the variance of the efficient TSIV estimator. However, since 2 the asymptotic variance of TSTSLS is larger than the efficient TSIV estimator, σ̂naive (β̂T ST SLS ) may or may not over-estimate the variance of β̂T SLS . Remark 4. When q = 1, the covariance matrices all become scalars. The GMM estimator β̂n,W no longer depends on W and is always equal to the two-sample Wald ratio estimator. To see this, all the matrices in (5) become scalars and β̂n = (sbzy /sbzz )/(sazx /sazz ). The asymptotic variance of β̂n is given by (6), which can be simplified to Var(β̂n ) ≈ ωn /(sazx /sazz )2 . The asymptotic variance in this special case can be derived more directly by the delta method as well (Burgess et al., 2015). Remark 5. When q > 1, our results mean that the covariance matrices of Z are needed to compute any IV estimator and its asymptotic variance (unless only a single IV is used). Just observing the marginal regression coefficients is not enough. In situations where only the Sazx and Sbzy are available (for example many GWAS only report summary statistics), one may estimate Sazz and Sbzz (which reflects linkage disequilibrium in mendelian randomization) from additional datasets drawn from the same population. A similar idea of estimating linkage disequilibrium from additional dataset can be found in the context of multiple-SNP analysis in GWAS (Yang et al., 2012). In the context of Mendelian randomization, this means we can still compute the TSTSLS estimator by plugging in estimates of Σazz and Σbzz obtained Q. Zhao et al./Two-Sample IV 7 from other samples, but to compute the asymptotic variance, the matrix Ω is not directly estimable. Nonetheless, one can still obtain a conservative estimate of Ω from (8) by using b β 2 (σvb )2 + 2βσuv + (σub )2 = Var(yib |zbi ) ≤ Var(yib ). This upper bound is usually not too conservative in Mendelian randomization since genetic variants identified so far usually only explain a small portion of the variability of complex diseases and traits (Manolio et al., 2009). 3. Relaxing invariance and homogeneity assumptions Apart from the structural model and validity of IV (Assumptions 1 and 2) that are necessary in the one-sample setting, in Section 2 we used additional invariance and linearity assumptions (Assumptions 3 to 5) to identify and estimate the causal effect in the heterogeneous twosample setting . Next we attempt to relax these assumptions. First of all, notice that we did not use invariance of g and u in the calculation above. Because y a is not observed, we do not need to consider the exposure-outcome relation in sample a. In fact, ua never appears in the calculation above, and we can replace β by β b and all the arguments in Section 2 still go through under the same assumptions. For example, it is easy to verify using (4) that mn (β b ) still has mean 0 and converges to 0 in probability. Therefore, the estimand of the TSIV estimators is indeed β b and we do not need to assume d β a = β b or ua = ub . Second, sampling homogeneity of the noise variable v (Assumption 5) is not crucially important in the above linear structural equation models (3). When the expected values of v a and v b are different, they can be absorbed in an intercept term and this does not affect the identification and estimation of β b . Also, our calculations above have already considered the possibility that the variance of v a and v b are different. Therefore, Assumption 5 is not needed when the structural relations are linear. However, we will see in the next two Sections that Assumption 5 is quite important when the structural relations are not linear. 4. Relaxing linearity of the instrument-exposure equation In one-sample instrumental variable analysis, correct specification of the instrument-exposure model is not necessary for consistent estimation of the causal effect. To see this, suppose the linear exposure-outcome model is correctly specified in (3). In the one sample problem, the parameter β can be identified by the following moment condition h(z) · (y − xβ) = 0 for any function h(z) due to the independence of z and u. This results in the class of instrumental variable estimators n n hX i hX i β̂h = yi h(zi ) / xi h(zi ) . (10) i=1 i=1 The TSLS estimator is a special case of (10) when h(z) = zT γ and γ is estimated from the first stage regression. In general, β̂h is consistent and asymptotically normal as long as Q. Zhao et al./Two-Sample IV 8 Cov(x, h(z)) 6= 0. The asymptotic variance of β̂h depends on the choice of h. The optimal choice of h, often called the optimal instrument, is the conditional expectation of x given z: h∗ (z) = E[x|z]. To summarize, in the one-sample problem, the TSLS estimator is consistent for β even if the linear instrument-exposure model is misspecified, although in that case the TSLS estimator is less efficient than the optimal instrumental variable estimator. This robustness property of TSLS does not carry to the two-sample setting due to a phenomenon known as the “conspiracy” of model misspecification and random design (Buja et al., 2014). Under the general instrument-exposure equation xsi = f s (zsi , vis ) in (2), the best linear projection (in Euclidean distance)  γ s = arg min E [(zsi )T γ − f s (zsi , vis )]2 (11) γ depends on the structural function f s , the distribution of the noise variable v s , and the distribution of the instrumental variables zsi . Therefore, even if structural invariance (Assumption 4) and sampling homogeneity of the noise variables (Assumption 5) are satisfied, γ a and γ b can still be different if the sampling distributions of z are different. In extreme cases, γ a and γ b can even have different signs; see Figure 1 for an example. Since the TSTSLS estimator converges to γ b β/γ a when the instrumental variable is univariate, the TSTSLS estimator and other TSIV estimators are biased and may even estimate the sign of β incorrectly. There are two ways to mitigate the issue of non-linearity of the instrument-exposure equation. The first is to only consider the common support of za and zb as suggested by Lawlor (2016) and match or weight the observations so that za and zb have the same distribution. This ensures the projections γ a and γ b are the same. The second solution is to nonparametrically model the instrument-exposure relation to avoid the drawback of using the linear approximations. We want to emphasize that, unlike the scenario with linear instrument-exposure equation in Section 2, both solutions above still hinge on sampling invariance of noise variables (Assumption 5). Even if the distributions of za and zb are the same and f a is modeled nonparametrically, the best linear or nonlinear approximation still depends on the distribution of the noise variable v. If Assumption 5 is violated so v a and v b have different distributions, the TSIV estimators are still generally biased, though the bias is unlikely to be very large. It is also worth noting that sampling homogeneity of the noise variables (Assumption 5) is untestable in the two sample setting because xb is not observed. One way to relax Assumption 5 is to assume the instrument-exposure equation is additive: Assumption 6. (Additivity of the instrument-exposure equation) f s (z, v) = fzs (z) + fvs (v). Under Assumption 6, we may non-parametrically estimate fzs (z) and then estimate β by regressing yib on the predicted fza (zbi ). This is consistent for β if fza is estimated consistently, because yib = βxbi + ubi = βfzb (zbi ) + βfvb (vib ) + ubi = βfza (zbi ) + (βfva (vib ) + ubi ). The last equation used structural invariance (Assumption 4). Even if the noise variables u and v may have different distributions in the two samples, the estimation of β is not affected (see Section 3). Q. Zhao et al./Two-Sample IV 9 5.0 20 15 10 sample sample a b a b y y 2.5 0.0 5 0 −2.5 −4 −2 0 2 4 −4 0 2 4 0.6 0.3 sample 0.2 a b 0.1 0.0 density 0.4 density −2 0.4 sample 0.2 a b 0.0 −4 −2 0 2 4 −4 −2 x 0 2 4 x (a) Before matching. (b) After nearest neighbor matching (pairs are kept if the absolute within pair difference is less than 0.1). Fig 1: “Conspiracy” of model misspecification and random design. In this example, f a (z, v) = d f b (z, v) = z 2 + z + v where v a = v b ∼ N(0, 1), z a ∼ N(−1, 1), and z b ∼ N(1, 1). If the model is misspecified and a linear model is used as an approximation, f s (z, v) ≈ η s + γ s z s , the projections γ a and γ b depends on the distribution of z a and z b and have different signs in this example. By only considering the common support of the two samples and matching the observations, the projections γ a and γ b are much closer. 5. Relaxing linearity of the exposure-outcome equation 5.1. LATE in the one-sample setting When the exposure-outcome equation is nonlinear, an additional assumption called homogeneity is usually needed to identify the causal effect. Next we review this approach in the one-sample setting when the instrument and the exposure are both binary. In this case, we can define four classes of observations based on the instrument-exposure equation: for s = a, b,   always taker (at), if f s (0, v) = 1, f s (1, v) = 1,    complier (co), if f s (0, v) = 0, f s (1, v) = 1, ts (v) =  never taker (nt), if f s (0, v) = 0, f s (1, v) = 0,    defier (de), if f s (0, v) = 1, f s (1, v) = 0. Classes are important to remove endogeneity since conditioning on the class, the exposure x is no longer dependent on the noise variable u, that is xs ⊥ ⊥ us | ts (v s ). (12) Q. Zhao et al./Two-Sample IV 10 The last equation is true because given ts (v s ) and hence the values of f s (0, v) and f s (1, v), the only randomness of xs comes from z s which is independent of us . If the classes were observable, (12) implies that we can identify the class-conditional average outcome E[g s (x, us )|ts = t] for (t, x) in the support of (ts , xs ), which is a subset of {at, co, nt, de} × {0, 1}. More specifically, since P(xs = 0|ts = at) = 0 and P(xs = 1|ts = nt) = 0, the support of (ts , xs ) contains 6 elements, supp(ts , xs ) = {(at, 1), (co, 0), (co, 1), (nt, 0), (de, 0), (de, 1)}. However, the classes are not directly observable, and in fact we can only identify four conditional expectations E[y s |xs = x, z s = z] = E[g s (x, us )|xs = x, z s = z] from the data. This means that the class-conditional average outcomes are not identifiable, because in the following system of equations, E[g s (0, us )|xs = 0, z s = 0] = E[g s (0, us )|ts = nt] · P(ts = nt) + E[g s (0, us )|ts = co] · P(ts = co), E[g s (0, us )|xs = 0, z s = 1] = E[g s (0, us )|ts = nt] · P(ts = nt) + E[g s (0, us )|ts = de] · P(ts = de), E[g s (1, us )|xs = 1, z s = 0] = E[g s (1, us )|ts = at] · P(ts = at) + E[g s (1, us )|ts = de] · P(ts = de), E[g s (1, us )|xs = 1, z s = 1] = E[g s (1, us )|ts = at] · P(ts = at) + E[g s (1, us )|ts = co] · P(ts = co), (13) there are six class-conditional average outcomes but only four equations. Note that to derive (13) we have used Assumption 2 which asserts z s ⊥ ⊥ ts = ts (v s ) and z s ⊥ ⊥ us , so s s s s s s s s s s E[g (x, u )|z , t ] = E[g (x, u )|t ] and P(t = t|z ) = P(t = t) for any fixed x and t. The monotonicity assumption is used to reduce the number of free parameters in (13). Assumption 7. (Monotonicity) f s (z, v) is a monotone function of z for any v and s = a, b. Without loss of generality, we will assume f s (z, v) is an increasing function of z, otherwise we can use −xs = −f s (z s , v s ) as the exposure. In the context of binary instrument and binary exposure, Assumption 7 means that P(ts = de) = 0 and is often called the nodefiance assumption (Balke and Pearl, 1997). This eliminates two class-conditional average outcomes, E[g s (0, us )|ts = de] and E[g s (1, us )|ts = de], leaving us four equations and four class-conditional average outcomes. Therefore, using (13), we can identify the so called local average treatment effect (LATE), E[g s (1, us ) − g s (0, us )|ts = co] (Angrist et al., 1996). In particular, under Assumptions 1, 2 and 7, one can show that the TSLS estimator in sample s converges to E[y s |z s = 1] − E[y s |z s = 0] E[xs |z s = 1] − E[xs |z s = 0] E[g s (1, us ) − g s (0, us )|ts = co] · P(ts = co) = P(ts = co) s s s =E[g (1, u ) − g (0, us )|ts = co]. s βLATE = (14) See (15) below for proof this result. When the exposure x is continuous, we may still define the class t such that (12) holds and identify the class-conditional average outcomes on the joint support of x and t. This support may be very limited when the instrument z is binary. We refer the reader to Imbens (2007) for further detail and discussion. In this case, the instrumental variable estimator β̂h in (10) converges in probability to a weighted average of local average treatment effects (Angrist et al., 2000). Note that in order for the weights to be non-negative, ordering the Q. Zhao et al./Two-Sample IV 11 instruments by E[xs |z s = z] must simultaneously order the instruments by the value of h(z) (Angrist et al., 2000, Theorem 2,3). A preferable choice of h(z) is the conditional expectation E[xs |z s = z]. 5.2. LATE in the two-sample setting We can still follow the LATE framework in the two-sample setting considered in this paper. When the instrument and the exposure are both binary, the TSTSLS estimator converges to a modification of (14) by taking the expectations in the numerator over sample a and the expectations in the denominator over sample b, E[y b |z b = 1] − E[y b |z b = 0] E[xa |z a = 1] − E[xa |z a = 0] E[g b (1, ub ) − g b (0, ub )|tb = co] · P(tb = co) = P(ta = co) P(tb = co) b =βLATE · . P(ta = co) ab βLATE = (15) Next we prove the second equality in (15). First we consider the numerator E[y b |z b = 1] − E[y b |z b = 0] X  = E[y b |z b = 1, tb = t] − E[y b |z b = 0, tb = t] · P(tb = t) t∈{at,co,nt,de} = X  E[y b |z b = 1, tb = t] − E[y b |z b = 0, tb = t] · P(tb = t) t∈{at,co,nt} where the first equality is due to the law of total expectation and the second equality uses Assumption 7. Next, notice that y b ⊥ ⊥ z b |tb = at, because P(xb = 1|tb = at) = 1 and by the exclusion restriction (implied from Assumption 2), y b only depends on z b through xb . Similarly, y b ⊥ ⊥ z b |tb = ne. Therefore, we are left with just the compliers E[y b |z b = 1] − E[y b |z b = 0]  = E[y b |z b = 1, tb = co] − E[y b |z b = 0, tb = co] · P(tb = co)  = E[g b (1, ub )|z b = 1, tb = co] − E[g b (0, ub )|z b = 0, tb = co] · P(tb = co)  = E[g b (1, ub )|tb = co] − E[g b (0, ub )|tb = co] · P(tb = co). In the last equation we have again used the exclusion restriction. Similarly, the denominator in (15) is E[xb |z b = 1] − E[xb |z b = 0] X  = E[xb |z b = 1, tb = t] − E[xb |z b = 0, tb = t] · P(tb = t) t∈{at,co,nt} =(1 − 1) · P(tb = at) + (1 − 0) · P(tb = co) + (0 − 0) · P(tb = nt) =P(tb = co). Q. Zhao et al./Two-Sample IV 12 Finally, note that similar to the one-sample case, (15) only uses Assumptions 1, 2 and 7. When structural invariance of the instrument-exposure equation f (Assumption 4) and d sampling homogeneity of the noise variable v (Assumption 5) hold, we have ta = tb because ab b the class ts is a function of f s and v s . Therefore βLATE = βLATE by equation (15). In general, the estimand of TSTSLS is a scaling of the LATE in the sample b. Since f a and f b are nontrivial functions of z by Assumption 2, the proportions of compliers are positive and hence ab b the ratio P(tb = co)/P(ta = co) > 0. This means that βLATE has the same sign as βLATE . When the exposure is continuous, most of the arguments in Angrist et al. (2000) would still hold as they were proved separately for the numerator and the denominator just like our proof of (15). Similarly, the TSTSLS estimator converges in probability to the estimand of the TSLS estimator in sample b times a scaling factor, and the scaling factor is equal to 1 under Assumptions 4 and 5. However, the scaling factor is not always positive because in the absence of Assumption 5, the conditional expectation E[xs |z s ] can be different in the two samples (same issue as in Section 4). Similar to Section 4, this can be resolved by assuming additivity (Assumption 6). 6. Simulation In all the simulations in this section, we consider 10 binary instrumental variables generated by s∗ i.i.d. (16) zsi = sign(zs∗ ∼ N(1, Σs ), Σsjk = (ρs )|j−k| , s = a, b. i ), zi We first verify the asymptotic results regarding the TSIV estimators in Section 2. In our first simulation, the exposures and the outcomes are generated by xsi = 0.2 · (1T zsi ) + vis , (17) yis (18) = xsi usi , +  ! ! 0 1 σuv  i.i.d. (vis , usi ) ∼ N  , , i = 1, . . . , ns , s = a, b. 0 σuv 1 (19) In this simulation we used ρa = 0.5, ρb = 0.5, 0, or −0.5, na = 1000 or 5000, nb = 1000 or 5000, and σuv = 0.5. In Table 2, we compare the performance of the TSTSLS estimator and the optimal TSIV estimator after centering the variables. In particular, we report the root mean squared error (RMSE), bias, and coverage of the 95% asymptotic confidence interval. When ρa = ρb = 0.5, the two estimators are asymptotically equivalent by (8). This is verified by Table 2 as the two estimators have the same RMSE, bias and coverage in this case. When ρa and ρb are different, the optimal TSIV estimator is generally more efficient than TSTSLS. However, Table 2 shows that the efficiency gain is substantial only if Σa and Σb (in this simulation, ρa and ρb ) are very different and nb is much larger than na . This phenomenon can also be seen from (8) as discussed in Remark 2. In the second simulation, we examine how misspecification of the instrument-exposure equation may bias the TSIV estimator. The data are generated in the same way as in the Q. Zhao et al./Two-Sample IV 13 Bias Coverage (nominal 95%) TSIV TSTSLS Opt. TSIV TSTSLS Opt. TSIV 0.102 -0.020 -0.020 0.941 0.941 0.065 -0.021 -0.021 0.924 0.923 5000 0.090 -0.006 -0.006 0.949 0.949 0.045 -0.004 -0.004 0.948 0.948 0.0 1000 0.133 -0.046 -0.039 0.928 0.933 0.078 -0.047 -0.029 0.875 0.909 5000 0.121 -0.012 -0.011 0.948 0.947 0.058 -0.010 -0.008 0.947 0.948 -0.5 1000 0.144 -0.058 -0.045 0.918 0.924 0.082 -0.058 -0.031 0.851 0.907 5000 0.130 -0.012 -0.011 0.951 0.951 0.061 -0.013 -0.010 0.947 0.949 Table 2 Simulation 1: Asymptotic efficiency of the TSTSLS and optimal TSIV estimators. The reported numbers are obtained by 10000 relizations of data simulated from equations (16), (17), (18), and (19). ρa 0.5 ρb 0.5 na 1000 nb 1000 5000 1000 5000 1000 5000 1000 5000 1000 5000 1000 5000 RMSE TSTSLS Opt. 0.102 0.066 0.090 0.045 0.134 0.086 0.121 0.058 0.147 0.096 0.130 0.062 Bias Coverage (nominal 95%) TSIV TSTSLS Opt. TSIV TSTSLS Opt. TSIV 0.069 -0.009 -0.009 0.938 0.940 0.045 -0.011 -0.010 0.922 0.922 0.061 -0.001 -0.001 0.946 0.946 5000 0.031 -0.002 -0.002 0.942 0.942 0.098 0.041 0.046 0.927 0.920 0.0 1000 0.073 0.042 0.052 0.878 0.827 0.100 0.059 0.060 0.885 0.884 5000 0.072 0.060 0.061 0.665 0.651 -0.5 1000 0.110 0.050 0.059 0.919 0.904 0.086 0.051 0.067 0.847 0.755 5000 0.114 0.074 0.075 0.860 0.859 0.087 0.075 0.077 0.561 0.535 Table 3 Simulation 2: When the instrument-exposure equation is misspecified, the TSIV estimators can be biased. The reported numbers are obtained by 10000 relizations of data simulated from equations (16), (17), (18), and (19). ρa 0.5 ρb 0.5 na 1000 nb 1000 5000 1000 5000 1000 5000 1000 5000 1000 5000 1000 5000 RMSE TSTSLS Opt. 0.069 0.045 0.061 0.031 0.095 0.066 0.100 0.071 0.105 0.075 0.114 0.085 first simulation except that we add interaction terms in the instrument-exposure equation. More specifically, (17) is replaced by X s s xsi = 0.2 · (1T zsi ) + 0.02 · zij zik + vis . (20) j6=k The results of the second simulation are reported in Table 3. When ρa = ρb = 0.5, the TSTSLS and the optimal TSIV estimators are still unbiased and the confidence intervals provide desired coverage. This is because the best linear approximations of the instrumentexposure equation are the same in the two samples. However, when ρa 6= ρb , the TSTSLS and the optimal TSIV estimators are biased and failed to cover the true parameter at the nominal 95% rate. As discussed in Section 4, this is because the best linear approximations of the instrument-exposure equation are different in the two samples. d Even if zai = zbi , the TSIV estimators can still be biased if via and vib have different distributions and the instrument-exposure equation is not additive (see the discussion after Q. Zhao et al./Two-Sample IV 14 Bias Coverage (nominal 95%) TSIV TSTSLS Opt. TSIV TSTSLS Opt. TSIV 0.311 -0.139 -0.139 0.899 0.898 0.197 -0.135 -0.135 0.761 0.762 0.167 -0.136 -0.136 0.555 0.552 5000 0.309 -0.097 -0.097 0.892 0.892 0.155 -0.093 -0.093 0.867 0.867 0.118 -0.097 -0.097 0.667 0.669 20000 0.283 -0.081 -0.081 0.939 0.939 0.150 -0.079 -0.079 0.886 0.886 0.106 -0.086 -0.086 0.707 0.707 Table 4 Simulation 3: Even if the instruments have the same distribution and all other assumptions are met, the TSIV estimators can still be biased if Assumption 5 (sampling homogeneity of noise) is violated. The reported numbers are obtained by 10000 relizations of data simulated from equations (16), (17), (18), and (19). ρa 0.5 ρb 0.5 na 1000 nb 1000 5000 20000 1000 5000 20000 1000 5000 20000 RMSE TSTSLS Opt. 0.311 0.198 0.167 0.309 0.155 0.118 0.283 0.150 0.106 Assumption (1) Structural equation model (2) Validity of IV (3.1) Linearity of exposure-outcome (3.2) Linearity of instrument-exposure (4) Structural invariance (5) Sampling homogeneity of noise (6) Additivity of instrument-exposure (7) Monotonicity Identifiable estimand Detail yis = g s (xsi , usi ), xsi = f s (zsi , vis ) zsi ⊥ ⊥ (usi , vis ) g s (xi , ui ) = β s xi + ui f b (zi , vi ) = (γ b )T zi + vi fa = fb d via = s Case 1 X X X X X Case 2 X X X Case 3 X X X X vib X f (z, v) = fzs (z) + fvs (v) f s (z, v) is a monotone in z X βb βb X b βLATE Table 5 Summary of some identification results and assumptions made in this paper. Assumption 6). In our third and final simulation, we generate the data from equations (16) and (18) but replace equations (17) and (19) with xsi = I(0.2 · (1T zsi ) + vis > 0),  ! ! s s 0 σvv σuv  i.i.d. (vis , usi ) ∼ N  , , i = 1, . . . , ns , s = a, b. s 0 σuv 1 (21) (22) a = 1, σ b = 2, and σ s = 0.5√σ s , s = a, b. In this simulation we use ρa = ρb = 0.5, σvv vv uv vv d The results of the third simulation are reported in Table 4. Even though zai = zbi in this simulation, the TSIV estimators are still biased because the best linear approximations of the instrument-exposure equation depend on the distributions of v, which are different in the two samples. 7. Summary and discussion Throughout the paper we have seen that different structural and sampling assumptions can lead to different identification results. We now summarize these results in Table 5. We make some final remarks on the distinctions between one-sample and two-sample instrumental variable analyses: Q. Zhao et al./Two-Sample IV 15 1. The instrumental variable analyses in the two-sample setting require additional assumptions to link the two samples. One of the key assumptions is structural invariance (Assumption 4), which may be reasonable in a large number of applications. 2. Another important assumption in the two-sample setting is homogeneity of the distributions of the noise variables (Assumption 5), which is necessary to identify the local average treatment effect (LATE). However, this assumption is untestable as we do not observe the exposure variable in sample b. 3. Although the two-sample two-stage least squares (TSTSLS) estimator is asymptotically efficient in the class of “limited information” estimators in the homogeneous setting, it is generally not efficient if the two samples are heterogeneous. However, the loss of efficiency might be small if the covariance matrices of the instruments in the two samples are not too different (see Remark 2). For practitioners, our results mean that it is necessary to obtain individual-level data in order to use multiple instruments in two-sample IV analysis if the samples are heterogeneous. Therefore, there is a fundamental limitation on what can be learned from merely summary statistics of GWAS. This issue can be potentially mitigated by using uncorrelated IVs or estimating the covariance matrices of the IVs using additional data, see Remark 5. Moreover, misspecification of the instrument-exposure equation and heterogeneity of the noise variable across samples still pose a threat to valid statistical inference as demonstrated in the simulations in Section 6. References Angrist, J. D., K. Graddy, and G. W. Imbens (2000). The interpretation of instrumental variables estimators in simultaneous equations models with an application to the demand for fish. The Review of Economic Studies 67 (3), 499–527. Angrist, J. D., G. W. Imbens, and D. B. Rubin (1996). Identification of causal effects using instrumental variables. Journal of the American Statistical Association 91 (434), 444–455. Angrist, J. D. and A. B. Krueger (1992). The effect of age at school entry on educational attainment: an application of instrumental variables with moments from two samples. Journal of the American Statistical Association 87 (418), 328–336. Balke, A. and J. Pearl (1997). Bounds on treatment effects from studies with imperfect compliance. Journal of the American Statistical Association 92 (439), 1171–1176. Barbeira, A., K. P. Shah, J. M. Torres, H. E. Wheeler, E. S. Torstenson, T. Edwards, T. Garcia, G. I. Bell, D. Nicolae, N. J. Cox, et al. (2016). MetaXcan: Summary statistics based gene-level association method infers accurate PrediXcan results. bioRxiv: 045260 . Buja, A., R. Berk, L. Brown, E. George, E. Pitkin, M. Traskin, L. Zhao, and K. Zhang (2014). Models as approximations, part i: A conspiracy of nonlinearity and random regressors in linear regression. arXiv:1404.1578 . Burgess, S., R. A. Scott, N. J. Timpson, G. D. Smith, S. G. Thompson, E.-I. Consortium, et al. (2015). Using published data in Mendelian randomization: a blueprint for efficient identification of causal risk factors. European Journal of Epidemiology 30 (7), 543–552. Burgess, S., D. S. Small, and S. G. Thompson (2015). A review of instrumental variable estimators for Mendelian randomization. Statistical Methods in Medical Research. Q. Zhao et al./Two-Sample IV 16 Currie, J. and A. Yelowitz (2000). Are public housing projects good for kids? Journal of Public Economics 75 (1), 99–124. Davey Smith, G. and S. Ebrahim (2003). “Mendelian randomization”: can genetic epidemiology contribute to understanding environmental determinants of disease? International Journal of Epidemiology 32 (1), 1–22. Gamazon, E. R., H. E. Wheeler, K. P. Shah, S. V. Mozaffari, K. Aquino-Michaels, R. J. Carroll, A. E. Eyler, J. C. Denny, D. L. Nicolae, N. J. Cox, et al. (2015). A gene-based association method for mapping traits using reference transcriptome data. Nature Genetics 47 (9), 1091–1098. Hansen, L. P. (1982). Large sample properties of generalized method of moments estimators. Econometrica 50 (4), 1029–1054. Hemani, G., J. Zheng, K. H. Wade, C. Laurin, B. Elsworth, S. Burgess, J. Bowden, R. Langdon, V. Tan, J. Yarmolinsky, et al. (2016). MR-Base: a platform for systematic causal inference across the phenome using billions of genetic associations. bioRxiv: 078972 . Imbens, G. W. (2007). Nonadditive models with endogenous regressors. In R. Blundell, W. Newey, and T. Persson (Eds.), Advances in Economics and Econometrics, Volume 3, pp. 17—46. Cambridge University Press. Inoue, A. and G. Solon (2010). Two-sample instrumental variables estimators. The Review of Economics and Statistics 92 (3), 557–561. Jappelli, T., J.-S. Pischke, and N. S. Souleles (1998). Testing for liquidity constraints in Euler equations with complementary data sources. Review of Economics and Statistics 80 (2), 251–262. Lawlor, D. A. (2016). Commentary: Two-sample Mendelian randomization: opportunities and challenges. International Journal of Epidemiology 45 (3), 908. Lawlor, D. A., R. M. Harbord, J. A. Sterne, N. Timpson, and G. Davey Smith (2008). Mendelian randomization: using genes as instruments for making causal inferences in epidemiology. Statistics in Medicine 27 (8), 1133–1163. Manolio, T. A., F. S. Collins, N. J. Cox, D. B. Goldstein, L. A. Hindorff, D. J. Hunter, M. I. McCarthy, E. M. Ramos, L. R. Cardon, A. Chakravarti, et al. (2009). Finding the missing heritability of complex diseases. Nature 461, 747–753. Pacini, D. and F. Windmeijer (2016). Robust inference for the two-sample 2SLS estimator. Economics Letters 146, 50–54. Pierce, B. L. and S. Burgess (2013). Efficient design for Mendelian randomization studies: subsample and 2-sample instrumental variable estimators. American Journal of Epidemiology 178 (7), 1177–1184. Smith, G. D. and G. Hemani (2014). Mendelian randomization: genetic anchors for causal inference in epidemiological studies. Human Molecular Genetics 23 (R1), R89–98. Yang, J., T. Ferreira, A. P. Morris, S. E. Medland, P. A. Madden, A. C. Heath, N. G. Martin, G. W. Montgomery, M. N. Weedon, R. J. Loos, et al. (2012). Conditional and joint multiplesnp analysis of GWAS summary statistics identifies additional variants influencing complex traits. Nature Genetics 44 (4), 369–375.
10math.ST
1 Artificial-noise-aided Secure Multicast Precoding for Directional Modulation Systems arXiv:1712.09511v1 [cs.IT] 27 Dec 2017 Feng Shu, Ling Xu, Jiangzhou Wang, Wei Zhu, and Zhou Xiaobo Abstract—In multi-cast scenario, all desired users are divided into K groups. Each group receives its own individual confidential message stream. Eavesdropper group aims to intercept K confidential-message streams. To achieve a secure transmission, two secure schemes are proposed: maximum group receive power plus null-space (NS) projection (Max-GRP plus NSP) and leakage. The former obtains its precoding vector per group by maximizing its own group receive power subject to the orthogonal constraint, and its AN projection matrix consist of all bases of NS of all desired steering vectors from all groups. The latter attains its desired precoding vector per group by driving the current confidential message power to its group steering space and reducing its power leakage to eavesdropper group and other K − 1 desired ones by maximizing signal to leakage and noise ratio (Max-SLNR). And its AN projection matrix is designed by forcing AN power into the eavesdropper steering space by viewing AN as a useful signal for eavesdropper group and maximizing AN to leakage-and-noise ratio (Max-ANLNR). Simulation results show that the proposed two methods are better than conventional method in terms of both bit-error-rate (BER) and secrecy sum-rate per group. Also, the leakage scheme performs better than Max-GRP-NSP , especially in the presence of direction measurement errors. However, the latter requires no channel statistical parameters and thus is simpler compared to the former. Index Terms—directional modulation, multicast, confidential message, security, artificial-noise. I. I NTRODUCTION In the recent several years, physical-layer security in wireless networks has attracted more and more research activities from both academia and industry [1]–[6]. In [1], the author’s pioneer research work has laid a foundation for physical-layer security. As a physical layer secure transmit technique in lineof-propagation (LoP) channel, directional modulation (DM) has made rapid progress in many aspects by using antenna array with the help of aided artificial noise (AN) [7]–[13]. To enhance security, the symbol-level precoder in [8] was presented by using the concept of constructive interference in directional modulation with the goal of reducing the energy consumption at transmitter. In the presence of direction measurement error, the authors in [12], [13] proposed two new robust DM synthesis methods for two different application scenarios: single-desired user and multi-user broadcasting by This work was supported in part by the National Natural Science Foundation of China (Nos. 61472190, and 61501238). Feng Shu, Ling Xu, Wei Zhu, and Zhou Xiaobo are with School of Electronic and Optical Engineering, Nanjing University of Science and Technology, 210094, CHINA. E-mail:{shufeng, xuling}@njust.edu.cn Jiangzhou Wang is with the School of Engineering and Digital Arts, University of Kent, Canterbury Kent CT2 7NT, United Kingdom fully exploiting the statistical properties of direction measurement error. Compared to existing non-robust methods, the proposed robust methods can achieve at least an orderof-magnitude bit error rate (BER) performance improvement along desired directions. In general, the DM in LoP channel might harvest a high performance gain along the desired directions via confidential-message beamforming and degrades the performance of eavesdroppers at undesired directions with the help of AN projection operation. Finally, the goal of secure transmission is realized. [7], [14] established a unified framework for physical layer multi-casting to multiple co-channel groups, where multiple independent data streams are transmitted to groups of users by the multiple antennas. If one group of eavesdropper appears, then how to achieve a secure transmission in such a situation is an interesting and important research topic. This secure problem includes twofold: the privacy protection among desired groups and the leakage of all confidential messages from all desired groups to the group of eavesdroppers. We will address this topic from the standpoint of physical layer security by using DM in this paper, where the LoP channel is considered and two precoding and AN projecting schemes for this multicast communications will be proposed. The remainder are organized as follows: Section II describes the system model in multi-cast scenario. Two AN-aided precoding schemes are proposed in Section III. Section IV presents the simulation results. Finally, we make conclusions in Section V. Notations: throughout the paper, matrices, vectors, and scalars are denoted by letters of bold upper case, bold lower case, and lower case, respectively. (·)T , (·)∗ and (·)H denote transpose, conjugate, and conjugate transpose, respectively. Matrices IN denotes the N × N identity matrix and 0M×N denotes M × N matrix of all zeros. tr(·) denotes matrix trace. II. S YSTEM M ODEL Fig. 1 plots the schematic diagram of a multi-cast multiuser directional modulation system in LoP channel with perfect CSI konwledge. In this system, there is one base station (BS), K groups of desired users, and one group of eavesdroppers. BS employs an N -antenna array. Desired group k is composed of Tk desired users. Eavesdropper group consists of M eavesdroppers. All users are equipped with a single antenna. In Fig. 1, antenna array at BS broadcasts K independent streams of confidential messages to K different desired groups, respectively and securely so that all users in the eavesdropper group can’t intercept any one of K streams of confidential 2 received signal vector of desired group k is p p y(θdk ) = α1 β1 Ps HH (θdk )vk xk + α1 β1 Ps HH (θdk ) Desired group 1 K X Eavesdroppers group vi xi + α2 β2 i=1,i6=k (3) where ndk ∼ CN (0, σd2 ITk ). Similarly, the received signal vector of the eavesdropper group can be expressed as Desired group K Ă Antenna array (N-element) at base station y(θe ) = α1 β1 K X p p Ps HH (θe ) vk xk + α2 β2 Ps HH (θe )• k=1 Fig. 1. Schematic diagram of multicast DM system TAN z + ne , messages. In Fig. 1, the normalized steering vector for the ith user of the √ kth desired group with direction angle θd,ki is h(θd,ki ) = 1/ N [ej2πψθd,ki (1) , · · · , ej2πψθd,ki (N ) ]T , where ψθd,ki (n) = (n − (N + 1)/2)d cos θd,ki /λ with d being antenna spacing and λ being the wavelength of transmit carrier. Therefore, the total steering channel matrix for kth desired group can be defined as H(θdk ) = [h(θdk,1 ), h(θdk,2 ), · · · , h(θdk,Tk )], p Ps HH (θdk )TAN z + ndk (1) where Tk denotes the number of desired users in kth group. In (1), H(θdk ) is an N × Tk matrix. Similarly, the N × M total steering channel matrix of the eavesdropper group is given by H(θe ) = [h(θe,1 ), · · · , h(θe,M )]. The transmit baseband signal is written as (4) where ne ∼ CN (0, σe2 IM ). III. T WO EFFICIENT SCHEMES OF PRECODING AND AN PROJECTION In this section, we will present two methods to design the confidential message precoding vector vk and AN projection matrix TAN in (2). The first scheme devises the confidential message precoder of maximizing group receive power (Max-GRP) subject to the orthogonal constraint and the AN projection matrix based on null-space projection (NSP) rule. The second scheme uses the leakage concept to design both precoding vectors and AN projection matrix. Due to the use of the statistical property of AN and channel noise, the latter provides a better and more robust performance than the former, which will be confirmed in our simulation section. A. Proposed Max-GRP plus NSP scheme s = α1 β1 K p X p Ps vk xk + α2 β2 Ps TAN z (2) k=1 where xk is the confidential message transmitted to the kth desired group, vk is the corresponding beamforming vector of group k for confidential message xk , Ps is the total transmit power, TAN is the AN projection matrix, and z is the AN vector, satisfying z ∼ CN (0, IN −PK Tk ). In (2), β1 and β2 k=1 are the power allocation factors of confidential message and AN, with the constraint β12 + β22 = 1. A large value of β1 means that more power is allocated to transmit confidential messages and less power is used as secure protection. How to choose the optimal values of β1 and β2 is a hard problem and depends on application scenarios. Parameter α1 is the normalized PK power PK factor of confidential message satisfying α21 E{ k=1 i=1 viH vk xk xH = 1. To simplify the above i } √ expression, we have α1 = 1/ γK, where γ is the normalized factor of signal constellation of digital modulation. For example, when √ shift keying (QPSK) is √ quadrature phase adopted, γ = 1/ 2, then α1 = 1/ 2K. The normalized AN H H power factor α2 ensures α2 E{tr[T q AN zz TAN ]} = 1, which can be simplified as α2 = 1/ σz2 tr(TAN TH AN ). When all PK N − k=1 Tk columns of TAN are orthogonal with each PK other and normalized, tr(TAN TH AN ) = N − k=1 Tk . The Firstly, let us define the complement of the steering matrix of group k as H = d,−k     H (θd1 ), · · · , H θd(k−1) , H θd(k+1) , · · · , H (θdK ) . Then, the optimization problem of maximizing group receive power (Max-GRP) of group k is casted as vkH H(θdk )HH (θdk )vk max vk subject to HH d,−k vk = 0. (5) The objective function in (5) denotes the receive power summation for all users of group k. The constraint HH d,−k vk = 0 means that the confidential message of desired group k will be transmitted through the corresponding null spaces of all the remaining desired groups by the optimization variable vk . The optimization problem in (5) aims to enhance the receive quality of confidential message for desired group k by maximizing the receive power sum of all users of group k. To solve the above problem, channel matrix Hd,−k is first decomposed as the singular-value decomposition (SVD) Hd,−k = h (1) Ud,−k (0) Ud,−k i (1) Σd,−k 0 0 0 ! h (1) Vd,−k (0) Vd,−k iH (6) (1) (0) where Σd,−k is a Lk ×Lk diagonal matrix, and Vd,−k consists of the last (N − Lk ) right singular vectors corresponding to 3 TABLE I C OMPLEXITY COMPARISON (FLOP S ). Complexity as a function of K O((7T 2 N + 3T 3 )K 2 +(−12T 2 − 4T N 2 − 3T 3 − N T )K +(7T 2 N + 7T N 2 + 2N 3 + T 3 + N 2 + N T )) Complexity as a function of T O((3K 2 − 3K + 1)T 3 +(7K 2 N − 12KN + 7N )T 2 +(7N 2 − 4KN 2 + N − N K)T + (N 2 + 2N 3 )) O(2T N 2 K + (3M N 2 + T N 2 + 4N 3 )) O((2KN 2 + N 2 )T + (3M N 2 + 4N 3 )) O(3T 2 N K 2 +(T 3 − T 2 N + M N T + T N −M 2 T − 2N 2 T )K +(−T 3 + 2M 2 N − M N T )+(+T 2 M − T N + M N + M N 2 + N 3 )) O((K − 1)T 3 +(3K 2 N − KN + M )T 2 + (M N K − M N + KN − N − M 2 K − 2N 2 K)T +(2M 2 N + M N + M N 2 + N 3 )) Methods Max-GRP-NSP Max-SLNR plus Max-ANLNR BD (0) N − Lk zero singular values. Define Fk = Vd,−k , and vk = Fk uk , then the optimization problem in (5) is converted into max H H uH k Fk H(θdk )H (θdk )Fk uk subject to uH k uk = 1, uk (7) which means that uk is the eigenvector corresponding to H the largest eigenvalue of matrix FH k H(θdk )H (θdk )Fk . The design of vk has been completed. In the following, we design the AN projection matrix TAN . The basic principle is to eliminate the influence of AN on the desired user by projecting AN to the null space of all desired users’ steering vectors from K groups, which is written as the form HH (θdk ) TAN z = 0 for all values of k with k ∈ {1, 2, · · · , K}, which can also be written as ∗ ∗ B. Proposed leakage-based method However, the Max-GRP plus NSP method does not exploit the effect of channel noise. Now, we consider the design of vk and TAN by using leakage idea with the help of variance of channel noise. Here, the confidential-message power of group k will be allowed to leak out towards other K − 1 desired groups and eavesdropper one. The corresponding precoding vector vk is optimized by the rule of maximizing the signalto-leakage-and-noise ratio (Max-SLNR) vk SLNR (vk ) (10) subject to vkH vk = 1 where   SLNR (vk ) = α21 β12 Ps tr vkH H (θdk ) HH (θdk ) vk K h  X tr α21 β12 Ps vkH H (θdi ) HH (θdi ) vk + i=1,i6=k α21 β12 Ps vkH H (θe ) HH i=1,i6=k H (θdk ) HH (θdk ) 2 (θe ) vk + σdk i−1 . (11) (12) Below, the AN will be regarded as a useful signal to the eavesdropper group. By optimizing the AN projection matrix TAN , the leakage of AN power to K desired groups should be made as small as possible. This idea can be represented as max ANLNR (TAN )   P subject to tr TAN H TAN = N − K k=1 Tk , TAN T . (8) [H (θd1 ), · · · , H (θdK )] · TAN z = 0PK k=1 Tk ×1  H ∗ ∗ T H , then Let us define HH d = H (θd1 ) , · · · , H (θdK ) the orthogonal condition in (8) is reduced to  −1 H P HH ⇒ TAN = IN −Hd HH Hd . d TAN z = 0 K d Hd k=1 Tk ×1 (9) The added AN is intended to interfere eavesdroppers, and the desired user groups receive no AN under ideal channel knowledge because we project AN onto the null space (NS) of all desired groups. To guarantee the existence of NS, the number of transmit antennas should be greater than the sum of receive antenna numbers of all desired groups of users. max According to the generalized Rayleigh-Ritz theorem, vk (k = 1, 2, · · · , K) is the eigenvector corresponding to the largest eigenvalue of matrix  −1 K 2 X σ  H (θdi ) HH (θdi ) + H (θe ) HH (θe ) + 2 dk IN  · α1 β12 Ps (13) which is called Max-ANLNR, where ANLNR stands for ANleakage-and-noise-ratio defined by ANLNR (TAN ) =  H tr TH AN H (θe ) H (θe ) TAN  K P tr TH H (θdi ) HH (θdi ) + AN i=1 2 σe 2 P N−PK T α2 β s 2 2 i=1 k ( ) IN  TAN , (14) where, similar to Max-SLNR in (10), all columns of AN projection matrix AN consists of the eigenvectors corresponding PT K to the N − k=1 Tk largest eigenvalues of the matrix given by   K X i=1 H H (θdi ) H (θdi ) + σe2 −1   IN  P α22 β22 Ps N − K k=1 Tk H (θe ) HH (θe ) . · (15) Therefore, we complete the design of the proposed MaxSLNR plus Max-ANLNR method. C. Complexity comparison and analysis In Table I, we list the complexities of our proposed methods and conventional block diagonalization (BD) method in [15], respectively. BD is a classic precoding method for conventional MU-MIMO systems, and performs better than zero-forcing in terms of sum-rate by allowing multi-antenna interference among antennas per user. Below, BD is adopted as a performance benchmark. Here, K stands for the number of desired groups and T is the number of users per group with T1 = · · · = TK = T . From this table, it is seen that the complexities of BD and the proposed Max-GRP-NSP are the 4 quadratic function of K and the complexity of the Max-SLNR plus Max-ANLNR is a linear function of K for fixed values of M , N and T . The former increases quadratically with K while the latter increases linearly with K. When M , N and K are fixed, the complexities of BD and the proposed MaxGRP-NSP are the cubic function of T and the complexity of the Max-SLNR plus Max-ANLNR is a linear function. The former increases cubically with T while the latter increases linearly with T . In general, N ≥ (KT +M ), so the number of antennas N at transmitter plays a dominant role in complexity. If we fix the values of K, T , and M , then the complexities of the three methods are cubic functions of N . In other words, they have the same magnitude complexity. IV. SIMULATIONS RESULTS Below, the performance of the two proposed methods will be evaluated. Simulation parameters are as follows: d = λ/2, N = 16, K = 2, T1 = T2√= M = 2, θd1 = {30◦ , 45◦ }, θd2 = {120◦, 135◦ }, β1 = 0.9, and QPSK modulation is used to evaluate the BER performance. 10-1 10-2 BER 10-4 10-3 30 10-4 10-5 15 Secrecy Sum Rate(bits/s/Hz) 100 conventional BD method in [15] is used as a performance reference. Parts (a) and (b) correspond to group 1 and group 2, respectively. It is seen from Part (a) that each BER curve achieves two local lowest values at the two desired directions of group 1: 30◦ and 45◦ , and rapidly rises up to more than 0.1. Clearly, the BER performances of the proposed two methods are better than that of BD along the desired directions. Additionally, the proposed two methods form two BER main beams around the two desired directions. Outside the two main beams, the BER performance degrades seriously. In other words, if eavesdroppers lie outside the two main beam, then it is extremely difficult for them to recovery the confidential message stream successfully. Observing Part (a), it is obvious that the Max-SLNR plus Max-ANLNR performs much better than the Max-GRP plus NSP at two desired directions. Part (b) plots the BER performance for group 2. Obviously, the same performance tendency is observed as Part (a). 30 60 90 5 Max-GRP plus NSP Max-SLNR plus Max-ANLNR BD in [15] 60 0 Max-SLNR plus Max-ANLNR Max-GRP plus NSP BD in [15] 0 10 120 150 0 5 10 15 SNR(dB) 20 25 (a) Group 1 180 Direction angle (deg.) 15 (a) Group 1 Secrecy Sum Rate(bits/s/Hz) 100 10-1 BER 10-2 10-4 10-3 10 5 Max-GRP plus NSP Max-SLNR plus Max-ANLNR BD in [15] 120 10-4 0 Max-SLNR plus Max-ANLNR Max-GRP plus NSP BD in [15] 0 30 60 90 0 120 150 180 Direction angle(deg.) (b) Group 2 Fig. 2. BER versus direction angle for two different desired user groups (SNR=14dB). Fig. 2 shows the curves of BER versus direction angle of the two proposed methods for two desired groups, where the 5 10SNR(dB)15 20 25 (b) Group 2 Fig. 3. Group secrecy sum-rate versus SNR for two different desired user groups. Fig. 3 illustrates the secrecy sum-rate (SSR) per group versus SNR of the two proposed methods for two desired groups. Here, Parts (a) and (b) plot the SSR performance for groups 1 and 2, respectively. In the two parts, it is evident that 5 the proposed two methods achieve an improvement over BD in SSR per group. From Part (a), it follows that the performance of the proposed Max-SLNR plus Max-ANLNR is slightly better than that of the Max-GRP plus NSP in the low SNR region, and much better than that of the latter in the medium and high SNR regions. As SNR increases, the performance gain over the Max-GRP plus NSP achieved by the proposed Max-SLNR plus Max-ANLNR increases gradually. Similar to Part (a), the same performance trend is seen in Part (b). To 100 ×10-3 8 6 10-1 BER 4 2 10-2 30 10-3 Max-GRP plus NSP Max-SLNR plus Max-ANLNR BD in [15] 0 30 60 90 120 150 180 150 180 Direction angle(deg.) (a) Group 1 100 0.015 10-1 BER 0.01 0.005 10-2 120 Max-GRP plus NSP Max-SLNR plus Max-ANLNR BD in [15] 10-3 0 30 60 90 120 Direction angle(deg.) (b) Group 2 Fig. 4. BER versus direction angle for two different desired user groups in the presence of direction measurement errors (SNR=14dB). evaluate the impact of direction measurement error on BER performance, Fig. 4 illustrates the BER performance of the two methods in the presence of direction angle measurement errors, where direction angle measurement errors are approximately modeled and normalized as uniform distributed random ∆θmax ◦ max variables in the interval [− ∆θ BW , BW ] with ∆θmax = 5 and BW = 2λ/(N d), where BW = 2λ/(N d) denotes the main beam bandwidth. From Parts (a) and (b), it is seen that the three methods become worse due to direction angle measurement errors. However, the proposed methods are more robust than BD. Comparing Fig. 4 and Fig. 2, we find that there is an-order-of-magnitude performance loss on BER due to errors. Further, it is certain that the proposed Max-SLNR plus Max-ANLNR method performs still better along the desired directions than the Max-GRP plus NSP, and their BER performance degrades and shows approximately the same BER performance outside two main desired beams. V. C ONCLUSION In this paper, two secure schemes, Max-GRP plus NSP and Max-SLNR plus Max-ANLNR, have been proposed for multicast DM scenario. From simulation, we find the proposed two methods behaves better than BD by means of BER and SSR per group. The Max-SLNR plus Max-ANLNR scheme performs much better than the Max-GRP plus NSP in accordance with BER and SSR per group regardless of direction measurement errors. Also, compared to the Max-SLNR plus Max-ANLNR, the Max-GRP plus NSP does not need variance of channel noise, and is simpler. Due to their good security and low-complexity, the proposed two schemes can be applied to the near future scenarios like unmanned aerial vehicle, satellite communications, and mmWave communications. R EFERENCES [1] A. D. Wyner, “The wire-tap channel,” Bell. Syst. Tech. J., vol. 54, no. 8, pp. 1355–1387, Oct. 1975. [2] N. Zhao, F. R. Yu, M. Li, Q. Yan, and V. C. Leung, “Physical layer security issues in interference-alignment-based wireless networks,” IEEE Commun. Mag., vol. 54, no. 8, pp. 162–168, Aug. 2016. [3] S. Yan, X. Zhou, N. Yang, B. He, and T. D. Abhayapala, “Artificialnoise-aided secure transmission in wiretap channels with transmitter-side correlation,” IEEE Trans. Wireless Commun., vol. 15, no. 12, pp. 8286– 8297, Dec. 2016. [4] Y. L. Zou, B. Champagne, W. P. Zhu, and L. Hanzo, “Relay-selection improves the security-reliability trade-off in cognitive radio systems,” IEEE Trans. Commun., vol. 63, no. 1, pp. 215–228, Jan. 2015. [5] B. Li, Z. Fei, Z. Chu, and Y. Zhang, “Secure transmission for heterogeneous cellular networks with wireless information and power transfer,” IEEE Syst. J., vol. PP, no. 99, pp. 1–12, June 2017. [6] B. Li, Z. Fei, and H. Chen, “Robust artificial noise-aided secure beamforming in wireless-powered non-regenerative relay,” IEEE Access, vol. 4, pp. 7921–7929, Nov. 2016. [7] A. Maha, D. Spano, A. Kalantari, C. Tsinos, D. Christopoulos, S. Chatzinotas, and B. Ottersten, “Symbol-level and multicast precoding for multiuser multiantenna downlink: A survey, classification and challenges,” arXiv preprint, vol. 3, no. 1, pp. 1–21, Mar. 2017, arXiv:1703.03617. [8] A. Kalantari, M. Soltanalian, S. Maleki, S. Chatzinotas, and B. Ottersten, “Directional modulation via symbol-level precoding: A way to enhance security,” IEEE Jour. on Sel. Topics in Signal Process., vol. 10, no. 8, pp. 1478–1493, Dec. 2016. [9] A. Babakhani, D. Rutledge, and A. Hajimiri, “Transmitter architectures based on nearfield direct antenna modulation,” IEEE J. Solid-State Circuits, vol. 43, no. 12, pp. 2674–2692, Dec. 2008. [10] M. P. Daly and J. T. Bernhard, “Directional modulation technique for phased arrays,” IEEE Trans. Antennas Propag., vol. 57, no. 9, pp. 2633– 2640, Sep. 2009. [11] Y. Ding and V. Fusco, “A vector approach for the analysis and synthesis of directional modulation transmitters,” IEEE Trans. Antennas Propag., vol. 62, no. 1, pp. 361–370, Jan. 2014. [12] J. S. Hu, F. Shu, and J. Li, “Robust synthesis method for secure directional modulation with imperfect direction angle,” IEEE Commun. Lett., vol. 20, no. 6, pp. 1084–1087, Jun. 2016. [13] F. Shu, X. M. Wu, J. Li, R. Q. Chen, and B. Vucetic, “Robust beamforming scheme for secure multi-beam directional modulation in broadcasting systems,” IEEE Access, vol. 4, pp. 6614–6623, Oct. 2016. [14] E. Karipidis, N. D. Sidiropoulos, and Z.-Q. Luo, “Far-field multicast beamforming for uniform linear antenna arrays,” IEEE Trans. Sig. Proc., pp. 4916–4927, Oct. 2007. [15] L.-U. Choi and R. D. Murch, “A transmit preprocessing technique for multiuser MIMO systems using a decomposition approach,” IEEE Trans.Wireless Commun., vol. 3, no. 1, pp. 20–24, Jan. 2004.
7cs.IT
arXiv:1711.04998v1 [math.GR] 14 Nov 2017 Duality between p-groups with three characteristic subgroups and semisimple anti-commutative algebras S. P. Glasby, Frederico A. M. Ribeiro and Csaba Schneider Abstract. Let p be an odd prime and let G be a non-abelian finite p-group of exponent p2 with three distinct characteristic subgroups, namely 1, Gp , and G. The quotient group G/Gp gives rise to an anti-commutative Fp -algebra L such that the action of Aut(L) is irreducible on L; we call such an algebra IAC. This paper establishes a duality G ↔ L between such groups and such IAC algebras. We prove that IAC algebras are semisimple and we classify the simple IAC algebras of dimension at most 4 over certain fields. We also give other examples of simple IAC algebras, including a family related to the m-th symmetric power of the natural module of SL(2, F). 2010 Mathematics subject classification: 20D15, 20C20, 20E15, 20F28, 17A30, 17A36 1. Introduction In a striking result, Helleloid and Martin [HM07] proved that the outer automorphism group Out(G) of a finite p-group G is almost always a p-groups. From this point of view, one might say that a p-group G is ‘interesting’ if Out(G) is ‘interesting’; for example, if Out(G) is insolvable, or Out(G) induces an irreducible subgroup on G/Φ(G) where Φ(G) is the Frattini subgroup of G. A class of these atypical p-groups is studied in this paper. A subgroup N of a group G is called characteristic if it is invariant under each automorphism α ∈ Aut(G). A group G with a unique non-trivial proper characteristic subgroup is abbreviated a UCS group. Finite UCS groups were studied by Taunt [Tau55] and later finite UCS p-groups were explored by the first and the third authors in collaboration with P. P. Pálfy [GPS11]. The characteristic subgroups of a finite UCS p-group G are 1, Φ(G), and G. The exponent of a finite UCS p-group G is either p or p2 . This paper focuses on finite non-abelian UCS p-groups of exponent p2 . For a finite UCS p-group G, the linear group induced by Out(G) on G/Φ(G) is irreducible, and in particular Op (Out(G)) acts trivially on G/Φ(G), which is rather conspicuous in the light of the aforementioned theorem of Helleloid and Martin. Date: November 15, 2017. 1 2 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER The fact that Out(G) is a p-group for almost all finite p-groups G also implies that finite p-groups have a rich structure of characteristic subgroups, which is used in the optimization of the standard algorithms for computing Aut(G); see for instance [ELGO02, Wil13]. However, when G does not have characteristic subgroups apart from the usual verbal subgroups, such optimization techniques fail. In particular, the algorithms for computing Aut(G) that are based on orbit-stabilizer calculation would perform poorly on UCS p-groups. Nevertheless, our paper shows that UCS p-groups of exponent p2 have a rigid algebraic structure that, in theory, can be exploited also in automorphism group computations, in a way which is rather similar to the philosophy pursued by J. B. Wilson and his collaborators in their recent work [BW12, BMW17, Wil17]. The rigid structure mentioned in the previous paragraph comes from the correspondence that is described in [GPS11, p. 86] between irreducible Fp H-modules V with the ∼ V for some U 6 ∧2 V (in [GPS11], we called such G-modules property that ∧2 V/U = ∼ G/Φ(G). ESQ, for exterior self-quotient) and UCS p-groups G of exponent p2 with V = 2 If V is such an ESQ H-module then the natural projection ∧ V → V can be viewed as an anti-commutative multiplication on V which turns V into an anti-commutative algebra L. The group H becomes an irreducible subgroup of Aut(L). This paper explores various connections between the class of UCS p-groups of exponent p2 and the class of finite-dimensional anti-commutative algebras whose automorphism groups are irreducible. Such algebras will be referred to as IAC algebras (for irreducible and anti-commutative). The main results of this paper show that, for an odd prime p, there is a bijection between the class of finite UCS p-groups of exponent p2 and the class of IAC algebra over Fp . Further, there is a correspondence between the subgroup structure of such a p-group and the subalgebra structure of the corresponding algebra under which normal subgroups are matched with ideals. Several connections exist between the theory of finite groups and the theory of nonassociative algebras and, indeed, any reader could name several theorems that link groups to Lie algebras. In constructing an explicit embedding of HS into E7 (5), the authors of [KMR99] used an anti-commutative algebra with an irreducible automorphism group, and their Lemma 2.4 drew similar conclusions to our Theorem 4.2. More recently, R. A. Wilson [Wil10] gave a new construction for the Suzuki groups using non-associative and commutative algebras over F2 . Closer to our context, symplectic alternating algebras arose in connection with the study of 2-Engel groups, see [Tra08b, PT16, ST15, ST16a, ST16b, Tra08a]. The p-groups G that we consider are nilpotent of class 2, and hence they are also 2-Engel. Although our IAC algebras are related to the exterior square ∧2 V, and symplectic alternating algebras are related to the exterior cube ∧3 V where V = G/Φ(G), parallels do exist between the two group–algebra paradigms. IAC algebras are related to irreducible ESQ G-modules. It was observed in [BH04] that a similar connection exists between Lie algebra modules that satisfy the corresponding property and IAC algebras. Indeed, the authors of [BH04] considered the exterior squares of some irreducible representations of the Lie algebra sl(2) in the same way as we UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 3 consider such representations for GL(2, F) in Theorem 7.1 and they defined non-associative anti-commutative algebras as we do in Theorem 8.1. In addition, they explicitly computed the structure constant tables for the resulting 3, 7, and 11-dimensional algebras, noting that the 3-dimensional algebra is the simple Lie algebra sl(2) (as implied also by our Proposition 5.1), while the 7-dimensional algebra is the non-Lie simple Malcev algebra. This fact is further exploited in [BD12] for the study of the polynomial identities of the Malcev algebra. In Section 2, we review some known properties of UCS p-groups before we establish in Section 3 a duality between the class of UCS p-groups of exponent p2 , and the class of IAC algebras. In Section 4 we prove that IAC algebras are semisimple, and that their subalgebras correspond to powerful subgroups of UCS groups. We address the classification of simple IAC algebras of dimension at most 4 in Section 5, and an infinite class of examples of simple IAC algebras, with widely varying dimensions, is given in Section 6. We prove a general version, which is valid also in prime characteristic, of the Clebsch-Gordan decomposition for tensor squares, exterior squares and symmetric squares of GL(2, F)-modules in Section 7, and apply it in Section 8 to construct some simple IAC algebras related to representations of SL(2, F). 2. UCS p-groups of exponent p2 It is useful to review some properties of UCS groups. Lemma 2.1 ([GPS11, Lemma 3]). Suppose that G is a finite non-abelian UCS p-group and 1 ✁ N ✁ G are the only characteristic subgroups of G. Then the following hold: (a) G ′ = Φ(G) = Z(G) = N and Gp = 1 or Gp = N; (b) the groups G/N and N are elementary abelian p-groups. Lemma 2.2 ([GPS11, Theorem 4]). Let G be a finite p-group such that G/Φ(G) and Φ(G) are non-trivial elementary abelian p-groups. Then G is a UCS group if and only if Aut(G) induces an irreducible linear group on both G/Φ(G) and on Φ(G). Consider, for a group G, the natural homomorphism G → G/Φ(G). For g ∈ G and for H 6 G we write g and H instead of gΦ(G) and HΦ(G)/Φ(G), respectively. In particular, G = G/Φ(G). Lemma 2.3 ([GPS11, Theorem 4(iii)]). Let G be a finite UCS p-group of odd exponent p . Then the map ϕ : G → Φ(G) defined by gϕ = gp is a well-defined isomorphism between the Fp Aut(G)-modules G and Φ(G). In particular, |G| = |Φ(G)|. 2 Suppose that G is a UCS p-group of odd exponent p2 and let g ∈ G. By Lemma 2.3, defining gp = gϕ = gp , we obtain a well-defined isomorphism between the Fp Aut(G)modules G and Φ(G). If h ∈ Φ(G), then let h1/p denote the unique preimage hϕ−1 ∈ G 4 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER of h under ϕ. Thus for every g ∈ G and h ∈ Φ(G) we have (1) (gp )1/p = g and (h1/p)p = h. Theorem 2.4 ([Tau55, Theorem 2.1]). Suppose that G is a UCS group, and N is its proper non-trivial characteristic subgroup. Assume further that Aut(G) fixes no nontrivial element of N ∪ G/N. Then the direct power Gk is a UCS group for all k > 1, and Nk is a characteristic subgroup of Gk . 3. UCS p-groups and IAC algebras We consider non-associative F-algebras L over a field F satisfying xx = 0 for all x ∈ L. Our focus will be when char(F) 6= 2. Such an algebra is called anti-commutative because yx = −xy holds for all x, y ∈ L. As these algebras are more similar to Lie algebras than to associative algebras, we henceforth write the product xy as Jx, yK. An anti-commutative algebra L for which Aut(L) acts irreducibly on L will be called IAC algebra (for i rreducible and anti-commutative). Let p be an odd prime and let G be a UCS p-group of exponent p2 . By Lemma 2.3, the map G → Φ(G), defined by x 7→ xp is an isomorphism of Aut(G)-modules. Given λ ∈ Fp and x ∈ G, considering λ as an integer between 0 and p − 1, the scalar action λx = xλ is well-defined and turns G into a vector space over Fp . It is less obvious that the following product Jx, yK for x, y ∈ G is well-defined: (2) Jx, yK = [x, y]1/p where x, y ∈ G and [x, y] = x−1 y−1 xy. Henceforth L(G) = (G, +, J·, ·K) will denote this Fp -algebra. Lemma 3.1. Suppose that p is an odd prime and G is a finite UCS p-group of exponent p2 . Then L(G) defined above is an IAC algebra over Fp . Proof. We first prove that the operation J·, ·K given by equation (2) is well-defined. Let v1 , v2 , w1 , w2 ∈ G such that v1 = v2 and w1 = w2 . Then v2 = v1 zv and w2 = w1 zw with zv , zw ∈ Φ(G). As zv and zw are central, and G has nilpotency class 2, we obtain that [v2 , w2 ] = [v1 , w1 ], and so [v2 , w2]1/p = [v1 , w1 ]1/p . Thus the value of J·, ·K is independent of the choice of coset representatives, and J·, ·K is well-defined. We prove next that J·, ·K distributes over the addition in G. Take u, v, w ∈ G and note that [u, vw] = [u, v][u, w] holds since G has nilpotency class 2. Therefore Ju, v + wK = [u, vw]1/p = ([u, v][u, w])1/p = [u, v]1/p[u, w]1/p = Ju, vK + Ju, wK. In addition, Jv, vK = [v, v]1/p = 11/p , equals the zero element of G. Hence Jv, vK = 0 for all v ∈ G. An automorphism α ∈ Aut(G) induces an Fp -linear transformation α : G → G UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 5 and a (restricted) isomorphism α ↓ : Φ(G) → Φ(G). Then, by Lemma 2.3, the map ϕ : x 7→ xp intertwines α↓ and α, i.e. (3) ϕ(α↓) = αϕ (α↓)ϕ−1 = ϕ−1 α. or Hence Ju, vKα = [u, v]1/pα = [u, v]ϕ−1 α = [u, v](α↓)ϕ−1 = [uα, vα]ϕ−1 = [uα, vα]1/p = Ju α, v αK. Thus α ∈ Aut(L(G)). By Lemma 2.2, Aut(G) induces an irreducible subgroup of GL(G). Thus Aut(L(G)) is irreducible on G, and L(G) is an IAC algebra as claimed.  In characteristic 2, we need not have |G/Φ(G)| = |Φ(G)| as in Lemma 2.3. For example, a non-abelian group G of order 8 is UCS and satisfies |G/Φ(G)| = 4 > 2 = |Φ(G)|. Although our construction of L(G) works more generally, namely when p > 2 and G 2 satisfies 1 < Φ(G) 6 Z(G), |G| = |Φ(G)|, and Gp = 1, the resulting anti-commutative algebra L(G) need not be an irreducible Aut(L)-module when G is not a UCS group. Given an algebra L, the subspace JL, LK is invariant under Aut(L). Thus if L is an IAC algebra, we have JL, LK = 0 or JL, LK = L. If L = L(G) for some finite UCS p-group G of exponent p2 , then JL, LK = 0 occurs if and only if G is abelian. We will usually assume that this is not the case; that is, JL, LK = L holds. Adopting the terminology from Lie algebras, an anti-commutative algebra L is said to be abelian if JL, LK = 0. The following result shows that the construction in Lemma 3.1 can be reversed. Theorem 3.2. Given an odd prime p and a finite-dimensional IAC algebra L over Fp , ∼ L. there exists a finite UCS p-group G = G(L) of exponent p2 such that L(G) = In Theorem 3.5 we show that G = L−1 , see Remark 3.4. Proof. Suppose that L has (finite) dimension r over Fp and {v1 , . . . , vr } is a basis. ∼ L in If L is abelian, then we take G to be the homocyclic group (Cp2 )r . Clearly, L(G) = this case, and so in the rest of the proof we assume that L is a non-abelian IAC algebra. Let H = Hp,r be the r-generator free group in the variety of groups that have exponent dividing p2 , nilpotency class at most 2 and have the property that all p-th powers are (i,j) central. Assume that ck are the structure constants of L; that is, (4) Jvi , vj K = r X (i,j) ck vk k=1 (i,j) for all 1 6 i < j 6 r. We consider the constants ck as elements of the field Fp as well as integers in {0, . . . , p − 1}. Suppose that h1 , . . . , hr are generators of H. Define N 6 H 6 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER as the subgroup (5) N= * [hi , hj ]−1 r Y (hpk ) (i,j) ck + |16i<j6r . k=1 As N 6 Φ(H) 6 Z(H), the subgroup N is normal in H. Further, considering Φ(H) as an r Fp -vector space, the given generators of N are linearly independent, and hence |N| = p(2) . Set G = H/N. Then G is a finite p-group, and so the Frattini subgroup of G is Gp G ′ = (H/N)p(H/N) ′ = (Hp H ′ N)/N = Φ(H)/N. On the other hand, since Φ(G) = Gp G ′ and the relations in N imply that G ′ 6 Gp , we find that Φ(G) = Gp . Since Φ(G) 6 Z(G) and Φ(G)p = 1, the map ϕ : G → Φ(G) r defined by g 7→ gp is a surjective Aut(G)-module homomorphism. Since |Φ(H)| = pr+(2) by [GPS11, p. 87], we have |G| = |Φ(G)| = pr , and the map g 7→ gp is an isomorphism. As remarked before this theorem, G satisfies sufficient conditions for us to construct the anti-commutative algebra L(G), as in Lemma 3.1. Set gi = hi N for 1 6 i 6 r, and define the linear map ξ : L → G by vi ξ = gi for all i. We claim that ξ is an isomorphism of Fp -algebras. Indeed, by (2) and (5) we have !1/p r Y (i,j) Jvi ξ, vj ξK = Jgi , gj K = [gi , gj ]1/p = . (gpk )ck k=1 Using (1) and (4) this equals r Y k=1 c (gpk )1/p k (i,j) = r Y (i,j) (gk )ck = Jvi , vj Kξ. k=1 Since |L| = |G| = pr and ξ is surjective, it follows that ξ is an Fp -isomorphism. We claim that G is a UCS p-group of exponent p2 . The construction of the p-group G ensures that G and Φ(G) are elementary abelian. By Lemma 2.2, it suffices to show that Aut(G) acts irreducibly on G and on Φ(G). Fix α ∈ Aut(L) and write vi α = r X aik vk where i ∈ {1, . . . , r} and aik ∈ Fp . k=1 As H is a relatively free group, there is a homomorphism α∗ : H → H satisfying r Y ∗ where aik ∈ {0, 1, . . . , p − 1}. hi α = hak ik k=1 By Burnside’s Basis Theorem, α∗ ∈ Aut(H). We claim that N is invariant under α∗ . Define ψ : H ′ → Hp as the linear map that Qr (i,j) acts on the generators of H ′ by [hi, hj ]ψ = k=1 (hpk )ck for all i < j. Note that the UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 7 subgroup N equals {h−1 (hψ) | h ∈ H ′ }. It suffices to show that ψα∗ = α∗ ψ, since this equality implies that (h−1 (hψ))α∗ = (hα∗ )−1 (hα∗ )ψ for all h ∈ H ′ , and, in turn, that N is invariant under α∗ . Define γ : Hp → L by hpi γ = vi and observe that γ is a linear isomorphism. Similarly γ ∧ γ : H ′ → ∧2 L defined by [hi , hj ] 7→ vi ∧ vj is a linear isomorphism onto the exterior square ∧2 L of L. The map M : ∧2 L → L defined by (u ∧ v)M = Ju, vK is an epimorphism since L = JL, LK. These maps are illustrated in Diagram (6): ψ H′ (6) γ∧γ M Λ2 L α∗ γ∧γ Λ2 L Hp α α∧α H′ γ−1 L M L α∗ γ−1 Hp . ψ Since each square piece of Diagram (6) is commutative, it follows that ψ = (γ ∧ γ)Mγ−1. Therefore ψα∗ = α∗ ψ, as claimed, which, in turn, implies that N is invariant under e of G = H/N. Recall that ξ : L → G satisfies α∗ . Hence α∗ induces an automorphism α vi ξ = gi . It is straightforward to see that the following Diagram (7) is commutative: H (7) α∗ H H/N = G e α H/N = G G/Φ(G) = G ξ−1 α α G/Φ(G) = G L ξ L. Hence the equation α = ξ−1 αξ relates α ∈ Aut(L) and α ∈ Aut(G). Therefore ξ−1 Aut(L)ξ is contained in the group induced by Aut(G) on G, and so Aut(G) acts irreducibly on G. At the start of the proof we showed that G and Φ(G) are isomorphic as Aut(G)-modules. Thus Aut(G) is irreducible on Φ(G) also, and by Lemma 2.2, G is a UCS p-group of exponent p2 .  Finite p-groups are commonly expressed using polycyclic presentations, see [HEO05, Chapter 8]. Corollary 3.3. Let L be an IAC algebra over Fp , p odd, with basis {v1 , . . . , vr } and Pr (i,j) (i,j) suppose Jvi , vj K = k=1 ck vk where ck ∈ Fp . Then the UCS group G(L) defined in 8 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER Theorem 3.2 is isomorphic to the group given by the polycyclic presentation (8) G = hg1 , . . . , gr , z1, . . . , zr | gpi = zi , zpi = [zj , gi] = [zi , zj ] = 1, [gi , gj ] = r Y c (i,j) zkk , i < ji. k=1 (i,j) Proof. Identify the scalars ck ∈ Fp in (8) with integers in the set {0, 1, . . . , p − 1}. The group presentation (8) is called a polycyclic presentation, and it has the property that the elements of the group defined by the presentation can be expressed in the form x gx11 · · · gxr r z1r+1 · · · zxr 2r where the exponents satisfy 0 6 xi 6 p − 1 for 1 6 i 6 2r. This shows that |G| 6 p2r . If equality holds, the presentation is called consistent, see [HEO05, page 280]. Recall in the proof of Theorem 3.2 that G(L) := H/N where H = Hp,r and N is the normal subgroup defined by (5). Suppose, as in the proof of Theorem 3.2, that H is generated by h1 , . . . , hr . Since the map χ : G → H/N defined by giχ = hi N and zi χ = hpi N preserves the relations in (8), it is a homomorphism. However χ is surjective, so χ is an isomorphism, and the presentation (8) must be consistent.  For an odd prime p, let IACp denote the set of isomorphism classes of finite dimensional IAC algebras over Fp and let UCSp2 denote the set of isomorphism classes of finite UCS p-groups of exponent p2 . Remark 3.4. We have well-defined maps on isomorphism classes UCSp2 → IACp with [G] 7→ [L(G)] as per Lemma 3.1 and IACp → UCSp2 with [L] 7→ [G(L)] as per Theorem 3.2. It is convenient to identify isomorphism classes [G] and [L] with G and L ∼ . With this abuse in mind, L and G can be viewed as respectively, and use = instead of = mutually inverse functions. Theorem 3.5. Let p be an odd prime. (a) If G is a finite UCS group of exponent p2 , then G(L(G)) = G. (b) If L is a finite-dimensional IAC algebra over Fp , then L(G(L)) = L. Therefore the maps G : IACp → UCSp2 and L : UCSp2 → IACp are bijections. Proof. (a) Let G be a finite UCS p-group of exponent p2 , say with r generators. Suppose that {g1 , . . . , gr } is a minimal generating set for G. Since G ′ = Gp there exist (i,j) constants ck satisfying: r Y (i,j) (i,j) (gpk )ck where 1 6 i < j 6 r and 0 6 ck 6 p − 1. (9) [gi , gj ] = k=1 Introducing redundant generators zk := gpk we see that G has a polycyclic presentation Pr (i,j) of the form (8). It follows from (2) that Jgi , gj K = k=1 ck gk . Therefore the numbers UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 9 (i,j) ck , interpreted as elements of the field Fp , are structure constants of L := L(G). By Corollary 3.3 the group G(L) has a polycyclic presentation of the form (8) involving the (i,j) ∼ G as desired. same ck . This proves that G(L(G)) = (b) Let L be a finite-dimensional IAC algebra over Fp . Theorem 3.2 proves precisely ∼ L where the minimal number of generators of G(L) is dim(L).  that L(G(L)) = We denote the kernel of the homomorphism Aut(G) → Aut(G/Z(G)) by Autc (G). The elements of Autc (G) are called central automorphisms of G. Theorem 3.6. Let G be an r-generator UCS p-group of exponent p2 where p > 2, and ∼ Aut(L) where Autc (G) is elementary abelian of let L = L(G). Then Aut(G)/Autc (G) = r2 order p . Proof. Let G be an r-generator UCS p-group of exponent p2 . Write A = Aut(G). Each α ∈ A induces and α ∈ Aut(G) defined by gα = (gα)Φ(G) and α 7→ α is a homomorphism. The additive group of L := L(G) is G, and it was shown in the proof of Theorem 3.2 that α 7→ α defines a surjective homomorphism Aut(G) → Aut(L). The kernel K of this epimorphism comprises those α ∈ A with g α = g for all g ∈ G. Since Φ(G) = Z(G), K is the group Autc (G) of central automorphisms. Therefore ∼ Aut(L) as claimed. Aut(G)/Autc (G) = Let α ∈ K be a central automorphism. Then gα = gzg for some zg ∈ Z(G) for all g ∈ G. Since [g1 α, g2 α] = [g1 , g2 ] and G ′ = Z(G), we see that α acts as the identity on Z(G). Hence zg depends only on the coset gΦ(G) = g and we may write zg = zg . This gives a function G → Z(G) defined by g 7→ zg . There is a well-known isomorphism Autc (G) → HomFp (G, Z(G)) taking α to the map g 7→ zg . However, HomFp (G, Z(G)) is isomorphic to the additive group of r × r matrices over Fp . Thus Autc (G) is elementary 2 abelian of order pr . (By contrast, the group Inn(G) of inner automorphisms, which is a subgroup of Autc (G), has order only pr .)  4. The structure of UCS p-groups and IAC algebras In this section we prove that a finite-dimensional IAC algebra over an arbitrary field is semisimple in the sense that it is a direct sum of pairwise isomorphic simple algebras. This leads naturally to the study of simple IAC algebras in Section 5. As noted in the introduction, invariant non-associative algebra structures also appeared in the study of finite simple groups, and a result similar to our Theorem 4.2 was proved in [KMR99, Lemma 2.4]. Since our context is somewhat different, we present our theorem with a proof. We will also extend the group–algebra duality established in Section 3. In Proposition 4.4 we exhibit a bijection between subalgebras of L and powerful subgroups of G = G(L) that contain Φ(G). This is reminiscent of the duality between field extensions and groups in Galois theory, because the substructures match. 10 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER Let V be a vector space. An irreducible subgroup H of GL(V) is called imprimitive if there is an H-invariant direct sum decomposition V = V1 ⊕ · · · ⊕ Vℓ with ℓ > 2, We call the decomposition V = V1 ⊕ · · · ⊕ Vℓ an imprimitivity decomposition for H. If no such decomposition exists, we call H primitive. By the irreducibility of the acting group, an imprimitivity decomposition is necessarily equidimensional; that is dim Vi = dim Vj for all subspaces Vi , Vj of the decomposition. Suppose that V = V1 ⊕ · · · ⊕ Vℓ is an imprimitivity decomposition for an irreducible subgroup H 6 GL(V). Then the action of H induces a permutation group on the set {V1 , . . . , Vℓ }. Further, H is isomorphic (as a linear group) to a subgroup of the wreath product GL(r/ℓ, F) ≀ K where r = dim V and K 6 Sℓ is permutationally isomorphic to the group induced by H on {V1 , . . . , Vℓ }. The structure of GL(r/ℓ, F) ≀ Sℓ is described in [Sup76, Section 15]. The following theorem is commonly attributed to Clifford, see [Sup76, Lemma 4, Section 15]. Theorem 4.1. The following hold. (a) Given a vector space V1 over a field F, a non-trivial subgroup A1 6 GL(V1 ), and a transitive subgroup P 6 Sℓ , the subgroup A1 ≀ P of GL((V1 )⊕ℓ ) is irreducible if and only if A1 is irreducible on V1 . (b) Suppose that A 6 GL(V) is irreducible on the vector space V and preserves the imprimitivity decomposition V = V1 ⊕ · · · ⊕ Vℓ . Then A is conjugate in GL(V) to a subgroup of GL(V1 ) ≀ Sℓ . Further, A is transitive on {V1 , . . . , Vℓ } and the setwise stabilizer AV1 is irreducible on V1 . Using Lie theoretic notation, the center of an anti-commutative algebra L is Z(L) := {x ∈ L | Jx, yK = 0 for all y ∈ L}. Since Z(L) is invariant under Aut(L), we see, for a non-abelian IAC algebra L, that Z(L) = 0. The next theorem shows that an IAC algebra (over an arbitrary field) is semisimple. See [KMR99, Lemma 2.4] for a similar result. Theorem 4.2. The following hold. (a) Suppose L0 is a simple IAC algebra, and ℓ > 1 is an integer. Then the direct sum L = (L0 )⊕ℓ is an IAC algebra. Further, if L0 is non-abelian, then L = (L0 )⊕ℓ has precisely ℓ minimal ideals namely the given direct summands, and in particular Aut(L) = Aut(L0 ) ≀ Sℓ . ∼ I⊕ℓ for some simple IAC (b) Let L be an IAC algebra of finite dimension. Then L = subalgebra I of L and some ℓ > 1. Further, if L is non-abelian, then ℓ is the number of minimal ideals of L. Proof. (a) If L0 is abelian, then so is L. Thus dim(L0 ) = 1 and Aut(L) = GL(L) acts irreducibly. Hence L is IAC. UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 11 Suppose now that L0 is non-abelian. Let L1 , . . . , Lℓ be the summands of the direct sum decomposition of L. Then, for i > 1, Li is a minimal ideal of L. We claim that each minimal ideal I coincides with Li for some i > 1. Assume, seeking a contradiction, that I 6= Li for all i > 1. Then, the minimality of I implies JLi , IK ⊆ Li ∩ I = 0 for all i > 1. Thus JL, IK = 0, and so I 6 Z(L); this is a contradiction as Z(L) = 0. Therefore L1 , . . . , Lℓ are all the minimal ideals of L as claimed. Now Aut(L) contains the wreath product W = Aut(L0 ) ≀ Sℓ and W is an irreducible subgroup of GL(L) by Theorem 4.1(a). Thus L is an IAC algebra. The group Aut(L) permutes the minimal ideals of L, and hence L = L1 ⊕ · · · ⊕ Lℓ is an imprimitivity decomposition of Aut(L). Further, the stabilizer of Li in Aut(L) induces a group of automorphisms of Li , which shows, by Theorem 4.1(b), that Aut(L) 6 Aut(L0 ) ≀ Sℓ . Therefore Aut(L) = Aut(L0 ) ≀ Sℓ as claimed. (b) Let L be a finite-dimensional IAC algebra and set A = Aut(L). If L is abelian, then L = F⊕ℓ where ℓ = dim(L), and each copy of F is a simple IAC algebra of dimension 1. Thus in this case the assertion is valid. Suppose that L is non-abelian. As notedP above, Z(L) = 0. Let I be a minimal ideal of L and set I = {Iα | α ∈ A}. Define K = J∈I J; then K is a nontrivial ideal of L which is invariant P under A. Thus K = L because A acts irreducibly on L. We show that the sum J∈I J is direct. Given J0 ∈ I, set P J0 = J∈I\{J0 } J. We are required to show that J0 ∩ J0 = 0. If J ∈ I \ {J0 }, then J0 ∩ J P L, and, by the minimality of J, we have that J0 ∩ J = 0. On the other hand, JJ0 , JK 6 J0 ∩ J, and hence JJ0 , JK = 0. Thus J0 centralizes each of the elements of I \ {J0 }, which gives that JJ0 , J0 K = 0. Then JJ0 ∩ J0 , LK = JJ0 ∩ J0 , J0 + J0 K = JJ0 ∩ J0 , J0 K = 0, which implies turn, that J0 ∩ J0 = 0. Thus L is equal to the L that J0 ∩ J0 6 Z(L), and, ∼in ⊕ℓ direct sum J∈I J as claimed. Write L = I where I is a minimal ideal of L and ℓ = |I|. It remains to show that I is IAC. As I inherits anti-commutativity from L, we need to show that Aut(I)Lis irreducible on I. Since Aut(L) permutes the elements of I, the decomposition L = J∈I J is an imprimitivity decomposition for Aut(L). Let AI denote the setwise stabilizer of I in Aut(L). Then AI induces a group of automorphisms of I that is irreducible on I by Theorem 4.1(b). Hence I is an IAC algebra.  Theorem 4.3. Let G be a finite UCS p-group of exponent p2 for some odd prime p ∼ L(G)⊕k . and let k > 1. Then Gk is a UCS p-group of exponent p2 and L(Gk ) = Proof. The assertion of the theorem holds if G is abelian, and so we may assume that G is non-abelian. Certainly Gk has exponent p2 . Moreover, ∼ (G/Φ(G))k = Gk . Φ(Gk ) = Φ(G)k and Gk /Φ(Gk ) = By Lemma 2.2, Aut(G) is irreducible on G and on Φ(G). Further, since G is non-abelian, G and Φ(G) are non-trivial Aut(G)-modules. Since Aut(G) ≀ Sk 6 Aut(Gk ), it follows from Theorem 4.1(a) that Aut(Gk ) acts irreducibly on Gk /Φ(Gk ) and on Φ(Gk ), and thus Gk is a UCS p-group, by Lemma 2.2. 12 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER ∼ L(G)⊕k . Let Gi denote the i-th copy of G in the direct We now prove that L(Gk ) = k k product G . Set L = L(G ) and, for i = 1, . . . , k, let Li = Gi Φ(Gk )/Φ(Gk ). We claim that Li P L. First, if u, v ∈ Li with u, v ∈ Gi , then Ju, vK = [u, v]1/p ∈ Li . Hence Li 6 L. If gi ∈ Gi and gj ∈ Gj with i 6= j, then [gi, gj ] = 1, and so Jgi , gj K = 0. This shows that Li is an ideal of L for each i ∈ {1, . . . , k}. Since k k k L(G ) = G /Φ(G ) = k M i=1 k k Gi Φ(G )/Φ(G ) = k M Li , i=1 and each Li is isomorphic to L(G), we obtain that L(Gk ) = L(G)⊕k .  Powerful p-groups were introduced by Lubotzky and Mann [LM87]. A finite p-group G is said to be powerful if G ′ 6 Gp when p > 2, and G ′ 6 G4 when p = 2. A subgroup N of a p-group G is said to be powerfully embedded in G if [N, G] 6 Np when p > 2 and [N, G] 6 N4 when p = 2. A powerfully embedded subgroup of G is always normal in G. Proposition 4.4. Let G be a finite UCS p-group of odd exponent p2 , and L = L(G). (a) There is a bijection between the set of subalgebras of L and the set of powerful subgroups of G that contain Φ(G). (b) The ideals of L correspond, via part (a), to powerfully embedded subgroups of G. Proof. There is a bijection H ↔ H := H/Φ(G) between the set of subgroups of G that contain Φ(G), and the set of subgroups of the quotient G = G/Φ(G). The subgroups of G are precisely the linear subspaces of L. We show first that H is a powerful subgroup of G if and only if H is a subalgebra of L which we henceforth denote as H 6 L. Suppose that H 6 L and let h1 , h2 ∈ H. Then Jh1 , h2 K ∈ H, and so Jh1 , h2 K = h with h ∈ H. The definition in (2) of the product in L implies that [h1 , h2 ] = hp , which shows that H ′ 6 Hp , and hence H is powerful. Conversely, suppose that H is powerful. Suppose h1 , h2 ∈ H. Then (h1 h2 )p = hp1 hp2 since p > 2, so the subgroup Hp = hhp | h ∈ Hi equals the subset {hp | h ∈ H}. Since H ′ 6 Hp , it follows that [h1 , h2 ] = hp for some h ∈ H. Thus Jh1 , h2 K = [h1 , h2 ]1/p = h ∈ H by (2), and so H 6 L . Suppose now that H is powerfully embedded in G. We have, for every h ∈ H and g ∈ G, that [h, g] = hp0 for some h0 ∈ H, and so Jh, gK = [h, g]1/p = h0 ∈ H. Hence H P L. On the other hand, suppose I P L. Then I = H for some H 6 G with Φ(G) 6 H. Since H is an ideal, for every h ∈ H and g ∈ G we have Jh, gK = h0 for some h0 ∈ H. Hence, [h, g]1/p = h0 , and so [h, g] = hp0 . Thus [H, G] 6 Hp and H is powerfully embedded in G.  By Theorem 4.2, every non-trivial proper ideal of an IAC algebra is a direct summand. Now we state and prove a corresponding result for UCS p-groups of exponent p2 . Corollary 4.5. Let G be a finite UCS p-group with odd exponent p2 . There exists a subgroup H of G satisfying the following conditions: UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 13 (a) H is powerfully embedded in G and Φ(G) < H, and (b) H is minimal among the subgroups of G satisfying (a). There exists a UCS subgroup H0 of G of exponent p2 such that G = (H0 )k for some k > 1, and H0 Φ(G) = H. Proof. A subgroup H satisfying conditions (a) and (b) does exist because G ′ 6 Gp and G satisfies condition (a). Set L = L(G) and L0 = H/Φ(G). By Lemma 3.1, L is an IAC algebra, and L0 P L by Proposition 4.4. Since L0 is minimal, and hence simple, L = (L0 )⊕k for some k > 1 by Theorem 4.2(b). However, H0 = G(L0 ) is a UCS group of exponent p2 by Theorem 3.2, and so too is (H0 )k by Theorem 4.3. However, L((H0 )k ) = L(H0 )⊕k = L(G(L0 ))⊕k = (L0 )⊕k = L. Therefore L((H0 )k ) = L(G). We obtain, by Theorem 3.5, that (H0 )k = G(L((H0 )k )) = G(L(G)) = G, and similarly L0 = L(G(L0 )) = L(H0 ). Finally, since L0 = H0 /Φ(H0 ) = H/Φ(G), we have H = H0 Φ(G).  By Theorem 2.4 (also by Theorem 4.3), if G is a UCS p-group of exponent p2 , then Gk is also a UCS p-group of exponent p2 . Hence in the class UCSp2 , the groups that cannot be decomposed non-trivially as direct powers can be viewed as basic building blocks. The final result of this section gives sufficient and necessary conditions for a UCS p-group of exponent p2 to be indecomposable as a direct power of a smaller such group. The corollary follows easily from Theorem 4.3 and Corollary 4.5. Corollary 4.6. The following are equivalent for a non-abelian finite UCS p-group of odd exponent p2 : (a) G cannot be written as a direct product Hk where H is a UCS p-group and k > 2; (b) G does not contain a powerfully embedded proper subgroup N such that Φ(G) < N; (c) L(G) is a simple algebra. 5. Simple IAC algebras of dimension at most 4  For an anti-commutative algebra of dimension r we have dimJL, LK 6 2r . Thus an r-dimensional IAC algebra is abelian and simple if r = 1, and abelian and nonsimple if r = 2. In this section we classify simple IAC algebras of dimension 3 and 4 in Proposition 5.1 and Theorem 5.3, respectively. 5.1. 3-dimensional IAC algebras. The proof of the following proposition uses ideas from the proof of [GPS11, Lemma 9]. Proposition 5.1. If L is a non-abelian 3-dimensional IAC algebra over a field F of ∼ SO(3, F). characteristic different from 2, then L is a simple Lie algebra and Aut(L) = Proof. Suppose that L is a non-abelian 3-dimensional IAC algebra. Let e = {e1 , e2 , e3 } be a basis for L and set f1 = Je2 , e3 K, f2 = Je3 , e1 K and f3 = Je1 , e2 K. Since JL, LK = L, 14 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER P3 we have that f = {f1 , f2 , f3 } is also a basis for L. Write fi = j=1 aij ej where aij ∈ F and i ∈ {1, 2, 3}, and consider the 3 × 3 invertible matrix A = (aij ). We claim that L satisfies the Jacobi identity if and only if A is symmetric. Since L is 3-dimensional, L satisfies the Jacobi identity if and only if the following equation holds: 0 = Je1 , Je2 , e3 KK + Je2 , Je3 , e1 KK + Je3 , Je1 , e2 KK = Je1 , f1 K + Je2 , f2 K + Je3 , f3 K. Using the linear combinations for the fi , we obtain the equivalent equation: a12 Je1 , e2 K + a13 Je1 , e3 K + a21 Je2 , e1 K + a23 Je2 , e3 K + a31 Je3 , e1K + a32 Je3 , e2 K = 0. Finally, the last equation is equivalent to the statement that A is a symmetric matrix. We now prove that A is a symmetric matrix. Let g ∈ Aut(L) and let [g]e and [g]f denote the matrices that represent g in the bases e and f, respectively. We claim that [g]f = det[g]e ([g]e )−t where (·)−t denotes the inverse transpose operation. Let [g]e = (gij ) and [g]f = (fij ). As g ∈ Aut(L), we have f1 g =Je2 , e3 Kg = Je2 g, e3gK = Jg21 e1 + g22 e2 + g23 e3 , g31e1 + g32 e2 + g33 e3 K =(g22 g33 − g23 g32 )Je2 , e3 K + (g23g31 − g21 g33 )Je3 , e1 K + (g21 g32 − g22 g31 )Je1 , e2K. This gives the first of the following equations, the others follow by cyclic permutations: f1 g = (g22 g33 − g23 g32 )f1 + (g23 g31 − g21 g33 )f2 + (g21 g32 − g22 g31 )f3 ; (10) f2 g = (g32 g13 − g33 g12 )f1 + (g33 g11 − g31 g13 )f2 + (g31 g12 − g32 g11 )f3 ; f3 g = (g12 g23 − g13 g22 )f1 + (g13 g21 − g11 g23 )f2 + (g11 g22 − g12 g21 )f3 . By Cramer’s Rule, the 3 × 3 system (10) has coefficient matrix det([g]e )([g]e)−t . Therefore [g]f = det([g]e )([g]e)−t , as claimed. For v ∈ L, let [v]e and [v]f denote vector representations of v in the bases e and f, respectively. The matrix A = (aij ) acts as a basis transformation matrix from the basis e to the basis f and [v]f = [v]e A. Therefore [g]e = A[g]fA−1 and so [g]e = A det([g]e)([g]e )−t A−1 , which implies that [g]e A[g]te = det([g]e)A. This says that g preserves the bilinear form (u, v) 7→ [u]e A([v]e )t up to a scalar multiple. In the next paragraph, we prove that At = A. Consider the group G(A) := {B ∈ GL(3, F) | BABt = det(B)A}. The previous paragraph shows that g ∈ Aut(L) implies [g]e ∈ G(A). Let J be the skew-symmetric matrix A − At , and define G(J) = {B ∈ GL(3, F) | BJBt = det(B)J} similarly. Clearly G(A) is a subgroup of G(J). Note that if w ∈ ker(J) and B ∈ G(J), then wBJ = wBJBt B−t = det(B)wJB−t = 0. Hence G(J) fixes the subspace ker(J) = {v ∈ F3 | vJ = 0}. Since Aut(L), considered as a subgroup of GL(3, F), is contained in G(A) and G(A) 6 G(J) and Aut(L) acts irreducibly on L, we see that ker(J) must be 0 or L. Further, since the UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 15 matrix J = A − At is skew-symmetric, we obtain that det(J) = det(Jt ) = det(−J) = (−1)3 det(J), and so 2 det(J) = 0. Thus, since char(F) 6= 2, det(J) = 0. Therefore ker(J) 6= 0, and hence ker(J) = L. Thus A − At = J = 0, and A is symmetric, as claimed. As explained in the first paragraphs of this proof, we obtain that L is a Lie algebra. Since L is non-abelian and IAC, Theorem 4.2 implies that L is the direct sum of pairwise isomorphic simple IAC algebras. As dim L = 3 and an IAC algebra of dimension 1 is abelian (see the paragraph before Proposition 5.1), the algebra L must be simple. Let g ∈ Aut(L). Since [g]e 6 G(A) we see that [g]e A([g]e )t = det(g)A. However, A is an invertible 3 × 3 matrix, so taking determinants gives det(g)2 det(A) = det(g)3 det(A). Hence det(g) = 1, and g preserves the symmetric bilinear form defined by A. Hence we have shown that Aut(L) lies in the subgroup SO(3, F) of G(A). Suppose g ∈ SO(3, F). The steps in the second paragraph of the proof are reversible, so it follows that g ∈ Aut(L). ∼ SO(3, F), as desired.  Thus we conclude that Aut(L) = Proposition 5.1 can be reversed: a 3-dimensional simple Lie algebra is IAC. This follows from the fact that the automorphism group of a 3-dimensional simple Lie algebra is isomorphic to the irreducible group SO(3, F) stabilizing its Killing form. If F is a finite field or an algebraically closed field of characteristic different from 2, then the only 3dimensional simple Lie algebra over F, up to isomorphism, is the classical Lie algebra sl(2, F) which is IAC. More generally, if n > 2, and F is a field of characteristic 0 or of characteristic p such that p ∤ n, then the group GL(n, F) acts on the simple Lie algebra sl(n, F) by the adjoint action g : x 7→ xg = g−1 xg for all x ∈ sl(n, F) and g ∈ GL(n, F). Since this action is irreducible (see [BHRD13, Lemma 5.4.10]), the simple Lie algebra sl(n, F) is IAC. It would be interesting to study whether all known finite-dimensional simple Lie algebras are IAC, but this problem goes beyond the scope of this paper. By [His84, Hauptsatz], if L is a finite-dimensional Chevalley type simple Lie algebra in characteristic different from 2, then L is IAC. Interesting examples of IAC algebras can also be found among Malcev algebras. For a field F of characteristic different from 2, the algebra O(F) of octonions can be viewed as an anti-commutative algebra under the multiplication Ja, bK = ab − ba. If char(F) 6= 3, then the algebra (O(F), +, J·, ·K) is not a Lie algebra, since O(F) is not associative. Further, the algebra (O(F), +, J·, ·K) can be written as F ⊕ M where M is a 7-dimensional anticommutative algebra and the simple exceptional group G2 (F) acts irreducibly on M (see [Wil09, Section 4.3]). Hence M is an IAC algebra. By [Kuz14, Theorem 3.11], non-Lie central simple Malcev algebras over fields of characteristic different from 2 or 3 are 7-dimensional and can be defined similarly to the algebra M above. By [Kuz14, Theorem 3.11], over a finite field of characteristic different from 2, there is a unique isomorphism type of central simple non-Lie Malcev algebras; namely, the algebra M defined above. 16 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER 5.2. 4-dimensional IAC algebras. In [GPS11, Theorem 17] the authors classified 4-generator UCS p-groups with exponent p2 . The bijection in Theorem 3.5 gives a classification of 4-dimensional simple IAC algebras over Fp where p is an odd prime. Using the ideas of the proof of [GPS11, Theorem 17], this classification is extended in Theorem 5.3 to all finite fields of characteristic different from 2. The concept of ESQ-modules was defined in [GPS11]. Let us recall the definition. Definition 5.2. For a group H and a field F, an FH-module V is called an ESQmodule (for exterior self-quotient) if there exists an FH-submodule U of ∧2 V such ∼ V. In this case, H is called an ESQ subgroup of GL(V). that ∧2 V/U = If A is a non-abelian finite-dimensional IAC algebra over a field F, then the product map ψ : ∧2 A → A, defined by (u ∧ v)ψ = Ju, vK, is an epimorphism of Aut(A)-modules. ∼ A, and so A is an irreducible ESQ FAut(A)-module. Conversely, let Hence ∧2 A/ ker ψ = V be an irreducible ESQ-module for a group H over a field F and let U 6 ∧2 V such that ∼ V. Assume that ψ : ∧2 V → V is an epimorphism with kernel U. Then we ∧2 V/U = can define an anti-commutative product on V by setting Ju, vK = (u ∧ v)ψ and we obtain that (V, +, J·, ·K) is an IAC algebra whose automorphism group contains H as a subgroup. Theorem 5.3. Let Fq be a finite field of q elements and assume that the characteristic of Fq is not 2. Then the following are valid. (a) If char(Fq ) = 5, then there exists no 4-dimensional simple IAC algebra over Fq . (b) If q ≡ ±1 (mod 5), then there exists, up to isomorphism, a unique 4-dimensional simple IAC algebra over Fq . Further, this algebra is isomorphic to the algebra given by the presentation he1 , e2 , e3 , e4 | Je1 , e2 K = e1 + e2 + 5e3 + 3e4 , Je1 , e3 K = −4e1 − 4e2 + 0e3 − 2e4 , Je1 , e4 K = 2e1 + 4e2 − 4e3 − 2e4 , Je2 , e3 K = −3e1 − 1e2 + 1e3 + 3e4 Je2 , e4 K = 2e1 + 0e2 + 4e3 + 4e4 , Je3 , e4 K = −3e1 − 5e2 − e3 − e4 i. (c) If q ≡ ±2 (mod 5), then, up to isomorphism, there are exactly two 4-dimensional simple IAC algebras over Fq ; one of these algebras is given by the presentation in statement (b). Moreover, the automorphism group of the algebra presented in (b) is AGL(1, 5), while the automorphism group of the second algebra in (c) is C5 . Proof. Since the proof follows the ideas in [GPS11, Theorem 17], we only give a sketch; the details can be filled in by the reader consulting [GPS11, Theorem 17]. (a) It follows from [GPS11, Theorem 16] that no irreducible ESQ subgroup of GL(4, q) exists if 5 | q, and hence over finite fields of characteristic 5, there are no 4-dimensional simple IAC algebras. This proves (a). UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 17 Suppose q = pk where p 6= 5 is a prime and k > 1. By quadratic reciprocity, 2 5 ∈ (F× q ) if and only if q ≡ ±1 (mod 5). To see this note first that q ≡ ±2 (mod 5) 2 × 2 implies p ≡ ±2 (mod 5) and k is odd, so 5 6∈ (F× p ) and 5 6∈ (Fq ) . On the other hand, × 2 2 × 2 if 5 ∈ (F× q ) , then either k is even and 5 ∈ (Fp2 ) 6 (Fq ) , or k is odd and p ≡ ±1 2 × 2 (mod 5) and so 5 ∈ (F× p ) 6 (Fq ) . (b) Let L be a 4-dimensional simple IAC algebra over Fq and set A = Aut(L). By the discussion preceding this theorem, A is an irreducible ESQ-subgroup of GL(4, q). We can argue, as in the proof of [GPS11, Theorem 17], that A 6 AGL(1, 5) contains C5 and that if A = AGL(1, 5), then L is isomorphic to the algebra presented in (b). By [GPS11, 2 Theorem 16], 5 ∈ (F× q ) if and only if no proper subgroup of AGL(1, 5) is irreducible. Hence in this case the algebra L presented in statement (b) is, up to isomorphism, the unique simple IAC algebra of dimension 4 over Fq , and Aut(L) = AGL(1, 5). (c) Assume now that q ≡ ±2 (mod 5). One possibility by [GPS11, Theorem 17] is that a simple 4-dimensional IAC algebra L is given by the presentation (b), and Aut(L) = AGL(1, 5). Suppose now that A 6= AGL(1, 5). The cyclic subgroup C5 of AGL(1, 5) is contained in A, and it is irreducible since q ≡ ±2 (mod 5). Let V be a 4-dimensional vector space over Fq . Let a ∈ GL(4, q) be an element of order 5, which is unique up to conjugacy. Then the hai-module ∧2 V can be written as ∧2 V = W ⊕C where ∼ V and C is the 2-dimensional fixed-point space of a. An IAC algebra structure on V W= is determined by an epimorphism ϕ : ∧2 V → V. As in the proof of [GPS11, Theorem 17], there is a bijection between the set of such linear epimorphisms and the set of subspaces N of V ⊕ ∧2 V such that dim N = 4, N ∩ V = 0, and N ∩ ∧2 V = C. If fact, identifying V and W with the field Fq4 , we may define, for each w ∈ W \ {0} such a subspace Nw exactly as in [GPS11, Theorem 17]. Now using the argument in [GPS11, Theorem 17], the multiplicative group of Fq4 acts on the set of subspaces Nw , inducing isomorphisms between the associated IAC algebras, with 5 orbits corresponding to the cosets of the ∼ C4 also acts on the set of these multiplicative subgroup (F× )5 . Then Gal(Fq4 : Fq ) = q4 subspaces Nw , also inducing isomorphism between the associated algebras, fusing the 4 orbits that correspond to non-trivial cosets and leaving the fifth orbit invariant. Therefore there are two F× ⋊ Gal(Fq4 : Fq )-orbits on the set of subspaces Nw , and there are two q4 isomorphism types of simple 4-dimensional IAC algebras.  6. r-dimensional simple IAC algebras In this section we construct an infinite family of finite-dimensional simple IAC algebras. We will work under the following hypothesis. Hypothesis 6.1. Fix an integer b > 2. Let n > 1 be a divisor of b2 + b − 1. Since b(b + 1) ≡ 1 (mod n), b is invertible modulo n, and let r be the multiplicative order of b modulo n. Suppose that r > 1 and let q be a prime power such that n | (q − 1). Let V = (Fq )r have basis e0 , e1 , . . . , er−1 . 18 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER There are infinitely many choices for a prime-power q with q ≡ 1 (mod n) by Dirichlet’s Theorem on primes in an arithmetic progression. Let ζ be an n-th root of unity in Fq and let G be the subgroup of GL(r, F) generated by the matrices     ζ 0 ... 0 0 1 0 0 ζb .. 0      .   A= and B =  . ..  .   0 0 1 br−1 1 0 ... 0 0 0 ... ζ −1 Direct calculation shows that Ar = Bn = 1 and BA = ABb where b−1 denotes the inverse of b modulo n. Let V = (Fq )r , and consider V and its exterior square ∧2 V as Gmodules. Since B is a diagonal matrix with pairwise distinct eigenvalues, and A cyclically permutes the 1-dimensional eigenspaces of B, we obtain that G acts irreducibly on V. Proposition 6.2. Assume Hypothesis 6.1 and let U1 = hei ∧ ej | j − i ≡ 1 mod ri = he0 ∧ e1 , e1 ∧ e2 , . . . , er−2 ∧ er−1 , er−1 ∧ e0 i ; U2 = hei ∧ ej | j − i 6≡ 1 mod ri . Then the following are valid: (a) ∧2 V = U1 ⊕ U2 is a G-invariant decomposition; (b) the map ψ : V → U1 defined by ei ψ = ei+1 ∧ ei+2 reading subscripts modulo r is a G-module isomorphism; and (c) V is an ESQ G-module. Proof. (a) Reduce the indices i modulo r if i > r. Then {ei ∧ ei+1 | 0 6 i 6 r − 1} is a basis element of U1 . Since (ei ∧ ei+1 )A = ei+1 ∧ ei+2 , we see that U1 A = U1 . A similar argument shows that U2 A = U2 . Since B is a diagonal matrix, we see that hei ∧ ej iB = hei ∧ ej i for all i < j, and hence U1 B = U1 and U2 B = U2 . Thus ∧2 V = U1 ⊕ U2 is a G-invariant decomposition, as claimed. 2 +b (b) Note first that b2 + b ≡ 1 mod n implies ζb verify that ψ commutes with A and with B: i+2 +bi+1 = ζ and ζb i = ζb . Let us ei Aψ = ei+1 ψ = ei+2 ∧ ei+3 = (ei+1 ∧ ei+2 )A = ei ψA; i i i+1 +bi+2 ei Bψ = ζb ei ψ = ζb (ei+1 ∧ ei+2 ) = ζb (ei+1 ∧ ei+2 ) = (ei+1 ∧ ei+2 )B = ei ψB. Since ψ is surjective and dim(V) = dim(Vψ) = dim(U1 ), we obtain that ψ is a bijection. Thus ψ is an isomorphism of G-modules. (c) This follows from (b) and the above fact that V is an irreducible G-module.  UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 19 Using the ESQ G-module V constructed before Proposition 6.2, we can construct an IAC algebra L that corresponds to V. Corollary 6.3. Assume Hypothesis 6.1. Let L be the vector space V = (Fq )r with an anti-commutative product defined on the basis {e0 , e1 , . . . , er−1 } by Je0 , e1 K = er−1 , Jei−1 , ei K = ei−2 for i = 2, 3, . . . , r − 1, Jer−1 , e0 K = er−2 , Jei , ej K = 0 if j − i 6= ±1 (mod r). Then L is an r-dimensional simple IAC algebra. Proof. It follows from Proposition 6.2 that L is IAC. Let us show that L is simple. Suppose that I P L and let v ∈ I \ {0}. Write v = v0 e0 + · · · + vr−1 er−1 with vi ∈ Fq . Suppose without loss of generality that v0 6= 0. Then using the multiplication table of L, we obtain that JJv, e1 K, e0 K = Jv0 er−1 − v2 e0 , e0 K = v0 er−2 . Hence er−2 ∈ I. Multiplying er−2 with the elements er−1 , e0, . . . er−3 , we obtain that ei ∈ I for all i ∈ {0, . . . , r − 1}. Thus I = L, and so L is simple as claimed.  7. The Clebsch-Gordan formula for the exterior square The aim of Section 8 is to present a class of ESQ modules for the group SL(2, F). In this section we prove a general version of the Clebsch–Gordan Formula for the exterior squares of the representations of GL(2, F) on spaces of homogeneous polynomials that is valid over fields of characteristic p. Such results are usually proved for SL(2, F), but generalizing to GL(2, F) does not require much more effort. Let F be a field of characteristic different from 2 and let F[X, Y] be the algebra of polynomials over F in two indeterminates. An action of GL(2, F) on F[X, Y] is given by X  X (11) λij (a11 X + a12 Y)i (a21 X + a22 Y)j λij Xi Y j A =   a11 a12 where A = . For each integer m > 0, the subspace of homogeneous polynoa21 a22 mials of degree m is invariant under this action. This space has dimension m + 1 since {Xi Y m−i | 0 6 i 6 m} is a basis. When char(F) = 0 this space is denoted Vm , and it is an irreducible FG-module for each m > 0. However, if F = Fq is a finite field, say with char(Fq ) = p, we use a different definition when p 6 m < q. In this case, the homogeneous polynomials of degree p have a proper submodule, namely hXp , Y pi. The irreducible SL(2, Fq)-modules in characteristic p were determined by Brauer and Nesbitt, and described clearly in [BHRD13, Theorem 5.2.3]. There are q pairwise nonisomorphic and absolutely irreducible FG-modules which we denote V0 , V1 , . . . , Vq−1 . 20 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER If m < p, then Vm denotes the subspace of homogeneous polynomials of degree m as above. If p 6 m < q, the definition of Vm depends on the p-adic expansion m = m0 + m1 p + · · · + mk pk of m where mi ∈ {0, 1, . . . , p − 1} and k := ⌊logp m⌋. We set φ φk Vm = Vm0 ⊗Vm ⊗· · ·⊗Vm where V φ denotes the FG-module obtained from V by twisting 1 k by the field automorphism φ : F → F with λφ = λp , see [HB82, Definition VII.1.13]. We are interested in irreducible ESQ-modules, i.e. irreducible modules V which are a quotient of their exterior square. The decomposition of Vm ⊗Vn as a module over SL(2, C) was described by Clebsch and Gordan, see [Kow14, Theorem 2.6.3]. Our primary interest is in GL(2, F)-module decompositions when F is finite. In the following theorem Vm is the GL(2, F)-module of homogeneous polynomials of degree m and Vdet is the 1-dimensional GL(2, F)-module on which GL(2, F) acts by the rule vg = (det g)v for all v ∈ Vdet and g ∈ GL(2, F). For a G-module V, we let S2 V denote the symmetric square of V. Theorem 7.1. Let F be a field of characteristic different from 2 and let G = GL(2, F). Then the following decompositions hold where the summands are irreducible FG-modules. (a) If m + n < char(F) or char(F) = 0, then min(m,n) ∼ Vm ⊗ Vn = M ⊗i Vdet ⊗ Vm+n−2i . i=0 (b) If 0 6 2m < char(F) or char(F) = 0, then m m M M ⊗i ⊗i 2 2 ∼ ∼ Vdet ⊗ V2m−2i . Vdet ⊗ V2m−2i and S Vm = ∧ Vm = i=1 i odd i=0 i even Proof. (a) Assume, without loss of generality, that m 6 n. We prove the result by induction on m. The case when m = 0 is clearly true. We view F[X1 , Y1 , X2 , Y2 ] as an FG-module, by adapting the action (11) separately for the indeterminates X1 , Y1 and for X2 , Y2 . Let Vm (X1 , Y1 ) be the submodule of F[X1 , Y1 ] comprising the degree m homogeneous polynomials, and define Vn (X2 , Y2 ) 6 F[X2 , Y2 ] similarly. The product set Vm,n := Vm (X1 , Y1 )Vn (X2 , Y2 ) ∼ Vn . The multiplication ∼ Vm and Vn (X2 , Y2 ) = is an FG-module. Further, Vm (X1 , Y1 ) = map ψ : Vm (X1 , Y1 ) ⊗ Vn (X2 , Y2 ) → Vm,n defined by (f(X1 , Y1 ) ⊗ g(X2 , Y2 ))ψ = f(X1 , Y1 )g(X2 , Y2 ) is a well-defined surjective FG-module homomorphism as an easy calculation shows that ((f ⊗ g)A)ψ = (f ⊗ g)ψA for all A ∈ GL(2, F). ∼ Vm,n . Comparing dimensions shows that ψ is an FG-isomorphism, and Vm ⊗ Vn = We now show Vm,n and Vm−1,n−1 ⊕ Vm+n are isomorphic FG-modules. Towards this end we will define an epimorphism π and a monomorphism δ. UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 21 Pm Pn Every element of Vm,n has the form i=0 j=0 λij Xi1 Y1m−i Xj2 Y2n−j where λij ∈ F. The evaluation homomorphism X2 7→ X1 , Y2 7→ Y1 gives rise to the following map (12) π : Vm,n → Vm+n (X1 , Y1 ) : Xi1 Y1m−i Xj2 Y2n−j 7→ X1i+j Y1m+n−i−j . It is straightforward to see that π is an FG-epimorphism. We now show that the FGn m n submodule W := (Xm 1 X2 )FG of Vm,n generated by X1 X2 is isomorphic to Vm+n . If m + n < char(F) or char(F) = 0, then Vm+n is an irreducible FG-module. Since Wπ is a non-zero submodule of Vm+n  , we have Wπ = Vm+n and dim(W) > m + n + 1. a b Conversely, suppose g = ∈ GL(2, F). The binomial theorem gives c d n m n (Xm 1 X2 )g = (aX1 + bY1 ) (aX2 + bY2 ) n   m   X X n m i m−i (aX2 )j (bY2 )n−j . (aX1 ) (bY1 ) = j i j=0 i=0 Collecting terms involving ak bm+n−k , where k = i + j, gives n (Xm 1 X2 )g P = m+n X ak bm+n−k hk k=0  n i m−i j n−j X1 Y1 X2 Y2 . This shows that W is spanned where hk is the polynomial i+j=k m i j by h0 , h1 , . . . , hm+n . Therefore dim(W) 6 m + n + 1. Hence dim(W) = m + n + 1, and π restricted to W gives an FG-isomorphism W → Vm+n . Note that F[X1 , Y1 , X2 , Y2 ] is an integral domain, and multiplying by a non-zero element in an integral domain is an injective map. Multiplying by r := X1 Y2 − Y1 X2 gives the map (13) δ : Vdet ⊗ Vm−1,n−1 → Vm,n , 1 ⊗ h(X1 , Y1 , X2 , Y2 ) 7→ r · h(X1 , Y1 , X2 , Y2 ). Observe first that rA equals (14) (a11X1 + a12 Y1 )(a21X2 + a22 Y2 ) − (a21 X1 + a22 Y1 )(a11X2 + a12 Y2 ) = (det A)r   a11 a12 where A = . It follows from (14) that rA = det(A)r for A ∈ GL(2, F), a21 a22 and hence hri = Vdet . Let h = h(X1 , Y1 , X2 , Y2 ) ∈ Vm−1,n−1 . We show that δ is an FG-homomorphism: ((1 ⊗ h)A)δ = (det(A)(hA))δ = det(A)(hA)r and ((1 ⊗ h)δ)A = (hr)A = (hA) det(A)r. n The subspaces imδ = (X1 Y2 − Y1 X2 )Vm−1,n−1 and W = (Xm 1 X2 )FG of Vm,n intersect trivially. Thus Vm,n has a submodule isomorphic to (Vdet ⊗ Vm−1,n−1 ) ⊕ Vm+n . However dim((Vdet ⊗ Vm−1,n−1 ) ⊕ Vm+n ) = mn + (m + n + 1) = (m + 1)(n + 1) = dim Vm,n , 22 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER and this implies ∼ Vm ⊗ Vn . ∼ Vm,n = (Vdet ⊗ Vm−1,n−1 ) ⊕ Vm+n = The decomposition (a) now follows by induction on m. Observe that when char(F) = p, then hypothesis m + n < p clearly implies that (m − 1) + (n − 1) < p. (b) Denote the symmetric and exterior squares of Vm by S2 Vm and ∧2 Vm , respectively. Since char(F) 6= 2 we have Vm ⊗ Vm = S2 Vm ⊕ ∧2 Vm . Our proof uses induction on m. The formulas are true for m = 0 because ∧2 V0 = 0 (here the sum is empty), and S2 V0 = V0 . Suppose m = 1. A calculation similar to (14) shows that (X ⊗ Y − Y ⊗ X)A = det(A)(X ⊗ Y − Y ⊗ X), and hence ∼ V2 , ∼ Vdet , and S2 V1 = hX ⊙ X, X ⊙ Y, Y ⊙ Yi = ∧2 V1 = hX ∧ Yi = where u ∧ v := 21 (u ⊗ v − v ⊗ u) and u ⊙ v := 21 (u ⊗ v + v ⊗ u). Thus the stated decompositions of ∧2 Vm and S2 Vm are valid for m = 1. Suppose now that m > 2. Recall the definitions in part (a) of the monomorphism δ, and the epimorphism π. Let f(X1 , Y1 ) ∈ Vm (X1 , Y1 ) and g(X2 , Y2 ) ∈ Vm (X2 , Y2 ) be arbitrary. Then ∼ ∧2 Vm ⊕ S2 Vm ∼ Vm ⊗ Vm = Vm,m = Vm (X1 , Y1 )Vm (X2 , Y2 ) = where (15) ∧2 Vm = hf(X1 , Y1 )g(X2 , Y2 ) − g(X1 , Y1 )f(X2 , Y2 )i , and (16) S2 Vm = hf(X1 , Y1 )g(X2 , Y2 ) + g(X1 , Y1 )f(X2 , Y2 )i . The following calculation may be used to show that (S2 Vm−1 )δ 6 ∧2 Vm : (X1 Y2 − Y1 X2 )(f(X1 , Y1 )g(X2 , Y2 ) + g(X1 , Y1 )f(X2 , Y2 )) = f(X1 , Y1 )X1 g(X2 , Y2 )Y2 − g(X1 , Y1 )Y1 f(X2 , Y2 )X2 − [f(X1 , Y1 )Y1 g(X2 , Y2 )X2 − g(X1 , Y1 )X1 f(X2 , Y2 )Y2 ]. The left side lies in (S2 Vm−1 )δ by (15), and the right side lies in ∧2 Vm by (16). Thus ∼ (S2 Vm−1 )δ 6 ∧2 Vm . This containment, however, is an equality Vdet ⊗ (S2 Vm−1 ) = because     m+1 dim(Vm−1 ) + 1 2 2 = dim(∧2 Vm ). = dim(S Vm−1 )δ = dim(S Vm−1 ) = 2 2 ∼ ∧2 Vm The inductive decomposition for S2 Vm−1 and the isomorphism Vdet ⊗ (S2 Vm−1 ) = 2 together imply the desired decomposition for ∧ Vm . A similar argument using (15) and (16) shows that (∧2 Vm−1 )δ 6 S2 Vm : (X1 Y2 − Y1 X2 )(f(X1 , Y1 )g(X2 , Y2 ) − g(X1 , Y1 )f(X2 , Y2 )) = f(X1 , Y1 )X1 g(X2 , Y2 )Y2 + g(X1 , Y1 )Y1 f(X2 , Y2 )X2 − [f(X1 , Y1 )Y1 g(X2 , Y2 )X2 + g(X1 , Y1 )X1 f(X2 , Y2 )Y2 ]. UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 23 ∼ (∧2 Vm−1 )δ 6 S2 Vm is an FG-submodule of S2 Vm . By part (a), Thus Vdet ⊗ (∧2 Vm−1 ) = V2m is an FG-submodule of Vm ⊗Vm . Our hypotheses imply that V2m is irreducible. Since ∼ Vdet ⊗ ∧2 Vm−1 V2m 66 ∧2 Vm , we see that V2m 6 S2 Vm and it intersects (∧2 Vm−1 )δ = 2 2 trivially. Therefore  Vdet ⊗ ∧ Vm−1 ⊕ V2m 6 S Vm . Comparing dimensions shows that Vdet ⊗ ∧2 Vm−1 ⊕ V2m = S2 Vm . The inductive decomposition for ∧2 Vm−1 implies the desired decomposition for S2 Vm . This proves part (b).  When char(F) = p, the hypothesis m + n < p in Theorem 7.1(a) is necessary; essentially because hXp , Y p i is a proper submodule of the homogeneous polynomials of degree p. Nevertheless, it is possible to relax the hypothesis m + n < p when the number of carries when adding m to n in base-p is zero. e Corollary 7.2. Suppose Fq has characteristic p where be integers P q = pj . Let m, nP with 0 6 m, n < q and with p-adic expansions m = j>0 mi p and n = j>0 ni pj . If mj + nj < p for each j > 0, then the following GL(2, Fq)-decomposition holds where the modules are twisted by powers of the automorphism λφ = λp , as per [HB82, Definition VII.1.13]: O min(m Mj ,nj ) φj ⊗i Vm ⊗ Vn = . Vdet ⊗ Vmj +nj −2i j>0 i=0 Proof. This follows from Vm ⊗ Vn = and Theorem 7.1(a). N j j>0 φ Vm ⊗ j N j>0 j Vnφj = N j>0 (Vmj j ⊗ Vnj )φ ,  8. Simple IAC algebras associated to SL(2, F) Since V0 is a trivial SL(2, F)-module, Theorem 7.1(b) may be used to determine when Vm is an ESQ-module. We need 2m − 2i = m to have a solution with i odd. Thus i = m/2 and m ≡ 2 (mod 4). Theorem 8.1. Let Vm be the above SL(2, F)-module where m ≡ 2 (mod 4) and where the field F satisfies char(F) = 0 or 2m < char(F). Then Vm is an absolutely irreducible ESQ-module. Further, if |F| > 5, the corresponding IAC algebra L is simple. Proof. We know that Vm is an absolutely irreducible SL(2, F)-module both when char(F) is zero or prime, c.f. [BHRD13, Theorem 5.2.3], [Kow14, Theorem 2.6.3] and [Tho04, pp. 57–59]. The preamble to this theorem showed that Vm is a quotient of ∧2 Vm . Thus we may turn L = Vm into an anti-commutative algebra satisfying JL, LK = L, as in Section 1. Since SL(2, F) acts irreducibly on L = Vm , we see that L is an IAC algebra. It remains to prove that L is a simple IAC algebra. By Theorem 4.2(b), L = I1 ⊕· · ·⊕Iℓ where I1 , . . . , Iℓ are the minimal ideals of L and ℓ > 1. The group SL(2, F) permutes the set X = {I1 , . . . , Iℓ } transitively. Since Z = Z(SL(2, F)) acts as the identity on this set, the 24 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER ∼ I⊕ℓ where I1 is a simple IAC projective linear group PSL(2, F) acts on X. Further, L = 1 algebra, and so dim I1 > 3, which implies that ℓ = dim(Vm )/ dim(I1 ) 6 (m + 1)/3. It is well known that PSL(2, F) is a simple group for |F| > 5. Suppose ℓ > 1. The homomorphism PSL(2, F) → Sℓ is faithful, and the image is transitive on ℓ points. This is impossible if F is infinite, as Sℓ is finite and PSL(2, F) is not. Thus |F| = q is finite. Set p = char(F). The minimal degree d of a transitive permutation representation of PSL(2, Fq ) is q + 1 except for q = 5, 7, 9, 11 in these cases d = 5, 7, 6, 11, respectively [KL90, Table 5.2.A, p. 175]. In all the cases we have 2q/3 6 d. Our hypothesis 2m < p implies 2p 2q m+1 p/2 + 1 6 6d6ℓ6 < . 3 3 3 3 This is false for all primes p, so we conclude that ℓ = 1, and L is simple.  Remark 8.2. Theorem 8.1 can be generalized to include ESQ H-modules where SL(2, Fq ) < H 6 GL(2, Fq ). For example, if m ≡ 2 (mod 4) and i = m/2 is a multiple ⊗i of |H : SL(2, Fq)|, then Vdet is a trivial H-module and L = Vm can be turned into an IAC algebra with H 6 Aut(L). Acknowledgments The first author gratefully acknowledges the support of the Australian Research Council Discovery Grant DP160102323. The third author thanks CNPq for Bolsa de Produtividade em Pesquisa Project 308773/2016-0, and Universal Project 475399/2013-7, as well as acknowledging the hospitality and financial support of the Centre for the Mathematics of Symmetry and Computation (CMSC) of UWA during visits in 2014 and 2017. The second author is grateful to Fapemig for a PhD scholarship and financially supporting his visit to the CMSC. References [BHRD13] John N. Bray, Derek F. Holt, and Colva M. Roney-Dougal, The maximal subgroups of the low-dimensional finite classical groups, London Mathematical Society Lecture Note Series, vol. 407, Cambridge University Press, Cambridge, 2013. ↑15, 19, 23 [BD12] Murray R. Bremner and Andrew Douglas, The simple non-Lie Malcev algebra as a LieYamaguti algebra, J. Algebra 358 (2012), 269–291. ↑3 [BH04] Murray Bremner and Irvin Hentzel, Invariant nonassociative algebra structures on irreducible representations of simple Lie algebras, Experiment. Math. 13 (2004), no. 2, 231–256. ↑2 [BMW17] Peter A. Brooksbank, Joshua Maglione, and James B. Wilson, A fast isomorphism test for groups whose Lie algebra has genus 2, J. Algebra 473 (2017), 545–590. ↑2 [BW12] Peter A. Brooksbank and James B. Wilson, Computing isometry groups of Hermitian maps, Trans. Amer. Math. Soc. 364 (2012), no. 4, 1975–1996. ↑2 [ELGO02] Bettina Eick, C. R. Leedham-Green, and E. A. O’Brien, Constructing automorphism groups of p-groups, Comm. Algebra 30 (2002), no. 5, 2271–2295. ↑2 [GPS11] S. P. Glasby, P. P. Pálfy, and Csaba Schneider, p-groups with a unique proper non-trivial characteristic subgroup, J. Algebra 348 (2011), 85–109. ↑1, 2, 3, 6, 13, 16, 17 UCS p-GROUPS AND ANTI-COMMUTATIVE ALGEBRAS 25 [HM07] Geir T. Helleloid and Ursula Martin, The automorphism group of a finite p-group is almost always a p-group, J. Algebra 312 (2007), no. 1, 294–329. ↑1 [His84] Gerhard Hiss, Die adjungierten Darstellungen der Chevalley-Gruppen, Arch. Math. (Basel) 42 (1984), no. 5, 408–416 (German). ↑15 [HEO05] Derek F. Holt, Bettina Eick, and Eamonn A. O’Brien, Handbook of computational group theory, Discrete Mathematics and its Applications (Boca Raton), Chapman & Hall/CRC, Boca Raton, FL, 2005. ↑7, 8 [HB82] Bertram Huppert and Norman Blackburn, Finite groups. II, Grundlehren der Mathematischen Wissenschaften [Fundamental Principles of Mathematical Sciences], vol. 242, Springer-Verlag, Berlin-New York, 1982. AMD, 44. ↑20, 23 [KL90] Peter Kleidman and Martin Liebeck, The subgroup structure of the finite classical groups, London Mathematical Society Lecture Note Series, vol. 129, Cambridge University Press, Cambridge, 1990. ↑24 [KMR99] P. B. Kleidman, U. Meierfrankenfeld, and A. J. E. Ryba, HS < E7 (5), J. London Math. Soc. (2) 60 (1999), no. 1, 95–107. ↑2, 9, 10 [Kow14] Emmanuel Kowalski, An introduction to the representation theory of groups, Graduate Studies in Mathematics, vol. 155, American Mathematical Society, Providence, RI, 2014. ↑20, 23 [Kuz14] E. N. Kuzmin, Structure and representations of finite dimensional Malcev algebras, Quasigroups Related Systems 22 (2014), no. 1, 97–132. ↑15 [LM87] Alexander Lubotzky and Avinoam Mann, Powerful p-groups. I. Finite groups, J. Algebra 105 (1987), no. 2, 484–505. ↑12 [PT16] Orazio Puglisi and Gunnar Traustason, On simple symplectic alternating algebras and their groups of automorphisms, J. Algebra 461 (2016), 164–176. ↑2 [Tra08a] Gunnar Traustason, Powerful 2-Engel groups. II, J. Algebra 319 (2008), no. 8, 3301–3323. MR2408320 ↑2 [Tra08b] , Symplectic alternating algebras, Internat. J. Algebra Comput. 18 (2008), no. 4, 719– 757. ↑2 [ST15] Layla Sorkatti and Gunnar Traustason, Nilpotent symplectic alternating algebras I, J. Algebra 423 (2015), 615–635. ↑2 [ST16a] , Nilpotent symplectic alternating algebras II, Internat. J. Algebra Comput. 26 (2016), no. 5, 1071–1094. ↑2 [ST16b] , Nilpotent symplectic alternating algebras III, Internat. J. Algebra Comput. 26 (2016), no. 5, 1095–1124. ↑2 [Sup76] D. A. Suprunenko, Matrix groups, American Mathematical Soc., Providence, R.I., 1976. Translated from the Russian; Translation edited by K. A. Hirsch; Translations of Mathematical Monographs, Vol. 45. ↑10 [Tau55] D. R. Taunt, Finite groups having unique proper characteristic subgroups. I, Proc. Cambridge Philos. Soc. 51 (1955), 25–36. ↑1, 4 [Tho04] Charles B. Thomas, Representations of finite and Lie groups, Imperial College Press, London, 2004. ↑23 [Wil13] James B. Wilson, More characteristic subgroups, Lie rings, and isomorphism tests for pgroups, J. Group Theory 16 (2013), no. 6, 875–897. ↑2 [Wil17] , On automorphisms of groups, rings, and algebras, Comm. Algebra 45 (2017), no. 4, 1452–1478. ↑2 [Wil09] Robert A. Wilson, The finite simple groups, Graduate Texts in Mathematics, vol. 251, Springer-Verlag London, Ltd., London, 2009. ↑15 [Wil10] , A new approach to the Suzuki groups, Math. Proc. Cambridge Philos. Soc. 148 (2010), no. 3, 425–428. ↑2 26 S. P. GLASBY, FREDERICO A. M. RIBEIRO AND CSABA SCHNEIDER (Glasby) Centre for Mathematics of Symmetry and Computation, University of Western Australia, 35 Stirling Highway, Perth 6009, Australia. Also affiliated with The Faculty of Information Sciences and Engineering, University of Canberra, ACT 2601, Australia. Email: [email protected]; URL: http://www.maths.uwa.edu.au/∼glasby/ (Ribeiro, Schneider) Departamento de Matemática, Instituto de Ciências Exatas, Universidade Federal de Minas Gerais, Av. Antônio Carlos 6627, Belo Horizonte, MG, Brazil. Email: [email protected], [email protected], URL: http://www.mat.ufmg.br/∼csaba
4math.GR
arXiv:1609.01360v2 [cs.LG] 22 Nov 2016 Evolutionary Synthesis of Deep Neural Networks via Synaptic Cluster-driven Genetic Encoding Mohammad Javad Shafiee, Alexander Wong Department of Systems Design Engineering, University of Waterloo Waterloo, Ontario, Canada {mjshafiee, a28wong}@uwaterloo.ca Abstract There has been significant recent interest towards achieving highly efficient deep neural network architectures. A promising paradigm for achieving this is the concept of evolutionary deep intelligence, which attempts to mimic biological evolution processes to synthesize highly-efficient deep neural networks over successive generations. An important aspect of evolutionary deep intelligence is the genetic encoding scheme used to mimic heredity, which can have a significant impact on the quality of offspring deep neural networks. Motivated by the neurobiological phenomenon of synaptic clustering, we introduce a new genetic encoding scheme where synaptic probability is driven towards the formation of a highly sparse set of synaptic clusters. Experimental results for the task of image classification demonstrated that the synthesized offspring networks using this synaptic cluster-driven genetic encoding scheme can achieve state-of-the-art performance while having network architectures that are not only significantly more efficient (with a ∼125fold decrease in synapses for MNIST) compared to the original ancestor network, but also tailored for GPU-accelerated machine learning applications. 1 Introduction There has been a strong interest toward obtaining highly efficient deep neural network architectures that maintain strong modeling power for different applications such as self-driving cars and smartphone applications where the available computing resources are practically limited to a combination of low-power, embedded GPUs and CPUs with limited memory and computing power. The optimal brain damage method [1] was one of the first approaches in this area, where synapses were pruned based on their strengths. Gong et al. [2] proposed a network compression framework where vector quantization was leveraged to shrink the storage requirements of deep neural networks. Han et al. [3] utilized pruning, quantization and Huffman coding to further reduce the storage requirements of deep neural networks. Hashing is another trick utilized by Chen et al. [4] to compress the network into a smaller amount of storage space. Low rank approximation [5, 6] and sparsity learning [7–9] are other strategies used to sparsify deep neural networks. Recently, Shafiee et al. [10] tackled this problem in a very different manner by proposing a novel framework for synthesizing highly efficient deep neural networks via the idea of evolutionary synthesis. Differing significantly from past attempts at leveraging evolutionary computing methods such as genetic algorithms for creating neural networks [11, 12], which attempted to create neural networks with high modeling capabilities in a direct but highly computationally expensive manner, the proposed novel evolutionary deep intelligence approach mimics biological evolution mechanisms such as random mutation, natural selection, and heredity to synthesize successive generations of deep neural networks with progressively more efficient network architectures. The architectural traits of ancestor deep neural networks are encoded via probabilistic ‘DNA’ sequences, with new offspring networks possessing diverse network architectures synthesized stochastically based on the 30th Conference on Neural Information Processing Systems (NIPS 2016), Barcelona, Spain. ‘DNA’ from the ancestor networks and computational environmental factor models, thus mimicking random mutation, heredity, and natural selection. These offspring networks are then trained, much like one would train a newborn, and have more efficient, more diverse network architectures while achieving powerful modeling capabilities. An important aspect of evolutionary deep intelligence that is particular interesting and worth deeper investigation is the genetic encoding scheme used to mimic heredity, which can have a significant impact on the way architectural traits are passed down from generation to generation and thus impact the quality of descendant deep neural networks. A more effective genetic encoding scheme can facilitate for better transfer of important genetic information from ancestor networks to allow for the synthesis of even more efficient and powerful deep neural networks in the next generation. As such, a deeper investigation and exploration into the incorporation of synaptic clustering into the genetic encoding scheme can be potentially fruitful for synthesizing highly efficient deep neural networks that are more geared for improving not only memory and storage requirements, but also be tailored for devices designed for highly parallel computations such as embedded GPUs. In this study, we introduce a new synaptic cluster-driven genetic encoding scheme for synthesizing highly efficient deep neural networks over successive generations. This is achieved through the introduction of a multi-factor synapse probability model where the synaptic probability is a product of both the probability of synthesis of a particular cluster of synapses and the probability of synthesis of a particular synapse within the synapse cluster. This genetic encoding scheme effectively promotes the formation of synaptic clusters over successive generations while also promoting the formation of highly efficient deep neural networks. 2 Methodology The proposed genetic encoding scheme decomposes synaptic probability into a multi-factor probability model, where the architectural traits of a deep neural network are encoded probabilistically as a product of the probability of synthesis of a particular cluster of synapses and the probability of synthesis of a particular synapse within the synapse cluster. Cluster-driven Genetic Encoding. Let the network architecture of a deep neural network be expressed by H(N, S), with N denoting the set of possible neurons and S denoting the set of possible synapses in the network. Each neuron ni ∈ N is connected via a set of synapses s̄ ⊂ S to neuron nj ∈ N such that the synaptic connectivity si ∈ S is associated with a wi ∈ W denoting its strength. The architectural traits of a deep neural network in generation g can be encoded by a conditional probability given its architecture at the previous generation g − 1, denoted by P (Hg |Hg−1 ), which can be treated as the probabilistic ‘DNA’ sequence of a deep neural network. Without loss of generality, based on the assumption that synaptic connectivity characteristics in an ancestor network are desirable traits to be inherited by descendant networks, one can instead encode the genetic information of a deep neural network by synaptic probability P (Sg |Wg−1 ), where wk,g−1 ∈ Wg−1 encodes the synaptic strength of each synapse sk,g ∈ Sg . In the proposed genetic encoding scheme, we wish to take into consideration and incorporate the neurobiological phenomenon of synaptic clustering [13–17], where the probability of synaptic co-activation increases for correlated synapses encoding similar information that are close together on the same dendrite. To explore the idea of promoting the formation of synaptic clusters over successive generations while also promoting the formation of highly efficient deep neural networks, the following multifactor synaptic probability model is introduced: i Yh  Y P (sg,i |wg−1,i ) (1) P (Sg |Wg−1 ) = P s̄g,c |Wg−1 · i∈c c∈C where the first factor (first conditional probability) models the probability of the synthesis of a particular cluster of synapses, s̄g,c , while the second factor models the probability of a particular synapse, sg,i , within synaptic cluster c. More specifically, the probability P (s̄g,c |Wg−1 ) represents the likelihood that a particular synaptic cluster, s̄g,c , be synthesized as a part of the network architecture in generation g given the synaptic strength in generation g − 1. For example, in a deep convolutional neural network, the synaptic cluster c can be any subset of synapses such as a kernel or a set of kernels within the deep neural network. The probability P (sg,i |wg−1,i ) represents the likelihood of existence of synapse i within the cluster c in generation g given its synaptic strength in generation g − 1. As such, the proposed synaptic probability model not only promotes the persistence of strong synaptic connectivity in offspring deep neural networks over successive generations, but also pro2 motes the persistence of strong synaptic clusters in offspring deep neural networks over successive generations. Cluster-driven Evolutionary Synthesis. In the seminal paper on evolutionary deep intelligence by Shafiee et al. [10], the synthesis probability P (Hg ) is composed of the synaptic probability P (Sg |Wg−1 ), which mimic heredity, and environmental factor model F (E) which mimic natural selection by introducing quantitative environmental conditions that offspring networks must adapt to: P (Hg ) = F (E) · P (Sg |Wg−1 ) (2) In this study, (2) is reformulated in a more general way to enable the incorporation of different quantitative environmental factors synaptic clusters as welli as each synapse: h both the synthesis ofY Yover Fs (E)P (sg,i |wg−1,i ) (3) P (Hg ) = Fc (E)P s̄g,c |Wg−1 · i∈c c∈C where Fc (·) and Fs (·) represents environmental factors enforced at the cluster and synapse levels, respectively. Realization of Cluster-driven Genetic Encoding. In this study, a simple realization of the proposed cluster-driven genetic encoding scheme is presented to demonstrate the benefits of the proposed scheme. Here, since we wish to promote the persistence of strong synaptic clusters in offspring deep neural networks over successive generations, the probability of the synthesis of a particular cluster of synapses, s̄g,c is modeled as  P ⌊ω   g−1,i ⌋ i∈c P s̄g,c = 1|Wg−1 = exp −1 (4) Z where ⌊·⌋ encodes the truncation of a synaptic weight and Z is a normalization factor to make (4)  a probability distribution, P s̄g,c |Wg−1 ∈ [0, 1]. The truncation of synaptic weights in the model reduces the influence of very weak synapses within a synaptic cluster on the genetic encoding process. The probability of a particular synapse, sg,i , within synaptic cluster c, denoted by ω  P (sg,i = 1|wg−1,i ) can be expressed as: g−1,i P (sg,i = 1|wg−1,i ) = exp −1 (5) z where z is a layer-wise normalization constant. By incorporating both of the aforementioned probabilities in the proposed scheme, the relationships amongst synapses as well as their individual synaptic strengths are taken into consideration in the genetic encoding process. 3 Experimental Results Evolutionary synthesis of deep neural networks across several generations is performed using the proposed genetic encoding scheme, and their network architectures and accuracies are investigated using three benchmark datasets: MNIST [18], STL-10 [19] and CIFAR10 [20]. The LeNet-5 architecture [18] is selected as the network architecture of the original, first generation ancestor network for MNIST and STL-10, while the AlexNet architecture [21] is utilized for the ancestor network for CIFAR10, with the first layer modified to utilize 5 × 5 × 3 kernels instead of 11 × 11 × 3 kernels given the smaller image size in CIFAR10. The environmental factor model being imposed at different generations in this study is designed to form deep neural networks with progressively more efficient network architectures than its ancestor networks while maintaining modeling accuracy. More specifically, Fc (·) and Fs (·) is formulated in this study such that an offspring deep neural network should not have more than 80% of the total number of synapses in its direct ancestor network. Furthermore, in this study, each kernel in the deep neural network is considered as a synaptic cluster in the synapse probability model. In other words, the probability of the synthesis of a particular synaptic cluster (i.e, P (s̄g,c |Wg−1 )) is modeled as the truncated summation of the weights within a kernel. Results & Discussion. In this study, offspring deep neural networks were synthesized in successive generations until the accuracy of the offspring network exceeded 3%, so that we can better study the changes in architectural efficiency in the descendant networks over multiple generations. Table 1 shows the architectural efficiency (defined in this study as the total number of synapses of the original, first-generation ancestor network divided by that of the current synthesized network) versus the modeling accuracy at several generations for three datasets. As observed in Table 1, the descendant network at the 13th generation for MNIST was a staggering ∼125-fold more efficient than the original, first-generation ancestor network without exhibiting a significant drop in the test 3 Table 1: Architectural efficiency vs. test accuracy for different generations of synthesized networks. “Gen.”, “A-E” and “ACC.” denote generation, architectural efficiency, and accuracy, respectively. Gen. 1 5 7 9 11 13 MNIST A-E 1.00X 5.20X 12.09X 32.23X 62.74X 125.09X ACC. 0.9947 0.9941 0.9928 0.9884 0.9849 0.9775 Gen. 1 3 5 7 9 10 STL-10 A-E 1.00X 2.37X 5.81X 14.99X 38.22X 56.27X ACC. 0.5774 0.5933 0.6039 0.6051 0.5744 0.5658 Gen. 1 2 3 4 5 6 CIFAR10 A-E ACC. 1.00X 1.64X 2.82X 5.06X 8.39X 14.39X 0.8669 0.8814 0.8766 0.8688 0.8588 0.8459 Table 2: Cluster efficiency of the convolutional layers (layers 1-3) and fully connected layer (layer 4) at first and the last reported generations of deep neural networks for MNIST and STL-10. Columns ‘E’ show overall cluster efficiency for synthesized deep neural networks. MNIST STL-10 Gen. ACC. Layer 1 Layer 2 Layer 3 Layer 4 E Gen. ACC. Layer 1 Layer 2 Layer 3 Layer 4 E 1(baseline) 0.9947 1X 1X 1X 1X 1X 1(baseline) 0.5774 1X 1X 1X 1X 1X 13 0.9775 3.6X 12.96X 8.83X 13.47X 9.71X 10 0.5658 3.31X 8.46X 5.49X 6.56X 5.96X Table 3: Cluster efficiency of the convolutional layers (layers 1-5) and fully connected layers (layers 6-7) at first and the last reported generations of deep neural networks for CIFAR10. Gen. ACC. Layer 1 Layer 2 Layer 3 Layer 4 Layer 5 Layer 6 Layer 7 E 1 (baseline) 0.8669 1X 1X 1X 1X 1X 1X 1X 1X 6 0.8459 2.01X 3.10X 3.50 3.40X 3.29X 2.97X 1.51X 2.82X accuracy (∼1.7% drop). This trend was consistent with that observed with the STL-10 results, where the descendant network at the 10th generation was ∼56-fold more efficient than the original, firstgeneration ancestor network without a significant drop in test accuracy (∼1.2% drop). It also worth noting that since the training dataset of the STL-10 dataset is relatively small, the descendant networks at generations 2 to 8 actually achieved higher test accuracies when compared to the original, first-generation ancestor network, which illustrates the generalizability of the descendant networks compared to the original ancestor network as the descendant networks had fewer parameters to train. Finally, for the case of CIFAR10 where a different network architecture was used (AlexNet), the descendant network at the 6th generation network was ∼14.4-fold more efficient than the original ancestor network with ∼2% drop in test accuracy, thus demonstrating the applicability of the proposed scheme for different network architectures. Embedded GPU Ramifications. Table 2 and 3 shows the cluster efficiency per layer of the synthesized deep neural networks in the last generations, where cluster efficiency is defined in this study as the total number of kernels in a layer of the original, first-generation ancestor network divided by that of the current synthesized network. It can be observed that for MNIST, the cluster efficiency of last-generation descendant network is ∼9.7X, which may result in a near 9.7-fold potential speed-up in running time on embedded GPUs by reducing the number of arithmetic operations by ∼9.7-fold compared to the first-generation ancestor network, though computational overhead in other layers such as ReLU may lead to a reduction in actual speed-up. The potential speed-up from the lastgeneration descendant network for STL-10 is lower compared to MNIST dataset, with the reported cluster efficiency in last-generation descendant network ∼6X. Finally, the cluster efficiency for the last generation descendant network for CIFAR10 is ∼2.8X, as shown in Table 3. These results demonstrate that not only can the proposed genetic encoding scheme promotes the synthesis of deep neural networks that are highly efficient yet maintains modeling accuracy, but also promotes the formation of highly sparse synaptic clusters that make them highly tailored for devices designed for highly parallel computations such as embedded GPUs. Acknowledgments This research has been supported by Canada Research Chairs programs, Natural Sciences and Engineering Research Council of Canada (NSERC), and the Ministry of Research and Innovation of Ontario. The authors also thank Nvidia for the GPU hardware used in this study through the Nvidia Hardware Grant Program. 4 References [1] Y. LeCun, J. S. Denker, S. A. Solla, R. E. Howard, and L. D. Jackel, “Optimal brain damage.” in Advances in Neural Information Processing Systems (NIPS), 1989. [2] Y. Gong, L. Liu, M. Yang, and L. Bourdev, “Compressing deep convolutional networks using vector quantization,” CoRR, abs/1412.6115, 2014. [3] S. Han, J. Pool, J. Tran, and W. Dally, “Learning both weights and connections for efficient neural network,” in Advances in Neural Information Processing Systems (NIPS), 2015. [4] W. Chen, J. T. Wilson, S. Tyree, K. Q. Weinberger, and Y. Chen, “Compressing neural networks with the hashing trick,” CoRR, abs/1504.04788, 2015. [5] Y. Ioannou, D. Robertson, J. Shotton, R. Cipolla, and A. Criminisi, “Training cnns with lowrank filters for efficient image classification,” arXiv preprint arXiv:1511.06744, 2015. [6] M. Jaderberg, A. Vedaldi, and A. Zisserman, “Speeding up convolutional neural networks with low rank expansions,” arXiv preprint arXiv:1405.3866, 2014. [7] J. Feng and T. Darrell, “Learning the structure of deep convolutional networks,” in Proceedings of the IEEE International Conference on Computer Vision, 2015, pp. 2749–2757. [8] B. Liu, M. Wang, H. Foroosh, M. Tappen, and M. Pensky, “Sparse convolutional neural networks,” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2015, pp. 806–814. [9] W. Wen, C. Wu, Y. Wang, Y. Chen, and H. Li, “Learning structured sparsity in deep neural networks,” arXiv preprint arXiv:1608.03665, 2016. [10] M. J. Shafiee, A. Mishra, and A. Wong, “Deep learning with Darwin: Evolutionary synthesis of deep neural networks,” arXiv preprint arXiv:1606.04393, 2016. [11] D. White and P. Ligomenides, “Gannet: A genetic algorithm for optimizing topology and weights in neural network design,” in International Workshop on Artificial Neural Networks. Springer, 1993, pp. 322–327. [12] K. O. Stanley and R. Miikkulainen, “Evolving neural networks through augmenting topologies,” Evolutionary computation, vol. 10, no. 2, pp. 99–127, 2002. [13] O. Welzel, C. H. Tischbirek, J. Jung, E. M. Kohler, A. Svetlitchny, A. W. Henkel, J. Kornhuber, and T. W. Groemer, “Synapse clusters are preferentially formed by synapses with large recycling pool sizes,” PloS one, vol. 5, no. 10, p. e13514, 2010. [14] G. Kastellakis, D. J. Cai, S. C. Mednick, A. J. Silva, and P. Poirazi, “Synaptic clustering within dendrites: An emerging theory of memory formation,” Progress in neurobiology, vol. 126, pp. 19–35, 2015. [15] M. E. Larkum and T. Nevian, “Synaptic clustering by dendritic signalling mechanisms,” Current opinion in neurobiology, vol. 18, no. 3, pp. 321–331, 2008. [16] N. Takahashi, K. Kitamura, N. Matsuo, M. Mayford, M. Kano, N. Matsuki, and Y. Ikegaya, “Locally synchronized synaptic inputs,” Science, vol. 335, no. 6066, pp. 353–356, 2012. [17] J. Winnubst and C. Lohmann, “Synaptic clustering during development and learning: the why, when, and how,” Frontiers in molecular neuroscience, vol. 5, 2015. [18] Y. LeCun, L. Bottou, Y. Bengio, and P. Haffner, “Gradient-based learning applied to document recognition,” Proceedings of the IEEE, vol. 86, no. 11, pp. 2278–2324, 1998. [19] A. Coates, A. Y. Ng, and H. Lee, “An analysis of single-layer networks in unsupervised feature learning,” in International conference on artificial intelligence and statistics, 2011, pp. 215– 223. [20] A. Krizhevsky and G. Hinton, “Learning multiple layers of features from tiny images,” 2009. [21] A. Krizhevsky, I. Sutskever, and G. E. Hinton, “Imagenet classification with deep convolutional neural networks,” in Advances in neural information processing systems (NIPS), 2012. 5
9cs.NE
Conditional Activation for Diverse Neurons in Heterogeneous Networks Albert Lee1, Bonnie Lam1, Wenyuan Li1, Hochul Lee1, Wei-Hao Chen2, Meng-Fan Chang2, and Kang. -L. Wang1 1 University of California, Los Angeles, 2National Tsing-Hua University Abstract In this paper, we propose a new scheme for modelling the diverse behavior of neurons. We introduce the “conditional activation”, in which a neuron’s activation function is dynamically modified by a control signal. We apply this method to recreate behavior of special neurons existing in the human auditory and visual system. A heterogeneous multilayered perceptron (MLP) incorporating the developed models demonstrates simultaneous improvement in learning speed and performance across a various number of hidden units and layers, compared to a homogeneous network composed of the conventional neuron model. For similar performance, the proposed model lowers the memory for storing network parameters significantly. I. Introduction Machine learning (ML) methods have recently demonstrated outstanding results with structures such as recurrent neural networks (RNNs), feedforward neural networks (FNNs), and convolutional neural networks (CNNs), including, the use of numerous methods such as drop-out/drop-connect [1][2], batch normalization [3], annealed/momentum learning rates [4], and data augmentation schemes [5] to allow for better generalization of learning result. These schemes have enabled state-of-the-art results in recognition accuracy on many datasets, at the cost of slower convergence, larger network size, or increased amount of training data. However, despite these innovations, an identical neuron model is used throughout the entire artificial neural network. This homogeneity in the neurons is thus a limiting factor in further advancement in performance, as a homogeneous system is by far less versatile and adaptive than its heterogeneous counterpart, as proven in numerous fields including communications [6], evolution/society [7], and neural networks [8]. Furthermore, the homogeneity of current AI systems neither allows the capability to contain intrinsic functions to drive the system toward a goal, nor rules that guide and govern the learning process within safety bounds. In contrast, the biological neural system contains a rich variety of neurons varying in structures, electrical properties, synaptic connections, as well as spatial and timing response [9]. Different neuron types result in high versatility and complementary computing capabilities, and their hard-wired anatomy further compose the intrinsic functions, rules, and values in the neural system. (For example: functions existing at birth which are not obtained or changed through learning, such as the auditory and visual systems [10]; non-learnable rules that govern behavior and safety, such as reflexes [11]; unconditioned reward values that motivate behavior, learning, and pleasure, such as enjoying music [12]–[14]). Thus, in order to further advance artificial intelligence, it is essential to understand and to utilize neural diversity and their anatomy for next generation AI. In this work, we present a new scheme for modelling the diverse response of neurons that are critical in human speech and image processing, and exhibit significantly different dynamic behavior than the traditional integrate-and-fire neuron. The remainder of this paper is organized as follows: Section II 1 introduces the proposed conditional activation scheme. Section III demonstrates the application of the conditional activation in creating diverse neuron models. Section IV shows learning results on a heterogeneous network composed of the developed models for the MNIST dataset. Section V summarizes this paper with discussions on future research directions. II. The Conditional Activation Scheme II.A. Modulation of a Neuron’s response In the neural system, the electrical response of a neuron can be dynamically modulated through several mechanisms. Chemical messages such as neurotransmitters and neuromodulators target receptors on a neuron leading to changes in various features [15][16]. Neurotransmitters are released at synapses affecting a small, local region, while neuromodulators are diffused into the intracellular neural tissue, thereby affecting a larger cluster of neurons. Activation or deactivation of genetic expressions through transcription factors may also change a neuron’s functions [17]. Input Layer Hidden Layer Output Layer Output Input Weighted Connections Neurons ReLU Input McCulloch-Pitts Neuron Weights Bias Sigmoid Membrane Potential φ Output Binary Step Activation Function Weighted Summation Fig.1 Structure of a multi-layer perceptron (MLP) incorporating the McCulloch-Pitts neuron model, which computes the weighted sum of its inputs passed through an activation function. II.B. Formulation of the conditional activation scheme A common context of the mechanisms in Sec. II.A is that a control signal changes the neurons response. The conditional activation scheme models this phenomenon by allowing a control signal to change a neuron model’s activation function. Fig.1 shows the conventional McCulloch-Pitts neuron employed in machine learning applications [18]. In this case, the neuron primarily composes of two parts: a weighted sum and an activation function. During forward propagation, the membrane potential m is computed as the weighted sum (∑ 𝑥𝑖 𝑤𝑖 ) plus a bias b. The result is then passed through the activation function, often a nonlinear thresholding function such as the rectified linear unit (ReLU), sigmoid, or step function. Formally, 2 𝑛 = 𝜑( ) = 𝜑 (∑ 𝑥𝑖 𝑤𝑖 + 𝑏) 𝑖=1 where 𝑥𝑖 is the neuron’s input, 𝑤𝑖 is the connection weights, 𝜑 is the activation function, and output of the neuron. is the The conditional activation scheme is shown in Fig.2. In this scheme, the activation has a set of response functions 𝜑1 𝜑𝑘 and takes in a set of input control channels 𝐿 = [𝐿1 𝐿𝑛 ]. Based on the pattern of the controls, one of the response functions is selected as the activation function of the neuron. Formally, 𝜑𝑖 ∈ [𝜑1 ( ), 𝜑2 ( ) ] = 𝜑𝑖 ( ) 𝑤ℎ𝑒𝑟𝑒 𝑖 = 𝑓𝑐𝑜𝑛𝑑 (𝐿) ∈ 𝑵 is the mapping from 𝐿 to each response function. ReLU = , Leaky ReLU [+,+] [+,-] Binary Step [-,+] Sigmoid [-,-] Fig.2 The conditional activation scheme. Here, the controls 𝐿 composes two channels 𝐿1 and 𝐿2 , and the response functions 𝜑𝑖 contains the ReLU, Leaky ReLU, Binary step, and Sigmoid functions. When both control channels are active, the activation function becomes a ReLU. When channel 𝐿1 is active and 𝐿2 is inactive, a leaky ReLU is selected. When channel 𝐿1 is inactive and 𝐿2 is active, a step function is selected. When both channels are inactive, the sigmoid function is selected. III. Conditional Activation in modelling diverse neuron functions II.A. Coincidence/synchrony detection and max functions Cells in the visual and auditory cortex show a variety of neuron functions. The octopus cells in the cochlear nucleus detects synchronous activity, firing only when multiple input synapses are simultaneously active [19]. It does not fire when two inputs arrive with a time delay, regardless of the amplitude and frequency of the signals. The ability to detect synchrony plays a vital role in human interpretation of temporal characteristics [20]–[22]. In fact, clinical studies have shown that individuals with damaged synchrony detection causes difficulty in speech interpretation [19]. The V4 neuron (also known as complex cell [23]) in the visual cortex computes the maximum value among its input activities [24]. It determines the region of focus in the field of view and provides attention modulation [25], and creates invariance, the ability to provide robust recognition despite shifting, resizing, and other transformations in the input. The max pooling layer widely adopted in RNNs is an extreme abstraction of this neuron’s function. II.B. synchronous and max neuron models 3 To model the activities of these neurons, we first construct the truth table of their electrical response with two inputs (In1 and In2). We then map the inputs to 𝐿 and , respectively, and translate firing to “above threshold” and silent to “below threshold”, as shown in Fig.3. Here, we set the threshold to 0. Inspecting the translated table, we see that for synchronous detection, the output is a constant 0 when the control 𝐿 is negative (inactive). However, when 𝐿 is positive (active), the output is when is positive and 0 when is negative, characterized by the ReLU function. This gives us the conditional activation for the synchronous detection: Synchronous In1 Silent (L<0) In1 Fired (L>0) Synchronous In1 Silent (L<0) In1 Fired (L>0) In2 Silent (m<0) Silent (0) Silent (0) In2 Silent (m<0) Silent (0) Fired (>0) In2 Fired (m>0) Silent (0) Fires (>0) In2 Fired (m>0) Fired (>0) Fired (>0) Synchronous L<0 L>0 Max L<0 L>0 𝑵 Fig.3 Using the conditional activation to model the synchronous detection and max functions. The truth table of the neuron’s activity is mapped to the activation’s inputs, then the mathematical representation is constructed. 𝜑𝑆𝑌𝑁𝐶,𝑖 ∈ [0, 𝑅𝑒𝐿𝑈]; Parameters 1 𝐿<0 𝑖 = 𝑓𝑐𝑜𝑛𝑑 (𝐿) = { 2 𝐿>0 𝜑𝑆𝑌𝑁𝐶 For the max function, when 𝐿 is negative, the output is again characterized by the ReLU function. However, when 𝐿 is positive, the output is equal to when is positive and the inverse of when is negative, characterized by the absolute function. This gives us the CA for the max function: 𝜑𝑀𝐴𝑋 𝜕 𝜕 𝜕 𝜕 ⁄𝜕 ⁄𝜕𝐿 ⁄𝜕 ⁄𝜕𝐿 𝐿>0 >0 1 0 1 0 <0 0 0 -1 1 𝐿<0 >0 0 1 1 0 <0 0 0 0 0 Table 1. Back propagation parameters of 𝜑𝑆𝑌𝑁𝐶 and 𝜑𝑀𝐴𝑋 used in this experiment. The back-propagation on the control L is 1 when the neuron’s output differs from the output generated by the ReLU function. 𝜑𝑀𝐴𝑋,𝑖 ∈ [𝑅𝑒𝐿𝑈, 𝑎𝑏𝑠]; 1 𝐿<0 𝑖= { 2 𝐿>0 The back-propagation parameters of the output with respect to (𝜕 ⁄𝜕 ) is modified according to the selected response function. For the back propagation on 𝐿 (𝜕 ⁄𝜕𝐿 ), we simply set it as 1 when the control caused the neuron’s response to differ from its original response. In the case of synchronous detection, this occurs when L is negative and m is positive. In the case of the max function, this occurs when L is positive and m is negative. 4 IV. Experimental Results We evaluate our model on MNIST, a hand-written digit dataset containing 60,000 training images and 10,000 testing images divided among 10 classes [26] (digits 0-9). Each grayscale image is a size of 28×28 pixels normalized to the range [0,1]. Two MLP networks were constructed: the reference homogeneous network composed entirely of conventional models with the RELU activation, and the proposed heterogeneous network with the second hidden layer composed of 50% synchronous conditional activations and 50% max conditional activations, as shown in Fig.4. The 𝐿 of each neuron is connected to the m of a random neuron in the same layer. The output of the last layer is fed into a softmax classifier. Training was done in batch sizes of 100 and weights were updated using the Adam [27] gradient descent algorithm. 𝐿1 ∑ ∑ ∑ 𝜑𝐴𝑁 ∑ 𝐿2 ∑ ∑ ∑ 𝜑𝐴𝑁 ∑ 𝐿 ∑ ∑ ∑ 𝜑𝐴𝑁 ∑ ∑ ∑ 𝜑 ∑ 𝐿 ∑ ∑ ∑ 𝜑 ∑ 𝐿 ∑ ∑ ∑ 𝜑 𝑖 𝑒 𝐿𝑎 𝑒𝑟 𝑖 𝑒 𝐿𝑎 𝑒𝑟 1 𝐿𝑎 𝑒𝑟 𝑠 𝑓 𝑎𝑥 ∑ 𝐿 𝐿𝑎 𝑒𝑟 Fig.4 MLP network structure for evaluating the proposed neuron model 4-layer, 200 neurons/layer 12% 12% 10% 4% 10% heterogeneous homogeneous 8% Error Rate heterogeneous homogeneous 6% Error Rate Error Rate 3-layer, 100 neurons/layer 4-layer, 100 neurons/layer 8% 6% 4% heterogeneous homogeneous 8% 6% 4% 2% 2% 0% 0 a. 1 2 3 4 5 Epoch 6 7 8 9 2% 0% x100 0 b. 1 2 3 4 5 Epoch 6 7 8 0% 9 x100 0 c. 1 2 3 4 5 6 7 8 9 x100 Epoch Fig.5 Recognition error as a function of training epochs for (a) a 4-layer, 200-neuron per layer MLP. (b) a 4layer, 100-neuron per layer MLP, and (c) a 3-layer, 100-neuron per layer MLP Fig.5(a) shows the recognition error as a function of epochs for a 4-layer MLP (3 hidden, one output) with 200 neurons per input/hidden layer. The final recognition error (i.e. when training set overfits) averaged over 5 trials of the homogeneous conventional model is 2.42%, while that of the inhomogenseous network incorporating the proposed model achieves 1.96%, demonstrating a ~20% improvement in error rate. The number of epochs for the former to reach 99% of the final error rate is 110 epochs, while that of the proposed takes only 70 epochs, a speedup of 36%. To generalize the improvement of the proposed model compared to the conventional model, we reduce the number of neurons in each layer from 200 to 100. Expectedly, the error rate increases as the number of 5 neurons per layer is reduced, as shown in Fig.5(b). The proposed models achieve an improvement of 20% and 46% in the error rate and training speed, respectively. We also look at the effect of reducing the number of hidden layers in the network. Our proposed model achieves improvement in error rate and training speed of 17% and 28%, at 3-layer, 100 neurons per layer. The advantages of the heterogeneous network is not only restricted to enhancements in recognition rate and training speed, but also extends to memory capacity. Table 2 shows a summary of the recognition error rate for different network structures, along with the memory needed to store the network. The necessary memory to store weights from a layer of 1 neurons to 2 neurons is 1 2, and the memory for storing biases for 1 neurons is 1 . For the proposed network, an additional 1 parameters are needed to store the 𝐿 input index of each cell. The proposed scheme outperforms a conventional 4-layer, 400 neurons per layer network with a modified 4-layer, 200 neurons per layer network, with a >60% reduction in the memory storage while simultaneously improving error rate and training time. Network Structure 4-layer 400 neurons 4-layer 200 neurons Parameters Error Rate Training Time* Homogeneous 638,810 2.05% 70 Heterogeneous 639,210 1.79% 50 Homogeneous 239,410 2.42% 110 Heterogeneous 239,610 1.96% 70 4-layer 100 neurons Homogeneous 99,710 3.03% 260 Heterogeneous 99,810 2.43% 140 3-layer 200 neurons Homogeneous 199,210 2.47% 100 Heterogeneous 199,410 2.15% 80 Homogeneous 89,610 3.31% 180 Heterogeneous 89,710 2.75% 130 3-layer 100 neurons *Epochs to 99% final recognition error rate Table 2. Recognition error rate, training time, and number of network parameters for different network structures. V. Summary and Future Directions We have introduced a novel scheme for modelling the diverse neural activity in the nervous system, particularly the dynamical modulation of a neurons response. Using this method, we recreated the activity of two special neuronal functions, the synchronous detection and the max function. Preliminary experiment results show that the heterogeneous network incorporating these models show improved recognition rate as well as training epochs across various network configurations, without the penalty in convergence speed, network size, and training data as previous machine learning algorithms. The research directions presented in this paper are intended to further advance machine learning performance through neural diversity. In addition to combining the present proposed model with other machine learning algorithms (e.g. Dropout, DropConnect) and network structures (RNN, spiking,…), the following research directions are also of great interest: (i) Further increasing the diversity in an inhomogeneous neural network, by exploring the different application-specific neurons existing in the human nervous system that are known to be critical to system function, and develop models that represent their behavior at a variety of abstractions. For example, the Nobel Prize winning discovery of place cells 6 and grid cells [28] may prove essential to navigation tasks. (ii) Understanding how learning is affected by neuromodulation, as there exist neurons that are very plastic and also cells that do not learn at all. Furthermore, the learning is also changed dynamically by the same mechanisms in Sec. II. (iii) Exploring the organization of neural functions in both artificial and biological neural networks. The hard-wired anatomy of neuron functions create intrinsic functions, rules, and values that govern our behavior and learning. We thus need to explore the organization of neuronal functions in both biological and the artificial networks, to create a methodology for building intrinsic functions in the system that lead to goal-driven unsupervised learning. At the same time, these functions will compose rules in the operation and growth of the network, such that the network cannot outstep certain boundaries. Interestingly, the mapped synchronous detection and the max functions are identical to the AND and OR functions in computing logic, which may provide a guideline for this purpose. The combined results from these three research directions will allow AI systems to be smaller, faster, and more powerful; at the same time able to achieve tasks without the need for large amounts of training data, while ensuring safety in operation and learning. Acknowledgements References [1] N. Srivastava, G. E. Hinton, A. Krizhevsky, I. Sutskever, and R. Salakhutdinov, “Dropout: a simple way to prevent neural networks from overfitting.,” J. Mach. Learn. Res., vol. 15, no. 1, pp. 1929–1958, 2014. [2] L. Wan, M. Zeiler, S. Zhang, Y. LeCun, and R. Fergus, “Regularization of neural networks using dropconnect,” Icml, no. 1, pp. 109–111, 2013. [3] A. Choromanska et al., “Batch Normalization: Accelerating Deep Network Training by Reducing Internal Covariate Shift,” Data Min. with Decis. Trees, vol. 7, no. 6, pp. 1–9, 2015. [4] T. Tieleman and G. Hinton, “Lecture 6.5-rmsprop: Divide the gradient by a running average of its recent magnitude.,” COURSERA Neural Networks Mach. Learn., 2012. [5] A. Krizhevsky, I. Sutskever, and G. E. Hinton, “ImageNet Classification with Deep Convolutional Neural Networks,” Adv. Neural Inf. Process. Syst., pp. 1–9, 2012. [6] J. G. Andrews, “Seven ways that hetnets are a cellular paradigm shift,” IEEE Commun. Mag., vol. 51, no. 3, pp. 136–144, 2013. [7] L. A. Renzulli, H. Aldrich, and J. Moody, “Family Matters: Gender, Networks, and Entrepreneurial Outcomes,” Soc. Forces, vol. 79, no. 2, pp. 523–546, 2000. [8] R. D. Beer, H. J. Chiel, and L. S. Sterling, “Heterogeneous neural networks for adaptive behavior in dynamic environments,” in Advances in neural information processing systems, 1989, pp. 577– 585. [9] E. ‐Michael Ostapoff, J. J. Feng, and D. K. Morest, “A physiological and structural study of neuron types in the cochlear nucleus. II. Neuron types and their structural correlation with response properties,” J. Comp. Neurol., vol. 346, no. 1, pp. 19–42, 1994. [10] M. H. Giard and F. Peronnet, “Auditory-Visual Integration during Multimodal Object Recognition in Humans: A Behavioral and Electrophysiological Study,” J. Cogn. Neurosci., vol. 11, no. 5, pp. 473–490, 1999. [11] A. S. Motor and N. Study, “THE BULBOCAVERNOSUS REFLEX,” no. December, pp. 813– 820, 2017. 7 [12] A. J. Blood and R. J. Zatorre, “Intensely pleasurable responses to music correlate with activity in brain regions implicated in reward and emotion,” Proc. Natl. Acad. Sci., vol. 98, no. 20, pp. 11818–11823, 2001. [13] K. C. Berridge, T. E. Robinson, and J. W. Aldridge, “NIH Public Access,” vol. 9, no. 1, pp. 65–73, 2010. [14] W. Schultz, “Predictive reward signal of dopamine neurons.,” J. Neurophysiol., vol. 80, no. 1, pp. 1–27, 1998. [15] A. V Egorov, B. N. Hamam, E. Fransen, M. E. Hasselmo, and A. A. Alonso, “Graded persistent activity in entorhinal cortex neurons,” Nature, vol. 420, no. 6912, pp. 173–178, 2002. [16] E. Barkai and M. E. Hasselmo, “Modulation of the input/output function of rat piriform cortex pyramidal cells,” J. Neurophysiol., vol. 72, no. 2, pp. 644–658, 1994. [17] B. L. Bloodgood, N. Sharma, H. A. Browne, A. Z. Trepman, and M. E. Greenberg, “The activitydependent transcription factor NPAS4 regulates domain-specific inhibition,” Nature, vol. 503, no. 7474, pp. 121–125, 2013. [18] H. Demuth, “Neural Networks,” Mathworks inc, vol. 19, no. 1, pp. 1–7, 2006. [19] D. Oertel, R. Bal, S. M. Gardner, P. H. Smith, and P. X. Joris, “Detection of synchrony in the activity of auditory nerve fibers by octopus cells of the mammalian cochlear nucleus.,” Proc. Natl. Acad. Sci. U. S. A., vol. 97, no. 22, pp. 11773–9, 2000. [20] B. Conrey and D. B. Pisoni, “Auditory-visual speech perception and synchrony detection for speech and nonspeech signals.,” J. Acoust. Soc. Am., vol. 119, no. 6, pp. 4065–4073, 2006. [21] N. L. Golding, D. Robertson, and D. Oertel, “Recordings from slices indicate that octopus cells of the cochlear nucleus detect coincident firing of auditory nerve fibers with temporal precision,” J. Neurosci., vol. 15, no. 4, pp. 3138–3153, 1995. [22] M. N. Kunchur, “Temporal resolution of hearing probed by bandwidth restriction,” Acta Acust. united with Acust., vol. 94, no. 4, pp. 594–603, 2008. [23] I. Lampl, D. Ferster, T. Poggio, and M. Riesenhuber, “Intracellular measurements of spatial integration and the MAX operation in complex cells of the cat primary visual cortex.,” J. Neurophysiol., vol. 92, no. 5, pp. 2704–2713, 2004. [24] T. J. Gawne, “Responses of Primate Visual Cortical Neurons to Stimuli Presented by Flash, Saccade, Blink, and External Darkening,” J. Neurophysiol., vol. 88, no. 5, pp. 2178–2186, 2002. [25] J. H. Reynolds, T. Pasternak, and R. Desimone, “Attention Increases Sensitivity of V4 Neurons,” Neuron, vol. 26, no. 3, pp. 703–714, 2000. [26] L. Deng, “The MNIST database of handwritten digit images for machine learning research,” IEEE Signal Process. Mag., vol. 29, no. 6, pp. 141–142, 2012. [27] D. P. Kingma and J. L. Ba, “Adam: a Method for Stochastic Optimization,” Int. Conf. Learn. Represent. 2015, pp. 1–15, 2015. [28] E. I. Moser, E. Kropff, and M.-B. Moser, “Place Cells, Grid Cells, and the Brain’s Spatial Representation System,” Annu. Rev. Neurosci., vol. 31, no. 1, pp. 69–89, 2008. 8
9cs.NE
arXiv:1510.05886v2 [cs.DM] 13 Mar 2017 Approximation Algorithm for Minimum Weight Connected m-Fold Dominating Set Zhao Zhang1 1 Jiao Zhou2 Ker-I Ko3 Ding-zhu Du4 College of Mathematics Physics and Information Engineering, Zhejiang Normal University Jinhua, Zhejiang, 321004, China 2 College of Mathematics and System Sciences, Xinjiang University Urumqi, Xinjiang, 830046, China 3 Department of Computer Science, National Chiao Tung University Hsinchu, 30050, Taiwan 4 Department of Computer Science, University of Texas at Dallas Richardson, Texas, 75080, USA Abstract: Using connected dominating set (CDS) to serve as a virtual backbone in a wireless networks can save energy and reduce interference. Since nodes may fail due to accidental damage or energy depletion, it is desirable that the virtual backbone has some fault-tolerance. A k-connected m-fold dominating set ((k, m)-CDS) of a graph G is a node set D such that every node in V \ D has at least m neighbors in D and the subgraph of G induced by D is k-connected. Using (k, m)-CDS can tolerate the failure of min{k − 1, m − 1} nodes. In this paper, we study Minimum Weight (1, m)-CDS problem ((1, m)-MWCDS), and present an (H(δ+m)+2H(δ−1))-approximation algorithm, where δ is the maximum degree of the graph and H(·) is the Harmonic number. Notice that there is a 1.35 ln n-approximation algorithm for the (1, 1)-MWCDS problem, where n is the number of nodes in the graph. Though our constant in O(ln ·) is larger than 1.35, n is replaced by δ. Such a replacement enables us to obtain a 3.67-approximation for the connecting part of (1, m)-MWCDS problem on unit disk graphs. Keyword: m-fold dominating set, connected dominating set, non-submodular function, greedy algorithm, unit disk graph. 1 Introduction A wireless sensor network (WSN) consists of spatially distributed autonomous sensors to monitor physical or environmental condition, and to cooperatively pass their data through the network. During recent years, WSN has been widely used in many fields, 1 such as environment and habitat monitoring, disaster recovery, health applications, etc. Since there is no fixed or predefined infrastructure in WSNs, frequent flooding of control messages from sensors may cause a lot of redundant contentions and collisions. Therefore, people have proposed the concept of virtual backbone which corresponds to a connected dominating set in a graph (Das and Bhargharan [4] and Ephremides et al. [8]). Given a graph G with node set V and edge set E, a subset of nodes C ⊆ V is said to be a dominating set (DS) of G if any v ∈ V \ C is adjacent to at least one node of C. We say that a dominating set C of G is a connected dominating set of G if the subgraph of G induced by C, denoted by G[C], is connected. Nodes in C are called dominators, the nodes in V \ C are called dominatees. Because sensors in a WSN are prone to failures due to accidental damage or battery depletion, it is important to maintain a certain degree of redundancy such that the virtual backbone is more fault-tolerant. In a more general setting, every sensor has a cost, it is desirable that under the condition that tasks can be successfully accomplished, the whole cost of virtual backbone is as small as possible. These considerations lead to the Minimum Node-Weighted k-Connected m-Fold Dominating Set problem (abbreviated as (k, m)-MWCDS), which is defined as follows: Definition 1.1 ((k, m)-MWCDS). Let G be a connected graph, k and m be two positive integers, c : V → R+ be a cost function on nodes. A node subset D ⊆ V is an m-fold dominating set (m-DS) if every node in V \ D has at least m neighbors in D. It is a kconnected m-fold dominating set ((k, m)-CDS) if furthermore, the subgraph of G induced by D is k-connected. The (k, m)-MWCDS problem is to find a (k, m)-CDS D such that P the cost of D is minimized, that is, c(D) = u∈D c(u) is as small as possible. After Dai and Wu [3] proposed using (k, k)-CDS as a model for fault-tolerant virtual backbone, a lot of approximation algorithms emerged, most of which are on unit disk graphs. In a unit disk graph (UDG), every node corresponds to a sensor on the plane, two nodes are adjacent if and only if the Euclidean distance between the corresponding sensors is at most one unit. There are a lot of studies on fault-tolerant virtual backbone in UDG which assume unit weight on each disk. However, for a general graph with a general weight function, related studies are rare. In this paper, we present a (H(δ + m) + 2H(δ − 1))-approximation algorithm for the (1, m)-MWCDS Pγ problem on a general graph, where δ is the maximum degree of the graph, and H(γ) = 1 1/i is the Harmonic number. It is a two-phase greedy algorithm. First, it constructs an m-fold dominating set D1 of G. Then it connects D1 by adding a set of connectors D2 . It is well known that if the potential function and the cost function related with a greedy algorithm is monotone increasing and submodular, then an O(ln n) performance ration can be achieved. Unfortunately, for various minimum CDS problems, no such potential functions are known. Nevertheless, we manage, in this paper, to deal with a nonsubmodular potential function and achieve an O(ln δ) performance ratio. It should be pointed out that for a general graph, Guha and Khuller [11] proposed a 1.35 ln n-approximation for the (1, 1)-MWCDS problem. Though our constant in O(ln n) 2 is larger, the parameter n in the performance ratio is replaced by δ. In many cases, δ might be substantially smaller than n. In particular, for an UDG, due to such an replacement, after having found an m-DS, the connecting part has a performance ratio at most 3.67. In [34], Zou et al. proposed a method for the connecting part with performance ratio at most 3.875, which makes use of a 1.55-approximation algorithm [16] for the classic Minimum Steiner Tree problem. If using currently best ratio for Minimum Steiner Tree problem [1], then their ratio is at most 3.475. Notice that the algorithm in [1] uses randomized iterative rounding. So, although our ratio 3.67 is a litter larger than 3.475, our algorithm has the advantage that it is purely combinatorial. Furthermore, we believe that our method is also of more theoretical interests and may find more applications in the study of other related problems. The rest of this paper is organized as follows. Section 2 introduces related works. Some notation and some preliminary are given in Section 3. In Section 4, the algorithm is presented. Section 5 analyzes the performance ratio. Section 6 improves the ratio on unit disk graph. Section 7 concludes the paper. 2 Related work The idea of using a connected dominating set as a virtual backbone for WSN was proposed by Das and Bhargharan [4] and Ephremides et al. [8]. Constructing a CDS of the minimum size is NP-hard. In fact, Guha and Khuller [11] proved that a minimum CDS cannot be approximated within ρ ln n for any 0 < ρ < 1 unless NP ⊆ DT IME(nO(loglogn) ). In the same paper, they proposed two greedy algorithms with performance ratios of 2(H(δ) + 1) and H(δ) + 2, respectively, where δ is the maximum degree of the graph and H(·) is the harmonic number. This was improved by Ruan et al. [17] to 2 + ln δ. Du et al. [5] presented a (1 + ε) ln(δ − 1)-approximation algorithm, where ε is an arbitrary positive real number. For unit disk graphs, a polynomial time approximation scheme (PTAS) was given by Cheng et al. [2], which was generalized to higher dimensional space by Zhang et al. [28]. There are a lot of studies on distributed algorithms for this problem. For a comprehensive study on CDS in UDG, the readers may refer to the book [7]. Considering the weighted version of the CDS problem, Guha and Khuller [11] proposed a (cn +1) ln n-approximation algorithm in a general graph, where cn ln k is the performance ratio for the node weighted Steiner tree problem (k is the number of terminal nodes to be connected). Later, they [12] improved it to an algorithm of performance ratio at most (1.35 + ε) ln n. For the minimum weight CDS in UDG, Zou et al. [34] gave a (9.875 + ε)approximation. The problem of constructing fault-tolerant virtual backbones was introduced by Dai and Wu [3]. They proposed three heuristic algorithms for the minimum (k, k)-CDS problem. However, no performance ratio analysis was given. A lot of works have been done for the CDS problem in UDG. The first constant approximation algorithm in this aspect was 3 given by Wang et al. [24], who obtained a 72-approximation for the (2, 1)-CDS problem in UDG. Shang et al. [18] gave an algorithm for the minimum (1, m)-CDS problem and an algorithm for the minimum (2, m)-CDS problem in UDG, the performance ratios are 5 + m5 for m ≤ 5 and 7 for m > 5, and 5 + 25 for 2 ≤ m ≤ 5 and 11 for m > 5, rem spectively. Constant approximation algorithms also exist for (3, m)-CDS in UDG [25, 26]. Recently, Shi et al. [20] presented the first constant approximation algorithm for general (k, m)-CDS on UDG. For the fault-tolerant CDS problem in a general graph, Zhang et al. [30] gave a 2rH(δr + m − 1)-approximation for the minimum r-hop (1, m)-CDS problem, where δr is the maximum degree in Gr , the r-th power graph of G. A node u is r-hop dominated by a set D if it is at most r-hops away from D. In particular, taking r = 1, the algorithm in [30] has performance ratio at most 2H(δ + m − 1) for the minimum (1, m)-CDS problem. This was improved by our recent work [33] to 2 + H(δ + m − 2). We also gave an (ln δ + o(ln δ))-approximation algorithm for the minimum (2, m)-CDS problem [19] and the minimum (3, m)-CDS problem [32] on a general graph. For the weighted version of fault-tolerant CDS problem on UDG, as a consequence of recent work [13], the minimum weight (1, 1)-CDS problem admits a PTAS. Combining the constant approximation algorithm for the minimum weight m-fold dominating set problem [9] and the 3.475-approximation algorithm for the connecting part [34], (1, m)MWCDS on UDG admits a constant-approximation. Recently, we [20, 31] gave the first constant approximation algorithm for the general minimum weight (k, m)-CDS problem on unit disk graph. As far as we know, there is no previous work on the approximation of the weighted version of fault-tolerant CDS problem in a general graph. Notice that in [34], the 3.875-approximation for the connecting part is based on the 1.55-approximation algorithm [16] for the classic minimum Steiner tree problem. If the best known ratio for the Steiner tree problem is used, which is 1.39 currently, then their connecting part has performance ratio at most 3.475. Notice that the 1.39-approximation for the Steiner tree problem uses randomized iterative rounding. So, although our performance ratio is larger than 3.475, it has the advantage that it is purely combinatorial. 3 Preliminaries In this section, we introduce some notation and give some preliminary results. For a node u ∈ V (G), denote by NG (u) the set of neighbors of u in G, andSdegG (u) = |NG (u)| is the degree of node u in G. For a node subset D ⊆ V (G), NG (D) = u∈D NG (u) \ D is the neighbor set of D, G[D] is the subgraph of G induced by D. When there is no confusion in the context, the vertex set of a subgraph will be used to denote the subgraph itself. For an element set U, suppose f : 2U 7→ R+ is a set function on U (called a potential 4 function). For two element sets C, D ⊆ U, let △D f (C) = f (C ∪ D) − f (C) be the marginal profit obtained by adding D into C. For simplicity, △u f (C) will be used to denote △{u} f (C) when u is a node. Potential function f is monotone increasing if f (C) ≤ f (D) holds for any subsets C ⊆ D ⊆ V . It is submodular if and only if △u f (C) ≥ △u f (D) holds for any C ⊆ D ⊆ V and any u ∈ V \ D. A monotone increasing and submodular function f with f (∅) = 0 is called a polymatroid. Given an element set U with cost function c : U 7→ R+ and given a polymatroid f : 2U 7→ R+ , denote by Ωf = {C ⊆ U : △u f (C) = 0 for any u ∈ U }. The Submodular Cover problem is: X min c(C) = c(u) u∈C s.t. C ∈ Ωf . The following is a classic result which can be found in [6] Theorem 2.29. Theorem 3.1. The greedy algorithm for the submodular coverPproblem has performance γ ratio H(γ), where γ = max{f ({u}) : u ∈ U} and H(γ) = i=1 1/i is the Harmonic number. 4 4.1 The Algorithm The Algorithm For a node set C, denote by p(C) the number of components in G[C]. For a node u ∈ V \ C, let NC (u) denote the set of neighbors of u in C. Define  max{m − |NC (u)|, 0}, u ∈ V \ C, qC (u) = 0, u ∈ C, and q(C) = m|V | − X qC (u). u∈V For a node set U ⊆ V , denote by NCC (U) the set of components of G[C] which are adjacent to U. Every component in NCC (U) is called a component neighbor of U in G[C]. For a node u ∈ V , we shall use Su to denote some star with center u, that is, Su is a subgraph of G induced by edges between node u and some of u’s neighbors in G. In particular, a node is a star of cardinality one and an edge is a star of cardinality two. To abuse the notation a little, we also use Su to denote the set of nodes in Su . Suppose Su \ {u} = {u1, u2 , . . . , us }, where c(u1 ) ≤ c(u2 ) ≤ . . . ≤ c(us ). Define p′C (Su ) = |NCC (u)| − 1 + s X min{1, − △ui p(C ∪ {u, u1, . . . , ui−1})}. i=1 5 (1) Call eC (Su ) = p′C (Su )/c(Su ) the efficiency of Su with respect to C. The algorithm is presented in Algorithm 1. Algorithm 1 Input: A connected graph G = (V, E). Output: A (1, m)-CDS DG of G. 1: Set D1 ← ∅ 2: while there exists a node u ∈ V \ D1 such that △u q(D1 ) > 0, do 3: select u which maximizes △u q(D1 )/c(u) 4: D1 ← D1 ∪ {u} 5: end while 6: Set D2 ← ∅ 7: while there exists a star Su ⊆ V \ (D1 ∪ D2 ) such that p′D1 ∪D2 (Su ) > 0, do 8: select a star Su with the largest efficiency with respect to D1 ∪ D2 . 9: D2 ← D2 ∪ S u 10: end while 11: Output DG ← D1 ∪ D2 4.2 The Idea of the Algorithm The idea underlying the algorithm is as follows. Potential function qD1 (u) measures how many more times that node u needs to be dominated, and q(D1 ) is the total residual domination requirement. As can be seen from Lemma 5.2, at the end of the first phase, we have an m-fold dominating set D1 . Then, the second phase aims to connect it by adding a connector set D2 . A natural potential function for connection is p(D1 ∪ D2 ), the number of components of G[D1 ∪ D2 ]. That is, every iteration chooses a node set S to be added into D2 which reduces the number of components by the largest amount until p(D1 ∪ D2 ) reaches 1. It is a folklore result (see Lemma 5.5) that simultaneously adding at most two nodes can reduce the number of components (even when ading any single node does not reduce the number of components). So, it is natural to use max{− △S p(D1 ∪ D2 )/c(S) : S ⊆ V \ (D1 ∪ D2 ), 1 ≤ |S| ≤ 2} (2) to work as a criterion for the choice of node set S to be added into D2 . However, choosing at most two nodes might yield a solution with very bad performance ratio. Consider the example shown in Fig.1, its optimal solution OP T = {u, v1 , . . . , S vd } has cost opt = 1 + (d + 1)ε. If (2) is used as the greedy criterion, then the output is di=1 {ui , vi }, whose S cost is c( di=1 {ui , vi }) = d(1 + ε) ≈ d · opt = n−2 opt. To overcome such a shortcoming, 3 an idea is to choose some star Su to maximize − △Su p(D1 ∪ D2 )/c(Su ) in each iteration. However, the computation of a most efficient star will take exponential time. This is why we define p′ as in (1) to be used in the greedy criterion. On one hand, p′ also plays the role of counting the reduction on components. On the other hand, a most efficient Su to maximize p′D1 ∪D2 (Su )/c(Su ) can be found in polynomial time, which will be shown in Subsection 5.2. 6 u1 v1 s ✚ ✡❩ ❏ ✚ ❩ ✚ ✡ ❏ ❩ u ❝ ✚ ✡ ❏ ❩ ✚ ❩ ❏ ❩❩ ✚ ❝✚ u2 ❝✡✚✚✡ ❏❩❩ ❝ud−1 ❝ud ✡ ❏ ❩ ✚ ✡ ❏ ❩ ✚ ❩ ❝vd ❝✚ v2 ❝✡ . . . ❏ ❝vd−1 s s ... {z } d Figure 1: Solid nodes represent nodes in C. The costs on circled nodes are c(u1 ) = c(u2 ) = . . . = c(ud ) = 1, c(v1 ) = c(v2 ) = . . . = c(vd ) = ε, and c(u) = 1 + ε. s | 5 s The Analysis of the Algorithm In this section, we analyze the performance ratio of Algorithm 1. 5.1 The Analysis of D1 Lemma 5.1. Function q is a polymatroid. Proof. Obviously, q(∅) = 0. It is easy to see that for any node u ∈ V , function −qC (u) is monotone increasing and submodular with respect to C. So, function q, being the summation of a constant function and some monotone increasing and submodular functions, is also monotone increasing and submodular. Lemma 5.2. The final node set D1 in Algorithm 1 is an m-fold dominating set of G. Proof. If there exists a node u ∈ V \D1 with |ND1 (u)| < m, then − △u qD1 (u) = −qD1 ∪{u} (u) + qD1 (u) = −0 + (m − |ND1 (u)|) > 0, and − △u qD1 (v) ≥ 0 for any node v P ∈ V \ {u} (by the monotonicity of −qD1 (v) with respect to D1 ). Thus △u q(D1 ) = − v∈V △u qD1 (v) > 0, and the algorithm does not terminate at this stage. Theorem 5.3. The final node set D1 in Algorithm 1 has weight w(D1) ≤ H(m + δ) · opt, where δ is the maximum degree of graph G, and opt is the optimal value for the m-MWCDS problem. Proof. By Lemma 5.1 and Lemma 5.2, the minimum weight m-fold dominating set problem is a special submodular cover problem with potential function q. So by Theorem 3.1, we have w(D1) ≤ H(γ) · opt′ , where opt′ is the optimal value for the m-MWDS problem. Then, the result follows from the observation that opt′ ≤ opt and γ = max{q({u})} = u∈V P max{m|V | − v∈V \{u} (m − |N{u} (v)|)} = max{m + dG (u)} = m + δ. u∈V u∈V 7 5.2 The Computation of an Optimal Star for Greedy Choice The idea for the definition of p′C (Su ) is as follows: Adding node u into C will merge e which reduces those components in NCC (u) into one component of G[C ∪ {u}], say C, the number of components by |NCC (u)| − 1. Then adding nodes in Su \ {u} sequentially according to the increasing order of their costs. Notice that − △ui p(C ∪ {u1 , . . . , ui−1 }) = |NCC (ui ) \ NCC (u, u1, . . . , ui−1 )| (3) e So, the term in the summation of is the number of components newly merged into C. definition (1) indicates that if adding ui merges at least one more component, we regard its contribution to p′C (Su ) as one. The advantage of such a counting is that an optimal star for the greedy criterion is polynomial-time computable. This claim is based on the following lemma. A simple relation will be used in the proof: for four positive real numbers a, b, c, d a+b b a b ≥ ⇒ ≥ . (4) c+d d c d Lemma 5.4. Suppose C is a dominating set of graph G. Then, there exists a most efficient star Su with respect to C such that |NCC (v)| = 1 for every node v ∈ Su \ {u}. Furthermore, if we denote by Cv the unique component in NCC (v), then components in {Cv }v∈Su \{u} are all distinct and they are also distinct from those components in NCC (u). Proof. Suppose Su is a most efficient star with Su \ {u} = {u1, . . . , us } such that c(u1 ) ≤ . . . ≤ c(us ). We first show that for any i = 1, . . . , s, − △ui p(C ∪ {u, u1, . . . , ui−1}) ≥ 1. (5) Suppose this is not true. Let i be the first index with − △ui p(C ∪ {u, u1, . . . , ui−1 }) = 0. Then by (3), we have NCC (ui ) ⊆ NCC (u, u1, . . . , ui−1 ) and thus NCC (u, u1, . . . , ui−1) = NCC (u, u1, . . . , ui ). It follows that for any j > i, − △uj p(C ∪ {u, u1, . . . , ui−1 , ui+1, . . . , uj−1}) = − △ui p(C ∪ {u, u1, . . . , uj−1}). So, for the star Su′ = Su \ {ui }, we have p′C (Su′ ) = p′C (Su ) and thus p′C (Su′ )/c(Su′ ) > p′C (Su )/c(Su ), contradicting the maximality of p′C (Su )/c(Su ). As a consequence of (5), p′C (Su ) = |NCC (u)| − 1 + s. Suppose there is a node ui with |NCC (ui )| ≥ 2, we choose ui to be such that i is as small as possible. Let Su′ = Su \ {ui }. Notice that for any j > i, − △uj p(C ∪ {u, u1, . . . , ui−1 , ui+1 , . . . , uj−1}) ≥ − △ui p(C ∪ {u, u1, . . . , uj−1}). Combining this with (5), we have p′C (Su′ ) = |NCC (u)| − 1 + (s − 1) = p′C (Su ) − 1. 8 By the maximality of Su , we have p′C (Su ) p′C (Su′ ) + 1 p′C (Su′ ) ≤ = . c(Su′ ) c(Su ) c(Su′ ) + c(ui ) Then by (4), p′C (Su′ ) 1 ≤ . c(Su′ ) c(ui ) It follows that 1 c(Su′ ) + 1 p′C (Su′ ) + 1 1 p′C (ui ) p′C (Su ) c(ui ) = ≤ = ≤ , c(Su ) c(Su′ ) + c(ui ) c(Su′ ) + c(ui ) c(ui ) c(ui ) where the last inequality holds because p′C (ui ) = |NCC (ui )| − 1 ≥ 1. Hence ui is a also a most efficient star. It is a trivial star satisfing the requirement of the lemma. Next, suppose Su is a nontrivial star in which every v ∈ Su \ {u} has |NCC (v)| = 1. Notice that an equivalent statement of (5) is that |NCC (ui ) \ NCC (u, u1, . . . , ui−1)| ≥ 1 for any i = 1, . . . , s. The second part of this lemma follows. By Lemma 5.4, a most efficient star with respect to C can be found in the following way. Guessing the center of the star requires time O(n). Suppose u is the guessed center. Let N (u) = {v : v is a neighbor of u in G and |NCC (v)| = 1}. Order the nodes in N (u) as u1 , . . . , us such that c(u1 ) ≤ . . . ≤ c(us ). For i = 1, . . . , s, scan ui sequentially. If ui has NCC (ui ) ⊆ NCC (u, u1, . . . , ui−1), then remove it from N (u) . For convenience of statement, suppose the remaining set N (u) = {u1 , u2 . . . , ut}. Then, the node set of a most efficient star centered at u must be of the form {u, u1, u2 , . . . , ul } for some l ∈ {0, . . . , t}. So, it suffices to compute the efficiency of the t + 1 sets {u, u1, . . . , ul } for l = 0, . . . , t and choose the most efficient one from them. Clearly, such a computation can be done in polynomial time. 5.3 Correctness of the Algorithm The following result is a folklore in the study of CDS (see, for example, [22]). Lemma 5.5. Suppose D is a dominating set of G such that G[D] is not connected. Then, two nearest components of G[D] are at most three hops away. Theorem 5.6. The output DG of Algorithm 1 is a (1, m)-CDS. Proof. By Lemma 5.2, D1 is an m-fold DS, and thus DG is also an m-DS. If G[DG ] is not connected, consider two nearest components of G[DG ], say G1 and G2 . Let P = u0 u1 . . . ut be a shortest path between G1 and G2 , where u0 ∈ V (G1 ) and ut ∈ V (G2 ). By Lemma 5.5, we have t = 2 or 3. Then, u1 (in the case t = 2) or u1u2 (in the case t = 3) is a star Su1 with p′DG (Su1 ) > 0. The algorithm will not terminate. 9 5.4 Decomposition of Optimal Solution The following lemma, as well as its proof, can be illustrated by Fig.2. Lemma 5.7. Let G be a connected graph, C be a dominating set of G and C ∗ be a connected dominating set of G. Then C ∗ \C can be decomposed into the union of node sets C ∗ \C = Y0 ∪ Y1 ∪ Y2 ∪, . . . , ∪Yh such that: (i) for 1 ≤ i ≤ h, subgraph G[Yi ] contains a star; (ii) subgraph G[C ∪ Y1 ∪ Y2 ∪, . . . , ∪Yh ] is connected; (iii) for 1 ≤ i ≤ h, |NCC (Yi )| ≥ 2; (iv) any node of C ∗ \C belongs to at most two sets of {Y0, Y1 , Y2 , . . . , Yh }. Proof. Let H be the graph obtained from G[C ∪ C ∗ ] by contracting every component of G[C] into a super-node (call it a terminal node). Since G[C ∪ C ∗ ] is connected, H is also connected, and thus H contains a spanning tree T . Recursively pruning non-terminal leaves, we obtain a tree T ′ in which every leaf is a terminal node (see Fig.2(a)(b)). Let Y0 be the set of pruned nodes. We may assume that every non-terminal node has at least one terminal neighbor in T ′ . (6) In fact, if this is not true, then we can modify T ′ into another tree satisfying this assumption. See Fig.2(c)(d) for an illustration. In (c), node u does not have a terminal neighbor in T ′ . Since C is a dominating set, u is adjacent with some component of G[C], say the component corresponding to terminal node v. Adding edge uv creates a unique cycle in T ′ + uv. Removing the edge on this cycle which is incident with u in T ′ , we have another tree in which u has a terminal neighbor (see Fig.2(d)). Notice that the removed edge is between two non-terminal nodes. So, the number of non-terminal nodes which have no terminal neighbors is strictly reduced. Recursively making such a modification results in a tree satisfying assumption (6). Tree T ′ can be viewed as a Steiner tree. By splitting off at non-leaf terminal nodes, T can be decomposed into full components T1′ , . . . , Tl′ (a full component in a Steiner tree is a subtree in which a node is a leaf if and only if it is a terminal node, see Fig.6(e)). Let Ti be the subtree of Ti′ induced by those non-terminal nodes. ′ For each i ∈ {1, . . . , l}, let vi be an arbitrary node of Ti and view Ti as a tree rooted at vi . For each node v ∈ V (Ti ), let Sv be the star centered at node v which Sl contains all children of v in Ti . Let Si = {Sv : v ∈ V (Ti ) and |NCC (Sv )| ≥ 2}. Let S = i=1 Si . Then {Yv = V (Sv ) : Sv ∈ S} is a desired decomposition of C ∗ \ (C ∪ Y0 ) (see Fig.6(f)). It should be noted that property (6) is used to guarantee that no node is missed in the decomposition. For example, in Fig.6(c) which does not satisfy this assumption, if we choose x to be the root of the lower subtree, then Su = uy and Sy = y are stars which does not have at least two terminal neighbors in T ′ , and thus they are excluded from S. But then, node y does not belong to any star in the decomposition. 10 s s ❝ s s ❝ ❝ ❝ s s ❝ ❛❝ s ❝ ❝ s ❛❝ s s ❛❝ ❛❝ ❝ s ❛❝ s s ❝ s s ❝ s ❝ ❝ vs x❝ ❝ ❝ ❝ s s s s ❝ u❝ y❝ s s ❝ (c) s s ❝ ❝ s ❝ (b) s ❝ s ❝ (a) s s ❝ ❝ ❝ ❝ s s (d) ❝ s s ❝ sss ❝ T1 ❝ T2 s ❝ T3 ❝ ❝ s s s (e) ❝ s ❝ ❝ S1 ❝ S2 ❝ S3 ❝ ❝ ❝ ❝S4 ❝S5 (f) Figure 2: An example for the decomposition of C ∗ \ C. Solid nodes are terminal nodes which correspond to components of G[C]. In (a), double circle nodes are pruned, yielding tree T ′ in (b). Figures in (c) and (d) are used to show how to obtain a tree satisfying assumption (6). In (c), the dashed edge uv is in G but not in T ′ . Adding edge uv and removing edge ux results in the tree in (d). Full components of T ′ are shown in (e). Figure (f ) shows the decomposed stars. 11 5.5 The Performance Ratio Theorem 5.8. The connector set D2 of Algorithm 1 has cost c(D2 ) ≤ 2H(δ − 1)opt. Proof. Let S1 , S2 , . . . , Sg be the sets chosen by Algorithm 1 in the order of their selection (0) into set D2 . Let DG = D1 . For 1 ≤ i ≤ g, let (i) (0) DG = DG ∪ S1 ∪ . . . ∪ Si . For i = 1, . . . , g, denote (i−1) ri = − △Si p(DG ) and wi = c(Si ) (i−1) − △Si p(DG ) . Suppose {Y0, Y1 , . . . , Yh } is the decomposition of OP T \ D1 as in Lemma 5.7, where Yi is a star centered at node vi . For i = 1, . . . , g + 1 and j = 1, . . . , h, denote ai,j = p′D(i−1) (Yj ). (7) G For 1 ≤ j ≤ h, define f (Yj ) = g X (ai,j − ai+1,j )wi , i=1 and let f (OP T ) = h X f (Yj ). (8) j=1 Claim 1. For any j = 1, . . . , h, f (Yj ) ≤ H(a1,j )c(Yj ). Since Si is chosen according to Lemma 5.4, the special structure of Si implies that (i−1) p′D(i−1) (Si ) = − △Si p(DG ). G Hence, wi = c(Si ) . ′ p (i−1) (Si ) DG Then, by the greedy choice of Si , we have c(Yj ) c(Yj ) c(Si ) . ≤ ′ = wi = ′ p (i−1) (Si ) p (i−1) (Yj ) ai,j DG (9) DG By the definition of p′ , it can be seen that ai,j is a decreasing function on variable i. Hence ai,j − ai+1,j ≥ 0. Combining this with (9), f (Yj ) ≤ g X (ai,j − ai+1,j ) i=1 ≤ c(Yj ) g X c(Yj ) ai,j H(ai,j ) − H(ai+1,j ) i=1  = c(Yj ) H(a1,j ) − H(ag+1,j ) , 12  where the second inequality uses the fact that for any integers a ≥ b, a a X X 1 1 a−b = ≤ = H(a) − H(b). a a l l=b+1 l=b+1 (g) Observe that ag+1,j = 0 since DG is connected, the claim follows. Claim 2. c(D2 ) ≤ f (OP T ). Notice that c(D2 ) and f (Yj ) can be rewritten as ! ! ! g g g g g g g X X X X X X X rl (wi − wi−1 ) rl w 1 + rl w i = rl − ri w i = c(D2 ) = i=1 i=1 l=i+1 l=i i=2 l=1 l=i (10) and f (Yj ) = a1,j w1 + g X ai,j (wi − wi−1 ). (11) i=2 ′ By the monotonicity of p , we have greedy choice of Si−1 , we have wi = c(Si ) ′ p (i−1) (Si ) DG ≥ p′ (i−1) (Si ) DG ≤ p′ c(Si ) ′ p (i−2) (Si ) DG ≥ (i−2) DG (Si ). Combining this with the c(Si−1 ) ′ p (i−2) (Si−1 ) DG = wi−1 . In other words, wi − wi−1 ≥ 0 for i = 1, . . . , g. Then, by (8), (10), and (11), it can be seen that to prove Claim 2, it suffices to prove that for i = 1, . . . , g, h X ai,j ≥ j=1 g X rl . (12) l=i The right hand side is g X l=i rl = g X l=i (l−1) −△Sl p(DG ) = g X (l−1) p(DG l=i (l)  (i−1) (g) (i−1) )−p(DG ) = p(DG )−p(DG ) = p(DG )−1. So, proving (12) is equivalent to proving h X j=1 (i−1) p′D(i−1) (Yj ) + 1 ≥ p(DG ). (13) G This inequality can be illustrated by Fig.3. In this figure, OP T is decomposed into four stars. A comprehension for the value p′D (Y1 ) = 3 is that in Fig.3(c), the double circled e components are merged into the triangled component. Call the new component as C. ′ Then, the comprehension of pD (Y2 ) = 3 is that in Fig.3(d), double circled components are merged into the triangled component. Notice that this triangled component is contained e and thus we can regard it as C e in our comprehension. Continue this procedure in C, 13 sequentially in such a way that Y1 ∪ . . . ∪ Yl is connected for l = 1, . . . , 4. Finally, all components of G[D] are merged into one component, the reduction on the number of components is p(D) − 1. Notice that the inequality might be strict because some components are counted more than once in the summation part. For example, the component labeled by u4 is repetitively counted. ut1 ut2 u4 t ut3 S❞1 ❞ v1 u5 t ❞v2 v4 ❞ ❞v3 v5 ❞ t❣ ❞ ❞ t❣ ❞ ❞ S2 S4 ❞ t ❞ ❞ ❞ ❞ ❞ S3 u6 t u7 t u8 t u9 t (a) (b) (c) t △ t △ ❣ t ❞ ❞ t △ ❞ ❣ t t t △ t❣ t❣ t △ ❞ t❣ t ❞ t❣ (d) (e) (f) Figure 3: An illustration for inequality (13). Solid circles indicate components. Claim 2 is proved. By Lemma 5.7 (iv), we have h X c(Yi ) ≤ 2opt. (14) i=1 Then by Claim 1, Claim 2, and the observation that a1,j ≤ δ − 1, we have c(D2 ) ≤ h X c(Yj )H(δ − 1) ≤ 2H(δ − 1)opt. j=1 The theorem is proved. Combining Theorem 5.3 and Theorem 5.8, we have the following result.  Theorem 5.9. Algorithm 1 is a polynomial-time H(δ + m) + 2H(δ − 1) -approximation for the m-MWCDS problem. 14 6 Implementation on Unit Disk Graphs Notice that the maximum degree δ in the performance ratio of the second part of the algorithm comes from a1,j ≤ δ − 1. So, to improve the approximation factor when the graph under consideration is a unit disk graph, we improve the upper bound for a1,j first. We use notation T1 , . . . , Tl in the proof of Lemma 5.7. Recall that each Ti has V (Ti ) ⊆ C ∗ \ C and is decomposed into some stars, and the final decomposition of C ∗ \ C is the union of these stars and a set of pruned nodes. We shall use k·k to denote Euclidean length. Lemma 6.1. In a unit disk graph, there exists a set of subtrees T1 , . . . , Tl in the proof of Lemma 5.7 such that any node v ∈ V (Ti ) has |NCC (v)| + degTi (v) ≤ 5. Proof. Construct a spanning tree of G[C ∪C ∗ ] as follows. First, replace each component of G[C] by a spanning tree of that component, which is called a tree component. Then, find a minimum length tree T which spans all nodes of C ∗ \ C and all tree components, where “minimum length” is with respect to Euclidean distance. For convenience of statement, we shall call a tree which spans all nodes of C ∗ \ C and all tree components as a valid tree. Each component of G[C] is called a component node of such a tree and is dealt with as a whole in the following. Similarly to the proof of Lemma 5.7, by pruning leafs in C ∗ \ C and by splitting off at component nodes, we obtain a set of full components T1′ , . . . , Tl′ . Let Ti be the subtree of Ti′ with component nodes removed. We choose tree T such that l X X degTi (u) is as small as possible. (15) i=1 u∈V (Ti ) Suppose there is a node v ∈ V (Ti ) with |NCC (v)|+degTi (v) = t > 6, assume NCC (v)∪ NTi (v) = {x1 , . . . , xt }, where xj is a node in C ∗ \ C or a node in a component neighbor of v (if v is adjacent with more than one node of a component neighbor, only one node of that component neighbor is chosen to appear in {x1 , . . . , xt }), and x1 , . . . , xt are in a clockwise order around node v. Since t > 6, there is an index j with ∠xj vxj+1 < π/3 (xt+1 is viewed as x1 ). Then kxj xj+1 k < max{kvxj k, kvxj+1k}, say kxj xj+1 k < kvxj k. Replacing edge vxj by xj xj+1 , we obtain another valid tree whose Euclidean length is shorter than T , a contradiction. So, every node v ∈ V (Ti ) has |NCC (v)| + degTi (v) ≤ 6. (16) A node u with |NCC (v)| + degTi (v) = 6 is called bad. Similar argument shows that for any bad node v ∈ V (Ti ), ∠xj vxj+1 = π/3 for j = 1, . . . , 6 and kvx1 k = · · · = kvx6 k. In other words, x1 , . . . , x6 locate at the corners of a regular hexagon with center v. First, suppose node v has a component neighbor, say x1 is in a component neighbor of v. If x2 ∈ C, then x2 must be in a same component of G[C] as x1 , because kx1 x2 k = kvx1 k ≤ 1, contradicting our convention that one component has at most one node appearing in {x1 , . . . , x6 }. So, x2 ∈ C ∗ \ C. Then, Te = T − {vx2 } + {x1 x2 } 15 P P is a valid tree with the same length as T . Notice that li=1 u∈V (Ti ) degTi (u) is decreased by two (edge x1 x2 does not contribute to the degree sum since one of its end is in a component neighbor and thus does not belong to Ti ), contradicting the choice of T (see (15)). So, for j = 1, . . . , 6, xj ∈ C ∗ \ C. Since Te = T − {vxj−1 , vxj+1} + {xj xj−1 , xj xj+1 } is also a valid tree whose length is the same as T , we have |NCC (xj )| + degTei (xj ) ≤ 6. By noticing that degTei (xj ) = degTi (xj ) + 2 (since both xj−1 , xj+1 ∈ C ∗ \ C), we have |NCC (xj )| + degTi (xj ) ≤ 4. (17) This inequality holds for any j = 1,P . . . , 6.PNotice that Tb = T P − {vxP 1 } + {x1 x2 } is a valid l l deg (u) = tree with the same length as T and i=1 u∈V (Tbi ) i=1 u∈V (Ti ) degTi (u). By Tbi property (16) and (17), we have   |NCC (u)| + degTi (u) − 1 ≤ 5, u = v, |NCC (u)| + degTbi (u) = |NCC (u)| + degTi (u) + 1 ≤ 5, u = x1 or x2 ,  |NCC (u)| + degTi (u) ≤ 6, u 6= v, x1 , x2 . So, the number of bad nodes in Tb is strictly reduced. By recursively executing such an operation, we have a tree satisfying the requirement of this lemma. Recall that condition (6) plays an important role in the decomposition. This does no pose any difficulty here, because by the modification method in the proof of Lemma 5.7, if u ∈ C ∗ \ C is not adjacent with any component neighbor in T ′ , then we may just add an edge between u and a component neighbor, and remove an edge between u and another node in C ∗ \ C. Such an operation does not increase the value of |NCC (u)| + degTi (u). Theorem 6.2. When applied to unit disk graphs, the node set D2 produced by Algorithm 1 has cost c(D2 ) ≤ 3.67opt. Proof. Let T1 , . . . , Tl be the subtrees in Lemma 6.1. Choose node vi = arg max{c(v) : v ∈ V (Ti )} to be the root of Ti . Decompose C ∗ \ C as in the proof of Lemma 5.7. Let (i) {Yv } be the set of stars coming from the decomposition of Ti . To avoid ambiguity, we (i) use a1,Yv(i) to denote p′D1 (Yv ) (which is a1,j in the proof of Theorem 5.8). By Lemma 6.1, if v = vi , then a1,Yv(i) ≤ |NCD1 (v)| − 1 + degTi (v) ≤ 4; if v 6= vi , then a1,Yv(i) ≤ |NCD1 (v)| − 1 + degTi (v) − 1 ≤ 3 (this is because the parent of v is not in Yv if v 6= vi ). Notice that vi belongs to exactly one star in the decomposition of C ∗ \ C. Hence inequality (14) can be improved to l X X i=1 c(Yv(i) ) + l X c(vi ) ≤ 2opt. (18) i=1 (i) Yv Combining Lemma 6.1 with Claim 1 and Claim 2 of Theorem 5.8,   l X l X X X H(4)c(Yv(i) ) + H(3) c(D2 ) ≤ c(Yv(i) )H(a1,Yv(i) ) ≤ c(Yv(i) ) . i i=1 Y (i) v i=1 (i) Yv ,v6=vi 16 (19) Since D1 is an m-fold dominating set, every vi has at least one component neighbor. (i) Then by Lemma 6.1, degTi (vi ) ≤ 4, and thus Yvi has at most five nodes. Since vi has the (i) maximum cost in Ti , we have c(Yvi ) ≤ 5c(vi ). So, (i)  c(Yvi ) (i) ≤ H(3)c(Yv(i) ) + 5c(v )/4 < H(3) c(Y ) + c(v ) . = + i i vi i 4 Combining this inequality with (18) and (19),   l X l X X c(D2 ) ≤ H(3)  c(vi ) ≤ 2H(3)opt < 3.67opt. c(Yv(i) ) + H(4)c(Yv(i) ) i H(3)c(Yv(i) ) i i=1 Y (i) v i=1 The theorem is proved. 7 Conclusion In this paper, we presented a (H(δ + m) + 2H(δ − 1))-approximation algorithm for the minimum weight (1, m)-CDS problem, where δ is the maximum degree of the graph. Compared with the 1.35 ln n-approximation algorithm for the minimum (1, 1)-CDS problem [12], our constant is larger. However, since in many cases, the maximum degree is much smaller than the number of nodes, our result is an improvement on the performance ratio in some sense. In particular, the replacement of n by δ in the performance ratio makes it possible to obtain a 3.67-approximation for the connecting part when the topology of the network is a unit disk graph. In fact, Zou et al. obtained a 2.5ρ-approximation for the connecting part in a unit disk graph, where ρ is the performance ratio for the minimum Steiner tree problem. If the best ρ = 1.39 is used, their algorithm has performance ratio 3.475. Notice that the 1.39-approximation algorithm for the minimum Steiner tree problem uses a combination of iterated rounding and random rounding. Our algorithm has the advantage of purely combinatorial and deterministic. Furthermore, we expect our method to have a theoretical value which can be used to deal with other problems. Acknowledgements This research is supported by NSFC (61222201,11531011), SRFDP (20126501110001), and Xingjiang Talent Youth Project (2013711011). It is accomplished when the second author is visiting National Chiao Tung University, Taiwan, sponsored by “Aiming for the Top University Program” of the National Chiao Tung University and Ministry of Education, Taiwan. References [1] Byrka J, Grandoni F, Rothvoss T, Sanità L (2013) J. ACM, 60(1), Article 6. 17 [2] Cheng X, Huang X, Li D, Wu W, Du DZ (2003) A polynomial-time approximation scheme for the minimum-connected dominating set in ad hoc wireless networks. Networks, 42(4), 202–208. [3] Dai F, Wu J (2006) On constructing k-connected k-dominating set in wireless ad hoc and sensor networks. J Parallel Distrib Comput 66(7), 947–958. [4] Das B, Bharghavan V (1997) Routing in ad-hoc networks using minimum connected dominating sets. IEEE International Conference on Comunications, Montreal, 376– 380. [5] Du DZ, Graham RL, Pardalos PM, Wan PJ, Wu WL, Zhao W (2008) Analysis of greedy approximation with nonsubmodular potential functions. SODA’08, 167–175. [6] Du DZ, Ko K, Hu X (2012) Design and analysis of approximation algorithms. Springer, New York. [7] Du DZ, Wan PJ (2013) Connected Dominating Set: Theory and Applications, Springer, New York. [8] Ephremides A, Wieselthier J, Baker D (1987) A design concept for reliable mobile radio networks with frequency hopping signaling. Proc IEEE 56–73. [9] Fukunage T (2015) Constant-approximation algorithms for highly-connected multidominating sets in unit disk graphs. arXiv:1511.09156. [10] Gao X, Wang Y, Li X, Wu W (2009) Analysis on theoretical bounds for approximating dominating set problems. Discrete Math. Algo. Appl., 1(1), 71–84. [11] Guha S, Khuller S (1998) Approximation algorithms for connected dominating sets. Algorithmica, 20(4), 374–387. [12] Guha S, Khuller S (1999) Improved methods for approximating node weithed steiner trees and connected dominating sets. Information and Computation 150, 57–74. [13] Li J, Jin Y (2015) A PTAS for the weighted unit disk cover problem. ICALP’15. [14] Li M, Wan P, Yao F (2009) Tighter approximation bounds for minimum CDS in wireless ad hoc networks. ISAAC’09, LNCS 5878, 699–709. [15] Li Y, Wu Y, Ai C, Beyah R (2012) On the construction of k-connected m-dominating sets in wireless networks. J. Comb. Optim. 23, 118–139. [16] Robins G, Zelikovsky A (2000) Improved Steiner tree approximation in graphs. SODA’00, 770–779. [17] Ruan L, Du H, Jia X, Wu W, Li Y, Ko K (2004) A greedy approximation for minimum connected dominating sets. Theor. Comput. Sci. 329(1), 325–330. [18] Shang W, Yao F, Wan P, Hu X (2008) On minimum m-connected k-dominating set problem in unit disc graphs. J. Comb. Optim. 16, 99–106. 18 [19] Shi Y, Zhang Y, Zhang Z, Wu W (2016) A greedy algorithm for the minimum 2connected m-fold dominating set problem. J. Comb. Optim. 31, 136–151. [20] Shi Y, Zhang Z, Mo Y, Du D-Z (2017) Approximation algorithm for minimum weight fault-tolerant virtual backbone. IEEE/ACM Trans. Net. doi:10.1109/TNET.2016.2607723. in Unit Disk Graphs [21] Thai M, Zhang N, Tiwari R, Xu X (2007) On approximation algorithms of kconnected m-dominating sets in disk graphs. Theor. Comput. Sci. 385, 49–59. [22] Wan PG, Alzoubi KM, Frieder O (2002) Distributed construction of connected dominating set in wireless ad hoc networks. INFOCOM’02 1597–1604, Mobile Networks and Applications, 9, 141–149. [23] Wan PJ, Wang L, Yao F (2008) Two-phased approximation algorithms for minimum CDS in wireless ad hoc networks. ICDCS’08, 337–344. [24] Wang F, Thai M, Du DZ (2009) On the construction of 2-connected virtual backbone in wireless networks. IEEE Trans. Wirel. Commun. 8(3), 1230–1237. [25] Wang W, Kim D, An M, Gao W, Li X, Zhang Z, Wu W (2013) On construction of quality fault-tolerant virtual backbone in wireless networks. IEEE/ACM Trans. Netw. 21(5), 1499–1510. [26] Wang W, Liu B, Kim D, Li D, Wang J, Jiang Y (2015) A better constant approximation for minimum 3-connected m-dominating set problem in unit disk graph using Tutte decomposition, to appear in INFOCOM’15. [27] Wu W, Du H, Jia X, Li Y, Huang S (2006) Minimum connected dominating sets and maximal independent sets in unit disk graphs. Theor. Comput. Sci. 352, 1–7. [28] Zhang Z, Gao X, Wu W, Du DZ (2009) A PTAS for minimum connected dominating set in 3-dimensional wireless sensor networks. J. Glob. Optim. 45, 451–458. [29] Zhang Z, Willson J, Wu W, Zhu X, Du DZ (2015) (3 + ε)-approximation for the minimum weight k-cover problem, in submission. A preliminary version was Computer Communications (INFOCOM), 2015 IEEE Conference on, pp 1364–1372. [30] Zhang Z, Liu Q, Li D (2009) Two algorithms for connected r-hop k-dominationg set. Discrete Math. Algo. Appl. 1(4), 485–498. [31] Zhang Z, Shi Y (2015) Approximation algorithm for minimum weight fault-tolerant virtual backbone in homogeneous wireless sensor network. Computer Communications (INFOCOM), 2015 IEEE Conference on, pp 1080–1085. [32] Zhang Z, Zhou J, Mo Y, Du D-Z (2016) Performance-guaranteed approximation algorithm for fault-tolerant connected dominating set in wireless networks. INFOCOM2016. 19 [33] Zhou J, Zhang Z, Wu W, Xing K (2014) A greedy algorithm for the fault-tolerant connected dominating set in a general graph. J. Comb. Optim. 28(1), 310–319. [34] Zou F, Li X, Gao S, Wu W (2009) Node-weighted Steiner tree approximation in unit disk graphs. J. Comb. Optim. 18, 342–349. [35] Zou F, Wang Y, Xu X, Du H, Li X, Wan P, Wu W (2011) New approximations for weighted dominating sets and connected dominating sets in unit disk graphs. Theoret. Comput. Sci. 412(3), 198–208. 20
8cs.DS
Efficient Generation of Geographically Accurate Transit Maps Hannah Bast Patrick Brosi Sabine Storandt University of Freiburg Freiburg, Germany University of Freiburg Freiburg, Germany JMU Würzburg Würzburg, Germany [email protected] [email protected] [email protected] arXiv:1710.02226v1 [cs.CG] 5 Oct 2017 ABSTRACT We present LOOM (Line-Ordering Optimized Maps), a fully automatic generator of geographically accurate transit maps. The input to LOOM is data about the lines of a given transit network, namely for each line, the sequence of stations it serves and the geographical course the vehicles of this line take. We parse this data from GTFS, the prevailing standard for public transit data. LOOM proceeds in three stages: (1) construct a so-called line graph, where edges correspond to segments of the network with the same set of lines following the same course; (2) construct an ILP that yields a line ordering for each edge which minimizes the total number of line crossings and line separations; (3) based on the line graph and the ILP solution, draw the map. As a naive ILP formulation is too demanding, we derive a new custom-tailored formulation which requires significantly fewer constraints. Furthermore, we present engineering techniques which use structural properties of the line graph to further reduce the ILP size. For the subway network of New York, we can reduce the number of constraints from 229,000 in the naive ILP formulation to about 4,500 with our techniques, enabling solution times of less than a second. Since our maps respect the geography of the transit network, they can be used for tiles and overlays in typical map services. Previous research work either did not take the geographical course of the lines into account, or was concerned with schematic maps without optimizing line crossings or line separations. 1 INTRODUCTION Cities with a public transit network usually have a map which illustrates the network and which is posted at all stations. Many map services also feature a transit layer where all lines and stations in an area are displayed. Such a map should satisfy the following main criteria: (1) It should depict the topology of the network: which transit lines are offered, which stations do they serve in which order, and which transfers are possible. (2) It should be neatly arranged and esthetically pleasing. (3) It should reflect the geographical course of the lines, at least to some extent. So far, such maps have been designed and drawn by hand. Concerning (3), the designers usually take some liberty, either to make the map fit into a certain format or to simplify the layout, or both. The goal of this paper is to produce transit maps fully automatically, adhering to (3) rather strictly: within a given tolerance, the lines on the map should be drawn according to their geographical course. This rises several algorithmic challenges; in particular because the geographical course of some lines may overlap partially. These lines should then of course not be rendered on top of each other as this would obfuscate the visibility. Instead, they should be Figure 1: Left: Google transit map cutout for Chicago. Right: LOOM map for the same area. drawn next to each other. This requires to first identify overlapping parts and then to choose the line ordering in the rendered map. A bad ordering can lead to many unnecessary line crossings. Hence our goal is to find orderings that minimize these undesired crossings. As the number of possible orderings exceeds an octillion even for the transit network of medium sized cities, we need to develop efficient methods to find the best ordering in reasonable time. 1.1 Overview and Definitions LOOM proceeds in three stages, which we briefly describe in the following along with some notation and terminology that will be used throughout the paper. Each stage is described in more detail in one of the following sections. Input: The input to LOOM is a set S of stations and a set L of lines. Each station has a geographical location. Each line has a unique ID (in our examples: numbers), the sequence of stations it serves, and the geographical course between them. This data is usually provided as part of a network’s GTFS feed. Line graph construction (Sect. 2): In its first stage, LOOM computes a line graph. This is an undirected labeled graph G = (V , E, L), where V ⊇ S (each station is a node, but there may be additional nodes), E is the set of edges, and each e ∈ E is labeled with a subset L(e) ⊆ L of the lines. Intuitively, each edge corresponds to a segment of the network, where the same set of lines takes the same geographical course (within a certain tolerance), and there is a node wherever such a set of lines splits up in different directions. Figure 2 shows the line graph for an excerpt from the light rail network of Stuttgart. We will see that the complexity of our algorithms in Sect. 3 depends on M = maxe ∈E |L(e)|, the maximal number of lines per segment. 5,6,7,9,11, 12,14,15 5,6,7,12,15 9,11,14 1,2,9,11,14 9,11,14 5,6,7, 12,15 4 9,11,14 15 1,2,4,11 5,6,7,12,15 2,9 1,2,4,11 15 5,6,7, 12,15 2,4,11,14 15 2,4,11,14 15 1,2,4,11 5,6,7,12 1,14 Figure 2: Left: Excerpt from a line graph which LOOM constructs for the 2015 light rail network of the city of Stuttgart from the given GTFS data. Each edge corresponds to a segment of the network where the same set of lines takes the same geographical course. Segment boundaries are often station nodes (large) but may also be intermediate nodes (small). The line ids for each segment are given in ascending order. LOOM’s central optimization step computes a line ordering that determines how the lines are drawn in the map, and where line crossings and separations occur. Right: The corresponding excerpt from LOOM’s transit map. Line ordering optimization (Sect. 3): In its second stage, LOOM computes an ordering of L(e) for each e ∈ E. This ordering determines where line crossings and separations occur, and is hence critical for the final map appearance. Previous research referred to the problem of minimizing crossings as the metro-line crossing minimization problem (MLCM), see Sect 1.3. We call a strongly related problem the metro-line node crossing minimization problem (MLNCM) with an optional line separation penalty (MLNCM-S) and formulate a concise Integer Linear Program (ILP) to solve it. Rendering (Sect. 5): In its third stage, LOOM draws the transit map based on the line graph from stage 1 and the ordering from stage 2. Each station node v is drawn as a polygon, where each side of the polygon corresponds to exactly one incident edge of v. We call this side the node front of that edge at that node. The node front for an edge e has |L(e)| so-called ports (Fig. 3). Drawing the map then amounts to connecting the ports (according to the ordering computed in stage 2) and drawing the station polygons. Figure 2, right, shows a rendered transit map after layout optimization. 1.2 Contributions • We present a new automatic map generator, called LOOM (LineOrdering Optimized Maps), for geographically accurate transit maps. The input is basic schedule data as provided in a GFTS feed. This is, as far as we know, the first research paper on this problem in its entirety. Previous research work considers only parts of this problem (oblivious either to the geographical course or to the order of the lines) and does not yield maps that can be used for tiles and overlays in typical map services. • We describe a line-sweeping approach to extract the line graph from a set of (partially overlapping) vehicle trips as they occur in real-world schedule data. • We phrase the crossing minimization problem in a novel way and provide an ILP formulation to solve it. Our new model resolves some issues with previous models, in particular, the restricted applicability of some algorithms to planar graphs, and the necessity of artificial grouping of crossings (which happens naturally with our approach). • As a naive ILP formulation turns out to lead to impractically many constraints, we derive an alternative formulation yielding significantly smaller ILPs in theory and practice. • We describe engineering techniques which allow to further simplify the line graph and hence lead to even smaller ILPs without compromising optimality of the final result. • We evaluate LOOM on the transit network of six cities around the world. For each city, line graph construction, ILP solution and rendering together take less than 1 minute. • Our maps are publicly available online1 . 1.3 Related Work Previous research on the metro-line crossing minimization problem (MLCM), as briefly summarized in the following, typically comes without experimental evaluations and without the production of actual maps. The problem of minimizing intra-edge crossings in transit maps was introduced in [5], with the premises of not hiding crossings under station markers for esthetic reasons. A polynomial time algorithm for the special case of optimizing the layout along a single edge was described. The term MLCM was coined in [4]. In that paper, optimal layouts for path and tree networks were investigated but arbitrary graphs were left as an open problem. In [1, 2, 13], several variants of MLCM were defined and efficient algorithms were presented for some of these variants, often with a restriction to planar graphs. In [3], an ILP formulation for MLCM under the periphery condition (see Sect. 3.3) was introduced. The resulting ILP was shown to have a size of O(|L| 2 |E|) with L being the set of lines and E the set of edges in the derived graph. In [9], it was observed that many (unavoidable) crossings scattered along a 1 http://loom.informatik.uni-freiburg.de single edge are also not visually pleasing, and hence crossings were grouped into so-called block crossings. The problem of minimizing the number of block crossings was shown to be NP-hard on simple graphs just like the original MLCM problem [8]. Our adapted MLNCM problem has the same complexity as MLCM and is hence also NP-hard. Our line graph construction is related to edge bundling. The goal of edge bundling in general networks is to group edges in order to save ink when drawing the network. Usually, the embedding of the edges is not fixed a priori but can be chosen such that many bundles occur (possibly respecting side constraints as edges being short). For example, in [11] a force-directed heuristic was described where edges attract other edges to form bundles automatically. Opposed to this, we are not allowed to embed edges arbitrarily as we want to maintain the geographical course of the vehicle trajectories. In [15], edge bundling in the context of metro line map layout was discussed, also considering orderings within the bundles to minimize crossings. But for their approach to work, the underlying graph has to fulfill a set of restrictive properties. For example, the so called path terminal property demands that a node in the graph cannot be an endpoint of one line and an intermediate node of another line at the same time. But this structure regularly appears in real-world instances. For example, a local train might end at the main station of a town, while a long-distance train might have this station only as an intermediate stop. Also self-intersections are forbidden which excludes instances with cyclic subway lines. With these additional properties required in [15] the problem becomes significantly easier but is no longer applicable to most real-world instances. Another line of research focuses on drawing schematic metro maps, for example, by restricting the representation of transit lines to octilinear polylines [12] or Bézier Curves [7]. See also [14] for a recent survey on automated metro map layout methods. These approaches strongly abstract from the geographical course of the lines (and often also from station positions), and the minimization of line crossings or separations is not part of the problem. In particular, the resulting maps cannot be used for tiles or overlays in typical map services. There is also some applied work on transit maps, but without publications of the details. One approach that seems to use a model similar to ours was described by Anton Dubreau in a blog post [6] although without a detailed discussion of their method. As far as we are aware there are no papers on MLCM concerned with real public transit data. 2 LINE GRAPH CONSTRUCTION This section describes stage 1 of LOOM: given line data, construct the line graph. We assume that the data is given in the GTFS format [10]. In GTFS, each trip (that is, a concrete tour of a vehicle of a line) is given explicitly and the graph induced by this data has many overlapping edges that may (partially) share the same path. Let e 1 , e 2 be two edges in G with their geometrical paths τe1 and τe2 . We define a parametrization τ (t) : [0, 1] 7→ R2 which maps the progress t to a point p ∈ R2 on τ . To decide whether a segment of τe1 is similar to a segment of τe2 , we use a simple approximation. ˆ we say ((t 1 , t 2 ) , (t ′ 1 , t ′ 2 )) is a shared For some distance threshold d, segment of e 1 and e 2 if ∀u ∈ [t 1 , t ′ 1 ] : ∃u ′ ∈ [t 2 , t ′ 2 ] : τe1 (u) − τe2 u ′  ˆ ≤ d. (1) graph G ′ We transform G into a line by repeatedly combining shared segments between two edges e 1 = {u 1 , v 1 } and e 2 = {u 2 , v 2 } into a single new edge e 12 until no more shared segments can be found. The new path τe12 is averaged from the shared segments on τe1 and τe2 . Two new non-station nodes u ′ and v ′ are introduced and split e 1 and e 2 such that e 1 = {u 1 , u ′ }, e 2 = {u 2 , u ′ }, e 1′ = {v ′, v 1 }, e 2′ = {v ′, v 2 } and e 12 = {u ′, v ′ }. Note that the new non-station nodes v ′ and u ′ will always have a degree of 3. To find the shared segments between τ and τ ′ , we sweep over τ in n steps of some ∆t, measuring the distance d between τ (i ·∆t) and ˆ we start a new segment. If τ ′ at each i < n along the way. If d ≤ d, d > dˆ and a segment is open, we close it. The algorithm can be made more robust against outliers by allowing d to exceed dˆ for a number of k steps. It can be sped up by indexing every linear segment of every path in a geometric index (for example, an R-Tree). 3 LINE ORDERING OPTIMIZATION This section describes stage 2 of LOOM, namely how to solve MLNCM: given a line graph, compute an ordering of the lines for each edge such that the total number of crossings in the final map is minimized. Contrary to the classic MLCM problem, which imposes a right and left ordering on each L(e) and allows crossings to occur anywhere on e, MLNCM only imposes a single ordering on each edge and restricts crossing events to nodes. This will proof advantageous during rendering, see Sect. 5. As the set of stations S is only a subset of V in our model (Sect. 1.1), we can still avoid line crossings in them. For each edge e, there are |L(e)|! many orderings, therefore the total number of combinations for the whole graph is immense. We formulate an ILP to find an optimal solution. We first define a baseline ILP which explicitly considers line crossings and has O(|E|M 2 ) variables and O(|E|M 6 ) constraints. We then define an improved ILP with only O(|E|M 2 ) constraints and which also considers line separations (MLNCM-S). 3.1 Baseline ILP For every edge e ∈ E, we define |L (e)| 2 decision variables x elp ∈ {0, 1} where e indicates the edge, l ∈ L(e) indicates the line, and p = 1, ..., |L (e)| indicates the position of the line in the edge. We want to enforce x elp = 1 when line l is assigned to position p, and 0 otherwise. This can be realized with the following constraints: ÕL(e) ∀l ∈ L(e) : x elp = 1. (2) p=1 To ensure that exactly one line is assigned to each position, we need the following additional constraints: Õ ∀p ∈ {1, ..., |L (e)|} : x elp = 1. (3) l ∈L(e) Let A, B be two lines belonging to an edge e = {v, w } and both extend over w. We distinguish two cases: either A and B continue along the same adjacent edge e ′ (Fig. 3, left), or they continue along different edges e ′ and e ′′ (Fig. 3, right). In the first case, A and B induce a crossing if the position of A is smaller than the position of B in L(e), so pe (A) < pe (B), but vice {A, B} e 1 2 1 2 3 1 w 2 {A, B, C} 1 {B, D} e0 {D} e {C, D} 1 2 1 2 3 {A, B, C} e0 w 1 1 2 This ensures that the sequence can only switch from 0 to 1, exactly once. To make sure that at some point a 1 appears and that each position is occupied by exactly one line, we additionally introduce the following constraints: Õ ∀p ∈ {1, ..., |L (e)|} : x el ≤p = p. (6) {A, C} e 00 {D} l ∈L(e) Figure 3: Example instances. Both station polygons have 4 node fronts, each corresponding to an incident edge. Each node front has exactly one port (1, 2, ...) for each line traversing through its edge. versa in L(e ′ ). We introduce the decision variable x ee ′ AB ∈ {0, 1}, which should be 1 in case a crossing is induced and 0 otherwise. To enforce this, we create one constraint per possible crossing. For example, a crossing would occur if we have pe (A) = 1 and pe (B) = 2 as well as pe ′ (A) = 2 and pe ′ (B) = 1. We encode this as follows: x eA1 + x e B2 + x e ′ A2 + x e ′ B1 − x ee ′ AB ≤ 3. (4) In case the crossing occurs, the first four variables are all set to 1. Hence their sum is 4 and the only way to fulfill the ≤ 3 constraint is to set x ee ′ AB to 1. In the example given in Fig. 3, six such constraints are necessary to account for all possible crossings of the lines A and B at node w. The objective function of the ILP then minimizes the sum over all variables x ee ′ AB . In the second case, the actual positions of A and B in e ′ and e ′′ do not matter, but just the order of e ′ and e ′′ . We introduce a split crossing decision variable x ee ′e ′′ AB ∈ {0, 1} and constraints of the form x eAi + x e B j − x ee ′e ′′ AB ≤ 1 for all orders of A and B at e with i < j as in that case a crossing would occur. We add x ee ′e ′′ AB to the objective function. For mapping lines to positions at each edge we need at most |E|M 2 variables and 2|E|M constraints. To minimize crossings, we have to consider at most M 2 pairs of lines per edge, and introduce a decision variable for each such pair. That makes at most |E|M 2 additional variables, which all appear in the objective function. Most constraints are introduced when two lines continue over a node in the same direction. In that case, we create no more than M 2 < M 4 constraints per line pair per edge, so at most |E|M 6 2 in total. In summary, we have O(|E|M 2 ) variables and O(|E|M 6 ) constraints. 3.2 Improved ILP Formulation The variables in the baseline ILP seem to be reasonable, as indeed Ω(|E|M 2 ) crossings could occur. But the O(|E|M 6 ) constraints are due to enumerating all possible position inversions explicitly. If we could check the statement position of A on e is smaller than the position of B efficiently, the number of constraints could be reduced. To have such an oracle, we first modify the lineposition assignment constraints. Instead of a decision variable encoding the exact position of a line, we now use x el ≤p ∈ {0, 1} which is 1 if the position of l in e is ≤ p and 0 otherwise. To enforce a unique position, we use the constraints: x el ≤p ≤ x el ≤p+1 . p=1 p x e B <A + x eA<B = 1. (8) The equality constraints make sure that not both x eA<B and x e B <A can be 1. If the position of A is smaller than the position of B, then more of the variables corresponding to A are 1, and hence the sum for A is higher. So if we subtract the sum for B from the sum for A and the result is ≥ 0, we know the position of A is smaller and x e B <A can be 0. Otherwise, the difference is negative, and we need to set x e B <A to 1 to fulfill the inequality. It is then indeed fulfilled for sure as the position gap can never exceed the number of lines per edge. To decide if there is a crossing, we would again like to have a decision variable x ee ′ AB ∈ {0, 1} which is 1 in case of a crossing and 0 otherwise. The constraint |x eA<B − x e ′ A<B | − x ee ′ AB ≤ 0 (9) realizes this, as either x eA<B = x e ′ A<B (both 0 or both 1) and then x ee ′ AB can be 0, or they are not equal and hence the absolute value of their difference is 1, enforcing x e ′ AB = 1. As absolute value computation cannot be part of an ILP we use the following equivalent standard replacement: x eA<B − x e ′ A<B − x ee ′ AB ≤ 0 −x eA<B + x e ′ A<B − x ee ′ AB ≤ 0. (10) (11) |E|M 2 O(|E|M 2 ) ∀l ∈ L(e) ∀p ∈ {1, ..., |L (e)| − 1} : So for exactly one line l, x el ≤1 = 1, for exactly two lines l ′ and l ′′ , x el ′ ≤2 = x el ′′ ≤2 = 1 (where for one l ∈ {l ′, l ′′ }, x el ≤1 = 1) and so on. We reconsider the example in Fig. 3, left. Before, we enumerated all possible positions which induce a crossing for A, B at the transition from e to e ′ . But it would be sufficient to have variables which tell us whether the position of A is smaller than the position of B in e, and the same for e ′ , and then compare those variables. For a line pair (A, B) on edge e we call the respective variables x e B <A , x eA<B ∈ {0, 1}. To get the desired value assignments, we add the following constraints: Õ |L(e)| Õ x eA ≤p − x e B ≤p + x e B <A M ≥ 0 (7) (5) For the line-position assignment, we need at most variables and constraints just like before. For counting the crossings, we need a constant number of new variables and constraints per pair of lines per edge. Hence the total number of variables and constraints in the improved ILP is O(|E|M 2 ). 3.3 Preventing Line Partner Separation So far, we have only considered the number of crossings. Another relevant criterion for esthetic appeal is that “partnering” lines are drawn side by side. Fig. 4 and Fig. 5 provide two examples. We address this by punishing line separations and call this extension to our original MLNCM problem MLNCM-S. For two adjacent edges e and e ′ and a line pair (A, B) that continues from e to e ′ , if A and B are placed alongside in e but not in e ′ , we want to add a penalty to Figure 4: Minimized crossings in the left example, but the right example better indicates line pairings. Figure 5: Both orderings have 2 crossings, but in the right example they are done in one pass. the objective function. For this, we add a variable x eA ∥B ∈ {0, 1} which should be 0 if |pe (A) − pe (B)| = 1 (if they are partners in e) and 1 otherwise. As x eA ∥B = x e B ∥A , we define a set U (e) of unique line pairs such that (l, l ′ ) ∈ U (e) ⇒ (l ′, l) < U (e). We add the following constraints per line pair (A, B) in U (e): Õ |L(e) | Õ x eA ≤p − x − x eA ∥B M ≤ 1 (12) p=1 p e B ≤p Õ |L(e) | Õ x e B ≤p − x eA≤p − x eA ∥B M ≤ 1. (13) constant global weighting factors w S× and w S ∥ to each x ee ′ll ′ and x ee ′l ∥l ′ in the objective function if l and l ′ continue over a node vs ∈ S. These factors have to be chosen high enough so that a crossing or separation in any other node v < S is never more expensive than in vs . As all w × (v) and w ∥ (v) appear as coefficients in the objective function, they have to be invariant to the actual line orderings. We can thus determine the maximum possible costs ŵ × and ŵ ∥ prior to optimization and choose w S× = ŵ × and w S ∥ = ŵ ∥ . If |pe (A) − pe (B)| = 1, then the sum difference is ≤ 1 and x eA ∥B can be 0. If |pe (A) − pe (B)| > 1, then either (12) or (13) enforce x eA ∥B = 1. To prevent the trivial solution where x eA ∥B is always 1, we add the following constraint per edge e:   Õ |L (e)| ′ x ≤ − |L (e)| − 1, (14) (l,l ′ )∈U (e) el ∥l 2 | as there are |L(e) line pairs (l, l ′ ) ∈ U (e) of which |L (e)| − 1 are 2 next to each other. Like in Sect. 3.2, we add a decision variable x ee ′ A ∥B to the objective function that should be 1 if A and B are separated between e and e ′ and 0 otherwise: 4 p=1 p x eA ∥B − x e ′ A ∥B − x ee ′ A ∥B ≤ 0 (15) −x eA ∥B + x e ′ A ∥B − x ee ′ A ∥B ≤ 0. (16) As we only add 1 constraint per edge and a constant number of constraints and variables per line pair in each edge, the total number of variables and constraints remains O(|E|M 2 ). Interestingly, punishing line separations also addresses a special case of the periphery condition introduced in [3]. In general, this condition holds if lines ending in a station are always drawn at the left- or rightmost position in each incident edge. For nodes with degree ≤ 2, the periphery condition is ensured in MLNCM-S (Fig. 6, left). For other nodes, however, it is not guaranteed (Fig. 6, right). 3.4 Placement of Crossings or Separations The placement of crossings or separations may be fine-tuned by adding node-based weighting factors w × (v) (for crossings) and w ∥ (v) (for separations) to the objective function to prefer nodes or to break ties. For example, w × (v) may depend on the node degree. As described above, we especially want to prevent crossings or separations in station nodes. This can be achieved by adding CORE GRAPH REDUCTION It is possible to further simplify the optimization problem. We make the following observations: Lemma 4.1. If for some set B = {A, B, C, ...} ⊆ L it holds for all l ∈ B, e ∈ E : l ∈ L(e) ⇒ B ⊆ L(e), then the optimal ordering is to always bundle A, B, C, ... next to each other with a fixed, global ordering. Proof. Let L ∈ B be the line that induces the minimal number of crossings and separations for some solution σ . Since all l ∈ B take the exact same path through the network, a solution can only be better than or equal to σ if it bundles all l , L alongside L. □ Lemma 4.2. Given an optimal ordering for each L(e). We say a node v belongs to W if deg(v) = 2 and for its adjacent edges e and e ′ the set of lines L(e) is equal to L(e ′ ). A crossing or a separation in some v ∈ W can always be moved from v to a node v ′ < W without negatively affecting optimality. Proof. We set L∗ = L(e) = L(e ′ ) and first consider crossings. There are two possible cases: (1) all l ∈ L∗ always occur together in each edge. Then Lemma 4.1 holds, and the ordering of L(e) is the same as of L(e ′ ), inhibiting any crossings in v. We can thus ignore this case. (2) Lemma 4.1 does not hold and the lines in L∗ separate in some node v ′ , v. Then they either diverge into separate edges at v ′ , or a subset of them ends in v ′ . If they diverge, the degree of v ′ has to be at least 3, implicating v ′ < W . If some (or one) of them end in v ′ , then v ′ has to be adjacent to at least 2 edges e, e ′ with L(e) , L(e ′ ), again implicating v ′ < W . Such a v ′ will thus indeed always exist. Under a uniform crossing penalty, we can trivially move the crossing from v to v ′ without affecting optimality. Under the penalty described in Sect. 3.4, optimality will also not be affected negatively, because deg(v) is always 2, implying that v is a station (Sect. 2). The same argument holds for line separations. □ Lemma 4.3. If for some edge e all l ∈ L(e) end in a node v or |L(e)| = 1, the ordering of L(e) will not affect the number of orderings or separations in v. Figure 6: Left: Periphery condition guaranteed by separation penalty. Right: Periphery condition not guaranteed by separation penalty. Proof. In the first case, no l ∈ L(e) extends over v, so they cannot introduce any crossing or separation. In the second case, all orderings of L(e) are equivalent (there is only one). □ {E, F } 5 {A, B, C } 1 6 {D } {E, F } 5 {C } {A, B } 4 3 9 {E } 7 {G } {D } {E, F } {A, B } {E } {F } 1 2 8 {D, E, F } 5 {D, E, F } {D, E, F } {F } {E, F } {X, C } {C } 8 1 {D } {C } {X, C } {F } {X } {A, B, C } 9 3 4 9 3 {E } {X } {E } {X } Figure 7: Left: line graph G with 7 lines. Middle: core graph of G after applying pruning rules, {A, B} was collapsed into {X }. Right: ordering-relevant connected components of G after applying splitting rules. Using the above, we can simplify the input graph with the following pruning rules (Fig. 7, middle): (1) delete each node v with degree 2 and L(e) = L(e ′ ), and combine the adjacent edges e = {u, v}, e ′ = {v, w } into a single new edge ee ′ = {u, w } with L(ee ′ ) = L(e) = L(e ′ ) (Lemma 4.2). (2) collapse lines that always occur together into a single new line k (Lemma 4.1). Weight crossings with k by the number of lines it combines to avoid distorting penalties. (3) remove each edge e = {u, v} where u and v are termini for all l ∈ L(e) (Lemma 4.3). This core graph of G may be further broken down into orderingrelevant connected components using the rules below (Fig. 7, right). The components can then be optimized separately. (1) cut each edge e = {u, v} with |L (e)| = 1 into two edges e ′ = {u, v ′ } and e ′′ = {v ′′, v} (Lemma 4.3). (2) replace each edge e = {u, v} where v has a degree > 1 and is a terminus node for each l ∈ L(e) with an edge e ′ = {u, v ′ } where v ′ is only connected to e ′ (Lemma 4.3). 5 RENDERING This section describes stage 3 of LOOM: given the line graph as computed in stage 1, and a line ordering for each edge as computed in stage 2, render the actual map. We split this into four basic steps, as illustrated in Fig. 8. In the first step (1), we make use of the fact that only a single ordering is imposed on each L(e) and render each l ∈ L(e) by perpendicular offsetting the edge’s geometry τe by −w |L(e)| /2 + w (pe (l) − 1), where w is the desired line width. In the next step (2), we make room for the line connections between edges by expanding the node fronts (and thus the node polygon). As a stopping criteria for this expansion, we simply use a maximum distance from the node front to its original position. The line connections in the node are then rendered by connecting all port pairs (3). In our experiments, we used cubic Bézier curves, but for schematic maps a circular arc or even a straight line might be preferable. For the station rendering (4), we found that the buffered node polygon already yields reasonable results, although with much potential for improvement. We also experimented with rotating rectangles until the total sum of the deviations between each node front orientation and the orientation of the rectangle was minimized. Both approaches can be seen in Fig. 2. Table 1: Graph dimensions for our datasets Freiburg (FR), Dallas (DA), Chicago (CG), Stuttgart (ST), Turin (TO) and New York (NY) with extraction times from GTFS. S are the stations, V the graph nodes, E the graph edges and L the transit lines. M is the maximum number of lines per edge. Line graph FR DA CG ST TO NY 6 Core graph t extr |S| |V | |E| |L| M |V | |E| |L| M 0.7 s 3s 13.5 s 7.7 s 4.9 s 3.7 s 74 108 143 192 339 456 80 117 153 223 398 517 81 118 154 235 435 548 5 7 8 15 14 26 4 4 6 8 5 9 20 24 23 51 91 110 21 24 24 60 124 138 5 7 8 15 14 23 4 4 6 8 5 9 EVALUATION We tested LOOM on the public transit schedules of six cities: Freiburg, Dallas, Chicago, Stuttgart, Turin and New York2 . Table 1 provides the basic dimensions of each dataset and the time needed to extract the line graph. For each dataset, we considered two versions of the line graph: the baseline graph and the core graph. For each graph, we considered three ILP variants: the baseline ILP (B), the improved ILP (I) and the improved ILP with added separation penalty (S). For each ILP, we evaluated two solvers: the GNU Linear Programming Kit (GLPK) and the COIN-OR CBC solver. As most of the datasets (except Turin) still only had one connected component after applying the splitting rules described in Sect. 4, we did not evaluate their application. Tests were run on an Intel Core i5-6300U machine with 4 cores à 2.4 GHz and 12 GB RAM. The CBC solver was compiled with multithreading support, and used with the default parameters and threads=4. The GLPK solver was used with the feasibility pump heuristic (fp_heur=ON), the proximity search heuristic (ps_heur=ON) and the presolver enabled (presolve=ON). For each node v, the penalty for a crossing between edge pairs ({A, B} in Figure 3, left) was 4 · deg(v), for other crossings ({A, B} in Figure 3, right) it was deg(v). The line separation penalty was 3 · deg(v). We found that these penalties produced nicer maps than a uniform penalty. This would imply w S× = 4 · maxv ∈V deg(v) and w S ∥ = 3 · maxv ∈V deg(v). However, we found that moving some crossings or separations to stations with a degree greater than 2 2 with uncollapsed express lines (1) (2) (3) (4) Figure 8: The four steps of rendering a given line graph: (1) render ordered lines as edges, (2) free node area, (3) render inner connections, (4) render station overlays. Table 2: Dimensions and solution times for Chicago (CG), Stuttgart (ST), Turin (TO) and New York (NY) and our three ILPs: baseline (B), improved (I), and with line separation penalty (S), with or without reduction to the core graph. A time of — means we aborted after 12 hours. The last two columns show the number of crossings (×) and separations (||) after optimization. On baseline graph On core graph × || CG B 41k × 861 I 1.7k × 1.2k S 2.2k × 1.4k — — 18 s 0.4 s 47 m 25 s 8.2k × 266 — 47 m 22 484 × 352 0.4 s 0.2 s 22 595 × 405 26 s 3.8 s 27 4-7 4-7 0 ST B 224k × 2.5k I 5.1k × 3.4k S 6.6k × 4.1k — — — 44k × 999 1.9k × 1.4k 2.5k × 1.6k rows × cols GLPK TO B I S 24k × 2.1k 4k × 2.8k 5k × 3.3k NY B 229k × 5.2k I 11k × 7.1k S 14k × 8.5k CBC — 7.1 s 4.5 m rows × cols GLPK CBC — — 10 s 1.4 s — 36 s — — 65 8-15 69 3 — — 32 m 0.6 s — 9.1 s 13k × 1k — — 1.9k × 1.4k 7.1 s 0.3 s 2.4k × 1.6k — 4.6 s — — 78 6-10 81 2 — — — 96k × 2.3k 4.5k × 3.1k 5.7k × 3.7k — 2.2 s 2.4 m — — — — — — 0.7 s 127 6-14 55 s 132 2 yielded results that looked better. Hence, crossings in v ∈ S were punished with w S× if deg(v) = 2 and otherwise with 3 · deg(v) (normal crossing) or 12 · deg(v) (edge-pair crossing). Similarly, instation line separations where punished with w S ∥ if deg(v) = 2 and 3 · deg(v) otherwise. Note that Lemma 4.2 still holds because we did not change the punishment for degree 2 stations. Also note that separations were only considered in (S) and thus depended on the solver and the input order in (B) and (I ). Table 2 shows the results of the ordering optimizations for 4 of our 6 datasets. With (I), the optimal order could be found in under 1.5 seconds for each of those datasets, and in under 1 minute with (S). For medium-sized networks an optimal solution for (S) was usually found in under 5 seconds. Although the ILPs for (S) were only slightly larger than for (I), optimization on the core graph took 35 times longer on average (with CBC). (B) could not be optimized in under 12 hours for all datasets except Chicago. In general, CBC outperformed GLPK for larger datasets, sometimes dramatically. As expected, core graph reduction made the ILPs significantly smaller. On average, the number of rows decreased by 61 % and the number of columns by 59 % for (I). For (S), the decrease was 62 % and 60 %, respectively. 7 CONCLUSIONS AND FUTURE WORK We have evaluated LOOM and shown that it produces geographically accurate transit maps. The whole pipeline took less than 1 minute for all considered inputs (including the rendering step). As the line graph construction required more time than the subsequent ILP solution for some datasets, faster algorithms for extracting the line graph would be of interest. The ideas behind LOOM may be useful also in a non-transit scenario. For example, one closely related problem is that of wire routing in integrated-circuit design. There, stations correspond to chips and other elements (which in wire routing are indeed of polygonal form), lines correspond to wires, and the geographical course of the lines may correspond to a pre-existing wiring. REFERENCES [1] Evmorfia Argyriou, Michael A Bekos, Michael Kaufmann, and Antonios Symvonis. 2008. Two polynomial time algorithms for the metro-line crossing minimization problem. In International Symposium on Graph Drawing. Springer, 336–347. [2] Evmorfia N Argyriou, Michael A Bekos, Michael Kaufmann, and Antonios Symvonis. 2010. On Metro-Line Crossing Minimization. J. Graph Algorithms Appl. 14, 1 (2010), 75–96. [3] Matthew Asquith, Joachim Gudmundsson, and Damian Merrick. 2008. An ILP for the metro-line crossing problem. In Proceedings of the fourteenth symposium on Computing: the Australasian theory-Volume 77. Australian Computer Society, Inc., 49–56. [4] Michael A Bekos, Michael Kaufmann, Katerina Potika, and Antonios Symvonis. 2007. Line crossing minimization on metro maps. In International Symposium on Graph Drawing. Springer, 231–242. [5] Marc Benkert, Martin Nöllenburg, Takeaki Uno, and Alexander Wolff. 2006. Minimizing intra-edge crossings in wiring diagrams and public transportation maps. In International Symposium on Graph Drawing. Springer, 270–281. [6] Anton Dubreau. 2016. Transit Maps: Apple vs. Google vs. Us. https://medium. com/transit-app/transit-maps-apple-vs-google-vs-us-cb3d7cd2c362. (2016). [7] Martin Fink, Herman Haverkort, Martin Nöllenburg, Maxwell Roberts, Julian Schuhmann, and Alexander Wolff. 2012. Drawing metro maps using Bézier curves. In International Symposium on Graph Drawing. Springer, 463–474. [8] Martin Fink and Sergey Pupyrev. 2013. Metro-Line Crossing Minimization: Hardness, Approximations, and Tractable Cases.. In Graph Drawing, Vol. 8242. 328–339. [9] Martin Fink and Sergey Pupyrev. 2013. Ordering metro lines by block crossings. In International Symposium on Mathematical Foundations of Computer Science. Springer, 397–408. [10] GTFS. [n. d.]. General Transit Feed Specification. ([n. d.]). https://developers. google.com/transit/gtfs. [11] Danny Holten and Jarke J Van Wijk. 2009. Force-Directed Edge Bundling for Graph Visualization. In Computer graphics forum, Vol. 28. Wiley Online Library, 983–990. [12] Seok-Hee Hong, Damian Merrick, and Hugo AD do Nascimento. 2006. Automatic visualisation of metro maps. Journal of Visual Languages & Computing 17, 3 (2006), 203–224. [13] Martin Nöllenburg. 2009. An improved algorithm for the metro-line crossing minimization problem. In International Symposium on Graph Drawing. Springer, 381–392. [14] Martin Nöllenburg. 2014. A survey on automated metro map layout methods. Tech. Rep. (2014). [15] Sergey Pupyrev, Lev Nachmanson, Sergey Bereg, and Alexander E Holroyd. 2011. Edge routing with ordered bundles.. In Graph Drawing, Vol. 7034. Springer, 136–147.
8cs.DS
arXiv:1601.06037v4 [cs.IT] 31 Jan 2018 Finite Field Matrix Channels for Network Coding Simon R. Blackburn and Jessica Claridge Department of Mathematics Royal Holloway University of London Egham, Surrey TW20 0EX, United Kingdom Abstract In 2010, Silva, Kschischang and Kötter studied certain classes of finite field matrix channels in order to model random linear network coding where exactly t random errors are introduced. In this paper we consider a generalisation of these matrix channels where the number of errors is not required to be constant, indeed the number of errors may follow any distribution. We show that a capacity-achieving input distribution can always be taken to have a very restricted form (the distribution should be uniform given the rank of the input matrix). This result complements, and is inspired by, a paper of Nobrega, Silva and Uchoa-Filho, that establishes a similar result for a class of matrix channels that model network coding with link erasures. Our result shows that the capacity of our channels can be expressed as a maximisation over probability distributions on the set of possible ranks of input matrices: a set of linear rather than exponential size. 1 Introduction Network coding, first defined in [1], allows intermediate nodes of a network to compute with and modify data, as opposed to the traditional view of nodes as ‘on/off’ switches. This can increase the rate of information flow through a network. It is shown in [13] that linear network coding is sufficient to maximise information flow in multicast problems, that is when there is one source node and information is to be transmitted to a set of sink nodes. Moreover, in [10] it is shown that for general multisource multicast problems, random linear network coding achieves capacity with probability exponentially approaching 1 with the code length. In random linear network coding, the source injects packets into the network; these packets can be thought of as vectors of length m with entries in a finite field Fq (where q is a fixed power of a prime). The packets flow through a network of unknown topology to a sink node. Each intermediate node forwards packets that are random linear combinations of the packets it has received. A sink node attempts to reconstruct the message from these packets. In this context, Silva, Kschischang and Kötter [18] studied a channel defined as follows. We write Fn×m to denote the set of q all n × m matrices over Fq , and write GL(n, q) for the set of all invertible matrices . in Fn×n q Definition 1.1. The Multiplicative Matrix Channel (MMC) has input set X and output set Y, where X = Y = Fn×m . The channel law is q Y = AX where A ∈ GL(n, q) is chosen uniformly at random. 1 Here the rows of X correspond to the packets transmitted by the source, the rows of Y are the packets received by the sink, and the matrix A corresponds to the linear combinations of packets computed by the intermediate nodes. Inspired by Montanari and Urbanke [14], Silva et al modelled the introduction of random errors into the network by considering the following generalisation of the MMC. We write Fn×m,r for the set of all n × m matrices of rank r. q Definition 1.2. The Additive Multiplicative Matrix Channel with t errors (AMMC) has input set X and output set Y, where X = Y = Fn×m . The channel law is q Y = A(X + B) where A ∈ GL(n, q) and B ∈ Fn×m,t are chosen uniformly and independently at q random. So the matrix B corresponds to the assumption that exactly t linearly independent random errors have been introduced. The MMC is exactly the AMMC with zero errors. We note that the AMMC is very different from the error model studied in the well-known paper by Kötter and Kschischang [12], where the errors are assumed to be adversarial (so the worst case is studied). In [18] the authors give upper and lower bounds on the capacity of the AMMC, which are shown to converge in certain interesting limiting cases. The exact capacity of the AMMC for fixed parameter choices is hard to determine due to the many degrees of freedom involved: the naive formula maximises over a probability distribution on the set of possible input matrices, and this set is exponentially large. In this paper we consider a generalisation of these matrix channels that allows the modelling of channels were the number of errors is not necessarily fixed. (For example, it enables the modelling of situations when at most t errors are introduced, or when the errors are not necessarily linearly independent, or both.) To define our generalisation, we need the following notation which is due to Nobrega, Silva and Uchoa-Filho [15]. Definition 1.3. Let R be a probability distribution on the set {0, 1, . . . , min{m, n}} . We define a distribution on the set Fn×m of possible ranks of matrices M ∈ Fn×m q q of matrices by choosing r according to R, and then once r is fixed choosing a matrix M ∈ Fn×m,r uniformly at random. We say that this distribution is Uniform Given q Rank (UGR) with rank distribution R. We say a distribution on Fn×m is Uniform q Given Rank (UGR) if it is UGR with rank distribution R for some distribution R. We write R(r) for the probability of rank r under the distribution R. So a distribution on Fn×m is UGR with rank distribution R if and only if each M ∈ Fn×m q q of rank r is chosen with probability R(r)/|Fn×m,r |. q Definition 1.4. Let R be a probability distribution on the set {0, 1, . . . , min{m, n}} of possible ranks of matrices M ∈ Fn×m . The Generalised Additive Multiplicative q MAtrix Channel with rank error distribution R (the Gamma channel Γ(R)) has input set X and output set Y, where X = Y = Fn×m . The channel law is q Y = A(X + B) where A ∈ GL(n, q) is chosen uniformly, where B ∈ Fn×m is UGR with rank distriq bution R, and where A and B are chosen independently. We see that the AMMC is the special case of Γ(R) when R is the distribution choosing rank t with probability 1. In [18, §VI-D] the authors consider a generalisation of the AMMC which is exactly the Gamma channel in the case when the error rank is bounded by t, that is they consider Γ(R) when R is any distribution with R(r) = 0 for all r > t. For t = n this channel is identical to the Gamma channel. However, the authors consider t as a maximum value for the error rank (thus will be 2 taken to be less than n), whereas we consider any full rank distribution, with high rank having low probability. Our model covers several very natural situations (some of which are also covered by the generalised AMMC with t < n). For example, we may drop the assumption that the t errors are linearly independent by defining R(r) to be the probability that t vectors span a subspace of dimension r, when the vectors are chosen uniformly and independently. We can also extend this to model situations when the number t of vectors varies according to natural distributions such as the binomial distribution (which arises when, for example, a packet is corrupted with some fixed non-zero probability). In practice, given a particular network, one may run tests on the network to see the actual error patterns produced and define an empirical distribution on ranks. One could also define an appropriate distribution by considering some combination of the situations described. We are interested in the capacity of the Gamma channel. In the generalised AMMC [18, §VI.D] the authors establish a lower bound on the capacity that is at most logq (t + 1) lower than the capacity of the AMMC with the same value of t. Therefore in the limiting cases considered their generalised channel performs at least as well as the AMMC. This is a very useful result when t is significantly smaller than n. However, if we take t = n then the expressions [18, Eq. 19 & 20] for the capacity in the limiting cases considered evaluate to zero. Throughout this paper, we assume that q, n, m and R are fixed by the application. We will refer to these values as the channel parameters. We note that the Gamma channel assumes that the transfer matrix A is always invertible. This is a realistic assumption in random linear network coding in standard situations: the field size q is normally large, which means linear dependencies between random vectors are less likely. In both [15] and [16] the authors consider (different) generalisations of the MMC channel that do not necessarily have a square full rank transfer matrix. Such channels allow modelling of network coding when no erroneous packets are injected into the network, but there may be link erasures. In [15], Nobrega, Silva and Uchoa-Filho define the transfer matrix to be picked from a UGR distribution. One result of [15] is that a capacity-achieving input distribution for their class of MMC channels can always be taken to be UGR. A main result of this paper (Theorem 5.5) is that a capacity-achieving input distribution for Gamma channels can always be taken to be UGR. Theorem 5.5 is a significant extension of the result of [15] to a new class of channels; the extension requires new technical ideas. This result is in contrast to the coding schemes proposed in [18], which restrict input matrices to have a specific form, and achieves capacity in the limiting cases considered. Their restrictions on the input allows for straightforward decoding, whereas it is not immediately obvious of how to construct an efficient UGR coding scheme which achieves capacity for any given parameters, indeed this is a problem of interest for future research. Corollary 6.2 to the main result of the paper provides an explicit method for computing the capacity of Gamma channels which maximises over a probability distribution over the set of possible ranks of input matrices, rather than the set of all input matrices itself. Thus we have reduced the problem of computing the capacity of a Gamma channel to an explicit maximisation over a set of variables of linear rather than exponential size. As examples of the results of this approach, the table below gives the computed capacity C of the AMMC channel with 2 errors for n × 2n matrices over F2 ; the capacity C 0 of the Gamma channel for n × 2n matrices over F2 when the number of errors is binomially distributed with expected number of errors equal to 2; and the capacity C 00 when the number of errors is 0, 1 or 2 with 3 Capacity 80 60 40 20 4 6 8 10 n Figure 1: Capacity (in bits) of the AMMC channel with 2 errors for n × 2n matrices over F2 . The three curves are: the upper bound from [18, Theorem 6]; the capacity computed using methods in this paper; the lower bound from [18, Theorem 7]. Capacity 80 60 40 20 4 6 8 10 n -20 Figure 2: Capacity C 00 (in bits) of the matrix channel with 0, 1 and 2 errors for n × 2n matrices over F2 specified in the text, together with the lower bound on the capacity from [18, § VI.D]. probabilities 1/7, 2/7 and 4/7 respectively. n C C0 C 00 3 1.731 1.117 2.765 4 5.586 4.633 7.354 5 11.644 10.422 14.090 6 18.807 18.368 23.003 7 30.050 28.395 34.032 8 42.381 40.491 47.094 9 56.798 54.676 62.177 10 73.290 70.996 79.274 Figure 1 plots the capacity C of the AMMC channel together with general upper and lower bounds on the capacity. (These bounds are due to Silva et al. [18, Theorem 6 and 7]. We comment that an improved upper bound due to Claridge [5, Equation 6.6.2] is very similar to [18, Theorem 6] for these parameters.) Similarly, Figure 2 plots the capacity C 00 of the third example channel together with the lower bound on the capacity due to Silva et al. [18, § VI.D]. The remainder of the paper is organised as follows. Section 2 proves some preliminary results needed in what follows. In Section 3 we state results from matrix theory that we use. Section 4 establishes a relationship between the distributions of the ranks of input and output matrices for a Gamma channel. Section 5 proves Theorem 5.5, and Section 6 proves Corollary 6.2, giving an exact expression for the capacity of the Gamma channels. In Section 7 we prove the results from matrix theory 4 that we use in earlier sections. Finally, Section 8 contains some concluding remarks. 2 Preliminaries on finite-dimensional vector spaces In this section we discuss finite-dimensional vector spaces and consider several counting problems involving subspaces and quotientspaces.  The Gaussian binomial coefficient, denoted m d q , is defined to be the number of ddimensional subspaces of an m-dimensional space over Fq . It is given by (e.g. [4, §9.2])  d−1     Y (q m − q i ) m , for d ≤ m = (1) (q d − q i ) i=0 d q   0, for d > m. Let V1 be a subspace of V . The following lemma gives the number of subspaces U of V where the intersection of U and V1 , and the image of U in the quotient space V /V1 , are both fixed. Lemma 2.1. Let V be a dV -dimensional vector space. Let V1 , V2 be subspaces of V , of dimensions dV1 and dV2 respectively, such that V2 ⊆ V1 . The number of dU dimensional subspaces U ⊆ V such that U ∩ V1 = V2 and the image of U in the quotient space V /V1 is the fixed dU − dV2 dimensional space U 0 , is given by q (dU −dV2 )(dV1 −dV2 ) . Proof. Fix a basis for V2 , say {b1,1 , . . . , b1,dV2 }. Let π : V → V /V1 be the map which takes vectors in V to their image in V /V1 . For dU 0 = dU − dV2 , let {y1 , . . . ydU 0 } be a basis for U 0 , and let {b2,1 , . . . , b2,dU 0 } be some vectors in V such that π(b2,i ) = yi , for i = 1, . . . , dU 0 . It is easy to check that every subspace U of the form we are counting has a basis B = {b1,1 , . . . , b1,dV2 , v1 + b2,1 , . . . , vdU 0 + b2,dU 0 } where v1 , . . . , vdU 0 ∈ ker π = V1 . Moreover, all bases of this form span a subspace U of the form we are counting, and a basis B 0 = {b1,1 , . . . , b1,dV2 , v10 + b2,1 , . . . , vd0 U 0 + b2,dU 0 } spans the same subspace as B if and only if [vi ] = [vi0 ] for i = 1, . . . , dU 0 , where [v] denotes the image of a vector v in the quotient space V1 /V2 . Therefore there is a bijection between spaces U of the required form and ordered sets {[v1 ], . . . , [vdU 0 ]} of elements in the quotient space V1 /V2 . For i = 1, . . . dU 0 , there are q dV1 −dV2 choices for [vi ] ∈ V1 /V2 , thus there are q dU 0 (dV1 −dV2 ) = q (dU −dV2 )(dV1 −dV2 ) . (2) choices for the ordered set {[v1 ], . . . , [vdU 0 ]}. The result follows. Given a vector space V and a subspace V1 ⊆ V , Lemma 2.1 can be used to count subspaces U of V when either U ∩ V1 is fixed, or the image of U in V /V1 is fixed, or when only the dimensions of these spaces are fixed. These results are given in the following three corollaries. Corollary 2.2. Let V be a dV -dimensional vector space. Let V1 , V2 be subspaces of V , of dimensions dV1 and dV2 respectively, such that V2 ⊆ V1 . The number of dU -dimensional subspaces U ⊆ V such that U ∩ V1 = V2 , is given by   dV − dV1 q (dU −dV2 )(dV1 −dV2 ) . dU − dV2 q 5 Proof. The quotient space V /V1 is a space of dimension dV − dV1 . Let U 0 be a (dU − dV2 )-dimensional subspace of V /V1 . There are   dV − dV1 dU − dV2 q possible choices for U 0 . For each such space U 0 , there are q (dU −dV2 )(dV1 −dV2 ) possibilities for a space U with whose image in the quotient V /V1 is U 0 , by Lemma 2.1. Corollary 2.3. Let V be a dV -dimensional vector space. Let V1 be a dV1 -dimensional subspace of V . The number of dU -dimensional subspaces U ⊆ V such that the image of U in the quotient space V /V1 is some fixed dU 0 dimensional space U 0 , is given by   dV1 q dU 0 (dV1 −(dU −dU 0 )) . (3) dU − dU 0 q Proof. There are  dV1 dU − dU 0  q possible choices for a (dU − dU 0 )-dimensional subspace V2 of V1 . For each choice of V1 , there are q (dU −(dU −dU 0 ))(dV1 −(dU −dU 0 )) = q dU 0 (dV1 −(dU −dU 0 )) possibilities for the space U whose intersection with V1 is the fixed space V2 , by Lemma 2.1. Corollary 2.4. Let V be a dV -dimensional vector space. Let V1 be a dV1 -dimensional subspace of V . For a subspace U of V , let [U ] denote the image of U in the quotient space V /V1 . The number of dU -dimensional subspaces U ⊆ V such that dim(U ∩V1 ) = dU V1 is equal to the number of dU -dimensional subspaces U such that dim([U ]) = dU − dU V1 . This number is equal to    dV1 (dU −dU V1 )(dV1 −dU V1 ) dV − dV1 q . dU − dU V1 q dU V1 q Proof. Note that dim(U ∩ V1 ) = dU V1 if and only if dim([U ]) = dU − dU V1 hence the first statement of the lemma holds. Let V2 be a (dU V1 )-dimensional subspace of V1 . There are   dV1 dU V 1 q possible choices for V2 , and  dV − dV1 dU − dU V1  q possible choices for a (dU − dU V1 )-dimensional subspace U 0 of V /V1 . For each choice of V2 and U 0 , Lemma 2.1 implies there are q (dU −dU V1 )(dV1 −dU V1 ) possibilities for the space U whose intersection with V1 is the fixed space V2 , and image in the quotient V /V1 is the fixed space U 0 . 3 Matrices over finite fields This short section describes the notation and results we use from the theory of matrices over finite fields. Let q be a non-trivial prime power, that is q = pn for some prime p and integer n ≥ 1. Let Fq be the finite field of order q. In the introduction we defined Fn×m to q be the set of n × m matrices with entries in Fq , we defined Fn×m,r to be the matrices q in Fn×m of rank r, and we defined GL(n, q) to be the set of invertible matrices in q Fn×n . q For a matrix M , we write rk(M ) for the rank of M and we write Row(M ) for the row space of M . 6 Lemma 3.1. Let U be a subspace of Fm q of dimension u. The number f0 (u) of matrices M ∈ Fn×m such that Row(M ) = U can be efficiently computed; it depends q only on q, n, m and u. For 0 ≤ u ≤ min{n, m}, f0 (u) = = u−1 Y qn − qi i=0 u X (−1)u−v q nv+( v=0 (4) u−v 2   ) u . v q (5) By an efficient computation, we mean a polynomial (in max{n, m}) number of arithmetic operations. Gabidulin [7, Theorem 4] establishes (4), and (5) follows from [7, Equation 13]. Therefore Lemma 3.1 immediately follows. The following results will be proved in Section 7. Lemma 3.2. Let U and V be subspaces of Fm q of dimensions u and v respectively. be a fixed matrix such that Row(M ) = U . Let h = dim(U ∩ V ). Let M ∈ Fn×m q such that Let r be a non-negative integer. The number of matrices B ∈ Fn×m,r q Row(B + M ) = V can be efficiently computed; it depends only on q, n, m, r, u, v and h. We write f1 (u, v, h; r) for the number of matrices B of this form. Lemma 3.3. Let r, rB and rX be non-negative integers. Let X be a fixed matrix such B that rk(X) = rX . The number of matrices B ∈ Fn×m,r such that rk(X + B) = r q can be efficiently computed; it depends only on q, n, m, r, rB and rX . We write f2 (r, rX , rB ) for the number of matrices B of this form. In Section 7, Theorems 7.3 and 7.4 we give exact expressions for the functions f1 and f2 respectively in terms of their inputs and the values q, n and m, from which Lemmas 3.2 and 3.3 follow immediately. We comment that the function f2 has connections with rank metric codes (see e.g. [8], [17] for example). For a fixed matrix X of rank rX , the function f2 (rX , rB , r) gives the number of matrices B of rank rB such that rk(X + B) = r. This is equal to the number of matrices B 0 of rank rB such that rk(X − B 0 ) = r (setting B 0 = −B). to be The rank distance is a metric defined for two matrices M1 , M2 ∈ Fn×m q dR (M1 , M2 ) = rk(M1 − M2 ). Therefore, the value f2 (rX , rB , r) gives the number of matrices of rank rB , that have rank distance r from some fixed matrix of rank rX . Or equivalently, considering the space of all n × m matrices over Fq , f2 (rX , rB , r) is the volume of intersection of two spheres with rank radii rX and rW with centres at rank distance r. The analysis of the volume of intersection of spheres in the rank metric space can lead to the development of covering properties for rank metric codes, as explored by Gadouleau and Yan [9]. In [9, Lemma 1], the authors give an expression for the function f2 , showing that indeed it is efficiently computable. The expression they give was developed using the theory of association schemes. In Section 7 we give an expression for f2 that avoids this theory, using direct counting arguments. Thus our new formula and proof give extra insight. 4 Input and output rank distributions A distribution PX on the input set X of the Gamma channel induces a distribution (the input rank distribution) RX on the set of possible ranks of input matrices. Let RY be the corresponding output rank distribution, induced from the distribution on the output set of the Gamma channel. A key result (Lemma 4.2) is that RY depends on only the channel parameters and RX (rather than on PX itself). This section aims to prove this result: it will play a vital role in the proof of Theorem 5.5 below. 7 Definition 4.1. Let r, rX , rB ∈ {0, . . . , min{n, m}}. Define f2 (r, rX , rB ) , B |Fn×m,r | q ρ(r; rX , rB ) = X where f2 is as defined in Lemma 3.3. For any fixed matrix X ∈ Fn×m,r , we see that q B ρ(r; rX , rB ) gives the proportion of matrices B ∈ Fn×m,r with rk(X + B) = r. Let q R be a probability distribution on the set {0, 1, . . . , min{n, m}} of possible ranks of n × m matrices. Define min{n,m} ρ(r; rX ) = X R(rB )ρ(r; rX , rB ), rB =0 so that ρ(r; rX ) gives the weighted average of this proportion over the possible ranks of matrices B. Lemma 4.1. Let X be an n×m matrix sampled from some distribution PX on Fn×m . q Let B be an n × m matrix sampled from a UGR distribution with rank distribution R, where X and B are chosen independently. Let r, rX , rB ∈ {0, . . . , min{n, m}}. Then ρ(r; rX , rB ) = Pr(rk(X + B) = r| rk(X) = rX and rk(B) = rB ), (6) ρ(r; rX ) = Pr(rk(X + B) = r| rk(X) = rX ). (7) and Proof. Let X be a fixed n × m matrix of rank rX . Then, since B has a UGR distribution, Pr(rk(X + B) = r| rk(B) = rB ) = B |{B ∈ Fn×m,r : rk(X + B) = r}| q B |Fn×m,r | q f2 (r, rX , rB ) = B |Fn×m,r | q = ρ(r; rX , rB ). Note that (8) only depends on rk(X), not X itself. Hence Pr(rk(X + B) = r| rk(X) = rX , rk(B) = rB ) X = Pr(X = X) Pr(rk(X + B) = r| rk(B) = rB ) X = X Pr(X = X)ρ(r; rX , rB ) X = ρ(r; rX , rB ), X where the sums are over matrices X ∈ Fn×m,r . Thus (6) holds. Also q Pr(rk(X + B) = r| rk(X) = rX ) min{n,m} = X R(rB )ρ(r; rX , rB ) (by (6)) rB =0 = ρ(r; rX ). Thus (7) holds, and so the lemma follows. 8 (8) Lemma 4.2. For the Gamma channel Γ(R) with input rank distribution RX , the output rank distribution is given by min{n,m} RY (r) = X RX (rX )R(rB ) rX ,rB =0 f2 (r, rX , rB ) B |Fn×m,r | q for r = 1, . . . , min{n, m}. In particular, RY depends only on the input rank distribution (and the channel parameters), not on the input distribution itself. Proof. We have that Pr(rk(X) = rX ) = RX (rX ) and Pr(rk(B) = rB ) = R(rB ). Hence, by (6), RY (r) = Pr(rk(Y ) = r) min{n,m} = X RX (rX )R(rB )ρ (rY ; rX , rB ) rX ,rB =0 min{n,m} = X RX (rX )R(rB ) rX ,rB =0 5 f2 (r, rX , rB ) . |Fqn×m,rB | A UGR input distribution achieves capacity This section shows (Theorem 5.5) that there exists a UGR input distribution to the Gamma channel that achieves capacity. Lemma 5.1. Let M and M 0 be fixed n × m matrices of the same rank. Let B be an n × m matrix picked from a UGR distribution, and let A be an n × n matrix picked uniformly from GL(n, q), with B and A picked independently. Let Y = A(M + B) and let Y 0 = A(M 0 + B). Then H(Y ) = H(Y 0 ). Proof. Let A be a fixed n×n invertible matrix. Since the matrices AM and AM 0 have the same rank, there exist invertible matrices R and C such that AM 0 = RAM C. defined by ϕ(Y ) = RY C. It → Fn×m Consider the linear transformation ϕ : Fn×m q q is simple to check that ϕ is well defined and a bijection. Note that ϕ(A(M + B)) = RAM C + RABC = A(M 0 + A−1 RABC). Since B is picked uniformly once its rank is determined, pre- and post-multiplying B by fixed invertible matrices gives a uniform matrix of the same rank, therefore B and A−1 RABC have the same distribution. Now Pr (Y = Y |A = A) = Pr (A(M + B) = Y ) = Pr (ϕ(A(M + B)) = ϕ(Y )) = Pr A(M 0 + A−1 RABC) = ϕ(Y ) = Pr (A(M 0 + B) = ϕ(Y )) 0 = Pr (Y = ϕ(Y )|A = A) ,  (9) (10) where (9) holds since the distributions of B and A−1 RABC are the same. Since 9 (10) is true for any fixed matrix A, it follows that X Pr(Y = Y ) = Pr(A = A) Pr(Y = Y |A = A) A∈GL(n,q) = X Pr(A = A) Pr(Y 0 = ϕ(Y )|A = A) A∈GL(n,q) = Pr(Y 0 = ϕ(Y )). (11) Thus Y and Y 0 have the same distribution, up to relabeling by ϕ. In particular, we find that H(Y ) = H(Y 0 ). Definition 5.1. Let M be any n × m matrix of rank r. Let A be an n × n invertible matrix chosen uniformly from GL(n, q). Let B be an n × m matrix chosen from a UGR distribution with rank distribution R, where A and B are picked independently. We define hr = H (A(M + B)) . Lemma 5.1 implies that the value hr does not depend on M , only on the rank r and the channel parameters q, n, m and R. The exact value of hr will be calculated later, in Theorem 6.1. Lemma 5.2. Consider the Gamma channel Γ(R). Let the input matrix X be sampled from a distribution PX with associated rank distribution RX , and let Y be the corresponding output matrix. Then min{n,m} X H(Y |X) = RX (r)hr . r=0 In particular, H(Y |X) depends only on the associated input rank distribution RX and the channel parameters. Proof. Choosing A and B as in the definition of the Gamma channel, we see that X H(Y |X) = P (X = X)H(A(X + B)) X∈X = X P (X = X)hrk(X) X∈X min{n,m} = X RX (r)hr , r=0 which establishes the first assertion of the lemma. The second assertion follows since hr depends only on r and the channel parameters. The following lemma is a well known result, see for example [6, Ex. 2.28]. Lemma 5.3. Let Y1 and Y2 be two random n × m matrices, sampled from distributions with the same associated rank distribution RY . If the distribution of Y2 is UGR then H(Y2 ) ≥ H(Y1 ). Lemma 5.4. Consider the Gamma channel Γ(R). If the input distribution PX is UGR then the induced output distribution PY is also UGR. Proof. Suppose the input distribution is UGR, with rank distribution RX . We start by showing that the distribution of X + B is UGR. Let D be any n × m matrix. 10 Then Pr(X + B = D) X = Pr(X = X) Pr(X + B = D|X = X) X∈Fn×m q = RX (rk(X)) X n×m,rk(X) X∈Fn×m q |Fq | Pr(X + B = D), since X is sampled from a UGR distribution. Hence Pr(X + B = D) min{n,m} X = r=0 min{n,m} X = r=0 RX (r) |Fqn×m,r | RX (r) |Fqn×m,r | X Pr(B = D − X) X∈Fn×m,r q R(rk(D − X)) X n×m,rk(D−X) |Fq X∈Fn×m,r q | , since X and B are independent, and since B has a UGR distribution with rank distribution R. Now R(rk(D − X)) X n×m,rk(D−X) X∈Fn×m,r q |Fq | min{n,m} X = |{X ∈ Fn×m,r : rk(D − X) = rB }| q rB =0 min{n,m} X = f2 (rB , rk(D), r) rB =0 R(rB ) |Fqn×m,rB | R(rB ) B |Fn×m,r | q and so Pr(X + B = D) min{n,m} = X r=0 min{n,m} RX (r) X R(rB ) f2 (rB , rk(D), r) n×m,rB . n×m,r |Fq | rB =0 |Fq | So Pr(X + B = D) does not depend on the specific matrix D, only its rank. Therefore, given any two n × m matrices D1 , D2 of the same rank, Pr(X + B = D1 ) = Pr(X + B = D2 ). Hence X + B has a UGR distribution. Let A be a fixed n × n invertible matrix. Since X + B is picked uniformly once its rank is determined, multiplying X + B by the invertible matrix A will give a uniform matrix of the same rank, therefore A(X + B) has a UGR distribution. So, defining Y = A(X + B) to be the output of the Gamma channel, we see that for any n × m matrix Y Pr(Y = Y |A = A) = Pr(A(X + B) = Y ) = = Pr (rk(A(X + B)) = rk(Y )) n×m,rk(Y ) |Fq | Pr (rk(Y ) = rk(Y )|A = A) n×m,rk(Y ) |Fq 11 | , where the second equality follows since A(X + B) has a UGR distribution. Thus X Pr(Y = Y ) = Pr(A = A) Pr(Y = Y |A = A) A∈GL(n,q) = X Pr(A = A) Pr(rk(Y ) = rk(Y )|A = A) A∈GL(n,q) = 1 n×m,rk(Y ) |Fq | n×m,rk(Y ) |Fq | Pr(rk(Y ) = rk(Y )). (12) Since (12) holds for all Y ∈ Fn×m it follows that Y has a UGR distribution. q Theorem 5.5. For the Gamma channel Γ(R), there exists a UGR input distribution that achieves channel capacity. Moreover, given any input distribution PX with associated rank distribution RX , if PX achieves capacity then the UGR distribution with rank distribution RX achieves capacity. Proof. Let X1 be a channel input, with output Y1 such that PX1 is a capacity achieving input distribution. That is maxPX {I(X, Y )} = I(X1 , Y1 ). Then define the input X2 with output Y2 to be distributed such that PX2 is the UGR distribution with RX2 = RX1 . To prove the theorem it suffices to show I(X2 , Y2 ) ≥ I(X1 , Y1 ). By Lemma 4.2, RY2 = RY1 and by Lemma 5.4, Y2 has a UGR distribution. Therefore, by Lemma 5.3, H(Y2 ) ≥ H(Y1 ). (13) Also, since RX2 = RX1 , Lemma 5.2 implies that H(Y2 |X2 ) = H(Y1 |X1 ). (14) Using (13) and (14), it follows that I(X2 , Y2 ) = H(Y2 ) − H(Y2 |X2 ) ≥ H(Y1 ) − H(Y2 |X2 ) = H(Y1 ) − H(Y1 |X1 ) = I(X1 , Y1 ). 6 Optimal input distributions and channel capacity Theorem 5.5 reduces the problem of computing the Gamma channel capacity to a maximisation over a set of variables of linear rather than exponential size, since the UGR distribution is determined by the distribution RX on a set of size min{n, m}+1. In this section we give an expression for this maximisation problem in terms of the channel parameters and the efficiently computable functions f0 , f1 and f2 defined in Section 3. Since the mutual information is concave when considered as a function over possible input distributions (see e.g. [6, Theorem 2.7.4]), this is a concave maximisation problem and hence efficiently computable (see e.g. [3]). Therefore the expression obtained provides a means for efficiently computing the exact channel capacity, and determining an optimal input rank distribution. We begin by computing the value of hr , as defined in Definition 5.1. This is needed to compute the maximisation problem in Corollary 6.2 that gives rise to the channel capacity. 12 Theorem 6.1. The value hr , as defined in Definition 5.1, is given by min{n,m} min{r,v}    r m−r q hr = h q v−h q v=0 h=0     min{n,m} X f (r, v, h; r ) f (v) 1 B  0 . · R(rB ) log  Pmin{n,m,v+h} n×m,rB B) |F | q R(rB ) f1 (r,v,h;r n×m,rB rB =0 r =h X X (v−h)(r−h) |Fq B | where f0 is as defined in Lemma 3.1 and f1 is as defined in Lemma 3.2. Proof. Let M be a fixed n × m matrix of rank r. Let Y = A(M + B), where A is picked uniformly from GL(n, q) and B has a UGR distribution with rank distribution R. Then hr = H(A(M + B)| rk(M ) = r) = H(Y ). Since Row(Y ) is fully determined by Y , it follows that H(Y , Row(Y )) = H(Y ). Therefore, using the chain rule for entropy (e.g. [6, Thm. 2.2.1]), we have H(Y ) = H(Y , Row(Y )) = H(Y | Row(Y )) + H(Row(Y )). (15) Now, multiplying (M + B) by a uniformly picked invertible matrix will result in a uniform matrix of the same rowspace as (M + B). That is, the distribution of Y is uniform given the rowspace of Y . Thus (see [6, Thm. 2.6.4])  H(Y | Row(Y ) = V ) = log |{Y 0 : Y 0 ∈ Fn×m , Row(Y 0 ) = V }| q = log (f0 (dim(V ))) , (16) where f0 is as defined in Lemma 3.1. Therefore X H(Y | Row(Y )) = Pr(Row(Y ) = V )H(Y | Row(Y ) = V ) V ⊆Fm q = X Pr(Row(Y ) = V ) log (f0 (dim(V ))) . (17) V ⊆Fm q Hence hr = H(Y ) = H(Y | Row(Y )) + H(Row(Y )) X = Pr(Row(Y ) = V ) log (f0 (dim(V ))) V ⊆Fm q − X Pr(Row(Y ) = V ) log (Pr(Row(Y ) = V )) V ⊆Fm q = X V ⊆Fm q  Pr(Row(Y ) = V ) log f0 (dim(V )) Pr(Row(Y ) = V )  . (18) Now, we calculate the probability of Y having a particular rowspace V . Set U = Row(M ), so dim U = r. For V ⊆ Fm q , let dU V = dim(U ∩ V ). Using the function f1 13 defined in Lemma 3.2, we obtain the following result. Pr(Row(Y ) = V ) = Pr(Row(M + B) = V ) min{n,m} = X Pr(rk(B) = rB ) Pr(Row(M + B) = V | rk(B) = rB ) rB =0 min{n,m} = X R(rB ) |{B : rk(B) = rB , Row(M + B) = V }| B |Fn×m,r | q (19) R(rB ) f1 (r, dim(V ), dU V ; rB ) , B |Fn×m,r | q (20) rB =0 min{n,m} = X rB =0 where (19) follows since B has a UGR distribution. Substituting (20) into (18) we get  min{n,m} hr = X X  V ⊆Fm q rB =0  f1 (r, dim(V ), dU V ; rB )  R(rB ) B |Fn×m,r | q   f (dim(V )) 0  · log  Pmin{n,m} f1 (r,dim(V ),dU V ;rB ) R(r ) n×m,r B rB =0 B |Fq (21) | In (21), for a given subspace V ⊆ Fm q , the corresponding term in the sum depends only on dim(V ) and dU V = dim(Row(M )∩V ). Clearly 0 ≤ dU V ≤ min{dim U, dim V }. Moreover, Corollary 2.4 implies that the number of spaces V with dim(V ) = v and dim(Row(M ) ∩ V ) = h for fixed integers v and h is    r m−r . q (v−h)(r−h) h q v−h q Combining this with (21) proves the theorem. Now we give the result of this section: an efficiently computable expression for the Gamma channel capacity as a maximisation over the set of possible input rank distributions. Corollary 6.2. The capacity of the Gamma channel Γ(R) is given by     n×m,rY  min{n,m}  min{n,m}  X X |Fq | − C = max  RY (rY ) log RX (rX )hrX , RX   RY (rY ) rY =0 rX =0 where hrX may be computed using Theorem 6.1, and RY (rY ) may be computed using Lemma 4.2. Proof. The capacity C of the channel is defined to be C = max{I(X; Y )} = max{H(Y ) − H(Y |X)}. PX PX (22) By Theorem 5.5, to achieve capacity we can chose the input distribution PX to be UGR. By Lemma 5.4, the output distribution will also be UGR. Therefore the output distribution is given by PY (Y ) = Pr(Y = Y ) = 1 n×m,rk(Y ) |Fq | 14 RY (rk(Y )) (23) for any Y ∈ Fn×m . Thus the entropy of Y is given by q X H(Y ) = − Pr(Y = Y ) log Pr(Y = Y ) Y ∈Fn×m q =− ! 1 X n×m,rk(Y ) |Fq Y ∈Fn×m q min{n,m} =− X  RY (rY ) log 7 Pmin{n,m} rX =0 n×m,rk(Y ) |Fq | RY (rk(Y ))  1 Y |Fn×m,r | q rY =0 Since H(Y |X) = RY (rk(Y )) log | ! 1 RY (rY ) . RX (rX )hrX by Lemma 5.2, the result follows from (22). Matrix function proofs The aim of this section is to derive efficiently computable expressions for the functions f1 and f2 , thus proving Lemmas 3.2 and 3.3 respectively and providing a method for computing the capacity formula given in Corollary 6.2. We approach this problem by first exploring several combinatorial results. In Subsection 7.1 we establish a counting result we need later, using Möbius theory. In Subsection 7.2, we use this result to derive expressions for the functions f1 and f2 . 7.1 A counting lemma In this subsection, we prove an ‘inversion’ lemma, Lemma 7.1, that we need in the following subsection. We use Möbius theory (a generalisation of inclusion–exclusion) to establish this lemma: see Bender and Goldman [2], for example, for a nice introduction to this theory and an exposition of all the results we use here. m Let Po(Fm q ) denote the poset of all subspaces of Fq ordered by containment. Let P and Q be two posets. Recall that the direct product P × Q is the poset where (p1 , q1 ) ≤ (p2 , q2 ) if and only if p1 ≤ p2 and q1 ≤ q2 , where p1 , p2 ∈ P and q1 , q2 ∈ Q. Lemma 7.1. Let f ((U, V )) be a real valued function defined for all pairs (U, V ) ∈ m Po(Fm q ) × Po(Fq ). If X g((U, V )) = f ((U 0 , V 0 )) (U 0 ,V 0 )≤(U,V ) then f ((U, V )) = X 0 0 (−1)u−u +v−v q ( u−u0 2 0 )+(v−v 2 ) g((U 0 , V 0 )), (U 0 ,V 0 )≤(U,V ) where dim(U ) = u, dim(U 0 ) = u0 , dim(V ) = v and dim(V 0 ) = v 0 . Proof. By the Möbius inversion formula (see [2, Theorem 1], for example) X f ((U, V )) = µ((U 0 , V 0 ), (U, V ))g((U 0 , V 0 )), (24) (U 0 ,V 0 )≤(U,V ) m where µ is the Möbius function of Po(Fm q ) × Po(Fq ). But (see [2, Theorem 3], for example), µ((U 0 , V 0 ), (U, V )) = µ0 (U 0 , U )µ0 (V 0 , V ) where µ0 is the Möbius function of Po(Fm q ). Moreover (see, for example, [2, §5]) the Möbius function of Po(Fm q ) may be written explicitly as dim(Y )−dim(X) 2 µ0 (X, Y ) = (−1)dim(Y )−dim(X) q ( for any X, Y ∈ Po(Fm q ) with X ⊆ Y . So the lemma follows. 15 ) 7.2 Computing f1 and f2 By ‘basic dimension properties’, we mean that all specified dimensions are nonnegative integers, and if dimensions dU and dV of subspaces U ⊆ V are specified, then dU ≤ dV . Lemma 7.2. Let z be a non-negative integer. Let X and Y be subspaces of Fzq of dimensions dX and dY respectively such that X∩Y = {0}. Let c(dX , dY , z, dR , dRX , dRY ) be the number of dR -dimensional subspaces R of Fzq such that dim(R ∩ X) = dRX , dim(R ∩ Y ) = dRY and such that X ⊆ Y + R. If the basic dimension properties are satisfied then c(dX , dY , z, dR , dRX , dRY ) is given by the formula  dX dRX  q dY dRY  q z − dX − dY dR − dRY − dX  q (dY −dRY )(dR −dX −dRY ) dX −d RX −1 Y q (q dY −dRY − q i ), i=0 otherwise c(dX , dY , z, dR , dRX , dRY ) = 0. We remark that, in this case, the basic dimension properties are that 0 ≤ dRX ≤ min{dR , dX }, 0 ≤ dRY ≤ min{dR , dY } and dX + dY ≤ z. Proof. Suppose that dX > dR − dRY . The condition that X ⊆ Y + R is equivalent to the condition that the subspace (X + Y )/Y is contained in the subspace (R + Y )/Y . The dimensions of these subspaces are dX and dR − dRY respectively, and so our  X −dY count is zero in this case. But dRz−d −dRY −dX q = 0 when dR − dRY − dX < 0 and so the lemma follows  X in this case. So we may assume that dX ≤ ddRY − dRY . There are ddRX choices for the subspace R ∩ X and dRY q choices for the q subspace R∩Y . Assume that these subspaces are fixed. The quotient Q = (R+Y )/Y of R in Fzq /Y has dimension (dR − dRY ). The condition that X ⊆ Y + R implies that (X + Y )/Y ⊆ (X  Q. Since  + Y )/Y has dimension dX , the number of choices Y −dX for Q is therefore dRz−d −dRY −dX q . Assume that Q is now also fixed. Fix u1 , u2 , . . . , udR −dRY −dX ∈ Fm q with the property that {ui + Y : 1 ≤ i ≤ dR − dRY −dX } spans a complement to (X +Y )/Y in Q. Fix a basis x1 , . . . , xdRX of R∩X, and extend this basis to a basis x1 , x2 , . . . , xdX of X. Fix a basis y1 , y2 , . . . , ydRY of R ∩ Y . Every subspace R we are counting has a basis of the form {yi : 1 ≤ i ≤ dRY } ∪ {xi : 1 ≤ i ≤ dRX } ∪ {xi + i : dRX + 1 ≤ i ≤ dX } ∪ {ui + δi : 1 ≤ i ≤ dR − dRY − dX } for some i , δi ∈ Y . Note that all subspaces with a basis of this form intersect Y in precisely the space spanned by {yi : 1 ≤ i ≤ dRY }, and all subspaces are equal to Q after taking a quotient by Y . Moreover, a subspace of this form intersects X in precisely the subspace spanned by {xi : 1 ≤ i ≤ dRX } if and only if the vectors i +(R∩Y ) are linearly independent in Y /(R∩Y ). Finally, two subspaces of this form are distinct if and only if the ordered set of vectors i and δi are different modulo R ∩ Y . There are q (dY −dRY )(dR −dX −dRY ) choices for vectors δi + (R ∩ Y ) ∈ Y /(R ∩ Y ), QdX −dRX −1 dY −dRY and there are i=0 (q − q i ) choices for linearly independent vectors i + (R ∩ Y ) ∈ Y /(R ∩ Y ). So the lemma follows. We define a function f1 (dU , dV , dU V ; r) as follows. When r < (dU − dU V ), we define f1 (dU , dV , dU V ; r) = 0. Otherwise we proceed as follows. For integers dV 0 , dW 0 and dV 0 W 0 , define r−d 0 W 2 κ1 (dV 0 , dW 0 , dV 0 W 0 ) = (−1)(r−dW 0 ) q ( V 0 ) nd 0 ) (−1)(dV −dV 0 ) q (dV −d 2 q V W0 . For integers dV 0 , dW 0 , dV 0 W 0 , dU W 0 , dV W 0 and dU V W 0 , define κ2 (dV 0 , dW 0 , dV 0 W 0 , dU W 0 , dV W 0 , dU V W 0 ) = ν1 ν2 ν3 16 where ν1 = c(dU − dU V , dV − dU V , m − dU V , dW 0 − dU V W 0 , dU W 0 − dU V W 0 , dV W 0 − dU V W 0 )      dU V dV W 0 (dV − dV W 0 ) − (dU − dU W 0 ) m − dW 0 ν2 = and dU V W 0 q dV 0 W 0 q (dV 0 − dV 0 W 0 ) − (dU − dU W 0 ) q r − dW 0 q ν3 = q (dW 0 −dU V W 0 )(dU V −dU V W 0 ) q (dV W 0 −dV 0 W 0 )(dV 0 −dV 0 W 0 ) , where c is the function defined in Lemma 7.2. Then f1 (dU , dV , dU V ; r) is equal to r X dV X dW 0 =0 dV 0 =0 min{dV 0 ,dW 0 } min{dU ,dW 0 } min{dV ,dW 0 } min{dU V ,dV W 0 ,dU W 0 } X X X X dV 0 W 0 =0 dU W 0 =0 dV W 0 =0 dU V W 0 =0 κ1 κ2 , where κ1 = κ1 (dV 0 , dW 0 , dV 0 W 0 ) and κ2 = κ2 (dV 0 , dW 0 , dV 0 W 0 , dU W 0 , dV W 0 , dU V W 0 ). Theorem 7.3. Let f1 be as defined in Lemma 3.2. That is, if U and V are subspaces n×m of Fm q of dimensions dU and dV respectively, with dU V = dim(U ∩ V ) and M ∈ Fq is a fixed matrix such that Row(M ) = U ; then f1 (dU , dV , dU V ; r) gives the number of such that Row(M + B) = V . Then the value f1 (dU , dV , dU V ; r) matrices B ∈ Fn×m,r q is as given above. Proof. We begin the proof with a simpler counting problem, and then use this result to establish the formula we are aiming for. For a subspace W of Fm q , let g(V, W ) be the number of n × m matrices B with Row(B) ⊆ W and Row(M + B) ⊆ V . We claim that ( q n dV W if U ⊆ V + W g(V, W ) = 0 otherwise. To see this, we proceed as follows. Let x1 , x2 , . . . , xn ∈ Fm q be the rows of M . Suppose that U 6⊆ V + W . Then (xi + W ) ∩ V = ∅ for some i, and so we must have g(V, W ) = 0, since there is no valid choice for the ith row of B in this case. Now suppose that U ⊆ V + W , so for all i we have (xi + W ) ∩ V 6= ∅ and therefore there exist w1 , w2 , . . . , wn ∈ W such that xi + wi ∈ V . It is not hard to check that a matrix B with rows bi has the property that Row(B) ⊆ W and Row(M + B) ⊆ V if and only if bi − wi ∈ V ∩ W . Hence there are q dV W choices for each row bi of B. Since B has n rows, the claim follows. Let f (V, W ) be the number Pof n×m matrices B with Row(B) = W and Row(M + B) = V . Now g(V, W ) = (V 0 ,W 0 ) f (V, W ), where the sum is over all pairs of subspaces (V 0 , W 0 ) with V 0 ⊆ V and W 0 ⊆ W . So, by Lemma 7.1, f (V, W ) = X dW −d 0 W 2 (−1)(dW −dW 0 )+(dV −dV 0 ) q ( V 0) )+(dV −d 2 g(V 0 , W 0 ) (V 0 ,W 0 ) = X dW −d 0 W 2 (−1)(dW −dW 0 )+(dV −dV 0 ) q ( V 0 ) nd 0 )+(dV −d 2 q V W0 (V 0 ,W 0 ) U ⊆V 0 +W 0 = X κ1 (dV 0 , dW 0 , dV 0 W 0 ), (V 0 ,W 0 ) U ⊆V 0 +W 0 where again V 0 ⊆ V and W 0 ⊆ W in our sums. The number of matrices B of rank r such that Row(M + B) = V is X f (V, W ). W ⊆Fm q dim W =r 17 So we can express this count as dV X r X dW 0 =0 dV 0 =0 min{dV 0 ,dW 0 } min{dU ,dW 0 } min{dV ,dW 0 } min{dU V ,dV W 0 , dU W 0 } X X X X X dV 0 W 0 =0 dU W 0 =0 dV W 0 =0 dU V W 0 =0 V 0 ,W 0 ,W κ1 (dV 0 , dW 0 , dV 0 W 0 ), (25) 0 where the last sum is over all triples (V 0 , W 0 , W ) of subspaces of Fm q with V ⊆ V , W 0 ⊆ W , U ⊆ V 0 + W 0 , dim(W 0 ) = dW 0 , dim(W ) = r, dim(V 0 ) = dV 0 , dim(V 0 ∩ W 0 ) = dV 0 W 0 , dim(U ∩ W 0 ) = dU W 0 , dim(V ∩ W 0 ) = dV W 0 and dim U ∩ V ∩ W 0 = dU V W 0 . We aim to count the number of possibilities for a subspace W 0 such that dim(W 0 ) = dW 0 , dim(U ∩ W 0 ) = dU W 0 , dim(V ∩ W 0 ) = dV W 0 and dim U ∩ V ∩ W 0 = dU V W 0 and that satisfy the weaker condition that U ⊆ V + W 0 . We will show (see below) that the number of such subspaces W 0 is   dU V q (dW 0 −dU V W 0 )(dU V −dU V W 0 ) , (26) c dU V W 0 q where c = c(dU − dU V , dV − dU V , m − dU V , dW 0 − dU V W 0 , dU W 0 − dU V W 0 , dV W 0 − dU V W 0 ) is defined in Lemma 7.2. Once we have fixed such a subspace W 0 , we choose V 0 and W as follows. We first choose the subspace V 0 ∩ W 0 . There are ddV0W 00 choices for this subspace. V W q The quotient space (V 0 + W 0 )/W 0 of V 0 by W 0 is a space of dimension dV 0 − dV 0 W 0 . It is contained in the (dV − dV W 0 )-dimensional space (V + W 0 )/W 0 and contains the (dU − dU W 0 )-dimensional space (U + W 0 )/W 0 . So the number of choices for (V 0 + W 0 )/W 0 is   (dV − dV W 0 ) − (dU − dU W 0 ) . (dV 0 − dV 0 W 0 ) − (dU − dU W 0 ) q Once this quotient space is also fixed, there are q (dV W 0 −dV 0 W 0 )(dV 0 −dV 0 W 0 ) choices for V 0 . Finally we choose the r-dimensional subspace W containing W 0 : there are  m−d W0 choices for W . r−d 0 W q Combining the formula (26) with (25) and the counting argument of the previous paragraph, the theorem follows. So it remains to establish (26).   The number of choices (26) for W 0 may be found as follows. There are d dU V 0 UV W q choices for the subspace T = (U ∩ V ) ∩ W 0 . Suppose that T is now fixed. We now consider the images X, Y and R of U , V and W 0 respectively in the quotient by U ∩V . So X = (U +(U ∩V ))/(U ∩V ) has dimension dU −dU V and Y = (V +(U ∩V ))/(U ∩V ) has dimension dV − dU V . Moreover R is a subspace of dimension dW 0 − dU V W 0 which intersects X and Y in subspaces of dimension dU W 0 − dU V W 0 and dV W 0 − dU V W 0 respectively. The subspaces X and Y intersect trivially. Since U ⊆ V + W 0 , we see that X ⊆ Y + R. Hence, by Lemma 7.2, the number of choices for the subspace R is c(dU − dU V , dV − dU V , m − dU V , dW 0 − dU V W 0 , dU W 0 − dU V W 0 , dV W 0 − dU V W 0 ). Suppose now that R is fixed. There are q (dW 0 −dU V W 0 )dU V W 0 subspaces W 0 with (W 0 + (U ∩ V ))/(U ∩ V ) = R and (U ∩ V ) ∩ W 0 = T . Since all of these subspace have the property that U ⊆ W 0 + V , the formula (26) follows, and so the theorem is proved. Theorem 7.4. Let f2 be as defined in Lemma 3.3. That is, for a fixed matrix X B with rk(X) = rX , f2 (r, rX , rB ) gives the number of matrices B ∈ Fn×m,r such that q rk(X + B) = r. Then, min{r,rX } f2 (r, rX , rB ) = X q (r−h)(rX −h) h=0 18  m − rX r−h  q rX h  f1 (rX , r, h; rB ). q Proof. Using the definition of f1 given above Theorem 7.3, we see that f2 (r, rX , rB ) X = f1 (rX , r, dim(V ∩ Row(X)); rB ) (27) V ⊆Fm q :dim(V )=r min{r,rX } = X |{V ⊆ Fm q : dim(V ) = r, dim(V ∩ Row(X)) = h}|f1 (rX , r, h; rB ) (28) h=0 where (27) follows since the number of matrices B with rk(X + B) = r is equal to the number of matrices B with Row(X + B) = V , summed over all spaces V ⊆ Fm q with dim(V ) = r. By Corollary 2.4, the number of r-dimensional subspaces V ⊆ Fm q , with dim(V ∩ Row(X)) = h is    m − rX rX . (29) q (r−h)(rX −h) r−h q h q Substituting (29) into (28) gives the result. 8 Conclusion In this paper we have considered a class of matrix channels (Gamma channels) suitable for modelling random linear network coding when random errors are introduced during transmission. The Gamma channels are a generalisation of the AMMC channel considered in [18]. Random errors are modelled by a matrix whose rank represents the number of linearly independent errors. The error matrix is chosen by first picking its rank according to a rank distribution R dependent on the application, and then choosing uniformly from all matrices of this rank (a UGR distribution). We show that in this model there always exists a capacity achieving input distribution that is UGR. This key result allows us to compute the capacity of the channel as a maximisation problem over possible (input) rank distributions, a set of linear rather than exponential size. We presented sample capacity computations in the introduction: all computations used a simple hill-climbing algorithm to perform the maximisation, and were implemented in Mathematica 10.4 [11]. Open Problem 1. Can bounds for the AMMC capacity be improved, to give good asymptotic results in more situations? We ran simulations to show that for the AMMC channel with two errors, the true capacity of the channel closely follows the trend of the previously known upper bound for the capacity. It might be possible to improve the lower bound on the capacity by using simulation results as a guide. Open Problem 2. Can good asymptotic bounds on the capacity of the Gamma channel be established? We believe it will be hard to find good capacity bounds that hold in complete generality. But it would be very interesting to investigate the binomial rank distribution for errors, or the distribution arising for errors that are not linearly independent mentioned in the introduction. Open Problem 3. Can explicit good coding schemes for the Gamma channel be constructed? Theorem 5.5 shows that there are UGR input distributions that achieve capacity. It would be interesting to see explicit good coding schemes that use UGR input distributions. (We are not aware of such schemes, even in special cases such as the AMMC channel.) 19 Acknowledgements Jessica Claridge would like to acknowledge the support of an EPSRC PhD studentship. Both authors would like to acknowledge the support of the EU COST Action IC1104, and would like thanks reviewers of an earlier version of this paper for their comments. References [1] R. Ahlswede, N. Cai, S.-Y. R. Li, and R. W. Yeung. Network information flow. IEEE Transactions on Information Theory, 46(4):1204–1216, Jul 2000. [2] E. A. Bender and J. R. Goldman. On the applications of Möbius inversion in combinatorial analysis. The American Mathematical Monthly, 82(8):789–803, October 1975. [3] S. Boyd and L. Vandenberghe. Convex Optimization. Cambridge university press, 2004. [4] P. J. Cameron. Combinatorics: Topics, Techniques, Algorithms. Cambridge University Press, 1994. [5] J. Claridge. On Matrix Models for Network Coding. PhD Thesis, Royal Holloway, University of London, 2017. [6] T. M. Cover and J. A. Thomas. Elements of information theory. John Wiley & Sons, 2012. [7] È. M. Gabidulin. Theory of codes with maximum rank distance. Problems of Information Transmission, 21(1):1–12, January 1985. [8] M. Gadouleau and Z. Yan. Packing and covering properties of rank metric codes. IEEE Transactions on Information Theory, 54(9):3873–3883, 2008. [9] M. Gadouleau and Z. Yan. Bounds on covering codes with the rank metric. IEEE Communications Letters, 13(9):691–693, 2009. [10] T. Ho, M. Médard, R. Kötter, D. R. Karger, M. Effros, J. Shi, and B. Leong. A random linear network coding approach to multicast. IEEE Transactions on Information Theory, 52(10):4413–4430, October 2006. [11] Wolfram Research, Inc. Mathematica, Version 10.4. Champaign, IL, 2016. [12] R. Kötter and F. R. Kschischang. Coding for errors and erasures in random network coding. IEEE Transactions on Information Theory, 54(8):3579–3591, Aug 2008. [13] S.-Y. R. Li, R. W. Yeung, and N. Cai. Linear network coding. IEEE Transactions on Information Theory, 49(2):371–381, 2003. [14] A. Montanari and R. L. Urbanke. Iterative coding for network coding. IEEE Transactions on Information Theory, 59(3):1563–1572, 2013. [15] R. W. Nobrega, D. Silva, and B. F. Uchoa-Filho. On the capacity of multiplicative finite-field matrix channels. IEEE Transactions on Information Theory, 59(8):4949–4960, 2013. [16] M. J. Siavoshani, S. Mohajer, C. Fragouli, and S. N. Diggavi. On the capacity of noncoherent network coding. IEEE Transactions on Information Theory, 57(2):1046–1066, 2011. [17] D. Silva, F. R. Kschischang, and R. Kötter. A rank-metric approach to error control in random network coding. IEEE Transactions on Information Theory, 54(9):3951–3967, 2008. 20 [18] D. Silva, F. R. Kschischang, and R. Kötter. Communication over finite-field matrix channels. IEEE Transactions on Information Theory, 56(3):1296–1305, March 2010. 21
7cs.IT
Expression-based aliasing for OO–languages Georgiana Caltais1 arXiv:1409.7509v2 [cs.PL] 20 Oct 2014 Department of Computer Science, ETH Zürich, Switzerland Abstract. Alias analysis has been an interesting research topic in verification and optimization of programs. The undecidability of determining whether two expressions in a program may reference to the same object is the main source of the challenges raised in alias analysis. In this paper we propose an extension of a previously introduced alias calculus based on program expressions, to the setting of unbounded program executions such as infinite loops and recursive calls. Moreover, we devise a corresponding executable specification in the K-framework. An important property of our extension is that, in a non-concurrent setting, the corresponding alias expressions can be over-approximated in terms of a notion of regular expressions. This further enables us to show that the associated K-machinery implements an algorithm that always stops and provides a sound over-approximation of the “may aliasing” information, where soundness stands for the lack of false negatives. As a case study, we analyze the integration and further applications of the alias calculus in SCOOP. The latter is an object-oriented programming model for concurrency, recently formalized in Maude; K definitions can be compiled into Maude for execution. 1 Introduction A research direction of interest in Computer Science is the application of alias analysis in verification and optimization of programs. One of the challenges along this line of research has been the undecidability of determining whether two expressions in a program may reference the same object. A rich suite of approaches aiming at providing a satisfactory balance between scalability and precision has already been developed in this regard. Examples include: (i) intraprocedural frameworks [16,15] that handle isolated functions only, and their inter-procedural counterparts [15,22,11] that consider the interactions between function calls; (ii) type-based techniques [8]; (iii) flow-based techniques [4,6] that establish aliases depending on the control-flow information of a procedure; (iv) context-(in)sensitive approaches [9,29] that depend on whether the calling context of a function is taken into account or not; (v) field-(in)sensitive approaches [20,1] that depend on whether the individual fields of objects in a program are traced or not. More details on such classifications can be found in [25], for instance. For a comprehensive survey on alias analyses for objectoriented programs, corresponding issues and remaining open problems, we refer the interested reader to the works in [28,10]. Of particular interest for the work in this paper is the untyped, flow-sensitive, field sensitive, inter-procedural and context-sensitive calculus for may aliasing, introduced in [14]. The aforementioned calculus covers most of the aspects of a modern object-oriented language, namely: object creation and deletion, conditionals, assignments, loops and (possibly recursive) function calls. The approach in [14] abstracts the aliasing information in terms of explicit access paths [17] referred to as alias expressions. Consider, for an example, the code x : = y; loop x : = x.next end (1) The corresponding execution causes x to become aliased to y.next.next. . . ., with a possibly infinite number of occurrences of the field next. The set of associated alias expressions can be equivalently written as: {[x, y.nextk ] | k ≥ 0}. (2) The sources of imprecision introduced by the calculus in [14] are limited to ignoring tests in conditionals, and to “cutting at length L”, for the case of possibly infinite alias relation as in (2). Intuitively, the cutting technique considers sequences longer than a given length L as aliased to all expressions. There is a huge literature on heap analysis for aliasing [10], but hardly any paper that presents a calculus as in [14] allowing the derivation of alias relations as the result of applying various instructions of a programming language. Our focus is two folded. First, we want extend the framework in [14] to the setting of unbounded program executions such as infinite loops and recursive calls. In accordance, the goal is to provide a way to shift from “finite” to “infinite behaviours”. This can be achieved in a rather straightforward manner, by redefining the construct loop p end in [14] according to the informal semantics: “execute p repeatedly any number of times, including zero”. However, developing a corresponding mechanism for reasoning on “may aliasing” in a finite number of steps is not trivial. The key observation that paves the way to a possible (finite state-based) modeling in a non-concurrent setting is that the alias expressions corresponding to loops and recursive calls grow in a regular fashion. Hence, they are finitely representable, as it is easy to see in (2), for instance. Such regularities cannot be exploited in concurrent contexts, due to the “non-determinism” of process interaction. A similar technique exploiting regular behaviour of (non-concurrent) programs, in order to reason on “may aliasing”, was previously introduced in [2]. In short, the results in [2] utilize abstract representations of programs in terms of finite pushdown systems, for which infinite execution paths have a regular structure (or are “lasso shaped”) [3]. Then, in the style of abstract interpretation [7], the collecting semantics is applied over the (finite state) pushdown systems to obtain the alias analysis itself. In short, the main difference with the results in [2] consists in how the abstract memory addresses corresponding to pointer variables are represented. In [2] these range over a finite set of natural numbers. In this paper we consider alias expressions build according to the calculus in [14]. The work in [2] also proposes an implementation of pushdown systems in the K-framework [26]. The latter is an executable semantic framework based on Rewriting Logic (RL) [18], and has successfully been used for defining programming languages and corresponding formal analysis tools. Moreover, K definitions have a direct implementation in K-Maude [27]. We agree that it could be worth presenting our analysis as an abstract interpretation (AI) [7]. A modelling exploiting the machinery of AI (based on abstract domains, abstraction and concretization functions, Galois connections, fixed-points, etc.) is an interesting, but different research topic per se. Our second interest w.r.t. may aliasing is its integration in SCOOP [21] – a simple object oriented programming model for concurrency; thus an operational based approach on handling the alias calculus is more appropriate. The basis of a RL-based framework for the design and analysis of the SCOOP model was recently set in [21]. The reference implementation of SCOOP is Eiffel [19]. The integration of alias analysis belongs to a more ambitious goal, namely, the construction of a RL-based toolbox for the analysis of SCOOP programs (examples include a deadlock detector and a type checker). Our contribution. By drawing inspiration from, and building on top of the results in [14,2], in this paper we propose: – an extension of the (finite) alias calculus in [14] to the setting of unbounded program executions, and a sound over-approximation technique based on “regular alias expressions”, for non-concurrent settings; – a RL-based specification of the extended calculus; – an algorithm that always terminates and provides a sound over-approximation of “may aliasing” by exploiting a notion of regular (finitely representable) aliases, for non-concurrent settings. Moreover, we analyze the integration, implementation and further applications of the alias calculus in SCOOP. Paper structure. The paper is organized as follows. In Section 2 we introduce the extension of the alias calculus in [14] to unbounded executions. In Section 3 we provide the RL-based executable specification of the calculus in the K semantic framework. The implementation in SCOOP, and further applications are discussed in Section 4. In Section 5 we draw the conclusions and provide pointers to future work. 2 The alias calculus In this section we define an extension of the calculus in [14], to unbounded program executions. Moreover, based on the idea behind the pumping lemma for regular languages [24], we devise a corresponding sound over-approximation of “may aliasing” in terms of regular expressions, applicable in sequential contexts. This paves the way to developing an algorithm for the aliasing problem, as presented in Section 3, in the formal setting of the K semantic framework [26]. Preliminaries. We proceed by briefly recalling the notion of alias relation and a series of associated notations and basic operations, as introduced in [14]. We call an expression a (possibly infinite) path of shape x.y.z. . . ., where x is a local variable, class attribute or Current, and y, z, . . . are attributes. Here, Current, also known as this or self, stands for the current object. For an arbitrary alias expression e, it holds that e.Current = Current.e = e. Let E represent the set of all expressions of a program. An alias relation is a symmetric and irreflexive binary relation over E × E. Given an alias relation r and an expression e, we define r/e = {e} ∪ {x: E | [x, e] ∈ r} denoting the set consisting of all elements in r which are aliased to e, plus e itself. Let x be an expression; we write r − x to represent r without the pairs with one element of shape x.e. We say that an alias relation is dot complete whenever for any t, u, v and a it holds that if [t, u] and [t.a, v] are alias pairs, then [u.a, v] is an alias pair and, moreover, if a is in the domain of t, then [t.a, u.a] is an alias pair. By the “domain of t” we refer to a method or a field in the class corresponding to the object referred by the expression associated to t. For instance, given a class NODE with a field next of type NODE, and a NODE object x, we say that next is in the domain of t = x.next.next. For the sake of brevity, we write dot-complete(r) for the closure under dot-completeness of a relation r. The notation r[x = u] represents the relation r augmented with pairs [x, y] and made dot complete, where y is an element of u. 2.1 Extension to unbounded executions We further introduce an extension of the alias calculus in [14] to infinite alias relations corresponding to unbounded executions such as infinite loops or recursive calls. The main difference in our approach is reflected by the definition of loops, which now complies to the usual fixed-point denotational semantics. The alias calculus is defined by a set of axioms “describing” how the execution a program affects the aliasing between expressions. As in [14], the calculus ignores tests in conditionals and loops. The program instructions are defined as follows: p :: = p ; p | then p else p end | create x | forget x | t : = s | loop p end | call f (l) | x.call f (l). (3) In short, we write r » p to represent the alias information obtained by executing p when starting with the initial alias relation r. The axiom for sequential composition is defined in the obvious way: r » (p ; q) = (r » p) » q. (4) Conditionals are handled by considering the union of the alias pairs resulted from the execution of the instructions corresponding to each of the two branches, when starting with the same initial relation: r » (then p else q end) = r » p ∪ r » q. (5) As previously mentioned, we define r » loop p end according to its informal semantics : “execute p repeatedly any number of times, including zero”. The corresponding rule is: [ r » (loop p end) = (r » pn ) (6) n∈N where ∪ stands for the union of alias relations, as above. This way, our calculus is extended to infinite alias relations. This is the main difference with the approach in [14] that proposes a “cutting” technique restricting the model to a maximum length L. In [14], sequences longer than L are considered as aliased to all expressions. Orthogonally, for sequential settings, we provide finite representations of infinite alias relations based on over-approximating regular expressions, as we shall see in Section 2.2. Both the creation and the deletion of an object x eliminate from the current alias relation all the pairs having one element prefixed by x: r » (create x) = r − x r » (forget x) = r − x. (7) The (qualified) function calls comply to their initial definitions in [14]: r » (call f (l)) = (r[f • :l]) » | f | r » (x.call f (l)) = x.((x′ .r) » call f (x′ .l)). (8) Here f • and | f | stand for the formal argument list and the body of f , respectively, whereas r[u:v] is the relation r in which every element of the list v is replaced by its counterpart in u. Intuitively, the negative variable x′ is meant to transpose the context of the qualified call to the context of the caller. Note that “.” (i.e., the constructor for alias expressions) is generalized to distribute over lists and relations: x.[a, b, . . .] = [x.a, x.b, . . .]. For an example, consider a class C in an OO-language, and an associated procedure f that assigns a local variable y, defined as: f (x) { y : = x }. Then, for instance, the aliasing for a.call f (a) computes as follows: ∅ » a.call f (a) = a.(a′ .∅ » y : = a′ .a) = a.(∅ » y : = Current) = dot-complete({[a.y, a]}). Recursive function calls can lead to infinite alias relations. In sequential settings, as for the case of loops, the mechanism exploiting sound regular overapproximations in order to derive finite representations of such relations is presented in the subsequent sections. The axiom for assignment is as well in accordance with its original counterpart in [14]: r » (t : = s) = given r1 = r[ot = t] then (r1 − t)[t = (r1 /s − t)] − ot end (9) where ot is a fresh variable (that stands for “old t”). Intuitively, the aliasing information w.r.t. the initial value of t is “saved” by associating t and ot in r and closing the new relation under dot-completeness, in r1 . Then, the initial t is “forgotten” by computing r1 − t and the new aliasing information is added in a consistent way. Namely, we add all pairs (t, s′ ), where s′ ranges over r1 /s − t representing all expressions already aliased with s in r1 , including s itself, but without t. Recall that alias relations are not reflexive, thus by eliminating t we make sure we do not include pairs of shape [t, t]. Then, we consider again the closure under dot-completeness and forget the aliasing information w.r.t. the initial value of t, by removing ot. Remark 1. It is worth discussing the reason behind not considering transitive alias relations. Assume the following program: then x : = y else y : = z end Based on the equations (5) and (9) handling conditionals and assignments, respectively, the calculus correctly identifies the alias set: {[x, y], [y, z]}. Including [x, z] would be semantically equivalent to the execution of the two branches in the conditional at the same time, which is not what we want. 2.2 A sound over-approximation In a sequential setting, the challenge of computing the alias information in the context of (infinite) loops and recursive calls reduces to evaluating their corresponding “unfoldings”, captured by expressions of shape r » pω , with ω ranging over naturals plus infinity, r an (initial) alias relation (r = ∅), and p a basic control block defined by: p :: = p ; p | then p else p end | create x | forget x | t : = s. (10) The value r » pω refers to the alias relation obtained by recursively executing the control block p, and it is calculated in the expected way: r » p0 = r r » pk+1 = (r » pk ) » p. Consider again the code in (1): x : = y; loop x : = x.next end. Its execution generates the alias relation (((∅ » (x : = y)) » (x : = x.next)) » (x : = x.next) . . . including an infinite number of pairs of shape: [x, y.next], [x, y.next.next], [x, y.next.next.next] . . . . (11) A similar reasoning does not hold for concurrent applications, where process interaction is not “regular”. In what follows we provide a way to compute finite representations of infinite alias relations in sequential settings. The key observation is that alias expressions corresponding to unbounded program executions grow in a regular fashion. See, for instance, the aliases in (11), which are pairs of type [x, y.nextk≥1 ]. Regular expressions are defined similarly to the regular languages over an alphabet. We say that an expression is regular if it is a local variable, class attribute or Current. Moreover, the concatenation e1 . e2 of two regular expressions e1 and e2 is also regular. Given a regular alias expression e, the expression e∗ is also regular; here (−)∗ denotes the Kleene star [13]. We call an alias relation regular if it consists of pairs of regular expressions. Lemma 1. Assume p a program built according to the rules in (3). Then, in a sequential setting, the relation ∅ » p is regular. Proof. The result follows by induction on the structure of p. We refer to Appendix A for the detailed proof. Inspired by the idea behind the pumping lemma for regular languages [24], we define a lasso property for alias relations, which identifies the repetitive patterns within the structure of the corresponding alias expressions. The intuition is that such patterns will occur for an infinite number of times due to the execution of loops or recursive function calls. Then, we supply sound over-approximations of “lasso” relations, based on regular alias expressions. In the context of alias relations, we say that the lasso property is satisfied by r and r′ whenever the following two conditions hold: (1) r behaves like a lasso base of r′ . Namely, all the pairs [e1 , e2 ] ∈ r are used to generate elements [e′1 , e′2 ] ∈ r′ , by repeating tails of prefixes of e1 and e2 , respectively, and (2) r′ is a lasso extension of r. Namely, all the pairs in r′ are generated from elements of r by repeating tails of their prefixes. For example, if e1 above is an expression of shape x.y.z.w, then e′1 can be x.y.y.z.w if we consider the tail y of the prefix x.y, or x.y.z.y.z.w if we take the tail y.z of the prefix x.y.z. Formally, consider r and r′ two alias relations, and xi , yi and zi a set of (possibly empty) expressions, for i ∈ {1, 2}. Then: lasso(r, r′ ) = ([x1 y1 z1 , x2 y2 z2 ] ∈ r iff [x1 y1 y1 z1 , x2 y2 y2 z2 ] ∈ r′ ). (12) For the simplicity of notation we sometimes omit the dot-separators between expressions. For instance, we write x y z in lieu of x.y.z. Assuming a lasso over r and r′ , we compute a relation consisting of regular expressions over-approximating r and r′ as: reg(r, r′ ) = {[x1 y1∗ z1 , x2 y2∗ z2 ] | [x1 y1 z1 , x2 y2 z2 ] ∈ r ∧ [x1 y1 y1 z1 , x2 y2 y2 z2 ] ∈ r′ } (13) where xi , yi and zi are possibly empty expressions, for i ∈ {1, 2}. As previously indicated, the over-approximation is sound w.r.t. the repeated application of a basic control block as in (10), in the way that it does not introduce any false negatives: Lemma 2. Consider r and r′ two alias relations, and p a basic control block in a sequential setting. If r » p = r′ and lasso(r, r′ ) = true, then the following holds for all n ≥ 1: r » pn ∈ reg(r, r′ ). Proof. The reasoning is by induction on n. The base case follows immediately, whereas the induction step is proved by “reductio ad absurdum”. A detailed proof is included in Appendix B. ⊓ ⊔ 3 A K-machinery for collecting aliases In this section we provide the specification of a RL-based mechanism collecting the alias information in the K semantic framework [26]. We choose K more as a notational convention to enable compact and modular definitions. In reality, the K-rules in this section are implemented in Maude, as rewriting theories, on top of the formalization of SCOOP [21] (we refer to Section 4 for more details on our approach). In short, our strategy is to start with a program built on top of the control structures in (3), then to apply the corresponding K-rules in order to get the “may aliasing” information in a designated K-cell (h − ial ). Independently of the setting (sequential or concurrent) one can exploit this approach in order to evaluate the aliases of a given finite length L. We also show that for sequential contexts, the application of the K-rules is finite and the aliases in the final configuration soundly over-approximate the (infinite) “may alias” relations of the calculus. Brief overview of K. K [26] is an executable semantic framework based on Rewriting Logic [18]. It is suitable for defining (concurrent) languages and corresponding formal analysis tools, with straightforward implementation in KMaude [27]. K-definitions make use of the so-called cells, which are labelled and can be nested, and (rewriting) rules describing the intended (operational) semantics. A cell is denoted by h − i[name] , where [name] stands for the name of the cell. A construction h . in stands for an empty cell named n. We use “pattern matching” and write h c . . .in for a cell with content c at the top, followed by an arbitrary content (. . .). Orthogonally, we can utilize cells of shape h. . . c in and h . . . c . . . in , defined in the obvious way. Of particular interest is h − ik – the continuation cell, or the k-cell, holding the stack of program instructions (associated to one processor), in the context of a programming language formalization. We write h i1 y i2 . . .ik for a set of instructions to be “executed”, starting with instruction i1 , followed by i2 . The associative operation y is the instruction sequencing. A K-rewrite rule h c . . .in1 h c′ in2 ⇒ h c′ . . .in1 h. . . c′ in3 (14) reads as: if cell n1 has c at the top and cell n2 contains value c′ , then c is replaced by c′ in n1 and c′ is added at the end of the cell n3 . The content of n2 remains unchanged. In short, (14) is written in a K-like syntax as: h c . . .in1 h. . . . in3 h c′ in2 . c′ c′ We further provide the details behind the K-specification of the alias calculus. As expected, the k-cell retains the instruction stack of the object-oriented program. We utilize cells h−ial to enclose the current alias information, and the so-called back-tracking cells h−ibkt-. . . enabling the sound computation of aliases for the case of then − else − end and, in non-concurrent contexts, for loops and (possibly recursive) function calls. As a convention, we mark with (♣) the rules that are sound only for non-concurrent applications, based on Lemma 2. Due to space limitations, in what follows we introduce only the K-rules for handling assignments and loops. The entire specification is included in Appendix C. As expected, the assignment rule simply restores the current alias relation according to its axiom in (9), and removes the assignment instruction from the top of the k-cell: h r ial h t : = s . . .ik (r1 − t)[t = (r1 /s − t)] − ot . with r1 = r[ot = t] (15) For loop p end, we utilize a meta-construction p l loop p end simulating the unfolding corresponding to (6), and a back-tracking stack h−ibkt-l collecting the alias information obtained after each execution of p. Moreover, the Kimplementation exploits the result in Lemma 2. Whenever a “lasso” is reached, the infinite rewriting is prevented by resuming the infinite application of p in terms of a sound over-approximating alias relation. The K-rules are as follows. First, the aforementioned unfolding is performed, and the alias relation before p is stored in the back-tracking cell as hrial-o hpil : h r ial h loop p end . . .ik h . . . .ibkt-l h r ial-o h p il p l loop p end (16) If the alias relation r′ obtained after the successful execution of p (marked by l at the top of the continuation) is not a lasso of the aliasing r before p (previously stored in h−ibkt-l ) then p is constrained to a new execution by becoming the top of the k-cell, and r′ is memorized for back-tracking: h r ′ ial h l loop p end . . .ik h h r ial-o h p il . . .ibkt-l if not lasso(r, r ′ ) (♣) (17) h r ′ ial-o h p il p l loop p end Last, if a lasso is reached after the execution of p, then the current aliasing is soundly replaced by a “regular” over-approximation reg(r, r′ ), the corresponding back-tracking information is removed from h−ibkt-l and the loop instruction is eliminated from the k-cell: h r′ ialh reg(r, r ′ ) l loop p end . . .ikh h r ial-o h p il . . .ibkt-l if lasso(r, r ′ ) (♣) (18) . . In a non-concurrent setting, the machinery orchestrating the K-rules introduced in this section, and thoroughly discussed in Appendix C, implements an algorithm that always terminates and provides a sound over-approximation of “may aliasing”. Theorem 1. Consider p a program built on top of the control structures in (3), that executes in a sequential setting. Then, the application of the corresponding K-rules when starting with p and an empty alias relation, is a finite rewriting of shape (∗) h ∅ ial h p ik =⇒ h r ial h . ik , with r a sound over-approximation of the aliasing information corresponding to the execution of p. Proof. The key observation is that, due to the execution of loops and/or recursive calls, expressions can infinitely grow in a regular fashion. Hence, a lasso is always reached. Consequently, the control structure generating the infinite behaviour is removed from the k-cell, according to the associated K-specification for loops and/or recursive calls. This guarantees termination. Moreover, recall that the regular expressions replacing the current alias information are a sound overapproximation, according to Lemma 2. ⊓ ⊔ Observe that the RL-based machinery can simulate precisely the “cutting at length L” technique in [14]. It suffices to disable the rules (♣) and stop the rewriting after L steps. The naturalness of applying the resulted aliasing framework is illustrated in the example in Appendix D, for the case of two mutually recursive functions. 4 Integration in SCOOP In this section we provide a brief overview on the integration and applicability of the alias calculus in SCOOP [21] – a simple object-oriented programming model for concurrency. Two main characteristics make SCOOP simple: 1) just one keyword programmers have to learn and use in order to enable concurrent executions, namely, separate and 2) the burden of orchestrating concurrent executions is handled within the model, therefore reducing the risk of correctness issues. In short, the key idea of SCOOP is to associate to each object a processor, or handler (that can be a CPU, or it can also be implemented in software, as a process or thread). Assume a processor p that performs a call o.f () on an object o. If o is declared as “separate”, then p sends a request for executing f () to q – the handler of o (note that p and q can coincide). Meanwhile, p can continue. Processors communicate via channels. The Maude semantics of SCOOP in [21] is defined over tuples of shape hp1 :: St1 | . . . | pn :: Stn , σi where, pi denotes a processor (for i ∈ {1, . . . , n}), Sti is the call stack of pi and σ is the state of the system. States hold the information about the heap (which is a mapping of references to objects) and the store (which includes formal arguments, local variables, etc.). The assignment instruction, for instance, is formally specified as the transition rule: a is fresh Γ ⊢ hp :: t : = s; St, σi → hp :: eval(a, s); wait(a); write(t, a.data); St, σi (19) where, intuitively, “eval(a, s)” evaluates s and puts the result on channel a, “wait(a)” enables processor p to use the evaluation result, “write(t, a.data)” sets the value of t to a.data, St is a call stack, and Γ is a typing environment [23] containing the class hierarchy of a program and all the type definitions. At this point it is easy to understand that the K-rule for assignments h r ial h t : = s . . .ik (r1 − t)[t = (r1 /s − t)] − ot . with r1 = r[ot = t] (15) can be straightforwardly integrated in (19) by enriching the state structure with a new field encapsulating the alias information, and considering instead the transition Γ ⊢ hp :: t : =s; St, σi → hp :: eval(a, s); wait(a); write(t, a.data); St, σ ′ i where σ.aliases = r σ ′ .aliases = (r1 − t)[t = (r1 /s − t)] − ot with r and r1 as in (15). The integration of all the K-rules of the alias calculus on top of the Maude formalization of SCOOP can be achieved by following a similar approach. For a case study, one can download the SCOOP formalization at: https://dl.dropboxusercontent.com/u/1356725/SCOOP.zip and run the command > maude SCOOP.maude ..\examples\aliasing-linked_list.maude corresponding to the code in (1): x : = y; loop x : = x.next end. The console outputs the aliased expressions for a rewriting of depth 100 which include, as expected, pairs of shape [x, y.nextk ]. (The over-approximating mechanism for sequential settings is still to be implemented.) As can be observed based on the code in aliasing-linked_list.maude, in order to implement our applications in Maude, we use intermediate (still intuitive) representations. For instance, the class structure defining a node in a simple linked list, with filed next is declared as: class ’NODE create {’make} ( attribute { ’ANY } ’next : [?, . , ’NODE] ; ) [...] end ; where ’next : [?, . , ’NODE] stands for an object of type NODE, that is handled by the current processor (.) and that can be Void (?), and ’make plays the role of a constructor. The intermediate representation of the instruction block in (1) is: assign (’x, ’y); until False loop ( assign (’x, ’x . ’next(nil)) ; ) end ; We include in Appendix E the whole class structure corresponding to (1), together with (the relevant parts of) the console output. For a detailed description of SCOOP and its Maude formalization we refer the interested reader to the work in [21]. 4.1 Further applications of the alias calculus Apart from providing an alias analysis tool, the alias calculus can be exploited in order to build an abstract semantics of SCOOP. For example, an abstraction of the assignment rule (15) would omit the evaluation of the right-hand side of the assignment t : = s and the associated message passing between channels: · Γ ⊢ hp :: t : = s; St, σi → hp :: St, σ ′ i where σ.aliases = r σ ′ .aliases = (r1 − t)[t = (r1 /s − t)] − ot with r and r1 as in (15). This way one derives a simplified, reduced semantics of SCOOP, more appropriate for model checking, for instance; the current SCOOP formalization in Maude is often too large for this purpose. A survey on abstracting techniques on top of Maude executable semantics is provided in [18]. Furthermore, the aliasing information could be used for the so-called “deadlocking” problem, where two or more executing threads are each waiting for the other to finish. In the context of SCOOP, this is equivalent to identifying whether a set of processors reserve each other circularly (i.e., there is a Coffman deadlock). This situation might occur, for instance, in a Dinning Philosophers scenario, where both philosophers and forks are objects residing on their own processors. The difficulty of identifying such deadlocks stems from the fact that SCOOP processors are known from object references, which may be aliased. 5 Conclusions In this paper we provide an extension of the alias calculus in [14] from finite alias relations to infinite ones corresponding to loops and recursive calls. Moreover, we devise an associated executable specification in the K semantic framework [26]. In Theorem 1 we show that the RL-based machinery implements an algorithm that always terminates with a sound over-approximation of “may aliasing”, in non-concurrent settings. This is achieved based on the sound (finitely representable) over-approximation of (“lasso shaped”) alias expressions in terms of regular expressions, as in Lemma 2. We also discuss the integration and applicability of the alias calculus on top of the Maude formalization of SCOOP [21]. An immediate direction for future work is to identify interesting (industrial) case studies to be analyzed using the framework developed in this paper. We are also interested in devising heuristics comparing the efficiency and the precision (e.g., the number of false positives introduced by the alias approximations) between our approach and other aliasing techniques. In this respect, we anticipate that the rewriting modulo associativity, together with the pattern matching capabilities of Maude will accelerate the identification of the “lasso” properties and the corresponding over-approximating regular alias expressions. This could eventually provide an effective reasoning apparatus for the “may aliasing” problem. Another research direction is to derive alias-based abstractions for analyzing concurrent programs. We foresee possible connections with the work in [12] on concurrent Kleene algebra formalizing choice, iteration, sequential and concurrent composition of programs. The corresponding definitions exploit abstractions of programs in terms of traces of events that can depend on each other. Thus, obvious challenges in this respect include: (i) defining notions of dependence for all the program constructs in this paper, (ii) relating the concurrent Kleene operators to the semantics of the SCOOP concurrency model and (iii) checking whether fixed-points approximating the aliasing information can be identified via fixed-point theorems. Furthermore, it would be worth investigating whether the graph-based model of alias relations introduced in [14] can be exploited in order to derive finite K specifications of the extended alias calculus. In case of a positive answer, the general aim is to study whether this type of representation increases the speed of the reasoning mechanism, and why not – its accuracy. With the same purpose, we refer to a possible integration with the technique in [5] that handles point-to graphs via a stack-based algorithm for fixed-point computations. We are also interested to what extent an abstract semantics based on aliases for SCOOP can be exploited for building more efficient analysis tools such as deadlock detectors, for instance. A survey on similar techniques that abstract away from possibly irrelevant information w.r.t. the problem under consideration is provided in [18]. Acknowledgements We are grateful for valuable comments to Măriuca Asăvoae, Alexander Kogtenkov, José Meseguer, Bertrand Meyer, Benjamin Morandi and Sergey Velder. The research leading to these results has received funding from the European Research Council under the European Union’s Seventh Framework Programme (FP7/2007-2013) / ERC Grant agreement no. 291389. References 1. E. Albert, P. Arenas, S. Genaim, and G. Puebla. Field-sensitive value analysis by field-insensitive analysis. In Proceedings of the 2Nd World Congress on Formal Methods, FM ’09, pages 370–386, Berlin, Heidelberg, 2009. Springer-Verlag. 2. I. M. Asavoae. Abstract semantics for alias analysis in K. Electr. Notes Theor. Comput. Sci., 304:97–110, 2014. 3. A. Bouajjani, J. Esparza, and O. Maler. Reachability analysis of pushdown automata: Application to model-checking. In CONCUR, pages 135–150, 1997. 4. M. Burke, P. Carini, J.-D. Choi, and M. Hind. Flow-insensitive interprocedural alias analysis in the presence of pointers. In K. Pingali, U. Banerjee, D. Gelernter, A. Nicolau, and D. Padua, editors, Languages and Compilers for Parallel Computing, volume 892 of Lecture Notes in Computer Science, pages 234–250. Springer Berlin Heidelberg, 1995. 5. D. R. Chase, M. N. Wegman, and F. K. Zadeck. Analysis of pointers and structures. In PLDI, pages 296–310, 1990. 6. J.-D. Choi, M. Burke, and P. Carini. Efficient flow-sensitive interprocedural computation of pointer-induced aliases and side effects. In Proceedings of the 20th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’93, pages 232–245, New York, NY, USA, 1993. ACM. 7. P. Cousot and R. Cousot. Abstract interpretation and application to logic programs. J. Log. Program., 13(2&3):103–179, 1992. 8. A. Diwan, K. S. McKinley, and J. E. B. Moss. Type-based alias analysis. SIGPLAN Not., 33(5):106–117, May 1998. 9. M. Emami, R. Ghiya, and L. J. Hendren. Context-sensitive interprocedural pointsto analysis in the presence of function pointers. In Proceedings of the ACM SIGPLAN 1994 Conference on Programming Language Design and Implementation, PLDI ’94, pages 242–256, New York, NY, USA, 1994. ACM. 10. M. Hind. Pointer analysis: haven’t we solved this problem yet? In PASTE, pages 54–61, 2001. 11. M. Hind, M. Burke, P. Carini, and J.-D. Choi. Interprocedural pointer alias analysis. ACM Trans. Program. Lang. Syst., 21(4):848–894, July 1999. 12. C. A. R. Hoare, B. Möller, G. Struth, and I. Wehrman. Concurrent Kleene algebra. In CONCUR 2009 - Concurrency Theory, 20th International Conference, CONCUR 2009, Bologna, Italy, September 1-4, 2009. Proceedings, pages 399–414, 2009. 13. S. C. Kleene. Representation of events in nerve nets and finite automata. In C. Shannon and J. McCarthy, editors, Automata Studies, pages 3–41. Princeton University Press, Princeton, NJ, 1956. 14. A. Kogtenkov, B. Meyer, and S. Velder. Alias and change calculi, applied to frame inference. CoRR, abs/1307.3189, 2013. 15. W. Landi. Undecidability of static analysis. ACM Lett. Program. Lang. Syst., 1(4):323–337, Dec. 1992. 16. W. Landi and B. G. Ryder. Pointer-induced aliasing: A problem classification. In Proceedings of the 18th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’91, pages 93–103, New York, NY, USA, 1991. ACM. 17. J. R. Larus and P. N. Hilfinger. Detecting conflicts between structure accesses. In PLDI, pages 21–34, 1988. 18. J. Meseguer and G. Rosu. The rewriting logic semantics project: A progress report. In Fundamentals of Computation Theory - 18th International Symposium, FCT 2011, Oslo, Norway, August 22-25, 2011. Proceedings, pages 1–37, 2011. 19. B. Meyer. Eiffel: The Language. Prentice-Hall, 1991. 20. A. Miné. Field-sensitive value analysis of embedded c programs with union types and pointer arithmetics. In Proceedings of the 2006 ACM SIGPLAN/SIGBED Conference on Language, Compilers, and Tool Support for Embedded Systems, LCTES ’06, pages 54–63, New York, NY, USA, 2006. ACM. 21. B. Morandi, M. Schill, S. Nanz, and B. Meyer. Prototyping a concurrency model. In ACSD, pages 170–179, 2013. 22. E. M. Myers. A precise inter-procedural data flow algorithm. In Proceedings of the 8th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’81, pages 219–230, New York, NY, USA, 1981. ACM. 23. P. Nienaltowski. Practical Framework for Contract-based Concurrent Objectoriented Programming. ETH, 2007. 24. M. O. Rabin and D. Scott. Finite automata and their decision problems. IBM J. Res. Dev., 3(2):114–125, Apr. 1959. 25. V. Robert and X. Leroy. A formally-verified alias analysis. In CPP, pages 11–26, 2012. 26. G. Rosu and T. F. Serbanuta. K overview and SIMPLE case study. In Proceedings of International K Workshop (K’11), ENTCS. Elsevier, 2013. To appear. 27. T.-F. Serbanuta and G. Rosu. K-Maude: A rewriting based tool for semantics of programming languages. In WRLA, pages 104–122, 2010. 28. M. Sridharan, S. Chandra, J. Dolby, S. J. Fink, and E. Yahav. Alias analysis for object-oriented programs. In Aliasing in Object-Oriented Programming, pages 196–232. 2013. 29. R. P. Wilson and M. S. Lam. Efficient context-sensitive pointer analysis for C programs. In Proceedings of the ACM SIGPLAN 1995 Conference on Programming Language Design and Implementation, PLDI ’95, pages 1–12, New York, NY, USA, 1995. ACM. A Regular expressions in sequential settings In this section we provide the proof of Lemma 1; we proceed by demonstrating a series of intermediate results. Remark 2. We first observe that the operations r/s, r − x, dot-completeness and r[x = u] introduced in Section 2 preserve the regularity of an alias relation r. Then, we define a notion of finite execution control blocks: p :: = create x | forget x | t : = s | p ; p | then p else p end | call f (l) | x.call f (l) (20) where f stands for a non-recursive function. It is easy to see that the execution of control blocks as in (20) preserve the regularity of alias relations as well. Lemma 3. For all regular alias relations r and p a finite-execution control block, in a sequential setting, it holds that r » p is also regular. Proof. The proof follows immediately, by induction on the structure of p and Remark 2. Base cases are: create x, forget x and t : = s. For function calls, the result is a consequence of their corresponding unfolding, based on the definitions in (8). Remark 3. W.r.t. may aliasing, recursive calls can be handled via loops. Consider, for instance the recursive function f (x) { B1 ; f (y); B2 } where B1 and B2 are instruction blocks built as in (3). It is intuitive to see that computing the may aliases resulted from the execution of f (x) reduces executing unfoldings of shape: loop B1 end; loop B2 end. Moreover, unbounded program executions also preserve regularity. Lemma 4. For all regular alias relations r and p a control block that can execute unboundedly, in a sequential setting, it holds that r » p is also regular. Proof. The proof follows by induction on the number of nested loops in p and Remark 3. Then, the result in Lemma 1 follows immediately by Lemma 3 and Lemma 4. B Sound over-approximations In what follows we provide the proof of Lemma 2: Consider r and r′ two alias relations, and p a basic control block. If r » p = r′ and lasso(r, r′ ) = true, then the following holds for all n ≥ 1: r » pn ∈ reg(r, r′ ). Proof. We proceed by induction on n. – Base case: n = 1. By hypothesis it holds that lasso(r, r′ ) = true. Hence, according to the definition of lasso(−, −) in (12), there exists a one-to-one correspondence of the shape [x1 y1 z1 , x2 y2 z2 ] ∈ r iff [x1 y1 y1 z1 , x2 y2 y2 z2 ] ∈ r′ between the elements of r and r′ , respectively. Consequently, by the definition of reg(−, −) in (13), it is easy to see that r′ ∈ reg(r, r′ ). – Induction step. Fix a natural number n and suppose that r » pk ∈ reg(r, r′ ) (21) for all k ∈ {1, . . . , n}. We want to prove that (21) holds also for k = n + 1. We continue by “reductio ad absurdum”. Consider r = r » pn ∈ reg(r, r′ ), and assume that r » p 6∈ reg(r, r′ ) (22) Clearly, the execution of p when starting with r identifies an alias pair which is not in reg(r, r′ ). Given that p is a basic control block as in (10), and based on the corresponding definitions in (4)–(9), it is not difficult to observe that the regular structure of the alias information can only be broken via a new added pair (t, s′ ) associated to an assignment t : = s within p. Let p = C[t : = s], where C is a context built according to (10), and t : = s is the upper-most assignment instruction in the syntactic tree associated to p, that introduces a pair [t, s′ ] which is not in reg(r, r′ ). Assume that r̃ is the intermediate alias relation obtained by reducing r » C[t : = s] according to the equations (4)–(9), before the application of the assignment axiom corresponding to t : = s. Note that t : = s was executed at least once before, as n ≥ 1, and observe that r̃ ∈ reg(r, r′ ). Hence, we identify two situations in the context of the aforementioned execution: (a) either all the newly added pairs corresponding to the assignment t : = s complied to the regular structure, or (b) each new pair [t′ , s′ ] that did not fit the regular pattern was later removed via a subsequent instruction “create u” or “forget u” within p, with u a prefix of t′ or s′ . If the case (a) above was satisfied, then, based on the definition of dotcompleteness, a pair (t, s′ ) ∈ (r˜1 − t)[t = r˜1 /s − t] − ot, where r˜1 = r̃[ot = t] cannot break the regular pattern of the alias expressions either. For the case (b) above, all the “non-well-behaved” new pairs will be again removed via a subsequent “create u” or “forget u” within p. Therefore, the assumption in (22) is false, so it holds that: r » p = r » pn+1 ∈ reg(r, r′ ). ⊓ ⊔ C Alias calculus in K – complete specification In this section we provide the full specification of the alias calculus in K. Recall that, as a convention, we mark with (♣) the rules that are sound only for nonconcurrent contexts, based on Lemma 2. The following K-rules are straightforward, based on the axioms (4)–(9) in Section 2.1. Namely, the rule implementing an instruction p ; q simply forces the sequential execution of p and q by positioning p y q at the top of the continuation cell: h p ; q . . .ik pyq (23) Handling create x and forget x complies to the associated definitions. Namely, it updates the current alias relation by removing all the pairs having (at least) one element with x as prefix. In addition, it also pops the corresponding instruction from the continuation stack: h r ialh create x . . .ik r−x . h r ialh forget x . . .ik r−x . (24) The assignment rule restores the current alias relation according to its axiom in (9), and removes the assignment instruction from the top of the k-cell: h r ial h t : = s . . .ik (r1 − t)[t = (r1 /s − t)] − ot . with r1 = r[ot = t] (25) The K-implementation of a then p else q end statement is more sophisticated, as it instruments a stack-based mechanism enabling the computation of the union of alias relations r » p ∪ r » q in three steps. First, we define the K-rule: h r ial h then p else q end . . .ik h . . . .ibkt-te h r, p it h r, q ie p et q ee (26) saving at the top of the back-tracking stack h−ibkt-te the initial alias relation r to be modified by both p and q, via two cells hr, pit and hr, qie , respectively. Note that the original instruction in the k-cell is replaced by a meta-construction marking the end of the executions corresponding to the then and else branches with et and ee , respectively. Second, whenever the successful execution of p (signaled by et ) at the top of the k-cell) builds an alias relation r′ , the execution of q starting with the original relation r is forced by replacing r′ with r in h−ial , and by positioning q ee at the top of the k-cell. The new alias information after p, denoted by hr′ , pit , is updated in the back-tracking cell: h r ′ ial h r et q ee q ee . . .ik h h r, p it h r, q ie . . .ibkt-te h r ′ , p it (27) Eventually, if the successful execution of q (marked by ee at the top of h−ik ) produces an alias relation r′′ , then the final alias information becomes r′ ∪ r′′ , where r′ is the aliasing after p, stored as showed in (27). The corresponding back-tracking information is removed from h−ibkt-te , and the next program instruction is enabled in the k-cell: h r ′′ ial h r ′ ∪ r ′′ ee . . . .ik h h r ′ , p it h r, q ie . . .ibkt-te . (28) For loop p end, we utilize a meta-construction p l loop p end simulating the set union in (6), and a back-tracking stack h−ibkt-l collecting the alias information obtained after each execution of p. Moreover, the K-implementation exploits the result in Lemma 2. Whenever a “lasso” is reached, the infinite rewriting is prevented by resuming the infinite application of p in terms of a sound over-approximating alias relation. The K-rules are as follows. First, the aforementioned unfolding is performed, and the alias relation before p is stored in the back-tracking cell as hrial-o hpil : h r ial h loop p end . . .ik h . . . .ibkt-l h r ial-o h p il p l loop p end (29) If the alias relation r′ obtained after the successful execution of p (marked by l at the top of the continuation) is not a lasso of the aliasing r before p (previously stored in h−ibkt-l ) then p is constrained to a new execution by becoming the top of the k-cell, and r′ is memorized for back-tracking: h r ′ ial h l loop p end . . .ik h h r ial-o h p il . . .ibkt-l if not lasso(r, r ′ ) (♣) (30) h r ′ ial-o h p il p l loop p end Last, if a lasso is reached after the execution of p, then the current aliasing is soundly replaced by a “regular” over-approximation reg(r, r′ ), the corresponding back-tracking information is removed from h−ibkt-l and the loop instruction is eliminated from the k-cell: h r′ ialh reg(r, r ′ ) l loop p end . . .ikh h r ial-o h p il . . .ibkt-l if lasso(r, r ′ ) (♣) (31) . . For handling function calls such as call f (l) we use a meta-construction | f | f . Here | f | stands for the body of f and f marks the end of the corresponding execution. Moreover, a stack h−ibkt-cf is utilized in order to store the alias information before each (possibly recursive) call of f , with the purpose of identifying the lassos generated by the (possibly repeated) execution of f . In order to guarantee a sound implementation of (mutually) recursive calls, both f and h−ibkt-cf are parameterized by f – the name of the function. An example illustrating this reasoning mechanism is provided in Appendix D. The first K rule for handling function calls matches the associated axiom in (8): the alias information is set to r[f • :l], whereas the next instructions to be executed are given by | f |. Note that the original aliasing is retained in the (initially empty) back-tracking cell via hrial-o . h . ibkt-cf r ial h call f (l) . . .ik h r[f • :l] h r ial-o |f | f (32) Remark 4. Observe that the back-tracking cell does not need to be parameterized by the actual argument list l of f . Each such argument is anyways replaced in the current alias relation r by its counterpart in the formal argument list of f . In short: r becomes r[f • :l]. A successful execution of call f (l) is distinguished by the occurrence of f at the top of the continuation stack. If this is the case, then the corresponding back-tracking alias information is removed from h−ibkt-cf and the next program instruction (if any) is enabled at the top of the k-cell: h r ′ ial h f . . . .ik h h r ial-o . . .ibkt-cf . (33) Recursive calls are treated by means of two K-rules. Note that a recursive context is identified whenever the current program instruction is of shape call f (l) and the associated back-tracking structure is not empty, i.e., rule (32) was previously applied. Then, if the recursive call of f when starting with r produces a lasso r′ , the execution of f (l) is stopped by soundly over-approximating the alias information with reg(r, r′ ), according to Lemma 2, and by removing call f (l) from the k-cell: h r′ ial h call f (l) . . .ik h h r ial-o . . .ibkt-cf if lasso(r, r ′ ) (♣) reg(r, r ′ ) . (34) If a lasso is not reached, then the body of f is executed once more, and the current aliasing is pushed to the back-tracking cell: h r ′ ial h call f (l) . . .ik h . h r ial-o . . .ibkt-cf if not lasso(r, r ′ ) (♣) h r ′ ial-o |f | f (35) Qualified calls x.call f (l) are handled by two K-rules as follows. First, based on the definition in (8), the “negative variable” x′ transposing the context of the call to to the context of the caller is distributed to the elements of the initial alias relation r, and to l – the argument list of f . Moreover, a meta-construction qf is utilized in order to mark the end of the qualified call in the continuation cell, similarly to the rule (32). The caller is stored in a back-tracking stack h . ibkt-qf also parameterized by f – the name of the function. The current instruction in the k-cell becomes call f (x′ .l), as expected: x.call f (l) h r ial h x′ .r call f (x′ .l) qf . . .ik h . ibkt-qf h x if (36) Second, when the successful termination of the qualified call is signaled by qf at the top of the k-cell, the corresponding stored caller is distributed to the current alias relation and removed from the back-tracking cell. The next instruction in the continuation cell is released by eliminating the top qf : h r ial h x.r D qf . . . .ik h h x if . . .ibkt-qf . (37) The K-machinery by example For an example, in this section we show how the K-machinery developed in Section 3 can be used in order to extract the alias information for the case of two mutually recursive functions defined as: f (x) { x : = x.a ; call g(x) } g(x) { x : = x.b ; call f (x) } We assume that x is an object of a class with two fields a and b, respectively. We consider a sequential setting. At first glance it is easy to see that the execution of call f (x), when starting with an empty alias relation r, produces the alias expressions: [x, x.(a.b)∗ ] [x.a, x.(a.b)∗ .a] [x.b, x.(a.b)∗ .b] (38) The associated reasoning in K is depicted in the figure below. The whole procedure starts with an empty alias relation r = ∅, and call f (x) in the continuation stack. Then, the corresponding K rules (for handling assignments and function calls) are applied in the natural way. A lasso is reached after two calls of f (x) that, consequently, determine two calls of g(x) – identified by g f g f in the k-cell. This triggers the application of rule (34) enabling the “regular” over-approximation as in Lemma 2. Our example also illustrates the importance of isolating the back-traced alias information in cells of shape h . ibkt-cf parameterized by the (possibly recursive) function f . More explicitly, rule (34) is soundly applied by identifying the aforementioned lasso based on: the current alias relation r4 , the recursive call f (l) at the top of the continuation, and the back-traced aliasing h h r2 ial-o . . .ibkt-cf associated to the previous executions of f (l). As introduced in (12), an alias relation r′ is a lasso of a relation r whenever there is a one-to-one correspondence between their elements as follows: [x1 y1 z1 , x2 y2 z2 ] ∈ r iff [x1 y1 y1 z1 , x2 y2 y2 z2 ] ∈ r′ . The current alias relation r4 = {[x, x.a.b.a.b], [x.a, x.a.b.a.b.a], [x.b, x.a.b.a.b.b]}, before applying rule (34), is a lasso of r2 = {[x, x.a.b], [x.a, x.a.b.a], [x.b, x.a.b.b]}. The aforementioned one-to-one correspondence is summarized in the following table: [x1 y1 z1 , x2 y2 z2 ] ∈ r2 iff [x1 y1 y1 z1 , x2 y2 y2 z2 ] ∈ r4 x1 y1 z1 x2 y2 z2 [x, x.a.b] ∈ r2 iff [x, x.a.b.a.b] ∈ r4 x ε ε x a.b ε [x.a, x.a.b.a] ∈ r2 iff [x.a, x.a.b.a.b.a] ∈ r4 x ε a x a.b a [x.b, x.a.b.b] ∈ r2 iff [x.b, x.a.b.a.b.b] ∈ r4 x ε b x a.b b Here ε stands for the empty alias expression. Moreover, according to rule (34), the lasso shaped by r2 and r4 also causes the (otherwise infinite) recursive calls to stop, as call f (l) is eliminated from the top of the k-cell. Hence, the rewriting process finishes with a sound overapproximation reg(r2 , r4 ) replacing the current alias relation (cf. Lemma 2), defined precisely as in (38). h r ial h call f (x) ik h . ibkt-cf h . ibkt-cg ⇓ (32) h r ial h x : = x.a; call g(x) f h h r ial-o ibkt-cf h . ibkt-cg ik ⇓ (25) h r1 ial h call g(x) f ik h h r ial-o ibkt-cf h . ibkt-cg where r1 = {[x, x.a], [x.a, x.a.a], [x.b, x.a.b]} ⇓ (35) h r1 ial h x : = x.b; call f (x) g h h r ial-o ibkt-cf h h r1 ial-o ibkt-cg f ik ⇓ (25) h r2 ial h call f (x) g f ik h h r ial-o ibkt-cf h h r1 ial-o ibkt-cg where r2 = {[x, x.a.b], [x.a, x.a.b.a], [x.b, x.a.b.b]} ⇓ (35) h r2 ial h x : = x.a; call g(x) f h h r2 ial-o h r ial-o ibkt-cf h h r1 ial-o ibkt-cg g f ik ⇓ (25) h r3 ial h call g(x) f g f ik h h r2 ial-o h r ial-o ibkt-cf h h r1 ial-o ibkt-cg where r3 = {[x, x.a.b.a], [x.a, x.a.b.a.a], [x.b, x.a.b.a.b]} ⇓ (35) h r3 ial h x : = x.b; call f (x) g f h h r2 ial-o h r ial-o ibkt-cf h h r3 ial-o h r1 ial-o ibkt-cg g f ik ⇓ (25) h r4 ial h call f (x) g f g f ik h h r2 ial-o h r ial-o ibkt-cf h h r3 ial-o h r1 ial-o ibkt-cg where r4 = {[x, x.a.b.a.b], [x.a, x.a.b.a.b.a], [x.b, x.a.b.a.b.b]} ⇓ (34) h reg(r2 , r4 ) ial h g f g f ik h h r2 ial-o h r ial-o ibkt-cf h h r3 ial-o h r1 ial-o ibkt-cg ⇓ (*)(33) ∗ ∗ h {[x, x.(a.b) ], [x.a, x.(a.b) .a], [x.b, x.(a.b)∗ .b]} ial h . ik h . ibkt-cf h . ibkt-cg Fig. 1. Aliasing and mutual recursion in K. E Example of aliasing in Maude The intermediate class-based representation (in aliasing-linked_list.maude) corresponding to the example x : = y; loop x : = x.next end is given as: (class ’LINKED_LIST_TEST create { ’make } ( procedure { ’ANY } ’make ( nil ) require True local ( ’x : [?, . , ’NODE] ; ’y : [?, . , ’NODE] ; ) do ( assign (’x, ’y); until False loop ( assign (’x, ’x . ’next(nil)) ; ) end ; ) ensure True rescue nil end ; ) invariant end) ; True class ’NODE create {’make} ( attribute { ’ANY } ’next : [?, . , ’NODE] ; ) invariant True end ; As can be seen from the code above, the syntax enables expressing Eiffellike properties of classes by using assertions s.a. preconditions (introduced by the keyword require), postconditions (through the keyword ensure) and class invariants. The “entry point” of the program corresponds to the function ’make in the (main) class ’LINKED_LIST_TEST and is set via: settings(’LINKED_LIST_TEST, ’make, false, aliasing-on) . Observe that the flag for performing the alias analysis is switched to “on”. In ’LINKED_LIST_TEST, two local variables x and y of type NODE are declared as running on the current processor (.), i.e., they are not separate. The instruction assign(’x, ’y), for instance, corresponds to the assignment x : = y. The class defining a NODE structure (in a linked list) simply consists of a (non-separate) field ’next of type NODE. We run the example by executing the command: > maude SCOOP.maude ..\examples\aliasing-linked_list.maude The relevant parts of the corresponding Maude output are as follows: \||||||||||||||||||/ --- Welcome to Maude --/||||||||||||||||||\ Maude 2.6 built: Mar 31 2011 23:36:02 Copyright 1997-2010 SRI International [...] ========================================== rewrite [100] in SYSTEM : [...] {0}proc(1) :: until False loop assign(’x, ’x . ’next(nil)) ; end ; [...], 100, aliasing-on ({[’x ; ’y . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next]} U {[’x . ’next ; ’y . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next . ’next]}) [...] state [...] heap [...] store [...] end In short, after 100 rewriting steps, the current processor {0}proc(1) has the execution corresponding to loop x : = x.next end on top of its instruction stack, and the aliasing information contains (the dot-complete closure of) the relation {[x, y.next42 ]}. Moreover, the output displays the contents of the current system state, by providing information on the heap and store, as formalized in [21].
6cs.PL
K-theory and K-homology of the wreath products of finite with free groups Sanaz Pooya arXiv:1707.05984v1 [math.OA] 19 Jul 2017 July 20, 2017 Abstract L Consider the wreath product Γ = F o Fn = Fn F o Fn , with F a finite group and Fn the free group on n generators. We study the Baum-Connes conjecture for this group. Our aim is to explicitly describe the Baum-Connes assembly map for F o Fn . To this end, we compute the topological and the analytical K-groups and exhibit their generators. Moreover, we present a concrete 2-dimensional model for EΓ. As a result of our K-theoretic computations, we obtain that K0 (C∗r (Γ)) Lis the free abelian group of countable rank with a basis consisting of projections in C∗r ( Fn F ) and K1 (C∗r (Γ)) is the free abelian group of rank n with a basis consisting of the unitaries coming from the free group. 1 Introduction The Baum-Connes conjecture, at the fascinating intersection of several areas in mathematics, was stated in 1982 by P. Baum and A. Connes. For a group G, it proposes a link via a certain assembly map between K-theory of the reduced group C ∗ -algebra C∗r (G) and the classifying space for proper actions EG. Formally, it states that the assembly map G ∗ µG i : Ki (EG) → Ki (Cr (G)) i = 0, 1 is an isomorphism of two abelian groups. The conjecture has been verified in a variety of cases including the huge class of a-Tmenable groups (e.g. amenable groups and free groups), due to Higson and Kasparov [5]. Among many as yet unanswered questions about different aspects of this conjecture, we aim at understanding its stability under semidirect product. Indeed, we would like to understand the conjecture for a group G = N o Q in terms of the status of the conjecture for N and Q. In this respect, at the very beginning of our way, we try to elucidate the isomorphism for some groups for which the conjecture is satisfied. We have started our investigation in [11] and [3]. This work can be considered a generalisation of the latter. Keywords : Wreath product, Baum-Connes conjecture MSC classification: 46L80, 55R40 1 L The group under consideration in this article is the wreath product Γ = F oFn = Fn F o Fn , where F is a finite group and Fn is the free group on n generators. The group F o Fn is a-T-menable as the groups F and Fn are so, see Theorem 1.1 in [2]. Therefore a result by Higson-Kasparov in [5] guarantees that the conjecture holds for this group. The aim of the present article is to describe this isomorphism explicitly. To this end, we compute all involved K-groups and find their generators. The computations on the topological side become possible, thanks to the existence of a 2-dimensional model for EΓ. We add that part of our explicit approach to the conjecture is to shed light on its topological side by providing a concrete 2-dimensional model. Lastly, we show that the assembly map sends generators to generators, as desired. Therefore, the Baum-Connes conjecture is explicitly proved for these groups. Our main tool on the analytical side is the Pimsner-Voiculescu 6-term exact sequence and on the topological side the Martı́nez spectral sequence. We note that the existence of a huge torsion subgroup led us to consider the equivariant K-homology via its link to Bredon homology. In order to formally state our main results, we fix some notation. Let Min F denote the set of (Murray-von Neumann equivalence classes of) minimal projections in C∗r (F ) = CF and let F̂ denote the set of unitary equivalence classes of irreducible representations of F . Moreover, denote by Min F (Fn ) and by F̂ (Fn ) , respectively, the set of finitely supported maps from Fn to Min F and to F̂ . In the theorems below, corresponding to Theorem 3.3 and Theorem 4.2, respectively, we describe the K-theory and K-homology of F o Fn . Theorem A. Let Γ = F o Fn with F a non-trivial finite group. Write Fn = ha1 , . . . , an i. The K-groups of C∗r (Γ) can be described as two free abelian groups. K0 (C∗r Γ) = ZR with R a countable basis indexed by representatives for Fn -orbits in Min F (Fn ) . K1 (C∗r Γ) = Z[a1 ] ⊕ . . . ⊕ Z[an ]. Theorem B. Let Γ = F o Fn with F a non-trivial finite group. Write Fn = ha1 , . . . , an i. The topological K-groups of EΓ can be described as two free abelian groups. KΓ0 (EΓ) = ZR0 with R0 a countable basis indexed by representatives for Fn -orbits in F̂ (Fn ) . KΓ1 (EΓ) = Z[v1 ] ⊕ . . . ⊕ Z[vn ], where [vi ] is the canonical generator of KZ1 (EZ) via the identification Z = hai i. Indeed, the inclusions hai i ,→ Fn ,→ Γ give rise to an inclusion hvi i = KZ1 (EZ) ,→ KF1 n (EFn ) ∼ = KΓ1 (EΓ). Comparing these two sides via the assembly map, the isomorphism for F o Fn is elementarily demonstrated in Theorem 5.1. Additionally, due to K-amenability, we implicitly compute 2 the K-theory of C∗ (Γ). We conclude the article by a remark on the modified trace conjecture. Assuming τ : C∗r (Γ) → C to be the canonical trace on C∗r (Γ), in our case we have that  1  Im τ∗ (K0 (C∗r (Γ)) = Z . |F | Acknowledgements We would like to thank Alain Valette for his useful comments. 2 Preliminaries In this section, we introduce some notations and recall some facts that we will use in the rest of the article. In particular, we introduce our main tools for the topological computations relevant for the left-hand side of the assembly map. 2.1 Topological tools: exact sequences We start with the definition of the main object appearing on the left-hand side of the BaumConnes assembly map. Definition 2.1. For a group G, let F be the family of finite subgroups of G. The classifying space for proper action denoted by EG is a G-CW-complex such that for all elements in F, the isotropy group is contractible and for all other subgroups this is empty. Note that EG is unique up to G-homotopy equivalence. Moreover, an infinite dimensional (G-CW -complex) model for EG always exists. However, the most interesting one is the one with the minimal dimension as it simplifies the homological computations. One of the goals of the Baum-Connes conjecture is to compute the K-theory of C∗r (G) via the G-equivariant K-homology of EG. The homology theory used for the left-hand side of the Baum-Connes conjecture is called Bredon homology, which we briefly recall here. In the context of Baum-Connes conjecture, this is defined in terms of the family F of finite subgroups of G and its coefficients are certain functors. Now, a few words on the nature of these functors. The orbit category OF G is the category whose objects are the homogeneous spaces G/H for H ∈ F and the morphisms are G-maps G/H → G/K. The category of covariant functors from OF G to the category Ab of abelian groups is denoted by G-ModF . The objects of this category are called OF G-modules. The Bredon homology groups of EG with coefficient M in G-ModF is denoted by HFi (EG; M ). We remark that HFi (EG; M ) is isomorphic to HFi (G; M ). The appropriate coefficient module in this context is the OF G-module RC ∈ G-ModF . The value of RC on G/H is the complex representation ring RC (H). We recall that RC (H) is the free abelian group on Ĥ, the dual of H. For more details on Bredon homology see [8]. 3 Despite the fact that the Baum-Connes’ philosophy suggests that computations on the topological side should be easier because we could use standard methods from algebraic topology, such computations can turn to be hard. However, for dim(EG) ≤ 2 we have more explicit results. Theorem 2.2. [[8], Theorem I.3.17] Suppose EG has a model with dim EG = 1, i.e. a tree. Then HFi (G, RC ) = 0 for i > 1, and there is an exact sequence M M RC (Gv ) −→ HF0 (G; RC ) −→ 0, RC (Ge ) −→ 0 −→ HF1 (G; RC ) −→ [v] [e] where the direct sums are respectively taken over the orbits of edges and vertices of the tree EG, and Ge and Gv denote the stabilisers of the edges and the vertices, respectively. Theorem 2.3. [[8], Theorem I.5.27] Suppose there exists a model for EG with dim(EG) ≤ 2. There is a short exact sequence F 0 −→ HF0 (G; RC ) −→ KG 0 (EG) −→ H2 (G; RC ) −→ 0, and an isomorphism HF1 (G; RC ) ' KG 1 (EG). We proceed by introducing another tool, a spectral sequence for group extensions, which will play an important role in our homological computations. This spectral sequence is an analogue of the Lyndon-Hochschild-Serre spectral sequence in group homology, which was developed by Martı́nez in [7]. Consider the group G = N o Q associated with a split short exact sequence 0 −→ N −→ G −→ Q −→ 0. Denote by F the family of finite subgroups of G and by H̄ the family of finite subgroups of Q. Set FN = F ∩ N to be the family of finite subgroups of N . Consider the pull back of family H̄, that is H = {H ≤ G : N ≤ H and H/N ∈ H̄}. Theorem 5.1 in [7] provides us with a spectral sequence whose second page satisfies F∩− F E2p,q = HH̄ (−; D)) =⇒ E∞ p (Q; Hq p,q = Hp+q (G; D). 2.2 Invariants and co-invariants For a set X, we denote by ZX the free abelian group generated by X. It can be identified with the group of almost everywhere zero functions X → Z. Let M be a G-module. We denote by M G the sub-module of G-invariants of the action and by MG = M/hm − g·m : m ∈ M, g ∈ Gi the module of G-co-invariants. In fact, M G and MG are respectively the largest G-invariant submodule and G-invariant quotient. We recall Lemma 1 in [3]. Remark 2.4. Let G be a countable group, X be a countable G-set, and Y be the set of finite G-orbits in X. The space of invariants and co-invariants of G y ZX can be described as (ZX)G ∼ = ZY, (ZX)G ∼ = Z(G\X). 4 Let R be a set of representatives for the orbit space of G on X. Since (ZX)G is a free abelian group, the quotient map ZX → (ZX)G splits, hence we get ZX = hm − g·m : m ∈ ZX, g ∈ Gi ⊕ ZR. Let (F, p) be a finite pointed set. We denote by F (Fn ) the countable set of maps f : Fn → F that are almost everywhere p, or equivalently have finite support. In the above description take X = F (Fn ) with the action of Fn by left multiplication, here, we describe a set of representatives for Fn -orbits in F (Fn ) . Given f ∈ F (Fn ) , we consider the convex hull of its support which is a finite sub-tree S of the Cayley graph of Fn . We present such f by χfS ∈ F (Fn ) in order to take into account the sub-tree S associated to its support. Therefore, for w ∈ Fn ( f (w) w ∈ support f f χS (w) = p otherwise. For a tree T , we define its barycentre as either a vertex or an edge remaining after removing successively the terminal vertices and corresponding edges. Now we say that a tree T is admissible if it is a finite sub-tree of the Cayley graph of Fn = ha1 , . . . , an i with its barycentre either e or an edge [e, ai ] for some i = 1, . . . , n. The next lemma, which is a generalisation of Lemma 2 in [3], will help us to describe the K0 -groups as co-invariants of certain actions. See Theorem 3.3 and Theorem 4.2. Lemma 2.5. Let Fn = ha1 , . . . , an i and let (F, p) be a finite pointed set. Consider the action Fn y F (Fn ) by left multiplication. A countable set R of representatives for Fn -orbits is R = {χfS : f ∈ F (Fn ) , S is admissible }. In particular, Z(F (Fn ) ) = hm − w · m : m ∈ Z(F (Fn ) ), w ∈ Fn i ⊕ ZR = hm − ai · m : m ∈ Z(F (Fn ) ), 1 ≤ i ≤ ni ⊕ ZR. Proof. One sees that no two distinct elements of R belong to the same orbit of this action. We next show that all elements of F (Fn ) lie in the orbit of some element in R. Take f ∈ F (Fn ) . Let S be the sub-tree associated to its support. Its barycentre is either a vertex w or an edge [w, wai ] for i ∈ {1, . . . , n}. In either cases, the sub-tree S̃ := w−1 S is admissible. Therefore, ˜ f belongs to the orbit of χfS̃ , where f˜ ∈ F (Fn ) . We close this section by describing the Baum-Connes assembly map for the locally finite group ⊕Fn F . See Section 4 in [3] for more details. 5 2.3 The Baum-Connes assembly map for the locally finite group ⊕Fn F L L Consider the group Γ = Fn F o Fn with the action Fn y Fn F by left multiplication on the indices. Let Bn = {w ∈ Fn : |w| ≤ n} denote the balls of radius n (with respect to the L word metric) on the Cayley graph of Fn . Write B = Fn F . Let Bn = {f ∈ B : suppf ⊂ Bn } L n correspond to Bn = m 1 F , where mn = |Bn |. We may express the group B as the co-limit of the increasing sequence of Bn ’s. It turns out that the subgroup B plays an essential role in our K-theoretic computations. In particular, as we will see, C∗ (B) provides us with sufficiently many projections to generate K0 (C∗r (Γ)). The conjecture holds for locally finite groups as co-limits are preserved by K-theory and by the assembly map. See Corollary I.5.2 and Theorem I.5.10 in [8]. However, we need a more descriptive picture of its assembly map. Let us first recall the Baum-Connes assembly map for a finite group F . Take π ∈ F̂ and let eπ denote the minimal projection in Mdim π (C). We then have µF0 : RC (F ) → Min F with π 7→ eπ . Analogue to Corollary 1 in [3], we have the following proposition. L Proposition 2.6. Let F be a non-trivial finite group, and B = Fn F . • The free abelian group Z(F̂ (Fn ) ) is isomorphic to KB 0 (EB) via π ∈ F̂ (Fn ) 7−→ ⊗w∈supp π πw ∈ RC (⊕w∈supp π Fw ) ⊂ KB 0 (EB) (where π = (πw )w , the group Fw is the corresponding copy of F in B to the index w ∈ Fn and πw is an irreducible representation of Fw ). • The free abelian group Z(Min F (Fn ) ) is isomorphic to K0 (C∗ B) via p ∈ Min F (Fn ) 7−→ [⊗w∈supp p pw ] ∈ Min(⊕w∈supp p Fw ) ⊂ K0 (C∗ (B)), and in particular the trivial map 1pF ∈ Min F (Fn ) with the constant value pF is mapped to [1], the K0 -class of 1 ∈ C∗ (B). • For π ∈ F̂ (Fn ) , we have µB (π) = ⊗w∈supp π µF (πw ) ∈ K0 (C ∗ (B)). We remark that, through the article, we consider in particular the finite pointed sets (F̂ , 1) and (Min F, pF ), where 1 denotes the trivial representation of F , and pF denotes the projecP tion pF = |F1 | f ∈F f . 3 K-theory of C∗r (Γ) In this section, we explicitly describe the analytical side of the Baum-Connes conjecture for F o Fn . 6 Let A be a C∗ -algebra and as before let Fn = ha1 , . . . , an i. For i = 1, . . . , n, let αi ∈ Aut(A) such that the αi ’s define an action α of Fn on A. For i = 1, . . . , n, denote by ui the unitary uai ∈ C∗r (Fn ) ⊂ B(`2 (Fn )). We assume A is faithfully represented on a Hilbert space H, i.e. A ⊂ B(H). The reduced crossed product A or Fn is generated by 2 hA, u1 , . . . , un : αi (a) = ui au−1 i , 1 ≤ i ≤ n, a ∈ Ai ⊂ B(` (Fn , H)). P Let σ = ni=1 Id −αi . The Pimsner-Voiculescu 6-term exact sequence for reduced crossed products with free groups [[10],Theorem 3.5] is a very convenient tool in K-theory. It provides us with information about the K-theory of such a crossed product in terms of the K-theory of the initial C∗ -algebra Ln (A) i=1 K O 0 σ* / K0 (A) ι∗ / K0 (A or Fn ) σ* Ln ∂1 K1 (A or Fn ) o ι∗ K1 (A) o  ∂0 i=1 K1 (A). In order to describe our analytical K-groups, we need to understand the kernel of the homomorphism σ∗ appearing above. We start with a lemma which is essential for the later computations. Lemma 3.1. Let (F, p) be a finite pointed set and let Fn = ha1 , . . . , an i. For X = F (Fn ) , consider n n M X ψ: ZX → ZX via ψ((fi )1≤i≤n ) = fi − ai ·fi , i=1 i=1 fi (a−1 i x). where ai ·fi (x) = The kernel of ψ is described by Ker(ψ) = Z1p ⊕ . . . ⊕ Z1p , where 1p denotes the constant map with the value p. L Proof. Choose (fi )1≤i≤n ∈ ni=1 ZX. If all fi ’s are Fn -invariant, then obviously (fi )1≤i≤n ∈ Ln Ker(ψ). In particular, 1p is Fn -invariant, hence i=1 Z1p ⊂ Ker(ψ). To conclude the statement of the lemma we need to show that these are in fact the only elements in the kernel. In order to do so we need some preparation. S We may write X = x∈X Fn ·x. For x ∈ X \ {1p }, we have that Fn ·x ∼ = Fn as Fn acts freely on X \ {1p }. For f ∈ ZX and x ∈ X \ {1p }, we define f˜x : Fn → Z by f˜(w) = f (w·x). Note that for 0 6= f ∈ ZX, if f˜x = 0 for all x ∈ X \ {1p }, then f ∈ Z · 1p . Therefore the new statement to prove is 0 6= (fi )1≤i≤n ∈ Ker(ψ) implies ∀x ∈ X \ {1p }, (f˜i x )1≤i≤n = 0. For x ∈ X \ {1p }, we define S= [ supp f˜i x ∪ 1≤i≤n [ 1≤i≤n 7 ai supp f˜i x . We assume S is non-empty. Note that for (fi )1≤i≤n ∈ Ker(ψ) and for w ∈ S, there have to be at least two functions such that w belongs to their supports, otherwise (fi )1≤i≤n can not belong to the kernel. Choose a word w ∈ S ⊂ Fn with the maximum length. The requirements above lead us to consider the following possibilities, for i 6= j ∈ {1, · · · , n}: 1. w ∈ supp f˜ix ∩ ai supp f˜ix , 2. w ∈ supp f˜ix ∩ supp f˜jx , 3. w ∈ ai supp f˜ix ∩ aj supp f˜jx , and 4. w ∈ supp f˜ix ∩ aj supp f˜jx . Claim: We can deduce contradictions from all these cases. Accepting this claim immediately implies that f˜i x = 0 for i = 1, . . . , n. As x ∈ X \ {1p } is chosen arbitrarily, we have that (f˜i x )1≤i≤n = 0 for all such x. Therefore (fi )1≤i≤n ∈ Ln i=1 Z · 1p , which finishes the proof. Proof of the claim: By an argument on the length of words in Fn , we successively show that all of the above possibilities lead to a contradiction. Case 1: If w ∈ supp f˜ix , then ai w ∈ ai supp f˜ix ⊂ S (†). Moreover, by the other assumption in 1, w ∈ ai supp f˜ix . Hence there exists u ∈ supp f˜ix such that w = ai u, equivalently −1 u = a−1 (otherwise, i w (‡). Now on the one hand, (†) forces w to start with ai |ai w| > |w| which is impossible). On the other hand (‡) implies that w starts with any letter except a−1 (if not, then |u| = |a−1 i i w| > |w| which is a contradiction). Therefore this case can not happen. Case 2: Let w be in the supports of f˜ix and f˜jx . Denote by al the starting letter of w. Either l ∈ {i, j} or l 6= i, j. If l = i (respectively, l = j), then aj w ∈ aj supp f˜jx (respectively, ai w ∈ ai supp f˜ix ) provides a longer word in S, which is impossible. Now if l 6= i, j, then ai w ∈ ai supp f˜ix provides a longer word in S which is impossible. Hence this case can not happen. Case 3: If w is in the intersection of the shifted supports, then there exists u ∈ supp f˜ix and v ∈ supp f˜jx such that ai u = w = aj v. Equivalently, we have that a−1 i w = u and −1 aj w = v. If w starts with either ai or aj , then v or u respectively gives us a longer word in S. If w starts in any other letter than these two, then both u and v give a longer word in S. That is a contradiction. Case 4: Let w ∈ supp f˜ix and w ∈ aj supp f˜jx . Then there exists u ∈ supp f˜jx such that a−1 j w = u. This implies that w has to start with aj . Moreover, the assumption at the beginning that w ∈ supp f˜ix together with the fact that w starts with aj guarantee that ai w ∈ ai supp f˜i ⊂ S has a longer length than the maximum. This is impossible. x 8 In the next proposition, we identify the image of the unitary ui ∈ A or Fn , i = 1, . . . , n, under ∂1 in the Pimsner-Voiculescu 6-term exact sequence. This generalises Lemma 2 in [11]. Proposition 3.2. Let A be a unital C∗ -algebra and write Fn = ha1 , . . . , an i. For i ∈ {1, . . . , n}, let αi ∈ Aut(A) define an action α of Fn on A. The boundary map ∂1 : K1 (A or L Fn ) → ni=1 K0 (A) in the Pimsner-Voiculescu 6-term exact sequence behaves in the following way with respect to the unitaries ui ∈ C∗r (Fn ) ⊂ A or Fn ∂1 ([ui ]) = (0, . . . , 0, −[1] , 0, . . . , 0). |{z} i−th slot In our proof, we use the original proof of Pimsner-Voiculescu in [10]. Proof. Let i ∈ {1, . . . , n}. Consider the following subset in Fn Wi = {reduced words in Fn that end with ai }. Note that for i 6= j ∈ {1, . . . , n}, we have that e ∈ Wi , aj Wi = Wi and ai Wi = Wi \ {e}. Assume A ⊂ B(H). Let K ⊂ B(H) denote the C ∗ -algebras of the compact operators on H. We recall that for j = 1, . . . , n we have that uj ∈ C∗r (Fn ) ⊂ A or Fn ⊂ B(`2 (Fn , H)). Consider the compression of these unitaries to `2 (Wi , H) ⊂ `2 (Fn , H). These provide us with n − 1 unitaries Uj , for i 6= j ∈ {1, . . . , n}, and one non-unitary isometry Si . We consider the following C∗ -algebra so-called Toeplitz algebra Tn,i = C∗ ({A, U1 , . . . , Ui−1 , Si , Ui+1 , . . . , Un }) ⊂ B(`2 (Wi , H)). Let Pe = I −Si Si∗ be the projection to δe ⊗ H. The ideal generated by Pe in Tn,i is isomorphic to A ⊗ K. Now we consider the Toeplitz extension Pn,i 0 −→ A ⊗ K −→ Tn,i −→ A or Fn −→ 0. The surjection Pn,i : Tn,i → A or Fn is defined by a 7→ a, Uj 7→ uj , a∈A j ∈ {1, . . . , n}, j 6= i Si 7→ ui . L Let Bn = {(t1 , . . . , tn ) ∈ ni=1 Tn,i : Pn,1 (t1 ) = . . . = Pn,n (tn )} be the fibred product of the C ∗ -algebras Tn,i over A or Fn . Consider the exact sequence introduced on page 153 in [10] 0 −→ (A ⊗ K)n −→ Bn −→ A or Fn −→ 0. 9 Restrict the action α of Fn to the action by its i-th generator, αi , on A and write hai i ∼ = Z. Together with the Toeplitz extension, this exact sequence fits into a commuting diagram / (A ⊗ K)n O 0 / Bn O / A or Fn O /0 / Tn,i /AoZ / 0, ιi /A⊗K 0 with ιi embedding to the i-th component and the middle homomorphism maps a ∈ Tn,i to (a, . . . , a) and maps Si to (Ui , . . . , Ui , Si , Ui , . . . , Ui ). Once we have such a commuting diagram the naturality of the 6-term exact sequence provides us with a commutative diagram in K-theory 8 / K0 (A or Fn ) 8 / K0 (Bn ) ; K0 ((A ⊗ K)n ) O / K0 (Tn,i ) K0 (A ⊗ K) O / K0 (A o Z)  K1 (Bn ) o K1 (A or Fn ) o 8 K1 ((A ⊗ K)n ) ; K1 (A o Z) o 8  K1 (Tn,i ) o K1 (A ⊗ K). The left vertical square fits into the diagram K0 (A) f ∼ = / K0 (A ⊗ K) O / K0 ((A ⊗ K)n ) O K1 (A o Z) / K1 (A or Fn ). ∼ = / Ln i=1 K0 (A ⊗ K) ∼ = / 2 Ln i=1 K0 (A) The triangles at the sides are the natural identifications in K-theory. Hence we get a commutative diagram K0 (A) ιi O ∂1,i / Ln (A) i=1 K O 0 ∂1 / K1 (A or Fn ). K1 (A o hui i) We remark that ∂1,i is the boundary map in the Pimsner-Voiculescu 6-term exact sequence for L Z, that is n = 1 in Fn . Moreover, we have that ∂1 = ni=1 ∂1,i as mentioned in the statement of Theorem 3.5 in [10]. Due to Lemma 2 in [11], we have that ∂1,i ([ui ]) = −[1] ∈ K0 (A) which is mapped by ιi to the i-th component of the n-tuple (0, . . . , 0, −[1], 0, . . . , 0). This finishes the proof. 10 In the next theorem, we explicitly describe the right-hand side of the Baum-Connes conjecture for F o Fn . Theorem 3.3. Let Γ = F o Fn with F a non-trivial finite group. Write Fn = ha1 , . . . , an i. The K-groups of C∗r (Γ) can be described as the free abelian groups K0 (C∗r (Γ)) = ZR with R a countable basis indexed by representatives for Fn -orbits in Min F (Fn ) . K1 (C∗r (Γ)) = Z[u1 ] ⊕ . . . ⊕ Z[un ]. Proof. Let B = ⊕Fn F . We may write C∗r (Γ) = C∗ (B) or Fn . Due to Proposition 2.6, we have N that K0 (C∗ (B)) = Z (Min F (Fn ) ). Moreover, C∗ (B) is an AF-algebra as C∗ (B) = Fn CF hence K1 (C∗ (B)) = 0. Substituting these K-groups in the Pimsner-Voiculescu 6-term exact sequence, we get the diagram Ln F i=1 Z (Min O (Fn ) ) σ* / Z(Min F (Fn ) ) ι∗ / K0 (C∗ Γ) r ∂1 K1 (C∗r (Γ)) o 0 o  ∂0 0. We start from the left-hand side of the diagram. Injectivity of ∂1 implies that K1 (C∗r (Γ)) = L Im ∂1 . By exactness of the diagram at ni=1 Z (Min F (Fn ) ), we have that Im ∂1 = Ker(σ* ). Due to Lemma 3.1, for X = Min F (Fn ) , p = pF and the operator ψ = σ∗ , the kernel is generated by n copies of 1pF ∈ Min F (Fn ) . Thus we have Ker(σ* ) = Z1pF ⊕ · · · ⊕ Z1pF . We recall from Proposition 2.6 that the element 1pF corresponds to [1] ∈ Z(Min F (Fn ) ). Moreover, we observed in Proposition 3.2 that ∂1 ([ui ]) = (0, . . . , −[1], 0, . . . , 0), therefore K1 (Cr∗ (Γ)) = Z[u1 ] ⊕ · · · ⊕ Z[un ]. In order to compute K0 (C∗r (Γ)), we focus on the right-hand side of the diagram. Surjectivity of ι∗ implies that K0 (C∗r (Γ)) = Z (Min F (Fn ) )/Ker ι∗ . By exactness of the diagram at Z (Min F (Fn ) ), we have that Ker ι∗ = Im(σ* ). Therefore K0 (Cr∗ (Γ)) = Z (Min F (Fn ) )/ Im(σ* ) . Furthermore, we identify Im(σ* ) = hf − ai · f : f ∈ Z (Min F (Fn ) ), 1 ≤ i ≤ ni. Using Remark 2.4 and Lemma 2.5, we can then express this quotient as the free abelian group on the (countable) set of representatives for Fn -orbits, that is K0 (C∗r (Γ)) = ZR with the described basis. 11 4 K-homology of EΓ In this section, we first present a suitable chain complex in order to define our homological groups. Later, we construct an explicit 2-dimensional model for EF o Fn and finally, we compute K-homology of EΓ. Ln Let e ∈ Fn denote the neutral element. Consider the free right Fn -module i=1 ZFn . Ln The elements ej = (0, . . . , 0, |{z} e , 0, . . . , 0) ∈ i=1 ZFn , for 1 ≤ j ≤ n, form the canonical j−th slot basis for this free module. Example I.4.3 in [1] provides us with the free resolution 0 −→ n M  δ ZFn −→ ZFn −→ Z −→ 0, i=1 with the augmentation  and the boundary map δ satisfying j ∈ {1, . . . , n}, δ(ej ) = e − aj . N Let M be a left Fn -module. We recall that ZFn ZFn M ∼ = M . Applying the functor N − ZFn M to the above resolution provides us with the chain complex 0 −→ n M δ M −→ M −→ 0. i=1 Note that in the complex above, by abusing the notation of δ, we have that δ(m1 , . . . , mn ) = Pn j=1 mj − aj mj . Therefore, we can write the first two homology groups H0 (Fn ; M ) = M/Im(δ) and H1 (Fn ; M ) = Ker(δ) ≤ n M M. i=1 4.1 A 2-dimensional model for EΓ In this part, we construct a concrete 2-dimensional model for EΓ. As we will see, this model comes from the model for EB. This construction generalises the one for E(F o Z) in [3] and it is derived from [4] for infinite cyclic extensions. Let B be our locally finite group represented as a co-limit of an increasing sequence Bn . We know that EB has a one dimensional model which is a tree T. Let V and E respectively denote the set of vertices and edges of T . The tree T can be described as follows: • V =E= ` n>0 B/Bn • For b ∈ B, the vertices bBn , bBn+1 ∈ V are connected via the edge labelled by bBn ∈ E. 12 Consider the Cayley graph of Fn . Intuitively speaking, the idea of construction is to install the tree T coming from a model for EB, over all vertices of the Cayley graph of Fn and then identify certain subcomplexes of these trees in a compatible way that the resulting complex meets all requirements of being a model for EΓ. Denote by Tw the tree T over the word w ∈ Fn , and by bBn,w a vertex on the n-th level of the filtration of the tree Tw . For w ∈ Fn , we denote by [w, waj ] the edge from w to waj on the Cayley graph of Fn . We define a B-action on Tw : for b, f ∈ B and w ∈ Fn f ·w bBn,w := (w−1 · f )bBn,w , n ∈ N. Note that each Tw is a model for EB as well. For j = 1, . . . , n, we define the gluing maps between neighbouring trees a ϕwj : Tw → Twaj : bBn,w 7→ (a−1 j · b)Bn+1,waj . a It can easily be checked that the ϕwj are B-equivariant, that is a a ϕwj (f ·w bBn,w ) = f ·waj ϕwj (bBn,waj ). For w ∈ Fn , we may identify an edge [w, wai ] with the interval [0, 1]. We define Z̃ := n [ j=1 [ (Tw × [w, waj ]) ∪ n [ j=1 w∈Fn |waj |>|w| [ (Tw × [w, wa−1 j ]). w∈Fn |wa−1 j |>|w| Each non-trivial word on the Cayley graph of Fn has 2n − 1 possibilities of increasing its length. We then identify points on the boundaries of edges in Z̃. More explicitly, if we assume that w ends with ai , then for k, j ∈ {1, . . . , n} with k 6= j 6= i we identify a±1 Tw × [w, wa±1 j ]3 j ±1 (bBn,w , wa±1 j ) ∼ (ϕw (bBn,w ), waj ) (bBn,w , wai ) ∼ (φawi (bBn,w ), wai ) Tw × [w, wai ] 3 ±1 ∈Twaj × [wa±1 j , waj ak ], ∈Twai × [wai , wa2i ]. For the trivial word we hence consider all 2n identifications. We define the mapping telescope Z := Z̃/∼. This quotient space is a candidate to be the desired model for EΓ. The group Γ acts on it. Indeed, the actions of B and Fn on Z combine into the conjugation action β of Γ on Z. To see this, we define the following actions: θ B y Z : θ(f )(bBn,w , t[w, wai ] ) = ((w−1 · f )bBn,w , t[w, wai ] ), η Fn y Z : η(aj )(bBn,w , t[w, wai ] ) = (bBn,aj w , t[aj w, aj wai ] ), 13 where t[w,wai ] denotes a point on the edge [w, wai ], hence t[aj w,aj wai ] is the point moved on the shifted edge. Moreover, η(aj )θ(f )η(aj )−1 (bBn,w , t[w, wai ] ) = η(aj )θ(f )(bBn,a−1 w , t[a−1 w, a−1 wai ] ) j j j = η(aj )(θ(f )(bBn,a−1 w ), t[a−1 w, a−1 wai ] ) j = −1 η(aj )(((a−1 j w) = η(aj )((w −1 j j · f )(bBn, a−1 w ), t[a−1 w, a−1 wai ] ) j j j · (aj · f ))(bBn, a−1 w ), t[a−1 w, a−1 wai ] ) j j j = ((w−1 · (aj · f ))(bBn, w ), t[w, wai ] ) = βaj (f )(bBn, w , t[w, wai ] ). Some observations are pertinent here. • Fn acts freely. • The action η has a fundamental domain D = Sn j=1 Te × [e, aj ). • Vertex stabilisers are finite, hence Γ acts properly on Z. Combining these observations, we have the following proposition. Proposition 4.1. The topological space Z is a 2-dimensional model for EΓ. Proof. It is verbatim the proof of Proposition 2 in [3]. In the rest of this section we compute the K-homology of EΓ, which is the Bredon homology of Γ = BoFn with coefficients in RC . For this we appeal to the Martinez spectral sequence recalled in Preliminary Section. Consider the split exact sequence 0 → B → Γ → Fn → 0 associated to the group Γ = B o Fn . Obviously, the family H̄ of finite subgroups of Fn only consists of the trivial group. Therefore the pull-back of this family only consists of the group B. Hence the second page of this spectral sequence is 2 FB FB Ep,q = HH̃ p (Fn ; Hq (B; RC )) = Hp (Fn ; Hq (B; RC )). Our aim is to compute these groups. We recall that the dimension of models for EB and EFn is one. Hence on the one hand, E2p,q is trivial for p ≥ 2, and on the other hand, by Theorem 2.2, Bredon homology of locally finite group B is trivial for q ≥ 1. Therefore, the only non-zero terms are p = 0, 1 and q = 0. Particularly, E20,0 and E21,0 are the only non-trivial terms of the E 2 -page. This means that the E 2 -page is concentrated in horizontal axis and the spectral sequence collapses in this 2 page as there is no differential. Accordingly, we have E∞ p,q = Ep,q for p, q ≥ 0. We recall that by Martı̀nez’s result, the spectral sequence converges to HFp+q (Γ; RC ). Together with the discussion at the beginning of this part, we may identify Bredon homology groups with 14 homology groups of Fn with coefficient in the free abelian group HF0 B (B; RC ). In particular, we need to compute FB 2 HF0 (Γ; RC ) = E∞ 0,0 = E0,0 = H0 (Fn ; H0 (B; RC )), (1) FB 2 HF1 (Γ; RC ) = E∞ 1,0 = E1,0 = H1 (Fn ; H0 (B; RC )). (2) and In the next theorem we explicitly describe the left-hand side of the Baum-Connes assembly map for F o Fn . Theorem 4.2. Let Γ = F o Fn with F a non-trivial finite group. Write Fn = ha1 , . . . , an i. The topological K-groups of EΓ can be described as two free abelain groups. KΓ0 (EΓ) = ZR0 with R0 a countable basis indexed by representatives for Fn -orbits in F̂ (Fn ) . KΓ1 (EΓ) = Z[v1 ] ⊕ . . . ⊕ Z[vn ], where [vi ] is the canonical generator of KZ1 (EZ) via the identification Z = hai i. Indeed, the inclusions hai i ,→ Fn ,→ Γ give rise to an inclusion hvi i = KZ1 (EZ) ,→ KF1 n (EFn ) ∼ = KΓ1 (EΓ). Proof. Due to Theorem 2.3 and equations in (1) and (2), we have that KΓi (EΓ) ∼ = HFi (Γ; RC ) = Hi (Fn ; HF0 B (B; RC )) for i = 0, 1. In order to compute the homological groups with the appropriate coefficients, we tensor the free resolution, at the beginning of this section, with the Fn -module HF0 B (B; RC ). We recall that by Theorem 2.2 and Proposition 2.6, we have ∼ KB (EB) = ∼ ZF̂ (Fn ) . Therefore, we have that HF0 B (B; RC ) = 0 KΓ0 (EΓ) ∼ = HF0 (Γ; RC ) = ZF̂ (Fn ) ZF̂ (Fn ) . = Im(δ) hf − ai .f : f ∈ ZF̂ (Fn ) , 1 ≤ i ≤ ni Due to Remark 2.4 and Lemma 2.5, KΓ0 (EΓ) is a free abelian group on the orbit space of the action Fn y ZF̂ (Fn ) with the described basis. For computing KΓ1 (EΓ), we appeal to Lemma 3.1. In view of that lemma for X = F̂ (Fn ) and p = 1, the trivial representation of F , we may describe the kernel as the fixed points of the action. More precisely, KΓ1 (EΓ) ∼ ⊕ . . . ⊕ Z11 . = HF1 (Γ; RC ) = Ker(δ) = Z1 | 1 {z } n terms In order to identify 11 in i-th copy with [vi ], we need to make some observations. As the groups Z and Fn are torsion-free, we have that KZ1 (EZ) ∼ = Ki (BZ) ∼ = K1 (S1 ) and _ KF1 n (EFn ) ∼ = Ki (BFn ) ∼ = K1 ( S1 ), n 15 W where BG stands for the classifying space and n S1 denotes the wedge of n-circles. We recall that H1 (Fn ) = Z ⊕ . . . ⊕ Z (n-times), and by Theorem 2.3, KF1 n (EFn ) ∼ = H1 (Fn ; Z). Moreover, due to functionality of K-theory and homology theory we have that S1 induces _ K1 (S1 ) ,→ K1 ( S 1 ), Z → ZF̂ (Fn ) : 1 7→ 11 induces H1 (Fn ; Z) → H1 (Fn ; ZF̂ (Fn ) ). S1 ,→ _ n n Now consider the following composition KZ1 (EZ) ∼ = / K1 (S1 ) 1 / K1 ( nS ) W ∼ = / H1 (Fn ; Z) ∼ / H1 (Fn ; ZF̂ (Fn ) ) = / KΓ (EΓ). 1 Choose ai ∈ Fn , and consider the identification hai i ∼ = Z. By Theorem 2.2 we have that Z ∼ K1 (EZ) = H1 (Z; Z) = Z[vi ]. According to the composition above, we can see that [vi ] 7→ (0, . . . , 0, 11 , 0, . . . , 0) ∈ KΓ1 (EΓ). This finishes the proof. 5 The Baum-Connes assembly map for F o Fn In this section, we explicitly describe the Baum-Connes assembly map for F o Fn , where F is a non-trivial finite group. Theorem 5.1. Let F be a non-trivial finite group. The Baum-Connes assembly map for Γ = F o Fn can be described as: The assembly map µΓ0 : KΓ0 (EΓ) → K0 (C∗r (Γ)) is an isomorphism between two countably generated free abelian groups. The assembly map µΓ1 : KΓ1 (EΓ) → K1 (C∗r (Γ)) is an isomorphism between two free abelian groups of rank n. Proof. µΓ0 is an isomorphism. Let ι : B ,→ Γ be an inclusion. Consider the following diagram Ln σ* B / KB (EB) ι∗ / KΓ (EΓ) /0 0 0 i=1 K0 (EB) Ln i=1 Ln µB 0  ∗ i=1 K0 (C (B)) µB 0 σ*  / K0 (C∗ (B)) ι∗ µΓ 0  / K0 (C∗ Γ) r / 0. Theorem 3.3 together with Theorem 4.2 imply that top and bottom sequences are exact. Moreover, functoriality of the assembly map (Corollary II.1.3 in [8]) yields the Ln B commutativity of the whole diagram. By Proposition 2.6, µB 0 and hence i=1 µ0 are isomorphisms. The Five Lemma then implies that µΓ0 is an isomorphism. 16 µΓ1 is an isomorphism. Consider the comparison diagram µΓ 1 KΓ1 (EΓ)  KF1 n (EFn ) / K1 (C∗ (Γ)) r µF1n  / K1 (C∗ (Fn )) r µZ 1  / K1 (C∗ (Z)).  KZ1 (EZ) Due to Theorem 3.3 and Theorem 4.2, we know that KΓ1 (EΓ) ∼ = K1 (C∗r (Γ)) ∼ = Zn and L n KΓ1 (EΓ) = KF1 n (EFn ) ∼ = i=1 KZ1 (EZ). For i = 1, . . . , n, take the generator [vi ] of the ith summand in KΓ1 (EΓ). Write hai i ∼ = Z. The n-tuple (0, . . . , 0, [vi ], 0, . . . , 0) ∈ KΓ1 (EΓ) maps to [vi ] ∈ KZ1 (EZ). By the explicit description in [[8], Section II.2.4], we know that the assembly map µZ1 transfers the generator on one side to the other. Moreover, Ln by functoriality of K-theory we have that K1 (C∗r (Fn )) ∼ = i=1 K1 (C∗ (Z)). Therefore, (0, . . . , 0, [vi ], 0, . . . , 0) maps to (0, . . . , 0, [ui ], 0, . . . , 0). 6 Trace We close the article by a remark on the image of the induced (canonical) trace on K0 (C∗r (Γ)), that is Im τ∗ (K0 (C∗r (Γ))). This is relevant in the context of the modified Trace conjecture formulated by Lück in [6]. Let τ : C∗r (G) → C be the canonical trace on C∗r (G). Concerning the (modified) Trace conjecture, it is predicted that for the induced homomorphism τ∗ : K0 (C∗r (G)) → R we have that  1  subring Im τ∗ ⊂ Z { : H ≤ G, H| < ∞} ⊂ Q. |H| In the case of Γ = F o Fn , thanks to the surjectivity of ι∗ : K0 (C∗ (B)) → K0 (C∗r (Γ)), we only need to consider Im τ∗ (C∗ (B)) = Im τ∗ (Z(MinF (Fn ) )). Therefore the computations in Proposition 5 in [3] implies the predicted result  1  Im τ∗ (K0 (C∗r Γ)) = Z . |F | References [1] K.S. Brown Cohomology of groups Springer, 1982 [2] Y. Cornulier, Y. Stalder and A.Valette Proper actions of wreath products and generalizations Trans. Amer. Math. Soc. 364 (2012), 3159-3184 17 [3] R. Flores, S. Pooya and A. Valette K-theory and K-homology for the lamplighter groups of finite groups arXiv:1610.02798, to appear in Proc. London Math. Soc. [4] M. Fluch On Bredon (co-)homological dimensions of groups PhD Thesis, 2011. http://www.fluch.pl/docs/phdthesis.pdf [5] N. Higson and G. Kasparov E-theory and KK-theory for groups which act properly and isometrically on Hilbert space Invent. Math. 144 (2001), no. 1, 23–74 [6] W. Lüeck The relation between the Baum-Connes conjecture and the trace conjecture Invent. Math. 149 (2002), 123-152 [7] C. Martı́nez A spectral sequence in Bredon co(homology) J. Pure Appl. Alg., 176 (2002), 161-173 [8] G. Mislin and A. Valette Proper group actions and the Baum-Connes conjecture, Advanced Courses in Mathematics - CRM Barcelona, Birkhäuser, 2003 [9] M. Pimsner and D. Voiculescu Exact sequences for K-groups and Ext- groups of certain crossed products C∗ -algebras J. Operator theory 4 (1980), 93-118 [10] M. Pimsner and D. Voiculescu K-groups of reduced crossed products by free groups J. Operator theory 8 (1982), 131-156 [11] S. Pooya and A. Valette K-theory for the C∗ -algebras of the solvable BaumslagSolitar groups arXiv:1604.05607 Sanaz Pooya Institut de Mathématiques Université de Neuchâtel Switzerland [email protected] 18
4math.GR
Unsupervised Neural-Symbolic Integration arXiv:1706.01991v2 [cs.AI] 22 Jun 2017 Son N. Tran The Australian E-Health Research Center, CSIRO [email protected] Abstract Symbolic has been long considered as a language of human intelligence while neural networks have advantages of robust computation and dealing with noisy data. The integration of neural-symbolic can offer better learning and reasoning while providing a means for interpretability through the representation of symbolic knowledge. Although previous works focus intensively on supervised feedforward neural networks, little has been done for the unsupervised counterparts. In this paper we show how to integrate symbolic knowledge into unsupervised neural networks. We exemplify our approach with knowledge in different forms, including propositional logic for DNA promoter prediction and firstorder logic for understanding family relationship. 1 Introduction An interesting topic in AI is integration of symbolic and neural networks, two different information processing paradigms. While the former is the key of higher level of intelligence the latter is well known for a capability of effective learning from data. In the last two decades, researchers have been working on the idea that combination of the two should offer joint benefits [Towell and Shavlik, 1994; Smolensky, 1995; Avila Garcez and Zaverucha, 1999; Valiant, 2006; Garcez et al., 2008; Penning et al., 2011; França et al., 2014; Tran and Garcez, 2016]. In previous work, supervised neural networks have been used intensively for the integration based on the analogy of modus ponens inference with symbolic rules and forward passing in neural networks [Towell and Shavlik, 1994; Avila Garcez and Zaverucha, 1999]. In such networks, due to the discriminative structures only a subset of variables can be inferred, i.e. the variables in the left hand of if-then ← formulas. This may limit their use in general reasoning. Unsupervised network, on the other hand, offers more flexible inference mechanism which seems more suitable for symbolic reasoning. Let us consider an XOR example z ↔ (x ⊕ y). Here, given the truth values of any two variables one can infer the rest. For supervised networks, a class variable must be discriminated from the others and only it can be inferred. An unsupervised network, in contrast, do not require such discrimination. Encoding symbolic knowledge in an unsupervised neural network needs a mechanism to convert symbolic formulas to the network without loss of generality. In previous work, Penalty logic shows that any propositional formula can be represented in a symmetric connectionist network (SCN) where inference with rules is equivalent to minimising the network’s energy. However, SCN uses dense connections of hidden and visible units which make the inference very computational. Recent work shows that any propositional formula can be represented in restricted Boltzmann machines [Tran, 2017]. Different from Penalty logic, here the RBM is a simplified version of SCN where there is no visible-visible and hidden-hidden connections. This makes inference in RBMs is easier. Several attempts have been made recently to integrate symbolic representation and RBMs [Penning et al., 2011; Tran and Garcez, 2016]. Despite achieving good practical results they are still heuristic. In this paper, we show how to encode symbolic knowledge in both propositional and firstorder forms into the RBM by extending the theory in [Tran, 2017]. The remainder of this paper is organized as follows. Section 2 review the idea of Confidence rule, a knowledge form to represent symbolic formulas in RBMs. In section 3 we show how to encode knowledge into RBMs. Section 4 presents the empirical verification of our encoding approach and Section 5 concludes the work. 2 Confidence Rules: Revisit A confidence rule [Tran and d’Avila Garcez, 2013; Tran and Garcez, 2016] is a propositional formula in the form: ^ ^ c:h↔ xt ∧ ¬xk (1) t k where h is called hypothesis, c is a non-negative real value called confidence value. Inference with a confidence rule is to find the model that makes the hypothesis h holds. If there exist a target variable y the inference of such variable will be similar to modus ponens, as shown in Table 1 An interesting feature of Confidence rules is that one can represent them in an RBM where Gibbs sampling can be seen Confidence rule inference h↔ V t∈T xt ∧ V k∈K Modus ponens ¬xk ∧ y y← V t xt ∧ V k ¬xk {xt , ¬xk | for ∀t ∈ T, ∀k ∈ K} {xt , ¬xk | for ∀t ∈ T, ∀k ∈ K} y y Table 1: Confidence rule and Modus ponens equivalently as maximising the total (weighted) satisfiability [Tran, 2017]. If a knowledge base is converted into Confidence rules then we can take the advantage of the computation mechanism in such neural networks for efficient inference. The equivalence between confidence rules and an RBM is defined in that the satisfiability of a formula is inversely proportional to the energy of a network: Encoding these rules into an RBM does not guarantee the equivalence. This is because it violates the condition that the DNF of a formula should have at most one conjunct is true given an assignment [Tran, 2017]. Fortunately this can be solved by grouping ¬xt , xk with a max-pooling hidden unit which results in an RBM with the energy function as12 : X X E = − c × hy (y + xt − xk − |T | − 1 + ) t t sϕ (x) = −aE rank (x) + b where sϕ is the truth value of the formula ϕ given an assignment x; Erank (x) = minh E (x, h) is the energy function minimised over all hidden variables; a > 0,b are scalars. By using disjunctive normal form (DNF) to present knowledge Confidence rules attract some criticism for practicality since it is more popular to convert a formula to a conjunctive normal form of polynomial size. However we will show that Confidence rules are still very useful in practice. In fact, in such tasks as knowledge extraction, transfer, and integration Confidence rules have been already employed [Penning et al., 2011; Tran and d’Avila Garcez, 2013; Tran and Garcez, 2016]. For knowledge integration previous work separates the if-and-only-if symbol in Confidence rules into two if-then rules to encode in a hierarchical networks [Tran and Garcez, 2016]. In this work, we show that such separation is not necessary since any propositional if-then formulas can be efficiently converted to Confidence rules. The details are in the next section. 3 Knowledge Encoding In many cases background knowledge presents a set of if-then formulas (or equivalent Horn clauses). This section shows how to convert them into Confidence rules for both propositional and first-order logic forms 3.1 Proposition Logic A propositional if-then formula has the form ^ ^ c:y← xt ∧ ¬xk t k t k t k _ k ¬xt ∨ t _ xk k Example 1. Let us consider the formula: 5 : y ← x1 ∧ ¬x2 which would be converted to DNF as: 5 : (y ∧ x1 ∧ ¬x2 ) ∨ (¬x1 ) ∨ (x2 ), and then to an RBM with the energy function: E = −5h1 (y + x1 − x2 − 1.5) − 5h2 max(−x1 + 0.5, x2 − 0.5). Table 2 shows the equivalence between the RBM and the formula. x1 0 0 0 0 1 1 1 1 x2 0 0 1 1 0 0 1 1 y 0 1 0 1 0 1 0 1 sϕ 1 1 1 1 0 1 1 1 Erank -2.5 -2.5 -2.5 -2.5 0 -2.5 -2.5 -2.5 Table 2: Energy of RBM and truth values of the formula 5 : y ← x1 ∧ ¬x2 where sϕ is (unweighted) truth values of the formula. This indicates the equivalence between the RBM and the formula as: 1 sϕ (x1, x2, y) = − Erank (x, y, z) + 0 2.5 First-order Logic A first order logic formula can also be converted into a set of Confidence rules. First, let us consider a predicate: P (x, y) which one can present in a propositional DNF as: _ px=a ∧ py=b ∧ pP k and then to the confidence rules: ^ ^ xt ∧ ¬xk c : hy ↔ y ∧ c : ht ↔ ¬xt for ∀t c : hk ↔ xk for ∀k c : hp ↔ 3.2 which can be transformed to a DNF as: ^ ^ _ _ c : (y ∧ xt ∧ ¬xk ) ∨ (¬xt ) ∨ (xk ) t k − c × hp max({−xt + , xk − 1 + |t ∈ T, k ∈ K}) (2) HereWa max pooling hidden unit represents a hypothesis: W hp ↔ tW ht ∨ k hWk which, in this case, can be written as: c : hp ↔ t ¬xt ∨ k xk . The final set rules are: ^ ^ c : hy ↔ y ∧ xt ∧ ¬xk a,b|P (a,b)=true where (a, b) are the models of P (x, y); px=a and py=b are the propositions that are true if x = a and y = b respectively, otherwise they are f alse; pP is the proposition indicating if 1 2 The proof is similar as in [Tran, 2017] 0<<1 the value of P (a, b). Each conjunct in this DNF then can be represented as a Confidence rule. Now, let us consider a first-order formula which we are also able to present in a set of Confidence rules. For example, a clause ϕ as: ∀x,y,z son(x, z) ← brother(x, y) ∧ has father(y, z) can be converted into: _ (px=a ∧ py=b ∧ pz=c ∧ pson ∧ pbrother ∧ phas father ) a,b,c|ϕ=true ∨ (¬px=a ∨ ¬py=b ∨ ¬pz=c ∨ ¬pbrother ∨ ¬phas father ) If one want to encode the background knowledge through its samples, for example: son(James, Andrew) ← brother(James, Jen) ∧ has father(Jen, Andrew) (a) Infer with Gibbs sampling (b) Infer with P (y|x) Figure 1: RBMs without rules v.s RBMs with rules then we can convert it into confidence rules: c : h1 ↔ james ∧ jen ∧ andrew ∧ son ∧ brother ∧ has father c : hp ↔ ¬james ∨ ¬jen ∨ ¬andrew ∨ ¬brother ∨ ¬has father4.2 Kinship In this experiment, we use the approach discussed in SecIn practice, in many cases we are only interested in inferring tion 3.2 for relation discovery and reasoning tasks with Kinthe predicates therefore we can omit ¬james, ¬jen, ¬andrew ship dataset [Hinton, 1986; Sutskever and Hinton, 2008]. from the second rule. Here given a set of examples about relations we perform two type of reasoning: (1) what is relation between two 4 Empirical Evaluation people, i.e ?(x, y); and (2) a person has a relation R with In this section we apply the encoding approaches discussed in whom, i.e. R(x, ?). Previous approaches are using matrithe previous section to integrate knowledge into unsupervised ces/tensors to represents the relations making it difficult to exnetworks. plain [Sutskever and Hinton, 2008]. In this work, since only predicates are given, we encode the examples for the predi4.1 DNA promoter cates in an unsupervised network as shown earlier in Section The DNA promoter dataset consist of a background theory 3.2. This constructs the left part of the integrated model in with 14 logical if-then rules [Towell and Shavlik, 1994]. The Figure 2. In the right part, we model the unknown clauses rules includes four symbols contact, minus10 , minus35 , by using a set of hidden units. The idea here is that by inconf ormation which are not observed in the data. This is ferring the predicates using the encoded rules in the left part suitable for hierarchical models as shown in previous works we can capture the relationship information, from which the [Towell and Shavlik, 1994; Tran and Garcez, 2016]. In this desired relation is inferred by reconstruction of such relationexperiment we group the rules using hypothetical syllogism ship in the right part. In this experiment, we use auto-encoder to eliminate the unseen symbols. After that we encode the [Bengio, 2009] for the right part for the purpose of efficient rules in an RBM following the theory in Section 3.1. The learning. The whole process is described in Algorithm 1. confidence values are selected empirically. We test the normal RBMs and the RBMs with encoded rule using leave-one-out method, both achieve 100% accuracy. In order to evaluate the effectiveness of our approach we partition the data into nine different training-test sets with number of training samples are 10, 20, 30, 40, 50, 60, 70, 80, 90. All experiments are repeated 50 times and the average results are reported in Figure 1. We perform the prediction using both Gibbs sampling and conditional distribution P (y|x). In particular, Figure 1a shows the prediction results using 1-step Gibbs sampling where the input is fixed to infer the hidden Figure 2: Encoding Kinship examples states and then to infer the label unit. In Figure 1b the results show the prediction accuracy achieved by inferring the Let us take an example where one wants to find the relalabel unit from the conditional distribution. As we can see, in both cases the integrated RBMs perform better than the tion between two people R(M arco, P ierro) =?. First, we normal RBMs on small training sets with number of training use the other examples to construct an integrated model as in sample is less than 60. With larger training sets, the rules are Figure 2. After that, we train the auto-encoder in the right part using unsupervised learning algorithm, then we extract no longer effective since the training samples are adequate to generalise the model to achieve 100% accuracy. the relation features from Marco and Pierro as shown in Ta- ble 3. In that table we also show the reconstructed scores for all the relations where son is the correct one. Algorithm 1 Data: Examples: E, Question: R(a,b) Result: R Encode all examples in an RBM: N Initialise D = ∅ for each example R(x, y) in E do f = INFER(N,x,y) Add f to D end Train an Auto-Encoder (AE) on D f = INFER(N,a,b) Reconstruct fˆ using AE Return R = arg maxR (fˆR ) . Return the unseen relation where the reconstruction feature have the highest value. 1: function INFER(N, a, b) 2: Infer direct relation between a,b 3: Infer possible relations of a: R(a,*) 4: Infer possible relations of b: R(*,b) 5: f = concatenation of all relations 6: Return f 7: end function We test the model on answering the question R(x, y) =? using leave-one-out validation which achieve 100% accuracy. We also use the integrated model to reason about whom one has a relation with. This question may have more than one answer, for example son(Athur, ?) can be either Cristopher or P enelope. We randomly select 10 examples for testing and repeat it for 5 times. If the designate answers are in the top relations with highest reconstructed features then we consider this as correct, otherwise we set it as wrong. The average error of this test is 0%. However, when we increase the number of test samples to 20 and 30 the average errors grow to 2.8% and 6.8% respectively. For comparison, the matrices based approach such as [Sutskever and Hinton, 2008] achieves 0.4%,1.2%,2.0% average error rates for 10, 20, 30 test examples respectively. Note that, such approach and many others [Socher et al., 2013] model each relation by a matrix/tensor while in this experiment we share the parameters across all relations. Also, the others use discriminative learning while we use unsupervised learning. The purpose of this is to exemplify the encoding technique we proposed earlier in this paper. Improvement can be achieved if similar methods are employed. 5 Conclusions The paper shows how to integrate symbolic knowledge into unsupervised neural networks. This work bases on the theoretical finding that any propositional formula can be represented in RBMs [Tran, 2017]. We show that converting background knowledge in the form of if-then rules to Confidence rules for encoding is efficient. In the experiments, we evaluate our approaches for DNA promoter prediction and relationship reasoning to show the validity of the approach. References [Avila Garcez and Zaverucha, 1999] Artur S. Avila Garcez and Gerson Zaverucha. The connectionist inductive learning and logic programming system. Applied Intelligence, 11(1):5977, July 1999. [Bengio, 2009] Yoshua Bengio. Learning deep architectures for ai. Found. Trends Mach. Learn., 2(1):1–127, January 2009. [França et al., 2014] Manoel V. M. França, Gerson Zaverucha, and Artur S. d’AvilaGarcez. Fast relational learning using bottom clause propositionalization with artificial neural networks. Machine Learning, 94(1):81–104, 2014. [Garcez et al., 2008] Artur S. d’Avila Garcez, Lus C. Lamb, and Dov M. Gabbay. Neural-Symbolic Cognitive Reasoning. Springer Publishing Company, Incorporated, 2008. [Hinton, 1986] Geoffrey E. Hinton. Learning distributed representations of concepts. In Proceedings of the Eighth Annual Conference of the Cognitive Science Society, pages 1–12. Hillsdale, NJ: Erlbaum, 1986. [Penning et al., 2011] Leo de Penning, Artur S. d’Avila Garcez, Lus C. Lamb, and John-Jules Ch Meyer. A neuralsymbolic cognitive agent for online learning and reasoning. In IJCAI, pages 1653–1658, 2011. [Smolensky, 1995] Paul Smolensky. Constituent structure and explanation in an integrated connectionist/symbolic cognitive architecture. In C. Mcdonald, editor, Connectionism: Debates on Psychological Explanation, pages 221–290. Blackwell, Cambridge, 1995. [Socher et al., 2013] Richard Socher, Danqi Chen, Christopher D. Manning, and Andrew Y. Ng. Reasoning with neural tensor networks for knowledge base completion. In Proceedings of the 26th International Conference on Neural Information Processing Systems, NIPS’13, pages 926– 934, USA, 2013. Curran Associates Inc. [Sutskever and Hinton, 2008] Ilya Sutskever and Geoffrey E Hinton. Using matrices to model symbolic relationship. In D. Koller, D. Schuurmans, Y. Bengio, and L. Bottou, editors, Advances in Neural Information Processing Systems 21, pages 1593–1600. Curran Associates, Inc., 2008. [Towell and Shavlik, 1994] Geoffrey G. Towell and Jude W. Shavlik. Knowledge-based artificial neural networks. Artificial Intelligence, 70(1-2):119–165, 1994. [Tran and d’Avila Garcez, 2013] Son N. Tran and Artur d’Avila Garcez. Knowledge extraction from deep belief networks for images. In IJCAI-2013 Workshop on NeuralSymbolic Learning and Reasoning, 2013. [Tran and Garcez, 2016] Son Tran and Artur Garcez. Deep logic networks: Inserting and extracting knowledge from deep belief networks. IEEE Transactions on Neural Networks and Learning Systems, PP(99):1–13, 2016. Marco, Pierro Marco Pierro Reconstruct (possible relations) 1.000: has father Marco has father who is Pierro 0.191:has wife Marco has wife 0.191:husband Marco is a husband of someone 0.191:has mother Marco has mother 0.191:father Marco is a father of someone 0.191:has daughter Marco has daughter 0.191:son Marco has is a son of someone 0.191:has son Marco has son 0.191:has sister Marco has sister 0.191:brother Marco is a brother of someone 0.191: has wife Pierro has wife 0.191: husband Pierro is a husband of someone 0.191: father Pierro is a father of someone 0.191: has daughter Pierro has daughter 0.008:wife 0.008:husband 0.001:mother 0.016:father 0.045:daughter 0.252:son 0.005:sister 0.013:brother 0.001:aunt 0.002:uncle 0.003:niece 0.002:nephew Table 3: Relation features [Tran, 2017] Son N. Tran. Propositional knowledge representation in restricted boltzmann machines. https://arxiv.org/abs/1705.10899, 2017. [Valiant, 2006] Leslie G. Valiant. Knowledge infusion. In Proceedings, The Twenty-First National Conference on Artificial Intelligence and the Eighteenth Innovative Applications of Artificial Intelligence Conference, July 1620, 2006, Boston, Massachusetts, USA, pages 1546–1551, 2006.
2cs.AI
Discriminative Measures for Comparison of Phylogenetic Trees Omur Arslan, Dan P. Guralnik, Daniel E. Koditschek arXiv:1310.5202v2 [q-bio.PE] 20 Oct 2015 Department of Electrical and Systems Engineering, University of Pennsylvania, Philadelphia, PA 19104, USA Abstract In this paper we introduce and study three new measures for efficient discriminative comparison of phylogenetic trees. The NNI navigation dissimilarity dnav counts the steps along a “combing” of the Nearest Neighbor Interchange (NNI) graph of binary hierarchies, providing an efficient approximation to the (NP-hard) NNI distance in terms of “edit length”. At the same time, a closed form formula for dnav presents it as a weighted count of pairwise incompatibilities between clusters, lending it the character of an edge dissimilarity measure as well. A relaxation of this formula to a simple count yields another measure on all trees — the crossing dissimilarity dCM . Both dissimilarities are symmetric and positive definite (vanish only between identical trees) on binary hierarchies but they fail to satisfy the triangle inequality. Nevertheless, both are bounded below by the widely used RobinsonFoulds metric and bounded above by a closely related true metric, the cluster-cardinality metric dCC . We show that each of the three proposed new dissimilarities is computable in time O(n2 ) in the number of leaves n, and conclude the paper with a brief numerical exploration of the distribution over tree space of these dissimilarities in comparison with the Robinson-Foulds metric and the more recently introduced matching-split distance. Keywords: Phylogenetic Trees, Evolutionary Trees, Nearest Neighbor Interchange, Comparison of Classifications, Tree Metric. 1. Introduction 1.1. Motivation A fundamental classification problem common to both computational biology and engineering is the efficient and informative comparison of hierarchical structures. In bioinformatics settings, these typically take the form of phylogenetic trees representing evolutionary relationships within a set S of taxa. In pattern recognition and data mining settings, hierarchical trees are often used to encode nested sequences of groupings of a set of observations. Dissimilarity between combinatorial trees has been measured in the past literature largely by recourse to one of two separate approaches: comparing edges and counting edit distances. Representing the former approach, a widely used tree metric is the Robinson-Foulds (RF) distance, dRF , [1] whose count of the disparate edges between trees requires linear time, O(n), in the number of leaves, n, to compute [2]. Empirically, dRF offers only a very coarse measure of disparity, and among its many proposed refinements, the recent matching split distance d MS , [3, 4] offers a more discriminative metric albeit with considerably higher computational cost, O(n2.5 log n). Alternatively, various edit distances have been proposed [5–8] but the most natural variant, the Nearest Neighbor Interchange (NNI) distance dNNI , entails an NP-complete computation for both labelled and unlabelled trees [9]. 1.2. Results Our main contribution is the introduction of a dissimilarity measure on the space BT S of labelled binary trees which bridges the above approaches by what is, effectively, a solution to the NNI navigation problem in BT S : Problem 1 (NNI Navigation Problem). Given a target τ ∈ BT S , provide an efficient algorithm Aτ which, for any σ ∈ BT S , computes a Nearest Neighbor Interchange to be performed on σ while guaranteeing that successive application of Aτ terminates in τ. Email addresses: [email protected] (Omur Arslan), [email protected] (Dan P. Guralnik), [email protected] (Daniel E. Koditschek) Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 2 This problem is motivated by applications in coordinated robot navigation [10–12], where a group of robots is required to reconfigure reactively in real time their (structural) adjacencies while navigating towards a desired goal configuration. Thus, our particular formulation of the problem is inspired by the notion of reactive planning [13], but may likely hold value for researchers interested in tree consensus and averaging as well. Of course, since computation of dNNI is NP-hard, one cannot hope for repeated applications of Aτ to produce NNI geodesics without incurring prohibitive complexity in each iteration. However, as we will show, constructing an efficient navigation scheme is possible if we allow the algorithm to produce less restricted paths: for |S | = n, our navigation algorithms require O(n) time for each iteration and produce paths of length O(n2 ) (as compared to the O(n log n) diameter of dNNI — see (19)). Additional insight into the geometry of the space (BT S , dNNI ) is gained by recognizing a significant degree of freedom with which our navigation algorithm may select the required tree restructuring operation at each stage. As it turns out, for any given target τ, the repeated application of Aτ to a tree σ until reaching τ will yield paths of equal lengths regardless of any choices made along the way. This length, by definition, is the navigation dissimilarity dnav (σ, τ) (and is obtained, in the manner described, in O(n3 ) time, though more efficient implementations will guarantee O(n2 )). At the same time, a closed form formula we derive for dnav allows us to avoid computing a navigation path when only the value of dnav is needed, and computes it in O(n2 ) time. Surprisingly, despite the asymmetric character of its construction, dnav is a symmetric (and positive definite) dissimilarity on BT S , though it fails to be a metric. Although dnav does not satisfy the triangle inequality, it is related to the well accepted Robinson-Foulds distance by the following tight bounds: 1 1 2 + dRF , (1) dRF ≤ dnav ≤ dRF 2 2 We find it useful to introduce a “relaxation” of dnav , the crossing dissimilarity dCM . This dissimilarity simply counts all the pairwise cluster incompatibilities between two trees, hence it is symmetric, positive-definite, and computable in O(n2 ) time. In fact, the two dissimilarities are commensurable, leading to similar bounds in terms of dRF : dCM ≤ dnav ≤ 3 dCM , 2 2 dRF ≤ dCM ≤ dRF . (2) Finally, we introduce a true metric whose spatial resolution and computational complexity is comparable to those our new dissimilarities. Exploiting a well known relation between trees and ultrametrics [14], we also introduce the cluster-cardinality distance dCC — constructed as the pullback of a matrix norm along an embedding of hierarchies into the space of matrices and computable in O(n2 ) time — which is a true metric bounding dCM from above (and hence also dnav , up to a constant factor). Thus, cumulatively we obtain: 2 2 dRF ≤ dnav ≤ dCM ≤ dCC . 3 3 (3) We have surveyed some of the new features of our tree proximity measures that might hold interest for pattern classification and phylogeny analysis relative to the diverse alternatives that have appeared in the literature. Closest among these many alternatives [15–17], dnav has some resemblance to an early NNI graph navigation algorithm, dra [17] which used a divide-and-conquer approach with a balancing strategy to achieve an O(n log n) computation of tree dissimilarity. Notwithstanding its lower computational cost, in contrast to dnav , the recursive definition of dra , as with many NNI distance approximations [15–17], does not admit a closed form expression. It is often of interest to compare more than pairs of hierarchies at a time, and the notion of a “consensus” tree has accordingly claimed a good deal of attention in the literature [18]. For instance, the majority rule tree [19] of a set of trees is a median tree respecting the RF distance and provides statistics on the central tendency of trees [20]. When dnav and dCM are extended to degenerate trees they fail to be positive definite, and thus their behavior over (typically degenerate) consensus trees departs still further from the properties of a true metric. However, it turns out that both notions of a consensus tree (strict [21], and loose/semi-strict [22]) behave as median trees with respect to both our dissimilarities. In fact, the loose consensus tree is the maximal (finest) median tree with respect to inclusion for both dnav and dCM . 2 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 3 The paper is organized as follows. Section 2 briefly summarizes the necessary background while introducing the notation used throughout the sequel. Section 3 introduces and studies the cluster-cardinality distance dCC and the crossing dissimilarity dCM . In Section 4 we present a solution of the NNI navigation problem and study properties of the resulting NNI navigation dissimilarity dnav and its relations with other tree dissimilarity measures. Section 5 discusses the relation between commonly used consensus models and our tree dissimilarities dCM and dnav , and compares our proposed tree measures with dRF and d MS based on some frequently used empirical distributions of tree measures. A brief discussion of future directions follows in Section 6. 2. Preliminaries 2.1. Hierarchies By a hierarchy τ over a fixed non-empty finite index set S we shall mean a rooted tree with labeled leaves (see Figure 1). Formally, τ is a finite connected acyclic graph with leaves (vertices of degree one) bijectively labelled by S , and edges oriented in such a way that (i) all interior vertices have out-degree at least two, and (ii) there is a vertex, referred to as the root of τ, such that every edge is oriented away from the root. Under these assumptions all the vertices of τ are reachable from the root through a directed path in τ [23]. The cluster C (v) of a vertex v ∈ Vτ of a hierarchy τ is defined to be the set of leaves reachable from v by a directed path in τ. Singleton clusters and the root cluster S are common to all trees, and we refer to them as the trivial clusters. We denote by C (τ) (respectively Cint (τ)) the set of all clusters (resp. non-trivial clusters) of τ:   o n Cint (τ) : = I ∈ C (τ) \ {S } |I| ≥ 2 , C (τ) : = C (v) v ∈ Vτ ⊆ P (S ) , (4) where P (S ) denotes the power set of S . 2.1.1. Compatibility Definition 1 ([8, 24]). Subsets A, B ⊂ S are said to be compatible, A ⊲⊳ B, if A∩B=∅ ∨ A⊆ B ∨ B⊆ A. (5) If A 6⊲⊳ B, then we say that A and B cross. We further extend the compatibility relation (⊲⊳) as follows: • For A, B ⊆ P (S ), write A ⊲⊳ B if A ⊲⊳ B for all A ∈ A and B ∈ B; • For a cluster I ⊆ S and a tree τ over the leaf set S , write I ⊲⊳ τ if {I} ⊲⊳ C (τ); • For two trees σ and τ over the leaf set S , write σ ⊲⊳ τ if C (σ) ⊲⊳ C (τ). By construction, any two elements of C (τ) are compatible for any tree τ. This motivates the following definition: Definition 2 ([24]). A subset A of P (S ) is said to be nested — also referred to in the literature as a “laminar family” — if any two elements of A are compatible. C (τ) is known as the laminar family associated with τ . 2.1.2. Hierarchical Relations The cluster set C (τ) of a hierarchy τ completely determines its representation as a rooted tree with labeled leaves: C (τ) stands in bijective correspondence with the vertex set of τ, and (v, v′ ) is an edge in τ if and only if C (v) ⊃ C (v′ ) and there is no ṽ ∈ Vτ such that C (v) ⊃ C (ṽ) ⊃ C (v′ ). Consequently, the standard notions of ancestor, descendant, parent and child of a vertex in common use for rooted trees carry over to the cluster representation as follows: o o n n (6a) Des (I, τ) = V ∈ C (τ) V ( I , Anc (I, τ) = V ∈ C (τ) I ( V , n o Pr (I, τ) = min (Anc (I, τ)) , Ch (I, τ) = V ∈ C (τ) Pr (V, τ) = I , (6b) where min (Anc (I, τ)) is computed with respect to the inclusion order. Note that for the trivial clusters we have Pr (S , τ) = ∅ and Ch ({s}, τ) = ∅ for s ∈ S . 3 11 root nc ( I, {1, 2, 3, 4, 5} interior node leaf node A {2 , 3, 4 τ τ) {4, 5} {1, 2} {4, 5} 5} } 5 , 4, , 4, {3 {3 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 4, 5 } P r (I, τ ) {1, 2, 3, 4, 5} left −τ right I rotation diagonal-flip 1 2 Ch (I, τ ) I 5 6 3 4 Des (I, τ ) 7 8 9 10 11 12 13 Figure 1. Hierarchical Relations: ancestors - Anc (I, τ), parent - Pr (I, τ), children - Ch (I, τ), descendants - Des (I, τ), and local complement (sibling) - I −τ of cluster I of a rooted binary phylogenetic tree, τ ∈ BT [13] . Filled and unfilled circles represent interior and leaf nodes, respectively. An interior node is referred to by its cluster, the list of leaves below it; for example, I = {4, 5, 6, 7}. Accordingly, the cluster set of τ is C (τ) =  {1} , {2} , . . . , {13} , {1, 2} , {1, 2, 3} , {4, 5} , {6, 7} , {4, 5, 6, 7} , {1, 2, . . . , 7} , {9, 10} , {8, 9, 10} , {11, 12} , {11, 12, 13} , {8, 9, . . . , 13} , {1, 2, . . . , 13} . Since the set of children partitions each parent, we find it useful to define the local complement I −τ of I ∈ C (τ) as I −τ : = Pr (I, τ) \ I , (7) not to be confused with the standard (global) complement, I C = S \ I. Further, a grandchild in τ is a cluster G ∈ C (τ)  having a grandparent Pr2 (G, τ) : = Pr Pr (G, τ) , τ in τ. We denote the set of all grandchildren in τ by G (τ), n o G (τ) : = G ∈ C (τ) Pr2 (G, τ) , ∅ . (8) If A, B are either elements of S or clusters of τ, it is convenient to have (A∧B)τ denote the smallest (in terms of cardinality) common ancestor of A and B in τ. Finally, the depth ℓτ (I) of a cluster in a hierarchy τ is defined to equal the number of distinct ancestors of I in τ. 2.1.3. Nondegeneracy A rooted tree where every interior vertex has exactly two children is said to be binary or non-degenerate. All other trees are said to be degenerate. We will denote the set of hierarchies over a finite leaf set S , by TS . The subset of non-degenerate hierarchies will be denoted by BT S . Note that the laminar family C (τ) of a degenerate tree τ may always be augmented with additional clusters while remaining nested (Definition 2). This leads to the well known result: Remark 1 ([24, 25]). Let τ ∈ TS . Then τ has at most 2 |S | − 1 vertices, with equality if and only if τ is nondegenerate, if and only if C (τ) is a maximal laminar family in P (S ) with respect to inclusion.1 2.1.4. Consensus Definition 3 ([21, 22]). For any set of trees T in TS , the strict and loose consensus trees of T , denoted T ∗ and T ∗ respectively, are defined by specifying their cluster sets as follows:     \    [  ∗ C (τ) , C (T ) =  C (T ∗ ) = I∈ C (τ) ∀σ ∈ T I ⊲⊳ σ . (9)     τ∈T τ∈T Note that the loose consensus tree T ∗ of T refines the strict consensus tree T ∗ , that is C (T ∗ ) ⊇ C (T ∗ ). 1 In this paper we adopt the convention that a laminar family does not contain the empty set (as an element). 4 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 5 2.2. Some Operations on Trees 2.2.1. The NNI Graph The standard definition of NNI walks on unrooted binary trees [5, 6] conveniently restricts to the space BT S of rooted binary trees as follows: Definition 4. Let σ ∈ BT S . We say that τ ∈ BT S is the result of performing a Nearest Neighbor Interchange (NNI) move on σ at a grandchild G ∈ G (σ) (8) if  n  o  C (τ) = C (σ) \ Pr (G, σ) ∪ Pr2 (G, σ) \ G . (10) We often indicate this by writing τ = NNI(σ, G). Note that the NNI move at cluster G on σ swaps cluster G with its parent’s sibling Pr (G, σ)−σ to yield τ, depicted in Figure 2(left); and after an NNI move at cluster G of σ, grandchild G of grandparent P = Pr2 (G, σ) with respect to σ becomes child G of parent P = Pr (G, τ) with respect to τ. It is standard to say that σ, τ ∈ BT S are NNI-adjacent if and only if one can be obtained from the other by a single move. Figure 2(left) illustrates the moves on BT S and their inverses. τ 1 PSfrag replacements B C (γ, A) (τ, B) 1 γ σ B C (σ, B) 2 4 2 4 1 3 3 2 3 1 2 3 4 1 2 3 4 1 4 PSfrag replacements (γ, C) A 4 3 1 4 2 3 2 3 1 4 1 4 2 3 2 3 1 4 A (τ, C) (σ, A) 2 1 2 A C 1 3 3 2 1 4 1 3 2 4 1 3 4 2 4 4 2 3 B 5 6 Figure 2. NNI moves (arrows, left) between binary trees, each move is labeled by its source tree and the grandchild defining the move, and the NNI Graph for S = [4] = {1, 2, 3, 4} (right). The NNI-graph is formed over the vertex set BT S by declaring two trees to be connected by an edge if and only if they are NNI-adjacent, see e.g. Figure 2(right). We will work with a directed version of this graph: Definition 5. The directed NNI graph NS = (BT S , ES ) is the directed graph on BT S with (σ, τ) ∈ ES iff τ results from applying an NNI move to σ. We will henceforth identify the notation for an NNI move (σ, G), G ∈ G (σ) with the directed edge (σ, NNI(σ, G)) ∈ ES wherever there is no danger of confusion. The (directed) NNI-graph on n leaves is a regular graph of out-degree 2(n − 2) [5]. Our description clarifies this by parametrizing the set of neighbors of τ ∈ BT S with its grandchildren, |G (τ)| = 2(|S | − 2). The vertex set of the NNI graph is known to grow super exponentially with the number of leaves [23], BT [n] = (2n − 3)!! = (2n − 3)(2n − 5) . . . 3 , n≥2. (11) As a result, exploration of the NNI-graph (for example, searching for the shortest path between hierarchies or an optimal phylogenetic tree model) rapidly becomes impractical and costly as the number of leaves increases. A useful observation for NNI-adjacent trees is: Lemma 1. An ordered pair of hierarchies (σ, τ) is an edge in NS if and only if there exists an ordered triple (A, B, C) of common clusters of σ and τ such that {A ∪ B} = C (σ) \ C (τ) and {B ∪ C} = C (τ) \ C (σ). The triple (A, B, C) is uniquely determined by (σ, τ) and will be referred to as the NNI-triplet associated with (σ, τ). Proof. The proof amounts to a formal restatement of the observations made in Figure 2(left). See Appendix A.1.  Observe that the triplet in reverse order (C, B, A) is the NNI-triple associated with the edge (τ, σ). Also note that the NNI moves on σ at A and on τ at C yield τ and σ, respectively. 5 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 6 2.2.2. Tree Restriction Definition 6. Let S be a fixed finite set and K ⊆ S . The restriction map resK : P (S ) → P (K) is defined to be n o resK (A) : = A ∩ K A ∈ A , A ∩ K , ∅ (12) for any A ⊆ P (S ). It is convenient to have A K denote resK (A). For σ ∈ TK and τ ∈ TS we will write: σ = resK (τ) = τ K ⇐⇒ C (σ) = C (τ) K .      Remark 2. Let τ ∈ BT S and {S L , S R } = Ch (S , τ). Then one has C (τ) = C τ S ∪ S ∪ C τ S . L (13) R Lemma 2. For any finite set S and K ⊆ S with |K| ≥ 2, resK (BT S ) = BT K .  Proof. See Appendix A.2. 2.3. Dissimilarities, Metrics and Ultrametrics Recall that a dissimilarity measure on X, or simply a dissimilarity, is a real-valued nonnegative symmetric function d on X × X satisfying d(x, x) = 0 for all x ∈ X. Recall that a dissimilarity d on X is positive definite if d (x, y) = 0 implies x = y for all x, y ∈ X. Many approximations of the (NP-hard) NNI metric are positive definite dissimilarities [15–17]. A dissimilarity d is a metric if it satisfies the triangle inequality, d (x, y) ≤ d (x, z) + d (z, y) for all x, y, z ∈ X. For example: Definition 7 ([1] and[3, 4]). The Robinson-Foulds distance dRF on TS is defined by: 2 1 (14) dRF (σ, τ) = C (σ) ⊖ C (τ) , σ, τ ∈ TS . 2 The matching split distance d MS between a pair of hierarchies σ and τ in BT S is defined to be the value of a minimum-weighted perfect matching in the graph GS (σ, τ) obtained from σ, τ ∈ BT S as the complete bipartite 3 graph  with sides Cint (σ) and Cint (τ) with each edge (I, J) ∈ Cint (σ) × Cint (τ) carrying the weight AS (I, J) = min I ⊖ J , I ⊖ J C . It is known that dRF ≤ d MS ≤ |S 2|+1 dRF [3], which explains the improvement of d MS over dRF in discriminative power. At the same time, the cost of computing a minimum weighted perfect matching in any GS (σ, τ) is O(|S |2.5 log |S |), which motivates the search for dissimilarities producing similar improvement in discriminative power (bounding dRF from above) yet having a lower computational cost than that of d MS . Recall that an ultrametric d on X is a metric on X satisfying the strengthened triangle inequality, d (x, y) ≤  max d (x, z) , d (z, y) for all x, y, z ∈ X. The following is a restatement of a well known fact (see, e.g. [14, 26, 27]) revealing the relation between hierarchies and ultrametrics: Lemma 3. Let τ ∈ TS and hτ : C (τ) → R≥0 . For any i, j ∈ S let (i∧ j)τ denote the smallest cluster in C (τ) containing the pair {i, j}. Then the dissimilarity on S given by  (15) dτ (i, j) : = hτ (i∧ j)τ , i, j ∈ S , is an ultrametric if and only if the following are satisfied for any I, J ∈ C (τ): (a) if I ⊆ J, then hτ (I) ≤ hτ (J) , (b) hτ (I) = 0 if and only if |I| = 1 .  Proof. See Appendix A.3. Recall that a set X may always inherit a metric from a metric space (Y, dY ) by pullback: any injective map f of X into Y yields a metric dX on X defined by dX (x1 , x2 ) : = dY ( f (x1 ) , f (x2 )) and known as the pullback dX = f ∗ dY of dY along f . For example, the RF metric is a pullback: it is common knowledge that the set F (X) of all finite subsets of a set X forms a metric space under the metric d (A, B) = |A ⊖ B|, which is one of the ways of defining Hamming distance; thus, the RF distance is (one half times) the pullback of this metric on F (P (S )) under the map τ 7→ C (τ). 2 Here, 3 This ⊖ denotes the symmetric set difference, i.e. A ⊖ B = (A \ B) ∪ (B \ A) for any sets A and B. corresponds to the Hamming distance of clusters. 6 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 7 3. Quantifying Incompatibility 3.1. The Cluster-Cardinality Distance We now introduce an embedding of hierarchies into the space of matrices based on the relation between hierarchies and ultrametrics, summarized in Lemma 3:  Definition 8. The ultrametric representation is the map U : TS → R|S |×|S | defined by U(τ)i j : = h (i∧ j)τ , where h : P (S ) → N is set to be h (I) : = |I| − 1, I ⊆ S . Lemma 4. The map U is injective. Proof. To see the injectivity of U (Definition 8), we shall show that U (σ) , U (τ) for any σ , τ ∈ TS . Two trees σ, τ ∈ TS are distinct if and only if they have at least one unshared cluster. Accordingly, for any σ , τ ∈ TS consider a common cluster I ∈ C (σ) ∩ C (τ) with distinct parents Pr (I, σ) , Pr (I, τ). Depending on the cardinality of parent clusters: • If |Pr (I, σ)| = |Pr (I, τ)|, then observe that there exists some j ∈ Pr (I, σ) such that j < Pr (I, τ) because Pr (I, σ) , Pr (I, τ). In fact, notice that j ∈ I −σ and j < I −τ (recall (7)). Hence, for any i ∈ I we have (i∧ j)σ = Pr (I, σ) and Pr (I, τ) ( (i∧ j)τ . Thus, it follows from Definition 8 that for any i ∈ I U (σ)i j = Pr (I, σ) − 1 < U (τ)i j = (i∧ j)τ − 1 . (16) • Otherwise, without loss of generality, let |Pr (I, σ)| < |Pr (I, τ)|. Then, observe that for any i ∈ I and j ∈ I −σ , U (σ)i j = |Pr (I, σ)| − 1 < U (τ)i j = (i∧ j)τ − 1 , (17) since (i∧ j)τ ⊇ Pr (I, τ). Therefore, for any σ , τ ∈ BT S one has U (σ) , U (τ), and the result follows.  Using the embedding U of TS into R|S |×|S | , we can construct tree metrics by pulling back metrics induced from matrix norms, such as the one below: Definition 9. The cluster-cardinality metric, dCC : TS × TS → R≥0 , on TS is defined to be 4 dCC (σ, τ) : = 1 U (σ) − U (τ) 2 1 , σ, τ ∈ TS . (18) Proposition 1. The cluster-cardinality distance dCC on TS is computable in O(|S |2 ) time. Proof. The 1-norm of the difference of a pair of |S | × |S | matrices obviously requires O(|S |2 ) time to compute, giving a lower bound on the computation cost of dCC . It remains to show that the embedding U (Definition 8) may be obtained at this cost. We proceed by induction based on a post-order traversal of the treesh involved, τ ∈ TS . For the base case, i consider the two-leaf tree τ ∈ BT [2] , i.e. |S | = 2: then we simply assign U (τ) = 01 10 . For the induction step, assume |S | ≥ 3 and denote Ch (S , τ) = {S k }1≤k≤K , where K ≥ 2 is the number of children of the root S in τ. We observe: • For every singleton child {i} of S in τ (if any), then set U (τ)ii = 0, which takes up O(1) time. • Note that all clusters of τ and their sizes can be obtained in O(|S |2 ) time by a single post-order traversal, as each individual cluster (as well as its cardinality) takes at most linear time to compute from those of its children. • Suppose that for any 1 ≤ k ≤ K and |S k | ≥ 2 the elements of U (τ) associated with the subtree rooted at S k can PK PK be computed in O(|S k |2 ) time. Then, the total number of updates associated with the root S is k=1 l=1 |S k | |S l | and corresponds to setting U (τ)i j = U (τ) ji = |S | − 1 for all i ∈ S k , j ∈ S l and 1 ≤ k, l ≤ K. P P k.k1 denotes the 1-norm of a matrix, i.e. kUk1 : = ni=1 nj=1 Ui j for U ∈ Rn×n . Our choice of the 1-norm was guided by the resulting relationships between dCC and the dissimilarity measures dCM and dnav introduced below. Other choices of norm on RS ×S may prove useful. 4 Here 7 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 In total, the cost of obtaining U (τ) is PK O(|S k |2 ) + PK PK 8 |S k | |S l | + O(|S |2 ) = O(|S |2 ), as required.  o The diameter, diam (X, d) : = max d (x, y) x, y ∈ X , of a finite metric space (X, d) is always of interest in algorithmic applications. Some known diameters for hierarchies [3, 4, 28] are: k=1 n diam (TS , dRF ) = |S | − 2 , k=1 l=1 diam (BT S , d MS ) = O(|S |2 ) , diam (BT S , dNNI ) = O(|S | log |S |) (19) For the cluster-cardinality distance we have: Proposition 2. diam (TS , dCC ) = O(|S |3 ) . Proof. From Definition 8, the minimum and maximum ultrametric distances between two distinct elements of S are, respectively, 1 and |S | − 1, implying the bound   (20) max U (σ)i j − U (τ)i j ≤ |S | − 2 . i, j∈S Moreover, using the tight upper bound on the change of the cluster-cardinality distance after a single NNI move from Proposition 3, the diameter of TS with respect to dCC satisfies % $ 1 2 3 |S | ≤ diam (TS , dCC ) ≤ |S | (|S | − 1) (|S | − 2) , (21) 27 2  which completes the proof. A common question regarding any distance being proposed for the space of trees is how it behaves with respect to certain tree rearrangements. For instance, any pair of NNI-adjacent trees, σ, τ ∈ BT S , are known to satisfy [3] 5 dNNI (σ, τ) = 1 ⇐⇒ dRF (σ, τ) = 1 , dNNI (σ, τ) = 1 =⇒ 2 ≤ d MS (σ, τ) ≤ $ (22) % |S | . 2 (23) Similarly for dCC we have: Proposition 3. Let (σ, τ) be an edge of the NNI-graph NS = (BT S , E) and (A, B, C) be the associated NNI triplet (Lemma 1). Then $ % 2 3 2 ≤ dCC (σ, τ) = 2 |A| |B| |C| ≤ |S | , (24) 27 and both bounds are tight. Proof. Let P = A ∪ B ∪ C and recall from Lemma 1 that A ∪ B ∈ C (σ) and B ∪ C ∈ C (τ). Note that P ∈ C (σ) ∩ C (τ) is a common (grand)parent cluster, and A, B and C are pairwise disjoint. Since the NNI moves between σ and τ only change the relative relations of clusters A, B and C, the distance between σ and τ can be rewritten as 1 (25) U (σ) − U (τ) 1 , dCC (σ, τ) = 2 X X X U (σ)i j − U (τ)i j + = U (σ)i j − U (τ)i j + U (σ)i j − U (τ)i j , (26) i∈A j∈B = X i∈A j∈B i∈A j∈C |h (A ∪ B) − h (P)| + | {z } =|C| = 2 |A| |B| |C| . X i∈A j∈C |h (P) − h (P)| + | {z } =0 X i∈B j∈C i∈B j∈C |h (P) − h (B ∪ C)| , | {z } (27) =|A| (28) Clearly, the lower bound in (24) is realized when |A| = |B| = |C| = 1. Since the maximum product of three numbers with a prescribed   sum occurs when all the numbers are equal — in our case, |A| + |B| + |C| ≤ |S | — we must have |A| |B| |C| ≤ 5 ⌊.⌋ |S |3 27 , as . is integer-valued. The result follows. denotes the floor operator returning the largest integer not greater than its operand. 8  Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 9 Inequalities of the above form allow one to take advantage of the combinatorial nature of dNNI through repeated application of the triangle inequality: Corollary 1. Over BT S one has dRF ≤ dNNI . Indeed, the length of a path in NS produces a bound on the RF distance between its endpoints by repeatedly applying the triangle inequality to (22). A similar argument yields: Corollary 2. Let d be a dissimilarity on BT S with the property that d (σ, τ) ≤ 1 for any pair of NNI-adjacent hierarchies σ, τ ∈ BT S . If d (σ, τ) > dNNI (σ, τ) for some σ, τ ∈ BT S , then d is not a metric. 3.2. The Crossing Dissimilarity Definition 10. Let σ, τ ∈ TS . We define their compatibility matrix C (σ, τ) and their crossing matrix X (σ, τ) to be6 C (σ, τ)I,J : = 1 (I ⊲⊳ J) X (σ, τ)I,J : = 1 − C (σ, τ)I,J , and (29) where I ∈ C (σ) , J ∈ C (τ) and 1 (.) denotes the indicator function returning unity if its argument holds true and zero otherwise. The crossing dissimilarity dCM is defined by dCM (σ, τ) : = X (σ, τ) 1 , counting7 the pairs of incompatible PSfraginreplacements clusters C (σ) ∪ C (τ). We list some useful properties of dCM : Remark 3. The crossing dissimilarity dCM on BT S is positive definite and symmetric, but it is not a metric (apply Corollary 2 to the observations of Figure 3). dCM (σ, τ ) = 1 σ dCM (τ, γ) = 1 τ dN av (σ, τ ) = 1 1 2 3 4 γ dN av (τ, γ) = 1 1 3 2 4 1 2 3 4 dN av (σ, γ) = 3 dCM (σ, γ) = 3 Figure 3. dCM and dnav are not metrics: an example of the triangle inequality failing for both dissimilarities. Proposition 4. The crossing dissimilarity dCM over TS can be computed in O(|S |2 ) time. Proof. The crossing matrix X (σ, τ) (29) of a pair of hierarchies σ, τ ∈ TS has at most 2 |S | − 1 rows and columns. Hence, the 1-norm of X (σ, τ) requires O(|S |2 ) time to compute, bounding the cost of dCM from below. To obtain the upper bound, we show that X (σ, τ) can be obtained in O(|S |2 ) time by post-order traversal. Observe that for any cluster J ∈ C (τ) (and symmetrically, for any cluster of C (σ)) one can check whether J is disjoint with or a superset of each cluster I of σ by a post-order traversal of σ in O(|S |) time using the following recursion: • If either I or J is a singleton then the cluster inclusions I ⊆ J, J ⊆ I and their disjointness can be determined in constant time using a hash map. 6 C (σ, τ) and X (σ, τ) can be defined only in terms of nontrivial clusters of σ and τ since any trivial cluster of σ and τ is compatible with any cluster K ⊆ S . As a result, we are required to separately consider the special case in which one of the trees has only trivial clusters whenever C or X are used to reason about degenerate trees. 7 We find that choosing to use the 1-norm of the crossing matrix easily reveals combinatorial relations between d CM and dCC (18); of course, one could use other matrix norms to construct alternative dissimilarities. 9 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 10 • Otherwise (|I| ≥ 2 and |J| ≥ 2), we have I ⊆ J ⇐⇒ ∀D ∈ Ch (I, σ) I ∩ J = ∅ ⇐⇒ ∀D ∈ Ch (I, σ) D ⊆ J, D ∩ J = ∅. (30) (31) Thus, it follows from Definition 1 that a complete list of compatibilities between σ and τ can be produced in O(|S |2 ) time, and so X (σ, τ) can be obtained at the same cost, O(|S |2 ).  Proposition 5. diam (TS , dCM ) = (|S | − 2)2 . PSfrag replacements Proof. Two clusters of a pair of trees can only be incompatible if they are both nontrivial. Recall from Remark 1 that the number of nontrivial clusters of a tree in TS is at most |S | − 2. Hence, by Definition 10, an upper bound on diam (TS , dCM ) is (|S | − 2)2 . To observe that this upper bound is realized, see Figure 4.  dRF (σ, τ ) = n−2 σ τ dCM (σ, τ ) =(n−2)2 dN av (σ, τ ) = 21 (n−1)(n−2) 1 2 3 ..... n−1 n n 2 3 ..... n−1 1   Figure 4. A pair of nondegenerate hierarchies realizing diam T[n] , dCM = (n − 2)2 and diam BT [n] , dnav = 1 2 (n − 1) (n − 2). Proposition 6. Two nondegenerate trees σ, τ ∈ BT S are NNI-adjacent if and only if dCM (σ, τ) = 1. Proof. The result is evident from Remark 1 and Definition 4.  Despite the result of the last proposition, dCM does not provide a linear lower bound on dNNI since diam (BT S , dNNI ) = O(|S | log |S |) < diam (BT S , dCM ) = O(|S |2 ) (Proposition 5). This inequality provides us with an additional, more conceptual, argument that dCM is not a metric, by applying Corollary 2. 2 Proposition 7. Over TS one has dRF ≤ dCM ≤ dRF . These bounds are tight. Proof. The lower bound directly follows from Remark 1. Because a pair of distinct binary hierarchies always have uncommon clusters whose count is equal to dRF , and an unshared cluster of one tree crosses at least one unshared cluster of the other tree. This bound is tight since for any σ, τ ∈ BT S dRF (σ, τ) = 1 ⇔ dNNI (σ, τ) = 1 ⇔ dCM (σ, τ) = 1. (32) For any σ, τ ∈ BT S , the columns and rows of X (σ, τ) (29) associated with common clusters of σ, τ are necessarily null. Hence, X (σ, τ)I,J , 0 implies I < C (τ) and J < C (σ). By the definition of dRF , there are no more than dRF (σ, τ)2  such pairs — hence the claimed upper bound. To observe that this bound is also tight, see Figure 4. Proposition 8. Over TS one has dCM ≤ dCC . Proof. Given any σ, τ ∈ TS we claim that there is a function q : C (σ) × C (τ) → S × S with the following properties: (a) for any I ∈ C (σ) and J ∈ C (τ), I ⊲⊳ J if and only if (i, j) = q (I, J) with i = j, (b) for any i , j ∈ S , q−1 (i, j) ≤ U (σ)i j − U (τ)i j . Observe that, if such a function does exist, then (a) implies:   [ q−1 (i, j) = (I, J) ∈ C (σ) × C (τ) I 6⊲⊳ J . i, j∈S 10 (33) Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 11 It is then evident from (33) and (b) that dCM (σ, τ) ≤ X q−1 (i, j) ≤ dCC (σ, τ) , (34) i, j∈S proving our proposition. We proceed to construct the function q. If I 6⊲⊳ J, then there exist i ∈ I ∩ J and j ∈ I \ J with the property that (i∧ j)σ = I. Accordingly, define   Q (I, J) : = (i, j) ∈ S × S i ∈ I ∩ J, j ∈ I \ J, (i∧ j)σ = I , (35)   R (I, J) : = (i, j) ∈ S × S i ∈ I ∩ J, j ∈ J \ I, (i∧ j)τ = J . (36) Note that if (i, j) ∈ Q (I, J) ∪ R (I, J), then i , j. Have S totally ordered (say, by enumerating its elements) and have S × S ordered lexicographically according to the order of S . Then, define q : C (σ) × C (τ) → S × S to be    min (I ∪ J) , min (I ∪ J) , if I ⊲⊳ J,    min Q (I, J) , if I 6⊲⊳ J, |I| ≤ |J| , q (I, J) : =  (37)    min R (I, J) , if I 6⊲⊳ J, |I| > |J| . Recall that Q (I, J) and R (I, J) both contain pairs of distinct elements of S . Hence, q satisfies the property (a) above. By construction, for any i , j we have: q−1 (i, j) ⊆ A (i, j) ∪ B (i, j) , (38) where   (I, J) ∈ C (σ) × C (τ) I 6⊲⊳ J, |I| ≤ |J| , (i, j) ∈ Q (I, J) ,   B (i, j) : = (I, J) ∈ C (σ) × C (τ) I 6⊲⊳ J, |I| ≥ |J| , (i, j) ∈ R (I, J) . A (i, j) : = (39) (40) Remark from (35) that if (I, J) ∈ A (i, j) then (i∧ j)σ = I and (i∧ j)τ ) J. Hence, if (i∧ j)σ ≥ (i∧ j)τ , then A (i, j) = ∅. Similarly, (i∧ j)σ ) I and (i∧ j)τ = J whenever (I, J) ∈ B (i, j); and B (i, j) = ∅ if (i∧ j)σ ≤ (i∧ j)τ . Thus, one can observe that for any i, j ∈ S , A (i, j) , ∅ =⇒ B (i, j) = ∅. (41) Recall that for any i, j ∈ S and (I, J) ∈ A (i, j) we have: I = (i∧ j)σ , J ( (i∧ j)τ , |I| ≤ |J| and J ∈ Anc ({i} , τ) . (42) Hence, one can conclude that A (i, j) ≤ (i∧ j)τ − (i∧ j)σ = U (τ)i j − U (σ)i j . (43) B (i, j) ≤ (i∧ j)σ − (i∧ j)τ = U (σ)i j − U (τ)i j . (44) Similarly, for any i, j ∈ S Thus, overall, using (38) and (41), one can obtain the second property of q as follows: for any i , j ∈ S q−1 σ,τ (i, j) ≤ A (i, j) + B (i, j) ≤ U (τ)i j − U (σ)i j , (45)  which completes the proof. 11 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 12 4. The Navigation Dissimilarity Problem 1 may be loosely restated in graph-theoretic terms as follows: Problem 2. For each tree τ ∈ BT S , find a subgraph NS ,τ of the NNI graph NS containing no directed cycles and such that every σ ∈ BT S satisfies: (†) If σ , τ then there exists an edge of NS ,τ exiting σ; moreover, such an edge may be produced in low time complexity. Clearly, the reactive navigation algorithm Aτ of Problem 1 is, in this case, to compute an edge of NS ,τ exiting the input tree σ and then follow that edge. The challenge for us is to produce a graph (Definition 18) where (i) the complexity of Aτ is low (Corollary 5), and (ii) the length of any directed path is bounded by a reasonable function of dNNI (σ, τ), or, at least of n = |S | (Definition 19, Theorem 2 and Corollary 4). Observe the similarity between our requirements of NS ,τ and a skeletal variant of the stricter notion of a combing from the early days of geometric group theory (see, e.g. [29]): a ‘coherent’ system of paths {p x } x ∈ X in a topological space X, one for each point of the space, with p x (0) = x0 for all x ∈ X and py (t) = p x (t) for all t ≤ s whenever y = p x (s). Specializing to the differentiable setting, one might hope to be able to (efficiently) compute a tangent vector t x to p x at x in some open dense (and necessarily contractible) sub-manifold of X so that the p x become integral curves of ẋ = t x ; following these curves in reverse comprises reactive navigation towards x0 , as seen through the eyes of a roboticist [13]. We start out with a study of the coarse structure of the directed NNI graph NS . We consider special subspaces of the vertex space BT S : Definition 11. Let K1 , . . . , Km , m ≥ 1, be a compatible family of subsets of S . Denote: n o BT S (K1 , . . . , Km ) : = σ ∈ BT S σ ⊲⊳ {K1 , . . . , Km } Recalling that C (σ) is a maximal nested family in P (S ) if and only if σ ∈ BT S , one has, in fact: n o BT S (K1 , . . . , Km ) = σ ∈ BT S K1 , . . . , Km ∈ C (σ) (46) (47) Intuitively, it is clear that the problem of navigating NS towards a specified tree τ may be parsed into a sequence of problems, each being that of navigating in BT S (K) towards BT S (K) ∩ BT S (Ch (K, τ)), where K ranges over C (τ), starting with K = S and continuing inductively, provided each step preserves the achievements of its predecessors. 4.1. Resolving incompatibilities with a prescribed split Throughout this section, let K = {K1 , K2 } be a fixed pair of disjoint non-empty subsets of S , and set K = K1 ∪ K2 . We will refer to such pairs as partial splits. Let us make a simple observation: Lemma 5. The following equivalence holds for all I ( K: I ⊲⊳ K ⇐⇒ (I ⊆ K1 ) ∨ (I ⊆ K2 ) (48) Proof. Suppose I ⊲⊳ K but neither I ⊆ K1 nor I ⊆ K2 holds. By Definition 1 we must then have I ⊇ K1 and I ⊇ K2 , implying I ⊇ K — contradiction to I ( K. The converse is trivial.  Let σ ∈ BT S (K) be a tree which splits K into a pair of children not coinciding with K. According to the preceding lemma, this is equivalent to Ch (K, σ) 6⊲⊳ K. Observe now that any cluster I ∈ C (σ) which is not a σ-descendant of K is automatically compatible with K. Thus, incompatibilities of σ with K could only occur among σ-descendants of K. This motivates the following definition: Definition 12 (Recombinants). For σ ∈ BT S (K) we distinguish two classes of σ-descendants of the cluster K: n o I (σ; K) : = I ∈ Des (K, σ) I 6⊲⊳ K , (49) n o  −σ R (σ; K) : = I ∈ I (σ; K) Ch (I, σ) ⊲⊳ K , Ch I , σ ⊲⊳ K (50) For lack of a better term, we will refer to the elements of R (σ; K) as recombinants of K in σ. See Figure 5. 12 PSfrag replacements Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 13 The set of recombinants suffices to characterize the compatibility of a tree with a given split: replacements Lemma 6. Observe that σ ∈ BT S (K) hasPSfrag recombinants of K if and only if σ < BT S (K). Proof. Indeed, if σ ∈ BT S (K), then all clusters of σ are compatible with K, causing I (σ; K) — and hence also R (σ; K) — to be empty. Conversely, suppose there is a cluster of σ incompatible with K. Then the σ-children of any deepest such cluster and its local complement’s children are compatible with K in σ, and their children are compatible with K as well (even if vacuously).  σ σ τ K A B B −σ I (σ; K) R (σ; K) I (σ; K) K τ K1 K2 1 7 4 5 9 3 8 2 6 B R (σ; K) A 1 B −σ 2 3 4 5 6 7 8 9 Figure 5. An illustration of I (σ; K) (49) and R (σ; K) (50) of σ ∈ BT [n] (K), where n ≥ 9 and K = [9]. The vertices and edges associated with clusters of σ incompatible with the split K are thickened. The only recombinant of K in σ is A = {1, 2} and it has Type 1. B and B−σ are examples of Type 2 clusters of σ incompatible with K which are not recombinants. Definition 13 (Incompatibility Types). Given σ ∈ BT S (K), a cluster I ∈ I (σ; K) is said to be of type 1 with respect to K if I −σ ⊲⊳ K. If I ∈ I (σ; K) is not of type 1, then it is said to be of type 2 (see Figure 5). Another, perhaps less intuitive, quantifier of incompatibility arises as follows: Definition 14 (Essential Crossing Index). Let K = {K1 , K2 } and L = {L1 , L2 } be partial splits. Their essential crossing index is defined as:   0 if L K ∪K ⊲⊳ K L ∪L   1 2 1 2   (51) [[L | K]] : =  1 if L j K ∪K ⊲⊳ K L ∪L for only one j ∈ {1, 2}  1 2 1 2    3 otherwise For a tree σ ∈ BT S we define: kσkK : = X [[Ch (I, σ) | K]] (52) I∈C(σ) The following elementary observations will be useful: Lemma 7. Let K = {K1 , K2 } and L = {L1 , L2 } be partial splits. Then [[K | L]] = [[L | K]]. Proof. Write K = K1 ∪ K2 and L = L1 ∪ L2 . Without loss of generality we may assume K = L = S , since: 2 2 [ [ (Ki ∩ L) = (L j ∩ K) = K ∩ L . i=1 (53) j=1 We study the possible cases: • [[L | K]] = 0: By definition, this means none of the Ki crosses any of the L j ; equivalently, no L j crosses any of the Ki and we have [[K | L]] = 0. • [[L | K]] = 1: WLOG, only L1 crosses K, hence L2 is contained in one of the Ki , say K2 . Then L1 contains K1 and at least one element of K2 , by Lemma 5. Thus, K1 ⊲⊳ L while K2 ⊲⊳ L2 , K2 6⊲⊳ L1 . This means [[K | L]] = 1. 13 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 14 • [[L | K]] = 3: if both L1 and L2 cross K, then L j ∩ Ki , ∅ for all i, j ∈ 1, 2, implying both K1 and K2 cross L, as desired.  We are now ready to construct the graph ΓS (K): Definition 15 (Projector Graph). Let K = {K1 , K2 } be a partial split, and set K = K1 ∪ K2 . Then ΓS (K) is defined to be the directed graph with vertex set BT S (K), and all edges of the form (σ, G) ∈ e E such that I : = Pr (G, σ) ∈ R (σ; K) and one of the following holds: 1. I is of type 1, and G−σ , I −σ ⊆ Ki for some i ∈ {1, 2}; 2. I is of type 2. PSfrag replacements σ′ σ I (σ, G) G I −σ PSfrag replacements σ′ σ σ ′′ σ ′′′ (σ, G) I I −σ G Figure 6. Different types of incompatibility — Type 1 (above) and Type 2 (below) — of a tree σ ∈ BT S (K), K = K1 ∪ K2 , with the split K = {K1 , K2 }, and the NNI moves suggested by ΓS (K) to resolve them. Clusters are colored blue or red according to their being contained in K1 or K2 , respectively. Thickened vertices represent the recombinants affected by these moves. The following elementary property of edges in ΓS (K) is crucial: Lemma 8. Suppose σ ∈ BT S (K), (σ, G) is an edge of ΓS (K) and τ = NNI(σ, G). Then kσkK = kτkK + 1. Proof. Let I = Pr (G, σ) and let J = I −σ ∪G−σ be the cluster replacing I in τ. Also, set M = Pr2 (G, σ) ∈ C (σ) ∩ C (τ). In the transition from σ to τ only the clusters I, J and M change (or lose, or acquire) their child splits. Therefore: kτkK = kσkK − [[Ch (I, σ) | K]] + [[Ch (J, τ) | K]] − [[Ch (M, σ) | K]] + [[Ch (M, τ) | K]] (54) Figure 6 demonstrates without loss of generality that, in the case when I is of type 1 with respect to K the values of the above crossing indices are 0, 0, 1 and 0, respectively, resulting in a total decrease of one unit. The case when I is of type 2 produces the respective values of 0, 1, 3 and 1, also resulting in a total decrease of one unit.  Lemma 9. The following are equivalent for a vertex σ ∈ BT S (K) of ΓS (K): 1. kσkK > 0; 2. ΓS (K) contains an edge exiting σ; 3. σ < BT S (K). Proof. First observe that, since K is a cluster of σ, all clusters I ′ ∈ C (σ) not contained in K have [[I ′ | K]] = 0. (1) ⇒ (2). By the preceding observation, if kσkK > 0 then σ has a sub-cluster of K whose child split is incompatible with K. By Lemma 6, σ then has a cluster I ( K which is a recombinant of K. Picking G to be an appropriate σ-child of I provides the required edge (σ, G). (2) ⇒ (3). Suppose (σ, G) is an edge in ΓS (K). Then I := Pr (G, σ) is incompatible with K, proving (3). (3) ⇒ (1). Finally, if σ < BT S (K) then σ contains a recombinant I whose parent M = Pr (I, σ) then must satisfy [[Ch (M, σ) | K]] > 0, resulting in kσkK > 0.  14 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 15 Definition 16 (Projection). Let K = {K1 , K2 } be a partial split, and set K = K1 ∪ K2 . For any σ ∈ BT S (K) we define its projection to BT S (K) ∩ BT S (K) to be the tree γ = PS (σ; K) ∈ BT S (K) ∩ BT S (K) whose clusters are of one of the following forms: (a) I ∈ C (σ) with I ∩ K = ∅ or K ⊆ I; (b) I ∩ Ki ∈ C (γ), i ∈ {1, 2} where I ∈ C (σ) (and I ⊆ K). Remark 4. The tree PS (σ; K) is a well-defined binary tree in BT S (K) ∩ BT S (K) by Lemma 2 (applied to BT K ). We are ready to state the main result of this section: Theorem 1. The directed graph ΓS (K) contains no directed cycles. Moreover, for every σ ∈ BT S (K), every maximal directed path of ΓS (K) emanating from σ terminates at the tree PS (σ; K) ∈ BT S (K) ∩ BT S (K) and has length kσkK . Proof. Denote Γ: =ΓS (K) for short. By Lemma 8, the function k·kK decreases by a unit along each edge of Γ, implying the absence of directed cycles in the graph. In particular, for each σ ∈ BT S (K), the length of a directed path in Γ emanating from σ is bounded above by kσkK . Since, by Lemma 9, σ ∈ BT S (K) has an exiting edge in Γ if and only if kσkK > 0, we conclude that all maximal directed paths in Γ emanating from σ have length exactly kσkK and terminate in BT S (K) ∩ BT S (K). It will be useful to henceforth denote o n (55) PathK (σ) : = p p is a maximal directed path in ΓS (K) emanating from σ It remains to prove that every p ∈ PathK (σ) terminates in PS (σ; K). We will prove the remaining assertion of the proposition by induction on kσkK . More precisely, for any nonnegative integer k let S (k) denote the statement that for every τ ∈ BT S (K) satisfying kτkK ≤ k every path in PathK (τ) terminates in PS (τ; K). Observing that S (0) holds true by construction, we assume S (k) holds for some k ≥ 0 and deduce S (k + 1). Suppose σ has kσkK = k + 1. Once again, consider any directed edge (σ, G) in ΓS (K), and write τ = NNI(σ, G) with kτkK = k. Let γ and γ′ denote the projections of σ and τ to BT S (K) ∩ BT S (K). Finally, letting I = Pr (G, σ) and J = G−σ ∪ I −σ we recall that C (τ) = (C (σ) r {I}) ∪ {J}. We observe the following: • For any set Q ⊆ S satisfying Q ∩ K = ∅ ∨ K ⊆ Q and for any tree σ′ lying on a path in PathK (σ) — for the trees τ, γ and γ′ in particular — one has Q ∈ C (σ) if and only if Q ∈ C (σ′ ). Thus, C (γ) \ C (γ′ ) consists only of proper subsets of K. • For a cluster Q ⊆ K of σ with Q , I we have Q ∩ Ki ∈ C (γ) =⇒ Q ∩ Ki ∈ C (γ′ ) for i ∈ {1, 2} because C (σ) r {I} ⊂ C (τ). • Finally, we consider the clusters I ∩ Ki : since I ∈ R (σ; K), the sets I ∩ Ki are precisely the children of I in σ, which makes them clusters of τ; since I ∩ Ki ⊂ Ki , they are also clusters of γ′ . To summarize, we have found out that C (γ) ⊆ C (γ′ ). By the maximality of C (γ) as a nested family (Remark 1 and Remark 4) they must be equal and we conclude that γ = γ′ . Applying the induction hypothesis, we deduce that every path in PathK (σ) starting with the edge (σ, G) must terminate in γ. Since the choice of edge (σ, G) was arbitrary, we are done.  4.2. The Navigation Distance The following result has the flavor of a commutation relation between different projector graphs: Lemma 10. Fix a pair of distinct partial splits K = {K1 , K2 } and L = {L1 , L2 }. Setting K = K1 ∪ K2 and L = L1 ∪ L2 assume in addition that {K, K1 , K2 } ⊲⊳ {L, L1 , L2 }. Then, for any σ ∈ BT S (K) and any edge (σ, G) ∈ ΓS (K) one has kNNI(σ, G)kL = kσkL . 15 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 16 Proof. As before, set τ = NNI(σ, G) and consider the sets I = Pr (G, σ), J = G−σ ∪ I −σ and M = Pr2 (G, σ) — all contained in the cluster K ∈ C (σ) ∩ C (τ) — and recall that C (τ) = (C (σ) r {I}) ∪ {J}. Without loss of generality, G ⊆ K1 and G−σ ⊆ K2 . Once again we observe that the transition from σ to τ affects only the crossing indices of the clusters I, J, M (which are all contained in K) as follows: kτkL = kσkL − [[Ch (I, σ) | L]] + [[Ch (J, τ) | L]] − [[Ch (M, σ) | L]] + [[Ch (M, τ) | L]] {z } | {z } | {z } | {z } | α γ β (56) δ Note that K , L, since otherwise the compatibility assumption and Lemma 5 would have forced K = L. Suppose now that K ∩ L = ∅. In this case the restrictions of L to I, J, M are all trivial and the corresponding crossing indices are all zero. Suppose K ( L. Then, without loss of generality, we have K ⊆ L1 by Lemma 5 and all children of I, J, M in σ and τ (as relevant) are compatible with L, resulting again in zero crossing indices. Since K ⊲⊳ L, K , L, we need only consider two cases (we refer the reader again to Figure 6 for an illustration): • L ⊆ K1 . We have Ch (I, σ) L = {G ∩ L, ∅} and therefore α = 0. Also, Ch (J, τ) Finally, Ch (M, σ) L = Ch (M, τ) L = {G ∩ L, I −σ ∩ L} produces γ = δ. L = {∅, I −σ ∩ L}, so that β = 0. • L ⊆ K2 . In this case we have Ch (I, σ) L = {∅, G−σ ∩L} and α is zero again. Similarly, observe that Ch (M, τ) {∅, J ∩ L} gives δ = 0. At the same time, Ch (J, τ) L = Ch (M, σ) L = {G−σ ∩ L, I −σ ∩ L}, so that β = γ. L =  This finishes the proof. Any pair of binary trees in BT S has a common cluster (the cluster S , for example), and one might hope to quantify the discrepancy between a pair of trees by counting common clusters which split differently in the two trees (perhaps, somehow accounting for the depth of these clusters). This motivates: Definition 17. For any σ, γ ∈ BT J , let K (σ, γ) denote the set n o K (σ, γ) : = K ∈ C (σ) ∩ C (γ) Ch (K, σ) , Ch (K, γ) . Remark 5. It is easy to see that, in BT S , σ = τ if and only if K (σ, τ) = ∅. o n Corollary 3. For all σ, τ ∈ BT S we have K (σ, τ) : = K ∈ C (σ) ∩ C (τ) Ch (K, σ) 6⊲⊳ Ch (K, τ) . Proof. Follows directly from Lemma 5 and the definitions. (57)  Given a prescribed target tree τ ∈ BT S , the projector graphs introduced above give rise to a tool for achieving planned reductions in the number of clusters in K (σ, τ) at a given depth, for any tree σ ∈ BT S . More formally, consider the following construction: Definition 18 (Navigation Graph). Let τ ∈ BT S . Then NS ,τ denotes the directed subgraph of the NNI graph NS with vertex set BT S and all the edges (σ, G) for which there exists a cluster K ∈ K (σ, τ) satisfying (σ, G) ∈ ΓS (Ch (K, τ)). We proceed to prove statements about the navigation graph analogous to those we have shown to hold for the projector graphs. It is time to introduce: Definition 19 (Navigation Distance). Let σ, τ ∈ BT S . We define the navigation distance from σ to τ to be: X kσkCh(K,τ) dnav (σ, τ) : = K∈C(τ) = X X [[Ch (L, σ) | Ch (K, σ)]] (58) (59) K∈C(τ) L∈C(σ) We also define the special crossing matrix S (σ, τ) by S (σ, τ)K,L := [[Ch (L, σ) | Ch (K, τ)]] , ∀K ∈ C (σ) , L ∈ C (τ) . Thus, dnav coincides with the standard 1-norm of the special crossing matrix. 16 (60) Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 17 Theorem 2. For any τ ∈ BT S the graph NS ,τ has no directed cycles. Moreover, for any σ ∈ BT S every maximal directed path in NS ,τ emanating from σ terminates in τ and has length dnav (σ, τ). We will refer to such paths as navigation paths from σ to τ. Proof. First, observe from equation (58) that dnav (σ, τ) is zero if and only if kσkK = 0 for every pair K of siblings in τ. By Lemma 9, this is equivalent to saying that σ ∈ BT S (K) for every pair of siblings in τ, or, in other words, that σ = τ. Moreover, note that dnav (σ, τ) > 0 implies there is an edge of NS ,τ exiting σ: indeed, if σ , τ then there exists a K ∈ K (σ, τ) (Remark 5), so that σ < BT S (Ch (K, τ)); Lemma 9 guarantees an edge of ΓS (Ch (K, τ)) exiting σ, which, by definition, is also an edge of NS ,τ . Suppose now (σ, G) is an edge in NS ,τ . That is, there exists K ∈ K (σ, τ) such that (σ, G) ∈ ΓS (K) where K = Ch (K, τ). Suppose there were more than one such K, that is: suppose K, L ∈ K (σ, τ), K , L, such that I := Pr (G, σ) is contained in both K and L, and such that Ch (I, σ) is incompatible both with Ch (K, τ) and Ch (L, τ). Since ∅ , I ⊆ K ∩ L and K ⊲⊳ L, we may assume K ( L. But then K, L ∈ C (τ) and K , L implies K is contained in a τ-child of L, denoted L1 . As I ⊆ K, we conclude that both σ-children of I are contained in L1 — a contradiction to the assumption that Ch (I, σ) and Ch (L, τ) are incompatible. Let σ′ = NNI(σ, G). Then, by Lemma 8, we have kσ′ kCh(K,τ) = kσkCh(K,τ) − 1. Moreover, Lemma 10 guarantees ′ kσ kCh(L,τ) = kσkCh(L,τ) for all L ∈ C (τ), L , K. Applying equation (58) we obtain dnav (NNI(σ, G), τ) = dnav (σ, τ) − 1 . (61) Thus, NS ,τ contains no directed cycles, and every maximal directed path in NS ,τ emanating from a fixed σ ∈ BT S terminates after precisely dnav (σ, τ) steps. By the preceding paragraph, every such path may only terminate in τ.  The solution to the navigation problem implied by this theorem yields the following (very crude) bounds on the performance of the corresponding reactive navigation algorithm: Corollary 4 (Navigation Complexity). The length of a navigation path through NS does not exceed O(|S |2 ). Proof. Let n = |S |. For all σ, τ ∈ BT S we have |C (τ)| = O(n), implying S (σ, τ) has O(n2 ) entries. The value of  dnav (σ, τ) never exceeds three times the number of entries in S (σ, τ). Corollary 5. Given σ, τ ∈ BT S , computing an edge of NS ,τ exiting σ may be done in O(|S |) time. Proof. Using a look-up table for the clusters of τ [2], a cluster K ∈ K (σ, τ) may be found in linear time by a traversal of σ. Next, an appropriate recombinant cluster may be found in linear time by post-order traversal of σ K (compare with proof of Proposition 1).  The last theorem emphasizes the crucial role of the fact that all navigation paths from σ to τ have the same length, equal to dnav (σ, τ), irrespective of the order in which one chooses to resolve the incompatibilities between the two trees. We will now consider additional applications of the last theorem which will help us clarify the geometry of the navigation distance and its relationship to the other dissimilarities mentioned in this paper. Lemma 11. Let K = {K1 , K2 } be a partial split, let τ ∈ BT S (K1 , K2 , K1 ∪ K2 ) and σ ∈ BT S (K1 ∪ K2 ). Then: (a) ΓS (K) is contained in NS ,τ ; (b) Let σ′ = PS (σ; K), then: (c) Finally, dnav   dnav (σ, τ) = dnav σ, σ′ + dnav σ′ , τ  σ, BT S (K1 , K2 , K1 ∪ K2 ) = kσkK . (62) Proof. For Lemma 11(a), let (σ, G) be an edge of ΓS (K). In particular, σ < BT S (K) so that K ∈ K (σ, τ) which produces (σ, G) ∈ NS ,τ by definition. For Lemma 11(b), let p be a maximal path in ΓS (K) emanating from σ. Then the endpoint of p is σ′ := PS (σ; K) by Theorem 1. Now apply Lemma 11(a) and Theorem 2 to extend p to a navigation path e p in NS ,τ from σ to τ. Then:    (63) p = ℓ ( p ) + dnav σ′ , τ = kσkK + dnav σ′ , τ , dnav (σ, τ) = ℓ e 17 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 18 as required. Finally, for Lemma 11(c), pick τ above to be a tree of BT S (K1 , K2 , K1 ∪ K2 ) with dnav (σ, τ) minimal. By the construction above, σ′ ∈ BT S (K1 , K2 , K1 ∪ K2 ) satisfies dnav (σ, σ′ ) ≤ dnav (σ, τ) while p is a navigation path from σ  to σ′ . Thus σ′ must coincide with τ, and (63) reduces to the desired equality. Corollary 6. For any bipartition {L, R} of S and σ ∈ BT S , the navigation distance dnav (σ, BT S (L, R)) can be computed in linear time, O(|S |). Proof. Similarly to the proof of Proposition 4, the crossing indices of σ-clusters with {L, R} can be determined in O(|S |) time using Lemma 5 and by post order traversal of σ. Therefore, by Lemma 11 and Theorem 1, the quantity  dnav (σ, BT S (S L , S R )) can be computed in O(|S |) by a complete traversal of σ. Lemma 12. For any bipartition {L, R} of S and σ ∈ BT S , an NNI navigation path in ΓS (L, R) joining σ to BT S (L, R) can be computed in O(|S |) time. Proof. As illustrated in Figure 5, since Anc (I, σ) ⊆ I (σ; {L, R}) ∪ {S } for any I ∈ I (σ; {L, R}), the vertices and branches of σ associated with clusters in I (σ; {L, R}) ∪ {S } defines a tree structure, containing all the information required to compute the navigation distance dnav (σ, BT S ) (L, R) = kσk{L,R} (Lemma 11.(c)). Hence, one can construct an NNI navigation path by a complete post-order traversal of this tree structure as follows: 1. Set k ← 0 and σ0 ← σ, and compute I (σ0 ; {L, R}). 2. Find a cluster I0 ∈ R (σ0 ; {L, R}) by a post-order traversal of incompatible clusters I (σ0 ; {L, R}) of σ0 . 3. While (I (σk ; {L, R}) , ∅) (a) If Ik ∈ R (σk ; {L, R}) is Type 1, then, as illustrated in Figure 6(top), choice a grandchild Gk ∈ Ch (Ik , σk ) such that Gk −σk , Ik −σk ⊆ L or Gk −σk , Ik −σk ⊆ R, and set σk+1 ← NNI (σk , Gk ) , I (σk+1 ; {L, R}) ← I (σk ; {L, R}) \ {Ik } , Ik+1 ← Pr (Ik , σk ) , k ← k + 1. (b) If Ik ∈ R (σk ; {L, R}) is Type 2, then, as illustrated in Figure 6(bottom), choice Gk ∈ Ch (Ik , σk ) and  Gk+1 ∈ Ch Ik −σk , σk such that Gk , Gk+1 ⊆ L or Gk , Gk+1 ⊆ R, and Gk+2 = Gk −σk ∪ Gk+1 −σk ; and set σk+1 ← NNI (σk , Gk ) , σk+2 ← NNI (σk+1 , Gk+1 ) , σk+3 ← NNI (σk+2 , Gk+2 ) ,  I (σk+3 ; {L, R}) ← I (σk ; {L, R}) \ Ik , Ik −σk , Ik+3 ← Pr (Ik , σk ) , k ← k + 3.  (c) Otherwise (Ik and Ik −σk are Type 2 with Ch (Ik , σk ) ⊲⊳ {L, R} and Ch Ik −σk , σk 6⊲⊳ {L, R}), find a cluster Jk ∈ R (σk ; {L, R}) by a post-order traversal of incompatible clusters of the subtree of σk rooted at Ik −σk , and set Ik ← Jk .  4. Return σk k∈[0, kσk{L,R} ] as an NNI navigation path starting at σ and ending in BT S (L, R). As discussed in the proof of Proposition 4, all clusters of σ incompatible with {L, R}, i.e. I (σ; {L, R}) in Step 1, can be determined in O(|S |) time. Given I (σ; {L, R}), a cluster I ∈ R (σ; {L, R}), in Step 2, can be found in O(|I (σ; {L, R})|) ≤ O(|S |) time by a post-order traversal of incompatible clusters of σ. Observe that the while loop terminates after at most 2 |I (σ; {L, R})| iterations after a complete traversal of the tree structure defined by I (σ; {L, R}) ∪ {S } since |I (σk ; {L, R})| decreases at least by one unit after every two consecutive iterations and a post-order subtree traversal in Step 3(c) is required only if the associated subtree is not explored yet. Hence, an NNI  navigation path joining σ to BT S (L, R) can be found by a complete post-order traversal of σ in O(|S |) time. The observation made in Lemma 11 is a good example of how the dual representation of dnav — both in terms of paths in the NNI graph, and in terms of a closed-form formula quantifying inter-cluster incompatibility — offers a practical compromise between the heretofore separate traditional approaches to constructing dissimilarities on BT S , those of edge comparison and of estimation of edit distances. A particular application of this dual nature is the decomposability of dnav (as defined in [30]): 18 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 19 Lemma 13 (Root Split Reduction). Fix τ ∈ BT S and denote {L, R} := Ch (S , τ). Then for any σ ∈ BT S one has:     (64) dnav (σ, τ) = dnav (σ, BT S (L, R)) + dnav σ L , τ L + dnav σ R , τ R Proof. By Lemma 11(2) it suffices to prove     dnav (PS (σ; L, R), τ) = dnav σ L , τ L + dnav σ R , τ R (65)     σ ∈ BT S (L, R) ⇒ dnav (σ, τ) = dnav σ L , τ L + dnav σ R , τ R (66)     By definition, C (PS (σ; L, R)) = {S } ∪ C σ L ∪ C σ R so it suffices to prove:     At this stage, however, observe that C σ L and C σ R together exhaust the list of of clusters of σ not equal to S , with the same holding ab initio for τ. This allows us to finish the proof by applying Theorem 2 separately in BT L and BT R .  The root split reduction of the NNI navigation dissimilarity may be used for its efficient computation: Corollary 7. The NNI navigation dissimilarity dnav on BT S is computable in O(|S |2 ) time. Proof. Let σ, τ ∈ BT S and {L, R} = Ch (S , τ). By the root split reduction above and the last corollary, dnav (σ, τ) requires the computation of dnav (σ, BT S (Ch (S , τ))) at a cost of O(|S |) time, plus the computation of the restrictions σ L and σ R , each of which can be computed using post-order traversal of σ in O(|S |) time. Hence, computing dnav (σ, τ) requires a complete (depth-first) traversal of τ with each stage incurring at most a linear time cost in |S |.  Corollary 8. An NNI navigation path joining σ ∈ BT S to τ ∈ BT S can be computed in O(|S |2 ) time. Proof. Similar to the recursive expression of dnav in Lemma 13, an NNI navigation path joining σ to τ can be found using the decomposability property within a divide-and-conquer approach as follows: first obtain an NNI navigation path from σ to BT S (Ch (S , τ)) in O(|S |) (Lemma 12) and then find NNI navigation paths between subtrees. Hence, this requires the pre-order traversal of τ each of whose step costs O(|S |). Thus, an NNI navigation path joining σ to τ can be recursively computed in O(|S |2 ) time, which completes the proof.  4.3. Properties of the Navigation Dissimilarity Proposition 9. The NNI navigation dissimilarity dnav is positive definite and symmetric, but it is not a metric. Proof. That dnav is positive definite follows directly from its definition. Lemma 7 proves it is symmetric and Corollary 2 with Figure 3 shows where the triangle inequality fails.  Lemma 14. Let {L, R} be a bipartition of S and σ ∈ BT S . Then we have the tight bound: dnav (σ, BT S (L, R)) ≤ |S | + min (|L| , |R|) − 3. (67) Proof. Denote S = {L, R}. For any σ ∈ BT S and I ∈ C (σ) observe that (i) [[Ch (I, σ) | S]] = 0 if I is a singleton or |I| = 2, and (ii) otherwise for larger clusters [[Ch (I, σ) | S]] equals 3 or 1 only if, respectively, both clusters or only one cluster of Ch (I, σ) are incompatible with S. Since there are at least |S | + 1 clusters of the first kind, there are at most |S | − 2 clusters of the second kind. Thus, applying Lemma 11 and Theorem 1 we have dnav (σ, BT S (L, R)) ≤ (|S | − 2) + |X| , (68) where X is the set of all I ∈ C (σ) both of whose children are incompatible with S. For each I ∈ X both I ∩ L and I ∩ R are non-singleton clusters of σ L and σ R , respectively (each child of I intersects each of L, R). Suppose now that I, J ∈ X are distinct. There are two cases, without loss of generality: • If I ∩ J = ∅, then I ∩ L , J ∩ L (and similarly for R); 19 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 20 • If I ( J, then J has a child I ′ disjoint from I, and this child must intersect L. Hence, I ∩ L ( J ∩ L.     We conclude that the map I 7→ I ∩ L (respectively I ∩ R) of X to C σ L (resp. to C σ R ) is injective, and has no singleton clusters in its image. Thus, |X| ≤ min (|L| − 1, |R| − 1), proving the desired inequality. The example σ, τ ∈ BT [n] in Figure 4 with {L, R} = Ch ([n] , τ) = {{1} , {2, 3, . . . , n}} shows that the upper bound in  (67) is tight (where dnav (σ, BT S (L, R)) = n − 2). Proposition 10. diam (BT S , dnav ) = 1 2 (|S | − 1) (|S | − 2) . Proof. We proceed by induction over |S |, with the base case |S | = 2 satisfying |BT S | = 1. The formula then holds trivially, as dnav = 0.   For the induction step assume |S | ≥ 3 and that σ, τ ∈ BT S satisfy dnav σ K , τ K ≤ 12 (|K| − 1) (|K| − 2) for every K ∈ Ch (S , τ) = {L, R}. Let µ = min (|L| , |R|), and note that |L| |R| = µ(|S | − µ). We now apply the root split reduction (Lemma 13):     (69) dnav (σ, τ) = dnav (σ, BT S (L, R)) + dnav σ L , τ L + dnav σ R , τ R , | {z } | {z } | {z } by Lemma 14 ≤ |S |+µ−3 ≤ 1 2 ≤ 1 2 ≤ by induction (|L|−1) (|L|−2) 1 2 ≤ by induction (|R|−1) (|R|−2) 1 2 (|S | − 1) (|S | − 2) + (1 − µ) (|S | − µ − 2) , | {z } (70) non-positive whenever |S |≥3 (|S | − 1) (|S | − 2) . Finally, note that the trees in Figure 4 realize this bound on the diameter. (71)  4.4. Relations with Other Tree Measures Like dCM (Proposition 7), dnav is tightly bounded in terms of dRF as follows: 2 + 12 dRF and both bounds are tight. Proposition 11. Over BT S one has dRF ≤ dnav ≤ 21 dRF Proof. Since dnav is realized by paths in the NNI graph we have dNNI ≤ dnav . The lower bound then follows from dRF ≤ dNNI (Corollary 1). The bound is tight because dRF (σ, τ) = 1 ⇔ dNNI (σ, τ) = 1 ⇔ dnav (σ, τ) = 1. (72) For the upper bound we argue by induction over |S |, keeping in mind that for |S | = 2 the result holds trivially. Suppose |S | ≥ 3. Now, if σ and τ have no common nontrivial clusters then dRF (σ, τ) = |S | − 2 and the result follows from Proposition 10. Otherwise, let I ∈ C (σ) ∩ C (τ) be a nontrivial cluster and consider the tree σ′ obtained from σ by replacing the branch σ I with the branch τ I . By theorem Theorem 2 and by the definition of dRF , respectively, we have:   (73) dnav (σ, τ) = dnav σ, σ′ + dnav σ′ , τ   ′ ′ (74) dRF (σ, τ) = dRF σ, σ + dRF σ , τ   Let α = dRF (σ, σ′ ) and β = dRF (σ′ , τ). Since dnav (σ, σ′ ) = dnav σ I , σ′ I we may apply the induction hypothesis in BT I to conclude dnav (σ, σ′ ) ≤ 12 α(α + 1). By pruning the trees σ′ and τ at cluster I we may apply the induction hypothesis in BT S̄ , where S̄ is the result of contracting I to a single vertex, to conclude that dnav (σ′ , τ) ≤ 21 β(β + 1). It then follows that: dnav (σ, τ) ≤ 12 α (α + 1) + 12 β (β + 1) ≤ 1 2 (α + β) (α + β + 1) = 21 dRF (σ, τ) (dRF (σ, τ) + 1) . (75)  Proposition 10 ensures this bound is tight. Proposition 12. Over BT S one has dnav (σ, τ) ≤ 23 dCM (σ, τ) . 20 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 21 Proof. Consider the closed form expression of dnav (59) in terms of crossing indices. Since the trivial clusters are compatible with any subset of S , it will suffices to verify that, for each I ∈ C (σ) and J ∈ C (τ), one has: X X [[Ch (I, σ) | Ch (J, τ)]] ≤ 32 1 (A 6⊲⊳ B) (76) A∈Ch(I,σ) B∈Ch(J,τ)  This verification is straightforward. The overall ordering of tree dissimilarities in Corollary 1, Proposition 8 and Proposition 12 can be combined as: Theorem 3. For non-degenerate hierarchies, 2 2 2 dRF ≤ dNNI ≤ dnav ≤ dCM ≤ dCC . 3 3 3 (77) Finally, we remark that the NNI navigation dissimilarity dnav (Definition 19) can be generalized to a pair of trees, σ and τ, in TS as  1 S (σ, τ) 1 + S (τ, σ) 1 , (78) dnav (σ, τ) = 2 which is non-negative and symmetric. For non-degenerate trees σ, τ ∈ BT S one has S (σ, τ) = S (τ, σ)T (which is evident from (60) and Lemma 7), so that dnav in (78) simplifies back to (59).8 Although the closed form expression of dnav in Theorem 2 enables the generalization of dnav to degenerate trees as above, the notion of NNI moves (Definition 4) is generally not valid in TS . As for non-degenerate trees in Proposition 12, the generalized dnav in TS can be bounded above by dCM as follows:   Proposition 13. Over TS one has dnav ≤ 18 |S |2 + 41 |S | dCM . Proof. Note that the number of nontrivial children of a cluster in a tree can be at most 12 |S |. Hence one can verify the result following similar steps as in the proof of Proposition 12.  5. Discussion and Statistical Analysis 5.1. Consensus Models and Median Trees Let us recall a definition : a median tree of a set of sample trees is a tree whose sum of distances to the sample trees is minimum. Although the notion of a median tree is simple and well-defined, finding a median tree of a set of trees is generally a hard combinatorial problem. On the other hand, a consensus model of a set of sample trees is a computationally efficient tool to identify common structures of sample trees. In particular, a remark relating dCM and dnav to commonly used consensus models of a set of trees and their median tree(s) is: Proposition 14. Both the strict and loose consensus trees, T ∗ and T ∗ , of any set of trees T in TS (Definition 3) are median trees with respect to both the crossing (dCM ) and navigation (dnav ) dissimilarities. In fact, for any d ∈ {dCM , dnav } one has: X X d (τ, T ∗ ) = 0. (79) d (τ, T ∗ ) = τ∈T τ∈T Proof. By Definition 3, both strict and loose consensus trees only contain clusters that are compatible with the clusters of every tree in T , and the loose consensus tree is the finest median tree containing only clusters from the sample trees.  Thus, the result follows for both dCM and dnav due their relation in Proposition 13. 8 AT is the transpose of matrix A. 21 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 22 5.2. Sample Distribution of Dissimilarities To compare their discriminative power, we use a standard statistical analysis of empirical distributions of different tree measures. The shape of the distribution of a tree measure tells how informative it is; for example, a highly concentrated distribution means that the associated tree measure behaves like the discrete metric9 as in the case of the Robinson-Foulds distance — see Figure 7. Finding a closed form expression for the distribution of a tree measure is a hard problem, and so extensive numerical simulations are generally applied to obtain its sample distribution. In particular, using the uniform and Yule model [31] for generating random trees, we compute the empirical distributions of dRF , d MS , dCC , dCM , and dnav as illustrated in Figure 7.10 Moreover, in Table 1 we present two commonly used statistical measures, skewness and kurtosis, for describing the shapes of the probability distributions of all these tree measures. Here, recall that the skewness of a probability distribution measures its tendency on one side of the mean, and the concept of kurtosis measures the peakedness of the distribution [32]. In addition to their computational advantage over d MS , as illustrated in both Figure 7 and Table 1, like d MS , our tree measures, dCC , dCM and dnav , are significantly more discriminative, with wider ranges of values and symmetry, than dRF . Table 1. Skewness and Kurtosis Values for the Distributions of Tree Measures in BT [25] dRF (14) d MS (Def. 7) dCC (18) dCM (Def. 10) dnav (Def. 19) Skewness Uniform Yule −2.6162 −2.0740 0.1293 −0.0117 −0.9294 −1.2507 0.1390 −0.0405 0.8809 −0.1195 Kurtosis Uniform Yule 9.8609 7.3998 3.0060 3.1136 3.8601 5.2724 3.1275 3.2103 4.8707 3.0746 Probability Distributions of Tree Dissimilarities Robinson−Foulds Distance Matching Split Distance 0.8 Cluster−Cardinality Distance 0.06 0.07 0.05 0.06 0.7 Crossing Dissimilarity NNI Navigation Dissimilarity 0.04 0.08 0.03 0.06 0.02 0.04 0.01 0.02 Probability 0.6 0.5 0.04 0.4 0.03 0.05 0.04 0.03 0.3 0.02 0.02 0.2 0.01 0.1 0 19 20 21 22 23 0 0.01 150 200 250 300 350 0 1500 2000 2500 Dissimilarity 0 150 200 250 300 350 400 0 60 80 100 120 140 (a) Probability Distributions of Tree Dissimilarities Robinson−Foulds Distance Matching Split Distance Cluster−Cardinality Distance Crossing Dissimilarity NNI Navigation Dissimilarity 0.07 0.1 0.7 0.06 0.08 Probability 0.6 0.5 0.08 0.05 0.1 0.06 0.04 0.08 0.03 0.06 0.02 0.04 0.01 0.02 0.06 0.4 0.04 0.3 0.2 0.04 0.02 0.02 0.1 0 19 20 21 22 23 0 0.12 150 200 250 0 1800 2000 2200 2400 2600 2800 Dissimilarity 0 150 200 250 300 0 40 50 60 70 80 90 (b) Figure 7. Empirical distribution of tree dissimilarities in BT [25] : (from left to right) the Robinson-Foulds distance dRF (14), the matching split distance dMS (Def. 7), the cluster-cardinality distance dCC (18), the crossing dissimilarity dCM (Def. 10), and the NNI navigation dissimilarity dnav (Def. 19). 100000 sample hierarchies are generated using (a) the uniform and (b)Yule model [31]. The resolutions of histograms of tree measures, from left to right, are 1, 4, 32, 4, 2 unit(s), respectively. 9 The discrete metric d : X × X → R≥0 on a set X is defined as for any x , y ∈ X d (x, x) = 0 and d (x, y) = 1. our numerical simulations for any chosen tree measure we observe the same pattern of sample distribution for different numbers of leaves, and so here we only include results for BT [25] . 10 In 22 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 23 6. Conclusion This paper presents three new tree measures for efficient discriminative comparison of trees. First, using the well known relation between trees and ultrametrics, the cluster-cardinality metric dCC is constructed as the pullback of matrix norms along an embedding of trees into the space of matrices. Second, we present the crossing dissimilarity dCM that counts the pairwise incompatibilities of trees. Third, the NNI navigation dissimilarity dnav while presented in closed form is constructed as the length of a navigation path in the space of trees. All of our dissimilarities can be computed in O(n2 ) with the number of leaves n, and they generalize to degenerate trees as well. Moreover, we provide a closed form expression for each proposed dissimilarity and present an ordering relation between these tree dissimilarities and related tree metrics in the literature (Theorem 3). Our numerical studies, summarized in Figure 7, suggest that the proposed tree measures are significantly more informative and discriminative than the Robinson-Foulds distance dRF , while maintaining a computational advantage over other distances such as the matching-split distance [3, 4]. Finally, the system of projector graphs (Theorem 1) and navigation graphs (Theorem 2) seems to play a fundamental role in the geometry of the NNI graph, realizing many of the intuitive desiderata of tree dissimilarity measures that have accumulated in the literature over the years. Consequently, NNI navigation paths are likely of some significance for consensus/average models or statistical analysis of trees. Acknowledgements This work was funded in part by the Air Force Office of Science Research under the MURI FA9550-10-1-0567. Appendix A. Proofs Appendix A.1. Proof of Lemma 1 Proof. Sufficiency is directly evident from Definition 4 because the cluster sets of a pair of nondegenerate hierarchies differ exactly by one cluster if and only if they are NNI-adjacent. To verify necessity, let the move (σ, P), P ∈ G (σ) 2 −σ join σ to τ, and o R = P and Q = Pr (P, σ) \ Pr (P, σ). By Definition 4, {Pr (P, σ)} = {P ∪ R} = C (σ) \ C (τ) and n 2 Pr (P, σ) \ P = {R ∪ Q} = C (τ) \ C (σ). Further, (P, R, Q) is the only ordered triple of common clusters of σ and τ with the property that {P ∪ R} = C (σ) \ C (τ) and {R ∪ Q} = C (τ) \ C (σ) since the cluster sets of any two NNI-adjacent hierarchies differ exactly by one element.  Appendix A.2. Proof of Lemma 2 Proof. To observe that resK (BT S ) ⊇ BT K , consider any two nondegenerate trees σ ∈ BT K and γ ∈ BT S \K , and let τ ∈ BT S be the nondegenerate tree with cluster set C (τ) = C (σ) ∪ {S } ∪ C (γ). Note that Ch (S , τ) = {K, S \ K}. Hence, we have from Remark 2 that σ = resK (τ). To prove that resK (BT S ) ⊆ BT K , let τ ∈ BT S and I ∈ C (τ) with the property that |I ∩ K| ≥ 2. Note that I ∩ K is an interior cluster of τ K . We shall show that the cluster I ∩ K ∈ C τ K always admits a bipartition in τ K . That is to say, there exist a cluster A ∈ C (τ) with children {AL , AR } = Ch (A, τ) such   that A ∩ K = I ∩ K and AL ∩ K , ∅ and AR ∩ K , ∅. Hence, Ch I ∩ K, τ K = {AL ∩ K, AR ∩ K}. Now observe that either IL ∩ K , ∅ and IR ∩ K , ∅ for {IL , IR } = Ch (I, τ), or there exists one and only one descendant D ∈ Des (I, τ) with {DL , DR } = Ch (D, τ) such that I ∩ K = D ∩ K and DL ∩ K , ∅ and DR ∩ K , ∅. Thus, all the interior clusters of τ K have exactly two children, which completes the proof.  Appendix A.3. Proof of Lemma 3 Proof. The proof of the sufficiency for being an ultrametric is as follows. Positive definiteness and symmetry of dτ are evident from (15) and Lemma 3.(a)-(b). To show the strong triangle inequality, let i , j , k ∈ S and I = (i∧ j)τ , and so dτ (i, j) = hτ (I). Accordingly, let {Ii , I j } ⊆ Ch (I, τ) with the property that i ∈ Ii and j ∈ I j . If k ∈ I, without loss of generality, let k ∈ Ii , and so k < I j . Then, using (15) and Lemma 3.(a), one can verify that dτ (i, k) ≤ hτ (Ii ) ≤ hτ (I) and dτ ( j, k) = hτ (I) because (i∧k)τ ⊆ Ii and ( j∧k)τ = I. Also note that if neither k ∈ Ii nor k ∈ I j (but still k ∈ I), then dτ (i, k) = dτ ( j, k) = hτ (I) since (i∧k)τ = ( j∧k)τ = I. Similarly, if k < I, then 23 Arslan, Guralnik, Koditschek / Preprint (2018) 1–24 24 dτ (i, k) ≥ hτ (I) and dτ ( j, k) ≥ hτ (I) because only some ancestors of I in τ might contain all i, j, k. Therefore, overall,  one always has dτ (i, j) ≤ max dτ (i, k) , dτ (k, j) , which completes the proof of the sufficiency. Let us continue with the necessity for being an ultrametric. Note that Lemma 3.(b) directly follows from positive definiteness of dτ . Let I ∈ C (τ) \ {S } be any non-singleton cluster of τ and i , j ∈ I with the property that (i∧ j)τ = I. For any k ∈ I −τ , we always have (i∧k)τ = ( j∧k)τ = Pr (I, τ). Now, using the ultrametric inequality of dτ , one deduces Lemma 3.(a) from   (A.1) hτ (I) = dτ (i, j) ≤ max dτ (i, k) , dτ ( j, k) = hτ Pr (I, τ) ,  which completes the proof. References [1] D. F. Robinson, L. R. Foulds, Comparison of phylogenetic trees, Mathematical Biosciences 53 (1-2) (1981) 131 – 147. [2] W. H. E. Day, Optimal algorithms for comparing trees with labeled leaves, Journal of Classification 2 (1985) 7–28. [3] D. Bogdanowicz, K. Giaro, Matching split distance for unrooted binary phylogenetic trees, Computational Biology and Bioinformatics, IEEE/ACM Transactions on 9 (1) (2012) 150–160. [4] Y. Lin, V. Rajan, B. Moret, A metric for phylogenetic trees based on matching, Computational Biology and Bioinformatics, IEEE/ACM Transactions on 9 (4) (2012) 1014–1022. [5] D. Robinson, Comparison of labeled trees with valency three, Journal of Combinatorial Theory, Series B 11 (2) (1971) 105 – 119. [6] G. Moore, M. Goodman, J. Barnabas, An iterative approach from the standpoint of the additive hypothesis to the dendrogram problem posed by molecular data sets, Journal of Theoretical Biology 38 (3) (1973) 423 – 457. [7] B. L. Allen, M. Steel, Subtree transfer operations and their induced metrics on evolutionary trees, Annals of Combinatorics 5 (2001) 1–15. [8] J. Felsenstein, Inferring Phylogenies, Sinauer Associates, Suderland, USA, 2004. [9] B. DasGupta, X. He, T. Jiang, M. Li, J. Tromp, L. Zhang, On distances between phylogenetic trees, in: Proceedings of the eighth annual ACM-SIAM symposium on Discrete algorithms, Society for Industrial and Applied Mathematics, 1997, pp. 427–436. [10] O. Arslan, D. P. Guralnik, D. E. Koditschek, Hierarchically clustered navigation of distinct euclidean particles, in: Communication, Control, and Computing (Allerton), 2012 50th Annual Allerton Conference on, 2012, pp. 946–953. [11] O. Arslan, D. Guralnik, D. E. Koditschek, Navigation of distinct euclidean particles via hierarchical clustering, in: Algorithmic Foundations of Robotics XI, Vol. 107 of Springer Tracts in Advanced Robotics, 2015, pp. 19–36. [12] N. Ayanian, V. Kumar, D. Koditschek, Synthesis of controllers to create, maintain, and reconfigure robot formations with communication constraints, in: Robotics Research, Vol. 70 of Springer Tracts in Advanced Robotics, Springer Berlin Heidelberg, 2011, pp. 625–642. [13] R. R. Burridge, A. A. Rizzi, D. E. Koditschek, Sequential composition of dynamically dexterous robot behaviors, The International Journal of Robotics Research 18 (6) (1999) 535–555. [14] G. Carlsson, F. Mémoli, Characterization, Stability and Convergence of Hierarchical Clustering methods, Journal of Machine Learning Research 11 (2010) 1425–1470. [15] M. Li, J. Tromp, L. Zhang, On the nearest neighbour interchange distance between evolutionary trees, Journal of Theoretical Biology (1996) 463–467. [16] K. CulikII, D. Wood, A note on some tree similarity measures, Information Processing Letters 15 (1) (1982) 39 – 42. [17] E. K. Brown, W. H. E. Day, A computationally efficient approximation to the nearest neighbor interchange metric, Journal of Classification 1 (1984) 93–124. [18] D. Bryant, A classification of consensus methods for phylogenetics, DIMACS series in Discrete Mathematics and Theoretical Computer Science 61 (2003) 163–184. [19] T. Margush, F. R. McMorris, Consensus n-trees, Bulletin of Mathematical Biology 43 (2) (1981) 239–244. [20] J.-P. Barthélemy, F. McMorris, The median procedure for n-trees, Journal of Classification 3 (2) (1986) 329–334. [21] F. James Rohlf, Consensus indices for comparing classifications, Mathematical Biosciences 59 (1) (1982) 131–144. [22] K. Bremer, Combinable component consensus, Cladistics 6 (4) (1990) 369–372. [23] L. J. Billera, S. P. Holmes, K. Vogtmann, Geometry of the space of phylogenetic trees, Advances in Applied Mathematics 27 (4) (2001) 733 – 767. [24] A. Schrijver, Combinatorial optimization: polyhedra and efficiency, Vol. 24, Springer, 2003. [25] K. Vogtmann, Geodesics in the space of trees., accessed May 22, 2015. (2007). URL www.math.cornell.edu/~ vogtmann/papers/TreeGeodesicss [26] A. K. Jain, R. C. Dubes, Algorithms for clustering data, Prentice-Hall, Inc., 1988. [27] R. Rammal, G. Toulouse, M. A. Virasoro, Ultrametricity for physicists, Reviews of Modern Physics 58 (3) (1986) 765. [28] D. D. Sleator, R. E. Tarjan, W. P. Thurston, Rotation distance, triangulations, and hyperbolic geometry, in: Proceedings of the eighteenth annual ACM symposium on Theory of computing, STOC ’86, 1986, pp. 122–135. [29] D. Epstein, M. Paterson, J. Cannon, D. Holt, S. Levy, W. P. Thurston, Word processing in groups, AK Peters, Ltd., 1992. [30] M. Waterman, T. Smith, On the similarity of dendrograms, Journal of Theoretical Biology 73 (4) (1978) 789 – 800. [31] C. Semple, M. Steel, Phylogenetics, Vol. 24, Oxford University Press, 2003. [32] J. A. Rice, Mathematical statistics and data analysis, Cengage Learning, 2007. 24
5cs.CE
1 Fundamental Limits of Caching: Improved Bounds with Coded Prefetching Jesús Gómez-Vilardebó arXiv:1612.09071v4 [cs.IT] 23 May 2017 Abstract We consider a cache network in which a single server is connected to multiple users via a shared error free link. The server has access to a database with N files of equal length F , and serves K users each with a cache memory of M F bits. A novel centralized coded caching scheme is proposed for scenarios with more users than files N ≤ K and cache capacities satisfying 2 1 ≤M ≤ N . The proposed scheme outperforms the best rate-memory region known in the literature if N ≤ K ≤ N 2+1 . K K I. I NTRODUCTION Content caching techniques are recently increasing attention to combat peak hour traffic in content delivery services. The basic idea is simple. If contents are made available at user terminals during low traffic periods, then the peak rate can be reduced. However, content requests are unknown to the server and thus content caching at user memories must be carefully chosen in order to be useful regardless of the contents requested during peak hours. The simplest caching scheme consists of storing each file partially at each user memory. Then, the server transmits the remaining requested data uncoded [1], [2]. For single user caching systems, this strategy is optimal. However, for multi-user systems, the seminal work in [3] by Maddah-Ali and Niesen shows that important gains can be obtained by a new coded caching strategy. Specifically, there authors show that, besides the local caching gain that is obtained by placing contents at user caches before they are requested, it is possible to obtain a global caching gain by creating broadcast opportunities. This is, by carefully choosing the content caches at different users, and using network coding techniques it is possible to transform the initial multi-cast network, where every user is requesting a different file, into a broadcast network, where every user requests exactly the same “coded” file, obtaining the new global caching gain. The fundamental caching scheme developed in [3] was latter extended to more realistic situations, including a decentralized scheme in [4], non-uniforms demands in [5], and online coded caching in [6]. In addition, new schemes pushing further the fundamental limits of caching systems have appeared in [7]–[13]. The work here proposed investigates the fundamental achievable rate for the particular situation where there are more users than files, and the caching memories at users are small compared to the number of files in the system. Besides its theoretical relevance, this situation can be readily found in the real world. For instance, global content delivery services such a Netflix serve a few multimedia contents to millions of users across the world. In addition, it was shown in [5] that a near optimal caching strategy consists in dividing the files into groups with similar popularity, and then applying the coded caching strategy to each group separately. Since the amount of users in each groups remains the same, when there are many groups, the cache size dedicated to each group is small as well as the number of files per user in each group. The rest of this paper is organized as follows. In Section II, we present the system model together with the more relevant previous results. In Section III, we summarize the main results of this paper. Section IV describes the caching scheme proposed, first, by providing a detailed example and, then extending it to the general case. Finally, conclusions are drawn in Section V. II. S YSTEM M ODEL AND P REVIOUS R ESULTS We consider a communication system with one server connected to K users, denoted as U1 , ..., UK , through a shared, error-free link. There is a database at the server with N files, each of length F bits, denoted as W1 , ...., WN . Each users is equipped with a local cache of capacity M F bits and is assumed to request only one full file. Here, we consider the special   N . and there are more users than files N ≤ K. For convenience, we define parameter g = MK case where M ∈ 0, N K We consider the communication model introduced in [3]. The caching system operates in two phases: the placement phase and the delivery phase. In the placement phase, users have access to the server database, and each user fills their cache. As in [11], we allow coding in the prefetching phase. Then, each user Uk requests a single full file Wd(k) where d = (d(1), ...., d(K)) denotes the demand vector. We denote the number of distinct request in d as Ne (d). In the delivery phase, only the server has access to the database. After being informed of the user demands, the server transmits a signal X of size RF bits over the shared link to satisfy all user requests simultaneously. The signal X is a function of the demand vector d, all the files in the data base, and the content in the user caches. The rate R is referred to as the rate of the shared link and is a function of the demand vector d. Using the local cache content and the received signal X, each user Uk reconstructs its requested file Wd(k) . For a caching system (M, N, K), given a particular demand d, we define a communication rate R is achievable if and only if there exists a message X of length RF bits such that every user Uk is able to reconstruct its desired file Wd(k) . 2 We denote as R(d) the achievable rate for a particular demand d. Then, the rate needed for the worst demand is given by R∗ = maxd∈D R(d). For the caching system described, there is a trade-off between the memory M at users, and the worst demand rate R∗ . Observe, that if users have no caching capacity M = 0, the server needs to send the full requested files and thus, the worst demand rate is R∗ = N . Instead, if users can have a complete copy of the server’s database M = N , then no information needs to be transmitted from the server R∗ = 0. We are interested in characterizing this rate memory trade-off. To that end, we define the rate-memory pair (R∗ , M ) and the rate-memory function R∗ (M ). A. Previous Results  N For the special case considered here M ∈ 0, K and N ≤ K, the best known rate-memory function in the literature can be obtained by memory sharing between four achievable rate-memory pairs: the trivial rate-memory pair (N, 0), the rate-memory 1 pairs obtained in [11] for M = K   N 1 ∗ (RCFL , MCFL ) = N − , , (1) K K N the rate-memory pair obtained by the schemes proposed in [7] and [12] for M = K   N (N + 1) N ∗ (RGBC , MGBC ) = N − , , 2K K (2) and the rate-memory pairs obtained in [13] ∗ (RMDS , MMDS ) =  N (K − t) t [(N − 1)t + K − N ] , K K (K − 1)  , t = 0, 1, ..., K. (3) The lower convex envelope of all these rate-memory pairs, provides the best rate-memory function in the literature. Our scheme is mainly motivated by the scheme described in [11], which makes use of coded prefetching at users’ cache. 1 As shown in [11], the scheme achieving (1) is optimal for M = K . The schemes proposed in [7] and [12] assume uncoded N prefetching. They are essentially the same at M = K . The scheme proposed in [12] was shown to be optimal among all the uncoded prefetching schemes. Finally, the scheme developed in [13] makes use of non binary codes, in particular distant separable (MDS) codes and rank metric codes to obtain the rate-memory pairs in (3), which are shown to be optimal at certain points. There have been other coded prefetching schemes proposed in the literature, see [10] and [8] but either they do not improve the current best known rate-memory trade-off or they apply to other situations. Despite all this efforts, the optimal rate-memory trade-off for a caching systems remains an open problem. There have been also efforts to obtain theoretical lower bounds on the delivery rate. The cut-set bound was studied in [3]. A tighter lower bound was obtained in [14]. Through a computational approach a lower-bound for the special case N = K = 3 is derived in [15]. Finally, in [9] yet another lower-bound is proposed. III. M AIN R ESULT The following theorem presents the delivery rate obtained by the proposed coded caching scheme for a particular demand d. Theorem 1. For a caching problem with K users and N files, K ≥ N , local cache size of M files at each user, and parameter N . Given a particular demand d, the delivery rate g = MK     N −1 Ne (d) + 1 KNe (d) −g g−1 g+1   (4) R= N −1 K g−1 is achievable for g ∈ {1, ..., N }. Furthermore, for g ∈ [1, N ] equals the lower convex envelope of its values at g ∈ {1, ..., N }. We prove this result and the next corollary in the following section by describing the new caching scheme. Corollary 1.1. For a caching problem with K users and N files, K ≥ N , local cache size of M files at each user, and N , the delivery rate-memory pairs parameter g = MK   N N +1 N ∗ (5) (R , M ) = N − , K g + 1 Kg are achievable for g ∈ {1, ..., N }. Furthermore, for g ∈ [1, N ] the rate-memory pairs in the the lower convex envelope of its values at g ∈ {1, ..., N } are achievable. 3 Prefetching User Uj Subfile assignment Coded cached subfiles {1,2} (j) Group {1,3} {2,3} (j) W1,{1,2} W1,{1,3} (j) W2,{1,2} (j) (j) W1,{1,2} ⊕ W2,{1,2} (j) W3,{1,3} (j) (j) W1,{1,3} ⊕ W3,{1,3} (j) W2,{2,3} (j) W3,{2,3} (j) (j) W2,{2,3} ⊕ W3,{2,3} TABLE I: Subfile assignement and prefetching at user Uj , for the proposed coded caching scheme when K = 6, N = 3 and M = 41 , i.e. g = 2. N Remark 1. The rate-memory function in (5) coincides with (1) for g = N , and with (2) for g = 1. For g = 1, M = K our scheme is essentially the same as the one described in [12] and [7]. However, the scheme proposed in [11] to achieve (1) differs slightly from the one considered here for K > N . Indeed, while [11] divides each file into N K subfiles, our scheme requires only K subfiles per file. The next three corollaries compare the proposed scheme with the scheme presented in [13], the cut set lower bound derived in [3], and the lower bound obtained in [14]. These results are proved in the Appendices. 1 N Corollary 1.2. For a caching problem with K users and N files, K ≥ N , and local cache size of K ≤M ≤ K , a sufficient condition for the proposed scheme to outperform the rate-memory region obtained by the lower convex envelope of the rate-memory pairs in (3), is N2 + 1 . K≤ 2 Corollary 1.3. Let RCB (M ) denote the rate-memory function obtained for the cut set lower bound. The rate difference between the cut set rate and the rate-memory pairs in Corollary 1.1 is   N +1 N N RCB (M ) − R⋆ (M ) = − K g g+1   N g+1  . (6) = N −1 K g−1 1 the cut set lower bound is achieved by the Observe that, as first reported in [11, Theorems 3 and 4], for M = K  g = N,  N −1 proposed strategy. From the second equality (6), given that K is the number of subfile partitions in our scheme, g−1   N we can see that is the distance in number of subfile transmissions to the cut set bound. g+1 Corollary 1.4. Let RSTC (M ) denote the lower bound on the rate-memory function presented in [14]. For K = N and N = N1−1 , this lower bound is achievable by the rate-memory function in Corollary 1.1. This is R⋆ N1−1 = M = (N −1)K   RSTC N 1−1 . We conclude this section by illustrating in Fig. 1 the rate-memory function for the proposed scheme and for the state of the art (SOTA). We consider the case N = 10 files and K = 15 users. In addition to the best state of the art rate-memory function, ∗ we provide the rate-memory function recently discovered in [12], the previously introduced rate-memory pairs (RMDS , MMDS ), ∗ ∗ ∗ N −1 found in [10] by using a coded prefetching (RCFL , MCFL ), and (RGBC , MGBC ) as well as the rate-memory pair Rc , K scheme. We also include in this figure for comparison, the cut set lower bound and the information-theoretical lower bound obtained in [14]. We observe that, for the special situation considered here, the new proposed scheme obtains a significant improvement with respect to the previous best SOTA. IV. P ROPOSED C ACHING S CHEME We describe the proposed scheme, first with a particular example. Then, we provide a detailed description of the general case. A. Example Consider a caching system with N = 3 files, K = 6 users and a caching capacity of M F bits with M = 41 , which correspondsto choosing g = 2. For this particular case, the best known coded caching scheme obtains the rate-memory pair 1 1 28 5 1 ∗ ∗ 12 + 36 , 4 by memory sharing between the rate-memory pair (RMDS , MMDS ) = (RCFL , MCFL ) = 2 , 6 from (3) with t = 1, 4 10 [12, Corollary 1] R∗MDS 9.5 Best SOTA New Strategy RCB Lower-bound Delivery rate, R ∗ 9 RSTC Lower-bound R∗CFL (M=1/K) 8.5 R∗c (M=(N-1)/K) R∗GBC (M=N/K) 8 7.5 7 6.5 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 Cache capacity, M Fig. 1: Rate-memory functions of the proposed scheme (New Strategy) compared with existing schemes and lower bounds in the literature for N = 10 and K = 15.   28 1 7 ∗ , 4 is from (3) with t = 2. Here, weshow that the rate-memory pair 12 and the rate-memory pair (RMDS , MMDS ) = 2, 15 1 achievable. The best known outer bound [14] obtains the rate-memory pair 27 12 , 4 .   N −1 The prefetching strategy is illustrated in Table I. We break each file Wf , f = {1, 2, 3} into K = 6 × 2 = 12 g−1 subfiles of equal size. Next, two different subfiles for each file are assigned to every user. Each subfile of file Wf assigned to user Ui is further associated to one of the two sets of g = 2 subfiles A ∈ {{1, 2} , {1, 3} , {2, 3}} which contain file index f , (i) this is f ∈ A, and denoted as Wf,A . Finally, each user Ui , i = {1, ..., 6} computes the binary sum of the g subfiles assigned to each of the 3 possible sets A, and stores the resultant coded subfile. In the following, these stored coded subfiles are referred to as coded cached subfiles. Given the above prefetching scheme, we illustrate our proposed delivery strategy for a representative demand scenario, where users U1 and U2 request file W1 , users U3 and U4 request file W2 , and users U5 and U6 request file W3 . We show later in this section, by addressing the general case, that this indeed corresponds to the worst possible demand. We represent this demand by the demand vector d = [1, 1, 2, 2, 3, 3]. Then Wd(i) returns the file requested by user Ui . First, observe that, users all together, store all subfiles XORed at some coded cached subfile, and that every subfile is only XORed at one of the coded cached subfiles. Having this in mind, the delivery scheme proposed divides the coded cached subfiles into three types and obtains the subfiles XORed at each of the coded cached subfiles types separately. Coded cached subfiles Type I: First, consider those coded cached subfiles XORing a subfile requested by some user together with subfiles that are not requested by any user. For the specific demand considered in this example, there are non of these coded cached subfiles, as every file is requested by some user. If there would be some, the server would simply broadcast, one by one, the subfiles requested by users XORed in every coded cached subfile Type I. Coded cached subfiles Type II: Second, consider those coded cached subfiles XORing a subfile requested by the user which stores them. For our specific example, there are two of such coded cached subfiles at each user. The delivery strategy for all the subfiles XORed at these coded cached subfiles is represented in Table II. The delivery scheme is divided into two consecutive phases, and each phase is further divided into a broadcast and computation task: Phase 1: For each of the coded cached subfiles Type II, the server first broadcasts (forth column), one by one, all the subfiles XORed at each coded cached subfile except for the one requested by the user in which the coded cached subfile is stored. Users obtain directly from this broadcasted transmission, all their requested subfiles which are XORed at the coded 5 User Coded cached subfiles Request Phase 1 Broadcast W1,{1,2} ⊕ W2,{1,2} W2,{1,2} Compute (1) W1,{1,2} W1,{1,3} ⊕ W3,{1,3} W3,{1,3} W1,{1,3} (1) U1∗ W1 U2 W1 U3∗ W2 (1) (1) W2 U5∗ W3 U6 (1) (1) (2) (2) (2) W1,{1,3} (2) W3,{1,3} (1) ⊕ W1,{1,2} (2) W3,{1,3} (3) (2) W1,{1,3} (3) (3) W1,{1,2} (3) (3) W2,{2,3} ⊕ W3,{2,3} W3,{2,3} (4) W1,{1,2} W2,{1,2} (4) W3,{2,3} (4) W3,{2,3} (4) W2,{2,3} (5) W3,{1,3} (5) W3,{2,3} ⊕ W1,{1,3} ⊕ W3,{1,3} (5) (5) W1,{1,3} (5) W2,{2,3} (5) W3,{2,3} (5) W2,{2,3} ⊕ (6) (6) (6) (6) (4) (5) (6) (6) W1,{1,3} W3,{1,3} (6) W2,{2,3} ⊕ W3,{2,3} (6) W2,{2,3} W3,{2,3} ⊕ ⊕ (2) W1,{1,2} (3) W1,{1,3} (1) W1,{1,2} (4) W2,{2,3} Compute (2) (1) W1,{1,2} (1) W1,{1,3} (4) W1,{1,2} (5) W1,{1,3} (6) W1,{1,3} (3) (4) Broadcast (3) W1,{1,2} W2,{1,2} W2,{2,3} (4) Broadcasted W2,{1,2} W1,{1,2} ⊕ W2,{1,2} W1,{1,3} ⊕ W3,{1,3} W3 (2) W2,{1,2} W1,{1,2} ⊕ W2,{1,2} (3) (1) (2) W1,{1,2} ⊕ W2,{1,2} (3) U4 Phase 2 W1,{1,2} (2) W1,{1,3} (1) W1,{1,2} (1) W1,{1,3} (4) (3) W2,{1,2} (3) W2,{2,3} (2) (5) W2,{2,3} (6) W2,{2,3} ⊕ ⊕ (4) W2,{1,2} (4) W2,{2,3} W2,{1,2} (4) W2,{2,3} (3) W2,{1,2} (3) W2,{2,3} (1) (6) W3,{1,3} (5) (6) (5) W3,{2,3} (6) W3,{2,3} W3,{1,3} ⊕ W3,{1,3} (2) W3,{1,3} (3) W3,{2,3} (4) W3,{2,3} ⊕ W3,{1,3} (6) W3,{2,3} (5) W3,{1,3} (5) W3,{2,3} TABLE II: Delivery scheme of requested subfiles XORed at coded cached subfiles Type II. User Coded cached subfiles U1∗ (1) W2,{2,3} U2 W2,{2,3} ⊕ W3,{2,3} U3∗ W1,{1,3} ⊕ W3,{1,3} U4 W1,{1,3} ⊕ W3,{1,3} U5∗ W1,{1,2} ⊕ W2,{1,2} U6 W1,{1,2} ⊕ W2,{1,2} (2) (3) (4) (5) (6) ⊕ (1) W3,{2,3} (2) (3) (4) (5) (6) Phase 1 Phase 2 Broadcast Compute Broadcast (1) (3) W3,{2,3} ⊕ W3,{1,3} (2) (1) W2,{2,3} ⊕ W2,{2,3} (2) (3) W3,{2,3} ⊕W3,{1,3} (1) (5) W1,{1,3} ⊕ W1,{1,2} (4) (5) W1,{1,3} ⊕ W1,{1,2} (4) (3) W3,{1,3} ⊕W3,{1,3} (1) (5) W2,{2,3} ⊕ W2,{1,2} (6) (1) W2,{1,2} ⊕ W2,{2,3} (6) (5) W1,{1,2} ⊕ W1,{1,2} (1) W2,{2,3} (5) W1,{1,2} ⊕ (3) W3,{1,3} ⊕ (1) W2,{2,3} (5) ⊕ (3) W3,{1,3} W1,{1,2} ⊕ (5) W1,{1,2} (1) W2,{2,3} (3) W3,{1,3} (5) W1,{1,2} ⊕ (1) W2,{1,2} Reordering Phase 1\Broadcast Compute (3) W3,{1,3} (1) W1,{1,3} (4) W1,{1,3} (6) W1,{1,2} (5) W2,{1,2} (2) W2,{2,3} (5) W2,{1,2} (1) ⊕ ⊕ ⊕ ⊕ ⊕ ⊕ (5) W1,{1,2} (5) W1,{1,2} (5) W1,{1,2} (1) W2,{2,3} (1) W2,{2,3} (1) W2,{2,3} (3) W3,{2,3} ⊕ W3,{1,3} Compute (1) W1,{1,3} (4) W1,{1,3} (6) W1,{1,2} (5) W2,{1,2} (2) W2,{2,3} (5) W2,{1,2} (1) W3,{2,3} (2) (2) (3) W3,{2,3} (4) (3) W3,{1,3} W3,{2,3} ⊕W3,{1,3} W3,{1,3} ⊕W3,{1,3} (4) TABLE III: Delivery scheme of requested subfiles XORed at coded cached subfiles Type III. cached subfiles stored at other users with a different demand (sixth column). Using these broadcasted subfiles (forth column) and their coded cached subfiles (third column), each user computes the requested subfiles (fifth column) which are XORed at each of the coded cached subfiles. Phase 2: Observe that, after Phase 1, every set of users with the same demand has computed a different and not overlapping subset of requested subfiles. In order to all the users with a common demand share their computed subfiles in Phase 1, the server arbitrarily selects one user leader for each subset of users with the same requested file. Let U = {1, 3, 5} denote the set of user leaders, then for every user i ∈ / U and every subset A of g files including Wd(i) , the server transmits (seventh column) the binary sum (i) (u) Wd(u),A ⊕ Wd(i),A where u ∈ U is the user leader with the same request d(u) = d(i). For clarity, we underline the subfiles obtained in Phase 1 at user leaders. Finally (eight column), given that each of the broadcasted coded subfiles XOR a subfile already available at the user leader together with a subfile already available at a non-user leader in the same demand group, user leaders can compute the remaining requested subfiles. Every other user, would first compute the subfile belonging to the user leader and then use it to obtain the rest of the requested subfiles in their demand group. Coded cached subfiles Type III: Finally, consider those coded cached subfiles which XOR together subfiles not requested by the user storing them. The delivery of the subfiles in coded cached subfiles Type III is illustrated in Table III. In our specific example, there is only one of such coded cached subfiles at each user cache (third column). Again, the delivery scheme is partitioned into two consecutive phases: 6 Phase 1: Select a set of user leaders U = {1, 3, 5}, for simplicity we consider the one used for coded cached subfiles Type II. Next, for every subset V ⊆ U of g + 1 = 3 user leaders (in our particular example there is only one of such subsets V = {1, 2, 3}), there is an associated set of file requests B(V) = {W1 , W2 , W3 }. The servers arbitrarily selects one subfile, (the underlined subfiles in the second column), each from a different file in B(V), from the subfiles XORed at each of the coded cached subfiles Type III of the user leaders in V. Next, for every other subfile XORed at coded cached subfiles Type III of all users (leaders or not), the server broadcasts the binary sum of such subfile and the one selected (underlined) that belongs to the same file (see third column). Finally, using these coded broadcasted subfiles, together with their own coded cached subfiles Type III, each user computes the binary sum of all the selected (underlined) subfiles belonging to files distinct from their requested file (forth column). Phase 2: Next, the server broadcasts the binary sum of all the selected/underlined subfiles (fifth column). Using this coded broadcasted subfile together with the coded subfile computed in Phase 1 (third column) each user computes the selected/underlined subfile belonging to its requested file (sixth column). Finally, each user obtains their remaining requested subfiles (eight column) by computing the binary sum of the recently computed subfile (sixth column) and each of the coded broadcasted subfiles in Phase 1 that XOR two subfiles belonging to its requested file (seventh column). B. General Scheme Next, we generalize the proposed centralized coded caching scheme. Consider a scenario with K users, N files of size F N . To achieve the rate R stated in Theorem 1, we present a prefetching and bits and a cache capacity at users of M = gK N 1 ≤M ≤ K , the minimum rate can be achieved by memory sharing. delivery scheme for g ∈ {0, 1, ..., N }, since for general K Prefetching scheme: In [11], the prefetching scheme stores at each user a different coded subfile XORing together N subfiles, one from each of the N files available in the system. The prefetching scheme proposed here extends this idea by storing at each user a different  coded subfile XORing together g ∈ {0, 1, ..., N } subfiles each from a different file. Given that there is not just N one, but different combinations of g different files, and no particular combination shall be preferred, we store one coded g   N −1 subfile for each possible combinations of g files. Specifically, we partition each file Wf , f ∈ {1, ..., N } into K g−1   N −1 non-overlapping subfiles of equal size and assign subfiles of each file to each user Ui , i ∈ {1, ..., K}. Next, g−1   N −1 consider each possible subset A ⊆ {1, ..., N } of g different files, i.e. |A| = g. Each of the subfiles of file Wf g−1 (i) assigned to userUi is also assigned to a different subset A satisfying f ∈ A. We identify this subfile as Wf,A . This is possible, N −1 since there are subsets A which include a particular file Wf , i.e. satisfying f ∈ A. Finally, at user Ui , for every g−1 subset of files A, we compute the binary sum of the g subfiles assigned to subset A, and store the coded cached subfile M (i) (i) ZA = Wf,A . f ∈A Finally, because each user stores  N g  coded cached subfiles, one for each subset A, and each subfile has  bits, the required cache load at each user equals M F =  K K  N  g N −1 g−1  F  F  = N gK F N −1 g−1   bits, which satisfies the memory constraint imposed. Delivery scheme: As pointed out in the example, all subfiles can be found only once at some code cached subfile. The delivery scheme proposed divides the coded cached subfiles into three types and obtains the requested subfiles XORed at each of the coded cached subfile types separately. Coded cached subfiles Type I: First, consider those requested subfiles which are XORed at coded cached subfiles that also XOR subfiles not requested by any user. The server simply broadcast, one by one, all the requested subfiles in every coded cached subfile Type I. Suppose only Ne (d) distinct files out of the total N files  are requested  by all users. From N −1 the placement phase, we know that XORed at all the coded cached subfiles, there are subfiles of each file g−1   Ne (d) − 1 at every user, from which there are requested subfiles XORed to other requested subfiles. Thus, there are g−1 7     N −1 Ne (d) − 1 − distinct subfiles of every file at every user which are encoded together with some not requested g−1 g−1 subfile. Finally, since there are Ne (d) different requests and K users, the total number of subfile transmissions needed is     N −1 Ne (d) − 1 TI = KNe (d) − . g−1 g−1 Coded cached subfiles Type II: Second, consider those coded cached subfiles which XOR a subfile requested by the user which stores them. Notice that, all requested subfiles still missing are encoded at some coded cache subfile together with g − 1 other also requested subfiles.The delivery strategy for all the subfiles XORed at the coded cached subfiles Type II is divided (i) into two consecutive phases. In the first phase, each user Ui obtains the subfiles Wd(i),A of their own demand d(i) encoded (i) at coded cached subfiles ZA in their own cache. In the second phase, every two distinct users Ui , Uj requesting the same file d(i) = d(j) share the subfiles obtained in Phase 1. Phase 1: For each of the coded cached subfiles Type II, the server first broadcasts, one by one, all the subfiles XORed at each coded cached subfile except the one requested by the user in which the coded cached subfile isstored. This is, the server  Ne (d) − 1 (i) (i) broadcast each of the g − 1 subfiles XORed to Wd(i),A in ZA . Given that there are of such subfiles at each g−1 user, we require   Ne (d) − 1 K(g − 1) (7) g−1 (i) subfile transmissions. Next, by computing the binary sum of ZA and the broadcasted subfiles XORed in the  coded cached  Ne (d) − 1 (i) (i) subfile ZA , each user obtains the requested subfile Wd(i),A . At the end of this phase, user Ui has obtained the g−1 requested subfiles which where cached at some coded cached subfile in its own cache. In addition, users obtain, directly, from the broadcasted subfiles, all their requested subfiles which are XORed at the coded cached subfiles  stored at users with a different Ne (d) − 2 demand. Specifically, let K(f ) denote the set of users requesting file Wf , user Ui obtains (K − |K(f )|) g−2 subfiles of his own requested file Wd(i) directly from the broadcast transmission. For consistency check, observe that the total number of subfiles obtained directly from the broadcast transmissions by all users coincides with the total number of subfiles transmitted in Phase 1.   X   Ne (d) − 2 Ne (d) − 2 (K − |K(f )|) = (Ne (d)K − K) g−2 g−2 ∀f ∈d =    (7) (8)  n n−1 n = m. m m−1 Phase 2: After Phase 1, because all subfiles XORed at codedcached subfiles of different users are distinct, users with the  Ne (d) − 1 same request have obtained a different subset of subfiles of their common requested file. Consider the set of g−1 users K(f ) requesting file Wf . In order to all users Ui , requesting file Wf , i ∈ K(f ) share the subfiles obtained Phase 1, the server arbitrarily selects one user leader u ∈ K(f ) per file Wf . For every other user Ui , i ∈ K(f )/u and every subset A of g requested files including Wd(i) , the server transmits the binary sum where (8) follows from (i,u) (i) (u) Yf,A = Wf,A ⊕ Wf,A . Given that there are  Ne (d) − 1 g−1  (9) subsets A of g requested files, we require a total of (|K(f )| − 1)  Ne (d) − 1 g−1  (10) coded subfile transmissions per file. Next, for every requested file Wf , the user leader u ∈ K(f ) computes the remaining requested subfiles by computing the (u) binary sum of the subfile Wf,A obtained in Phase 1 with each of the broadcasted coded subfiles (i) (i,u) (u) Wf,A = Yf,A ⊕ Wf,A (11) for all i ∈ K(f )/u and all sets of g requested files A, such that d(u) ∈ A. Every other user Uj , j 6= u, requesting file Wf , (u) j ∈ K(f ) first obtains the subfile of the user leader Wf,A by computing (u) (j,u) (j) Wf,A = Yf,A ⊕ Wf,A , 8 (u) and then uses Wf,A to obtain the rest of the subfiles by computing (11) for all i ∈ K(f )/u/j and all sets of g requested files A, such that f ∈ A. Because there are Ne (d) distinct requested files, the total number of coded subfile transmissions (9) is     X Ne (d) − 1 Ne (d) − 1 (|K(f )| − 1) = (K − Ne (d)) . (12) g−1 g−1 ∀f ∈d Finally, adding together (7) and (12), the total number of subfile length transmissions needed to obtain the requested subfiles XORed in the coded cached subfiles Type II is   Ne (d) − 1 TII = (Kg − Ne (d)) . g−1 Coded cached subfiles Type III: Finally, consider those coded cached subfiles which XOR together subfiles not requested by the user storing them. Specifically, consider any subset V of g + 1 users with different demands. Let B(V) denote the set of g + 1 demands of the users in V. For any user, Ui , i ∈ V there is exactly one coded cached subfile M (i) (i) Wf,B(V)\d(i) ZB(V)\d(i) = f ∈B(V)\d(i) which does not XOR a subfile of d(i), but XORs together one subfile requested by each of the other g − 1 users in V. In this phase, all user obtain such subfiles. Observe that for coded cached subfiles Type III to exist, there might be at least g + 1 users with different demands, this is Ne (d) ≥ g + 1. Again, the delivery scheme is partitioned into two consecutive phases: Phase 1: First, the server selects a set of Ne (d) user leaders U each with a different demand. Next, for every subset V ⊆ U of g + 1 user leaders, the server arbitrarily associates to each user, Uj , j ∈ V a different file rV (j) ∈ B(V), such that rV (j) 6= d(j) and rV (i) 6= rV (j) for all i 6= j, i ∈ V. Since |B(V)| = g + 1, this is always possible. The server then broadcasts the coded subfiles (i,j) YV (j) (i) = WrV (j),B(V)\d(i) ⊕ WrV (j),B(V)\d(j)   Ne (d) for all j ∈ V\i with rV (j) 6= d(i), rV (j) 6= rV (i) and all i ∈ V. Because there are subsets V ⊆ U of g + 1 g+1   Ne (d) users, this results in a total of (g − 1)(g + 1) subfile length transmissions. Next, for every other user, Ui , i ∈ /U g+1 satisfying d(i) ∈ B (V), the server broadcasts (i,j) YV (j) (i) = WrV (j),B(V)\d(i) ⊕ WrV (j),B(V)\d(j)   Ne (d) − 1 for all j ∈ V with rV (j) 6= d(i). Because there are K − Ne (d) not users leaders i ∈ / U, and there are g   Ne (d) − 1 subsets V ⊆ U of g + 1 users satisfying d(j) ∈ V, this results in a total of g (K − Ne (d)) coded subfile g transmissions. Next, for all subsets of g + 1 users V ⊆ U, every user Ui , satisfying d(i) ∈ B(V) computes M M M (i,j) (i) (i,j) (i) YV Wf,B(V )\d(i) = YV ZB(V)\d(i) j∈V\i,rV (j)6=d(i) f ∈B(V)\d(i) j∈V\i,rV (j)6=d(i) = M (i) WrV (j),B(V )\d(i) M (i,j) YV j∈V\i,rV (j)6=d(i) j∈V,rV (j)6=d(i) = (i) WrV (i),B(V )\d(i) = (i) WrV (i),B(V )\d(i) M j∈V\i,rV (j)6=d(i) M  (i) (j) WrV (j),B(V)\d(j) j∈V\i,rV (j)6=d(i) = M (j) WrV (j),B(V)\d(j) j∈V,rV (j)6=d(i) where for every i ∈ / V, we defined rV (i) = rV (j) where j ∈ V and d(i) = d(j). Phase 2: Finally, for each subset of g + 1 users leaders V ⊆ U, the server broadcasts the coded subfile M (j) YV = WrV (j),B(V)\d(j) . j∈V (i,j) WrV (j),B(V )\d(i) ⊕ YV  9   Ne (d) additional coded subfiles transmissions. Now, for all subsets of g + 1 users V ⊆ U, every g+1 (j) user Ui , satisfying d(i) ∈ B(V) obtains the subfile WrV (j)=d(i),B(V)\d(j) which is cached at user leader, Uj j ∈ V satisfying rV (j) = d(i), by computing M (j) (j) WrV (j),B(V)\d(j) ⊕ YV = WrV (j)=d(i),B(V)\d(j) This results in a total of j∈V,rV (j)6=d(i) (j) Wd(i),B(V)\d(j) . = (l) User Ui obtains the rest of his requested subfiles Wd(i),B(V)\d(l) XORed at the coded cached subfile Type III of user Ul , (l) ZB(V)\d(l) by choosing j ∈ V satisfying rV (j) = d(i) and computing (j) (l) (j) (l,j) (j) = Wd(i),B(V)\d(j) ⊕ WrV (j),B(V)\d(l) ⊕ WrV (j),B(V)\d(j) Wd(i),B(V)\d(j) ⊕ YV (l) = Wd(i),B(V)\d(l) for all subsets of g + 1 users V ⊆ U and all users l 6= i satisfying d(i) = d(l). The total number of transmissions in both phases is     Ne (d) Ne (d) − 1 TIII = ((g − 1)(g + 1) + 1) + (K − N0 ) g g+1 g     N (d) Ne (d) − 1 e (13) = g K− g g+1     Ne (d) Ne (d) − 1 (14) = (Ne (d) − g) K − g−1 g+1         n n−1 n n n n+1−k where (13) follows from = and (14) follows from . = k k k k−1 k k−1 Finally, adding together all the subfile length transmissions required for the three coded cached subfile types, we obtain      Ne (d) + 1 Ne (d) − 1 N −1 T = KNe (d) − Ne (d) g−1 g−1 g+1     N −1 Ne (d) + 1 = KNe (d) −g (15) g−1 g+1 which leads to the rate (4) stated in Theorem 1. we obtain the rate-memory function stated in Corollary 1.1. Finally, to prove Corollary 1.1, we need to show that (15) increases monotonically as a function of Ne (d). For the easy of notation, let us substitute Ne (d) by x, and denote (15) as a function of Ne (d) as T (x). Then, observe that T (x) = = = = =    n = k Thus, for x = 1 to x = N − 1, we have where (16) follows from Kx   N −1 g−1  −g   x+1 g+1     g+1 N −1 x+2 Kx −g 1− (16) g−1 g+1 x+2       g+1 x+2 N −1 x+2 Kx −g +g g+1 g−1 g+1 x+2       N −1 x+2 x+1 Kx −g +g (17) g−1 g+1 g     x N −1 T (x + 1) + (x + 1) −K g−1 g−1       n n−1 n+1 n k and (17) follows by applying = 1 − n+1 k twice. k k−1 k T (x + 1) = T (x) + K  N −1 g−1  − (x + 1)  x g−1  ≥ T (x)  x where the last inequality follows since increases monotonically with x, and x ≤ N − 1 ≤ K − 1. Finally, g−1 particularizing (15) to Ne (d) = N , we obtain the rate-memory function in 5.  10 V. C ONCLUSIONS In this work, we proposed a novel centralized coded caching scheme for the case where there are more users than files and users are equipped with small memories. The scheme uses coded prefetching and outperforms previously proposed schemes 2 for moderate-high number of users, N ≤ K ≤ N 2+1 . Our current future work includes the extension of the proposed coded prefetching technique to larger memories and scenarios with more users than files, as well as, the extension of the proposed centralized technique to the decentralized setting. P ROOF A PPENDIX A OF C OROLLARY 1.2 To prove this results, we first observe that by isolating parameter t in the MDS rate points, t = substituting it into the MMDS memory points, we can obtain the following memory-rate function (lb) MMDS (R) = (N − R) ((N − R) (N K − K) + N (K − N )) . N 2 (K − 1) K N ∗ (N − RMDS ) and (18) (lb) (lb) Due to the convexity of MMDS (R) function with respect to R, we have that MMDS (R) represents a lower-bound on the MDS memory-rate region that can be obtained by the lower convex envelope of the memory-rate pairs (3). (lb) Particularizing (18) to the rate points in (5), we can write MMDS as a function of g as  2  N +1 1 N −1 (lb) MMDS (g) = +K−N g + 1 K(K − 1) g+1 for g = 1, ..., N . Thus, a sufficient conditions for the new rate-memory pairs in (5) to improve the MDS rate-memory region is N (lb) ≤ MMDS (g) Mg which leads us to K≤ N 2g + 1 . g+1 2 g+1 increases monotonically with g, we have that a sufficient condition for our strategy to improve the MDS Finally, since Ng+1   strategy in the complete region considered M ∈ 0, N K and N ≤ K, is K≤ P ROOF N2 + 1 . 2 A PPENDIX B OF C OROLLARY 1.3 The proof of Corollary 1.3 follows the lines of [11]. From [3], the cut set lower bound is given by s RCB (M ) = max s −  N  M. s∈{1,...,min(N,K)} s Particularized to the case N ≤ K, we have RCB (M ) 1 ≥ max 1 −  N  M, ...., N − N M s ! ≥ N − NM   N +1 N N − = R (M ) − K g g+1   N g +1  = R∗ (M ) −  N −1 K g−1 ∗ where R∗ (M ) is the rate-memory tradeoff function presented in Corollary 1.1 for g ∈ {1, ..., N }. 11 P ROOF A PPENDIX C OF C OROLLARY 1.4 The lower bound obtained in [14, Theorem 1] is given by RSTC (M ) = max s ∈{1, ...,K)}  l ∈ 1, ..., Ns 1 l + µ (N − ls) + N − sM − − (N − Kl) s+µ ! (19)  where µ = min N −ls l , K − s ∀s, l. Observe that for l = 1 and s = N − 1, K ≥ N , we have µ = min(N − s, K − s) = N − s = 1, and the objective in (19) reads N − (N − 1) M − N1 . Thus, RSTC (M ) ≥ which particularized to K = N , M = N − (N − 1) M − 1 N N (N −1)K , g = N − 1 leads us to   1 N ≥ N −1− RSTC (N − 1)K N   1 . = R∗ N −1 R EFERENCES [1] M. R. Korupolu, C. Plaxton, and R. Rajaraman, “Placement algorithms for hierarchical cooperative caching,” Journal of Algorithms, vol. 38, no. 1, pp. 260 – 302, 2001. [Online]. Available: http://www.sciencedirect.com/science/article/pii/S0196677400911295 [2] A. Dan, D. Sitaram, and P. Shahabuddin, “Dynamic batching policies for an on-demand video server,” Multimedia Systems, vol. 4, no. 3, pp. 112–121, 1996. [Online]. Available: http://dx.doi.org/10.1007/s005300050016 [3] M. A. Maddah-Ali and U. Niesen, “Fundamental limits of caching,” IEEE Transactions on Information Theory, vol. 60, no. 5, pp. 2856–2867, May 2014. [4] ——, “Decentralized coded caching attains order-optimal memory-rate tradeoff,” IEEE/ACM Transactions on Networking, vol. 23, no. 4, pp. 1029–1040, Aug 2015. [5] U. Niesen and M. A. Maddah-Ali, “Coded caching with nonuniform demands,” IEEE Transactions on Information Theory, vol. PP, no. 99, pp. 1–1, 2016. [6] R. Pedarsani, M. A. Maddah-Ali, and U. Niesen, “Online coded caching,” IEEE/ACM Transactions on Networking, vol. 24, no. 2, pp. 836–845, April 2016. [7] M. M. Amiri, Q. Yang, and D. Gündüz, “Coded caching for a large number of users,” CoRR, vol. abs/1605.01993, 2016. [Online]. Available: http://arxiv.org/abs/1605.01993 [8] S. Sahraei and M. Gastpar, “K users caching two files: An improved achievable rate,” in 2016 Annual Conference on Information Science and Systems (CISS), March 2016, pp. 620–624. [9] H. Ghasemi and A. Ramamoorthy, “Improved lower bounds for coded caching,” in 2015 IEEE International Symposium on Information Theory (ISIT), June 2015, pp. 1696–1700. [10] M. M. Amiri and D. Gunduz, “Fundamental limits of coded caching: Improved delivery rate-cache capacity trade-off,” IEEE Transactions on Communications, vol. PP, no. 99, pp. 1–1, 2016. [11] Z. Chen, P. Fan, and K. B. Letaief, “Fundamental limits of caching: improved bounds for users with small buffers,” IET Communications, vol. 10, no. 17, pp. 2315–2318, 2016. [12] Q. Yu, M. A. Maddah-Ali, and A. S. Avestimehr, “The exact rate-memory tradeoff for caching with uncoded prefetching,” CoRR, vol. abs/1609.07817, 2016. [Online]. Available: http://arxiv.org/abs/1609.07817 [13] C. Tian and J. Chen, “Caching and Delivery via Interference Elimination,” ArXiv e-prints, Apr. 2016. [14] A. Sengupta, R. Tandon, and T. C. Clancy, “Improved approximation of storage-rate tradeoff for caching via new outer bounds,” in 2015 IEEE International Symposium on Information Theory (ISIT), June 2015, pp. 1691–1695. [15] C. Tian, “A note on the fundamental limits of coded caching,” CoRR, vol. abs/1503.00010, 2015. [Online]. Available: http://arxiv.org/abs/1503.00010
7cs.IT
Optimizing scoring function of dynamic programming of pairwise profile alignment using derivative free neural network Kazunori D Yamada1,2∗ Graduate School of Information Sciences, Tohoku University, Sendai, Japan, 2 Artificial Intelligence Research Center, National Institute of Advanced Industrial Science and Technology (AIST), Tokyo, Japan, arXiv:1708.09097v2 [q-bio.QM] 8 Sep 2017 1 ming (DP) [2, 3]. Profile alignment methods using these functions have been successful for a long time [4], although cosine similarity or correlation coefficient cannot capture the non-linear relationship between two vectors and the similarity between two sites is not always expressed by linear relationships. The performance of profile sequence alignment has been improved by various studies in the past decades. For example, HHalign improved alignment quality using profiles constructed with the hidden Markov model, which provided more information than PSSM [5], MUSTER incorporated protein structural information in a profile [3], and MRFalign utilized the Markov random fields to improve alignment quality [6]. Although various methods have been devised from different perspectives, studies to develop the scoring function itself with sophisticated technologies are lacking. Neural networks are computing system, which mimic biological nervous system of animal brains. Theoretically, it can approximate any function regardless of linearity of the functions [7]. Neural networks are attracting attention from various areas of research, including bioinformatics, due to the availability of improved computational methods and the explosive increase in available data. In recent years, these algorithms have been vigorously applied to bioinformatics. For example, several studies applied a deep neural network model to predict protein-protein interaction [8, 9], protein structure [10, 11] and various other biological conditions such as residue contact map, backbone angles, and solvent accessibility [12, 13]. These algorithms basically used the backpropagation method, which requires derivation of a cost function for searching optimal parameters, and few studies implemented derivative free neural network. In this study, we utilized the neural network to optimize a scoring function. In the process, we first combined two PSSVs (for which we wanted to calculate similarity) derived from two sites and set it as an input vector. A target vector was required to implement supervised learning. However, in this case, we did not have the target vector because the ideal function and an ideal similarity score for each site were unknown, and thus, the scoring function could not be directly optimized. Instead, we calculated the entire DP table for the input sequences and the difference between the resultant alignment and the correct alignment was Abstract A profile comparison method with position-specific scoring matrix (PSSM) is one of the most accurate alignment methods. Currently, cosine similarity and correlation coefficient are used as scoring functions of dynamic programming to calculate similarity between PSSMs. However, it is unclear that these functions are optimal for profile alignment methods. At least, by definition, these functions cannot capture non-linear relationships between profiles. Therefore, in this study, we attempted to discover a novel scoring function, which was more suitable for the profile comparison method than the existing ones. Firstly we implemented a new derivative free neural network by combining the conventional neural network with evolutionary strategy optimization method. Next, using the framework, the scoring function was optimized for aligning remote sequence pairs. Nepal, the pairwise profile aligner with the novel scoring function significantly improved both alignment sensitivity and precision, compared to aligners with the existing functions. Nepal improved alignment quality because of adaptation to remote sequence alignment and increasing the expressive power of similarity score. The novel scoring function can be realized using a simple matrix operation and easily incorporated into other aligners. With our scoring function, the performance of homology detection and/or multiple sequence alignment for remote homologous sequences would be further improved. Introduction The profile comparison alignment method with a positionspecific scoring matrix (PSSM) [1] is one of the most accurate alignment methods. The PSSM is a two dimensional vector (matrix) for sequence length. Each element in the vector consists of a 20 dimensional numerical vector, in which each value represents the likelihood of the existence of each amino acid position in a biological sequence. Here, we designed the vector inside PSSM as a position-specific scoring vector (PSSV). In a profile alignment, cosine similarity or correlation coefficient is generally calculated against the PSSVs to calculate similarity or dissimilarity between the two sites in the sequences of interest on dynamic program1 used for calculating cost. In this case, we could not use the backpropagation method for optimal weight search because we lacked the derivation of the cost function required for this search. Namely, we could not incorporate our idea in the conventional neural network framework. Therefore, we newly utilized the covariance matrix adaptation evolution strategy (CMA-ES) [14], which is an adaptive optimization method modifying the basic evolutionary strategy [15], as the search method for neural network to realize derivative free neural network calculation. Using this framework, we attempted to produce higher performance scoring function for remote sequence alignment in this study. Pairwise sequence profile Dynamic programming PSSV A W1a (u) xa w2 Score PSSV B METHODS y Dataset W1b Bias xb We downloaded the non-redundant subset of SCOP40 (1.75 release) [16], in which sequence identity between any sequence pair is less than 40%, from ASTRAL [17]. We selected the remote sequence subset since we wanted to improve the remote sequence alignment quality. The SCOP is a protein domain dataset where sequences are classified in hierarchical manner by class, fold, superfamily, and family. All notations of the superfamily in the dataset were sorted by alphabetical order and all superfamilies, the ordered numbers of which were multiples of three, were classified into a learning dataset, whereas the others were classified into a test dataset. We obtained 3,726 and 6,843 sequences in the learning and test datasets, respectively. Next, we randomly extracted a maximum of 10 pairs of sequences from each superfamily to negate a bias induced by different volumes of each superfamily and used these sequence pairs for subsequence construction of PSSM. We confirmed that sequences in each pair were from the same family to obtain decent reference alignment. Finally, we obtained 1,721 and 3,195 sequence pairs in the learning and test datasets. b2 1 b1 Bias 1 Completing DP table with the score Calculation of cost with test and reference alignment Figure 1. Schematic diagram of learning network developed in this study. The upper case letters in italics and bold face, the lower case letters in italics and bold face, and the lower case letters in italics represent matrix, vector, and scalar values, respectively. The activating function is represented by φ(). Construction of profiles and reference alignments y = w2 φ(xa W1a + xb W1b + b1 ) + b2 Figure 1 shows the learning network computed in this study. We calculated similarity scores between two PSSVs using the neural network. At first, the summation of matrix products between xa (the PSSV A) and W1a, xb (the other PSSV B) and W1b, and 1 (bias) and b1 in the neural network were calculated. The resultant vector was transformed by an activating function, φ(). Finally, the summation of the dot products between the transformed vector and w2, and 1 and b2 was calculated. The resultant value was used as the similarity score for the two sites. Namely, the forward calculation was computed by the following equation. Here, y is the similarity score. The complete DP table was calculated using the similarity score and a final pairwise alignment was produced. The pairwise alignment and its corresponding reference alignment were compared to each other and an alignment sensitivity score, described below, was calculated. The subtraction of the alignment sensitivity score from 1 was used as cost for searching optimum weight by the neural network with CMA-ES. We set the weights W1a and W1b equal to each other (shared weight) so that the network outputs same value even though the input order of the two PSSVs were opposite. The 2 number of units of the middle layer was set to 144. The rectified linear unit was utilized as the activation function. We set σ, λ, and µ as 0.032, 70, and 35, respectively, as parameters for CMA-ES. Here, σ is almost equivalent to step size of the gradient descent method, and λ and µ indicate the number of descendant and survival individuals in evolutional process. In actual learning, we read training datasets in batch manner. The learning loop was stopped using the early stopping criteria by checking the dissociation between the training and validating curves. The initial weight was derived from parameters that mimicked the correlation coefficient. To generate the initial weight, we randomly generated 200,000 PSSM pairs and learned them using multilayer perceptron with hyperparameters (the dimension of weight and activating function) identical to the above hyperparameters. In addition to the weights, we simultaneously optimized the open and extension gap penalties. The initial values of open and extension gap penalties were set as -1.5 and -0.1. functions, changing open and extension gap penalties by 0.1 increments from -2.0 to -0.6 and from -0.4 to -0.1, respectively. The best alignment sensitivity was selected as the optimum combination among the combinations of open and extension gap penalties. As shown in Table 1, the best gap penalty combination for cosine similarity and correlation coefficient was (-1.0, -0.1) and (-1.5, -0.1). Optimization of scoring function of the neural network Next, we conducted optimization of scoring function on the neural network with CMA-ES. During learning, we randomly divided the learning dataset into two subsets, namely, the training and validation datasets, which included 1,536 and 160 pairwise PSSV sets and its corresponding reference alignments as targets, respectively. Since calculation of CMA-ES in our parameter settings requires more than 100,000 times DP (the size of training dataset × λ) per epoch, the consumption of computer resources was large and calculation time was long even when 24 threads were used with the C++ program; therefore, we set the maximum limit for epoch to a small number such as 150. We selected the best scores from the validation scores of the last fifth part of an entire epoch (which was derived from 145th epoch) and obtained final weight and bias matrices, namely, the substance of a novel scoring function and optimal gap penalty combination, respectively. As a result, optimal combination of open and extension gap penalty for the final weight and bias matrix were approximately -1.7 and -0.2. Finally, we implemented the pairwise profile aligner with the weight and bias matrices as novel scoring function and named it as neural network enhanced profile alignment library (Nepal). Our aligner and scoring function (weight and bias matrices) can be downloaded from https://github.com/yamada-kd/nepal. Alignment algorithm In this study, we implemented the semi-global alignment method, namely global alignment with free end-gaps method [18, 19]. Metrics of alignment quality The alignment quality was evaluated using alignment sensitivity and precision [20]. The alignment sensitivity was calculated by dividing the number of correctly aligned sites by the number of non-gapped sites in a reference alignment. In contrast, alignment precision was calculated by dividing the number of correctly aligned sites by the number of nongapped sites in a test alignment. Calculation of residue interior propensity The relative accessible surface area (rASA) for residues of all proteins in the learning and test dataset was calculated by areaimol in CCP4 package version 6.5.0 [21]. The residues of which rASA is less than 0.25 were counted as an interior residue and the other residues were counted as surface residue, according to a previous study [22]. We divided the ratio of the interior residues by the background probability of residues to calculate the residue interior propensity. The residue interior propensity is the likelihood of a residue existing inside a protein. Namely, propensity greater than 1 signifies that the probability of the residue to be inside the protein is high. Benchmark of Nepal and other aligners with existing function on the test dataset Next, we conducted benchmark test of Nepal and other aligners with existing functions on the test dataset. In addition to profile comparison methods, we examined the performance of sequence comparison aligners with difference substitution matrices such as BLOSUM62 [23] and MIQS [24] for reference. We used -10 and -2 as open and extension gap penalties, respectively, based on a previous study [24]. When calculating alignment qualities, the test dataset Table 1. Gap optimization of the existing scoring function RESULTS AND DISCUSSION Cosine CC Gap optimization of existing functions At first, we conducted gap penalty optimization of the existing scoring functions such as cosine similarity and correlation coefficient on the learning dataset. We computed both alignment sensitivity and precision for aligners using these Open -1.0 -1.5 Extension -0.1 -0.1 Sensitivity 0.6837 0.6882 Precision 0.6550 0.6613 Open and Extension indicate optimized open and extension gap penalties, respectively, and Cosine and CC represent aligners with a cosine similarity and correlation coefficient as scoring functions, respectively. 3 Table 2. Comparison of Nepal with other alignment methods was further categorized into remote and medium subset depending on pairwise sequence identity of the reference alignments. The remote and medium subset includes sequence pairs, of which each sequence identity was not lower than 0% and less than 20%, and not lower than 20% and less than 40%, respectively. Generally, a pairwise alignment between sequences of lower identity such as those in the twilight zone is more difficult [25]. Table 2 shows alignment quality scores for each method. Results show that among the existing methods, including sequence comparison methods, the method with the best performance from all perspectives was the profile comparison method with correlation coefficient scoring function. In contrast, Nepal improved both alignment sensitivity and precision compared to this method. Actually, these improvements were statistically significant according to Wilcoxon signed rank test with Bonferroni correction even when significance level (α) is set to 0.01. Comparison between sequencebased methods with different substitution matrices such as MIQS and BLOSUM62 showed that the gain of improvement of MIQS compared to BLOSUM62 was more significant for the remote subset than the medium subset. This was expected since MIQS was originally developed to improve remote homology alignment. This trend was observed regarding the relationship between Nepal and correlation coefficient implemented aligner, where Nepal improved both alignment sensitivity and precision by about 4% and 1% in remote and medium subsets, respectively. This indicated that the novel scoring function was optimized for remote sequence alignment. This is expected because sequence alignment between sequences with closer identities was easier than those with remote identities. Therefore, during optimization, the novel scoring function would be optimized to be naturally advantageous for remote sequence alignments. Since the problem regarding remote relationship holds true for sequence similarity search [24, 26], the novel scoring function of our method could be useful for improving the performance of remote similarity search methods. Sensitivity Nepal Cosine CC MIQS BL62 Precision Nepal Cosine CC MIQS BL62 Remote [0,20) (1,405 files) Medium [20,40) (1,790 files) All [0,40) (3,195 files) 0.5317 0.5045∗∗ 0.5135∗∗ 0.2775∗∗ 0.2333∗∗ 0.8343 0.8246∗∗ 0.8269∗∗ 0.7316∗∗ 0.6955∗∗ 0.7012 0.6838∗∗ 0.6891∗∗ 0.5319∗∗ 0.4923∗∗ 0.5031 0.4753∗∗ 0.4858∗∗ 0.2654∗∗ 0.2317∗∗ 0.8102 0.7999∗∗ 0.8032∗∗ 0.7134∗∗ 0.6902∗∗ 0.6751 0.6571∗∗ 0.6636∗∗ 0.5164∗∗ 0.4885∗∗ The interval on the second line in the header represents sequence identity (%) of each division. Methods such as Cosine, CC, MIQS, and BL62 indicate profile comparison methods with cosine similarity and correlation coefficient and sequence comparison methods with MIQS and BLOSUM62. The double asterisks on the score (∗∗ ) indicate p-value < 0.01 on Wilcoxon signed rank test with Bonferroni correction when the method is compared to Nepal. cient between the connection weight and interior propensity was approximately 0.6 and the value was statistically significant (p-value < 0.05). While residues which are exposed on the protein surface are subject to higher mutation pressures, interior residues are less susceptible to mutation [28]. This is because the protein structure is disrupted if mutations in the interior residues collapse the hydrophobic core [29]. The scoring function constructed in this study was optimized for alignment of remote homologous sequences. According to the previous study based on substitution matrices [30], hydrophobicity of residues was the dominant property of remote sequence substitution rather than simple mutability. This fact partially represents that for remote sequence alignment, residues occupying interior locations in a protein higher order structure with less susceptibility to mutation pressure are considered more meaningful. Since our scoring function was also optimized for remote sequence alignment, the above property would be observed and this fact paradoxically suggests that our scoring function was optimized for remote sequence alignment. Collectively, this property is one of the reasons for the superiority of our method to the existing ones. In addition, although the connection weight consisted of various values, it would at least contribute to increasing the expressive power of the novel scoring function. For example, we wanted to calculate the similarity score between PSSV A (a) and B (b) as shown in Figure 3. The original scores are 0.488207 and 0.387911 when calculated using the correlation coefficient and Nepal score, respectively, (middle panel Figure 3). The scores calculated by correlation coefficient did not change when the 1st and 18th sites or the 4th and 19th sites were swapped. This was unexpected since the converted PSSV obtained after swapping was not identical to the original one. This could be one of the drawbacks of us- Importance of attributes using the connection weight method Finally, we calculated the importance of 20 attributes using the connection weight method [27]. As shown in Figure 2A, the connection weights against each attribute, namely each amino acid, were distributed to various values. This indicated that our developed scoring function discerned the importance of the attributes depending on the variety of amino acids. According to the results, the connection weight of hydrophobic residues such as Leu, Ile, and Val were of higher value. These residues are located mostly inside the hydrophobic cores of proteins. In addition, as shown in Figure 2B, the other residues which also tend to locate inside proteins, such as Ala, Cys, and Tyr, were of higher importance. In contrast, residues which tend to locate on protein surface, such as Asp, Pro, Lys, and Asn, were of lower importance. The Spearman’s rank correlation coeffi4 oped a novel scoring function for profile comparison and Nepal, a pairwise profile aligner with the scoring function. Large computational resources were required by our learning procedure with the derivative free neural network; thus, we could not examine whether the learning was converged enough because of our limited computational environment. Nevertheless, Nepal significantly improved alignment quality of profile alignment, especially for alignment of remote relationships, compared to the existing scoring functions. Nepal improved alignment quality because of adaptation to remote sequence alignment and increasing the expressive power of similarity score. The novel scoring function can be realized using a simple matrix operation and the parameters are provided on https://github.com/yamada-kd/nepal. In future, the performance of distant homology detection method or that of multiple sequence alignment method for remote homologous sequences may be further improved with our scoring function. Absolute connection weight A 0.35 0.30 0.25 0.20 0.15 0.10 0.05 0 A L I T C S V Y G R E QW F D H P M K N B Interior propensity 1.3 1.2 1.1 A R N D C Q E G H I L K M F P S T W Y V a -4 -3 0 2 -4 3 3 -2 1 -2 0 0 -3 0 -1 -1 -2 -1 0 -2 b -9 -5 5 3 -1 -1 1 3 -3 -5 -7 0 -8 -4 -2 0 -3 -4 -2 -5 1.0 CC: 0.488207, Nepal: 0.831417 0.9 Swap(1,18) 0.8 A R N D C Q E G H I L K M F P S T W Y V a -1 0 0 2 -4 3 3 -2 1 -2 0 0 -3 0 -1 -1 -2 -4 -3 -2 b -4 -2 5 3 -1 -1 1 3 -3 -5 -7 0 -8 -4 -2 0 -3 -9 -5 -5 A L I T C S V Y G R E QW F D H P M K N CC: 0.488207, Nepal: 0.387911 Figure 2. (A) Absolute connection weight for each attribute, which corresponds to the profile value of each amino acid. Filled and open bar represents positive and negative sign of original connection weight, respectively. (B) The residue interior propensity against whole data in the study. Swap(4,19) A R N D C Q E G H I L K M F P S T W Y V a -1 0 0 -3 -4 3 3 -2 1 -2 0 0 -3 0 -1 -1 -2 -4 2 -2 b -4 -2 5 -5 -1 -1 1 3 -3 -3 -7 0 -8 -4 -2 0 -5 -9 3 -5 ing unweighted linear function such as cosine similarity and correlation coefficient. In contrast, Nepal scores changed after the swapping, which varied with the change in PSSV. Actually, there were about 290,000 overlaps when we calculated similarity score to six places of decimal against randomly generated one million PSSVs using correlation coefficient, whereas there were approximately 180,000 overlaps when Nepal was used. These overlaps would negatively affect DP computation because higher overlap scores would cause difficulty in deciding the correct path, especially during the computation of maximum three values derived from up, diagonal, and left side of the DP cell. Collectively, the different weights based on amino acid variety presented by the connection weight method is one of the reasons why Nepal score improved the alignment quality compared to the existing scoring functions. CC: 0.488207, Nepal: 0.190817 Figure 3. Transition of similarity scores depending on site swapping. In each panel, a and b stand for PSSV A and B respectively. The middle panel represents an original PSSV and similarity scores calculated by correlation coefficient (CC) and Nepal. The top and bottom panel stands for the resultant PSSVs and the similarity scores. ADDITIONAL INFORMATION Acknowledgements We are grateful to Dr Kentaro Tomii, Dr. Satoshi Omori and Mr. Tsukasa Nakamura for constructive discussion. Computations were partially performed on the NIG supercomputer at the ROIS National Institute of Genetics. CONCLUSION In this study, we developed a new derivative free neural network with CMA-ES. Using this framework, we devel5 [12] Pietro Di Lena, Ken Nagata, and Pierre Baldi. Deep architectures for protein contact map prediction. Bioinformatics (Oxford, England), 28:2449–2457, October 2012. Funding This work was supported in part by the Top Global University Project from the Ministry of Education, Culture, Sports, Science, and Technology of Japan (MEXT) [13] Rhys Heffernan, Yuedong Yang, Kuldip Paliwal, and Yaoqi Zhou. Capturing non-local interactions by long short term memory bidirectional recurrent neural networks for improving prediction of protein secondary structure, backbone angles, contact numbers, and solvent accessibility. Bioinformatics (Oxford, England), April 2017. Availability of data and material The source code of Nepal and the learned parameters are available at GitHub (https://github.com/yamada-kd/nepal). [14] Nikolaus Hansen and Andreas Ostermeier. Adapting arbitrary normal mutation distributions in evolution strategies: The covariance matrix adaptation. In Evolutionary Computation, 1996., Proceedings of IEEE International Conference on, pages 312–317. IEEE, 1996. Abbreviations [15] Hans-Georg Beyer. Toward a theory of evolution strategies: Some asymptotical results from the (1,+ λ)-theory. Evolutionary computation, 1(2):165–188, 1993. CMA-ES: covariance matrix adaptation evolution strategy; DP: dynamic programming; PSSM: position-specific scoring matrix; PSSV: position-specific scoring vector [16] Antonina Andreeva, Dave Howorth, John-Marc Chandonia, Steven E Brenner, Tim J P Hubbard, Cyrus Chothia, and Alexey G Murzin. Data growth and its impact on the scop database: new developments. Nucleic acids research, 36:D419–D425, January 2008. [17] John-Marc Chandonia, Gary Hon, Nigel S Walker, Loredana Lo Conte, Patrice Koehl, Michael Levitt, and Steven E Brenner. The astral compendium in 2004. Nucleic acids research, 32:D189–D192, January 2004. Competing interests The authors declare that they have no competing interests. [18] O Gotoh. An improved algorithm for matching biological sequences. Journal of molecular biology, 162:705–708, December 1982. Author Contribution KDY did everything. [19] S B Needleman and C D Wunsch. A general method applicable to the search for similarities in the amino acid sequence of two proteins. Journal of molecular biology, 48:443–453, March 1970. References [20] A Biegert and J SÃűding. Sequence context-specific profiles for homology searching. Proceedings of the National Academy of Sciences of the United States of America, 106:3770–3775, March 2009. [1] S F Altschul, T L Madden, A A SchÃČÂd’ffer, J Zhang, Z Zhang, W Miller, and D J Lipman. Gapped blast and psi-blast: a new generation of protein database search programs. Nucleic acids research, 25:3389–3402, September 1997. [2] Kentaro Tomii and Yutaka Akiyama. Forte: a profile-profile comparison tool for protein fold recognition. Bioinformatics (Oxford, England), 20:594–595, March 2004. [21] Martyn D Winn, Charles C Ballard, Kevin D Cowtan, Eleanor J Dodson, Paul Emsley, Phil R Evans, Ronan M Keegan, Eugene B Krissinel, Andrew G W Leslie, Airlie McCoy, Stuart J McNicholas, Garib N Murshudov, Navraj S Pannu, Elizabeth A Potterton, Harold R Powell, Randy J Read, Alexei Vagin, and Keith S Wilson. Overview of the ccp4 suite and current developments. Acta crystallographica. Section D, Biological crystallography, 67:235–242, April 2011. [3] Sitao Wu and Yang Zhang. Muster: Improving protein sequence profile-profile alignments by using multiple sources of structure information. Proteins, 72:547–556, August 2008. [22] Emmanuel D Levy. A simple definition of structural regions in proteins and its use in analyzing interface evolution. Journal of molecular biology, 403:660–670, November 2010. [4] Kentaro Tomii, Takatsugu Hirokawa, and Chie Motono. Protein structure prediction using a variety of profile libraries and 3d verification. Proteins, 61 Suppl 7:114–121, 2005. [23] S Henikoff and J G Henikoff. Amino acid substitution matrices from protein blocks. Proceedings of the National Academy of Sciences of the United States of America, 89:10915–10919, November 1992. [5] Johannes SÃűding. Protein homology detection by hmm-hmm comparison. Bioinformatics (Oxford, England), 21:951–960, April 2005. [24] Kazunori Yamada and Kentaro Tomii. Revisiting amino acid substitution matrices for identifying distantly related proteins. Bioinformatics (Oxford, England), 30:317–325, February 2014. [6] Jianzhu Ma, Sheng Wang, Zhiyong Wang, and Jinbo Xu. Mrfalign: protein homology detection through alignment of markov random fields. PLoS computational biology, 10:e1003500, March 2014. [25] B Rost. Twilight zone of protein sequence alignments. Protein engineering, 12:85–94, February 1999. [7] G Gybenko. Approximation by superposition of sigmoidal functions. Mathematics of Control, Signals and Systems, 2(4):303–314, 1989. [26] Piero Fariselli, Ivan Rossi, Emidio Capriotti, and Rita Casadio. The wwwh of remote homolog detection: the state of the art. Briefings in bioinformatics, 8:78–87, March 2007. [8] Xiuquan Du, Shiwei Sun, Changlin Hu, Yu Yao, Yuanting Yan, and Yanping Zhang. Deepppi: Boosting prediction of protein-protein interactions with deep neural networks. Journal of chemical information and modeling, 57:1499–1510, June 2017. [27] Julian D Olden, Michael K Joy, and Russell G Death. An accurate comparison of methods for quantifying variable importance in artificial neural networks using simulated data. Ecological Modelling, 178(3):389–397, 2004. [9] Tanlin Sun, Bo Zhou, Luhua Lai, and Jianfeng Pei. Sequence-based prediction of protein protein interaction using a deep-learning algorithm. BMC bioinformatics, 18(1):277, 2017. [28] Jianzhi Zhang and Jian-Rong Yang. Determinants of the rate of protein sequence evolution. Nature reviews. Genetics, 16:409–420, July 2015. [10] Sheng Wang, Jian Peng, Jianzhu Ma, and Jinbo Xu. Protein secondary structure prediction using deep convolutional neural fields. Scientific reports, 6:18962, January 2016. [29] S Chakravarty and R Varadarajan. Residue depth: a novel parameter for the analysis of protein structure and stability. Structure (London, England : 1993), 7:723–732, July 1999. [30] Akira R Kinjo and Ken Nishikawa. Eigenvalue analysis of amino acid substitution matrices reveals a sharp transition of the mode of sequence conservation in proteins. Bioinformatics (Oxford, England), 20:2504–2508, November 2004. [11] Matt Spencer, Jesse Eickholt, and Jianlin Cheng. A deep learning network approach to ab initio protein secondary structure prediction. IEEE/ACM transactions on computational biology and bioinformatics, 12:103–112, 2015. 6
9cs.NE
1 Gene Similarity-based Approaches for Determining Core-Genes of Chloroplasts Bassam AlKindy∗† , Christophe Guyeux∗ , Jean-François Couchot∗ , Michel Salomon∗ , Jacques M. Bahi∗ ∗ FEMTO-ST arXiv:1412.5323v1 [cs.NE] 17 Dec 2014 Institute, UMR 6174 CNRS, DISC Computer Science Department, University of Franche-Comté, France † Department of Computer Science, University of Mustansiriyah, Baghdad, Iraq {bassam.al-kindy, christophe.guyeux, jean-francois.couchot, michel.salomon, jacques.bahi}@univ-fcomte.fr Abstract—1 In computational biology and bioinformatics, the manner to understand evolution processes within various related organisms paid a lot of attention these last decades. However, accurate methodologies are still needed to discover genes content evolution. In a previous work, two novel approaches based on sequence similarities and genes features have been proposed. More precisely, we proposed to use genes names, sequence similarities, or both, insured either from NCBI or from DOGMA annotation tools. Dogma has the advantage to be an up-to-date accurate automatic tool specifically designed for chloroplasts, whereas NCBI possesses high quality human curated genes (together with wrongly annotated ones). The key idea of the former proposal was to take the best from these two tools. However, the first proposal was limited by name variations and spelling errors on the NCBI side, leading to core trees of low quality. In this paper, these flaws are fixed by improving the comparison of NCBI and DOGMA results, and by relaxing constraints on gene names while adding a stage of post-validation on gene sequences. The two stages of similarity measures, on names and sequences, are thus proposed for sequence clustering. This improves results that can be obtained using either NCBI or DOGMA alone. Results obtained with this “quality control test” are further investigated and compared with previously released ones, on both computational and biological aspects, considering a set of 99 chloroplastic genomes. Index Terms—Chloroplasts, Clustering, Quality Control, Methodology, Pan genome, Core genome, Evolution I. I NTRODUCTION The idea motivating the importance of identifying core genes is to understand the shared functionality of a given set of species. We introduced in a previous work [1] two methods for discovering core and pan genes of chloroplastic genomes using both sequence similarity and alignment based approaches. To determine these core and pan genomes for a large set of DNA sequences, we propose in this work to improve the alignment based approach by considering a novel sequence quality control test. More precisely, we focus on the following questions considering a collection of 99 chloroplasts: how can we identify the best core genome (an artificially designed set of coding sequences as close as possible to the real biological one) and how to deduce scenarii regarding their gene loss. 1 This paper was submitted to IEEE International Conference on Bioinformatics and Biomedicine (BIBM 2014) on 15/07/2014, Accepted 05/09/2014. Oral presentation was on 05/11/2014. The term Chloroplast comes from the combination of plastid and chloro, meaning that it is an organelle found in plant and eukaryotic algae cells which contains chlorophyll. Chloroplasts may have evolved from Cyanobacteria through endosymbiosis and since their main objective is to conduct photosynthesis, these fundamental tiny energy factories are present in many organisms. This key role explains why chloroplasts are at the basis of most trophic pyramids and thus responsible for evolution and speciation. Moreover, as photosynthetic organisms release atmospheric oxygen when converting light energy into chemical energy and simultaneously produce organic molecules from carbon dioxide, they originated the breathable air and represent a mid to long term carbon storage medium. Consequently, exploring the evolutionary history of chloroplasts is of great interest and therefore further phylogenetic studies are needed. An early study of finding the common genes in chloroplasts was realized in 1998 by Stoebe et al. [2]. They established the distribution of 190 identified genes and 66 hypothetical protein-coding genes (ysf ) in all nine photosynthetic algal plastid genomes available (excluding non photosynthetic Astasia tonga) from the last update of plastid genes nomenclature and distribution. The distribution reveals a set of approximately 50 core protein-coding genes retained in all taxa. In 2003, Grzebyk et al. [3], have studied the core genes among 24 chloroplastic sequences extracted from public databases, 10 of them being algae plastid genomes. They broadly clustered the 50 genes from Stoebe et al. into three major functional domains: (1) genes encoded for ATP synthesis (atp genes); (2) genes encoded for photosynthetic processes (psa and psb genes); and (3) housekeeping genes that include the plastid ribosomal proteins (rpl and rps genes). The study shows that all plastid genomes were rich in housekeeping genes with one rbcLg gene involved in photosynthesis. To determine core chloroplast genomes for a given set of photosynthetic organisms, bioinformatics investigations using sequence annotation and comparison tools are required, and therefore various choices are possible. The purpose of our research work is precisely to study the impact of these choices on the obtained results. A general presentation of the approaches we propose is provided in Section II. A closer examination of the approaches is given in Section III. Section III-A will present coding sequences clustering method based on sequence 2 similarity, while Section III-B will describe quality test method based on quality genes. The paper ends with a discussion based on biological aspects regarding the evolutionary history of the considered genomes, leading to our methodology proposal for core and pan genomes discovery of chloroplasts, followed by a conclusion section summarizing our investigations. II. A N OVERVIEW OF THE P IPELINE Instead of considering only gene sequences taken from NCBI or DOGMA [4], an improved quality test process now takes place as shown in Figure 1. It works with gene names and sequences, to produce what we call “quality genes”. Remark that such a simple general idea is not so easy to realize, and that it is not sufficient to only consider gene names provided by such tools. Providing good annotations is an important stage for extracting gene features. Indeed, gene features here could be considered as: gene names, gene sequences, protein sequences, and so on. We will subsequently propose methods that use gene names and sequences for extracting core genes and producing chloroplast evolutionary tree. Real genomes were used in this study, which cover eleven types of chloroplast families (see [1] for more details). Furthermore, two kinds of annotations will be considered in this document, namely the ones provided by NCBI on the one hand, and the ones by DOGMA on the other hand. A. Similarity-based approach Basically, this method starts with annotated genomes either from NCBI or DOGMA and uses a distance d : N = {A, T, C, G}∗ × {A, T, C, G}∗ → [0, 1] on genes coding sequences to group similar alleles in a same cluster. For a given threshold T ∈ [0, 1] and a similarity measure d, the method builds the similarity undirected graph where vertices are alleles and s.t. there is an edge between gi and gj if we have d(gi , gj ) 6 T . Each connected component (CC) of this graph defines a class of the DNA sequences and is abusively called a “gene”, whereas all its nodes (DNA sequences) are the “alleles” of this gene. Let π the function that maps each into its  G sequence G representative gene. Each genome G = g , ..., g mG is thus 1  G ) where duplicated mapped into the set π(g1G ), ..., π(gm G genes are removed. Consequently, the core genome (resp., the pan genome) of two genomes G1 and G2 is defined as the intersection (resp., as the union) of their projected genomes. The intersection (resp. the union) of all the projected genomes constitutes the core genome (resp. the pan genome) of the whole species. Let us now consider the 99 chloroplastic genomes introduced earlier. We use in this case study either the coding sequences downloaded from NCBI website or the sequences predicted by DOGMA. Each genome is thus constituted by a list of coding sequences. In this illustration study, we have evaluated the similarity between two sequences by using a global alignment. More precisely, the measure d introduced in the first approach is the similarity score provided after a Needleman-Wunch global alignment, by the emboss package released by EMBL [5]. The number of genes in the core genome and in the pan genome have been computed. Obtained results from various threshold values are represented in Table I. Remark that when the threshold is large, the pan genome is large too. No matter the chosen annotation tool, this first approach suffers from producing too small core genomes, for any chosen similarity threshold, compared to what is usually expected by biologists. TABLE I: Size of core and pan genomes w.r.t. the similarity threshold Fig. 1: An overview of the pipeline III. C ORE GENES EXTRACTION To make this document self contained, we recall the same definition with a fast revision of similarity based method. Threshold(%) 50 55 60 65 70 75 80 85 90 95 100 Method 1 NCBI DOGMA core pan core pan 1 163 1 118 5 692 2 409 2 1032 2 519 1 1454 2 685 0 2000 1 1116 0 2667 1 1781 0 3541 0 2730 0 4620 0 3945 0 5703 0 5181 0 7307 0 7302 0 8911 0 10132 B. Quality test approach Let us present our new approach. In this one, we propose to integrate a similarity distance on gene names into the pipeline. 3 Each similarity is computed between a name from DOGMA and a name from NCBI, as shown in Figure 2. Vision output, this defragmentation consists in concatenating all the possible permutations (in the case of duplication), and only keeping the permutation with the best similarity score in comparisons with other sequences having the same gene name, if this score is larger than the given threshold. IV. I MPLEMENTATION All algorithms have been implemented using Python language version 2.7, on a personal computer running Ubuntu 12.04 32bit with 6 GByte memory, and a quad-core Intel core i5 processor with an operating frequency of 2.5 GHz. A. Construction of quality genomes Fig. 2: Part of the implementation of the second method, comparison of the common genes from NCBI and DOGMA. The proposed distance is the Levenshtein one, which is close to the Needleman-Wunsch, except that gap opening and extension penalties are equal. The same name is then set to sequences whose NCBI names are close according to this edit distance. The risk is now to merge genes that are different but whose names are similar (for instance, ND4 and ND4L are two different mitochondrial genes, but with similar names). To fix such a flaw, the sequence similarity, for intersected genes in a genome, is compared too in a second stage (with a NeedlemanWunsch global alignment) after selecting a genome accession number, and the genes correspondence is simply ignored if this similarity is below a predefined threshold. We call this operation, which will result in a set of quality genes, a quality test. A result from this quality test process is a set of quality genes. These genes will then constitute the quality genomes. A list of generated quality genomes based on specific threshold will construct the intersection core matrix to generate the core genes, core tree, and phylogenetic tree after choosing an appropriate outgroup. It is important to note that DNA sequence annotation raises a problem in the case of DOGMA: contrary to what happens with gene features in NCBI, genes predicted by DOGMA annotation may be fragmented in several parts. Such genes are stored in the Gene-Vision file format produced by DOGMA, as each fragment is in this file with the same gene name. A gene whose name is present at least twice in the file is either a duplicated gene or a fragmented one. Obviously, fragmented genes must be defragmented before the DNA similarity computation stage (remark that such a defragmentation has already been realized on NCBI website). As the orientation of each fragment is given in the Gene- (a) Sizes of genomes based on NCBI and DOGMA annotations. We can see in this figure that the number of genes with DOGMA is larger than with NCBI, because the former generates more tRNAs and rRNAs genes than NCBI. (b) Percentage of genes coverage between NCBI and DOGMA. The former outperforms the latter, as almost all genes in NCBI genomes have been covered with common genes, while most of DOGMA genes are ignored. However, correlation of them with NCBI (after quality test) is 0.6731, while it is 0.9664 with DOGMA, this latter being thus more accurate than NCBI. Fig. 3: Original and coverage sizes between NCBI and DOGMA genomes based on threshold of 60% To produce a core tree and genomes based on quality control approach2 , we need to know what are the common genes that share almost the same name and sequence from different annotation tools. Figure 3a shows the original amount of genes based on two different annotation tools, their correlation is equal to 0.57. A two steps quality test routine is then launched to produce “quality genomes” and to enlarge the correlation: (1) select all common genes based on gene names and (2) check the similarity of sequences, which must be larger than a predefined threshold. Figure 3b presents the genes coverage percentage between NCBI and DOGMA. Remark that, gene differences between such annotation tools can affect the final 2 see http://members.femto-st.fr/christophe-guyeux/en/chloroplasts 4 core genome. More precisely, The number of tRNAs and rRNAs genes are very high in the case of DOGMA annotation, while they are very low in the case of NCBI. There are also some unnamed or badly named ORFs genes in the case of NCBI. These genes may improve the final core genome, if their functionality are well defined. B. Core and pan genomes Fig. 4: Amount of core genes from each method w.r.t threshold. Note that a maximal number of core genes does not mean good core genomes: we are looking for genes meeting biological requirements. The number of Core genes, illustrated in Figure 4, represents the amount of genes in the computed core genome. The main goal is to find the largest number of core genes that is compatible with biological background related to chloroplasts. From the first approach with a threshold of 60%, we have obtained 2 genes for 99 genomes with NCBI and DOGMA, whereas 4 genes for 98 genomes have been found using the second approach. In the case of second approach, we have ignored one genome for Micromonas pusilla under the accession (NC_012568.1) from our sample, because we have a few amount of quality genes or none that could have been generated from its correspondents. With the second approach, zero gene in rooted core genome means that we have two or more subtrees of organisms that are completely divergent among each other. Unfortunately, for the first approach with NCBI annotation, the core genes within NCBI cores tree did not provide true biologically distribution of the genomes. Conversely, in the case of DOGMA annotation, the distribution of genomes is biologically relevant. The NCBI under performance may be explained by broken subcores due to an artificially low number of genes in some genomes intersection, which could be explained by coding sequence prediction or annotation errors, or by very divergent genomes. More precisely, Micromonas pusilla (accession number NC_012568.1) is the only genome who totally destroys the final core genome with NCBI annotations, for both gene features and gene quality methods. V. D ISCUSSION According to chloroplast endosymbiotic theory, the primary endosymbiosis has led to three chloroplast lineages among which the two most evolved groups are the chloroplastida and the rhodophyceæ. These chloroplast groups, which respectively consist of Land plants and Green algae, and Red algae, gave rise to secondary plastids when algae cells were engulfed by other heterotrophic eukaryotes through various secondary endosymbioses. Thus Euglens [6] come from Green algae while Red algae gave birth to both Brown algae and Dinoflagellates. Now, if we observe the built core trees, in particular the one gained with quality control approach, we can notice that a primary plastid generated by the first endosymbiosis can be found in a single lineage of the chloroplast genome evolution tree: the chloroplastida group corresponds to a lineage, whereas the rhodophyceæ group is represented by a second one. The generated core tree is composed by two subtrees, the first one containing the lineages of land plants and green algae and the second one presenting the lineages of brown and green algae. In the tree, some chloroplast lineages such as Angiosperms and green algae have well biological distributions, while other lineages (Euglens, Dinoflagellates, and Ferns) are badly distributed when compared to their biological history. Indeed, common quality genes from quality control approach are well covered by most NCBI genomes, while a large number of tRNAs and rRNAs from DOGMA genomes have been lost. VI. C ONCLUSION In this research work, we studied two methodologies for extracting core genes from a large set of chloroplastic genomes, and we developed Python programs to evaluate them in practice. A two stage similarity measure, on names and sequences, is thus proposed for DNA sequences clustering in genes, which merges best results provided by NCBI and DOGMA. Results obtained with this “quality control test” are deeply compared with our previous research work, on both computational and biological aspects, considering a set of 99 chloroplastic genomes. Core trees have finally been generated for each method, to investigate the distribution of chloroplasts and core genomes. The tree from DOGMA annotation has revealed the best distribution of chloroplasts regarding their evolutionary history. In particular, it appears to us that each endosymbiosis event is well branched in the DOGMA core tree. R EFERENCES [1] B. Alkindy, J. F. Couchot, C. Guyeux, A. Mouly, M. Salomon, J. M. Bahi, "Finding the Core-Genes of Chloroplasts", Journal of Bioscience, Biochemistery, and Bioinformatics, IACSIT press, 4(5):357–364, 2014. [2] B. Stoebe, W. Martin, K. V. Kowallik, "Distribution and nomenclature of protein-coding genes in 12 sequenced chloroplast genomes". Plant Molecular Biology Reporter, Springer 16(3):243-255, 1998. [3] D. Grzebyk, O. Schofield, C. Vetriani, P. G. Falkowski, THE MESOZOIC RADIATION OF EUKARYOTIC ALGAE: THE PORTABLE PLASTID HYPOTHESIS1. Journal of Phycology, 39(2):259-267, 2013. [4] Stacia K. Wyman, Robert K. Jansen, Jeffrey L. Boore, "Automatic annotation of organellar genomes with DOGMA", BIOINFORMATICS, oxford Press, 20(172004):3252–3255, 2004. [5] P. Rice, I. Longden, and A. Bleasby. “EMBOSS: the European Molecular Biology Open Software Suite”, Journal Trends in Genetics, 16(6):276277, 2000. [6] Geoffrey I. McFadden,"Primary and secondary endosymbiosis and the origin of plastids", Journal of Phycology, Wiley Online Library 37(6):951– 959, 2001.
9cs.NE
arXiv:1601.02187v3 [math.GR] 14 Feb 2018 NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS SEBASTIAN HENSEL AND DAWID KIELAK Abstract. We generalise the Karrass–Pietrowski–Solitar and the Nielsen realisation theorems from the setting of free groups to that of free products. As a result, we obtain a fixed point theorem for finite groups of outer automorphisms acting on the relative free splitting complex of Handel–Mosher and on the outer space of a free product of Guirardel– Levitt, as well as a relative version of the Nielsen realisation theorem, which in the case of free groups answers a question of Karen Vogtmann. We also prove Nielsen realisation for limit groups, and as a byproduct obtain a new proof that limit groups are CAT(0). The proofs rely on a new version of Stallings’ theorem on groups with at least two ends, in which some control over the behaviour of virtual free factors is gained. 1. Introduction In its original form, the Nielsen realisation problem asks which finite subgroups of the mapping class group of a surface can be realised as groups of homeomorphisms of the surface. A celebrated result of Kerckhoff [Ker1, Ker2] answers this in the positive for all finite subgroups, and even allows for realisations by isometries of a suitable hyperbolic metric. Subsequently, similar realisation results were found in other contexts, perhaps most notably for realising finite groups in Out(Fn ) by isometries of a suitable graph (independently by [Cul], [Khr], [Zim]; compare [HOP] for a different approach). In this article, we begin to develop a relative approach to Nielsen realisation problems. The philosophy here is that if a group G allows for a natural decomposition into pieces, then Nielsen realisation for Out(G) may be reduced to realisation in the pieces, and a gluing problem. In addition to just solving Nielsen realisation for finite subgroups of Out(G), such an approach yields more explicit realisations, which also exhibit the structure of pieces for G. We demonstrate this strategy for two classes of groups: free products and limit groups. In another article, we use the results presented here, together with the philosophy of relative Nielsen realisation, to prove Nielsen realisation for certain right-angled Artin groups ([HK]). The second-named author was supported by the SFB 701. 1 2 SEBASTIAN HENSEL AND DAWID KIELAK The early proofs of Nielsen realisation for free groups rely in a fundamental way on a result of Karrass–Pietrowski–Solitar [KPS], which states that every finitely generated virtually free group acts on a tree with finite edge and vertex stabilisers. In the language of Bass–Serre theory, it amounts to saying that such a virtually free group is a fundamental group of a finite graph of groups with finite edge and vertex groups. This result of Karrass–Pietrowski–Solitar in turn relies on the celebrated theorem of Stallings on groups with at least two ends [Sta1, Sta2]. Stallings’ theorem states that any finitely generated group with at least two ends splits over a finite group, which means that it acts on a tree with a single edge orbit and finite edge stabilisers. Equivalently: it is a fundamental group of a graph of groups with a single edge and a finite edge group. In the first part of this article, we generalise these results to the setting of a free product A = A1 ∗ · · · ∗ An ∗ B in which we (usually) require the factors Ai to be finitely generated, and B to be a finitely generated free group. Consider any finite group H acting on A by outer automorphisms in a way preserving the given free-product decomposition, by which we mean that each element of H sends each subgroup Ai to some Aj (up to conjugation); note that we do not require the action of H to preserve B in any way. We then obtain a corresponding group extension 1→A→A→H→1 In this setting we prove (for formal statements, see the appropriate sections) Relative Stallings’ theorem (Theorem 2.7): A splits over a finite group, in such a way that each Ai fixes a vertex in the associated action on a tree. Relative Karrass–Pietrowski–Solitar theorem (Theorem 4.1): A acts on a tree with finite edge stabilisers, and with each Ai fixing a vertex of the tree, and with, informally speaking, all other vertex groups finite. Relative Nielsen realisation theorem (Theorem 7.5): Suppose that we are given complete non-positively curved (i.e. locally CAT(0)) spaces Xi realising the induced actions of H on the factors Ai . Then the action of H can be realised by a complete non-positively curved space X; in fact X can be chosen to contain the Xi in an equivariant manner. We emphasise that such a relative Nielsen realisation is new even if all Ai are free groups, in which case it answers a question of Karen Vogtmann. The classical Nielsen realisation for graphs immediately implies that a finite subgroup H < Out(Fn ) fixes points in the Culler–Vogtmann Outer Space (defined in [CV]), as well as in the complex of free splittings of Fn (which is a simplicial closure of Outer Space). As an application of the NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 3 work in this article, we similarly obtain fixed point statements (Corollaries 5.1 and 6.1) for the graph of relative free splittings defined by Handel and Mosher [HM], and the outer space of a free product defined by Guirardel and Levitt [GL]. In the last section of the paper we prove Theorem 8.12. Let A be a limit group, and let A→A→H be an extension of A by a finite group H. Then there exists a complete compact locally CAT(κ) space X realising the extension A, where κ = −1 when A is hyperbolic, and κ = 0 otherwise. When κ = −1, the space X is of dimension at most 2. This theorem is obtained by combining the classical Nielsen realisation theorems (for free, free-abelian and surface groups – see Theorems 8.2 to 8.4) with the existence of an invariant JSJ decomposition shown by Bumagin– Kharlampovich–Myasnikov [BKM]. Note that, in general, having a graph of groups decomposition for a group G with CAT(0) vertex groups and virtually cyclic edge groups does not allow one to build a CAT(0) space for G to act on, and thus conclude that G is itself CAT(0); the JSJ decompositions of limit groups are however special in this respect, and the extra structure allows for the conclusion. This has been observed by Sam Brown in [Bro], where he developed techniques for building up a CAT(0) space for G to act on. Observe that we obtain optimal curvature bounds for our space X – it has been proved by Alibegović–Bestvina [AB] that limit groups are CAT(0), and by Sam Brown [Bro] that a limit group is CAT(−1) if and only if it is hyperbolic. Also, taking H to be the trivial group gives a new (more direct) proof of the fact that limit groups are CAT(0). Throughout the paper, we are going to make liberal use of the standard terminology of graphs of groups. The reader may find all the necessary information in Serre’s book [Ser]. We are also going to make use of standard facts about CAT(0) and non-positively curved (NPC) spaces, as well as more general CAT(κ) spaces; the standard reference here is the book by Bridson– Haefliger [BH]. Acknowledgements. The authors would like to thank Karen Vogtmann for discussions and suggesting the statement of relative Nielsen realisation for free groups, Stefan Witzel for pointing out the work of Sam Brown, and the referee for extremely valuable comments. 2. Relative Stallings’ theorem In this section we will prove the relative version of Stallings’ theorem. Before we can begin with the proof, we need a number of definitions to 4 SEBASTIAN HENSEL AND DAWID KIELAK formalise the notion of a free splitting that is preserved by a finite group action. Convention. When talking about free factor decompositions A = A1 ∗ · · · ∗ An ∗ B of some group A, we will always assume that at least two of the factors {A1 , . . . , An , B} are non-trivial. Definition 2.1. Suppose that φ : H → Out(A) is a homomorphism with a finite domain. Let A = A1 ∗ · · · ∗ An ∗ B be a free factor decomposition of A. We say that this decomposition is preserved by H if and only if for every i and every h ∈ H, there is some j such that h(Ai ) is conjugate to Aj . We say that a factor Ai is minimal if and only if for any h ∈ H the fact that h(Ai ) is conjugate to Aj implies that j > i. Remark 2.2. Note that when the decomposition is preserved, we obtain an induced action H → Sym(n) on the indices 1, . . . , n. We may thus speak of the stabilisers StabH (i) inside H. Furthermore, we obtain an induced action StabH (i) → Out(Ai ) The minimality of factors is merely a way of choosing a representative of each H orbit in the action H → Sym(n). Remark 2.3. Given an action φ : H → Out(A), with φ injective and A with trivial centre, we can define A 6 Aut(A) to be the preimage of H = im φ under the natural map Aut(A) → Out(A). We then note that A is an extension of A by H: 1→A→A→H→1 and the left action of H by outer automorphisms agrees with the left conjugation action inside the extension A. Observe that then for each i we also obtain an extension 1 → Ai → Ai → StabH (i) → 1 where Ai is the normaliser of Ai in A. We emphasise that this construction works even when Ai itself is not centre-free. In this case it carries more information than the induced action StabH (i) → Out(Ai ) (e.g. consider the case of Ai = Z – there are many different extensions corresponding to the same map to Out(Z)). We will now begin the proof of the relative version of Stallings’ theorem. It will use ideas from both Dunwoody’s proof [Dun1] and Krön’s proof [Krö]1 of Stallings’ theorem, which we now recall. Convention. If E is a set of edges in a graph Θ, we write Θ − E to mean the graph obtained from Θ by removing the interiors of edges in E. 1We warn the reader that later parts of Krön’s paper are not entirely correct; we only rely on the early, correct sections. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 5 Definition 2.4. Let Θ be a graph. A finite subset E of the edge set of Θ is called a set of cutting edges if and only if Θ − E is disconnected and has at least two infinite components. A cut C is the union of all vertices contained in an infinite connected complementary component of some set of cutting edges. The boundary of C consists of all edges with exactly one endpoint in C. Given two cuts C and D, we call them nested if and only if C or its complement C ∗ is contained in D or its complement D∗ . Note that C ∗ and D∗ do not need to be cuts. We first aim to show the following theorem which is implicit in [Krö]. Theorem 2.5 ([Krö]). Suppose that Θ is a connected graph on which a group G acts. Let P be a subset of the edge set of Θ, which is stable under the G-action. If there exists a set of cutting edges lying in P, then there exists a cut C whose boundary lies in P, such that C ∗ is also a cut, and such that furthermore for any g ∈ G the cuts C and g.C are nested. Sketch of proof. In order to prove this, we recall the following terminology, roughly following Dunwoody. We say that C is a P-cut if and only if its boundary lies in P. Say that a P-cut is P-narrow, if and only if its boundary contains the minimal number of elements among all P-cuts. Note that for each P-narrow cut C, the complement C ∗ is also a cut, as otherwise we could remove some edges from the boundary of C and get another P-cut. Given any edge e ∈ P, there are finitely many P-narrow cuts which contain e in its boundary. This is shown by Dunwoody [Dun1, 2.5] for narrow cuts, and the proof carries over to the P-narrow case. Alternatively, Krön [Krö, Lemma 2.1] shows this for sets of cutting edges which cut the graph into exactly two connected components, and P-narrow cuts have this property. Now, consider for each P-narrow cut C the number m(C) of P-narrow cuts which are not nested with C (this is finite by [Dun1, 2.6]). Call a Pnarrow cut optimally nested if m(C) is smallest amongst all P-narrow cuts. The proof of Theorem 3.3 of [Krö] now shows that optimally nested P-cuts are all nested with each other. This shows Theorem 2.5.  To use that theorem, recall Theorem 2.6 ([Dun1, Theorem 4.1]). Let G be a group acting on a graph Θ. Suppose that there exists a cut C, such that (1) C ∗ is also a cut; and (2) there exists g ∈ G such that g.C is properly contained in C or C ∗ ; and (3) C and h.C are nested for any h ∈ G. Let E be the boundary of C. Then G splits over the stabiliser of E , and the stabiliser of any component of Θ − G.E is contained in a conjugate of a vertex group. 6 SEBASTIAN HENSEL AND DAWID KIELAK Figure 1. A local picture of the graph Θ. Now we are ready for our main splitting result. Theorem 2.7 (Relative Stallings’ Theorem). Let φ : H → Out(A) be a monomorphism with a finite domain. Let A = A1 ∗ · · · ∗ An ∗ B be a free product decomposition with each Ai and B finitely generated, and suppose that it is preserved by H. Let A be the preimage of H = im φ in Aut(A). Then A acts on a tree with finite quotient so that each Ai fixes a vertex, and no non-trivial subgroup of A fixes any edge. Note in particular that the quotient of the associated tree by A has a single edge. Proof. Before we begin the proof in earnest, we will give a brief outline of the strategy. First, we will define a variant of the Cayley graph for A in which the free product structure of A will be visible (in fact, a subgraph will collapse to the Bass-Serre tree of the free product decomposition of A). This graph will contain the different copies if Ai disjointly, separated by edges labelled with a certain label. We will then aim to show that there is a set of cutting edges just using edges with that label – which, using Theorem 2.6, will yield the desired action on a tree. Let Ai and B be finite generating sets of Ai and B, respectively (for all A which maps onto H under the i 6 n). We also choose a finite set H ⊂ S natural epimorphism A → H. Note that i Ai ∪ B ∪ H is a generating set of A. We define Θ to be aS variation of the (right) Cayley graph of A with respect to the generating set i Ai ∪ B ∪ H. Intuitively, every vertex of the Cayley graph will be “blown up” to a finite tree (see Fig. 1). More formally, the vertex set of Θ is V (Θ) = A t (A × {0, . . . , n}) NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 7 We adopt the notation that a vertex corresponding to an element in A will simply be denoted by g, whereas a vertex (g, i) in the second factor will be denoted by gi . We now define the edge set, together with a labelling of the edges by integers 0, 1, . . . , n, as follows: • for each g ∈ A and each i ∈ {0, . . . , n} we have an edge labelled by 0 connecting g to gi ; • for each g ∈ A, each i > 1 and each a ∈ Ai , we have an edge labelled by i from gi to (ga)i ; • for each g ∈ A, and each b ∈ B ∪ H, we have an edge labelled by 0 from g0 to (gb)0 . The group A acts on Θ on the left, preserving the labels. The action is free and co-compact. The graph Θ retracts via a quasi-isometry onto a usual Cayley graph of A by collapsing edges connecting g to gi . Also note that there are copies of the Cayley graphs of the Ai with respect to the generating set Ai in Θ, where each edge has the label i. Let Ω denote a graph constructed in the same way for the group A with S respect to the generating set Ai ∪ B. There is a natural embedding of Ω into Θ, and hence we will consider Ω as a subgraph of Θ. Note that this embedding is also a quasi-isometry. We will now construct n specific quasi-isometric retractions of Θ onto Ω. These will be used later to modify paths in order to avoid edges with certain labels. Let us fix i ∈ {1, . . . , n}. For each h ∈ H we pick a representative hi ∈ A thereof, such that hi Ai hi −1 = Aj for a suitable (and unique) j; for 1 ∈ H we pick 1 ∈ A as a representative. These elements hi are coset representatives of the normal subgroup A of A. Such a choice defines a retraction ρi : Θ → Ω in the following way: each vertex g is mapped to the unique vertex g 0 where g 0 ∈ A and g 0 hi = g for some hi ; the vertex gk is then mapped to (g 0 )k . An edge labelled by 0 connecting g to gk is sent to the edge connecting g 0 to (g 0 )k . The remaining edges with label 0 are sent in an A-equivariant fashion to paths connecting the image of their endpoints; the lengths of such paths are uniformly bounded, since (up to the A-action) there are only finitely many edges with label 0. Similarly, the edges of label k 6∈ {0, i} are mapped in an A-equivariant manner to paths connecting the images of their endpoints; again, their length is uniformly bounded. Each edge labelled by i is sent A-equivariantly to a path connecting the images of its endpoints, such that the path contains edges labelled only by some j (where j is determined by the coset of A the endpoints lie in); such a path exist by the choice of the representatives hi . Note that each such retraction ρi is a (κi , κi )-quasi-isometry for some κi > 1; we set κ = maxi κi . 8 SEBASTIAN HENSEL AND DAWID KIELAK Now we are ready to construct a set of cutting edges in Θ. Consider the ball BΩ (1, 1) of radius 1 around the vertex 1 in Ω (all of whose edges are labelled by 0). Since A is a nontrivial free product, the identity element disconnects the Cayley graph into at least two infinite components. Hence, BΩ (1, 1) disconnects Ω also into at least two infinite components; let us take two vertices of Ω, x and y, lying in distinct infinite components of Ω − BΩ (1, 1), and such that dΩ (1, x) = dΩ (1, y) > κ2 + 4 Now let E denote the set of all edges lying in the ball BΘ (1, κ2 +4) labelled by 0. We claim that E disconnects Θ into at least two infinite components. Note that Θ−E has finitely many components, since E is finite. By possibly choosing x, y even further from each other, it therefore suffices to show that E disconnects x from y (viewed as vertices of Θ). Suppose for a contradiction that there exists a path γ in Θ−E connecting x to y. Using any of the quasi-isometries ρi we immediately see that γ has to go through BΘ (1, κ2 +4), since ρi (γ) must intersect BΩ (1, 1). Note that if γ 0 ⊂ γ is a subpath lying completely in BΘ (1, κ2 + 4), then γ 0 only traverses edges with the same label (as γ does not intersect E). Thus, we can write γ as a concatenation γ = γ1 ∗ · · · ∗ γm where each γi intersects BΘ (1, κ2 + 4) only at edges of one label, and its endpoints lie outside of BΘ (1, κ2 + 4). We modify each γi by pre- and postconcatenating it with a path of length at most 4 (note that all the elements of H correspond to edges), so that it now starts and ends at Ω. Still, the new path (which we will continue to call γi ) intersects BΘ (1, κ2 + 1) only at edges labelled by a single label. Now we construct a new path γ 0 as follows. Suppose that ki is such that each edge in γi ∩ BΘ (1, κ2 + 1) has label ki . We put γi0 = ρki (γi ) Note that as ρki is a retraction onto Ω, and the endpoints of γi are in Ω, the path γi0 has the same endpoints as γi . Put 0 γ 0 = γ10 ∗ · · · ∗ γm This is now a path joining x to y in Ω, and thus contains an edge e ∈ BΩ (1, 1) There exists an edge f in some γi , such that e lies in the image of f under the map ρki that we applied to γi . Since each ρk is an (κ, κ)-quasi-isometry, the edge f lies within BΘ (1, κ2 + 1). But then ρki (f ) is a path the edges of whom are never labelled by 0, and so in particular e 6∈ E, a contradiction. We now apply Theorem 2.5, taking P to be the set of edges labelled by 0. Let C denote the cut we obtain, and let F denote its boundary. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 9 To apply Theorem 2.6 we need to only show that for some g ∈ A we have g.C properly contained in C or C ∗ . Since C ∗ is infinite, it contains an element g ∈ A such that g.F 6= F . Taking such a g, we see that either g.C is properly contained in C ∗ (in which case we are done), or C is properly contained in g.C. In the latter case we have g −1 .C ⊂ C. We have thus verified all the hypotheses of Theorem 2.6. Since the boundary F of the final cut C is labelled by 0, upon removal of the open edges in A.F , the connected component containing 1i contains the entire subgroup Ai , since vertices corresponding to elements of this subgroup are connected to 1i by paths labelled by i. Thus Ai is a subgroup of a conjugate of a vertex group, and so it fixes a vertex in the associated action on a tree. It remains to show the triviality of edge stabilisers in A. In fact we will show that no non-trivial subgroup G < A fixes a narrow cut in Θ with boundary consisting only of edges labelled by 0. To this end, let C be such a cut, and F the set of edges forming the boundary of C. We begin by considering the subgraph Ω. Let Γ be an infinite component of Ω − F , and h ∈ H be arbitrary. There are infinitely many vertices v in Γ such that no edge emanating from v lies in F (as the latter is finite). Take one such vertex, and consider an edge e in its star which corresponds to right multiplication with h. Since h normalises A, it in fact connects Ω to h.Ω. On the other hand, there can be only a single component of h.Ω − F which is connected to Γ as the cut C is narrow: otherwise the components of h.Ω − F would lie in the same component of Θ − F , and F would fail the definition of a boundary of a cut. In summary, we have shown, that for each h, each infinite component Γ of Ω − F is connected (via an edge corresponding to right multiplication by h) to a unique infinite component of h.Ω − F . In other words, infinite components of Ω − F and h.Ω − F are in bijection to each other, where the bijection identifies components which are connected in Θ − F . Now, we can think of Ω as the Bass-Serre tree for the splitting of A, whose vertices have been “blown up” to Cayley graphs of the subgroups Ai . In particular, each edge labelled by 0 disconnects Ω. This implies that Ω − F , and hence each h.Ω − F , has exactly two components, both of which are infinite. Namely, if Ω−F would have more than two infinite components, or just a single one, the same would be true for Θ − F , violating narrowness of the cut F . It also implies that F ∩h.Ω consists of exactly one edge for each h. Since A acts freely on Ω, this implies the final claim of the theorem.  3. Blow-ups We make the convention that graphs of groups are always connected unless explicitly stated otherwise. Proposition 3.1 (Blow-up with finite edge groups). Let G be a graph of groups with finite edge groups. For each vertex v suppose that the associated 10 SEBASTIAN HENSEL AND DAWID KIELAK vertex group Gv acts on a connected space Xv in such a way that each finite subgroup of Gv fixes a point of Xv . Then there exists a connected space Y on which π1 (G) acts, satisfying the following: e (1) there is a π1 (G)-equivariant map π : Y → G; e fixed by Gv , then π −1 (w) is Gv -equivariantly (2) if w is a vertex of G isometric to Xv ; (3) every finite subgroup of G fixes a point of Y . Moreover, when the spaces Xv are compact, complete and CAT(0) then Y is a compact, complete CAT(0) space. e are left cosets of the vertex groups Gv of Proof. Recall that the vertices of G G; for each vertex w we pick an element zw ∈ G to be a coset representative of such a coset. We will build the space Y in two steps. First, we construct the preimage e and call it V . We define V to be the disjoint under π of the vertices of G, e and Xw is an union of spaces Xw , where w runs over the vertices of G, isometric copy of Xv , where v is the image of w under the quotient map e → G. We construct π : V → G e by declaring π(Xw ) = {w}. G We now construct an action of A = π1 (G) on V . Let us take Xw ⊂ V , and let a ∈ A. Let u = a.w, and note that its image in G is still v. The action of a on V will take Xw to Xu ; using the identifications Xw ' Xv ' Xu we −1 a. only need to say how a is supposed to act on Xv , and here it acts as zw We now construct the space Y by adding edges to V . e with terminal endpoint w and initial endpoint u. Let e be an edge of G Let Xe denote a copy of the unit interval. Now Ge is a finite subgroup of Gw , and so fixes a point in Xw seen as a subset of V . We glue the endpoint 1 of Xe to this point. Analogously, we glue the endpoint 0 to a point in Xu . Now, using the action of A, we equivariantly glue all the endpoints of the edges in the A-orbit of e. We proceed this way for all (geometric) edges. Note that this construction allows us to extend the definition of π. When all the vertex spaces are complete CAT(0), it is clear that so is Y.  Remark 3.2. Suppose that the spaces Xv in the above proposition are trees. Then the resulting space Y is a tree, and the quotient graph of groups is obtained from G by replacing v by the quotient graph of groups X//Gv . We will refer to the above construction as blowing up G by the spaces Xv . We warn the reader that our notion of a blow-up is not standard terminology (and has nothing to do with blow-ups in other fields). When dealing with limit groups, we will need a more powerful version of a blow-up. We will use a method by Sam Brown, essentially following [Bro, Theorem 3.1]; to this end let us start with a number of definitions and standard facts. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 11 Definition 3.3. An n-simplex of type Mκ is the convex hull of n + 1 points in general position lying in the n-dimensional model space Mκ of curvature κ, as defined in [BH]. An Mκ -simplicial complex K is a simplicial complex in which each simplex is endowed with the metric of a simplex of type Mκ , and the face inclusions are isometries. Note that we will be interested in the case of n = 2 and negative κ, where the model space Mκ is just a suitably rescaled hyperbolic plane. Definition 3.4. Let K be a Mκ -simplicial complex of dimension at most 2. The link of a vertex v is a metric graph whose vertices are edges of K incident at v, and edges are 2-simplices of K containing v. Inclusion of edges into simplices in X induces the inclusion of vertices into edges in the link. The length of an edge in the link is equal to the angle the edges corresponding to its endpoints make in the simplex. Let us state a version of Gromov’s link condition adapted to our setting. Theorem 3.5 (Gromov’s link condition [BH, Theorem II.5.2] ). Let K be a Mκ -simplicial complex of dimension at most 2, endowed with a cocompact simplicial isometric action. Then K is a locally CAT(κ) space if and only if the link of each vertex in K is CAT(1). Of course, for a graph being CAT(1) is equivalent to having no non-trivial simple loop of length less than 2π. Lemma 3.6 ([Bro, Lemma 2.29]). For any 0 < θ < π and any A, C with C > A > 0, there exists k < 0 and a locally CAT(k) Mk -simplicial annulus with one locally geodesic boundary component of length A, and one boundary component of length C which is locally geodesic everywhere except for one point where it subtends an angle greater than θ. Lemma 3.7. Let Z be an infinite virtually cyclic group. Any two cocompact isometric actions on R have the same kernel, and the quotient of Z by the kernel is isomorphic to either Z or the infinite dihedral group D∞ . Proof. Clearly both actions on R can be made into actions on 2-regular trees with a single edge orbit and no edge inversions; each such action gives us a decomposition of Z into a graph of finite groups, where the kernel of the action is the unique edge group, and the quotient is as claimed. Let G1 and G2 denote the graphs of groups, and K1 and K2 denote the respective edge groups. Suppose that one of the graphs, say G1 , has only one vertex. Then K1 is also equal to the vertex group, and we have K2 6 K1 , since any finite group acting on a tree has a fixed point. If G2 also has a single vertex than K1 6 K2 by the same argument and we are done. Otherwise Z/K1 ' Z is a quotient of Z/K2 ' D∞ , which is impossible. Now suppose that both G1 and G2 have two vertices each. Let Gv be a vertex group of G1 . Arguing as before we see that it fixes a point in the 12 SEBASTIAN HENSEL AND DAWID KIELAK e 2 , and so some index 2 subgroup of Gv fixes an edge. Thus action of Z on G K1 ∩ K2 is a subgroup of K1 of index at most two. If the index is two, then the image of K1 in Z/K2 ' D∞ is a normal subgroup of cardinality 2. But D∞ does not have such subgroups, and so K1 6 K2 . By symmetry K2 6 K1 and we are done.  Let us record the following standard fact. Lemma 3.8. Let Z be an infinite virtually cyclic group acting properly by semi-simple isometries on a complete CAT(0) space X. Then Z fixes an image of a geodesic in X (called an axis). For the purpose of the next proposition, let us introduce some notation. Definition 3.9. A CAT(−1) M−1 -simplicial complex of dimension at most 2 with finitely many isometry classes of simplices will be called useful. Proposition 3.10 (Blow-up with virtually cyclic edge groups). Suppose that κ ∈ {0, −1}. Let G be a finite graph of groups with virtually cyclic edge groups. For each vertex v suppose that the associated vertex group Gv acts properly cocompactly on a connected complete CAT(κ) simplicial complex Xv by semi-simple isometries. Suppose further that (A1) there exists an orientation of geometric edges of G such that the initial vertex of every edge e is useful: that is, it is a vertex u with Xu useful; and (A2) when Xu is useful and e1 , . . . , en are all the edges of G incident at u carrying an infinite edge group, then the axes preserved by g −1 Xei g with i ∈ {1, . . . , n} and gi 6∈ Xei can be taken to be simplicial and pairwise transverse. Then there exists a connected complete CAT(κ) space Y on which π1 (G) acts cocompactly, satisfying the following: e (1) there is a π1 (G)-equivariant map π : Y → G; e fixed by Gv , then π −1 (w) is Gv -equivariantly (2) if w is a vertex of G isometric to Xv . Proof. We will proceed exactly as in the proof of Proposition 3.1, with two exceptions: firstly, we will rescale the spaces Xv before we start the construction; secondly, we will need to deal with infinite virtually cyclic edge groups. Let us first explain how to deal with the infinite edge groups, and then it will become apparent how we need to rescale the useful spaces. e with infinite stabiliser Ge (note that this Let e be an oriented edge of G is a slight abuse of notation, as we usually reserve Ge to be an edge group e The group is virtually cyclic, and so, in G rather than a stabiliser in G). by Lemma 3.8, fixes an axis in each of the vertex spaces corresponding to the endpoints of e (it could of course be two axes in a single space, if e is a loop). The actions on these axes are equivariant by Lemma 3.7, and the only difference is the length of the quotient of the axis by Ge ; we will denote the NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 13 − + two lengths by λ+ e and λe , where λe is the amount by which Ge translates the axis corresponding to the terminus of e, and λ− e to the origin. We claim that we can rescale the spaces Xv and orient the geometric edges so that for any edge e with infinite stabiliser we have the initial vertex − of e useful and λ+ e 6 λe . Let us assume that we have already performed a suitable rescaling – we will come back to it at the end of the proof. Let u denote the initial (useful) endpoint of e; let w denote the other endpoint of e. We replace each 2-dimensional simplex in Xu by the comparison simplex of type M− 1 – note that, in particular, this does not affect the 2 metric on the 1-skeleton of Xu , and hence does not affect the constant λ− e. b Let Xu denote the resulting space. bu we have generated, in Brown’s terminology, an excess angle δ (deIn X bu the distance between pending on u), that is in the link of any vertex x in X any two points which were of distance at least π in the link of x in Xu is bu . By possibly decreasing δ, we may assume at least π + 2δ in the link in X that δ < π3 , and that the distance between any two distinct vertices in a link bu is at least δ (this is possible since there are only finitely of a vertex in X bu ). We still many different isometry types of simplices in Xu , and so in X bu simplicially and isometrically. have Gu acting on X + Suppose that λe = λ− e . Then we take Xe to be a flat strip [0, 1] × R on which Ge acts by translating the R factor so that the quotient is isometric to [0, 1] × R/λ+ e Z. − then we take X to be the universal cover of an annulus from If λ+ = 6 λ e e e − Lemma 3.6 with boundary curves of length λ+ e and λe , and θ = π − δ. The space Xe is a CAT(ke ) Mke -simplicial complex for some ke < 0. We glue the preimage (in Xe ) of each of the boundary curves to the corresponding axis of Ge , so that the gluing is an Ge -equivariant isometry. The gluing along the preimage of the shorter curve (or both curves if they are of equal length) proceeds along convex subspaces, and so if the vertex space was CAT(µ) with µ 6 0, then the glued-up space is still locally CAT(µ) along the axis of Ge . The situation is different at the useful end: here we glue in along a nonconvex curve. We claim that the resulting space is still locally CAT(ke ) along this geodesic. This follows from Gromov’s link condition (Theorem 3.5), and bu we introduced a single the observation that in the link of any vertex of X path (a shortcut) of length at least π − δ between vertices whose distance before the introduction of the shortcut was at least π + 2δ. A simple closed curve which traverses both endpoints of the shortcut therefore had length at least 2π + 4δ before introducing the shortcut, and thus still has length > 2π + δ afterwards. Thus there is still no non-trivial simple loop shorter than 2π. We now use the action of A = π1 (G) to equivariantly glue in copies of Xe for all edges in the orbit of e. We proceed in the same way for all the other (geometric) edges. 14 SEBASTIAN HENSEL AND DAWID KIELAK Now we need to look at the curvature. The useful spaces have all been altered to be M− 1 -simplicial complexes, and so they are now CAT(− 12 ). If 2 we had any CAT(0) vertex spaces, then they remain CAT(0). The universal covers Xe of annuli are CAT(ke ) with ke < 0; the infinite strips are CAT(0). The gluing into the non-useful spaces did not disturb the curvature. A single gluing into a useful space did not disturb the curvature either, but the situation is more complicated when we glue more than one space Xe into bu , since we could have introduced multiple shortcuts of length at a single X least π − δ into a link of a single vertex. If a curve traverses one (or no) shortcut, then the argument given above shows that it has length at least 2π. If it traverses more more than 2, then (as δ < π/3), it also has length > 2π. In the final case where it goes through exactly two, note that the endpoints of the shortcuts are all distinct by the transversality assumption (A2). Hence, by the choice of δ, any path connecting these endpoints has length > δ, and so the total path has length > 2(π − δ) + 2δ as well. We conclude that our space Y is complete and CAT(k), where k is the maximum of the values ke , κ and − 21 . When κ = 0 we have k = 0 and we are done. Otherwise, observing that we had only finitely many edges in G, we have k < 0, and so we can rescale Y to obtain a CAT(−1) space, as claimed. We still need to explain how to rescale the vertex spaces. We order the vertices of the graph of groups G in some way, obtaining a list v1 , . . . , vm . The space Xv1 we do not rescale. Up to reorienting the geometric edges − running from v1 to itself we see that the constants λ+ e and λe for such edges + + satisfy λe 6 λe . We look at the full subgraph Γ of G spanned by the vertices v1 , . . . , vi . Inductively, we assume that the spaces corresponding to vertices in Γ have already been rescaled as required. Now we attach vi+1 to Γ, together with all edges connecting vi+1 to itself or Γ. If Xvi+1 is not useful, then we have no edges of the latter type, and all edges connecting vi+1 to Γ are oriented towards vi+1 . Clearly we can rescale Xv to be sufficiently small so that the desired inequalities are satisfied (note that there are only finitely many edges to consider). If Xvi+1 is useful then we can reorient all edges connecting vi+1 to Γ so that they run away from vi+1 . Now we can make Xvi+1 sufficiently big to satisfy the desired inequalities. We also reorient the edges connecting vi+1 to itself in a suitable manner.  4. Relative Karrass–Pietrowski–Solitar theorem The following theorem is a generalisation of a theorem of Karrass–Pietrowski– Solitar [KPS], which lies behind the Nielsen realisation theorem for free groups. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 15 Theorem 4.1 (Relative Karrass–Pietrowski–Solitar theorem). Let φ : H → Out(A) be a monomorphism with a finite domain, and let A = A1 ∗ · · · ∗ An ∗ B be a decomposition preserved by H, with each Ai finitely generated, nontrivial, and B a (possibly trivial) finitely generated free group. Let A1 , . . . , Am be the minimal factors. Then the associated extension A of A by H is isomorphic to the fundamental group of a finite graph of groups with finite edge groups, with m distinguished vertices v1 , . . . , vm , such that the vertex group associated to vi is a conjugate of the extension Ai of Ai by StabH (i), and vertex groups associated to other vertices are finite. Proof. The proof goes along precisely the same lines as the original proof of Karrass–Pietrowski–Solitar [KPS], with the exception that we use Relative Stallings’ Theorem (Theorem 2.7) instead of the classical one. We will prove the result by an induction on a complexity (n, f ) where n is the number of factors Ai , and f is the rank of the free group B in the decomposition. We order the complexity lexicographically. The cases of complexity (0, f ) follow from the usual Nielsen realisation theorem for free groups (see Theorem 8.2). Thus, for the inductive step, we assume a complexity (m, f ) with m > 0. We begin by applying Theorem 2.7 to the finite extension A. We obtain a graph of groups P with one edge and a finite edge group, such that each Ai lies up to conjugation in a vertex group, and no non-trivial subgroup of any factor Ai fixes an edge. Let v be any vertex of Pe. The group Pv is a finite extension of A ∩ Pv by a subgroup Hv of H. Let us look at the structure of Pv ∩ A more closely. Consider the graph of groups associated to the product A1 ∗ . . . An ∗ B and apply Kurosh’s theorem [Ser, Theorem I.14] to the subgroup Pv ∩ A. We obtain that Pv ∩ A is a free product of groups of the form Pv ∩ xAi x−1 for some x ∈ A, and a free group B 0 . Let us suppose that the intersection Pv ∩ xAi x−1 is nontrivial for some i and x ∈ A. This implies that a non-trivial subgroup G of Ai fixes the vertex x−1 .v. We also know that Ai fixes some vertex vi in Pe by construction, and thus so does G. If x−1 .v 6= vi , this would imply that G fixes an edge, which is impossible. Hence vi = x−1 .v and in particular we have that xAi x−1 6 Pv . Now suppose that Pv ∩yAi y −1 is non-trivial for some other element y ∈ A. Then x−1 .v = vi = y −1 .v, and so xy −1 ∈ A ∩ Pv . This implies that the two free factors Pv ∩ xAi x−1 and Pv ∩ yAi y −1 of Pv ∩ A are conjugate inside the group, and so they must coincide. We consider the action of A on the tree P̃ , and conclude that A is equal to the fundamental group of the graph of groups P̃ //A. The discussion above shows that: 16 SEBASTIAN HENSEL AND DAWID KIELAK i) The stabilizer of a vertex v ∈ P̃ has the structure −1 0 Pv ∩ A = xi(v,1) Ai(v,1) x−1 i(v,1) ∗ · · · ∗ xi(v,k) Ai(v,k) xi(v,k) ∗ B where the indices i(v, k) are all distinct, and B 0 is some free group. ii) If a conjugate of Ai intersects some stabilizer of v non-trivially, then it stabilizes v. iii) For each i there is exactly one vertex v so that a conjugate of Ai appears as Ai(v,l) in the description above. iv) The edge groups in P̃ //A are trivial. Since the splitting which P defines is non-trivial, the index of Pv ∩ A in A is infinite, and thus A is not a subgroup of Pv for any v. Next, we aim to show that the complexity of each Pv ∩A is strictly smaller than that of A. To begin, note that the only way that this could fail is if there is some vertex w so that −1 0 Pw ∩ A = x1 A1 x−1 1 ∗ · · · ∗ x m Am x m ∗ B for B 0 a free group. Since all edge groups in P̃ //A are trivial, A is obtained from Pw ∩ A by a free product with a free group. Such an operation cannot decrease the rank of B 0 , and in fact increases it unless the free product is trivial. But in the latter case we would have Pw ∩A = A, which is impossible. We have thus shown that each Pv is an extension Pv ∩ A → Pv → Hv where Hv is a subgroup of H, the group Pv ∩ A decomposes in a way which is preserved by Hv , and its complexity is smaller than that of A. Therefore the group Pv satisfies the assumption of the inductive hypothesis. We now use Proposition 3.1 (together with the remark following it) to construct a new graph of groups Q, by blowing P up at u by the result of the theorem applied to Pu , with u varying over some chosen lifts of the vertices of P . By construction, Q is a finite graph of groups with finite edge groups, and the fundamental group of Q is indeed A. Also, Q inherits distinguished vertices from the graphs of groups we blew up with. Thus, Q is as required in the assertion of our theorem, with two possible exceptions. Firstly, it might have too many distinguished vertices. This would happen if for some i and j we have Ai and Aj both being subgroups of, say, Pv , which are conjugate in A but not in Pv . Let h ∈ A be an element such that hAi h−1 = Aj . Since both Ai and Aj fix only one vertex, and this vertex is v, we must have h ∈ Pv , and so Ai and Aj are conjugate inside Pv . Secondly, it could be that the finite extensions of Ai we obtain as vertex groups are not extensions by StabH (i). This would happen if StabH (i) is not a subgroup of Hv . Let us take h ∈ A in the preimage of StabH (i), such that hAi h−1 = Ai . Then in the action on Pe the element h takes a vertex fixed by Ai to another such; if these were different, then Ai would fix an NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 17 edge, which is impossible. Thus h fixes the same vertex as Ai . This finishes the proof.  5. Fixed points in the graph of relative free splittings Consider a free product decomposition A = A1 ∗ · · · ∗ An ∗ B with B a finitely generated free group. Handel and Mosher [HM] (see also the work of Horbez [Hor]) defined a graph of relative free splittings FS(A, {A1 , . . . , An }) associated to such a decomposition. Its vertices are finite non-trivial graphs of groups with trivial edge groups, and such that each Ai is contained in a conjugate of a vertex group; two such graphs of groups define the same vertex when the associated universal covers are Aequivariantly isometric. Two vertices are connected by an edge if and only if the graphs of groups admit a common refinement. In their article, Handel and Mosher prove that FS(A, {A1 , . . . , An }) is connected and Gromov hyperbolic [HM, Theorem 1.1]. Observe that the subgroup Out(A, {A1 , . . . , An }) of Out(A) consisting of those outer automorphisms of A which preserve the decomposition A = A1 ∗ · · · ∗ An ∗ B acts on this graph. We offer the following fixed point theorem for this action on FS(A, {A1 , . . . , An }). Corollary 5.1. Let H 6 Out(A, {A1 , . . . , An }) be a finite subgroup, and suppose that the factors Ai are finitely generated. Then H fixes a point in the free-splitting graph FS(A, {A1 , . . . , An }). Proof. Theorem 4.1 gives us an action of the extension A on a tree T ; in particular A acts on this tree, and this action satisfies the definition of a vertex in FS(A, {A1 , . . . , An }). Since the whole of A acts on T , every outer automorphism in H fixes this vertex.  6. Fixed points in the outer space of a free product Take any finitely generated group A, and consider its Grushko decomposition, that is a free splitting A = A1 ∗ · · · ∗ An ∗ B where B is a finitely generated free group, and each group Ai is finitely generated and freely indecomposible, that is it cannot act on a tree without a global fixed point (note that Z is not freely indecomposible in this sense). Grushko’s Theorem [Gru] tells us that such a decomposition is essentially unique; more precisely, if A = A01 ∗ · · · ∗ A0m ∗ B 0 18 SEBASTIAN HENSEL AND DAWID KIELAK is another such decomposition, then B ∼ = B 0 , m = n, and there is a permutation β of the set {1, . . . , n} such that Ai is conjugate to A0β(i) . In particular, this implies that the decomposition A = A1 ∗ · · · ∗ An ∗ B is preserved in our sense by every outer automorphism of A. In [GL] Guirardel and Levitt introduced P O, the (projectivised) outer space of a free product. It has a structure of a ‘simplicial complex with missing faces’ – it is homeomorphic to a union of open simplices in a metric realisation of a simplicial complex. In particular, each open simplex contains a barycentre; the barycentres are equivalence classes of pairs (G, ι), where: (1) G is a finite graph of groups with trivial edge groups; (2) edges of G are given length 1; (3) for every i ∈ {1, . . . , n}, there is a unique vertex vi in G such that the vertex group Gvi is conjugate to Ai ; (4) all other vertices have trivial vertex groups; (5) every leaf of G is one of the vertices {v1 , . . . , vn }; (6) ι : π1 (G) → A is an isomorphism. The equivalence relation is given by postcomposing ι with an inner automorphism of A, and by multiplying the lengths of all edges of G by a positive constant. We also consider two pairs G, ι and G0 , ι0 equivalent if there exists an isometry ψ : G → G0 such that ι = ι0 ◦ ψ. Because of the essential uniqueness of the Grushko decomposition, the group Out(A) acts on P O by postcomposing the marking ι. We offer the following result for this action. Corollary 6.1. Let A be a finitely generated group, and let H 6 Out(A) be a finite subgroup. Then H fixes a barycentre in P O. Proof. Theorem 4.1 gives us an action of the extension A on a tree T , and we may assume that this action is minimal; in particular A acts on this tree, and this action satisfies the definition of a vertex in P O (with all edge lengths equal to 1). Since the whole of A acts on T , every outer automorphism in H fixes this vertex.  Note that P O has been shown in [GL, Theorem 4.2, Corollary 4.4] to be contractible. 7. Relative Nielsen realisation In this section we use Theorem 4.1 to prove relative Nielsen Realisation for free products. To do this we need to formalise the notion of a marking of a space. Definition 7.1. We say that a path-connected topological space X with a e is marked by a group A if and only if it comes equipped universal covering X with an isomorphism between A and the group of deck transformations of e X. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 19 Remark 7.2. Given a space X marked by a group A, we obtain an isoe (where p denotes its morphism A ∼ = π1 (X, p) by choosing a basepoint pe ∈ X projection in X). Conversely, an isomorphism A ∼ = π1 (X, p) together with a choice of a lift e pe ∈ X of p determines the marking in the sense of the previous definition. Definition 7.3. Suppose that we are given an embedding π1 (X) ,→ π1 (Y ) of fundamental groups of two path-connected spaces X and Y , both marked. A map ι : X → Y is said to respect the markings via the map e ι if and only e e if e ι : X → Y is π1 (X)-equivariant (with respect to the given embedding π1 (X) ,→ π1 (Y )), and satisfies the commutative diagram e X  X e ι e /Y ι  /Y We say that ι respects the markings if and only if such an e ι exists. Suppose that we have a metric space X marked by a group A, and a group H acting on X. Of course such a setup yields the induced action H → Out(A), but in fact it does more: it gives us an extension 1→A→A→H→1 where A is the group of all lifts of elements of H to automorphisms of the e of X. universal covering X Definition 7.4. Suppose that we are given a group extension A→A→H We say that an action φ : H → Isom(X) of H on a metric space X realises the extension A if and only if X is marked by A, and the extension π1 (X) → G → H induced by φ fits into the commutative diagram A  ' π1 (X) /A  /H ' /G /H When A is centre-free, and we are given an embedding H 6 Out(A), we say that an action φ as before realises the action H → Out(A) if and only if it realises the corresponding extension. Now we are ready to state the relative Nielsen Realisation theorem for free products. 20 SEBASTIAN HENSEL AND DAWID KIELAK Theorem 7.5 (Relative Nielsen Realisation). Let φ : H → Out(A) be a homomorphism with a finite domain, and let A = A1 ∗ · · · ∗ An ∗ B be a decomposition preserved by H, with each Ai finitely generated, and B a (possibly trivial) finitely generated free group. Let A1 , . . . , Am be the minimal factors. Suppose that for each i ∈ {1, . . . , m} we are given a complete NPC space Xi marked by Ai , on which Stabi (H) acts in such a way that the associated extension of Ai by StabH (i) is isomorphic (as an extension) to the extension Ai coming from A. Then there exists a complete NPC space X realising the action φ, and such that for each i ∈ {1, . . . , m} we have a StabH (i)equivariant embedding ιi : Xi → X which preserves the marking. Moreover, the images of the spaces Xi are disjoint, and collapsing each Xi and its images under the action of H individually to a point yields a graph with fundamental group abstractly isomorphic to the free group B. As outlined in the introduction, the proof is very similar to the classical proof of Nielsen realisation, with our new relative Stallings’ and Karrass– Pietrowski–Solitar theorems in place of the classical ones. Proof. When φ is injective we first apply Theorem 4.1 to obtain a graph of e by groups G, and then use Proposition 3.1 and blow up each vertex of G f e the appropriate Xi ; we call the resulting space X. The space X is obtained e by taking the quotient of the action of A on X. If φ is not injective, then we consider the induced map H/ ker φ → Out(A) apply the previous paragraph, and declare H to act on the resulting space with ker φ in the kernel.  Remark 7.6. In the above theorem the hypothesis on the spaces Xi being complete and NPC can be replaced by the condition that they are semilocally simply connected, and any finite group acting on their universal covering fixes at least one point. Remark 7.7. On the other hand, when we strengthen the hypothesis and require the spaces Xi to be NPC cube complexes (with the actions of our finite groups preserving the combinatorial structure), then we may arrange for X to also be a cube complex. When constructing the blow ups, we may always take the fixed points of the finite groups to be midpoints of cubes, and then X is naturally a cube complex, when we take the cubical barycentric subdivisions of the complexes Xi instead of the original cube complexes Xi . Remark 7.8. In [HOP] Osajda, Przytycki and the first-named author develop a more topological approach to Nielsen realisation and the Karrass– Pietrowski–Solitar theorem. In that article, Nielsen realisation is shown first, using dismantlability of the sphere graph (or free splitting graph) of NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 21 a free group, and the Karrass–Pietrowski–Solitar theorem then follows as a consequence. The relative Nielsen realisation theorem with all free factors Ai being finitely generated free groups is a fairly quick consequence of the methods developed in [HOP] – however, the more general version proved here cannot at the current time be shown using the methods of [HOP]: to the authors knowledge no analogue of the sphere graph exhibits suitable properties. It would be an interesting problem to find a “splitting graph” for free products which has dismantling properties analogous to the ones shown in [HOP] to hold for arc, sphere and disk graphs. 8. Nielsen realisation for limit groups Definition 8.1. A group A is called fully residually free if and only if for any finite subset {a1 , . . . , an } ⊆ A r {1} there exists a free quotient q : A → F such that q(ai ) 6= 1 for each i. A finitely generated fully residually free group is called a limit group. Note that the definition immediately implies that limit groups are torsion free. The three most immediate classes of examples are free groups, free abelian groups, and surface groups. For each of these classes we have a Nielsen realisation results, and these will form a basis for an inductive argument. Theorem 8.2 ([Cul, Khr, Zim]). Let H be a finite subgroup of Out(Fn ), where Fn denotes the free group of rank n. There exists a finite graph X realising the given action H < Out(Fn ). Theorem 8.3. Let Zn → Zn → H be a finite extension of Zn . There exists a metric n-torus X realising this extension. Theorem 8.4 (Kerckhoff [Ker1, Ker2]). Let H be a finite subgroup of Out(π1 (Σ)) where Σ is a closed surface of genus at least 2. There exists a hyperbolic metric on Σ such that Σ endowed with this metric realises the given action H < Out(π1 (Σ)). We are going to use an inductive approach to limit groups; such an approach is possible since the class of limit groups coincides with the class of constructible limit groups (for this and other facts see [BF]). What is important for us is that this means that every limit groups has a well-defined level, which is a natural number. We do not need to recall the precise definition of the level; it will suffice to recall two facts: • the level of a limit group is equal to 0 if and only if the group is finitely generated and free; and 22 SEBASTIAN HENSEL AND DAWID KIELAK • a limit group A of level n either is a free product of two limit groups of level 6 n−1 or it admits a generalised abelian decomposition (which is a special kind of a graph of groups decomposition; see e.g. [BF] for details) and a proper epimorphism ρ : A → B to a limit group of level 6 n − 1, such that in particular every non-abelian, non-free and non-surface vertex group of the generalised abelian decomposition is mapped injectively by ρ. The crucial property of one-ended limit groups is that they admit JSJdecompositions invariant under automorphisms. Theorem 8.5 (Bumagin–Kharlampovich–Myasnikov [BKM, Theorem 3.13 and Lemma 3.16]). Let A be a one-ended limit group. Then there exists a finite graph of groups G with π1 (G) = A and the following additional properties. i) All vertex groups are finitely generated, and all edge groups are cyclic. ii) Every maximal abelian subgroup of A is conjugate to a vertex group of G. iii) Each vertex group is either a maximal abelian subgroup of A, a quadratically hanging subgroup (which implies that it is isomorphic to a finitely generated free group or a surface group) or a rigid subgroup. The latter two types are non-abelian. iv) Every edge in G connects a vertex carrying a maximal abelian subgroup to a vertex carrying a non-abelian group (qudratically hanging or rigid). e v) Any automorphism φ of A induces an A-equivariant isometry ψ of G such that the following diagram commutes A e / Isom(G) φ  A  cψ e / Isom(G) where cψ denotes conjugation by ψ. We will refer to the graph of groups G as the canonical JSJ decomposition. Note that for the naming of the various vertex groups we use the conventions of Bestvina–Feighn [BF]. Note also that the first description of a JSJ decomposition for limit groups very much like the above (without property (v)) can be found in the work of Sela [Sel]. The canonical JSJ decomposition has one additional property (see [BKM, Theorem 3.13(1)]) – it is universal, which in particular implies that given any graph of groups decomposition G0 of A, every rigid vertex group of the canonical JSJ decomposition is (up to conjugation) contained in a vertex group of G0 . Lemma 8.6. Let A be a one-ended limit group of level n, and let R be a rigid vertex group in the canonical JSJ decomposition G of A. Then R is a NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 23 surface group or a hyperbolic group isomorphic to a free product of finitely many limit groups of level less than n. Proof. Alibegović [Ali, Thm 3.3] showed that a limit group is hyperbolic if and only if its maximal abelian subgroups are cyclic. Let Z be a maximal abelian subgroup of R. There exists Z 0 , a maximal abelian subgroup of A, e fixes a vertex whose stabiliser which contains Z. But Z 0 , when acting on G, is maximal abelian. Thus Z also fixes this vertex, and also the (distinct) vertex corresponding to the nonabelian group R. Therefore Z fixes an edge e which implies that Z is cyclic. in G, The definition of level n tells us that either A is a non-trivial free product (which it cannot be, as it is one-ended), or it admits a graph of groups decomposition G0 and an epimorphism ρ : A → B to a limit group of level at most n − 1 such that ρ is injective on every non-abelian, non-free, nonsurface vertex group. If R is a surface group or a free group then we have proven the statement (note that A is not free, and hence n > 0). If R is not free and not a surface group, then the vertex group in G0 in which it lies (up to conjugation) is not free, not abelian, and not a surface group. Thus ρ maps R into B injectively, and so R is a finitely generated subgroup of a limit group of level at most n − 1. A result of Wilton [Wil, Lemma 4.7] now tells us that R is isomorphic to a free product of finitely many limit groups of level less than n.  We now need to discuss malnormality. Definition 8.7. Recall that a subgroup G 6 A is malnormal if and only if a−1 Ga ∩ G 6= {1} implies that a ∈ G for every a ∈ A. Following Sam Brown, we say that a family of subgroups G1 , . . . , Gn of A is malnormal if and only if for every a ∈ A we have that a−1 Gi a ∩ Gj 6= {1} implies that i = j and a ∈ Gi . We will use another property of limit groups and their canonical JSJ decompositions. Proposition 8.8 ([BKM, Theorem 3.1(3),(4)]). Let A be a limit group. Every non-trivial abelian subgroup of A lies in a unique maximal abelian subgroup, and every maximal abelian subgroup is malnormal. Corollary 8.9. Let Gv be a non-abelian vertex group in a canonical JSJ decomposition of a one-ended limit group A. Then the edge groups carried by edges incident at v form a malnormal family in Gv . Proof. Let Z1 and Z2 denote two edge groups carried by distinct edges, e and e0 say, incident at v. Without loss of generality we may assume that each of these groups is infinite cyclic. Suppose that there exists g ∈ Gv and a non-trivial z ∈ g −1 Z1 g ∩ Z2 . Each Zi lies in a unique maximal subgroup Mi of A. But then the abelian subgroup generated by z lies in both M1 and M2 , which forces M1 = M2 by uniqueness. Now g −1 M1 g ∩ M1 6= {1} 24 SEBASTIAN HENSEL AND DAWID KIELAK which implies that g ∈ M1 (since M1 is malnormal), and so g −1 Z1 g = Z1 , which in turn implies that z ∈ Z1 ∩ Z2 . The edges e and e0 form a loop in G, and so there is the corresponding element t in A = π1 (G). Observe that t commutes with z, and so the group ht, zi must lie in M1 . But this is a contradiction, as t does not fix any vertices e in G.  We are now going to use [Bro, Lemma 2.31]; we are however going to break the argument of this lemma in two parts. Lemma 8.10 (Brown). Let X be a connected M−1 -simplicial complex of dimension at most 2. Let A = π1 (X), and suppose that we are given a malnormal family {G1 , . . . , Gn } of infinite cyclic subgroups of A. Then, after possibly subdividing X, each group Gi fixes a (simplicial) axis ai in the universal cover of X, and the images in X of axes ai and aj for i 6= j are distinct. In the second part of [Bro, Lemma 2.31] we need to introduce an extra component, namely a simplicial action of a finite group H on X, which permutes the groups Gi up to conjugation. Lemma 8.11 (Brown). Let X be a locally CAT(−1) connected finite M−1 simplicial complex of dimension at most 2. Let A = π1 (X), and suppose that we are given a family {c1 , . . . , cn } of locally geodesic simplicial closed curves with images pairwise distinct. Suppose that we have a finite group H acting simplicially on X in a way preserving the images of the curves c1 , . . . , cn setwise. Then there exists a locally CAT(k) 2-dimensional finite simplicial complex X 0 of curvature k, with k < 0, with a transverse family of locally geodesic simplicial closed curves {c01 , . . . , c0n }, such that X 0 is Hequivariantly homotopic to X, and the homotopy takes c0i to ci for each i. Sketch of proof. The proof of [Bro, Lemma 2.31] goes through verbatim, with a slight modification; to explain the modification let us first briefly recount Brown’s proof. We start by finding two local geodesics, say c1 and c2 , which contain segments whose union is a tripod – one arm of the tripod is shared by both segments. We glue in a fin, that is a 2-dimensional Mk -simplex, so that one side of the simplex is glued to the shared segment of the tripod, and another side is glued to another arm (the intersection of the two sides goes to the central vertex of the tripod). This way one of the curves, say c1 , is no longer locally geodesic, and we replace it by a locally geodesic curve identical to c1 except that instead of travelling along two sides of the fin, it goes along the third side. The problem is that after the gluing of a fin our space will usually not be locally CAT(−1) (the third side of the fin introduces a shortcut in the link of the central vertex of the tripod). To deal with this, we first replace simplices in X by the corresponding Mk -simplices, and this creates an excess angle δ NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 25 (compare also the proof of Proposition 3.10). Then gluing in the fin does not affect the property of being locally CAT(k). We glue such fins multiple times, until all local geodesics intersect transversely; after each gluing we perform a replacement of simplices to generate the excess angle. Now let us describe what changes in our argument. When gluing in a fin, we need to do it H-equivariantly in the following sense: a fin is glued along two consecutive edges, say (e, e0 ), and H acts on pairs of consecutive edges. We thus glue in one fin for each coset of the stabiliser of (e, e0 ) in H. This way, when we introduce shortcuts in a link of a vertex, no two points are joined by more than one shortcut. Since we are gluing multiple fins simultaneously, we need to make the angle π − δ sufficiently close to π.  Note that when we say that the family {c01 , . . . , c0n } is transverse, we mean that each curve c0i intersects transversely with the other curves and itself. Theorem 8.12. Let A be a limit group, and let A→A→H be an extension of A by a finite group H. Then there exists a complete compact locally CAT(κ) space X realising the extension A, where κ = −1 when A is hyperbolic, and κ = 0 otherwise. When κ = −1, the space X is of dimension at most 2. Proof. The proof will be an induction on the level of A. Before we start, we will show that assuming the result holds for one-ended limit groups of level n, it holds for all limit groups of level n. Consider a limit group A which is not one-ended. We apply the classical version of Stallings theorem to A, and split it over a finite group. We will in fact apply the theorem multiple times, so that we obtain a finite graph of groups G0 with finite edge groups, with all vertex groups finitely generated and one-ended, and π1 (G0 ) = A; the fact that we only have to apply the theorem finitely many times follows from finite presentability of A (see [BKM, Theorem 3.1(5)]) and Dunwoody’s accessibility [Dun2]. The one-ended vertex groups are themselves finite extensions of limit groups, and so for each of them we have a connected metric space to act on by assumption. We now use Proposition 3.1 – the assumption on finite groups fixing points is satisfied since the vertex spaces are complete and CAT(0). We will now assume that A, and so A, is one-ended. As mentioned before, the proof is an induction on the level n of A. If n = 0 then A is a fintely generated free group and we are done by Theorem 8.2. Also, if A is a surface group or a finitely generated free-abelian group, then we are also done by Theorems 8.3 and 8.4. 26 SEBASTIAN HENSEL AND DAWID KIELAK We apply Theorem 8.5 and obtain a connected graph of groups G with π1 (G) = A (the canonical JSJ decomposition) for which we can extend the natural e to an action of A. Taking the quotient by A we obtain a action of A on G new graph of groups Γ with π1 (Γ) = A The edge groups of Γ are virtually cyclic, and the vertex groups are finite extensions of finitely generated free or free-abelian groups, or surface groups, or of other rigid vertex groups, which are hyperbolic and isomorphic to free products of finitely many limit groups of smaller level (in view of Lemma 8.6). Using Theorems 8.2 to 8.4 and the inductive hypothesis, for each vertex group Γv we construct a compact complete NPC space Xv marked by Av = A ∩ Γv , on which Γv /Av acts in such a way that the induced extension is ev is CAT(0). When Gv is hyperbolic, it is isomorphic to Γv . The space X actually CAT(−1) and at most 2-dimensional. In particular, this is the case for all vertices if A is hyperbolic (and therefore so are all vertex groups, being limit groups whose maximal Abelian subgroups are cyclic). eu is (at most) 2–dimensional and CAT(−1), we can easily trianWhen X gulate it Γu -equivariantly using convex simplices; we can then replace each 2-simplex by the corresponding 2-simplex of type M−1 , and the resulting eu and Xu have the structure of (at most) space is still CAT(−1). Thus, X 2-dimensional M−1 -simplicial complexes, the latter being finite. Moreover, we can triangulate it in such a way that each axis fixed by an infinite cyclic group carried by an edge incident at u is also simplicial. Observe that Γv /Av permutes these axes, and so each of the corresponding edge groups in Γ preserves such an axis as well. Now we apply Lemma 8.10 and conclude that distinct axes do not coincide. Thus we may use Lemma 8.11, and replace Xu by a new CAT(−1) M−1 -simplicial complex (after rescaling) of dimension at most 2, which has only finitely many isometry classes of simplices, and in which our axes intersect each other and themselves transversely. Observing that each infinite edge group preserves an axis in each of the relevant vertex spaces by Lemma 3.8, we apply Proposition 3.10, and take the resulting space to be X. The result is NPC in any case, and if A was hyperbolic (and therefore all vertex spaces were CAT(−1)), it is locally CAT(−1) as claimed.  References [Ali] [AB] Emina Alibegović. A combination theorem for relatively hyperbolic groups. Bull. London Math. Soc. 37(2005), 459–466. Emina Alibegović and Mladen Bestvina. Limit groups are CAT(0). J. London Math. Soc. (2) 74(2006), 259–272. NIELSEN REALISATION BY GLUING: LIMIT GROUPS AND FREE PRODUCTS 27 [BF] [BH] [Bro] [BKM] [Cul] [CV] [Dun1] [Dun2] [Gru] [GL] [HM] [HK] [HOP] [Hor] [KPS] [Ker1] [Ker2] [Khr] [Krö] [Sel] [Ser] [Sta1] [Sta2] Mladen Bestvina and Mark Feighn. Notes on Sela’s work: limit groups and Makanin-Razborov diagrams. In Geometric and cohomological methods in group theory, volume 358 of London Math. Soc. Lecture Note Ser., pages 1–29. Cambridge Univ. Press, Cambridge, 2009. Martin R. Bridson and André Haefliger. Metric spaces of non-positive curvature, volume 319 of Grundlehren der Mathematischen Wissenschaften [Fundamental Principles of Mathematical Sciences]. Springer-Verlag, Berlin, 1999. Samuel Brown. A gluing theorem for negatively curved complexes. J. Lond. Math. Soc. (2) 93(2016), 741–762. Inna Bumagin, Olga Kharlampovich, and Alexei Miasnikov. The isomorphism problem for finitely generated fully residually free groups. J. Pure Appl. Algebra 208(2007), 961–977. Marc Culler. Finite groups of outer automorphisms of a free group. In Contributions to group theory, volume 33 of Contemp. Math., pages 197–207. Amer. Math. Soc., Providence, RI, 1984. Marc Culler and Karen Vogtmann. Moduli of graphs and automorphisms of free groups. Invent. Math. 84(1986), 91–119. M. J. Dunwoody. Cutting up graphs. Combinatorica 2(1982), 15–23. M. J. Dunwoody. The accessibility of finitely presented groups. Invent. Math. 81(1985), 449–457. I. Gruschko. Über die Basen eines freien Produktes von Gruppen. Rec. Math. [Mat. Sbornik] N.S. 8 (50)(1940), 169–182. Vincent Guirardel and Gilbert Levitt. The outer space of a free product. Proc. Lond. Math. Soc. (3) 94(2007), 695–714. Michael Handel and Lee Mosher. Relative free splitting and free factor complexes I: Hyperbolicity. arXiv:1407.3508. S. Hensel and D. Kielak. Nielsen realisation for untwisted right-angled Artin groups. arXiv:1410.1618. Sebastian Hensel, Damian Osajda, and Piotr Przytycki. Realisation and dismantlability. Geom. Topol. 18(2014), 2079–2126. Camille Horbez. The boundary of the outer space of a free product. arXiv:1408.0543. A. Karrass, A. Pietrowski, and D. Solitar. Finite and infinite cyclic extensions of free groups. J. Austral. Math. Soc. 16(1973), 458–466. Collection of articles dedicated to the memory of Hanna Neumann, IV. Steven P. Kerckhoff. The Nielsen realization problem. Bull. Amer. Math. Soc. (N.S.) 2(1980), 452–454. Steven P. Kerckhoff. The Nielsen realization problem. Ann. of Math. (2) 117(1983), 235–265. D. G. Khramtsov. Finite groups of automorphisms of free groups. Mat. Zametki 38(1985), 386–392, 476. Bernhard Krön. Cutting up graphs revisited—a short proof of Stallings’ structure theorem. Groups Complex. Cryptol. 2(2010), 213–221. Zlil Sela. Diophantine geometry over groups I: Makanin-Razborov diagrams. Publications Mathématiques de l’Institut des Hautes Études Scientifiques 93(Sep 2001), 31–106. Jean-Pierre Serre. Trees. Springer Monographs in Mathematics. Springer-Verlag, Berlin, 2003. Translated from the French original by John Stillwell, Corrected 2nd printing of the 1980 English translation. John R. Stallings. On Torsion-Free Groups with Infinitely Many Ends. Annals of Mathematics Second Series, 88(September 1968), 312–334. John R. Stallings. Group theory and three-dimensional manifolds. Yale University Press, New Haven,, 1971. 28 [Wil] [Zim] SEBASTIAN HENSEL AND DAWID KIELAK Henry Wilton. Solutions to Bestvina & Feighn’s exercises on limit groups. In Geometric and cohomological methods in group theory, volume 358 of London Math. Soc. Lecture Note Ser., pages 30–62. Cambridge Univ. Press, Cambridge, 2009. Bruno Zimmermann. Über Homöomorphismen n-dimensionaler Henkelkörper und endliche Erweiterungen von Schottky-Gruppen. Comment. Math. Helv. 56(1981), 474–486. Sebastian Hensel Mathematisches Institut Universität Bonn Endenicher Allee 60 D-53115 Bonn Germany [email protected] Dawid Kielak Fakultät für Mathematik Universität Bielefeld Postfach 100131 D-33501 Bielefeld Germany [email protected]
4math.GR
Control refinement for discrete-time descriptor systems: a behavioural approach via simulation relations F. Chen ∗ , S. Haesaert ∗ , A. Abate ∗∗ , and S. Weiland ∗ ∗ arXiv:1704.01672v1 [cs.SY] 6 Apr 2017 Department of Electrical Engineering Eindhoven University of Technology, Eindhoven, The Netherlands ∗∗ Department of Computer Science University of Oxford, Oxford, United Kingdom Abstract: The analysis of industrial processes, modelled as descriptor systems, is often computationally hard due to the presence of both algebraic couplings and difference equations of high order. In this paper, we introduce a control refinement notion for these descriptor systems that enables analysis and control design over related reduced-order systems. Utilising the behavioural framework, we extend upon the standard hierarchical control refinement for ordinary systems and allow for algebraic couplings inherent to descriptor systems. Keywords: Descriptor systems, simulation relations, control refinement, behavioural theory. 1. INTRODUCTION Complex industrial processes generally contain algebraic couplings in addition to differential (or difference) equations of high order. These systems, referred to as descriptor systems (Kunkel and Mehrmann, 2006; Dai, 1989), are commonly used in the modelling of mechanical systems. The presence of algebraic equations, or couplings, together with large state dimensions renders numerical simulation and controller design challenging. Instead model reduction methods (Antoulas, 2005) can be applied to replace the systems with reduced order ones. Even though most methods have been developed for systems with only ordinary difference equations, recent research also targets descriptor systems (Cao et al., 2015). In this paper, we newly target the use of descriptor systems of reduced order for the verifiable design of controllers. A rich body of literature on verification and formal controller synthesis exists for systems solely composed of difference equations. This includes the algorithmic design of certifiable (hybrid) controllers and the verification of pre-specified requirements (Tabuada, 2009; Kloetzer and Belta, 2008). Usually, these methods first reduce the original, concrete systems to abstract systems with finite or smaller dimensional state spaces over which the verification or controller synthesis can be run. A such controller obtained for the abstract system can be refined over the concrete system leveraging the existence of a similarity relation, e.g., an (approximate) simulation relation, between the two systems (Tabuada, 2009; Girard and Pappas, 2011). For the application of these relations in control problems, a hierarchical control framework is presented by (Girard and Pappas, 2009). Currently, the control synthesis over descriptor systems cannot be dealt with in this fashion due to the presence of algebraic equations. The presence of similarity relations between descriptor systems has also been a topic under investigation in (Megawati and Van der Schaft, 2015). This work on similarity relations deals with continuous-time descriptor systems that are unconstrained and non-deterministic, and focuses on the conditions for bisimilarity and on the construction of similarity relations. Instead in this work, we specifically consider the control refinement problem for discrete-time descriptor systems via simulation relations within a behavioural framework, such that properties verified over the future behaviour of the abstract system are also verified over the concrete controlled system. Within the behavioural theory (Willems and Polderman, 2013), a formal distinction is made between a system (its behaviour) and its representations, enabling us to investigate descriptor systems and refinement control problems without having to directly deal with their inherent anticausality. In the next section, we define the notion of dynamical systems and control within a behavioural framework and use it to formalise the control refinement problem. Subsequently, Section 3 is dedicated to the exact control refinement for descriptor systems and contains the main results of the paper. The last section closes with the conclusions. 2. THE BEHAVIOURAL FRAMEWORK 2.1 Discrete-time descriptor systems As introduced by (Willems and Polderman, 2013), we define dynamical systems as follows. Definition 1. A dynamical system Σ is defined as a triple Σ = (T, W, B) with the time axis T, the signal space W, and the behaviour B ⊂ WT . ✷ In this definition, WT denotes the collection of all timedependent functions w : T → W. The set of trajectories or time-dependent functions given by B represents the trajectories that are compatible with the system. This set is referred to as the behaviour of the system (Willems and Polderman, 2013). Generally, the representation of the behaviour of a dynamical system by equations, such as a set of ordinary differential equations, state space equations and transfer functions, is non-unique. Hence we distinguish a dynamical system (its behaviour) from the mathematical equations used to represent its governing laws. We consider dynamical systems evolving over discrete-time (T := N = {0, 1, 2, . . .}) that can be represented by a combination of linear difference and algebraic equations. The dynamics of such a linear discrete-time descriptor system (DS) are defined by the tuple (E, A, B, C) as Ex(t + 1) = Ax(t) + Bu(t), (1) y(t) = Cx(t), with the state x(t) ∈ X = Rn , the input u(t) ∈ U = Rp , and the output y(t) ∈ Y = Rk and t ∈ N. Further, E, A ∈ Rn×n , B ∈ Rn×p and C ∈ Rk×n are constant matrices and we presume that rank(B) = p and rank(C) = k. We say that a trajectory w = (u, x, y), with w : N → (U × X × Y), satisfies (1) if for all t ∈ N the equations in (1) evaluated at u(t), x(t), x(t + 1), y(t) hold. Then the collection of all trajectories w defines the full behaviour, or equivalently the input-state-output behaviour as Bi/s/o := {(u, x, y) ∈ (U × X × Y)N | (1) is satisfied}. (2) Σ := (T, W, B) = (N, U × X × Y, Binit i/s/o ) with • the time axis T := N = {0, 1, 2, . . .}, • the full signal space W := U × X × Y, and • the initialised behaviour 1 N Binit i/s/o = {w ∈ W |w = (u, x, y) s.t. (1) and s.t. x(0) = x0 ∈ X0 }. 2.2 Control of descriptor systems Controller synthesis amounts to synthesising a system Σc , called a controller, which, after interconnection with Σ, restricts the behaviour B of Σ to desirable (or controlled) trajectories. Thus, in the behavioural framework, control is defined through interconnections (or via variable sharing as specified next), rather than based on the causal transmission of signals or information, as in classical system theory. Let Σ1 = (T, C1 ×W, B1 ) and Σ2 = (T, C2 ×W, B2 ) be two dynamical systems. Then, as depicted in Fig. 1a and defined in (Willems and Polderman, 2013), the interconnection of Σ1 and Σ2 over W, denoted by Σ = Σ1 ×w Σ2 with the shared variable w ∈ W, yields the dynamical system Σ = (T, C1 × C2 × W, B) with B = {(c1 , c2 , w) : T → C1 × C2 × W | (c1 , w) ∈ B1 , (c2 , w) ∈ B2 }. The variable x is considered as a latent variable, therefore the manifest, or equivalently the input-output behaviour associated with (1) is defined by Bi/o:= {(u, y)|∃x ∈ XN s.t. (u, x, y) ∈ Bi/s/o }. If E is non-singular, we refer to the corresponding dynamical system as a non-singular DS. In that case, we can transform (1) into standard state space equations, as x(t + 1) = Ãx(t) + B̃u(t), y(t) = Cx(t), with à = E −1 A, B̃ = E −1 (3) B. Further Bi/s/o as in (2) is {(u, x, y) ∈ (U × X × Y)N | (u, x, y) s.t. (3) holds}. Similarly, if E is non-singular, Bi/o can be defined by (3). The tuple with dynamics (1) defines a dynamical system Σ evolving over the combined signal space W = U × X × Y with behaviour B := Bi/s/o given in (2). Similarly, for W restricted to input-output space, the tuple (N, U×Y, Bi/o ) defines the manifest or induced dynamical system. We are specifically interested in the behaviour initialised at t = 0 with a given set of initial states X0 ⊂ X. For this, we say that a trajectory w : N → (U × X × Y) is initialised with X0 if (1) holds and x(0) = x0 ∈ X0 . Such a trajectory, initialised with x0 ∈ X0 , is also called the continuation of x0 . We refer to the collection of initialised trajectories related to X0 as the initialised behaviour Binit i/s/o . This allows us to formalise our definition of the descriptor system evolving over N. Definition 2. (Discrete-time descriptor systems (DS)). A (discrete-time) descriptor system is defined as a dynamical system Σ initialised with X0 , whose behaviour can be represented by the combination of algebraic equations and difference equations given in (1), that is (4) c1 c2 w Σ1 Σ2 (a) The interconnected system Σ obtained via the shared variables w in W between dynamical systems Σ1 and Σ2 with signal spaces C1 × W and C2 × W. BΣ BΣ×Σc BΣ c (b) The controlled behaviour BΣ×Σc = BΣ ∩ BΣc is given as the intersection of the behaviours of the dynamical system Σ and its controller Σc . Fig. 1. The left figure (a) portrays the general interconnection of two dynamical systems. In figure (b), the more specific case of behavioural intersection for a system and its controller is depicted. Observe that w ∈ WT contains the signals shared by both Σ1 and Σ2 , while c1 ∈ CT1 only belongs to Σ1 and c2 ∈ CT2 only belongs to Σ2 . So, in the interconnected system, the shared variable w satisfies the laws of both B1 and B2 . Note that it is always possible to trivially extend the signal spaces of Σ1 and Σ2 (and the associated behaviour) such that a full interconnection structure is obtained, that is, such that both C1 and C2 are empty and the behaviour of the interconnected system is B = B1 ∩ B2 . Hence, a full interconnection of Σ = (T, W, BΣ ) and Σc = (T, W, BΣc ) is simply Σ ×w Σc = (T, W, BΣ ∩ BΣc ), with the intersection of the behaviours, denoted by BΣ×Σc , as portrayed in Fig. 1b. That is, interconnection and intersection are equivalent in full interconnections. Further, we define a well-posed controller Σc for Σ as follows. Definition 3. Consider a dynamical system Σ = (T, W, B), with initialised behaviour as defined in (4). We say that a system Σc = (T, W, Bc ) is a well-posed controller for Σ if the following conditions are satisfied: 1 In the sequel the indexes init and i/s/o will be dropped. (1) BΣ×Σc := BΣ ∩ BΣc 6= {∅}; (2) For every initial state x0 ∈ X0 , there exists a unique continuation in BΣ×Σc . Denote with C(Σ) the collection of all well-posed controllers for Σ. We want a controller that accepts any initial state of the system. This is formalised in the second condition by requiring that for any initial state of Σ, there exists a unique continuation in BΣ×Σc . We elucidate the properties of a well-posed linear controller as follows. Example 1. For a system Σ as in (1), consider a controller Σc , which is a DS, and has dynamics given as Ec x(t + 1) = Ac x(t) + Bc u(t), (5) with Ec , Ac ∈ Rnc ×n and Bc ∈ Rnc ×p . Suppose that the controller shares the variables u and x with the system Σ. That is, w = (u, x). The interconnected system Σ ×w Σc yields the state evolutions of the combined system as       B A E u(t), (6) x(t) + x(t + 1) = Bc Ac Ec and can be rewritten     to A E −B x(t + 1) = x(t). Ac Ec −Bc u(t) (7) If for any x(t) ∈ X, there exists a pair (x(t + 1), u(t)) such that (7) holds, then this implies that for any initial state x0 ∈ X0 of Σ there exists a continuation in the controlled behaviour. In addition, if the pair (x(t + 1), u(t)) is unique for any x(t) ∈ X, then this continuation is unique and we say that Σc ∈ C(Σ). This existence and uniqueness of the pairs (x(t+ 1), u(t)) depends on the solutions of the matrix equality (7). We use the classical results on the solutions of matrix equalities (cf. (Abadir and Magnus, 2005)) to conclude that the first well-posedness condition is satisfied if and only if     E B E B A rank = rank . (8) Ec Bc Ec Bc Ac If in addition, rank  E B A Ec Bc Ac  = n + p, (9) then the second condition is also satisfied and Σc ∈ C(Σ). Of interest is the design of well-posed controllers subject to specifications over the future output behaviour of the controlled system. We thus consider specifications defined over the output space. In order to analyse the output behaviour, we introduce a projection map. For B ⊂ (W1 × W2 )T we denote with ΠW2 a projection given as ΠW2 (B) := {w2 ∈ WT2 |∃w1 ∈ WT1 (E, A, B, C) as in (1) and initialised with X0 . A well-posed controller for Σ is referred to Σc ∈ C(Σ). The controlled concrete system is the interconnected system Σ×w Σc with the shared variables w = (u, x). Now, we consider a simpler DS Σa , related to the concrete DS Σ, with dynamics given as (Ea , Aa , Ba , Ca ) and initialised with Xa0 . We assume that the synthesis of a wellposed controller Σca for Σa is substantially easier than for Σ. We refer to this simpler system Σa as the abstract DS, and we note that its signals take values ua (t), xa (t), ya (t) with xa (t) ∈ Xa = Rm , ua (t) ∈ Ua = Rq , ya (t) ∈ Ya = Y = Rk and t ∈ N. With respect to the concrete system, the abstract DS is generally a reduced-order system. The controlled abstract system Σa ×wa Σca is the interconnected system with the shared variables wa = (ua , xa ). If we assume that we can compute a well-posed controller for the abstract system, then the control synthesis problem reduces to a control refinement problem. Definition 4. (Exact control refinement). Let Σa and Σ be the abstract and concrete DS, respectively. We say that controller Σc ∈ C(Σ) refines the controller Σca ∈ C(Σa ) if ΠY (BΣ×Σc ) ⊆ ΠY (BΣa ×Σca ). Then we formalise the exact control refinement problem. Problem 1. Let Σa and Σ be the abstract and concrete DS, respectively. For any Σca ∈ C(Σa ), refine Σca to Σc , s.t. Σc ∈ C(Σ) and ΠY (BΣ×Σc ) ⊆ ΠY (BΣa ×Σca ). In the next section, we will show that the existence of a solution to this problem hinges on certain conditions involving similarity relations between the concrete and abstract DS. For this, we will first introduce simulation relations to formally characterise this similarity. 3. EXACT CONTROL REFINEMENT 3.1 Similarity relations between DS We give the notion of simulation relation as defined in (Tabuada, 2009) for transition systems and applied to pairs of DS Σ1 and Σ2 that share the same output space Y1 = Y2 = Y. Definition 5. Let Σ1 and Σ2 be two DS with respective dynamics (E1 , A1 , B1 , C1 ) and (E2 , A2 , B2 , C2 ) over state spaces X1 and X2 . A relation R ⊆ X1 × X2 is called a simulation relation from Σ1 to Σ2 , if ∀(x1 , x2 ) ∈ R, (1) for all (u1 , x+ 1 ) ∈ U1 × X1 subject to E1 x+ 1 = A1 x1 + B1 u1 there exists (u2 , x+ 2 ) ∈ U2 × X2 subject to s.t. (w1 , w2 ) ∈ B}. We focus here on finding a controller Σc for a given dynamical system Σ such that the output behaviour ΠY (BΣ×Σc ) of the interconnected system satisfies some specifications. 2.3 Exact control refinement & problem statement Let us refer to the original DS that represents the real physical system as the concrete DS. It is for this system that we would like to develop a well-posed controller. Recall that the DS is a dynamical system Σ with dynamics such that E2 x+ 2 = A2 x2 + + (x1 , x2 ) ∈ R, and + B2 u 2 (2) we have C1 x1 = C2 x2 . We say that Σ1 is simulated by Σ2 , denoted by Σ1  Σ2 , if there exists a simulation relation R from Σ1 to Σ2 and if in addition ∀x10 ∈ X10 , ∃x20 ∈ X20 such that (x10 , x20 ) ∈ R. We call R ⊆ X1 × X2 a bisimulation relation between Σ1 and Σ2 , if R is a simulation relation from Σ1 to Σ2 and its inverse R−1 ⊆ X2 × X1 is a simulation relation from Σ2 to Σ1 . We say that Σ1 and Σ2 are bisimilar, denoted by Σ1 ∼ = Σ2 , if Σ1  Σ2 w.r.t. R and Σ2  Σ1 w.r.t. R−1 . Simulation relations as defined above are transitive. Let R12 and R23 be simulation relations respectively, from Σ1 to Σ2 and from Σ2 to Σ3 . Then a simulation relation from Σ1 to Σ3 is given as a composition of R12 and R23 , namely R12 ◦R23 = {(x1 , x3 ) | ∃x2 : (x1 , x2 ) ∈ R12 ∧(x2 , x3 ) ∈ R23 }. We also have that Σ1  Σ2 and Σ2  Σ3 implies Σ1  Σ3 and, in addition, Σ1 ∼ = Σ3 . = Σ3 implies Σ1 ∼ = Σ2 and Σ2 ∼ Simulation relations have also implications on the properties of the output behaviours of the two systems. More precisely, if a system is simulated by another system then this implies output behaviour inclusion. This follows from Proposition 4.9 in (Tabuada, 2009) and is formalised next. Proposition 6. Let Σ1 and Σ2 be two DS with simulation relations as defined in Definition 5. Then, Σ1  Σ2 =⇒ ΠY (BΣ1 ) ⊆ ΠY (BΣ2 ), Σ1 ∼ = Σ2 =⇒ ΠY (BΣ1 ) = ΠY (BΣ2 ). Simulation relations can also be used for the controller design for deterministic systems such as nonsingular DS (Tabuada, 2009; Fainekos et al., 2007; Girard and Pappas, 2009). This will be used in the next subsection, where we consider the exact control refinement for non-singular DS. After that, we introduce a transformation of a singular DS to an auxiliary nonsingular DS representation, referred to as a driving variable (DV) system. The exact control refinement problem is then solved based on the introduced notions. 3.2 Control refinement for non-singular DS Let us consider the simple case where the concrete and abstract systems of interest are given with non-singular dynamics. For these systems, the existence of a simulation relation also implies the existence of an interface function (Girard and Pappas, 2009), which is formulated as follows. Definition 7. (Interface). Let Σ1 and Σ2 be two nonsingular DS defined over the same output space Y with a simulation relation R from Σ1 to Σ2 . A mapping F : U1 × X1 × X2 7→ U2 is an interface related to R, if ∀(x1 , x2 ) ∈ R and for all u1 ∈ U1 , u2 := F (u1 , x1 , x2 ) ∈ U2 is such that + (x+ 1 , x2 ) ∈ R with + x+ 1 = A1 x1 + B1 u1 and x2 = A2 x2 + B2 u2 . It follows from Definition 5 that there exists at least one interface related to R if two deterministic, or non-singular systems are in a simulation relation. As such we can solve the exact refinement problem as follows. Theorem 8. Let Σ1 and Σ2 be two non-singular DS defined over the same output space Y with dynamics (I, A1 , B1 , C1 ) and (I, A2 , B2 , C2 ), which are initialised with X10 and X20 , respectively. If there exists a relation R ⊆ X1 × X2 such that (1) R is a simulation relation from Σ1 to Σ2 , and (2) ∀x20 ∈ X20 , ∃x10 ∈ X10 s.t. (x10 , x20 ) ∈ R, then for any controller Σc1 ∈ C(Σ1 ), there exists a controller Σc2 ∈ C(Σ2 ) that is an exact control refinement for Σc1 and thus achieves with ΠY (BΣ2 ×Σc2 ) ⊆ ΠY (BΣ1 ×Σc1 ). Proof. Since R is a simulation relation from Σ1 to Σ2 , there exists an interface function F : U1 × X1 × X2 → U2 as given in Definition 7, cf (Tabuada, 2009; Girard and Pappas, 2009). Additionally, due to (2) there exists a map, F0 : X20 → X10 such that for all x20 ∈ X20 it holds that (F0 (x20 ), x20 ) ∈ R. Next, we construct the controller Σc2 that achieves exact control refinement for Σc1 as Σc2 := (Σ1 ×w1 Σc1 ) ×w1 ΣF , where w1 = (u1 , x1 ) and where ΣF := (N, W, BF ) is a dynamical system taking values in the combined signal space with BF := {(x1 , u1 , x2 , u2 ) ∈ W|x10 = F0 (x20 ) and u2 = F (x1 , u1 , x2 )}. The dynamical system Σc2 is a well-posed controller for Σ2 with Σ2 ×w2 Σc2 sharing w2 = (u2 , x2 ). Denote with BΣ2 ×Σc2 the behaviour of the controlled system, then due to the construction of ΣF it follows that BΣ2 ×Σc2 is nonempty and ∀x20 ∈ X20 , ∃x10 ∈ X10 such that (x10 , x20 ) has a unique continuation in BΣ2 ×Σc2 . Furthermore it holds that ΠY (BΣ2 ×Σc2 ) ⊆ ΠY (BΣ1 ×Σc1 ). ✷ The design of the controller Σc2 that achieves exact control refinement for Σc1 is similar to that in (Tabuada, 2009), which also holds in the behavioural framework. 3.3 Driving variable systems Since it is difficult to control and analyse a DS directly, we develop a transformation to a system representation that is in non-singular DS form and is driven by an auxiliary input. We refer to this non-singular DS as the driving variable (DV) system (Weiland, 1991). We investigate whether the DS and the obtained DV system are bisimilar and behaviourally equivalent. Let us first introduce with a simple example the apparent non-determinism or anticausality in the DS. Later-on, we show the connections between a DS and its related DV system. Example 2. Consider the DS with dynamics (E, A, B, C) defined as h1i h 0 iT h1 0 0i h −1 0 0 i E = 0 0 1 , A = 0 1 0 , B = 1 , C = 0.2 , (10) 0 0 0 1 0 0 1 0.5 T and x(t) = [x1 (t) x2 (t) x3 (t)] . In this case, the input u(t) = −x3 (t) is constrained by the third state component. Now the state trajectories of (10) can be found as follows: • for a given input sequence u : N → U, we have x2 (t) = −u(t)−u(t+1), and thus we can use this anticausal relation of the DS to find the corresponding state trajectories; • alternatively, we can allow the next state x2 (t + 1) to be freely chosen, and for arbitrary state x2 (t), the equations (10) impose constraints on the input sequence that is, therefore, no longer free as u(t) = −x3 (t). We embrace the latter, non-deterministic interpretation of the DS. This non-determinism can be characterised by introducing an auxiliary driving input of a so-called DV system. We reorganise the state evolution of (1). For simplicity we omit the time index in x(t) and u(t) and denote x(t + 1) as x+  + x = Ax, (11) M u where M = [E −B]. For any x, we notice that the pairs (u, x+ ) are non-unique due to the non-determinism related to x+ . If M has full row rank, then it has a right inverse. This always holds when the DS is reachable (cf. Definition 2-1.1 (Dai, 1989)). In that case we can characterise the non-determinism as follows. Let M + be a right inverse of M such that M M + = I and N be a matrix such that im N = ker M and N T N = I. Then all pairs (u, x+ ) that are compatible with state x in (11) are parametrised as  + x = M + Ax + N s, (12) u where s is a free variable. We now claim that all transitions (x, u, x+ ) in (12) for some variable s satisfy (11). To see this, multiply M on both sides of (12) to regain (11). Now assume that there exists a tuple (x, u, x+ ) satisfying (11) that does not satisfy (12). Then there exists an s and a vector z 6= 0 that is not an element of the kernel of M and such that the right side of (12) becomes M + Ax + N s + z. Multiplying again with M , we infer that there is an additional non-zero term M z and that (11) cannot hold. In conclusion any transition of (11) is also a transition of (12) and vice versa. Example 3. [Example 2: cont’d] For the DS of Example 2, the related DV system ΣDV is developed as h −1 0 −1 i h 0 i x(t + 1) = 0 0 0 x(t) + −1 s(t) 0 1 −1 0 (13) u(t) = [ 0 0 −1 ]x(t) y(t) = [ 0 0.2 0.5 ]x(t). As indicated by (13), the input u(t) is a function of the state trajectory. The non-determinism of x2 (t + 1) is characterised by −s(t) for which the auxiliary input s can be freely selected. Let us now formalise the notion of a driving variable representation. We associate a driving variable representation with any given DS (1) by defining a tuple (Ad , Bd , Cu , Du , C) and setting     Ad Bd = M + A, = N, (14) Cu Du where N ∈ R(n+p)×p has orthonormal columns, that is N T N = I. For any given DS, this tuple defines the driving variable system ΣDV = (N, W, BΣDV ), which maintains the same set of initial states X0 and has dynamics x(t + 1) = Ad x(t) + Bd s(t) u(t) = Cu x(t) + Du s(t) (15) y(t) = Cx(t), thereby yielding the initialised behaviour BΣDV := {w ∈ WN |w =(u, x, y), ∃s ∈ SN s.t. (15) and x0 ∈ X0 }. Next, we propose the following assumption for DS, which will be used in the sequel to develop our main results. Assumption 1. The given DS Σ is a dynamical system with dynamics (E, A, B, C) such that M = [E −B] has full row rank. The relationship between a DS and its related DV system is characterised as follows. Theorem 9. Let the DS Σ be given as in (1) satisfying Assumption 1 and let ΣDV = (N, W, BΣDV ) be defined as in (15). Then (1) Σ and ΣDV are bisimilar, that is, Σ ∼ = ΣDV , (2) Σ and ΣDV have equal behaviour, i.e., BΣDV = BΣ , (3) Σ and ΣDV have equal output behaviour, that is, ΠY (BΣ ) = ΠY (BΣDV ). Proof. For the first statement (1), we define the diagonal relation as I := {(x, x) | x ∈ X}. Then I is a bisimulation relation between Σ and ΣDV , because by construction their state evolutions can be matched, hence stay in I; and they share the same output map. In addition, since they have the same set of initial states it follows that Σ ∼ = ΣDV . The second part (2) follows immediately from the derivation of ΣDV , because by construction all the transitions in Σ can be matched by those of ΣDV and vice versa, in addition, they have the same output map. Hence, they share the same signal space (U × X × Y) and we can conclude that Σ and ΣDV have equal behaviour. Additionally, we have that (2) implies (3); via Proposition 6 also (1) implies (3). ✷ 3.4 Main result: exact control refinement for DS Based on the results developed in the previous subsections, we now derive the solution to the exact control refinement problem in Problem 1. More precisely, subject to the assumption that there exists a simulation relation R from Σa to Σ, for which in addition holds that ∀x0 ∈ X0 , ∃xa0 ∈ Xa0 s.t. (xa0 , x0 ) ∈ R, we show that for any Σca ∈ C(Σa ), there exists a controller Σc for Σ that refines Σca such that Σc ∈ C(Σ) and ΠY (BΣ×Σc ) ⊆ ΠY (BΣa ×Σca ). In the case of Assumption 1, we construct DV systems ΣDV and ΣDVa for the respective DS systems Σ and Σa as a first step. For these systems, we develop the following results on exact control refinement: i) The exact control refinement for the DV systems: ∀ΣcDVa ∈ C(ΣDVa ), ∃ΣcDV ∈ C(ΣDV ), s.t.   ΠY BΣDV ×Σc ; ⊆ ΠY BΣDVa ×Σc DV DVa ii) The exact control refinement from Σa to ΣDVa : ∀Σca ∈ C(Σa ), ∃ΣcDVa ∈ C(ΣDVa ), s.t.   ; ΠY BΣa ×Σca = ΠY BΣDVa ×Σc DVa iii) The exact control refinement from ΣDV to Σ: ∀ΣcDV ∈ C(ΣDV ), ∃Σc ∈ C(Σ), s.t.   = ΠY (BΣ×Σc ) . ΠY BΣDV ×Σc DV It will be shown that the combination of the elements i)–iii) also implies the construction of the exact control refinement for the concrete and abstract DS. i) Exact control refinement for the DV systems. From Theorem 9, we know that Σ ∼ = ΣDVa = ΣDV and Σa ∼ with respective diagonal relations I := {(x, x)|x ∈ X} and Ia := {(xa , xa )|xa ∈ Xa }. Hence as depicted in Fig. 2 and based on the transitivity of simulation relations, we also derive that R is a simulation relation from ΣDVa to ΣDV . Σ∼ = ΣDV , w.r.t. I Σ R = Ia ◦ R ◦ I (∃xa0 , ∀x0 ) ∈ R R (∃xa0 , ∀x0 ) ∈ R Σa ΣDV DVa ΣDVa Σa ∼ = ΣDVa , w.r.t. Ia Fig. 2. Connection between DS and DV systems for the exact control refinement. Since the DV systems ΣDV and ΣDVa share the same initial states as the respective DS Σ and Σa , it also holds that ∀x0 ∈ X0 , ∃xa0 ∈ Xa0 s.t. (xa0 , x0 ) ∈ R. According to Theorem 8, we know that we can do exact control refinement, that is, we have shown ∀ΣcDVa ∈ C(ΣDVa ), ∃ΣcDV ∈ C(ΣDV ), s.t.   ⊆ ΠY BΣDVa ×Σc . ΠY BΣDV ×Σc DVa DV ii) Exact control refinement from Σa to ΣDVa . Denote with ΣDVa the abstract DV system related to Σa , with dynamics (Ada , Bda , Cua , Dua , Ca ) and initialised with Xa0 . We first derive the static function Sa mapping transitions of Σa to the auxiliary input sa of ΣDVa . From the definition of DV systems, we can also derive the transitions of ΣDVa indexed with a, which is similar to the derivation of (12).  + xa = Ma+ Aa xa + Na sa . (16) ua Multiplying NaT on both sides of (16), Sa is derived as  + T xa −NaT Ma+ Aa xa . (17) Sa : sa = Sa (x+ , u , x ) = N a a a a ua Sa maps the state evolutions of Σa ×wa Σca to the auxiliary input sa for ΣDVa , where wa = (ua , xa ). Now, we consider the exact control refinement from the abstract DS to the abstract DV system. Theorem 10. Let Σa be the abstract DS with dynamics (Ea , Aa , Ba , Ca ) satisfying the condition of Assumption 1 and let ΣDVa be its related DV system with dynamics (Ada , Bda , Cua , Dua , Ca ) such that both systems are initialised with Xa0 . Then, for any Σca ∈ C(Σa ), there exists a controller ΣcDVa ∈ C(ΣDVa ) that is an exact control refinement for Σca as defined in Definition 4 with   . ΠY BΣa ×Σca = ΠY BΣDVa ×Σc DVa Proof. Denote with xa and xda the state variables of Σa and ΣDVa , respectively. Next, we construct the controller ΣcDVa that achieves exact control refinement for Σca as ΣcDVa := (Σa ×wa Σca ) ×wa ΣSa , where wa = (ua , xa ) and where ΣSa := (N, W, BSa ) is a dynamical system with BSa := {(xa , ua , xda , sa ) ∈ W|xa0 = xda0 and sa = Sa (x+ a , ua , xa )}. c The dynamical system ΣDVa is a well-posed controller for ΣDVa with ΣDVa ×wad ΣcDVa sharing wad = (sa , xda ). Denote the behaviour of the controlled system. with BΣDVa ×Σc DVa By construction, we know that the set of the behaviour is non-empty and there is a unique continuation for any xda0 ∈ Xa0 . Further based on the construction of ΣSa , the behaviour is such that xda (t) = xa (t), ∀t ∈ N. Additionally, since Σa and ΣDVa share the same set of initial states  Xa0 ,  it holds that ΠY BΣa ×Σca = ΠY BΣDVa ×Σc . ✷ The proof is actually constructive in the design of the controller ΣcDVa that achieves exact control refinement for Σc a . iii) Exact control refinement from ΣDV to Σ. Now, we consider the exact control refinement from ΣDV to Σ. Suppose we are given a well-posed controller ΣcDV for ΣDV , which shares the free variable s and the state variable x with ΣDV . We want to design a well-posed controller for Σ over w = (u, x), for which we consider the dynamical system ΣC = (N, W, B) over the signal space W = U × X × S, the behaviour of which can be defined by BdT x(t + 1) = BdT Ad x(t) + BdT Bd s(t) (18) u(t) = Cu x(t) + Du s(t). Then the dynamics of the interconnected system Σ ×w ΣC as a function of x and as      s is derived BDu A + BCu E s(t). (19) x(t) + x(t + 1) = BdT Bd BdT BdT Ad Note that A + BCu = EAd and BDu = EBd by multiplying M = [E −B] on the left-hand side of the two equations in (14). Therefore, (19) is simplified to       E E E Bd s(t). (20) Ad x(t) + x(t + 1) = BdT BdT BdT T  Furthermore E T Bd has full column rank because the  T T is square and has full rank. Hence matrix M N  T T E Bd has a left inverse and the dynamics of Σ ×w ΣC in (20) can be simplified as x(t + 1) = Ad x(t) + Bd s(t), which is exactly the same as the state evolutions of ΣDV as shown in (15). Next we construct Σc := ΣC ×wd ΣcDV with wd = (s, xd ) and it is a well-posed controller for Σ. This allows us to state the following theorem regarding the control refinement from ΣDV to Σ. Theorem 11. Let Σ be the concrete DS with dynamics (E, A, B, C) satisfying Assumption 1 and let ΣDV be its related DV system with dynamics (Ad , Bd , Cu , Du , C) such that both systems are initialised with X0 . Then, for any ΣcDV ∈ C(ΣDV ), there exists a controller Σc ∈ C(Σ) that is an exact control refinement for ΣcDV as defined in Definition 4 with   ΠY BΣDV ×Σc DV = ΠY (BΣ×Σc ) . Proof. Denote with x and xd the state variables of the Σ and ΣDV , respectively. Next, we construct the controller Σc that achieves exact control refinement for ΣcDV as Σc := ΣC ×wd ΣcDV , where wd = (s, xd ) and the dynamics of ΣC is defined as (18). Then, we can show that the dynamical system Σc is a well-posed controller for Σ. Based on the analysis of (20), it is shown that Σ ×w ΣC = ΣDV with w = (u, x), then we can derive Σ ×w Σc = ΣDV ×wd ΣcDV . Therefore, we can  = ΠY BΣ×Σc conclude Σc ∈ C(Σ) with ΠY BΣDV ×Σc DV immediately follows from ΣcDV ∈ C(ΣDV ). ✷ Exact control refinement for descriptor systems. We can now argue that there exists exact control refinement from Σa to Σ, as stated in the following result. Theorem 12. Consider two DS Σa (abstract, initialised with Xa0 ) and Σ (concrete, initialised with X0 ) satisfying Assumption 1 and let R be a simulation relation from Σa to Σ, for which in addition holds that ∀x0 ∈ X0 , ∃xa0 ∈ Xa0 s.t. (xa0 , x0 ) ∈ R. Then, for any Σca ∈ C(Σa ), there exists a controller Σc ∈ C(Σ) such that  ΠY (BΣ×Σc ) ⊆ ΠY BΣa ×Σca . Proof. Based on Assumption 1, we first construct ΣDV and ΣDVa . Then to prove this we need to construct the exact control refinement. This can be done based on the subsequent control refinements given in Theorem 10, Theorem 8 and Theorem 11. ✷ Theorem 12 claims the existence of such controller Σc that achieves exact control refinement for Σca . More precisely, we have shown in the proof that the refined controller Σc is constructive, which provides the solution to Problem 1. To elucidate how such an exact control refinement is constructed, we consider the following example. Example 4. [Example 2,3: cont’d] Consider the DS of Example 2 and its related DV system (cf. Example 3) such that both systems are initialised with X0 = {x0 | x0 ∈ [−1, 1]3 ⊂ R3 }. According to Silverman-Ho algorithm (Dai, 1989), we can select an abstract DS Σa = (Ea , Aa , Ba , Ca ) that is the minimal realisation of Σ and is initialised with Xa0 = R2 , in addition [ 01 00 ], Aa [ 10 01 ], Ba [ 10 ], Ca T [ 0.7 0.2 ] . Ea = = = = Similarly, the related DV system ΣDVa of Σa is given as  0  xa (t + 1) = [ 00 10 ]xa (t) + −1 sa (t) (21) ua (t) = [ −1 0 ]xa (t) ya (t) = [ 0.7 0.2 ]xa (t). Subsequently, R := {(xa , x) | xa = Hx, xa ∈ Xa , x ∈ X} is a simulation relation from Σa to Σ with   1 H = 00 01 −1 . This can be proved through verifying the two properties of Definition 5. In addition, the condition ∀x0 ∈ X0 , ∃xa0 ∈ Xa0 s.t. (xa0 , x0 ) ∈ R holds. According to Theorem 12, we can refine any Σca ∈ C(Σa ) to attain a well-posed controller Σc for Σ that solves Problem 1 as follows: Define Σca ∈ C(Σa ) with dynamics as [ 1 1 ]xa (t + 1) = [ 0.5 0.5 ]xa (t) + ua (t). The controlled system Σa ×wa Σca is derived as  0  1 xa (t + 1) = −0.5 −0.5 xa (t) ya (t) = [ 0.7 0.2 ]xa (t), with wa = (ua , xa ) and ua (t) = [ −1 0 ]xa (t). Then Σa ×wa Σca is stable. According to Theorem 10, we derive the map Sa for ΣDVa as sa (t) = [ 0 −1 ]xa (t + 1) = [ 0.5 0.5 ]xa (t). Next, the related interface from ΣDVa to ΣDV is developed as s(t) = sa (t) − [ 0 1 −1 ]x(t). According to Theorem 11, we derive the well-posed controller Σc as [ 0 −1 0 ]x(t + 1) = [ 0 −1 1 ]x(t) + [ 0.5 0.5 ]xa (t) u(t) = [ 0 0 −1 ]x(t), and the interconnected system Σ ×w Σc with w = (u, x), is derived as i h1 0 1 i h 0 0 x(t + 1) = 0 1 −1 x(t) + −0.5 −0.5 xa (t) 0 1 −1 0 0 y(t) = [ 0 0.2 0.5 ]x(t). Since (xa , x) ∈ R, that is xa = Hx, Σ ×w Σc can be simplified by replacing xa (t): h1 0 1 i x(t + 1) = 0 0.5 −1 x(t) 0 1 −1 y(t) = [ 0 0.2 0.5 ]x(t).  Finally, Σc ∈ C(Σ) and ΠY (BΣ×Σc ) ⊆ ΠY BΣa ×Σca are achieved. 4. CONCLUSION In this paper, we have developed a control refinement procedure for discrete-time descriptor systems that is largely based on the behavioural theory of dynamical systems and the theory of simulation relations among dynamical systems. Our main results provide complete solutions of the control refinement problem for this class of discrete-time systems. The exact control refinement that has been developed in this work also opens the possibilities for approximate control refinement notions, to be coupled with approximate similarity relations: these promise to leverage general model reduction techniques and to provide more freedom for the analysis and control of descriptor systems. The future research includes a comparison of the control refinement approach for descriptor systems to results in perturbation theory, as well as control refinement for nonlinear descriptor systems. REFERENCES Abadir, K.M. and Magnus, J.R. (2005). Matrix algebra. Cambridge University Press. Antoulas, A.C. (2005). Approximation of large-scale dynamical systems. SIAM. Cao, X., Saltik, M., and Weiland, S. (2015). Hankel model reduction for descriptor systems. In 2015 54th IEEE CDC, 4668–4673. Dai, L. (1989). Singular control systems. Springer-Verlag New York, Inc. Fainekos, G.E., Girard, A., and Pappas, G.J. (2007). Hierarchical synthesis of hybrid controllers from temporal logic specifications. In International Workshop on HSCC, 203–216. Girard, A. and Pappas, G.J. (2009). Hierarchical control system design using approximate simulation. Automatica, 45(2), 566–571. Girard, A. and Pappas, G.J. (2011). Approximate bisimulation: A bridge between computer science and control theory. European Journal of Control, 17(5), 568–578. Kloetzer, M. and Belta, C. (2008). A fully automated framework for control of linear systems from temporal logic specifications. IEEE Transactions on Automatic Control, 53(1), 287–297. Kunkel, P. and Mehrmann, V.L. (2006). Differentialalgebraic equations: analysis and numerical solution. European Mathematical Society. Megawati, N.Y. and Van der Schaft, A. (2015). Bisimulation equivalence of DAE systems. arXiv:1512.04689. Tabuada, P. (2009). Verification and control of hybrid systems: a symbolic approach. Springer Science & Business Media. Van der Schaft, A. (2004). Equivalence of dynamical systems by bisimulation. IEEE transactions on automatic control, 49(12), 2160–2172. Weiland, S. (1991). Theory of approximation and disturbnace attenuation for linear systems. University of Groningen. Willems, J.C. and Polderman, J.W. (2013). Introduction to mathematical systems theory: a behavioral approach, volume 26. Springer Science & Business Media.
3cs.SY
Multitask Evolution with Cartesian Genetic Programming Extended Abstract Eric O. Scott Kenneth A. De Jong George Mason University 4400 University Drive Fairfax, Virginia 22030 [email protected] George Mason University 4400 University Drive Fairfax, Virginia 22030 [email protected] arXiv:1702.02217v2 [cs.NE] 24 Apr 2017 ABSTRACT I0 I1 We introduce a genetic programming method for solving multiple Boolean circuit synthesis tasks simultaneously. This allows us to solve a set of elementary logic functions twice as easily as with a direct, single-task approach. CCS CONCEPTS •Computing methodologies → Search methodologies; KEYWORDS Output A Cartesian Genetic Programming, Multitask Learning ACM Reference format: Eric O. Scott and Kenneth A. De Jong. 2017. Multitask Evolution with Cartesian Genetic Programming. In Proceedings of GECCO ’17 Companion, Berlin, Germany, July 15-19, 2017, 2 pages. DOI: http://dx.doi.org/10.1145/3067695.3075615 1 INTRODUCTION Most evolutionary algorithms and metaheuristics built to date have been used as single-task problem solvers. With a few exceptions in areas like case-based reasoning [2] and robot shaping [3], traditionally there is no attempt to store solutions, subcomponents, or other evolved information from one task and to reuse it on other tasks. Instead, these search algorithms rely on direct guidance from an objective function to approach a solution via variation and selection. Very recently, a disjoint handful of researchers have begun to design new kinds of evolutionary systems that depart significantly from this single-task, adaptationist paradigm. Preliminary efforts with multitask evolutionary systems have begun to reveal cases where transferring and re-using information across superficially dissimilar tasks can serve to help a problem-solving agent perform more efficiently, or to provide a means of solving problems that would otherwise be deceptive or intractable. A number of different mechanisms for effectively evolving solutions to multiple tasks simultaneously or in sequence have recently been proposed by authors working in different domains. New structured-population models such as MAP-elites, for instance, have been developed for robotics and design applications [8], ‘multifactorial’ methods have Permission to make digital or hard copies of part or all of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for third-party components of this work must be honored. For all other uses, contact the owner/author(s). GECCO ’17 Companion, Berlin, Germany © 2017 Copyright held by the owner/author(s). 978-1-4503-4939-0/17/07. . . $15.00 DOI: http://dx.doi.org/10.1145/3067695.3075615 Output B Output C 1 Output C 2 Figure 1: A hypothetical logic circuit that solves three distinct Boolean functions over two inputs. The tree that solves task C reuses subtrees of the tree that solves task B. been introduced for combinatorial optimization [5], and agentbased ‘path-reuse’ mechanisms have been proposed to allow deep neural networks that have been evolved for different pattern recognition tasks to reuse subcomponents that were trained for previous tasks [4]. In this work, we are applying Cartesian genetic programming (CGP, [7]) in a multitask fashion to evolve logic circuits that solve elementary Boolean functions. Taking inspiration from the canonical literature on multitask learning in neural networks [1], we follow what we call a ‘multi-behavior’ approach to multitask evolution: each individual genome in the evolutionary algorithm encodes a solution to several tasks at once (Figure 1). In the resulting program tree, the solutions to each task all share the same inputs, but have their own designated outputs. This allows subtrees that are useful in the solution to one task to be reused as partial solutions to other tasks. CGP has often been applied in much this way to synthesize solutions to single tasks with more than one output. Our focus here is somewhat different: we are interested in finding ways of sharing and transferring information across multiple distinct tasks. The question here is whether we can use multitask CGP to more efficiently solve a set of tasks that would traditionally be treated separately. 2 METHODOLOGY The set of tasks used in this study is a simple suite T of 9 elementary logic function synthesis tasks that were originally used by Lenski et al. to demonstrate that complex tasks are sometimes easier to solve in conjunction with other tasks than they are to solve directly GECCO ’17 Companion, July 15-19, 2017, Berlin, Germany Eric O. Scott and Kenneth A. De Jong [6]: Performance of Tuned Algorithms on all 9 tasks 100000 Our primitive set consists only of {NAND}. For a preliminary proof of concept we wish only to demonstrate the following claim: Hypothesis: A multi-behavior approach will be able to solve all |T | = 9 tasks using less computational effort than a traditional single-task approach. To test this, we apply a standard (1 + 4)-style implementation of Cartesian genetic programming to a fitness function that evaluates each circuit on all 9 tasks simultaneously. We treat the average fitness across all 9 tasks as a scalar fitness value. Now, in multitask algorithm applications it sometimes happens that progress is impeded by task interference: progress on one task may overwrite the solution to previously solved tasks, preventing the algorithm from encoding solutions to many tasks at once. In light of this, we further hypothesize that multi-behavior CGP will perform better if we avoid mutating genes that belong to a successful solution to a task. We effect this by tracking which outputs each circuit element contributes information to. We then configure the probability that each element’s genes are mutated to be a decreasing function of the mean fitness of all the tasks it belongs to. We test this weighted mutation scheme with both linearly- and exponentiallydecreasing weighting functions. All together, we implemented one single-task CGP algorithm and three multi-behavior algorithms (a constant-mutation case, the linear case, and the exponential case). In order to achieve a fair comparison, we performed an extensive sweep over CGP’s free parameters and our weighted mutation scheme parameters to select configurations of each algorithm that solve the suite of tasks in the least computational effort on average. As a result of this parameter-tuning process, some algorithms are configured to use different circuit sizes than others. To compare results with different circuit sizes, our measure of computational effort is node-evaluations—that is, the number of individuals that have been evaluated, multiplied by their size. To solve all 9 tasks with each algorithm, we run each multi-behavior algorithm once on the task suite, and then we run the single-task algorithm 9 times in sequence, once for each of the tasks, measuring the total number of node-evaluations expended along the way before a solution is found. 3 PRELIMINARY RESULTS Results on the 9-logic suite suggest that the multi-behavior CGP algorithm is more efficient than a single-task approach when a constant or exponentially-weighted mutation rate is used. Figure 2 shows the distribution of effort each algorithm required to successfully find solutions to all 9 tasks. On average, we find that the exponentially-weighted algorithm solves the tasks twice as easily as the single-task algorithm does. One of the potential advantages of this kind of multitask evolution is that no prior knowledge is needed about how information might be reused across different tasks: evolution dynamically discovers subproblems that are redundant across tasks. Much more work is needed, however, to understand how sharing information across tasks works in different domains, and what conditions or Node-Evaluations to solve all 9 tasks T = {AND, AND N, EQU, NAND, NOR, NOT, OR, OR N, XOR}. 75000 50000 25000 0 Constant Exponential Linear Single Task Algorithm Figure 2: Preliminary results indicate that a multi-behavior approach is more efficient at solving all 9 tasks than a singletask approach. structural similarities among tasks are necessary to see performance improvements from multitask evolution. As this research continues, we intend to analyze the circuits generated by the multi-behavior approach for patterns of reuse, and to extend this methodology to more complex task suites and primitive sets. REFERENCES [1] Rich Caruana. 1998. Multitask learning. In Learning to learn. Springer, 95–133. [2] Pádraig Cunningham and Barry Smyth. 1997. Case-based reasoning in scheduling: reusing solution components. International Journal of Production Research 35, 11 (1997), 2947–2962. [3] Marco Dorigo and Marco Colombetti. 1998. Robot Shaping: An Experiment in Behavior Engineering. MIT Press, Cambridge, MA, USA. [4] Chrisantha Fernando, Dylan Banarse, Charles Blundell, Yori Zwols, David Ha, Andrei A Rusu, Alexander Pritzel, and Daan Wierstra. 2017. PathNet: Evolution Channels Gradient Descent in Super Neural Networks. arXiv preprint arXiv:1701.08734 (2017). [5] Abhishek Gupta, Yew-Soon Ong, and Liang Feng. 2016. Multifactorial Evolution. IEEE Transactions on Evolutionary Computation 20, 3 (2016), 343–357. [6] Richard E. Lenski, Charles Ofria, Robert T. Pennock, and Christoph Adami. 2003. The evolutionary origin of complex features. Nature 423 (May 2003), 139–144. [7] Julian F Miller. 2011. Cartesian genetic programming. In Cartesian Genetic Programming. Springer, 17–34. [8] A Nguyen, J Yosinski, and J Clune. 2016. Understanding Innovation Engines: Automated Creativity and Improved Stochastic Optimization via Deep Learning. Evolutionary Computation (2016).
9cs.NE
CONTINUITY OF DISCRETE HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS arXiv:1307.4447v4 [math.GT] 15 Jul 2016 SEBASTIAN HURTADO Abstract. Let M and N be two closed C ∞ manifolds and let Diffc (M ) denote the group of C ∞ diffeomorphisms isotopic to the identity. We prove that any (discrete) group homomorphism between Diffc (M ) and Diffc (N ) is continuous. We also show that a non-trivial group homomorphism Φ : Diffc (M ) → Diffc (N ) implies that dim(M ) ≤ dim(N ) and give a classification of such homomorphisms when dim(M ) = dim(N ). 1. Introduction Let M be a C ∞ manifold and let Diffc (M ) be the group of C ∞ diffeomorphisms of M which are isotopic to the identity and compactly supported (if M is noncompact). A well known theorem of Mather, Herman, Thurston and Epstein states that Diffc (M ) as a discrete group is simple (see [4]). In [11], Filipckewicz proved the following result: Given two C ∞ manifolds M and N , the groups Diffc (M ) and Diffc (N ) are isomorphic (as discrete groups) if and only if the manifolds M and N are C ∞ diffeomorphic. Moreover, if such an isomorphism exists should be given by conjugation with a fixed element of Diff(M ). Filipckewicz’s theorem implies in particular that two different smooth exotic 7-spheres have different diffeomorphism groups. The focus of this paper is the study of abstract group homomorphisms between groups of diffeomorphisms. We will make no assumptions on the continuity of the homomorphisms. Let M and N be two manifolds and let Φ : Diffc (M ) → Diffc (N ) be a group homomorphism. Observe that the simplicity of these groups imply that Φ is either trivial or injective. Date: July 18, 2016. 1991 Mathematics Subject Classification. Primary 00A30; Secondary 00A22, 03E20. 1 CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 2 Some examples of homomorphisms of the type Φ : Diffc (M ) → Diffc (N ) are the following: (1) Inclusion: If M ⊂ N is an open submanifold of N , the inclusion gives a homomorphism Φ : Diffc (M ) → Diffc (N ). (2) Coverings: If p : N → M is a finite covering, every diffeomorphism f ∈ Diffc (M ) can be lifted to a diffeomorphism f˜ of N . These lifts in many cases give a group homomorphism. For example, this is the case when p is an irregular cover (i.e. Deck(M/N ) = {Id}), as in this case he lift f˜ of any diffeomorphism f is unique. (3) Bundles: The unit tangent bundle U T (M ), the Grassmannian Grk (M ), consisting of k-planes in T (M ), product bundles, symmetric products and other bundles over M admit a natural action of Diffc (M ). Observe that all the homomorphisms described above are in some sense continuous maps from Diffc (M ) to Diffc (N ) in their usual C ∞ topologies. The main result of this paper shows that this is always the case when M is closed. Before stating our main result we need the following definition: Definition 1.1. For any compact subset K ⊆ M , let DiffK (M ) denote the group of diffeomorphisms in Diffc (M ) supported in K. A group homomorphism Φ : Diffc (M ) → Diffc (N ) is weakly continuous if for every compact set K ⊆ M , the restriction Φ|DiffK (M ) of Φ to DiffK (M ) is continuous in the weak topology, see 2.3. Our main theorem is the following: Theorem 1.2. Let M and N be C ∞ manifolds. If Φ : Diffc (M ) → Diffc (N ) is a discrete group homomorphism, then Φ is weakly continuous. It is worth pointing out that there is no assumption on the dimensions of the manifolds. As a consequence of Theorem 1.2, we will obtain a classification of all possible homomorphisms in the case when dim(M ) ≥ dim(N ). Mann [17] gave a classification of all the non-trivial homomorphisms Φ : Diffc (M ) → Diffc (N ) in the case that N is 1-dimensional. She CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 3 showed using one dimensional dynamics techniques (Kopell’s lemma, Szekeres theorem, etc.) that M must be one dimensional and that these homomorphisms are what she described as “topologically diagonal”. In the case when M = N = R, topologically diagonal means that Φ is given in the following way: Take a collection of finite disjoint open intervals Ij ⊂ R and diffeomorphisms fj : M → Ij . For each diffeomorphism g ∈ Diffc (R) the action of Φ(g) in the interval Ij is given by conjugation by fj , i.e. Φ(g)(x) = fi gfi−1 (x) for every x ∈ Ii . The action is defined to be the identity everywhere else. We will prove a generalization of the previous result: Theorem 1.3. Let M and N be C ∞ manifolds, let N be closed and dim(M ) ≥ dim(N ). If Φ : Diffc (M ) → Diffc (N ) is a non-trivial homomorphism of groups, then dim(M ) = dim(N ) and Φ is “extended topologically diagonal”. The definition of extended topologically diagonal is given in Subsection 3.12 and is a generalization of what we previously described as topologically diagonal by allowing the possibility of taking finite coverings of M and embedding them into N , see definition 3.12. Observe that as a corollary of Theorem 1.3 we obtain another proof of Filipckewicz’s theorem. The result also gives an affirmative answer to a question of Ghys (see [12]) asking whether a non-trivial homomorphism Φ : Diffc (M ) → Diffc (N ) implies that dim(N ) ≥ dim(M ). The rigidity results we obtain can be compared to analogous results obtained by Aramayona-Souto [2], who proved similar statements for homomorphisms between mapping class groups of surfaces and to deep results of Margulis about rigidity of lattices in linear groups. (See [22], Chapter 5). 1.1. Ingredients and main idea of the proof. The key ingredient in the proof of Theorem 1.2 is a theorem of E. Militon. This theorem says roughly that given a sequence hn converging to the identity in Diffc (M ) sufficiently fast (a geometric statement), one can construct a finite subset S of Diffc (M ), such that the group generated by S contains the sequence hn and such that the word length lS (hn ) (See 2.2) of each diffeomoprhism hn in the alphabet S is bounded by a sequence kn not depending on hn (an algebraic statement), see 2.3 for the correct statement. Militon’s theorem is a generalization of a result of Avila [3] CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 4 about Diff(S 1 ) and is related to results of Calegari-Freedman [6]. Militon’s result is strongly related to the theme of distortion elements in geometry group theory (See Gromov [13], Chapter 3). An element f of a finitely generated group G with generating set S is called distorted n if lim lS (fn ) = 0. n→∞ Consider for example the group BS(2, 1) = {a, b|bab−1 = a2 }. This group can be thought as the group generated by the functions a : x → n x + 1 and b : x → 2x in Diff(R). Observe that bn ab−n = a2 for every n and therefore a is distorted (In some sense a is “exponentially” distorted). An element f ∈ Diffc (M ) is said to be recurrent in Diffc (M ) if f satisfies that lim inf dC ∞ (f n , Id) = 0, for example an irrational rotation in S 1 is recurrent (See 2.3). A corollary of Militon’s theorem is that any recurrent element in Diffc (M ) is distorted in some finitely generated subgroup of Diffc (M ). Even more, it implies that such an element is“arbitrarily distorted” in the sense that f could be made as distorted as one wants (See ?? for a precise definition). For a nice exposition of the concept of distortion in transformation groups and the definition of the different types of distortion, see [6]. Observe that distorted elements are preserved under group homomorphisms and therefore if one wants to understand the existence of a group homomorphism, it might be fruitful to understand the distortion elements of the groups involved in the homomorphism. One example of this approach can be seen in the work of Franks and Handel [10]. They proved that any homomorphism from a large class of higher rank lattices Γ (For example SL3 (Z)) into Diffµ (S) (the group of diffeomorphisms of a surface preserving a measure µ) is finite using the fact that Γ has distorted elements and showing that any distorted element f ∈ Diffµ (S) fixes the support of the measure µ. For a more concrete statement of this and a clear exposition, see [9]. The main idea of how to use Militon’s theorem to obtain our rigidity results is illustrated in section 2.2 with a motivating example that encloses the main idea of Theorem 1.2 and is the heart of this paper. 1.2. Outline. The paper is divided as follows. In section 2, we will use Militon’s theorem to prove Lemma 2.1, which is the main tool to prove Theorem 1.2. In section 3, we prove Theorem 1.3 assuming that Φ is CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 5 weakly continuous, this section is independent of the other sections. In section 4, we establish some general facts about two constructions in group actions on manifolds that we will use for the proof of Theorem 1.2. In section 5, we show that Φ is weakly continuous using the results on section 2 and the facts discussed in section 4, finishing the proof of theorems 1.2 and 1.3. Finally, in section 6, we end up with some questions and remarks related to this work. 1.3. Acknowledgements. The author would like to thank the referee, Kathryn Mann, Benson Farb and especially Emmanuel Militon for useful comments and corrections on a previous version of this paper. The author is in debt with his advisor, Ian Agol, for his help, encouragement and support. 2. Main technique This is the most important section of the chapter, we will prove Lemma 2.1 which is a slightly weaker version of Theorem 1.2. The main ingredient in the proof of Lemma 2.1 is Theorem 2.3. We will discuss a motivating example in subsection 2.2 which avoids some necessary technicalities in the proof of Lemma 2.1 but contains the central point of our discussion. 2.1. Notation. Throughout this section and for the rest of this chapter we make use of the following notation: M and N denote C ∞ manifolds, Diffc (M ) will be the group of C ∞ diffeomorphisms which are compactly supported and isotopic to the identity. The letter Φ will always be a discrete group homomorphism Φ : Diffc (M ) → Diffc (N ) unless stated otherwise. For a compact set K, we let DiffK (M ) be the subgroup of Diffc (M ) consisting of diffeomorphisms supported in a compact set K. We will consider Diffc (M ) as a topological space endowed with the weak topology, this topology is metrizable and we will denote by d any metric that induces such topology. For more information about the weak topology see 2.3. We are now in position of stating the main lemma of this section. Lemma 2.1. Let M and N be C ∞ manifolds, let K be any compact subset of M and let Φ : Diffc (M ) → Diffc (N ) be a discrete group homomorphism. Suppose hn is a sequence in DiffK (M ) such that lim dC ∞ (hn , Id) = 0 n→∞ CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 6 Then {Φ(hn )} contains a subsequence converging to a diffeomorphism H, which is an isometry for a C ∞ Riemannian metric on N . Observe that the isometry H in Lemma 2.1 is necessarily homotopic to the identity, and therefore if the manifold N does not admit a metric with isometries homotopic to the identity (as for example is the case when N is a closed surface of genus g ≥ 2), the previous theorem implies the continuity of the homomorphism Φ restricted to DiffK (M ). Before stating Militon’s theorem, we will need the following standard definition: Definition 2.2. Let G be a finitely generated group and let S be a finite generating set. We assume that S = S −1 . Given an element g ∈ G, the word length lS (g) of g in s is defined as the minimum integer n such that g can be expressed as a product g = s1 s2 ...sn where each si ∈ S. In a more technical language, lS (g) is the distance of g to the identity in the Cayley graph corresponding to S. We are now in position of stating Militon’s theorem: Theorem 2.3. Let M be a compact manifold. There exist two sequences {n } → 0 and {kn } of positive real numbers such that for any sequence hn of diffeomorphisms in Diffc (M ) satisfying: dC ∞ (hn , Id) ≤ n there exists a finite set S ⊂ Diffc (M ) such that: (1) hn belongs to the subgroup generated by S (2) lS (hn ) ≤ kn Remark 2.4. The previous theorem is also true in the case where M is not compact and Diffc (M ) is replaced with DiffK (M ) for a compact subset K of M . Remark 2.5. The set S depends on the sequence hn , but the sequences {n } and {kn } are independent of the choice of hn . This result is a generalization of a Theorem of Avila [3], who proved the same result for Diffc (S1 ) case. The proof of the theorem is related to a construction of Calegari-Freedman [6], who showed that an irrational rotation of S2 is “arbitrarily distorted” in Diffc (S2 ). CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 7 For sake of completeness, we give a rough summary of how Theorem 2.3 is proved in [3], [19]. The proof of Theorem 2.3 has two steps: The first step is to show that an element in Diffc (M ) close to the identity can be written as a product of commutators of elements which are close to the identity, this step is proved using a KAM theory technique. The first step allows one to reduce the general case to the case where all the fn ’s are commutators supported in small open balls. The second step consist of using a finite set of diffeomorphisms to encode the sequence {fn } into a finite S, this step uses some clever algebraic tricks similar to the ones used in the proof of the simplicity of Diffc (M ) by Thurston (see [4], p. 23). The tricks depend heavily on the fact that the fn ’s are products of commutators. To give a hint of how powerful Theorem 2.3 can be for our purposes, observe the following: Let hn be a sequence in Diffc (M ) supported in a compact set K and converging to the identity in Diffc (M ) as in Theorem 2.3. As a consequence of Theorem 2.3, the sequence {hn } is generated by a finite set of diffeomorphisms S and therefore the set Φ(S) generates a group containing {Φ(hn )}. As a consequence, there exists a compact set K 0 ⊂ N (Namely, the union of the support of the generators) such that every element of the sequence {Φ(hn )} is supported in K 0 . This statement is not easy to deduce by elementary means. The following example is fundamental and contains the main idea in the proof of Lemma 2.1: 2.2. Motivating example. Let S2 be the 2-sphere and let Φ : Diffc (S2 ) → Diffc (S2 ) be a homomorphism of groups. As a consequence of Theorem 1.3 we are going to show that Φ is induced by conjugation via an element of Diff(S2 ). In particular, f and Φ(f ) turned out being conjugates as diffeomorphisms for every f ∈ Diffc (S2 ). In the next proposition we show that this is true for the most basic diffeomorphisms of S2 , namely rotations in SO(3). Proposition 2.6. Let S2 be the 2-sphere and let Φ : Diffc (S2 ) → Diffc (S2 ) be a group homomorphism. For any rotation R in SO(3), we have that C := Φ(R) preserves a Lipschitz metric g. If the metric g happens to be C ∞ then C is conjugate to a rotation in Diffc (S2 ). Proof. (Sketch) First consider the case when R is a finite order rotation. In this case, the diffeomorphism C is an element of finite order, CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 8 let say of order n. If we take anyPRiemannian metric g 0 in S2 and we n−1 consider the average metric g = i=0 (C i )∗ g 0 , it is easy to check that g is a Riemannian metric that is invariant under C . It follows from the uniformization theorem of Riemann surfaces that g is conformally equivalent to the standard metric in S2 . This implies that C is conjugate to a conformal map of finite order of S2 (an element of P SL2 (C)) and this easily implies that C is conjugate to a finite order rotation in SO(3). Now consider the case when R has infinite order (an irrational rotation). We want to imitate the proof of the finite order case: Let g 0 be an arbitrary Riemannian metric and consider the sequence of average Pn 1 i ∗ 0 metrics gn = n i=0 (C ) g . If an appropriate subsequence of {gn } converges to a metric g, the metric g would be invariant under C and we would be able to conclude that C is conjugate to a rotation arguing in the same way as in the finite order case. The problem is that to obtain such a convergent subsequence, we need the sequence {(C n )∗ (g 0 )} to not behave badly. The idea then is to obtain bounds in the derivatives of powers of C which would assure that the sequence of average metrics gn have a nice convergent subsequence. Therefore, we are going to show that kD(C n )k ≤ K, for some fixed constant K and every integer n. Suppose such a constant K does not exist, then there is a subsequence {C mn } such that kD(C mn )k → ∞. Passing through a subsequence, we can assume that the sequence of rotations Rmn is convergent, let’s assume it converges to the identity (if Rmn converges to another rotation, a similar argument works). Furthermore, we can kn assume that kD(C mn )k ≥ ee and that dC ∞ (Rmn , Id) ≤ n , for the constants n and kn in Theorem 2.3. Using Theorem 2.3, we can find a finite set S = {s1 , s2 . . . sl } such that lS (Rmn ) ≤ kn for every n and therefore we can express Rmn = Qln j=1 sij for some integers ln ≤ kn . If we take a constant L such that for each generator kD(Φ(sm ))k ≤ L for every m ≤ l, we obtain: g(n) = kDC mn k = kD ln Y j=1 ln Y  Φ(sij ) k ≤ kD(Φ(sij ))k ≤ Lkn j=1 This give us a contradiction: On the one hand the sequence kD(C mn )k kn diverges superexponentially (greater than ee ), and on the other hand, CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 9 it diverges at most exponentially (less than Lkn ). It is not difficult to show this imply gn has a convergent subsequence converging to a metric that a priory might be not smooth, see the proof of 2.1 for more details.  To promote the metric g in the previous proposition to an actual C ∞ metric we need to have control over higher derivatives of diffeomorphisms. We would also need an analog for higher order derivatives of the the fact that for any f, g ∈ Diff(S2 ), the inequality kD(f ◦ g)k ≤ kD(f )kkD(g)k holds. The purpose of the next two subsections is to set up the right framework to achieve these tasks. 2.3. Norms of derivatives. In the next two sections we will define “norms” k.kr of any element in Diffc (M ) whose purpose is to measure how big the r-derivatives of a diffeomorphism are. We are going to use the word “norm” to refer to them but the functions k.kr are not in any sense related to the various definitions of norms in the literature. This and the next subsection are technical and might be a good idea to skip them in a first read. If the reader decides to do that, he/she should have in mind that the r-norm k.kr of a diffeomorphism is an analog of kD(.)k for the the r-derivative and to take a look at Lemma 2.11, where using the chain rule, we will obtain for any f, g ∈ Diffc (M ) a bound for kf ◦ gkr in terms of the r-norms of the diffeomorphisms f and g. The group Diff(M ) has a natural topology known as the “weak topology”. This topology is defined as follows: Take a locally finite covering by coordinate charts {(Ui , φi )}i of M . For every diffeomorphism f ∈ Diffc (M ), every compact set K ⊂ Ui such that f (K) ⊂ Uj , every integer r ≥ 0 and every real number i,j  > 0, there is a neighborhood NK, (f ) of f defined as the set of all diffeomorphisms g ∈ Diff(M ) such that g(K) ⊂ Uj and such that for every 0 ≤ k ≤ r: −1 k kDk (φj ◦ f ◦ φ−1 i ) − D (φj ◦ g ◦ φi )k ≤  Where for any function f : Rn → Rn , Dk (f ) denotes any k-partial derivative of a component of f . CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 10 The topology induced in Diffc (M ) as a subset of Diff(M ) happens to be metrizable, Diffc (M ) is actually a Frechét manifold (see [15] for more details about this topology). We will denote by “dC ∞ ” any metric which induces such topology in Diffc (M ). For the proof of Lemma 2.1 we will need our norm k.kr to have two properties. The first property is that the r-norm should be able to tell when the r-derivatives of a sequence of diffeomorphisms {fn } is diverging or not. The second property is to have a bound for the r-norm of f ◦ g in terms of the r-norms of f and g. Based on these needs and the definition of the topology of Diffc (M ), we will define for an integer r ≥ 1 the r-norms in Diffc (M ) as follows: Let’s start first with the case when M ⊆ Rn is an open subset. In this case, we define for any compactly supported diffeomorphism f ∈ Diffc (M ) and for any r ≥ 1, kf kr = max ∂rf ∂xi1 ∂xi2 ..∂xir The maximum is taken over all the partial derivatives of the different components of f and over all the points x ∈ M . In order to define k.kr for an arbitrary manifold, we use a covering set {Ui }i of M by coordinate charts satisfying the following properties: (1) Each Ui is diffeomorphic to a closed ball of Rn by some diffeomorphism φi . (2) (int(Ui ), φi ) is a system of coordinate charts for M . (3) Every compact set K intersects a finite number of Ui ’s. The existence of such covering follows easily from the paracompacity of M . Let fix a compact set K in M . After choosing an arbitrary covering with the properties above, we define for every f ∈ DiffK (M ): kf kr,K = sup kφj ◦ f ◦ φ−1 i kr i,j The supremum is taken over all (i, j)’s such that Ui ∩K 6= ∅, Uj ∩K 6= ∅, and such the expression φj ◦ f ◦ φ−1 is well defined. The set of (i, j)’s i satisfying these properties is finite and therefore the above expression is always finite. CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 11 Remark 2.7. Whenever the compact set K is clear in our context we will suppress the subindex K and denote k.kr,K by k.kr , but it is important to take into account that k.kr is depending on K. Lemma 2.8. Let fn be a sequence in DiffK (M ). Suppose there exist constants C and Cr (for every r ≥ 1) such that the following holds: (1) kD(fn )k ≤ C (2) kfn kr ≤ Cr for n sufficiently large (depending on r) Then there is a subsequence of {fn } converging in the C ∞ topology to a diffeomorphism f satisfying kD(f )k ≤ C and kf kr ≤ Cr . Proof. From the bound kD(fn )k ≤ C, we conclude that the sequence fn is equicontinuous, and by Arzela-Ascoli’s theorem we obtain a subsequence fn0 of fn converging uniformly to a continuous map f : K → M . Similarly, for a fixed integer r ≥ 1, the inequality kfn0 kr ≤ Cr implies there is a subsequence fn00 of fn0 such that the first (r − 1) derivatives of fn00 converge uniformly in any fixed coordinate chart intersecting K. Using Cantor’s diagonal argument, we obtain a subsequence fn000 of fn00 , such that all the r-derivatives of fn000 converge uniformly, for every coordinate charts involving K. This implies that the map f is C ∞ . Using that kD(fn )k ≤ C, we can obtain that f is bi-Lipschitz and therefore invertible. In conclusion f is a diffeomorphism and satisfies kD(f )k ≤ C.  Observe that even though our definition of the k.kr norms depends strongly on the choice of coordinates charts, the previous statement is independent of the particular choice. 2.3.1. Metrics. In the proof of Lemma 2.1, we will also need to be able to measure when a sequence of metrics gn is “diverging” in the C ∞ sense: For a metric g = we define: P i,j gi,j dxi dxj defined in an closed sets U ⊆ Rn , ( maxi,j,x∈U |gi,j (x)| for r = 0 kgkr = maxi,j kgi,j kr for r ≥ 1 CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 12 We defined the previous norm k.kr just for metrics defined in closed subsets of Rn , the reason being that this shorten the use of new terminology and the length of our proofs. In the same spirit of Lemma 2.8, if a sequence of metrics gn defined in a closed set U ⊂ Rn satisfy that kgn kr ≤ Dr for some fixed constants Dr , it is easy to show hat gn has a subsequence converging to a C ∞ metric g uniformly in each compact set. We will need to make use of the following fact, which is an easy consequence of the chain rule: Lemma 2.9. Let U , V be closed sets of Rn . Let g be any Riemannian metric defined in U and let H : V → U be a diffeomorphism. Suppose for every r ≥ 1, there exist constants Cr , Dr such that: (1) kgkr ≤ Dr (2) kHkr ≤ Cr Then, there are constants Dr0 , just depending on Ck and Dk for k ≤ r + 1, such that kH ∗ (g)kr ≤ Dr0 for every r. Remark 2.10. H ∗ (g) denotes the pullback of g under H. 2.3.2. Main inequality. The next lemma is the analog for higher derivatives of the inequality kD(f ◦ g)k ≤ kD(f )kkD(g)k that we announced previously. Lemma 2.11. For every integer r ≥ 2, there exist constants Cr such that for any f, g ∈ Diffc (M ) the following inequality holds: kf ◦ gkr ≤ Cr (max {kf kl + kgkl })r+1 1≤l≤r Proof. We will first consider the case when M = Rn . Applying the chain rule r times to each of the components of the partial derivatives of f ◦ g we obtain a sum of terms. Each term in this sum is the product of at most r + 1 partial derivatives of some fi ’s and gj ’s (fi , gj denote components of f and g). The number of terms in this sum is at most a constant Cr (just depending on r and the dimension of M ) and each of the terms is less than kf kl + kgkl for some 1 ≤ l ≤ r, therefore: kf ◦ gkr ≤ Cr (max {kf kl + kgkl })r+1 1≤l≤r For an arbitrary manifold M , we take a covering by coordinate charts (Ui , φi ) as in the definition of the r-norm. For every pair (i, j) such that ((f ◦ g)−1 (Uj )) ∩ Ui 6= ∅ and every coordinate chart (Uk , φk ) such that f −1 (Uk ) intersects the set ((f ◦ g)−1 (Uj )) ∩ Ui , we have that: CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 13 −1 −1 kφj ◦ f ◦ g ◦ φ−1 i kr = kφj ◦ f ◦ φk ◦ φk ◦ g ◦ φi kr −1 r+1 ≤ Cr (max {kφj ◦ f ◦ φ−1 k kl + kφk ◦ g ◦ φi kl }) 1≤l≤r ≤ Cr (max {kf kl + kgkl })r+1 1≤l≤r In the previous equation, the first inequality follows from the Rn case proved previously. We can conclude the following: r+1 kf ◦ gkr = sup kφj ◦ f ◦ g ◦ φ−1 i kr ≤ Cr (max {kf kl + kgkl }) 1≤l≤r i,j  2.4. Proof of Lemma 2.1. The following lemma is the only place where we use Militon’s theorem. Roughly, the lemma claims that there exists a compact set K ⊂ Diffc (N ) such that for any sequence hn converging to the identity and n sufficiently large, Φ(hn ) is as close to K as one wants. More precisely: Lemma 2.12. Let M and N be two manifolds, let K be any compact subset of N , and let Φ : Diffc (M ) → Diffc (N ) be a group homomorphism. There exists a compact set K 0 and constants C and Cr such that: For every sequence hn in DiffK (M ) such that lim dC ∞ (hn , Id) = 0 n→∞ The following holds for n sufficiently large: (1) Φ(hn ) is supported in K 0 . (2) kD(Φ(hn ))k ≤ C. (3) kΦ(hn )kr ≤ Cr . Remark 2.13. How large n has to be in order to kΦ(hn )kr ≤ Cr to hold might depend on each particular r. The r-norms k.kr in N are defined with respect to the compact set K 0 in (1). In the proof of Lemma 2.12 we will use the following technical fact, which is a consequence of Lemma 2.11. Lemma 2.14. Fix an integer r ≥ 2. Let Ci be the constants defined in 2.12 and s1 , s2 . . . sk be elements of Diffc (M ). Let L be a constant such that: (1) ksj ki ≤ L, for every 1 ≤ i ≤ r and 1 ≤ j ≤ k. (2) max {Ci , 2} ≤ L 1≤i≤r CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 14 for every k ≥ 1 the following inequality holds: 2k ks1 ◦ s2 · · · ◦ sk kr ≤ L(r+2) Proof. The proof goes by induction on k, the case k = 1 is obvious. Suppose it holds for an integer k. Using Lemma 2.11, we have that: ks1 ◦ s2 · · · ◦ sk+1 kr ≤ L( max {ks1 ◦ s2 . . . sk ki + ksk+1 ki })r+1 1≤i≤r ≤ L( max {ks1 ◦ s2 . . . sk ki + L})r+1 1≤i≤r 2k ≤ L(L(r+2) + L)r+1 2k ≤ L(2L(r+2) )r+1 2k+1 ≤ L(Lr+1 L(r+2) ) 2k+1 +(r+2) = L(r+2) Using that the inequality (r + 2)2k+1 + (r + 2) ≤ (r + 2)2(k+1) holds for r ≥ 1, the results follows for k + 1.  Proof. (Lemma 2.12): Existence of K 0 : The proof goes by contradiction. Suppose such a compact set K 0 ⊂ N does not exist, using Cantor’s diagonal argument one can finds a sequence hn → Id such that the supports of Φ(hn ) are not contained in any compact set. Passing to a subsequence we can assume that dC ∞ (hn , Id) ≤ n for the sequence {n } in Theorem 2.3. Using theorem 2.3 we obtain a finite set S = {s1 , s2 . . . sl } such that the sequence {hn } is contained in the group generated by S. Applying Φ the same is true for the sequence {Φ(hn )} and S 0 = {Φ(s1 ), Φ(s2 ) . . . Φ(sl )}, therefore the support of all the Φ(hn )’s lies in the compact set K 00 given by the union of the supports of the elements in S 0 , which gives us a contradiction. Bound for kD(.)k: Suppose that no such constant C exists. Using a diagonal argument we can find a sequence hn ∈ DiffK (M ) converging to the identity and such that the sequence g(n) := kD(Φ(hn ))k diverges. Furthermore, passing to a subsequence we can assume that dC ∞ (hn , Id) ≤ n and that lim log(g(n)) = ∞, for the constants n and kn n→∞ kn defined in Theorem 2.3. CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 15 Using Theorem 2.3 we can find a finite set S = {s1 , s2 . . . sl } in Diffc (M ) generating a group containing al the hn ’s and such that lS (hn ) ≤ Qn kn for every n. Therefore, we have that hn = lj=1 sij for some constants ln ≤ kn . If we take a constant L such that kD(Φ(si ))k ≤ L for every generator si we get that: g(n) = kD(Φ(hn ))k = ln Y D(Φ(sij )) ≤ j=1 Therefore the inequality diverges. fact that log(g(n)) kn ln Y kD(Φ(sij ))k ≤ Lln ≤ Lkn j=1 log(g(n)) kn ≤ log(L) holds, contradicting the Bound for k.kr : The proof is similar to the previous case, but we will need to use Lemma 2.14. Suppose that for a fixed integer r such constant Cr does not exist. In that case, we can find a sequence hn converging to the identity and such that g(n) := kΦ(hn )kr diverges. Passing to a subsequence, we can further assume that dC ∞ (hn , Id) ≤ n and also that: log log(g(n)) lim (1) =∞ n→∞ kn For the sequences (n ) and (kn ) in Lemma 2.3. Using Lemma 2.3, we can find a finite set S generating a subgroup of Diffc (M ) where the inequality lS (hn ) ≤ kn holds for every n. Let L be a constant such that kΦ(g)kr ≤ L for every g ∈ S and which satisfies the hypothesis of Lemma 2.14. Using Lemma 2.14, we have that: 2kn g(n) = kΦ(hn )kr ≤ L(r+2) Taking logarithms in both sides we obtain: log log(g(n)) ≤ 2kn log(r + 2) + log(log(L)) which contradicts (1).  Finally, we will formulate Lemma 2.1 one more time and finish its proof. Lemma 2.1. Let M and N be C ∞ manifolds and let Φ : Diffc (M ) → Diffc (N ) be a group homomorphism. Suppose that hn is a sequence in Diffc (M ) supported in a compact set K and such that lim dC ∞ (hn , Id) = 0 n→∞ CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 16 Then {Φ(hn )} has a convergent subsequence, converging to a diffeomorphism H, which is an isometry for a C ∞ Riemannian metric on N. Proof. From Theorem 2.12 we conclude that given a fixed integer r ≥ 1, for n large enough the inequality kΦ(hn )kr ≤ Cr holds . Using Lemma 2.8 we can extract a convergent subsequence from {Φ(hn )} which is converging to a C ∞ diffeomorphism H. Even more, taking powers of hn we have the following: For every fixed integer k, the sequence hkn → Id and then the inequality kΦ(hkn )kr ≤ Cr holds for n large enough. Therefore we can conclude that kH k kr ≤ Cr for every integer k. Fix a Riemannian metric g 0 on N and consider the sequence of metrics: n 1 X k ∗ 0 gn = (H ) g n + 1 k=0 (The notation (H k )∗ g 0 denotes the pullback of the metric g 0 under the diffeomorphism H k ). Next, we will show that the sequence gn has a subsequence converging to a C ∞ metric g, which is invariant under H. To simplify the rest of the proof we will use the following notation. Take coordinate charts (Ui , φi ) of N as in the definition of the k.kr norms (See 2.3). For any metric g in N , let g i be the metric defined in the closed set φi (Ui ) ⊂ Rn obtained by pull back, more concretely ∗ g i := (φ−1 i ) g. Going back to our proof, observe that a diagonal argument shows that gn has a convergent subsequence if and only if in any coordinate chart, the corresponding sequence of metrics has a convergent subsequence. More concretely, we just need to show that for any fixed integer i, the sequence of metrics {gni }n (as defined in the previous paragraph) have a convergent subsequence. Pn 1 k ∗ 0 i Observe that gni = n+1 k=0 ((H ) g ) . From (1) on Theorem 2.12 the diffeomorphism S H is supported in a compact set, therefore for each fixed i the set k H k (Ui ) is contained in the union of a finite number of Uj ’s and so we can assume it intersects non-trivially the sets Ul for 1 ≤ l ≤ j. We define Dr := max kg l kr . 1≤l≤j For every integer k and each x ∈ Ui , the point H k (x) lies in the interior of Ul for some 1 ≤ l ≤ j. Thus we have that ((H k )∗ g)i = CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 17 ∗ l (φl ◦ H k ◦ φ−1 i ) g in a small ball around x. Using the inequalities −1 k kφl ◦ H ◦ φi k ≤ Cr and kg l k ≤ Dr , we can apply Lemma 2.9 to obtain constants Dr0 such that 0 ≤ k((H k )∗ g)i kr ≤ Dr0 for every integer r ≥ 1. The previous inequality implies that kgni kr ≤ Dr0 for every n ≥ 1 and therefore our sequence {gni }n has a convergent subsequence as we wanted. In conclusion, we can extract from the sequence gn a subsequence converging to a C ∞ metric g. To finish our proof we just need to show that the metric g is non-degenerate and invariant under H. Non degeneracy: As the inequality kD(H k )k ≤ C holds for every integer k, we conclude that for each vector v ∈ T M , each of the metrics gn satisfy the inequality: g 0 (v, v) ≤ gn (v, v) ≤ C 2 g 0 (v, v) C2 This implies that any convergent subsequence of {gn } converge to a non-degenerate metric and so our g is non-degenerate. Invariance under H: For any vector v ∈ T N , we have: kH ∗ gn (v, v) − gn (v, v)k = k(H n+1 )∗ g(v,v)−g(v,v)k n+1 ≤ (C + 1) kg(v,v)k n+1 Taking limits for our subsequence in the previous inequality we obtain that the metric g is invariant under H.  As a corollary, we obtain a proof of Theorem 1.2 in the case N is non compact. Corollary 2.15. Let M and N be C ∞ manifolds and suppose that N is non compact, any group homomorphism Φ : Diffc (M ) → Diffc (N ) is weakly continuous. Proof. Let K be any compact set in M . Arguing by contradiction, suppose hn is a sequence converging to the identity in DiffK (M ) but such that Φ(hn ) is not converging to the identity. We can suppose that dC ∞ (Φ(hn ), Id) ≥ C > 1 for every n ≥ 1. By Lemma 2.1 there is subsequence of Φ(hn ) converging to an isometry H in N and by (1) in Theorem 2.12 the isometry H should be the identity outside a compact set K 0 of N , therefore H is the identity everywhere contradicting that dC ∞ (Φ(hn ), Id) ≥ C > 1.  CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 18 3. Continuous case 3.1. Notation. Let M and N denote two C ∞ manifolds of dimension m and n respectively. For the rest of this section we will assume that N is closed. If U is an open subset of M , we define: GU = {f ∈ Diffc (M )| supp(f ) ⊂ U } We recall the definition of “ weak continuity” given in section 1. Definition 3.1. For any compact subset K ⊆ M , let DiffK (M ) denote the group of diffeomorphisms in Diffc (M ) supported in K. A group homomorphism Φ : Diffc (M ) → Diffc (N ) is weakly continuous if for every compact set K ⊆ M , the restriction Φ|DiffK (M ) of Φ to DiffK (M ) is continuous. Remark 3.2. If M is closed, this definition is equivalent to Φ being continuous in the usual sense. 3.2. Weak Continuity vs Continuity. The concept of weak continuity for a group homomorphism Φ : Diffc (M ) → Diffc (N ) is not equivalent to our homomorphism Φ being continuous in the weak topology of Diffc (M ) and one should not expect such continuity to hold. For example, take the open unit ball B ⊂ Rn . The homomorphism induced by the inclusion i : B → Rn is a group homomorphism which is not a continuous map in the weak topology: Take a sequence of diffeomorphisms fn supported in small disjoint balls Bn contained in B such that each Bn is centered at a point pn and has radius rn in such a way that the sequence pn converges to a point in ∂ B̄ , the radii rn → 0 and such that Dpn (fn ) = 2Id. The sequence fn converges to the identity in Diffc (B) in the weak topology because restricted to every compact set K ⊂ B, the sequence fn is the identity for large n. Nonetheless fn does not converge in Diffc (Rn ) and therefore Φ is not continuous. In this section, we will assume that Φ is always weakly continuous. The main purpose of this section is to establish the following result: Theorem 3.3. If Φ : Diffc (M ) → Diffc (N ) is a non-trivial weakly continuous homomorphism of groups, then dim(M ) ≤ dim(N ). If dim(M ) = dim(N ), then Φ is extended topologically diagonal. The definition of “extended topologically diagonal” will be given in 3.12 . The assumption of weak continuity results to be very strong for CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 19 a homomorphism between groups of diffeomorphisms. As a proof of that, we recall the following classic result (See [20], Ch. 5): Theorem 3.4. (Montgomery, Zippin) Let Φ be a continuous homomorphism from a finite dimensional Lie group G to the group Diffc (M ) of C ∞ diffeomorphisms of a manifold M . Then the map π : M × G → M given by π(x, g) = Φ(g)x is a C ∞ map in both variables (x, g) simultaneously. Corollary 3.5. If Φ : Diffc (M ) → Diffc (N ) is weakly continuous and X is a compactly supported vector field in M generating a flow ft ∈ Diffc (M ), then Φ(ft ) is a flow in Diffc (N ) generated by some vector field Y supported in N . Proof. H(t) = Φ(ft ) defines a homomorphism from R to Diff(M ). H(t) is continuous by the weak continuity of Φ and therefore is a C ∞ flow by Theorem 3.4. We obtain that Φ(ft ) is generated by some vector field Y in N .  In our proofs, we will use the following known fact. For a proof of this fact, see [4]. Lemma 3.6. (Fragmentation property) Let M be a manifold and B be an open cover of M , then Diffc (M ) is generated by the following set: C = {f ∈ Diffc (M ) such that supp(f ) ⊂ B0 , for some B0 ∈ B} In the next two subsections we will construct some examples of homomorphisms between groups of diffeomorphisms when dim(M ) = dim(N ). 3.3. Examples. When dim(M ) = dim(N ), there are two fundamental ways of constructing examples of homomorphisms of the type Φ : Diffc (M ) → Diffc (N ). The first one is to embed a finite number of copies of M into N and to act in such copies in the obvious way (topologically diagonal). The second one consist of homomorphisms coming from lifting diffeomorphisms of M to a covering N . The main theorem of this section shows that if Φ is continuous, all possible homomorphisms are combinations of these two examples. We will discuss these two fundamental examples in more detail: CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 20 3.3.1. Topologically diagonal. Definition 3.7. A homomorphism Φ : Diffc (M ) → Diffc (N ) is topologically diagonal if there exists a finite collection of disjoint open sets Ui ⊆ N and diffeomorphisms ρi : M → Ui , so that for every f ∈ Diffc (M ) we have: ( ρi ◦ f ◦ ρ−1 if x ∈ Ui i (x) Φ(f )(x) = x otherwise The fact that Ui is a finite collection is necessary. Even though we may be able to embed an infinite collection of M ’s in a closed manifold N , if the collection is not finite, the homomorphism Φ is not well defined.To illustrate better this point, observe the following: Let M = Rn and suppose there is an infinite collection of open sets Ui ⊂ N giving rise to a homomorphism Φ as in 3.7. Take a diffeomorphism f supported in the unit ball around the origin in Rn , such that f (0) = 0 and Df (0) = 2Id. Using the notation of ρi as in 3.7, consider the sequence ρi (0) = pi in N . {pi }i is an infinite sequence by assumption and therefore has an accumulation point p in N \ ∪i Ui . We have that D(Φ(f ))(pi ) = 2Id, and by continuity we have that D(Φ(f ))(p) = 2Id. It’s not difficult to see by the compactness of N that there is a another set of points qi → p such that Φ(f )qi = qi and that D(Φ(f ))(qi ) = Id, which implies that D(Φ(f ))(p) = Id, a contradiction. 3.3.2. Finite coverings. Many times when N is a finite covering of M there is a homomorphism Φ : Diffc (M ) → Diffc (N ) obtained by lifting a given f ∈ Diffc (M ) to an appropriate diffeomorphism f˜ of N . For example, if M and N are closed hyperbolic surfaces, every diffeomorphism of M isotopic to the identity can be lifted to the universal covering H2 (Hyperbolic plane). Even more, it can be lifted to a unique homeomorphism f 0 : H2 → H2 such that f 0 restricts to the identity in ∂H2 = S1 . This lift commutes with all the covering translations, and so one can project f 0 to a diffeomorphism f˜ of our covering surface N . One can check that ffg = f˜g̃ by the uniqueness of these lifts. Therefore, we obtain a homomorphism Φ : Diffc (M ) → Diffc (N ). Unfortunately, this is not true for all covering maps π : M → N . 2 For example, if we let M = N = S1 and π : S1 → S1 , the obvious CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 21 2 cover, any of the lifts of the rotation r2 in S1 of order 2, has order 4, and therefore it is impossible to construct a homomorphism Φ that commutes with p. The obstruction as we will see, comes from the fact that π1 (Diffc (S1 )) ∼ = Z is generated by a full rotation around the circle 2 and that π : S1 → S1 corresponds to the subgroup 2Z of Z. In a more precise way, we have the following situation: Let G = Diffc (M ), H be the group consisting of lifts of elements of G to N and L be the group of deck transformations corresponding to the covering map π : M → N , we have an exact sequence of discrete groups: (2) e→L→H→G→e We are interested in understanding when this sequence splits. For sake of completeness, we mention a useful criterion for proving this. For a proof, see [5] p.104. Lemma 3.8. The sequence e → L → H → G → e splits if and only if the two following conditions are satisfied: • The natural map H → Out(L) lifts to Aut(L). • The element in H 3 (G, Z(L)) defined by the exact sequence is trivial (Z(L) denotes the centralizer of L). As a consequence of Theorem 1.2 (whose proof will be given in section 5) our homomorphism Φ : G → H is continuous (when M and N are closed) and therefore showing that the previous sequence splits discretely is equivalent to show it splits continuously. Therefore, we just need to understand in which case there exists a continuous homomorphism Φ : G → H which splits our sequence. Observe that H is a covering of G, and so the existence of such continuous section Φ is equivalent to the covering H being trivial: H as a topological space should consist of the union of disjoint copies of G. This happens if and only if every element of L lies in different components of H. In conclusion, our sequence splits if there is no deck covering transformation L isotopic to the identity in H. In conclusion, our exact sequence (2) splits if and only if there is no deck transformation L of the covering π : N → M , which is isotopic to the identity in Diffc (N ). CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 22 Observe that if there is a path γ ∈ H connecting the identity to a non-trivial deck transformation L, projecting γ down to G we obtain a loop γ 0 representing a non-trivial element in π1 (G, e), the fundamental group of G based at the identity. To obtain a more precise statement of when this happens, we will need the following definition: Take an arbitrary point x ∈ M , there is a natural evaluation map Ex : Diffc (M ) → M given by Ex (f ) = f (x) and so we have a natural homomorphism of fundamental groups: Ex ∗ : π1 (Diffc (M ), e) → π1 (M, x) Observe the following fact: Proposition 3.9. A closed loop γ ∈ π1 (G, e) has a lift to H connecting the identity to a non-trivial deck transformation if and only if Ex ∗ (γ) 6∈ π1 (N ). Proof. In one direction, if a loop γ ∈ π1 (G, e) satisfies Ex ∗ (γ) 6∈ π1 (N ), the lift of Ex ∗ (γ) to N is not a closed loop. Therefore, the lift of γ to H ⊂ Diffc (N ) starting at the identity has to have the other endpoint in a non-trivial lift of the identity of Diffc (M ), that is, a non-trivial deck transformation. The other direction is trivial.  Summarizing all the previous discussion, we have the following criterion: Lemma 3.10. Let π : N → M be a covering map. There exists a unique continuous homomorphism π ∗ : Diffc (M ) → Diffc (N ) such that for every f ∈ Diffc (N ), the following diagram commutes: π ∗ (f ) N −−−→   πy N  π y M −−−→ M f if and only if Ex∗ (π1 (Diffc (M ), e)) ⊂ π1 (N ). Observe that if ft is a path in Diffc (M ) representing a loop α of π1 (Diffc (M ), e) based at the identity and γs is a loop based at x representing an element of π1 (M ), the family of paths {ft (γs )} give us a homotopy between the loops γ and (Ex∗ (ft ))−1 γ(Ex∗ (ft )). This shows CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 23 that the image of Ex ∗ is a central subgroup of π1 (M ). In particular, we obtain the following useful corollary: Corollary 3.11. If π : N → M is a covering map and π1 (M ) is center-less, then there is a homomorphism π ∗ : Diffc (M ) → Diffc (N ) as in Lemma 3.10. 3.4. Extended topologically diagonal. Based on the previous two examples we make the following definition: Definition 3.12. A homomorphism Φ : Diffc (M ) → Diffc (N ) is extended topologically diagonal (See Figure 3.4) if there exists a finite collection of disjoint open sets Ui ⊆ N and a set of finite coverings πi : Mi → M , together with a collection of diffeomorphisms ρi : Mi → Ui such that: For every f ∈ Diffc (M ), the following holds: ( ρi ◦ πi∗ (f ) ◦ ρ−1 if x ∈ Ui i (x) Φ(f )(x) = x otherwise Where πi∗ : Diffc (M ) → Diffc (Mi ) are the homomorphisms coming from the finite coverings πi as in the previous subsection. Remark 3.13. The coverings have to be finite in order for Φ to be an actual homomorphism into Diffc (N ). See the comments at the end of 3.3.1. We will illustrate the previous definition with the following example: Example 3.1. Let M be the once punctured 2-dimensional torus and let N be the closed orientable surface of genus 3. Take M1 to be a copy of M and M2 to be the twice punctured torus (which is a double cover of M ) as in Figure 3.4. We embed M1 and M2 into N as illustrated in Figure 3.4 and obtain a homomorphism Φ : Diffc (M ) → Diffc (N ). We are now in position to give a proof of the main result of this section. 3.5. Proof of Theorem 3.3. In order to prove Theorem 3.3, we will need to make the following definitions: Definition 3.14. For any group G ⊆ Diffc (N ), we define: supp1 (G) = {p ∈ N such that g(p) 6= p for some g ∈ G} CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 24 Figure 1. An extended topologically diagonal embedding For each x ∈ M , let’s define: \ supp1 (Φ(GBr )) Sx = r>0 where Br is an open ball of radius r around x. We construct the sets Sx thinking of constructing the maps ρi in the definition of extended topologically diagonal. We would like to show that Sx consists of a discrete set of points and that the correspondence Sx → x give us a collection of coverings from some open sets of N to M . Let N 0 := N \fix(Φ(Diffc (M ))) be the set of points in N that are not fixed by the action of Diffc (M ). Lemma 3.15. Let Φ : Diffc (M ) → Diffc (N ) be a non-trivial homomorphism, for every x ∈ M we have the following: (1) Sx is a non-empty set. (2) For any f ∈ Diffc (M ), Φ(f )Sx = Sf (x) . (3) N 0 = ∪x∈M Sx . Proof. We start with the proof of item (3). If p ∈ N 0 , there is an element f0 in Diffc (M ) such that Φ(f0 )(p) 6= p. Using the fragmentation property, we can express f as a product of diffeomorphisms supported in balls of radius one an so we obtain a diffeomorphism f1 supported in B1 ⊂ M such that Φ(f1 )(p) 6= p. We can iterate this inductive procedure and construct a diffeomorphism fn ∈ Diffc (M ) supported in a ball Bn of radius at most 1/n, such that Bn ⊂ Bn−1 and such that CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 25 Φ(fn )p 6= p. We define x := follows. T n Bn . It is clear that p ∈ Sx , so item (3) Item (2) follows by conjugating f and applying Φ. Item (1) is a direct consequence of (2) and (3).  The following two lemmas are technical lemmas needed for the proof of Lemma 3.18. Lemma 3.16. Given x0 ∈ M and U ⊆ M an open set containing x0 , there exists a neighborhood Nx0 of x0 in M and a continuous map Ψ : Nx0 → GU such that for every x ∈ Nx0 we have that Ψ(x)(x0 ) = x. Proof. Using coordinate charts is enough to check the case when M = Rn and x0 = 0. For 1 ≤ i ≤ n, let Xi be vector fields in Rn supported in U such that {Xi (0)}i is a linearly independent set of vectors. If fti are the flows generated by Xi , we have that fti ∈ GU . We define for t = (t1 , t2 . . . , tn ) ∈ (−, )n , the map ρ : (−, )n → Rn by ρ(t) = ft11 ft22 . . . ftnn (0). By our choice of Xi ’s, for sufficiently small , ρ is a diffeomorphism onto a small neighborhood N0 of 0 ∈ Rn . If ρ−1 (x) = (t1 (x), t2 (x), . . . , tn (x)), we can define the map Ψ : N0 → GU by Ψ(x) = ft11 (x) ft22 (x) . . . ftnn (x) . Ψ is clearly continuous and Ψ(x)(0) = x.  Lemma 3.17. Let Φ : Diffc (M ) → Diff(N ) be a weakly continuous homomorphism and let p be a point in N . There are no n + 1 pairwise disjoint open subsets Ui ⊂ M , i = 1, 2, . . . , n + 1, such that every subgroup Φ(GUi ) does not fix p. Proof. Suppose that such a point p exists. As a consequence of the simplicity of GUi , any element of GUi can be written as a product of a finite number of flows. Therefore, for every 1 ≤ i ≤ n + 1, there exists a flow fti supported in Ui , such that Φ(fti ) does not fix p. Observe that the vector fields Xi generating the flows Φ(fti ) satisfy that Xi (p) 6= 0. Also, as Φ(fti ) and Φ(ftj ) commute, we have that [Xi , Xj ] = 0 for every i, j. Let’s take a maximal collection of vector fields C = {X1 , X2 , . . . , Xk } in N such that X1 (p), X2 (p), . . . , Xk (p) are linearly independent and CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 26 such that all the Xj ’s comes from flows in different Φ(GUi )’s. Observe that k must be less or equal to n, therefore we can assume w.l.o.g. that if ft is any flow in GUn+1 and Y is the vector field corresponding to the flow Φ(ft ), then Y (p) is a linear combination of elements in {X1 (p), X2 (p), . . . , Xk (p)}. If we consider the open set: U = {q ∈ N | X1 (q), X2 (q), . . . , Xk (q) are linearly independent} We have that the vector fields in C define a foliation F on U by Frobenius integrability theorem. Let L be the leaf of F containing p. Observe that as Y (p) is a linear combination of elements of {X1 (p), X2 (p), . . . , Xk (p)} and [Y, Xi ] = 0, then we have that Y is tangent everywhere to the leaves defined by C. It also follows that if q ∈ U , then Φ(gt )q ∈ U for every t. In conclusion, we have that Φ(gt ) necessarily preserves L. As the diffeomorphism gt was an arbitrary flow in GUn+1 , we have obtained a non-trivial homomorphism Ψ : GUn+1 → Diff(L). Even more, the image of this map is abelian, since if Y and Z are vector fields coming from Φ(GUn+1 ), both Y and Z commute with all the elements of C, and therefore Y and Z can be shown to be linear combination of vector fields in C. This contradicts the simplicity of GUn+1 .  Lemma 3.18. If x, y are 2 distinct points on M , then Sx ∩ Sy = ∅. Proof. From Lemma 3.17, for any n + 1 different points x1 , x2 . . . , xn+1 in M we have that Sx1 ∩ Sx2 ∩ · · · ∩ Sxn+1 = ∅. Let k be the largest integer such that there exist x1 , x2 , . . . , xk distinct points on M such that Sx1 ∩ Sx2 ∩ · · · ∩ Sxk 6= ∅. We are going to show that k = 1. Take p be an arbitrary point in Sx1 ∩ Sx2 ∩ · · · ∩ Sxk . By Lemma 3.16, we can find pairwise disjoint neighborhoods Nxi of M and continuous maps Ψi : Nxi → Diffc (M ), such that Ψi (y)(xi ) = y for every y ∈ Nxi . Even more, we can suppose that the support of the elements in the image of Ψi and Ψj have disjoint support if i 6= j. Let V = Q Nxi ⊆ M k , we define the map Ψ : V → N given by: i Ψ(y1 , y2 , . . . , yk ) = Φ( Y Ψi (yi ))(p) i CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 27 Ψ isQcontinuous because Φ and all the Ψi ’s are continuous. Observe Q that ( Ψi (yi ))(xl ) = yl for every 1 ≤ l ≤ k, therefore Φ( Ψi (yi ))(p) ∈ i i Sy1 ∩Sy2 ∩· · ·∩Syk by property (2) in Lemma 3.15. By maximality of k, we obtain that Ψ is injective. It follows then that dim(M k ) ≤ dim(N ) and therefore k = 1 and dim(M ) = dim(N ).  As a corollary of the last paragraph we obtain: Corollary 3.19. If Φ : Diffc (M ) → Diffc (N ) is a weakly continuous homomorphism and dim(N ) < dim(M ), then Φ is trivial. Corollary 3.20. If Φ : Diffc (M ) → Diffc (N ) is a weakly continuous homomorphism of groups and dim(M ) = dim(N ), then for each p ∈ N 0 we have that Φ(Diffc (M ))p is an open set of M . Using the previous corollary, we obtain that for our set N 0 := N \ fix(Φ(Diffc (M ))) defined before Lemma 3.15, we have that N 0 = ∪i Ui where each Ui is an open set defined as Ui := Φ(Diff(M ))pi for some point pi ∈ N 0 . Observe that each Ui is a connected open set where the action of Diffc (M ) is transitive. To finish the proof of Theorem 3.3, we just need to show the following: Lemma 3.21. If Φ(Diffc (M )) acts transitively on N , then there is a C ∞ covering map π : N → M such that for every f ∈ Diffc (M ) the following diagram commutes: Φ(f ) N −−−→   πy N  π y M −−−→ M f In other words, Φ = π ∗ as in subsection 3.3.2. Proof. Let π : N → M be the map defined by π(p) = x if p ∈ Sx . Observe that the map is well defined by Lemma 3.18 and is surjective by our transitivity assumption. Next, we will show that π is locally a C ∞ diffeomorphism. Using Lemma 3.16, we can find a neighborhood Nx of M and a continuous map Ψ : Nx → Diffc (M ) such that Ψ(y)(x) = y for every y ∈ Nx . We can define the map ρ : Nx → N given by ρ(y) = Φ(Ψ(y))(p) CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 28 Observe that ρ is continuous because Φ is weakly continuous and injective because ρ(y) ∈ Sy and Lemma 3.18. We also have that π◦ρ = Id which implies that π is a covering map. To show that π is a C ∞ map it is enough to show that ρ is a C ∞ diffeomorphism onto its image. The fact that ρ is smooth follows from Lemma 3.4: It’s enough to prove that the image of a C ∞ embedded curve γ passing through x is a C ∞ curve. Given γ, we can construct a C ∞ compactly supported vector field X such that γ is a flow line of this vector field. X defines a flow ft and by Lemma 3.5 we have that Φ(ft ) is a C ∞ flow. Observe that ρ(ft (x)) ∈ Sft (x) = Φ(ft )Sx . Using that ρ is locally a homeomorphism for t sufficiently small we have that ρ(ft (x)) = Φ(ft )p and therefore ρ(γ) is smooth.  4. Blow-ups and gluing of actions In the proof of Theorem 1.2 we are going to make use of the following two constructions on group actions on manifolds: 4.1. Blow-ups. Given a closed manifold N and a closed embedded submanifold L ⊂ N of positive codimension, let Diffc (N, L) be the group of diffeomorphisms of N preserving L setwise. Suppose we have a group G ⊆ Diffc (N, L). We will show how to construct a natural action of G in N σ , where N σ is the manifold obtained by blowing up N along L. Intuitively, the blow-up N σ is obtained by compactifying N \L by the unit normal bundle of L in N . More concretely, let fix a Riemannian metric on N and let N (L) be the unit normal bundle of our submanifold L in that metric. The normal neighborhood theorem states that the map: p0 : N (L) × (0, ) → N Defined by sending (v, t) to the point γv (t) in N at distance t along the geodesic with initial vector v, is a diffeomorphism onto a neighborhood of L for sufficiently small . We now define formally N σ , the blow-up of N along L, as follows: N σ = (N (L) × [0, )) ∪ (N \L)/p0 . N σ is a compact manifold with N (L) as its boundary and there is a canonical smooth map π : N σ → N . The smooth structure on the blow-up N σ does not depend on the metric, N σ can be also described CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 29 as the compactification of N \L by the set of directions up to positive scale in ∪ (Tq N/Tq L). q∈L In order to describe the smooth structure on N σ in more detail, suppose for the rest of this section that L consists of a single point p (the more general case can be treated in a similar way). Let x1 , x2 , . . . , xn be coordinate charts around p in N , where xi (p) = 0 for every 1 ≤ i ≤ n and let v be a direction up to positive scale in Tp (N ). Without loss of generality, assume that in our coordinate charts we have that v = hv1 , v2 , . . . , vn−1 , 1i. Then, there is a corresponding set of coordinate charts ξ1 , ξ2 , . . . , ξn−1 , xn around v in N σ , where v corresponds to the point ξi = vi , xn = 0 and the change of coordinates for xn > 0 is given by xj = xn ξj . The next lemma is the main fact that we need about blow-ups of actions and implies that for a given group action Φ : G → Diffc (N ), preserving a submanifold L, there is a corresponding action Φ0 : G → Diffc (N σ ) in the corresponding blow-up N σ , more precisely: Lemma 4.1. There is a “blow-up” map σ : Diffc (N, L) → Diffc (N σ ) such that for every h ∈ Diffc (N, L) the following diagram commutes: σ(h) N σ −−−→   πy Nσ  π y N −−−→ N h Even more, σ is a group homomorphism. Proof. For any h in Diffc (N ) we will define σ(h) as follows: If x ∈ N σ \ ∂N σ we define σ(h)(x) = h(x). On the boundary ∂N σ , we can define σ(h) as the projectivization (up to positive scale) of the map Dh(p) : Tp N → Tp N . It is easy to see that σ(h) is continuous. We need to check that σ(h) is a smooth map: Suppose that in our coordinate charts x1 , x2 , . . . , xn around p in N , the diffeomorphism h is given locally by h = (h1 , . . . , hn ), where p correspond to 0 ∈ Rn and h(0) = 0. Given a direction v (up to positive scale) at the origin, such as v = hv1 , v2 , . . . , vn−1 , 1i, there exists some j such that ∇hj (p)(vi , 1) 6= 0, so we can assume that ∇hj (p)(vi , 1) > 0. In our coordinate charts ξ1 , ξ2 , . . . , ξn−1 , xn explained previously, we have that σ(h) is given by σ(h) = (hσ1 , hσ2 , . . . , hσn ) where: CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 30 ( hσi (ξ, xn ) = hi (xn ξ,xn ) hj (xn ξ,xn ) if i 6= j hj (xn ξ, xn ) if i = j Where ξ := hξ1 , ξ2 , . . . , ξn−1 i and xn 6= 0. When xn = 0 (in the boundary), we have that: hi (xn ξ, xn ) ∇hi (0)hξ, 1i = xn →0 hj (xn ξ, xn ) ∇hj (0)hξ, 1i hσi (ξ, 0) = lim Additionally, observe that that ∇hj (0)(ξ, 1) 6= 0. ∂ h (xn ξ, xn ) ∂xn j = ∇hj (xn ξ, xn )(ξ, 1) and All the previous formulas imply that the derivatives of any order of σ(h) exist for points in the boundary ∂N σ and therefore σ(h) belongs to Diffc (N σ ). We still need to show that σ : Diffc (N, L) → Diff(N σ ) is a group homomorphism, more precisely, we need to show that for any f, g ∈ Diffc (N, L), the equality σ(f g) = σ(f )σ(g) holds. This equality is obvious for points in N σ \∂N σ and it follows from the chain rule for points in ∂N σ .  For more details and other aspects about the previous blow-up construction, see ([16], sec 2.5). A related blow-up for diffeomorphisms is studied in great detail in [1]. 4.2. Gluing actions along a boundary. Given N1 and N2 two compact manifolds with non-empty boundary, suppose there is a diffeomorphism α : ∂N 1 → ∂N 2 . Denote N = N 1 ∪ N 2 the manifold obtained by gluing N 1 and N 2 along the boundary using α. Suppose we have actions Φi : G → Diffc (N i ) in such a way that the actions of every element g ∈ G coincide in the common boundary. More precisely, suppose that for each g ∈ G, the equality Φ2 (g) = α ◦ Φ1 (g) ◦ α−1 holds for points in ∂N 2 . In general, if we glue Φ1 (g) and Φ2 (g) along the common boundary, we will not obtain a C ∞ diffeomorphism of N . Nonetheless, the following theorem of Parkhe (See [21]) gives a way to modify the actions in such a way that the resulting glued action of G in our manifold N is a truly C ∞ action. CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 31 Theorem 4.2. There are homeomorphisms Ψ1 and Ψ2 of N 1 and N 2 with the following property: i (1) For any f ∈ Diffc (N i ), the map Ψi f Ψ−1 i ∈ Diffc (N ) 1 2 (2) If f1 ∈ Diffc (N ) and f2 ∈ Diffc (N ) coincide in the common boundary, then the diffeomorphism f defined by Ψi fi Ψ−1 in N i i ∞ for i = 1, 2 is a C diffeomorphism of N . Therefore, if we define new homomorphisms Φ0i : G → Diffc (Ni ) 0 0 by Φ0i (g) = Ψi Φi (g)Ψ−1 i , we can glue both Φ1 and Φ2 to obtain a 0 homomorphism Φ : G → Diffc (N ). 5. Proof of theorem 1.2 In this section, we will use the results of section 2 together with the facts discussed in section 4 to give a proof of Theorem 1.2. This result along with Theorem 3.3 completes also the proof of Theorem 1.3. From now on, we denote G = Diffc (Rn ). As in section 3, if B is an embedded open ball contained in Rn , we denote: GB = {f ∈ Diffc (M )| supp(f ) ⊂ B} In the proof of Theorem 1.2 we are going to make use of the following basic fact: Lemma 5.1. Φ is weakly continuous if for some ball B ⊂ M whose closure is a closed ball embedded in M , we have that the restriction Φ|GB of Φ to the subgroup GB is continuous. Proof. Conjugating with elements of Diffc (M ) we get that for any embedded ball B 0 , the homomorphism Φ|Diffc (B 0 ) is continuous. From the proof of the fragmentation lemma (Lemma 2.1.8 in [4]) , one obtains that if the sequence fn tending to Id is supported in a compact set K and C is a finite covering of K by sufficiently small balls, then for large n, the diffeomorphisms fn can be written as products of diffeomorphisms supported in open sets of C. Furthermore, we can achieve this with at most k factors for each open set of C (for some constant k) and it can be done in such a way that these diffeomorphisms are also converging to the identity.  We will proceed to give a sketch of our main result, Theorem 1.2. Sketch of the proof of Theorem 1.2. The proof goes by induction in the dimension of N . Consider any open ball B whose closure is a closed ball embedded in M . By Lemma 5.1, to show that Φ is weakly continuous, it is enough to show that Φ is weakly continuous when we restrict CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 32 to the subgroup GB . We are going to use many times the following fact: Φ is weakly continuous if the following condition holds: There is no sequence fn in GB , such that fn → Id and Φ(fn ) → A, where A is a non-trivial isometry in some Riemannian metric on N . This fact is an immediate consequence of Lemma 2.1. Assume such non-trivial isometry A exists. If we take a ball B 0 disjoint from B, the actions of GB 0 and A commute. If A has a non-trivial fixed point set L, then GB 0 preserves L setwise, a manifold of lower dimension than N . Therefore, we can blow-up the action at L and show by induction that Φ is continuous. If A acts freely instead, we will obtain an action of GB 0 on the space N 0 := N/H, where H = hAi is the closure of the subgroup generated by A. If the group H is infinite, N 0 is a manifold of lower dimension than N and we can proceed to prove the continuity by induction. If H is finite, we will show a way to replace H by a similar infinite group of isometries Ĥ to proceed as in the case where H is infinite.  In the proof of Theorem 1.2, we are going to make use of the following known fact: Lemma 5.2. If N is a closed Riemannian manifold and H is a nontrivial closed connected subgroup of the group of isometries of N , then fix(H) = {p ∈ N | h(p) = p for every h ∈ H} is a closed submanifold of positive codimension. We will also need the following technical lemma: Lemma 5.3. If Φ : Diffc (B0 ) → Diffc (N 0 ) is a weakly continuous homomorphism, then there exists an embedded open ball B2 ⊂ B1 and a point p ∈ N 0 such that for any diffeomorphism f supported in B2 , the equality Φ(f )p = p holds. Proof. Define n = dim(N ) + 1 and consider an arbitrary point p ∈ N . For 1 ≤ i ≤ n, let Ui be disjoint embedded balls contained in B1 . Using Lemma 3.17, we conclude that for at least one of these balls, which we denote by B2 , the restricted homomorphism Φ|GB2 fixes p.  CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 33 By Lemma 5.1, Theorem 1.2 is a direct consequence of the following: Lemma 5.4. Let N be a closed manifold. If Φ : Diffc (Rm ) → Diffc (N ) is a group homomorphism, then Φ is weakly continuous. Proof. We proceed by induction on the dimension of N . The proof for the case n = 0 is trivial and the case n = 1 is proved in [17]. Let B de the unit ball in Rn . Suppose that Φ is not weakly continuous. By Lemma 2.1, there is a ball B0 ⊂ B strictly contained in B and a sequence fn ∈ GB0 such that fn → Id and Φ(fn ) → A, where A is a non-trivial isometry for some Riemmanian metric on N . Define H := hAi, H is a closed subgroup of the Lie group of isometries of N . We can further suppose that B0 is strictly contained in B. For the rest of the proof, we let B1 ⊆ B be an embedded ball disjoint from B0 , Observe that as B0 and B1 are disjoint, the groups Φ(GB0 ) and Φ(GB1 ) commute. First we show that we can assume H acts freely: Lemma 5.5. If H does not act freely, then Φ is weakly continuous. Proof. Suppose that H does not act freely. We can replace our group H with a non-trivial closed subgroup and assume that L = fix(H) 6= ∅. By Lemma 5.2, L is a closed submanifold of positive codimension. Observe that the action of Φ(GB1 ) on N commutes with the action of H and therefore L is invariant under Φ(GB1 ). Using Lemma 4.1 we can blow-up the action Φ at L to obtain an action Φσ : GB1 → N σ . This new action preserves the boundary ∂N σ = N (S), and therefore we obtained a homomorphism Φσ |∂N σ : Diffc (Rm ) → Diff(∂N σ ) that by induction is weakly continuous. To prove that Φ is weakly continuous, we will need to define the following objects: Let N 1 and N 2 be two copies of N σ . Additionally, let N 0 := N 1 ∪ N 2 , be the manifold obtained by gluing N 1 , N 2 in the obvious way. Finally, consider the homomorphisms Φi : GB1 → Diffc (N i ) equal to Φσ for i = 1, 2. Observe that the previous homomorphisms define an action of GB1 on N 0 , but this action might not be smooth in the submanifold corresponding to the glued boundaries. Using the gluing theorem described CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 34 in section 4.2, we can conjugate the actions in each N i by homeomorphisms and obtain a smooth action Φ0 : GB1 → Diffc (N 0 ). We are now going to make use of the following trick: We will show that Φ0 is weakly continuous using the induction hypothesis and then we will show that the continuity of Φ0 implies the continuity of Φ. Let’s show that Φ0 : GB1 → Diffc (N 0 ) is weakly continuous. By Lemma 2.1, it is enough to show the following: If fn ∈ GB1 is a sequence such that fn → Id and Φ0 (fn ) → A, where A is an isometry for N 0 , then A is trivial. By induction, the restriction of Φ0 to the submanifold corresponding to the glued boundaries is continuous, therefore A is trivial in a codimension one submanifold. As any orientation-preserving isometry that is trivial in a codimension one submanifold is trivial everywhere, we obtain that A must be trivial. Now we show that the weak continuity of Φ0 implies Φ is weakly continuous as well. Let fn be a sequence in GB1 such that fn → Id and Φ(fn ) → A, where A is an isometry of N . From the previous paragraph, we have that Φ0 (fn ) → Id. This implies that Φσ (fn ) → Id (at least topologically) and therefore Φ(fn ) → Id. In conclusion, A must be trivial and by Lemma 2.1, the homomorphism Φ is continuous.  We can now assume that the action of H in N is free. Next, we will prove that if H is infinite, then Φ is continuous. Lemma 5.6. If H is infinite and acts freely, then Φ is weakly continuous. Proof. Let B1 a ball in M disjoint from B0 . The actions of Φ(GB1 ) and H on the manifold N commute. If we let N 0 := N/H, then N 0 is a smooth manifold because the action is free. The dimension of N 0 is lower than the dimension of N , moreover, we have that Φ descends to a homomorphism Φ0 : GB1 → Diffc (N 0 ). By induction, Φ0 is continuous. Let p ∈ N 0 be an arbitrary point. By Lemma 5.3, there is a ball B2 ⊆ B1 such that Φ0 (GB2 )p = p. Therefore, Φ(GB2 ) preserves the manifold Hp = {h(p) | h ∈ H}, furthermore we can assume that the dimension of Hp is lower than the dimension of N . In conclusion, we obtain a homomorphism Φ00 : GB2 → Diffc (Hp ) CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 35 that by induction is continuous. We are going to deduce the weak continuity of Φ from the continuity of Φ0 and Φ00 . By Lemma 2.1, it is enough to show that if fn ∈ GB2 is a sequence such that fn → Id and Φ(fn ) → A, where A is an isometry of N , then A = Id. Take a point q ∈ Hp , we are going to show that A(q) = q and that the derivative Dq (A) of A at q is trivial. Given that A is an isometry of some metric, these two facts are enough to show that A is trivial. The fact that A(q) = q, follows from the fact that Φ00 (fn ) → Id. We now prove that the derivative Dq A is trivial. We can split the tangent space Tq (N ) of N at q as follows: Tq (N ) = Tq (Hp ) ⊕ W Where Tq (Hp ) is the tangent space of Hp at q and W is the orthogonal complement of Tq (Hp ) in Tq (N ). Observe that as Φ00 (fn ) → Id, then Dq A preserves Tq (Hp ) and Dq |Tq (Hp ) = Id. In a similar way, considering the fact that Φ0 (fn ) → Id, if we let πW denote the orthogonal projection of Tq (N ) onto W , we have that πW ◦ Dq A = Id These two facts imply that the linear map Dq (A) must be the identity: Dq (A) has a matrix decomposition in blocks, each block corresponding to the subspaces Tq (Hp ) and W . In this decomposition, Dq A is an upper triangular matrix and the diagonal blocks are the identity, therefore, all the eigenvalues of Dq A are equal to one. Since A is an isometry, Dq A is an orthogonal matrix will all its eigenvalues equal to one and therefore Dq A must be the identity. In conclusion, we have that A(q) = q and Dq A = Id. As A is an isometry, A must be trivial.  The only remaining case to finish the proof of Theorem 5.4 is the case where H is a finite group and H acts freely on N . We will show that if Φ were not continuous, we can replace H with an infinite group of isometries Ĥ that would reduce the proof of this case to the previous two lemmas. CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 36 Lemma 5.7. If H is finite and acts freely, one of the following alternatives hold: (1) Φ is weakly continuous. (2) There exists a metric on N and an infinite subgroup of isometries Ĥ of N , together with an embedded ball B 0 ⊆ Rn such that the action of Φ(GB 0 ) commutes with the action of Ĥ. Proof. Let N0 := N , H0 := H and N1 := N0 /H0 . The homomorphism Φ descends to a homomorphism Φ1 : GB1 → Diff(N1 ) as the groups GB1 and H0 commute with each other. One can check that if Φ1 is continuous, then Φ is continuous. Therefore, if Φ1 is not continuous, there is a sequence fn,1 ∈ GB1 such that fn,1 → Id and such that Φ1 (fn,1 ) → A1 ∈ Diff(N1 ), where A1 is a non-trivial isometry on some metric on N1 . Let H1 = hA1 i. If H1 does not act freely or H1 is infinite, we can use lemmas 5.5 and 5.6 to conclude that Φ1 is continuous, therefore we can assume H1 is finite and fixed point free. We are now in the same situation we were at the beginning of the proof of this lemma. For that reason, we can repeat this procedure infinitely many times as follows: We construct for each integer k, the following objects: A ball Bk ⊂ B disjoint from the balls Bj for j < k, a closed manifold Nk = Nk−1 /Hk−1 and a group homomorphism Φk : GBk → Diff(Nk ) descending from Φk−1 . Together with a sequence {fn,k } ∈ GBk such that as n → ∞, we have that fn,k → Id and Φk (fn,k ) → Ak , where Ak is a non-trivial isometry on some metric on Nk and the group Hk = hAk i is a non-trivial finite group of diffeomorphisms acting freely on Nk . Observe that the only way this procedure can’t be repeated infinitely times is if for some k, the homomorphism Φk were weakly continuous, but this would imply that Φ is weakly continuous, therefore we can assume the previous objects are defined for every integer k ≥ 1. Next, we are going to show how to get an infinite group of isometries for N from our Hk ’s. Let’s define: Ĥk = {h ∈ Diffc (N ) | h is a lift of some diffeomorphism hk ∈ Hk } Each diffeomorphism hk of Hk can be lifted to a diffeomorphism of N : The diffeomorphism Ak is the limit of the sequence Φk (gn,k ), we consider the sequence {Φ(gn,k )} that consist of lifts of Φk (gn,k ), by Lemma 2.1 this sequence has a convergent subsequence converging to CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 37 a diffeomorphism A0k of N which is necessarily a lift of Ak . Observe that in fact Ĥk is a finite subgroup of Diffc (N ) and that Ĥk−1 ⊂ Ĥk , being this last inclusion strict. S We define the group Ĥ := k≥0 Ĥk . Observe that Ĥ is necessarily an infinite group. We will prove that Ĥ is invariant under a Riemannian metric on N in a similar way that we prove Lemma 2.1. In order to do that, we will show the following bounds: Lemma 5.8. Every h ∈ Ĥ satisfies the following bounds: (1) khkr ≤ Cr for every r ≥ 1. (2) kD(h)k ≤ C. For the constants C, Cr in Lemma 2.12 Proof. We will prove by induction in k that for every h ∈ Ĥk , there exists a sequence hn ∈ GB such that hn → Id and Φ(hn ) → h. By lemma 2.12, this is enough to show that such bounds in the derivatives hold. This statement is obvious for k = 0. Suppose it is true for j ≤ k − 1. Consider the projection homomorphism Ψ : Ĥk → Hk and observe that the kernel of Ψ is exactly Ĥk−1 . By definition Hk = hAk i. First, we will show that Ak has a lift to N belonging to Ĥk and satisfying our induction hypothesis. Consider the sequence fn,k ∈ GBk such that as n → ∞, we have that fn,k → Id and Φk (fn,k ) → Ak as in the construction of the Ak ’s. We have that for every n, the diffeomorphism Φ(fn,k ) is a lift of Φk (fn,k ) to Diffc (N ). Using Lemma 2.1, we can find a subsequence fni ,k of fn,k , such that Φ(fni ,k ) → A0k , where A0k is a diffeomorphism of N . The diffeomorphism A0k is necessarily a lift of Ak and therefore A0k belongs to Ĥk and satisfies our induction hypothesis. To finish the induction, observe that as Hk is cyclic, every element of Ĥk is a product of an element of ker(Ψ) = Ĥk−1 and a power of A0k . Therefore, to conclude that every element of Ĥk satisfies the induction hypothesis, it is enough to show that if f, g ∈ Ĥk satisfy the induction hypothesis, then f g satisfies the hypothesis too. This is easy to prove, if there exist sequences {fn }, {gn } such that fn → Id, gn → Id and CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 38 such that Φ(fn ) → f , Φ(gn ) → g, then the sequence {fn gn } satisfies that fn gn → Id and Φ(fn gn ) → f g.  To conclude the proof of Lemma 5.7, we would proceed in a similar way as we did in Lemma 2.1, we will show that Ĥ preserves a Riemannian metric g in N as follows: Take an arbitrary metric g 0 for N and average g with respect to the groups Ĥn . More precisely, consider the sequence of metrics: gn = 1 X |Ĥk | h∗ (g 0 ) h∈Hˆk Observe that gn is invariant under Ĥn . Therefore, if there is a subconvergent sequence of gn converging to a metric g, then g is invariant under Ĥ. To ensure the existence of such subconvergent subsequence using the same argument used in the proof of Lemma 2.1 taking into account the bounds obtained in Lemma 5.8. In conclusion, Ĥ is an infinite group of isometries of N . To finish the proof of Lemma 5.7, take an embedded ball B 0 ⊂ B in N disjoint from all the balls Bn and apply Lemma 5.6.   6. Questions and Remarks. 6.1. Higher dimensions. Maybe the most natural question to ask in view of Theorem 1.3 is wether it is possible to obtain a characterization of homomorphisms Φ : Diffc (M ) → Diffc (N ) in the case that dim(M ) < dim(N ). All the known homomorphisms known to the author are built from pieces, each piece coming from some natural bundles over M or over Symmk (M ) (the set of unordered k points in M ). These bundles could be products, coverings, or somewhat similar to the tangent bundle or other bundles where one has some kind of linear action in the fiber. The pieces are glued along submanifolds where the actions in both sides agree. 6.2. Lower regularity. One might expect similar results for the groups Diffrc (M ) of C r diffeomorphisms of a manifold M . Some of the techniques here might apply to such problems in the case when r ≥ 2 or r ≥ 3. One of the reasons to believe it is possible to do so is that r Diff∞ c (M ) ⊂ Diffc (M ) and therefore one might be able to show some sort of continuity for homomorphisms of the type Φ : Diff∞ c (M ) → CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 39 Diffr (M ) using Militon’s theorem. It is important to point out that Militon’s theorem might be very difficult to generalize to the C r category: One of the main steps in the proof of Militon’s Theorem uses a KAM technique and such techniques typically have a loss of regularity if r < ∞. In the topological category things seem to be much more difficult as every homeomorphim f ∈ Homeo0 (M ) is arbitrarily distorted (See [6]). 6.3. Discrete homomorphisms between Lie groups. One might also try to understand discrete homomorphisms between simple Lie groups. For example, one can show that any discrete homomorphism from SO(3) to itself is conjugate to the standard one. The same is true for SL2 (R). For SL2 (C), the situation is a little bit different, one can use a non trivial field automorphism of C, to get a homomorphism from Sl2 (C) to itself that is not conjugate to the standard one. Nonetheless, one can show that any of the homomorphism between Sl2 (C) and itself come from this construction. An observation worth mentioning is that if the homomorphism Φ is measurable, then Φ is continuous and in fact C ∞ (See [22], Ap. B.3). Therefore, a non standard homomorphism is necessarily not measurable (as in the examples for SL2 (C) described above). Other more difficult set of questions related to the Zimmer program (see [7]) come from asking wether a discrete homomorphism of groups from a simple lie group G to Diffc (M ) comes from a standard embedding. For example, Matsumoto[18] shows that any action of P SL2 (R) in Diffc (S 1 ) is conjugate to the standard action. One might wonder if that is also the case for S 2 and P SL3 (R): 6.3.1. Question. Does every homomorphism Φ : P SL3 (R) → Diff(S 2 ) is conjugate to the standard embedding? Using the fact that P SL2 (C) acts in S 2 and SO(3) ⊂ P SL2 (C) one can compose the action of P SL2 (C) by a non trivial field automorphism of C to obtain a non standard action of SO(3) in S 2 , nonetheless one can still ask if the following is true in the volume preserving setting: 6.3.2. Question. Does there exist a homomorphism Φ : SO(3) → Diffµ (S 2 ) that is not conjugate to the standard one? CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 40 For this type of questions, the technique used here does not seem to work as the distortion elements in any linear group are at most exponentially distorted. Nevertheless, studying the distorted elements involved might give some useful information. 6.4. Distortion elements in groups of diffeomorphisms. It is worth pointing out that Militon’s theorem implies that if M is a closed manifold and f is an infinite order isometry on M then f is arbitrarily distorted. The converse to this statement is not true, there are examples of diffeomorphisms f in Diffc (M ) that are not isometries but are still recurrent (f is recurrent if satisfies lim inf n dC ∞ (f n , Id) = 0) and therefore arbitrarily distorted as a consequence of Militon’s theorem. Some of these examples can be constructed using the Anosov-Katok method. For example, one can use the construction in [14] to obtain such examples. 6.4.1. Question. Is it possible to obtain a classification of all possible distorted (or arbitrarily distorted as defined in [6]) elements in Diffc (S 1 ) or Diffc (S 2 )? This might be useful to show that certain discrete groups can’t act by diffeomorphisms on S 1 and S 2 . References [1] Gregory Arone and Marja Kankaanrinta, On the functoriality of the blowup construction Bull. Belg. Math. Soc. Simon Stevin Volume 17, Number 5 (2010), 821-832. [2] J. Aramayona, J. Souto Rigidity phenomena in mapping class groups. [3] A. Avila, Distortion elements in Diffc (R/Z) arXiv:0808.2334 [math.DS], 2008. [4] A. Banyaga, The structure of classical diffeomorphism groups. [5] Kenneth Brown, Cohomology of groups Graduate Texts in Mathematics 87, Springer Verlag, ISBN 0-387-90688-6, MR 0672956 [6] Danny Calegari, Michael H Freedman, Distortion in transformation groups. arXiv:math/0509701 [math.DS], 2005. [7] David Fisher, Groups acting on manifolds: around the Zimmer program arXiv:0809.4849 [math.DS], 2008. [8] R. P. Filipkiewicz (1982). Isomorphisms between diffeomorphism groups. Ergodic Theory and Dynamical Systems, 2, pp 159-171. [9] John Franks, Distortion in groups of circle and surface diffeomorphisms. arXiv:0705.4054 [math.DS], 2006. [10] John Franks, Michael Handel, Distortion Elements in group actions on surfaces. arXiv:math/0404532v2 [math.DS], 2004. [11] R. P. Filipkiewicz (1982). Isomorphisms between diffeomorphism groups. Ergodic Theory and Dynamical Systems, 2, pp 159-171. CONTINUITY OF HOMOMORPHISMS OF DIFFEOMORPHISM GROUPS 41 [12] E. Ghys, Prolongements des diffomorphismes de la sphre. Enseign. . Math. (2) 37 (1991), no. 1-2, 45-59. [13] M. Gromov Asymptotic invariants of infinite groups. Geometric group theory. Volume 2 Cambridge Univ. Press, Cambridge(1993), 1-295 [14] M.R. Herman, construction of some curious diffeomorphisms of the Riemann sphere Math. Soc. (2) 34(1986), 375-384 [15] Hirsch, Morris W. Differential topology. Vol. 33. New York: Springer-verlag, 1976. [16] Peter Kronheimer and Tomasz Mrowka, Monopoles and three-manifolds New Mathematical Monographs, 10, Cambridge University Press. 2007. [17] Kathryn Mann, Homomorphisms between diffeomorphism groups. arXiv:1206.1196 [math.GT], 2012. [18] Shigenori Matsumoto, Numerical invariants for semiconjugacy of homeomorphisms of the circle Proc. Amer. Math. Soc. 98 (1986), 163-168 [19] Emmanuel Militon, lments de distorsion du groupe des diffomorphismes isotopes l’identit d’une varit compacte. arXiv:1005.1765 [math.DS], 2012. [20] D. Montgomery and L. Zippin, Topological transformation groups. Wiley(Interscience), New York. 1955. [21] Kiran Parkhe, Smooth gluing of group actions and applications arXiv:1210.2325 [math.DS] 2012. [22] Robert J. Zimmer, Ergodic theory and semisimple groups University of California, Berkeley, USA E-mail address: [email protected]
4math.GR
Probabilistic Plan Synthesis for Coupled Multi-Agent Systems ⋆ Alexandros Nikou ∗ Jana Tumova ∗∗ Dimos V. Dimarogonas ∗ arXiv:1704.01432v2 [cs.SY] 7 May 2017 ∗ ACCESS Linnaeus Center, School of Electrical Engineering and KTH Center for Autonomous Systems, KTH Royal Institute of Technology, SE-100 44, Stockholm, Sweden. E-mail: {anikou, dimos}@kth.se ∗∗ School of Computer Science and Communication, KTH Royal Institute of Technology, SE-100 44, Stockholm, Sweden. E-mail: {tumova}@kth.se Abstract: This paper presents a fully automated procedure for controller synthesis for multiagent systems under the presence of uncertainties. We model the motion of each of the N agents in the environment as a Markov Decision Process (MDP) and we assign to each agent one individual high-level formula given in Probabilistic Computational Tree Logic (PCTL). Each agent may need to collaborate with other agents in order to achieve a task. The collaboration is imposed by sharing actions between the agents. We aim to design local control policies such that each agent satisfies its individual PCTL formula. The proposed algorithm builds on clustering the agents, MDP products construction and controller policies design. We show that our approach has better computational complexity than the centralized case, which traditionally suffers from very high computational demands. Keywords: Multi-Agent Systems, Cooperative Systems, Reachability Analysis, Verification and Abstraction of Hybrid Systems. 1. INTRODUCTION Cooperative control of multi-agent systems has traditionally focused on designing distributed control laws in order to achieve global tasks such as consensus, formation control, network connectivity and collision avoidance. Over the last few years, the field of control of multi-agent systems under high-level task specifications has been gaining attention. In this work, we aim to impose specific probability bounds to each robot in order to satisfy one specification task formula. Such formulas can be “The probability of a robot to periodically survey regions A, B, C, avoid region D is always more than 0.9”, or “The probability of a robot to visit regions A, B, C, in this order is more that 0.8”. Temporal properties for multi-agent plan synthesis under Linear Temporal Logic (LTL) formulas has been considered e.g., in [Guo and Dimarogonas, 2013, 2015, Ulusoy et al., 2013, Kantaros and Zavlanos, 2016]. Timed temporal properties given in Metric Temporal Logic (MTL) and Metric Interval Temporal Logic (MITL) have been addressed in [Quottrup et al., 2004, Karaman and Frazzoli, 2008, Nikou et al., 2016, 2017b,a] respectively. Most of the existing formal synthesis frameworks are based on the discretization of the agent’s motion in a partitioned environment to a finite Transition System (TS) (the pro⋆ This work was supported by the H2020 ERC Starting Grant BUCOPHSYS, the Swedish Research Council (VR), the Swedish Foundation for Strategic Research (SSF) and the Knut och Alice Wallenberg Foundation. cess is called abstraction) under the following assumptions. First, the measurements of the current state are accurate. Second, the transition system is either purely deterministic (namely, each control action enables a unique transition) or purely nondeterministic (namely, each control action enable multiple transitions). However, in realistic applications of robotic systems, noisy sensors and actuators can cause both of the aforementioned assumptions to fail. Motivated by this, we aim to model the multi-agent system in a probabilistic way such that the above issues are taken into consideration. Some recent works model the system in a probabilistic way and imposes high-level specifications, given in Linear Temporal Logic (see e.g., [Ding et al., 2011, Wolff et al., 2012, Ding et al., 2014, Fu et al., 2015, Wang et al., 2015]). In [Montana et al., 2016], the authors modeled the system with an MDP and computed policies such that the satisfaction of a formula given in MITL, is maximized. Other works model the system in a probabilistic way with Markov Decision Processes (MDPs) and introduce high-level tasks in PCTL (see e.g., [Ayala et al., 2011, Lahijanian et al., 2012, Wu and Lin, 2015, 2016]). However, all these works are restricted to single agent planning and they are not expendable to multi-agent systems in a straightforward way since in the multi-agent case potential couplings may occur among the agents. By extending these works to multi-agent systems, in order to develop an approach in which the system noise, model errors and external disturbances is explicitly considered, in this work we consider that each agent is modeled as a MDP and the task specifications are given in PCTL formulas. Motivated by the fact that in real applications, the agents (robots) are required to collaborate with each other to perform a task, we assume that there are agents in the system that are dependent to each other. They need to communicate, collaborate through sharing a common action in order to achieve a desired task. The main contribution of the paper is to develop a strategy for controlling a general framework of N individual MDPs with respect to individual agents’ specifications given in PCTL formulas. The proposed solution can handle the dependencies between the agents by considering agents clustering and MDP product construction and has provably better complexity than the centralized approach. When applied to robotic systems, our approach provides a framework for multi-robot control from temporal logic specifications with probabilistic guarantees. To the best of the authors’ knowledge this is the first work that addresses the cooperative task planning for multi-agent systems under probabilistic temporal logic specifications in the presence of dependencies between the agents. The paper is divided into five parts. In Section 2, notation and preliminaries are given. Section 3 provides the modeling of the system and the problem statement. Section 4 provides the technical details of the solution. Finally, conclusions and future work directions are discussed in Section 5. 2. NOTATION AND PRELIMINARIES In this section, the mathematical notation and preliminary definitions from probabilistic model checking that are necessary for this paper are introduced. Denote by N the set of natural numbers. Given a set S, denote by |S| its cardinality and by 2S the set of all its N subsets. Denote by Si = S1 × . . . × SN × i=1 the n-th fold Cartesian product of the sets S1 , . . . , SN . An atomic proposition χ is a statement that is either True (⊤) or False (⊥). 2.1 Markov Decision Processes MDPs offer a mathematical framework for modeling systems with stochastic dynamics. These models provide an effective way for describing processes in which sequential decision making is required for a system. Definition 1. A probability distribution over P a countable set S is a function σ : S → [0, 1] satisfying s∈S σ(s) = 1. Define by Σ(S) the set of all probability distributions over the set S. Definition 2. A Discrete Time Markov Chain (DTMC) D is a tuple (S, s0 , P ) where: S is a finite set of states; s0 ∈ S is the initial state; P : S × S → [0, 1] is the transition P probability matrix where for all s ∈ S it holds that s′ ∈S P (s, s′ ) = 1. Definition 3. A Markov Decision Process (MDP) M is a tuple (S, s0 , Act, T ) where: S is a finite set of states; s0 ∈ S is the initial state; Act is a finite set of actions (controls); T : S → 2Act×Σ(S) is the transition probability function. Denote by A(s) the set of all actions that are available at the state s ∈ S and let δ(s, α, s′ ) ∈ [0, 1] be the probability of transitioning from the state s to the state s′ under the action α ∈ A(s). For a state s ∈ S and an action α ∈ A(s), define the set Post(s, α) = {s′ ∈ S : δ(s, α, s′ ) > 0}. The transition probability function T can be represented P|S|−1 as a matrix with i=0 |A(si )| rows and |S| columns. An execution of an MPD is represented by a path. Formally, an infinite path r is a sequence of states of the form: αk−1 αk α1 α0 . . . −→ sk −→ sk+1 . . . , such that s1 −→ r = s0 −→ sk ∈ Sk , αk ∈ A(sk ) and δ(sk , αk+1 , sk+1 ) > 0, ∀k ≥ 0. A αn−1 α1 α0 . . . −→ sn is a prefix of an s1 −→ finite path ρ = s0 −→ infinite path ending in a state. In case of the actions are not taken into consideration, the infinite and finite run can be written as r = s1 s2 . . . sn . . . and ρ = s1 s2 . . . sn respectively. Denote by |ρ| = n the length of the finite path and by r(k), ρ(k) the k-th element of the paths r, ρ respectively. The set of all finite and infinite paths are defined by F P ath and IP ath respectively. A control policy at each state of an MDP and is formally defined as follows: Definition 4. (Control Policy) A control policy µ : F P ath → Act of an MDP model M is a function mapping a finite αn−1 α1 α0 . . . −→ sn , of M onto an action s1 −→ path ρ = s0 −→ in A(sn ) and specifies for every finite path, the next action to be enabled. If a control policy depends only on the last state of the finite path ρ, then it is called a stationary policy. Denote by M the set of all control policies. Under a control policy µ ∈ M , an MDP becomes a DTMC Dµ (see Def. 2). Let IP athµ ⊆ IP ath and F P athµ ⊆ F P ath denote the set of infinite and finite paths that can be produced under the control policy µ. For each policy µ ∈ M , a probability measure P robµ over the set of all paths (under the control policy µ) IP athµ is induced. A probability measure P robfµin over the set of paths F P athµ for a finite path ρ, is defined as: P robfµin (ρ) = 1, if |ρ| = 0 and P robfµin (ρ) = P (s0 , s1 )P (s1 , s2 ) . . . P (sn−1 , sn ), otherwise, where P (sk , sk+1 ), k ≥ 0 are the corresponding transition probabilities in Dµ . Define also the set of all infinite paths with prefix ρ as: C(ρ) = {r ∈ IP athµ : ρ is a prefix of r}. By invoking theorems from probability theory [Rutten et al., 2004], we have that: P robµ (C(ρ)) = P robfµin (ρ), ∀ρ ∈ F P athµ . where P robfµin (ρ) as is defined previously. 2.2 Probabilistic Computational Tree Logic (PCTL) Probabilistic Computational Tree Logic (PCTL) [Hansson and Jonsson, 1994] is used to express properties of MDPs. PCTL formulas can be recursively defined as follows: ϕ := ⊤ | χ | ¬ϕ | ϕ1 ∧ ϕ2 | P⊲⊳p [ψ], (state f ormulas) ψ := ϕ | ϕ1 U ≤k ϕ2 , (path f ormulas) where χ ∈ Act is an action, ⊲⊳= {<, >, ≤, ≥}, p ∈ [0, 1] and k ∈ N ∪ {∞}. In the syntax above, we distinguish between state formulas ϕ and path formulas ψ, which are evaluated over states and paths, respectively. A property of a model will always be expressed as a state formula; path formulas only occur as the parameter of the probabilistic path operator P⊲⊳p [ψ]. Intuitively, a state s satisfies P⊲⊳p [ψ] (we write s |= P⊲⊳p [ψ]) if there exists a control policy µ under which the probability of all paths starting from s is in the range of the interval ⊲⊳ p. For path formulas, we allow the “next” ( ) operator which is true if the state formula ϕ is satisfied in the next state and the “bounded until” (U ≤k ) which is true if ϕ2 is satisfied within k steps and ϕ1 holds up until that point. The unbounded “until” operator U is the same as U ≤k as k → ∞. Definition 5. [Hansson and Jonsson, 1994] (Semantics of PCTL) For any state s ∈ S, the satisfaction relation |= is defined inductively as follows: s |= ⊤ ⇔ ∀s ∈ S, s |= χ ⇔ χ ∈ A(s), s |= ¬ϕ ⇔ s 6|= ϕ, s |= ϕ1 ∧ ϕ2 ⇔ s |= ϕ1 and s |= ϕ2 , s |= P⊲⊳p [ψ] ⇔ P robµ (s, ψ) ⊲⊳ p, where P robµ (s, ψ) denotes the probability that a path starting from the state s satisfies the path formula ψ under the specific control policy µ. Moreover, for any path r ∈ IP ath we have that: r |= ϕ ⇔ r(1) |= ϕ, r |= ϕ1 U ≤k ϕ2 ⇔ ∃ i ≤ k, r(i) |= ϕ2 ∧ r(j) |= ϕ1 ∀j < i. For the operators  (always) and ✸ (eventually) it holds that:     P⊲⊳p ✸≤k ϕ = P⊲⊳p ⊤ U ≤k ϕ ,     P⊲⊳p ≤k ϕ = P⊲⊳p ✸≤k ¬ϕ , where ⊲⊳= {<, >, ≤, ≥} and ⊲⊳ = {>, <, ≥, ≤}. Remark 1. Traditionally, the PCTL semantics are defined over a set of atomic propositions. However, in this paper, we aim to introduce dependencies over the actions among the agents. Therefore, the PCTL semantics are defined over a set of actions. 2.3 Probabilistic Verification There are three problems that have generally been considered in probabilistic model checking of stochastic systems: • (Model Checking) Given an MDP M and a property ϕ, check which of the states of the MDP M satisfy ϕ. • (Controller Synthesis): Given an MDP M and a property ϕ, find all the control policies under which the formula is satisfied. • (Existence) Given an MDP M and a property ϕ, find, if it exists, a control policy µ such that the MDP M satisfies the property ϕ under µ. In this paper, we are mainly interested in the Controller Synthesis problem. The motivation for that is the following: if one control policy fails to guarantee the satisfaction of a formula, it may exists another policy under which the formula is satisfied. We refer the reader to [Rutten et al., 2004, Bianco and Alfaro, 1995] for more details about probabilistic model checking. 3. PROBLEM FORMULATION 3.1 System Model and Abstraction Consider a multi-agent team with N ≥ 2 agents operating in the bounded workspace W ⊆ Rn . Let V = {1, . . . , N } denote the index set of the agents. The workspace W = S γℓ is partitioned using a finite number (assume W ) of ℓ∈W regions of interest γ1 , . . . , γW . Denote by γℓi the fact that the agent i is occupying the region γℓ , where i ∈ V, ℓ ∈ W. We assume that each agent is programmed with a small set of feedback control primitives, which are not completely reliable, allowing it to move inside each region and from a region to an adjacent regions. It is also assumed that the probabilities of these transitions are known. Assumption 1. We assume here that an abstraction of the dynamics of each robot into a MDP is given, and that a low level continuous time controller that allows each robot to transit from one region γℓ to an adjacent region γl with ℓ, l ∈ W, can be designed. This modeling has been also considered in [Lahijanian et al., 2012]. Definition 6. The motion of each agent i ∈ V in the workspace can be described by a Markov Decision Process (MDP) Mi = (Si , si0 , Acti , Ti ) where:  i • Si = γ1i , γ2i , . . . , γW is the set of states of agent i. The number of states for each agent is |Si | = W , meaning that Si includes all regions within W. • si0 ∈ Si is the initial state of agent i (the initial region where agent i may start). Note that the initial state is known and deterministic i.e. we know exactly the region from which each agent starts its motion. • Acti is a finite set of actions (controls). • Ti : Si → 2Acti ×Σ(Si ) is the transition probability function. Remark 2. We investigate here, under which conditions two or more agents are visiting simultaneously a specific region of the workspace. Consider the {i1 , . . . , ic } ⊆ V, c ≥ 2 agents of the multi-agent system. Let ri1 = si01 si11 si21 . . . sik1 . . . sin1 , . . . , ric = si0c si1c si2c . . . sikc . . . sinc , be the finite paths of length n that are executed by the corresponding MDPs M1 , . . . , Mc , respectively, where sjz ∈ Sz , ∀z ≥ 0, j ∈ {i1 , . . . , ic }. Then, if there exists k ≥ 1 such that for all the k-th elements of the above runs (in the same position at every path) it holds that sik1 = · · · = sikc = smeet , then we say that the agents {i1 , . . . , ic } are k visiting simultaneously the same region sk . If there does not exist such region smeet , then the agents cannot meet k simultaneously to one region. 3.2 Handshaking Actions The motivation for introducing dependencies in the multiagent system comes from real applications where more than one agents (robots) need to collaborate with each other in oder to perform a desired task. For example, imagine two aerial manipulators that are required to meet and grasp an object simultaneously and deliver it to a specific location in a warehouse. In order to be able to introduce dependencies in the actions between the agents, we write the action set of each agent as: Acti = {Πi , Π̂i }, i ∈ V, where Πi is a finite set of actions that the agent i need to execute in collaboration with other agents (handshaking actions) and Π̂i is a finite set of actions that the agent i executes independently of the other agents (independent actions). For the independent actions it holds that: Π̂i ∩ Π̂j = ∅, ∀i 6= j, i, j ∈ V. The independent actions can always be executed without any constraints. On the other hand, for the handshaking actions, we have the following requirements: • First, the agents are required to meet and occupy the same region of the workspace (not necessarily a specific region). • Once they meet, they need to execute simultaneously the same action. • All the agents that share an action are required to execute it in order for the task to be completed properly. Formally, the handshaking actions are defined as follows: Definition 7. (Handshaking Actions) Let {i1 , . . . , ic } ⊆ V, c ≥ 2 be a set of agents that need to collaborate in order to execute simultaneously a task under the action α. The following two properties should hold in order for α to be well-posed handshaking action: T (1) α ∈ i∈{i1 ,...,ic } Πi . (2) Let the following finite paths of length n: i1 i i α 1 αk−1 α 1 αn−1 αic c αik−1 α c αin−1 0 . . . −→ sik1 −→ sik1′ . . . −→ sin1 , ri1 = si01 −→ .. . 0 . . . −→ sikc −→ sikc′ . . . −→ sinc , ric = si0c −→ be executed by the MDPs Mi1 , . . . , Mic respectively. Here, sik1 , . . . , sikc are the regions that the i1 , . . . , ic should occupy in order to execute the handshaking action α simultaneously. Then, there should exist at least one k ≥ 0 such that sik1 = · · · = sikc = smeet and δ(sjk , α, sjk′ ) > 0 for at least one k j j sk′ ∈ Post(sk , α) for every j ∈ {i1 , . . . , ic }. Notice that the same condition for a state smeet as in k condition (2) was mentioned in Remark 2, but here the existence of a common action α is also required. It should be also noted that every region of the workspace in which the agents can potentially meet, can serve as a region that a handshaking action can be executed (if such an action exists). 3.3 Dependencies Suppose that one agent i receives a cooperative task that involves other agent’s j ∈ V\{i} participation. This means that both agents need to execute the same action at the same region so as for the task to be performed. The dependencies are formally defined as: Definition 8. The agents i, j ∈ V are called dependent if one the following statements holds: (1) Agent i depends on agent j if Πi ∩ Πj 6= ∅. (2) Agent i depends on agent j if Πi ∩ Πj 6= ∅. (3) There exist at least one region smeet , k ≥ 0 of the k workspace such that the second condition of Def. 7 holds. Conditions (1),(2) can be checked by comparing all the elements of the sets Πi , Πj , ∀i, j ∈ V one by one. Condition (3) can be checked by using graph search algorithms. Remark 3. It should be noticed from the above definitions that all the agents that share an action, they are required to meet and execute it simultaneously. Remark 4. Due to fact that the control policies are defined over finite paths, the handshaking actions are defined with respect to finite paths as well. Therefore, the graph search algorithm for condition (3) is searching into a finite graph. Assumption 2. It is assumed that there exists at least 2 agents that are dependent. Otherwise, there exist no dependencies between the agents and the problem that is later defined can be straightforwardly solved by solving the controller synthesis methodology of Section 4 for each agent independently. 3.4 Problem Statement We define here the problem that we aim to solve in this paper: Problem 1. Given N agents performing in the workspace W, under the Assumptions 1, 2, individual task specification formulas ϕ1 , . . . , ϕN over the actions Πi ∪ Π̂i , i ∈ V given in PCTL with semantics as in Sec. 2.2, synthesize individual control policies µ1 , . . . , µN (if there exists one) which guarantee the satisfaction of the formulas ϕ1 , . . . , ϕN respectively. 4. PROBLEM SOLUTION 4.1 Overview An overview of the proposed solution is given as follows: • Step 1: First, the dependencies among the agents are modeled as a dependency graph (see Section 4.2). The agents are split into clusters and each cluster contains the agents that are dependent according to Def. 8. • Step 2: For each cluster of agents, the mutual specifif are defined (see cation ϕm and the product MDP M Section 4.3). • Step 3: By utilizing the controller synthesis algorithms of Section 4.6, we design a control policy µ e of each cluster that guarantees the satisfaction of ϕm (if such a control policy exists). We provide in Sec. 4.4 the definition of successful control policies, which project onto local control policies µ1 , . . . , µN for each agent, which finally are a solution to Problem 1. An algorithm describing all the steps of the proposed procedure is given in Section 4.5. Probabilistic model checking algorithms, which can compute all the control policies under which a PCTL formula ϕm is satisfied, are presented in Section 4.6. The computational complexity of the proposed framework is discussed in Section 4.7. Problem 1 can be solved in a centralized way by computing the product of all individual MDPs Mi , i ∈ V (see Definition 12) and perform the proposed methodology of this paper to the centralized system without any clustering among the agents. However, this solution leads to a high computational burden and state explosion of the product MDP M. A comparison of the computational complexity of the proposed framework that exploits the potential sparsity of dependencies with the centralized approach is discussed in Section 4.7. 4 2 C1 C2 1 3 5 6 C3 4.2 Modeling the Dependencies Based on the dependency relation of the Def. 8, the dependency graph associated with the handshaking actions Πi , i ∈ V is defined as follows: Definition 9. The dependency graph G = (V, E), is an undirected graph that consists of the set of vertices V in which each of the agents is node for the graph and the edge set E which is defined as follows: E = {{i, j} : i is dependent to j and i, j ∈ V, i 6= j}. In order to proceed, the following definition is required: Definition 10. [Mesbahi and Egerstedt, 2010] Let G = (V, E) be an undirected graph. Then every graph G ′ = (V ′ , E ′ ) with V ′ ⊆ V and E ′ ⊆ E if called a subgraph of the graph G. Definition 11. The set C = {Cℓ : ℓ ∈ M} ⊆ V, where M = {1, . . . , m}, forms a dependency cluster if and only if ∀i, j ∈ C there is a path from node i to node j in the dependency graph G. Define the function f : V → M which maps each agent to the index ofS the cluster that P it belongs to. It can be observed that ℓ∈M Cℓ = V and ℓ∈M |Cℓ | = |V| = N . Each agent i ∈ V for which there exist no j ∈ V such that j ∈ Cf (i) will be called an independent agent. For an independent agent it holds that |Cf (i) | = 1. From Definition 11, it follows that every dependency cluster Cℓ ∈ C, ℓ ∈ M is the vertex set of the subgraphs G(ℓ) = (Cℓ , Eℓ ), Eℓ ⊆ E, ℓ ∈ M of the system graph G. Loosely speaking, two agents belong to the same cluster when they are directly dependent or transitively dependent by a dependency chain. An example of a dependency graph and dependency clusters is given as follows: Example 1. Consider N = 6 agents with V = {1, . . . , 6}, E = {{1, 2}, {3, 4}, {4, 5}}. The m = 3 clusters are given as: C1 = {1, 2}, C2 = {3, 4, 5} and C3 = {6} and the corresponding subgraphs G (1) = (C1 , E1 = {1, 2}), G (2) = (C2 , E2 = {{3, 4}, {4, 5}}) and G (3) = (C3 , E3 = ∅). Moreover, f (1) = f (2) = 1, f (3) = f (4) = f (5) = 2, f (6) = 3. The dependency graph is depicted in Fig. 1. According to the mathematical derivation above, Assumption 2 is modified as follows: Assumption 3. There exists at least one dependency cluster Cℓ , ℓ ∈ M (as was defined in Definition 11) of the dependency graph G of the under consideration multi-agent Fig. 1. An example of a dependency graph G = (V, E) and its subgraphs for N = 6 agents. system, which contains at least two dependent agents. I.e., there exists ℓ ∈ M such that: |Cℓ | = 2, if N = 2 and |Cℓ | ∈ [2, N − 1], if N > 2. By employing the above computation, the initial multiagent system is modeled as m subgraphs G ℓ , ℓ ∈ M which capture the dependencies between the agents, as they are defined in Def. 8. This forms a convenient modeling of the system’s dependencies in order to compute the product MDP of every subsystem ℓ ∈ M in the next Section. 4.3 Product Markov Decision Process Define here the mutual specification of a cluster of agents Cℓ as: ^ ϕℓm = ϕi , ℓ ∈ M, (1) i∈Cℓ over the set of actions   . If the satisfaction Π ∪ Π̂ i i i∈Cℓ S of ϕℓm for each cluster Cℓ is guaranteed, it holds by definition that the satisfaction of all the individual formulas ϕi , i ∈ V is guaranteed as well. Thus, a method for finding a team control policy that guarantees the satisfaction of ϕℓm , ℓ ∈ M should be provided. In the sequel, we construct a product MDP that captures the collaborative behavior of all the agents within fℓ , allow us to synthesize a control a cluster. Having M policy µ e for Cℓ , which guarantees the satisfaction of the collaborative formula ϕℓm . Subsequently, the team control policy µ eℓ can be projected onto the local agents’ control policies µ1 , . . . , µN which are a solution to Problem 1. fℓ for Definition 12. (Product MDP) The product MDP M ℓ g e e the cluster of agents Cℓ is a tuple (Sℓ , se , Actℓ , Tℓ ) where: 0 × Si is the set of states. • seℓ0 = × si0 is the initial state. i∈C • Seℓ = i∈Cℓ ℓ o n S S g • Actℓ = i∈Cℓ Acti = i∈Cℓ Πi , Π̂i is the set of actions. f ℓ ×Σ(Seℓ ) is the transition probability • Teℓ : Seℓ → 2Act function for the product system. Similar to δ of Def. e s, α 3, we define δ(e e, se′ ) ∈ [0, 1] the probability of transitioning from the state se to the state se′ under the action α e. Let Cℓ = {i1 , . . . , i|Cℓ | } be an enumeration of the agents of the cluster Cℓ . Then, δeℓ is defined as follows: e i , . . . , si ), α, (s′ , . . . , s′ )) = (1) δ((s i1 |Cℓ | T i|Cℓ | Q 1 ′ δ (s , α, s ), if α ∈ j j j j∈Cℓ A(sj ). j∈Cℓ e si1 , si|Cℓ | ), α, (e (2) δ((e si1 , . . . , sek1 , . . . , sekν , . . . , e Q . . . , se′k1 , . . . , e s′kν , . . . , sei|Cℓ | )) = νj=1 δkj (skj , α, s′kj ) if  -  ν \ [  α∈ A(skj ) A(sz ) , j=1 z∈Cℓ \{k1 ,...,kν } for kj ∈ Cℓ , j ∈ {1, . . . , ν}. Intuitively, (1) denotes that all the agents i1 , . . . , i|Cℓ | of the cluster |Cℓ | are located in the states si1 , . . . , si|Cℓ | respectively, and they are simultaneously transiting to the states s′i1 , . . . , s′i|C | with action α. (2) denotes that ℓ among all the agents of the cluster Cℓ , only the agent {k1 , . . . , kν } ( Cℓ are transiting simultaneously to the states s′k1 , . . . , s′kν respectively. (2) can not be handshaking action since for the handshaking action all the agents of the cluster should transit simultaneously to the next state. In order for (1) to be a handshaking transition according to Def. 7 it is required also that si1 = . . . = si|Cℓ | . Remark 5. In the case of a cluster ℓ ∈ M that contains an independent agent i ∈ V with the property |Cℓ | = |Cf (i) | = fℓ coincides with the individual 1, the product MDP M f MDP Mi of Def. 6 (Mℓ ≡ Mi ). The infinite path re, the finite path ρe, the control policy µ e and the set of all infinite and finite paths F^ P ath and ^ IP ath, are defined similarly to Sec. 2.1. 4.4 Designing the Control Policies µ e fℓ , ℓ ∈ M of each cluster captures the The product MDP M paths and the control policies of the agents that belong to the same cluster and they are required to collaborate for achieving a task or acting independently. the set of actions of the agent j that are appearing in the g s et Act. The set µ e(e ρ) contains control policies that are either handshaking or independent. Let us also define the following set of handshaking actions: Succ(α, ℓ) = {α ∈ Πi1 ∩ eℓ (e ρ)}, which is the subset of µ e(e ρ) · · · ∩ Πi|Cℓ | : α ∈ µ that contains the handshaking actions. We need to search now if all the projections µij , ∀j ∈ {1, . . . , |Cℓ |} follow the handshaking rules of Def. 7. Definition 13. (Successful Control Policy) Let µ eℓ (e ρ) = g be a control policy of a cluster µ eℓ (e s0 se1 . . . sen ) ⊆ Act Cℓ . The control policy µ eℓ (e ρ) is called successful if for all α ∈ Succ(α, ℓ) it holds that sni1 = · · · = sni|C | and ℓ δ(snj , α, (snj )′ ) > 0 for at least one (snj )′ ∈ Post(snj , α), j ∈ {ii , . . . , i|Cℓ | }. o n g:M fℓ |= ϕℓ , ℓ ∈ M, denotes Let SP (ℓ) = µ eℓ (e ρ) ⊆ Act m the set of all the control policies that guarantee the satisfaction of the formula ϕℓm . All the control policies of SP needs to be checked if they are successful. If SP (ℓ) = ∅ for at least one ℓ ∈ M, then the Problem 1 has no solution. The set SP (ℓ) is computed by employing the algorithms of Section 4.6. 4.5 Proposed Algorithm The proposed procedure of solving Problem 1 can be shown in Algorithm 1. The function checkDepend() determines the dependent agents according to Def. 8. The product and projection that were introduced in Sec. 4.3, 4.4, are computed by the functions product(), projection() respectively. The algorithms of Sec. 4.6 are incorporated in the function controlSynthesis(). By employing Def. 13, the function succPolicy() determines if a sequence of control policies are successful. Remark 6. Even though our proposed solution is centralized in each cluster, it is partially decentralized in terms of the whole multi-agent system. 4.6 Algorithms for Probabilistic Control Synthesis By employing the controller synthesis algorithms (see Section 4.6), the control policies µ eℓ for the team of agents in each cluster can be designed. The algorithms can compute all the control policies µ eℓ that guarantees the satisfaction of formula ϕℓm from (1). We are investigating here algorithms of computing all the control policies µ eℓ ∈ SP (ℓ). Once these control policies are found, then by following Algorithm 1, the individual policies µj , j ∈ {i1 , . . . , i|Cℓ | } can be designed and the Problem 1 is solved (if there exists a solution). For more details about the algorithms we refer to [Rutten et al., 2004, Kwiatkowska et al., 2007, Forejt et al., 2011, Bianco and Alfaro, 1995, Lahijanian et al., 2012] Consider a cluster of agents Cℓ = {i1 , . . . , i|Cℓ | }. A g for the control policy µ eℓ (e ρ) = µ eℓ (e s0 se1 . . . sen ) ⊆ Act finite path ρe = se0 se1 . . . sen of length n, where sek = (ski1 , . . . , ski|C | ), k ∈ {1, . . . , n}, projects onto the local inℓ dividual control policies µj (s1j , . . . , snj ), j ∈ {i1 , . . . , i|Cℓ | }, of the agents {i1 , . . . , i|Cℓ | } of the cluster Cℓ , ℓ ∈ M. Note First, define Sat(ϕℓm ) = {s ∈ S : s |= ϕℓm } as the set of states that satisfy ϕℓm . Then we have: Sat(⊤) = S, Sat(π) = {s ∈ S : π ∈ A(s)}, Sat(¬ϕℓm ) = S\Sat(ϕℓm ), Sat(ϕℓm,1 ∧ ϕℓm,2 ) = Sat(ϕℓm,1 ) ∩ Sat(ϕℓm,2 ) for two PCTL formulas ϕℓm,1 , ϕℓm,2 . Define also the minimum and the maximum probabilities of satisfying the formula under the control policy µ for a starting state s: P robmax (s, ψ) = sup {P robµ (s, ψ)}, (2a) What remains is to project these policies onto the individual control policies of the agents of each cluster in such a way that they serve as a solution to Problem 1. g that: µj ⊆ Act j g ⊆ Actj , j ∈ {i1 , . . . , i|Cℓ | }, and Act is j µ∈M P robmin (s, ψ) = inf {P robµ (s, ψ)}. µ∈M (2b) Algorithm 1 - SolveProblem1(·) 1: Input: MDPs: M1 , . . . , MN ; 2: PCTL Formulas: ϕ1 , . . . , ϕN 3: Output: µ1 , . . . , µN 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: C = {CVℓ , ℓ ∈ M} = checkDepend(Act1 , . . . , ActN ) ϕℓm = i∈Cℓ ϕi for z ∈ Cℓ = {i1 , . . . , i|Cℓ |} do fℓ = product({Mj , j ∈ Cℓ }) M f, ϕℓ ) SP (ℓ) = controlSynthesis(M m for µ eℓ ∈ SP (ℓ) do fℓ ) {µ1 , . . . , µN } = projection(M if succPolicy({µ1 , . . . , µN }) = ⊤ then solFound = 1 return {µ1 , . . . , µN } ⊲ Solution found else go to 12 ⊲ Search other control policies end if end for if solFound 6= 1 then Problem 1 has no solution end if end for where M is set of all control policies. It has been proved in [Bianco and Alfaro, 1995], that the model checking problem problem of the operator P⊲⊳p [ψ] can be reduced to the computation of (2a), (2b) according to the following: • If ⊲⊳ = {≥, >} then s |= P⊲⊳p [ψ] ⇔ P robmin (s, ψ) ⊲⊳ p. (3) • If ⊲⊳ = {≤, <} then s |= P⊲⊳p [ψ] ⇔ P robmax (s, ψ) ⊲⊳ p. (4) For the controller synthesis (as was defined in Section 2.3) of the path operators P⊲⊳p [ ϕℓm ], P⊲⊳p [ϕℓm U ≤k ϕℓm ], we utilize the Algorithms 2,3 respectively as follows: Algorithm 2 If the formula is ϕℓm = P⊲⊳p [ ϕℓm,1 ], initially the maximum probability of satisfying ϕℓm at the state s ∈ S:   X δ(s, α, s′ ) , (5) P robmax (s, ϕℓm ) = max  α∈A(s) s′ ∈Sat(ϕℓm,1 ) is computed for every s ∈ S. By replacing max with min in (5), P robmin (s, ϕℓm,1 ) can be computed. Define the vector Φ(s) = 1, if s ∈ Sat(ϕℓm,1 ) or Φ(s) = 0, otherwise. Perform now the matrix multiplication X = T · Φ. X is a vector whose entries are the probabilities of satisfying ϕ1 , where each row corresponds to a state-action pair. After obtaining the vector X, eliminate the state-actions pairs whose probabilities are not in the range of ⊲⊳ p by taking into consideration the conditions (3), (4). This operation determines all the states s ∈ S and all the actions µ ∈ M that satisfy the formula ϕℓm . Algorithm 3 For  the formula of the form φℓm =  P⊲⊳p ϕℓm,1 U ≤k ϕℓm,2 , define by S yes = Sat(ϕℓm,2 ), S no =   S\ Sat(ϕℓm,1 ) ∪ Sat(ϕℓm,2 ) , and S rem = S\(S yes ∪ S no ) the states that always satisfy the specification, the states that never satisfy the specification and the remaining states, respectively. Compute the maximum probability of satisfying ϕℓm at the state s ∈ S as: P robmax (s, ϕℓm ) = 1 or 0, if s ∈ S yes or s ∈ S no respectively. For s ∈ s ∈ S rem and k ≥ 0 compute recursively the following: P robmax (s, ϕℓm , k) X = max δ(s, α, s′ )P robmax (s, ϕℓm , k − 1) α∈A(s) s′ ∈S rem + X ′ ! δ(s, α, s ) , s′ ∈S yes (6) with P robmax (s, ϕℓm , 0) = 0. The computation can be carried out in k iterations, each similar to the process of Algorithm 2. By replacing max with min in (6), P robmin (s, ϕℓm , k) can be computed.   Algorithm 4 The form φℓm = P⊲⊳p ϕℓm,1 U ϕℓm,2 is in   fact the same as φℓm = P⊲⊳p ϕℓm,1 U ≤k ϕℓm,2 as k → ∞. With this approach, Algorithm 3 can be used to solve this problem. Remark 7. The resulting control strategies of the aforementioned algorithms are stationary. Therefore, the control policies µ eℓ (e s1 se2 . . . sen ) depend only to the state sen . 4.7 Computational Complexity According to [Baier et al., 2008], the model checking of an MDP M is polynomial in the number of states of M and linear in the length of the formula ϕ. Denote by |ϕ| the length of the formula ϕ in terms of the number of the operator it has e.g., |P≥0.5 [ {red}]| = 2 . The complexity can be expressed mathematically as O(poly(|M|)|ϕ|κ(ϕ)), where κ(ϕ) = max{k : φ1 U ≤k ϕ2 }, ϕ1 , ϕ2 are subformulas of ϕ and ϕ1 U ≤k ϕ2 are possible until operators involving in ϕ. Define also poly(n) = 2O(log(n)) . If ϕ does not contain a bounded until operator then κ(ϕ) = 1. The number of states of the the product MDP in the Q N e = and the centralized solution is |S| i∈V |Si | = W corresponding complexity is in the class of   O = O 2O(N log(W )) · |ϕℓm | · κ(ϕℓm ) , where ϕℓm as it is defined in (1) for |Cℓ | = N . The worst case complexity of the proposed framework is when 1 agent is independent and the other N − 1 agents are dependent to each other. Then, there are two clusters ℓ ∈ {1, 2}: the first contains the independent agent and the other one contains the remaining agents. The Si | = W |Cℓ | , ℓ ∈ corresponding MDPs have |Seℓ | = | × i∈Cℓ {1, 2} states i.e., W, W N −1 states respectively. Thus, the worst case complexity of our framework is:  e = O 2O(log(W )) · |ϕ1 | · κ(ϕ1 ) O m m  O((N −1) log(W )) 2 2 +2 · |ϕm | · κ(ϕm ) . (7) The best case complexity of the proposed framework is when every agent is dependent to at most one other agent. Formally, if N is odd number then |Cℓ′ | = 1 for only one ℓ′ ∈ M and |Cℓ | = 2, ∀ℓ ∈ M\{ℓ′ }. In this case, the best case complexity is in the class:  X [2O((N −1) log(W )) · |ϕℓm | · κ(ϕℓm )] Ō = O ℓ∈M\{ℓ′ } +2 O(log(W )) · ′ |ϕℓm | ·  ′ κ(ϕℓm ) . If N is even number, then previous summation in performed in all the elements ℓ ∈ M. In total, it holds that: e < O which verifies that our proposed frameŌ < O work achieves significantly better computational complexity than the centralized one. 5. CONCLUSIONS AND FUTURE WORK We have proposed a systematic method for designing control policies for multi-agent systems. We assume that the system is under the presence of model uncertainties and actuation failures, thus the modeling is performed through MDPs. The agents are divided into dependency clusters which indicate the team of agents that they need to share an action in order to achieve a desired task. With the proposed framework, each agent is guaranteed to perform a task given in PCTL formulas. The computational complexity of the proposed framework is significantly better than the complexity of the centralized framework. Future efforts will be devoted towards performing the abstraction of the stochastic system which is given according to Assumption 1. REFERENCES Ayala, A., Andersson, S., and Belta, C. (2011). Temporal Logic Control in Dynamic Environments with Probabilistic Satisfaction Guarantees. IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS). Baier, C., Katoen, J., and Larsen, K.G. (2008). Principles of model checking. MIT Press. Bianco, A. and Alfaro, L. (1995). Model Checking of Probabilistic and Nondeterministic Systems. International Conference on Foundations of Software Technology and Theoretical Computer Science. Ding, X., Smith, S., Belta, C., and Rus, D. (2011). LTL Control in Uncertain Environments with Probabilistic Satisfaction Guarantees. 18th World Congress of the International Federation of Automatic Control (IFAC WC). Ding, X., Smith, S., Belta, C., and Rus, D. (2014). Optimal Control of Markov Decision Processes With Linear Temporal Logic Constraints. IEEE Transactions on Automatic Control (TAC). Forejt, V., Kwiatkowska, M., Norman, G., and Parker, D. (2011). Automated Verification Techniques for Probabilistic Systems. Formal Methods for Eternal Networked Software Systems. Fu, J., Han, S., and Topcu, U. (2015). Optimal control in markov decision processes via distributed optimization. 55th IEEE Conference on Decision and Control (CDC). Guo, M. and Dimarogonas, D. (2013). Reconfiguration in Motion Planning of Single-and Multi-Agent Systems Under Infeasible Local LTL Specifications. 52nd IEEE Conference on Decision and Control (CDC). Guo, M. and Dimarogonas, D. (2015). Multi-Agent Plan Reconfiguration Under Local LTL Specifications. The International Journal of Robotics Research (IJRR), 34(2), 218–235. Hansson, H. and Jonsson, B. (1994). A Logic for Reasoning about Time and Reliability. Formal Aspects of Computing. Kantaros, Y. and Zavlanos, M. (2016). A Distributed LTL-Based Approach for Intermittent Communication in Mobile Robot Networks. ACC. Karaman, S. and Frazzoli, E. (2008). Vehicle Routing Problem with Metric Temporal Logic Specifications. 47th IEEE Conference on Decision and Control (CDC 2008), 3953–3958. Kwiatkowska, M., Norman, G., and Parker, D. (2007). Stochastic Model Checking. International School on Formal Methods for the Design of Computer, Communication and Software Systems. Lahijanian, M., Andersson, S., and Belta, C. (2012). Temporal Logic Motion Planning and Control with Probabilistic Satisfaction Guarantees. IEEE Transactions on Robotics (TRO). Mesbahi, M. and Egerstedt, M. (2010). Graph Theoretic Methods in Multiagent Networks. Princeton University Press. Montana, F., Liu, J., and Dodd, T. (2016). SamplingBased Stochastic Optimal Control with metric interval temporal logic specifications. 2016 IEEE Conference on Control Applications (CCA). Nikou, A., Andersson, S., and Dimarogonas, D.D. (2017a). Control Synthesis for Multi-Agent Systems under Metric Interval Temporal Logic Specifications. 20th World Congress of the International Federation of Automatic Control (IFAC WC), Toulouse, France. Nikou, A., Boskos, D., Tumova, J., and Dimarogonas, D.D. (2017b). Cooperative Planning Synthesis for Coupled Multi-Agent Systems Under Timed Temporal Specifications. American Control Conference (ACC), Seattle, WA, USA. Nikou, A., Tumova, J., and Dimarogonas, D. (2016). Cooperative Task Planning of Multi-Agent Systems Under Timed Temporal Specifications. American Control Conference (ACC), 13–19. Quottrup, M., Bak, T., and Zamanabadi, R. (2004). MultiRobot Planning: A Timed Automata Approach. IEEE International Conference on Robotics and Automation (ICRA 2004), 5, 4417–4422. Rutten, J., Kwiatkowska, M., Norman, G., and Parker, D. (2004). Mathematical Techniques for Analyzing Concurrent and Probabilistic systems. American Mathematical Society. Ulusoy, A., Smith, S., Ding, X., Belta, C., and Rus, D. (2013). Optimality and Robustness in Multi-Robot Path Planning with Temporal Logic Constraints. The International Journal of Robotics Research, 32(8), 889– 911. Wang, J., Ding, X., Lahijanian, M., Paschalidis, I., and C. Belta, C.A. (2015). Temporal Logic Motion Control Using Actor–Critic Methods. The International Journal of Robotics Research. Wolff, E., Topcu, U., and Murray, R. (2012). Robust Control of Uncertain Markov Decision Processes with Temporal Logic Specifications. 51st IEEE Conference on Decision and Control (CDC). Wu, B. and Lin, H. (2015). Counterexample-Guided Permissive Supervisor Synthesis for Probabilistic Systems Through Learning. American Control Conference (ACC). Wu, B. and Lin, H. (2016). Counterexample-Guided Distributed Permissive Supervisor Synthesis for Probabilistic Multi-Agent Systems Through Learning. American Control Conference (ACC).
3cs.SY
A DECISION-MAKING SUPPORT SYSTEM BASED ON KNOW-HOW Kryssanov, V.V., Abramov, V.A., Fukuda*, Y., Konishi*, K. IACP, 5, Radio St., Vladivostok, 690041 Russia * TRI of JSPMI, 1-1-12 Hachiman-cho, Higashikurume-shi, Tokyo, 203 Japan [email protected] ABSTRACT The research results described are concerned with: • developing a domain modeling method and tools to provide the design and implementation of decisionmaking support systems for computer integrated manufacturing; • building a decision-making support system based on know-how and its software environment. The research is funded by NEDO, Japan. Keywords: CIM, decision-making, know-how 1. INTRODUCTION Today, one of the important problems of Computer Integrated Manufacturing (CIM) is to utilize the human experience of making decisions in a variety of professional tasks accumulated by leading manufacturers over the world, and propagate this experience by developing appropriate computer-aided support technologies. From a computer science perspective, it is crucial to create a strong theoretical foundation and build tools to acquire, analyze and synthesize the information of decision-making. Extensive researchers’ efforts have been made on understanding and formalizing the activity of decisionmaking in the manufacturing domain since the 80s. As a result, a number of systems qualified to support the activity have been developed. These systems can be naturally classified into three categories: information retrieval systems, decision support systems and expert systems. As no clear distinction between these categories can be found in the literature, we suggest that a distinction should be made based on the notions that: • an information retrieval system is a computer-based system to capture, manipulate, retrieve and transmit organized data necessary to solve a professional task according to detailed transactions defined by a user; • a decision support system is a knowledge-based information system to capture, handle and analyze information which affects or is intended to affect decisionmaking performed by people in the scope of a professional task appointed by a user; • an expert system is a knowledge-based system to be used instead of or together with a human operator to make decisions in the framework of a professional task with explanations for users. This is an informal classification of the systems dealing with decision-making in manufacturing. However, it may be helpful to realize what has already been done and how it corresponds with present and future trends of the manufacture infrastructure. It should be noted first, that information retrieval systems are currently not discussed in the literature as standalone programs but as a part of specialized CIM applications: CAD, CAM, CAPP, etc. There are many reasons for this, and the dissimilarity of manufacturing terminology can be pointed to as one. Another reason is existing retrieval systems cannot provide the freedom in formulating transactions necessary for CIM. Knowledge-based systems have been developed for manufacturing for more than twenty years. Despite many limitations in the points of applicability, integration and maintenance of the systems, research in this area is considered now as a core of computer-aided decisionmaking in CIM. At the same time, expert systems, which make decisions automatically, are not discussed as an inevitable component of the manufacturing environment at present (Wada, 1996). So, hereafter we will concentrate on decision support systems as well as interactive expert systems, referring to them as DSS. A further distinction needs to be drawn between stages of maturation of the support technologies for decisionmaking. We will argue here that any idea concerning the technologies, to be successfully put into practice, should have an adequate embodiment on each of these three levels of problem awareness: 1) formal specification, 2) design, 3) implementation and maintenance. To apply a formal specification technique to decisionmaking means to use a formal method having a rigorous mathematical basis and capable of modeling the domain in general, specifying the domain professional tasks and representing the domain knowledge as well. The formal method is to provide decision support applications design with the highest integrity, reliability and compatibility. On the stage of design, it is necessary to explicate the mathematical and program content of the technology. Taking the characteristics, which a user expects to witness in dealing with a DSS for a basis, functionality and behavior of the DSS and its software environment are decided. Implementation and maintenance of a decision-making support technology assumes implementation of a DSS as well as the systems to ensure the functions of updating, verification, validation and integration with external applications of the DSS which are necessary. An overwhelming majority of research reported in the literature has been on the detailed design of decision support systems, whereas formal specification of the problem has still been a difficult and expensive task. Few projects have been brought to the stage of implementation and maintenance, and no attempts have been published to give a description of a support technology for decisionmaking in CIM for all of the above levels of problem awareness. The focus of this paper is on a scientific method for developing and maintaining Decision Support Systems as essential components of CIM. In the following section, we formulate the scope and necessary assumptions of the method. In Section 3, an approach to modeling the domain and specifying the domain tasks is outlined. Then we discuss some aspects of the information representation technique. A view of the decision-making process and a software environment to support decision-making technologies are presented in Section 5. Next, the suggested method is extended to the case of utilizing empirical know-how. Section 7 gives an account of an experiment resulting in a DSS and its software environment. Finally, in Section 8, we discuss related work and draw some conclusions from our experiences. 2. STARTING POINTS Despite the fact that no universal approach to decisionmaking in CIM exists at present, a number of instances of success using various knowledge-based and algorithm techniques of making decisions for domain tasks can be found in the literature. As specification of the input and output of the task to be solved with a particular method is still necessary to develop a DSS, these instances might be considered as the knowledge (or metaknowledge) of how it is possible to get desired information under the conditions. Such interpretation makes the knowledge-based approach more fundamental. However, the problem is how to integrate the methods, qualitative as well as quantitative, within one DSS. We guess, that a basis for such integration can be a mapping of the domain professional activity onto a unified information structure, i.e., a domain model. We will consider that the domain is characterized by the professional activity that consists in solving different tasks (or else we will have to think about a DSS owning encyclopedic knowledge). Solving a task takes place in the domain reality, requires professional knowledge, and affects a set of domain objects, both physical and conceptual. We will assume that the domain reality can be thought of as a potentially infinite set of separated situations, where each situation corresponds to a DSS run made to solve a professional task. Rejecting this hypothesis leads us to the conception of real-time systems that is out of the scope of this paper. The situations are not linked to one another. This assertion causes the discrete updating of the knowledge for a DSS. Each of the situations is defined on a finite set of domain objects, that means time and space frames of a situation as well as human ability to recognize a finite set of objects within a professional task. The professional knowledge is how people use the domain objects to solve the task when the information about the objects is used as the input, output and intermediate data. This knowledge, the input data and the output data for every task can be represented verbally. The latest assumption is always true for input and output data (if not, decision-making support becomes meaningless), but it does not interdict implicit or tacit knowledge to be used. 3. THE FORMALISM Let us introduce the necessary notions. Definition 1. An S -sorted set A is a family of sets As , one for each sort s ∈ S : A = {As s ∈ S }.  Definition 2. A many-sorted signature is a couple S , Σ , where S is the sort set, Σ is an S * × S -sorted family {Σ } a ∈ S * , s ∈ S of symbols, and every symbol a ,s σ ∈ Σ a,s has arity a and sort s .  Definition 3. An algebra  of a many-sorted signature S , Σ is a finite family A = {As s ∈ S } of sets called the carriers of  , conjointly with a mapping Aσ :Aa → As for each σ ∈ Σ a, s , where Aa = As1 × × Asn   when a = s1 sn .  Let X Σ be a signature Σ with a finite set of variables X such that Σ = n  Σi , i =0 n > 0 , Σi Σ j i≠ j = ∅ , and Σ i is a many-sorted signature with the sort set S = {O, F , P}, here O, F and P are respectively objective, functional and predicate sorts; X = {X s s ∈ S } is disjointed from Σ . Now we introduce a declarative model for representing the domain as the following. Definition 4. A domain model Μ n of n-th order with the signature X Σ is a tuple Μ n = Λ,Φ such that Λ= n =1; {  ,  ,  ,  } for 0 i i = 0, 2, 3,  2 n n > 1 , and Λ = {  } for 0 Σi , , n . The carriers A i of the algebra  i , i > 1 , is an algebra of the signature follow the condition: Σ O0 ⊂ A 2 , Σ i −1 ⊂ Ai and A i ⊂ Ai +1 when i = 2, , n . There are partial mappings Aσ : B → C  when σ ∈ΣF , Aσ : B → D when σ ∈ΣP , and Aσ : D → C when σ ∈ Σ O . Here B is a Cartesian multiplication of nonempty subsets of Ai , C is a nonempty subset of Ai , D is a one-point set. Φ is a finite set of quantifier-free logical formulas involving variables of X . These formulas are written in a predicate calculus language defined on Σ .†  The predicate calculus language is of the languages based on higher order logics (in general case) where terms and formulas can be in the form: x (k ) (t1 , , t m ) , here   (k ) x ∈ X is a variable, t1 , , t m are terms, 1 ≤ k ≤ n is the order of the variable. The range of values of x (k ) is a subset of A 0 if k = 1 , and a subset of A k for k > 1 . We will call an S -sorted { } function R i = Rs : Z si → Asi Z si ⊂ X s , s ∈ S , i > 0 , as an assignment of values in Ai to variables in a variable set X. Definition 5. An algebra  1 of the signature Σ1 such that Σ 0O ⊂ A1 and A1 ⊂ A 2 is a solution for the model Μ n iff every formula entering Φ is true for all the possible R i , i = 1, , n .   It is important to note that the symbols of Σ1 will be interpreted as unknowns for the model. We will specify the input data and conditions of a domain professional task in terms of Σ 0 Σ1 (including at least one symbol of Σ1 ), the output data – in terms of Σ1 , and the optimization criterion for the task – as a predicate defined on  1 . More details of this formalism can be found in Kleshchev, et al., (1996).  4. INFORMATION REPRESENTATION To consider computer-aided decision-making support based on the domain model, we need to formulate the main principles for mapping the domain information onto the logical structure described above. Let us define an abstract set of domain objects such that: a) all of the domain objects in the set, i.e., the instances have the same identifying attributes, b) all the instances are subject to and conform to the same rules. A representation of common properties of elements of such a set will be called a domain scale. Naturally, decisionmaking uses “values on the scales”, i.e., information models of the set elements, instead of domain objects. A set of domain scales retaining all the domain objects forms the domain scale system. Taxonomies, product data representation standards or the like are essentials of the domain scale system. We will regard the algebra  0 as a unified representation of the domain scale system. † This stipulates applying predicate calculus logic rather than a programming technique. It can be postulated that the information of the domain reality has a stable structure. A model of this structure is a domain ontology. We will argue that an ontology can be created with a collection of content-specified knowledge representation primitives. In general, this collection consists of object constants, relations and classes. Situation semantics (type of action, state, relationships, which are described in the situation) are organized around an object constant within the situation that is a dedicated domain object. A relation is a set of m -tuples, m > 1 , where each of the tuples links a finite set of domain objects into a sequence and represents a relationship among objects arising while solving a task. There are special types of relations called functional relations, where the last item of an m -tuple is the value of the function on the first m − 1 items of the tuple. A class is a unary relation, i.e., a set of tuples of length one. We will consider the symbols of Σ1 as designations of the primitives, which make up an ontology. Let an abstraction be a projection reducing granularity of the domain information. It can be thought of that the algebra  i , i > 0 , represents a set of facts (those are instances of how subject matter experts treat the domain objects during solving professional tasks) mapped onto abstractions of the same level. Then, the granularity is decreased from fine to coarse by increasing i . The set of formulas Φ is created by consistency constraints on  i , i = 1 n , and the formulas  determining connections between  i , i > 1 , and  1 . Making decisions involves resolving formulas of Φ . Now we define a DSS as a practical accomplishment of the domain model Μ n of the signature X Σ having a finite solution set and a collection of solving methods for specified professional tasks. Clearly, a model of a signature 0 1 2 n Σ Σ Σ and a model of a signature X Σ =Σ        = Σ  Σ  Σ    Σ Σ 0 1 2 m can have the same solution set. This condition provides the model tractability necessary during the stage of DSS design. Let Μ n be a model with  a potentially infinite set of solutions. Then, Μ n might be an information model of the whole domain reality.‡ We will argue that establishing computer-aided support for decision-making in CIM predestinates building  such that every task in the domain reality has at least one model in  . Practically, it means that there is continued updating of the domain information held by DSS. This is a reason to develop a fund of domain information (knowledge) as a global model Μ Gn with the solution set  as a unified core for decision Y support systems. Then, while the model Μ Gn is modified as ‡ However, the reader should be aware that such a model could embody no models or one or many models for a task. necessary, a DSS can utilize a part of the domain information represented in Μ Gn . The latest possible if      ,  are model realized in the DSS, and  ,  are of Μ 0 ⊆ 0 G and 1 ⊆ 1 G 1 , where 1 G 0 0 G of the  i G ( i > 1 ) onto  1 G accordingly as shown with the formulas of Φ G . This method of knowledge acquisition is a kind of “training on instances” that has several drawbacks. The main predicament is the necessity to analyze a huge amount of facts that vary on many dimensions. We suppose, that establishing an associated domain information space through the Internet would make this problem manageable. 5. DECISION-MAKING IN CIM Figure 1 presents a conceptual diagram of the decisionmaking process in the domain. As it is demonstrated in the figure, decision-making is initiated by an external inquirer (it can be a user or a system) and begun from gathering information to specify a problem (task). Then, associated information is recognized (this information can be used to refine the problem), and relevant (local) reality models are selected. The models are evolved, and possible alternatives (problem solutions) are evaluated. Next, the best solutions are chosen for the final decision. After the decision is made, the new reality is considered and, if necessary, the process is repeated under new conditions. I n q u i rer P ro b l em (ta s k) s p eci f i ca ti o n s A s s o ci a ted i n f o rm a ti o n i d en ti f i ca ti o n F o rm u l a ti n g rea l i ty m o d el s E v o l v i n g m o d el s E v a l u a ti n g p o s s i b l e a l tern a ti v es S el ecti n g b es t s o l u ti o n s a n d ta ki n g d eci s i o n Fig. 1. Decision-making process. d ecis io n G a th eri n g i n f o rm a ti o n a s s o cia ted in fo r m a tio n ch a llen g e Cor e of the Global Information Model n G . Recently, there is the researchers’ belief that capturing manufacturing ontologies has great implications for developing CIM information-based applications (Benjamin, et al, 1995). Because people, as a rule, have great difficulty articulating the knowledge associated with the subconscious and skill-based activity, elicitation of ontologies (necessarily included with such knowledge) appears to be a difficult problem. In the framework of our approach, the implicit knowledge would be represented by a wide range of domain tasks with their associated responses - the domain facts. These facts are appended to Μ Gn . And the implicit component of  would be acquired through mapping S ys te m for validation and verification  2 G  0 G S cale S ys tem B ui lder  1 G O ntol og y B ui lder ...  n G Fact Mas ter Φ Information fee dbac k analyzer G Formulas S olving Me thods Li brar y Interface I N T E R N E T Fig. 2. Support environment for decision-making. Decision-making in CIM has the same structure, however it is necessary to consider communication aspects to provide group collaboration support. The latest means, the usage of structured group decision techniques (Forgionne, 1991) via an information layer to manage shared information processing is one feasible way. We define a decision-making technology in CIM as a technique of applying DSS to make decisions for a special problem. So, as it was formulated in Section 4, to establish computer-aided support for decision-making technologies is, first, to create a unified information space and, second, to build the domain reality model. Several interactive computer information tools should be developed to deliver complete support for communication and decision-making. Being linked through the Internet, they form an application environment for DSS. Figure 2 shows the main components in the environment based on the global domain model, what the relationships are among them, and how they handle the domain information. The following systems are needed: • Scale System Builder: a tool to construct and update the domain scale system as a set of abstract data types. • Ontology Builder: a CASE system to arrange models of domain ontologies. There are three predefined symbol groups: object constants, relations and classes (see Section 4). Symbols of the groups are combined in the structure that can be completely represented within the first order logic. • Fact Master: a tool to collect and represent the domain facts. There is a knowledge representation language based on higher order logics. • System for validation and verification: a tool to check pertinency of the domain facts to the reality model and the scale system. If there is incompleteness of  0 or Σ1 , or inconsistency of 1, the system delivers the related I) a b c d e f g h ... ... ... ... ... ... ... ... Structural carbon steel ... 325∼425 ... 30 ... 9 10∼15 ... ... 3 ... 3∼7 ... 11 ... Free-cutting carbon steel 85∼325 30 12 3 3∼7 10 10∼20 ) Each string in the table establishes recommended values of peripheral rake angle (column e), end recess (f), end clearance angle (g), peripheral clearance angle (h) for an end-mill with helix angle from c and diameter from d when the end-mill is made of high-speed steel and the workpiece material is of classes pointed in a with hardness belongs to an interval from b.  SYMBOLS OF Σ 0 : End_mill_material_classification = scalar scale; End_Mill Material = structure( classification: End_mill_material_classification; hardness: HRC ); Workpiece_material_classification = scalar scale; Workpiece_material = structure( classification: Work_material_classification; … hardness: HB; … ); End_mill_type = scalar scale; End_mill = structure( type: End_mill_type; … material: End_Mill_Material; … diameter: Millimeter; helix_angle: Degree; peripheral_rake_angle: Degree; end_recess: Degree; end_clearance_angle: Degree; peripheral_clearance_angle: Degree; … ); Product = structure( … material: Workpiece_material; … ); 1 SYMBOLS OF Σ : Constant object: workpiece: Product; Classes: end_mill: End_mill; // end_mill ∈ Σ P , workpiece ∈ Σ1O 1   Σ 2  ( a: Work_material_classification × b: interval of HB × c: interval of Degree × d: Millimeter × e: interval of Degree × f: interval of Degree × g: interval of Degree × h: Degree ); //  ∈ Σ 2P ’×’ designates Cartesian power multiplication) VARIABLES: a(2): Work_material_classification; b(2): interval of HB; c(2): interval of Degree; d(2): Millimeter; e(2): interval of Degree; f(2): interval of Degree; g(2): interval of Degree; h(2): Degree; FORMULA: end_mill.type = 'Square end-mill' & end_mill.material.classification = 'High-speed steel' & Table_1(workpiece.material.classification, workpiece.material.hardness, c(2), d(2), e(2), f(2), g(2), h(2) ) & end_mill.helix_angle ∈ c(2) & end_mill.diameter = d(2) → end_mill.peripheral_rake_angle ∈ e(2) & end_mill.end_recess ∈ f(2) & end_mill.end_clearance_angle ∈ g(2) & end_mill.peripheral_clearance_angle = h(2). Fig. 3. An example of know-how formalization. information that may be used by people to modify the domain model core. • Interface: an automatic system to provide access to the global information model for CIM applications. Necessary portability and interoperability on the level of information representation models can be enabled with semantic translation by articulation axioms (Collet, et al., 1991). • Information feedback analyzer: a tool to decompose information of practical instances of taking decisions represented in terms of Σ 0  Σ1 into declarative components (new facts to be added to the domain model) and procedural components (new samples of problem solving methods to be added to the Solving Methods Library). 6. KNOW-HOW UTILIZATION It is a well-known fact, that know-how plays a significant role during decision-making by people in actual manufacturing. Generally, the knowledge of know-how can be classified into the conjectural knowledge (having mostly a procedural nature) and experimental knowledge (having largely a declarative character). The former is usually a generalization of professional skill while the latter emanates from the results of practical experiments. There are distinct difficulties in utilizing these kinds of knowledge for DSS: conjectural knowledge is intricately acquired and represented whereas empirical knowledge is hardly used. A key to solving the first problem would be gathering a representative collection of instances of treatment of a problem by subject matter experts, and then mapping the information of this collection onto the domain reality model as it was drawn in the previous sections. The experimental knowledge usually comes to be known in a form already formalized - as tables or graphs, - which is rather easy to represent in DSS. However, extremely large amounts of such know-how, their peculiar nature, and high granularity make the experimental knowledge difficult to utilize widely for application. A way to manage this problem would be to accumulate such know-how by representing them in algebras  Gi , i > 1 , and formulas of ΦG . A variety of know-how has been collected from Japanese manufacturers in this study. An example of that material is partially reproduced in Figure 3. The knowledge of the example may be accessed while selecting tools in process planning. Part (I) of the figure shows a fragment of the table containing the information about end mill edge angles recommended to prolong tool life. Part (II) summarizes how to use the information of the table, and part (III) systematically introduces elements of model Μ n which would be to add the information of the example to the model (simplifying the rather lengthy formal representation). 7. RESULTS A working approximation of the application environment described in Section 5 has been developed in the research. Prototypes of a Scale System Builder and Ontology Builder have been implemented as one software tool.§ 47 examples of know-how treated of end milling have been analyzed, and a DSS based on this know-how has been developed using the tool (see Figure 4). A reality model for the task of calculating the machining parameters has been realized in the DSS. The knowledge base of the system contains logical formulas including ten formulas with higher order predicates. Taking the characteristics of the product material and the end-mill as the input data, the system is § In our current implementation, networked communication is not provided. USER Us er I nterf ac e Scale System Builder & Ontology Builder I np u t An aly zer R eality M o del D ec is ion - m ak in g m o d ule S c ale s y s tem M o del S elec to r D atab as e F or m u la In ter pr eter F o rm ulas O u tp u t & Exp lan atio n S y s tem F ac ts Fig. 4. Modular structure of the DSS. Fig. 5. A sample run of the system. able to get a solution for two optimization criteria: tool life or machining operation time. Forward chaining is used in the model-based reasoning. A function of explanation (textual and graphic illustrations) is provided by the system. Updating and enlarging the fact (know-how) base of the system are accessible through the software tool. An example of a DSS run is shown in Figure 5. All the above programs have been implemented on IBM PC platform in Borland Pascal 7.0 . 8. RELATED WORK AND CONCLUSIONS Recently, research world-wide has begun on information processing in CIM. (Koonce, et al., 1996) discussed the integration aspects for manufacturing applications and provided a view of the architecture for the integrated manufacturing systems based on the unified data metamodel. In Aguiar and Weston, (1995) a general modelbased approach to computer-aided support of the life cycle of integrated manufacturing enterprises was introduced. Demands on the next generation of manufacturing resource data and info-systems were identified by Kjellberg and Bohlin, (1996). Despite much research on the subject being published, almost all of it, including the works mentioned above, have been made on the conceptual level rather than the pragmatic one. In this paper we have introduced a model-based technique for developing and maintaining Decision Support Systems in CIM and illustrated the approach with an example from our work on the problem of utilizing empirical know-how. A few conclusions can be drawn from our experiences: • The development of formal methods is an important issue in software engineering technologies for manufacturing. Applying an adequate formal specification technique much facilitates creating decision support technologies in CIM. • Building a unified domain model accessible through the Internet is a vital task of CIM. Such a model can serve as a core to gather, analyze and synthesize the information for DSS. • Founding CIM ontologies can assist utilizing know-how for computer-aided decision-making. Capturing the ontologies can be smoothly organized while an associated information space is established in the domain. One more outcome of the study is that the progress of CIM application systems requires the creation of a domain knowledge (information) fund rather than mere CIM taxonomies and ontologies. A possible way to ensure representation of multiple domain knowledge is the use of a domain-oriented predicate calculus language based on higher order logics. REFERENCES Aguiar, M.W.C., and Weston, R.H. (1995). A model driven approach to enterprise integration. Int. J. Computer Integrated Manufacturing, Vol. 8, No. 3, pp. 210224. Collet, C., Huhns, M.N., Shen, W.-M. (1991). Resource Integration Using a Large Knowledge Base in Carnot. IEEE Computer, Vol.24, No. 12, pp. 55-62. Forgionne, G.A., (1991). Decision Technology Systems: A Vehicle To Consolidate Decision Making Support. Information Processing & Management, Vol. 27, No. 6, pp. 679-697. Kjellberg, T., Bohlin, M. (1996). Design of a Manufacturing Resource Information System. CIRP Annals, Vol. 45/1, pp. 149-152. Kleshchev, A.S., Kryssanov, V.V., Fukuda, Y., Konishi K. (1996). CAPP Expert System Building Technology: Logical Approach. In: Proceedings of The 6th IFIP TC5/WG5.7 International Conference APMS’96, (N.Okino, H.Tamura and S.Fujii (Ed.)), pp. 115-120. IFIP, Kyoto. Koonce, D.A., Judd, R.P., and Parks, C.M. (1996). Manufacturing systems engineering and design: an intelligent, multi-model, integration architecture. Int. J. Computer Integrated Manufacturing, Vol. 9, No. 6, pp. 443-453. Wada, R. (1996). A new concept for next-generation machine tools. In: Proceedings of The 7th International Machine Tool Engineers Conference, pp. 173-189. JMTBA, Tokyo.
5cs.CE
Lazy Evaluation of Convolutional Filters arXiv:1605.08543v1 [cs.CV] 27 May 2016 Sam Leroux, Steven Bohez, Cedric De Boom, Elias De Coninck, Tim Verbelen, Bert Vankeirsbilck, Pieter Simoens, Bart Dhoedt FIRST. LASTNAME @ UGENT. BE Ghent University - iMinds, Department of Information Technology, Technologiepark-Zwijnaarde 15, 9052 Gent, Belgium Abstract In this paper we propose a technique which avoids the evaluation of certain convolutional filters in a deep neural network. This allows to trade-off the accuracy of a deep neural network with the computational and memory requirements. This is especially important on a constrained device unable to hold all the weights of the network in memory. 1. Introduction Deep neural networks are good candidates to enable the next generation of pervasive devices. Internet-of-Things (IoT) devices are commonplace in our everyday lives, yet are still limited in their functionality. Combining the intelligence of deep neural networks with vast amounts of rich sensor data available in an IoT ecosystem could allow for a truly Internet-of-Smart-Things. Deep neural networks require large amounts of resources, both to train and to evaluate. Training is usually less of a problem since this can be done offline on large GPU clusters in the cloud. Inference on the other hand is more of a challenge. The typical IoT devices are limited in the resources available, they usually contain a low-power single-core CPU, limited memory and are often battery powered. Evaluating the current state-of-the-art deep neural networks on these devices is often simply not possible. Current state-of-the-art architectures are usually deep and wide. Impressive results have been obtained by converting these large trained networks into smaller, computationally less expensive versions. (Ba & Caruana, 2014; Romero et al., 2014). Accepted for the 33 rd International Conference on Machine Learning - Workshop on Device Intelligence, New York, NY, USA, 2016. Copyright 2016 by the author(s). It is well known that 32 bit floating point numbers are not needed, 16 bit (Gupta et al., 2015), 10 bit (Courbariaux et al., 2014), 8 bit (Vanhoucke et al., 2011) and even binary (Courbariaux & Bengio, 2016) and fixed point precision (Lin et al., 2015) weights and activations are sufficient for training and evaluating a neural network. Another approach is presented in (Chen et al., 2015) where the authors use a hash function to group connection weights into hash buckets. All connections with the same hash value share the same parameter value thereby reducing the number of parameters to store. Other techniques to exploit the redundancy among weights include low-rank decompositions of the weight matrices (Sainath et al., 2013; Denil et al., 2013; Sindhwani et al., 2015) and sparsity inducing regularisation techniques (Collins & Kohli, 2014). Other approaches optimize the structure of the neural network itself. A three step method is presented in (Han et al., 2015) where first the network is trained to discover which connections are important, then, the redundant connections are pruned and finally the network is retrained to fine-tune the weights of the remaining connections. This procedure is able to reduce the number of parameters up to 13 times without any loss of accuracy. In this paper we present a lazy evaluation approach which allows reducing the required runtime of a deep neural network by selectively evaluating the convolutional filters. Our approach is most similar to the perforatedCNNs technique (Figurnov et al., 2015) which avoids evaluating convolutional filters for some of the spatial positions. The filters are only evaluated for a subset of the spatial positions, an interpolated value is used for the other positions. Our approach on the other hand evaluates the filters at every spatial position but reduces the number of filters that need to be evaluated. A combination of both techniques could allow for an even larger reduction in computational cost since both techniques exploit orthogonal properties of the network. Lazy Evaluation of Convolutional Filters The remainder of this paper is organised as follows: In Section 2 we introduce the concept of Lazy evaluation of convolutional filters. In Section 3 we present the experimental results. We conclude in Section 4 with the future work. 2. Concept One interesting property of deep convolutional neural networks (CNNs) is that they learn a hierarchy of features (Le, 2013; Razavian et al., 2014; Yosinski et al., 2014). The first layers learn to detect low level features such as oriented edges and color transitions. These features are then combined by the deeper layers into high level concepts such as human faces and various objects. The default implementation of a CNN evaluates every filter of every layer as the input is being processed by the network. Filters that are not relevant will return a feature map with extremely small values and will have little impact on the final classification. We try to prune these irrelevant filters on a per sample basis by predicting which filters will be useful for the specific input based on the activations of the filters in the previous convolutional layer at runtime. We define the Activation Strength of a certain convolutional filter when processing the input as the sum of the absolute values in the output of the filter. We hypothesise that only filters with a large Activation Strength have an impact on the final classification. Consequently, the filters with the lowest Activation Strength are not relevant at all and can be omitted, effectively setting the activation for the entire feature map to zero instead of performing the actual computation. We use linear regression to predict the Activation Strength of the filters in layer i based on the Activations of the filters in layer i − 1. The forward propagation algorithm is changed as shown in algorithm 1 The additional hyperparameter nl for each convolutional layer l is used to trade-off accuracy and computational cost at runtime. The ability to dynamically trade off accuracy and computation is especially interesting for mobile devices that are battery operated. A suitable tradeoff parameter can be selected based on the remaining battery capacity and the remaining operation time or on the desired runtime and accuracy. 3. Experiments In this section we present the preliminary results of our approach. We choose an image classification task Algorithm 1 Forward propagation through the network for each layer l in the network do if l is a convolutional layer then • Use linear regression to predict the activation strengths of layer l based on the activation strengths of layer l − 1 • Evaluate the nl % filters with the largest predicted Activation Strengths, use zero values for the other filters else Use the unmodified forward propagation for this layer end if end for since this is arguably the current benchmark for deep convolutional neural networks and because of the high dimensional input data which requires large amounts of memory and computation power. We focus on real-time image processing and propagate the dataset one image at a time through the network in all these experiments. This best resembles the real world applications where data has to be processed the moment it becomes available. There is no time to accumulate images in batch to allow for optimized batch processing. We choose the VGG network (Simonyan & Zisserman, 2014) with 19 layers trained on the Imagenet (Deng et al., 2009) dataset as the base network to optimize since this is a typical, widely used architecture obtaining near state-of-the-art performance. All experiments were implemented in Theano (Bergstra, 2010). All timings reported are measured on an Intel i5-2400 CPU. The following sections are organised following the different research questions posed in this research. 3.1. What is the impact of pruning convolutional filters on the accuracy and runtime of the network ? 3.1.1. I MPACT ON ACCURACY We processed each image in our validation set and for each image and each convolutional layer we independently set the nl % activations with the smallest activation strength to zero and recorded the accuracy of the entire network. We expect that the deep layers have highly specialised filters and that the majority of these filters can be ignored while still allowing a high classification accuracy. The filters in the first layers, on the other hand, are low level filters and should each have a useful contribution to the accuracy of the network. The results are shown in Figure 1. We observe the Lazy Evaluation of Convolutional Filters Layer runtime (s/sample) Accuracy 0.8 0.6 0.4 0.2 0 0.2 conv1_2 conv3_2 conv4_2 conv5_2 0.4 0.6 0.8 Active fraction conv2_1 conv3_3 conv4_3 conv5_3 conv2_2 conv3_4 conv4_4 conv5_4 1 conv3_1 conv4_1 conv5_1 Figure 1. The global accuracy of the network as a function of the active filters for each layer. This graph illustrates how sensitive the accuracy is to ignoring filters in each convolutional layer. The layer names follow the original VGG paper (Simonyan & Zisserman, 2014) predicted behaviour although less straight forward than expected. The last layer in the network for example is highly specialised, up to 80% of its filters (total of 512 filters) can be ignored without any significant drop in accuracy (−0.4%). Dropping filters from one of the first convolutional layers incurs a much higher penalty. Not all layers follow this global trend. The “conv2 2” layer for example is the most sensitive to ignored filters, even more sensitive than the very first convolutional layer. 3.1.2. I MPACT ON RUNTIME The previous section showed that we can ignore certain filters in each convolutional layer without a significant drop in accuracy. In this section we investigate the impact on the required runtime. The results are shown in Figure 2. This graph shows the computational cost for each convolutional layer as a function of the fraction of active filters. We observe a more or less linear relationship. The sudden drop in computational cost when all filters are used (x = 1) is caused by a suboptimal implementation where data needs to be copied into a preallocated buffer. This is especially costly for the early layers since these produce the largest activation maps. A more efficient in-place implementation should solve this. The overhead of predicting the most important filters based on the activations of the 0.15 0.10 0.05 0.00 0.2 0.4 0.6 0.8 Active fraction conv1_2 conv3_1 conv4_[2-4] conv2_1 conv3_[2-4] conv5_[1-4] 1 conv2_2 conv4_1 Figure 2. The required runtime of each convolutional layer as a function of the active filters, measured on a single core CPU. previous layer is included in these measurements and is small compared to the cost of evaluating all convolutional filters (< 2%). We only show the results measured on a single CPU core. Graphical Processing Units (GPUs) allow for a much more efficient evaluation of a neural network because of their inherent parallelism (Krizhevsky et al., 2012). The approach presented in this paper is not useful for GPU implementations because the cost of evaluating extra filters on a GPU is relatively small compared to the cost caused by transfering data to and from the device. In an IoT use case however most of the devices are single core CPU operated and could benefit from the lazy filter evaluation approach. This is especially true when the network is too large to fit into the memory of the device and the filters need to be processed sequentially. Secondary memory access is needed in those cases to retrieve the weights while processing data. The last convolutional layer (“conv5 4”) is the least sensitive to ignored filters and as such a good candidate for heavy pruning. The computational cost of this layer is however only a small part of the total computational cost (≈ 3%). It is still useful to prune most of the “conv5 4” filters since this results in a very sparse activation map which allows a large speed-up of the fully connected layer following this layer and an even larger reduction in required memory (see Section 3.4). Lazy Evaluation of Convolutional Filters 3.2. Can we predict the relevant filters of a certain layer based on the activations of the previous layer ? The crucial part of this technique is predicting which filters will be relevant before evaluating them. We used linear regression to predict the Activation Strength of each filter in a convolutional layer based on the Activation Strengths of the filters in the previous convolutional layer. si = si−1 · W + b where si is a vector of dimensionality m (the number of convolutional filters in layer i), si−1 is a vector of dimensionality n (the number of filters in the previous convolutional layer, W is an m ∗ n weight matrix and b is an mdimensional bias vector. We used gradient descent to minimise the mean absolute error between the predicted and the real activation strengths. On average we are able to correctly predict about 90% of the top N% filters for each layer. 3.3. What is the gain in runtime and the loss in accuracy of this approach ? The technique presented in this paper allows a runtime trade-off between accuracy and speed. The task of finding suitable trade-off parameters is a multi objective optimization task characterized by a Pareto front. We used the NSGA-II algorithm (Deb et al., 2002) implemented in PyGMO (Izzo, 2012) to explore this Pareto front. The result is presented in Figure 3. The horizontal and vertical lines show the baseline accuracy, respectively the baseline runtime of the network. Baseline 3.4. How can we use this technique to reduce the memory footprint of the network? The computational cost of a convolutional neural network is dominated by the convolutional layers. The fully connected layers on the other hand dictate the memory footprint. The first fully connected layer in the VGG19 network for example has 102764544 parameters and needs 411MB just to store these weights (float32). Figure 1 shows that the last convolutional layer (“conv5 4”) is highly specialised, up to 80% of the filters can be ignored without any significant impact on accuracy. This results in a very sparse activation map. Figure 2 showed that disabling these filters unfortunately has little impact on the required runtime of this layer. The memory footprint of the first fully connected layer however is directly proportional to the number of active filters in the last convolutional layer. When we disable 80% of the filters only 20% of the weights of the fully connected layer are needed since the other 80% will be multiplied with zero values. We only need to load a subset of the weights into memory at runtime (i.e. 88MB instead of 441MB) thanks to the sparsity of the last convolutional layer. 4. Conclusion and future work We presented an approach which avoids evaluating convolutional filters that are unlikely to have an impact on the final classification. We trained a linear regression model for each convolutional layer to predict the importance of each convolutional filter based on the activations of the previous layer. This allowed us to prune low-impact filters at runtime. on a per-sample basis. As a consequence the activations can be very sparse reducing the number of parameters that need to be retrieved from secondary storage mediums on devices that are unable to hold all parameters in memory. Accuracy 0.8 In future work we will investigate if it is possible to combine this approach with the techniques presented in the related work section. We will also implement this technique on embedded and FPGA platforms where the weights do not fit in on-chip memory and external memory access is the bottleneck during computation. 0.6 0.4 0.2 Acknowledgment 0 0.8 0.9 1 1.1 1.2 Runtime (s/sample) Figure 3. The trade-off between accuracy and required runtime. Part of this work was supported by the iMinds IoT Research Program. Steven Bohez is funded by a PhD grant of the Agency for Innovation by Science and Technology in Flanders (IWT). Cedric De Boom is funded by a PhD grant of the Flanders Research Foundation (FWO). We gratefully acknowledge the support of NVIDIA Corporation with the donation of a Tesla K40 GPU and a Jetson TK1 and TX1. Lazy Evaluation of Convolutional Filters References Ba, Jimmy and Caruana, Rich. Do deep nets really need to be deep? In Advances in neural information processing systems, pp. 2654–2662, 2014. Bergstra, James. Theano: a CPU and GPU math expression compiler. In Proceedings of the Python for Scientific Computing Conference (SciPy), June 2010. Oral Presentation. Chen, Wenlin, Wilson, James T, Tyree, Stephen, Weinberger, Kilian Q, and Chen, Yixin. Compressing neural networks with the hashing trick. arXiv preprint arXiv:1504.04788, 2015. Collins, Maxwell D and Kohli, Pushmeet. Memory bounded deep convolutional networks. arXiv preprint arXiv:1412.1442, 2014. Courbariaux, Matthieu and Bengio, Yoshua. Binarynet: Training deep neural networks with weights and activations constrained to+ 1 or-1. arXiv preprint arXiv:1602.02830, 2016. Courbariaux, Matthieu, Bengio, Yoshua, and David, JeanPierre. Training deep neural networks with low precision multiplications. arXiv preprint arXiv:1412.7024, 2014. Deb, Kalyanmoy, Pratap, Amrit, Agarwal, Sameer, and Meyarivan, TAMT. A fast and elitist multiobjective genetic algorithm: Nsga-ii. Evolutionary Computation, IEEE Transactions on, 6(2):182–197, 2002. Deng, Jia, Dong, Wei, Socher, Richard, Li, Li-Jia, Li, Kai, and Fei-Fei, Li. Imagenet: A large-scale hierarchical image database. In Computer Vision and Pattern Recognition, 2009. CVPR 2009. IEEE Conference on, pp. 248– 255. IEEE, 2009. Denil, Misha, Shakibi, Babak, Dinh, Laurent, de Freitas, Nando, et al. Predicting parameters in deep learning. In Advances in Neural Information Processing Systems, pp. 2148–2156, 2013. Figurnov, Michael, Vetrov, Dmitry, and Kohli, Pushmeet. Perforatedcnns: Acceleration through elimination of redundant convolutions. arXiv preprint arXiv:1504.08362, 2015. Gupta, Suyog, Agrawal, Ankur, Gopalakrishnan, Kailash, and Narayanan, Pritish. Deep learning with limited numerical precision. arXiv preprint arXiv:1502.02551, 2015. Han, Song, Pool, Jeff, Tran, John, and Dally, William. Learning both weights and connections for efficient neural network. In Advances in Neural Information Processing Systems, pp. 1135–1143, 2015. Izzo, Dario. Pygmo and pykep: Open source tools for massively parallel optimization in astrodynamics (the case of interplanetary trajectory optimization). In 5th International Conference on Astrodynamics Tools and Techniques (ICATT), 2012. Krizhevsky, Alex, Sutskever, Ilya, and Hinton, Geoffrey E. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pp. 1097–1105, 2012. Le, Quoc V. Building high-level features using large scale unsupervised learning. In Acoustics, Speech and Signal Processing (ICASSP), 2013 IEEE International Conference on, pp. 8595–8598. IEEE, 2013. Lin, Darryl D, Talathi, Sachin S, and Annapureddy, V Sreekanth. Fixed point quantization of deep convolutional networks. arXiv preprint arXiv:1511.06393, 2015. Razavian, Ali, Azizpour, Hossein, Sullivan, Josephine, and Carlsson, Stefan. Cnn features off-the-shelf: an astounding baseline for recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition Workshops, pp. 806–813, 2014. Romero, Adriana, Ballas, Nicolas, Kahou, Samira Ebrahimi, Chassang, Antoine, Gatta, Carlo, and Bengio, Yoshua. Fitnets: Hints for thin deep nets. arXiv preprint arXiv:1412.6550, 2014. Sainath, Tara N, Kingsbury, Brian, Sindhwani, Vikas, Arisoy, Ebru, and Ramabhadran, Bhuvana. Low-rank matrix factorization for deep neural network training with high-dimensional output targets. In Acoustics, Speech and Signal Processing (ICASSP), 2013 IEEE International Conference on, pp. 6655–6659. IEEE, 2013. Simonyan, Karen and Zisserman, Andrew. Very deep convolutional networks for large-scale image recognition. arXiv preprint arXiv:1409.1556, 2014. Sindhwani, Vikas, Sainath, Tara, and Kumar, Sanjiv. Structured transforms for small-footprint deep learning. In Advances in Neural Information Processing Systems, pp. 3070–3078, 2015. Vanhoucke, Vincent, Senior, Andrew, and Mao, Mark Z. Improving the speed of neural networks on cpus. In Proc. Deep Learning and Unsupervised Feature Learning NIPS Workshop, volume 1, 2011. Yosinski, Jason, Clune, Jeff, Bengio, Yoshua, and Lipson, Hod. How transferable are features in deep neural networks? In Advances in Neural Information Processing Systems, pp. 3320–3328, 2014.
9cs.NE
Learning a Tree-Structured Ising Model in Order to Make Predictions arXiv:1604.06749v2 [math.ST] 8 Aug 2016 Guy Bresler† and Mina Karzand‡∗ Massachusetts Institute of Technology Abstract: We study the problem of learning a tree graphical model from samples such that low-order marginals are accurate. We define a distance (“small set TV” or ssTV) between distributions P and Q by taking the maximum, over all subsets S of a given size, of the total variation between the marginals of P and Q on S. Approximating a distribution to within small ssTV allows making predictions based on partial observations. Focusing on pairwise marginals and tree-structured Ising models on p nodes with maximum edge strength β, we prove that max{e2β log p, η −2 log(p/η)} i.i.d. samples suffices to get a distribution (from the same class) with ssTV at most η from the one generating the samples. Keywords and phrases: Structure learning, Ising model, Inference, Graphical models, Trees. 1. Introduction Markov random fields, or undirected graphical models, are a useful way to represent high-dimensional probability distributions. Their practical utility is in part due to: 1) edges between variables capture direct interaction, which make the model interpretable and 2) the graph structure facilitates efficient approximate inference from partial observations, for example using loopy belief propagation or variational methods. The inference task of interest to us in this paper is evaluation of conditional probabilities or marginals, e.g. P(Xi = +|XS = xS ) or P(xS ), having observed a subset of values xS for a set of variables S. In applications it is often necessary to learn the model from data. It makes sense to measure accuracy of the learned model in a manner corresponding to the intended use. While in some applications it is of interest to learn the graph itself, in many machine learning problems the focus is on making predictions. In the literature, learning the graph is called structure learning; this problem has been studied extensively in recent years, see e.g. [20, 7, 1, 24, 19]. In this paper we consider the problem of learning a good model for the purpose of performing subsequent inference. This objective has been called “inferning” [15], and has received significantly less attention. ∗ The list of authors is in alphabetical order. Bresler is with the Department of Electrical Engineering and Computer Science at MIT and a member of LIDS and IDSS. [email protected] ‡ Mina Karzand is with the Department of Electrical Engineering and Computer Science at MIT and a member of LIDS, IDSS and RLE. [email protected] † Guy 1 G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 2 Tree-structured graphical models have been particularly well-studied. Aside from their theoretical appeal, there are two reasons for the practical utility of tree models: 1) Structure learning for trees can be accomplished with smaller sample and time complexity as compared to loopy graphs, and 2) Efficient exact inference (computation of marginals) is possible using belief propagation. Hence, in this paper we focus on tree-structured Ising models. The main question we address is how many i.i.d. samples are required in order to guarantee that subsequent inference computations are accurate. Since computation of marginals on trees is easy, the crux of the task is in learning a model with marginals that are close to those of the original model. One of the take home messages is that learning for the purpose of making predictions requires dramatically fewer samples than is necessary for correctly recovering the underlying tree. The central technical challenge is that our analysis must also apply when it is impossible to learn the true tree, and this requires careful control of the sorts of errors that can occur. With the goal of making predictions in mind, we introduce a new loss function to evaluate learning algorithms based on the accuracy of low-order marginals. The loss between true distribution P and learned distribution Q is defined to be L(k) (P, Q) , sup dTV (PS , QS ) , S:|S|=k where PS denotes the marginal on set S. As discussed in Section 3.2, small loss L(k) guarantees accurate posterior distributions conditioned on sets of size k −1. In this paper we restrict attention to tree-structured Ising models with no external field. For tree T = (V, E) on p nodes and edge parameters α ≤ |θij | ≤ β for (i, j) ∈ E, each configuration x ∈ {−1, +1}p is assigned probability  X  P (x) = exp θij xi xj − Φ(θ) , (1.1) (i,j)∈E where Φ(θ) is the normalizing constant. Our main result gives lower and upper bounds on the number of samples needed to learn a tree Ising model to ensure small L(2) loss, which in this setting is equivalent to accurate pairwise marginals. We emphasize that the task is to learn a model from the same class (tree-structured Ising) with these guarantees; this is sometimes called proper learning. p , e2β log pδ } samples generated acTheorem 1.1. Given n > C max{η −2 log δη cording to a tree Ising model P , denote the Chow-Liu tree by TCL . The Ising model Q on TCL obtained by matching correlations satisfies L(2) (P, Q) ≤ η with probability at least 1 − δ. Conversely, if n ≤ C 0 η −2 log p, then no algorithm can find a tree model Q such that L(2) (P, Q) ≤ η with probability greater than half. The result shows that the Chow-Liu tree, which can be found in time O(p2 log p), gives small L(2) error. We next place the result in context of related work. G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 3 1.1. Related work Tree structured Markov random fields have attracted a lot of attention in different fields. These models, although admittedly a restricted class of probability distributions, are desirable from two different reasons: First, almost all computational tasks (e.g., computation of marginals or mode) that are hard even to approximate for general distributions can be performed exactly by efficient iterative algorithms on trees (typically in linear time). Sum-product or max-product are two well-studied examples [23, 32, 33, 17]. Second, learning tree-structured graphical models is also usually a much easier task in term of both sample and time complexity compared to the loopy graphs. Structure learning in general graphical models have been studied widely. Information theoretic bounds on the number of samples have been provided [25, 29, 5, 6, 34]. Structure learning in trees and forest estimation have been studied by [8, 27]. Some generalizations of tree-structured models are studied such as forest approximations[28, 18], polytrees [12], bounded tree-width graphs [26, 22] and mixtures of trees [3, 19]. Structure learning becomes statistically more challenging, meaning more data is required, when interactions between variables are very weak or very strong [25, 5, 29]. It is intuitively clear that very weak edges are difficult to detect, leading to non-identifiability of the model. The goal of this paper is to show that accurate inference is possible even when structure learning is not. Loopy belief propagation yields accurate marginals in high girth graphs (locally tree-like graphs) with correlation decay. [15] use this intuition to study this family of graphical models and propose an algorithm which recovers all the edges of the true graph. Due to insufficiency of the number of samples, the output of their algorithm can have extra edges, which are proved to be weak. The learned distribution is close to the true one in Kullback-Leibler divergence. The paper [16] also studied recovery of the wrong graph for Gaussian graphical models and provided a lower bound on the KL distance between the estimated distribution and original distribution. In [22], a polynomial time algorithm using polynomial number of samples is proposed to learn bounded tree-width graphical models with respect to KL divergence. They use ideas from submodular optimization and proper factorization of the distribution over bounded tree-width graphs. Latent tree models have been well-studied in the phylogenetic reconstruction literature. The paper [14] studied sample and time complexity of tree metric based algorithms to reconstruct phylogenetic trees. [13] and [21] use distorted tree metrics to get approximations of the phylogenetic trees when the exact reconstruction of tree is not possible. In [21] studied in Section 6 a forest approximation of the tree is recovered. In [13] the prior assumptions on the phylogenetic tree is removed and instead a forest structure is recovered which is guaranteed to recover strong edges and deeper parts of the tree. Similar approaches are taken in numerical taxonomy problems in which data is fitted to a tree metric. In [2], given a pairwise distance matrix D over p nodes is approximated by a tree metric with the induced distance matrix T . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 4 Let  = minT {kT − Dk∞ } . An O(p2 ) algorithm is provided which produces Tb with kTb − Dk∞ ≤ 3 and it is shown that finding a T with kT − Dk∞ ≤ 9/8 is NP-hard. For loopy graphs, both estimation of parameters and prediction based on noisy observations are computationally challenging tasks. [31] made the observation that considering the performance of the estimation and prediction together might be beneficial. They focus on computationally efficient prediction algorithms such as reweighted sum-product algorithm which is proved to converge to a unique global optima. They compare the prediction performance of these algorithms using two different sets of parameters. The first set is the true parameters of the model given by an oracle. The second set of parameters are derived by using the tree-reweighted Bethe surrogate. The second set of parameters are inconsistent in general and even having infinite data, this estimation process does not provide the true parameters. They show that using reweighted sum-product prediction algorithm, the inconsistent parameters derived by the tree-reweighted Bethe surrogate would provide smaller prediction error. It seems that the effect of error imposed in the estimation phase cancels out by using the approximate computationally efficient prediction algorithm. 1.2. Outline of paper The next section provides background on the Ising model, tree models, and graphical model learning. Section 3.1 studies the problem of learning treestructured Ising models, and specifies the sample complexity of exact recovery. Then in Section 3.2 we define a loss function motivated by inference computation and state our main result in Section 3.3. Section 4 analyzes an illustrative example to provide intuition for the main result. Section 5 contains a sketch of proof of the main result. Section 6 introduces the truncation algorithm and analyzes its performance in terms of ssTV. Section 7 contains proofs of the main results. A few technical lemmas are deferred to Section 9. Finally, Section 10 proves a combinatorial lemma on the relationship between the true and learned spanning trees. 2. Preliminaries 2.1. Notation For a given tree T = (V, E) let PT (α, β) be the set of Ising models (1.1) with the restriction α ≤ |θij | ≤ β for each edge (i, j) ∈ E. Denote by PT = PT (0, ∞) the set of Ising models on T with no restrictions on parameter strength. We denote by µij = EP Xi Xj the correlation between the variables corresponding to any pair of vertices i, j ∈ V. For an edge Q e = (i, j) we write µe = µij and similarly for a set of edges A ⊆ E, µA = e∈A µe . The empirical distribution Pn bij = EPb Xi Xj is the of samples is denoted by Pb(x) = n1 l=1 1{X (l) =x} and µ empirical correlation between nodes i and j. G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 5 2.2. Tree models We study distributions that are Markov with respect to graphs. A distribution P on X V is Markov with respect to a graph G = (V, E) if for all i ∈ V, we have P (xi |xV\{i} ) = P (xi |x∂i ) (here ∂i is the neighborhood of i in G). In this paper we are interested in distributions P that are Markov with respect to a tree T = (V, E). A consequence (see [17]) is that P (x) factorizes as P (x) = Y i∈V P (xi ) Y (i,j)∈E P (xi , xj ) . P (xi )P (xj ) (2.1) For an arbitrary distribution Q and tree T, the distribution e Q(x) = arg min D(QkP ) P is factorized as (2.1) is the best approximation to Q within distributions Markov with respect to T. e is specified by matching the first and second moments, It is proved in [8] that Q e i , xj ) = Q(xi , xj ). i.e., for all (i, j) ∈ E, and all xi , xj ∈ X , Q(x p For distribution P on {−, +} and tree T, we define ΠT (P ) = arg min D(P kQ) Q∈PT to be the projection of P onto the class of Ising models on T with no external field. Hence, Pe = ΠT (P ) can be represented as Equation (1.1) for some θe supported on T. Lemma 11.1 shows that Pe = ΠT (P ) has edge weights θeij for each (i, j) ∈ ET satisfying tanh θeij = µij , EP Xi Xj . 3. Learning trees to make predictions In this section we first state a specialization to our setting of the Chow-Liu algorithm. Later, in order to set up the learning for prediction problem, we discuss the problem of exact structure learning and give tight (up to a multiplicative constant) sample complexity for that problem. Finally, we define the ssTV distance L(k) , explain how it relates to prediction, and then state our results. Denote the set of all trees on p nodes by T . For some distribution P ∈ PT , one observes n independent samples (configurations) X (1) , . . . , X (n) ∈ {−, +}p from the Ising model (1.1). Restricting to trees, a structure learning algorithm is a (possibly randomized) map φ : {−1, +1}p×n → T taking n samples X 1:n = X (1) , . . . , X (n) to a tree φ(X 1:n ). The maximum likelihood tree or Chow-Liu tree plays a central role in tree structure learning. Chow and Liu [8] observed that the maximum likelihood tree is the max-weight spanning tree in the complete graph, where each edge has weight equal to the empirical mutual information between the variables at its endpoints. The tree can thus be found greedily, and the run-time is dominated by computing empirical mutual information between all pairs of nodes. Lemma 11.2 applies analysis similar to [8] to zero-field Ising models on trees to support the following definition: G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 6 Definition 3.1 (Chow-Liu Tree). Given n i.i.d samples X 1:n from distribution P ∈ PT , we define the Chow-Liu tree to be the maximum likelihood tree: TCL = argmax max P (X 1:n ) . T∈T P ∈PT This definition is slightly abusing the conventional terminology, as the ChowLiu tree is classically the maximum likelihood tree assuming that the generative distribution is tree-structured, whereas in our definition we are assuming that the original distribution P ∈ PT can be described by Equation (1.1). Thus, it is not only tree-structured, but also has uniform singleton marginals. Note that maximizing the likelihood of i.i.d. samples corresponds to minimizing the KL divergence. For the samples with empirical distribution Pb, TCL = arg minT∈T minP ∈PT D(PbkP ). Lemma 11.2 shows that X TCL = argmax |b µe | , (3.1) {spanning trees T0 } e∈E T0 where for e = (i, j), µ be = EPb Xi Xj is the empirical correlation between variables Xi and Xj . Chow and Wagner [9] showed that the maximum likelihood tree is consistent for structure learning of general discrete tree models, i.e., in the limit of large sample size the correct graph structure is found. More recently, detailed analysis of error exponents was carried out by Tan et al. [27, 28]. A variety of other results and generalizations have appeared, including for example Liu et al.’s work on forest estimation with non-parametric potentials [18]. 3.1. Exact recovery of trees The statistical performance of a structure learning algorithm is often measured using the zero-one loss, L0−1 (T, T0 ) = 1{T6=T0 } , (3.2) meaning that the exact underlying graph must be learned. (See e.g., [7], [25], [28], [18]). The risk, or expected loss, under some distribution P ∈ PT (α, β) is then given by the probability of reconstruction error, EP L0−1 (T, φ(X 1:n )) = P(φ(X 1:n ) 6= T) , and for given α, β, p and n, the maximum risk is sup{P(φ(X 1:n ) 6= T) : T ∈ T , P ∈ PT (α, β)} . The sample complexity for learning the correct tree underlying the distribution increases as edges become weaker, i.e., as α → 0, because weak edges are harder to detect. As the maximum edge strength β increases, there is a similar increase in sample complexity (as shown by [25, 29] for general bounded degree models). In the context of tree-structured Ising models we give the following theorem (here and throughout, α and β are the bounds α ≤ |θij | ≤ β): 1 2β −2 e α log p Theorem 3.2 (Necessary samples for structure learning). Given n < 16 samples, the worst-case probability of error over trees T ∈ T and distributions G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 7 P ∈ PT (α, β) is at least half for any algorithm, i.e., inf φ sup P (φ(X 1:n ) 6= T) > 1/2 . T∈T P ∈PT (α,β) The proof given in Section 8.1, applies Fano’s inequality to a large set of trees that are difficult to distinguish. The next theorem gives an essentially matching sufficient condition. Theorem 3.3 (Sufficient samples for structure learning). Fix an arbitrary tree T and Ising distribution P ∈ PT (α, β). If the number of samples is n > Ce2β max{α−2 , 1} log(p/δ) samples, then with probability at least 1−δ the ChowLiu algorithm recovers the true tree , i.e., TCL = T. The proof is presented in Section 8.2. Note that Theorems 3.2 and 3.3 give tight bounds (up to numerical constant) for the sample complexity of learning the tree structure for Ising models with zero external field. The necessary number of samples increases as the minimum edge weight α decreases. Hence, if edges can be arbitrarily weak, it is impossible to learn the tree given a bounded number of samples. If the goal is merely to make accurate predictions, it is natural to seek a less stringent, approximate notion of learning. Several papers consider learning a model that is close in KL-divergence, e.g. [1, 18, 28]. This corresponds to the log-likelihood loss. The sample complexity for learning a model to within constant KL-divergence  scales at least linearly in the number of variables p, an unrealistic requirement in the high-dimensional setting of interest. Using number of samples scaling logarithmically in dimension requires relaxing the KL-divergence to scale as p, but this does not imply a nontrivial guarantee on the quality of approximation for marginals of few variables (as done in this paper). In the next section we study estimation with respect to the small-set TV loss function, which captures prediction accuracy of the model. We will see that the associated sample complexity is independent of the minimum coupling strength α of the original model. 3.2. Learning for inference For a subset of nodes S ⊆ [p] we consider the P marginal distribution over variables XS , which can be written as PS (xS ) = xV\S P (x). Given two distributions P, Q on the same space, for each k ≥ 1 the maximum total variation distance over all size k marginals is denoted by L(k) (P, Q) , supS:|S|=k dTV (PS , QS ) . Note that L(k) is non-decreasing in k. One can check that L(k) satisfies the triangle inequality: for any three distributions P, Q, R, L(k) (P, Q) + L(k) (Q, R) ≥ L(k) (P, R) . (3.3) Closeness of P and Q in L(k) implies that the respective posteriors conditioned on subsets of variables of size k − 1 are close on average. To see this, suppose that we wish to compute P (Xi = +|XS ). We measure performance of the G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 8 approximation Q by the expected magnitude of error |P (xi = +|XS ) − Q(xi = +|XS )| averaged over XS : EXS |P (Xi = +|XS ) − Q(Xi = +|XS )| X = |P (Xi = +, XS = xS ) − Q(Xi = +|XS = xS )P (XS = xS )| xS ≤ X |P (Xi = +, XS = xS ) − Q(Xi = +, XS = xS )| + xS X |Q(xS ) − P (xS )| xS ≤ 2L(|S|+1) (P, Q) . where the last inequality is a consequence of monotonicity of L(k) in k. e ∈ T and distriIn this paper we focus on L(2) . Note that for the trees T, T e butions P ∈ PT and P ∈ PTe , we have 1 L(2) (P, Pe) = sup 2 w,w∈V e = sup w,w∈V e 1 2 X 2 xw ,xw e ∈{−,+} Y e∈pathT (w,w) e |P (xw , xwe ) − Pe(xw , xwe )| µe − Y e0 ∈pathTe (w,w) e µ ee0 , (3.4) where for e = (i, j) ∈ ET , µe = EP Xi Xj and for e0 = (i, j) ∈ ETe , µ ee0 = EPe Xi Xj . Distribution P ∈ PT has singleton uniform marginals (i.e., P (xi = +) = 1/2) and so P (xw , xwe ) = [1 + xw xwe EP [Xw XQ w e ]] /4. Also, from the Ising definition (1.1) one can check that EP [Xw Xwe ] = e∈pathT (w,w) e µe . The same e holds for P ∈ PTe , which gives (3.4). e is challenging As discussed in detail in section 3.3, bounding L(2) when T 6= T since these products of correlations are in general computed along different paths as imposed by Equation (3.4). 3.3. Main result Our main contribution is to provide upper and lower bounds on the number of samples required to get accurate pairwise marginals. To get the upper bound on the number of samples, we study the Chow-Liu algorithm and bound the expression (3.4). The Chow-Liu algorithm recovers the maximum likelihood tree minimizing the expected zero-one loss in (3.2), but as shown in Theorem 3.4, the maximum likelihood tree also performs well in terms of accuracy of pairwise marginals. Recall that ΠT (P ) = arg minQ∈P(T) D(P kQ) is the reverse information projection of the distribution P onto the zero-field Ising models on tree T. Theorem 3.4 (Learning for inference using Chow-Liu algorithm). For T ∈ p } T , let the distribution P ∈ PT (0, β). Given n > C max{e2β log pδ , η −2 log ηδ CL samples, if the tree T is the Chow-Liu tree as defined in (3.1), then with probability at least 1 − δ we have L(2) (P, ΠTCL (Pb)) < η . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 9 The main challenge is that the number of samples available in this regime is not sufficient for structure learning, as can be seen by comparing with Theorem 3.2. This means that accurate inference must be performed using possibly the wrong tree. To guarantee accurate pairwise marginals using the wrong tree, we characterize the combinatorial and statistical properties of the mistakes made by the algorithm in detecting edges. A sketch of the proof is provided in Section 5. We also provide a lower bound on the necessary number of samples to guarantee small L(2) loss. Theorem 3.5 (Samples necessary for small ssTV). Suppose one observes n < η −1 atanh−1 (η) log p samples. Then the worst-case probability of L(2) loss greater than η taken over trees T ∈ T and distributions P ∈ PT (α, β) is at least half for any algorithm, i.e., h i inf sup P L(2) (P, φ(X 1:n )) > η > 1/2 . φ T∈T P ∈PT (α,β) The proof is provided in Section 8.2. 4. Illustrative example: three node Markov chain A Markov chain with three nodes captures a few of the key ideas developed in this paper. Let p = 3 and P (X1 , X2 , X3 ) be represented by the tree T1 in Figure 1 in which X1 ↔ X2 ↔ X3 form a Markov chain with correlations µ12 and µ23 . Without loss of generality, we assume µ12 , µ23 > 0 . Suppose that for some small value , µ12 = 1 − µ23 =  . Given n samples from P , the empirical correlations µ b12 , µ b23 and µ b13 between each pair of random variables are concentrated around µ12 = , µ23 = 1 −  and µ13 = µ12 µ23 = (1 − ) . Let µ b12 = µ12 + z12 , µ b23 = µ23 + z23 and µ b13 = µ12 µ23 + z13 , where the fluctuations of z12 , z23 and z13 shrink as n grows. It is useful to imagine the typical fluctuations of zij to be on the order /10. Since max{µ12 , µ13 } = max{ , (1 − )} =   µ23 , concentration bounds guarantee that with high probability µ b23 > max{b µ12 , µ b13 } and the (greedy implementation of) Chow-Liu algorithm described in (3.1) adds the edge (2, 3) to TCL . But since µ12 − µ13 = 2 is smaller than fluctuations of z12 and z13 there is no guarantee that µ b12 > µ b13 . In particular, if z13 − z12 > 2 , then TCL = T3 . The preceding discussion provides the intuition underlying a statistical characterization of the possible errors made by the Chow-Liu algorithm. Later on in the proof, we provide a lower bound τ (n, β, δ) so that using n samples, any edge e with |µe | ≥ τ is recovered by the Chow-Liu algorithm with probability at least 1 − δ. Conversely, if there is a mistake made by Chow-Liu algorithm such that e ∈ T but e ∈ / TCL , then |µe | ≤ τ . This lower bound is going to play a key role in bounding the ssTV L(2) for TCL whether or not it is equal to T . In the regime where n is not large enough to guarantee the correct recovery of all the edges in the tree, there are two natural strategies: G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions x3 x2 x3 x2 10 x3 x2 x1 x1 x1 T1 T2 T3 Fig 1. The original distribution is described by T1 . The width of the edges indicate the coupling b = T2 as the correlation strength between the nodes. The truncation algorithm would recover T between node x1 and all the other nodes is not strong enough to recover any edge confidently. Running Chow-Liu algorithm would recover TCL to be T1 or T2 depending on the realization of the smaples. I. Truncation Algorithm: The algorithm finds the maximum weight spanning forest of the complete graph, where the weight of each edge e is |b µe |−τ , for a specified threshold τ . This process is equivalent to finding the maximum weight spanning tree and then truncating the edges with weight smaller than τ . The purpose of this algorithm is recovering a forest F which is a good approximation of the original tree T in the sense that EF ⊆ ET . The edges missing from the forest are all weak edges in the original tree that cannot be recovered reliably using n samples. The appropriate value of τ can be determined based on concentrations inequalities. The details of this algorithm and its sample complexity will be discussed in Section 6. II. Chow-Liu Algorithm: We can use the Chow-Liu tree as our estimated structure despite the fact that it may well return the incorrect tree. Under the assumptions given for our three-node example, the truncation alb = T2 in Figure 1, whereas Chow-Liu would give T b = T1 gorithm would return T (2) b or T = T3 . We compare the graph estimation error, defined as L (P, ΠTb (P )), for the above cases: b = T1 T b = T2 T b = T3 T → L(2) (P, ΠTb (P )) = 0 → L(2) (P, ΠTb (P )) = |µ12 | =  → L(2) (P, ΠTb (P )) = |µ12 |(1 − µ223 ) = 2 (2 − ) Evidently, the loss due to graph estimation error in the truncation algorithm is bigger than Chow-Liu algorithm algorithm whether or not the latter recovers the true tree. This is because the Chow-Liu algorithm does not make arbitrary errors in estimating the tree: errors happen when both the original tree and the estimated tree describe the original distribution rather well. The formal representation of this statement is the main result in this paper and is given in Theorem 3.4. G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 11 5. Outline of Proof We now sketch the argument for the main result, Theorem 3.4, guaranteeing accurate pairwise marginals in the Chow-Liu tree. The starting point is an application of the triangle inequality (3.3): L(2) (P, ΠTCL (Pb)) ≤ L(2) (P, ΠTCL (P )) + L(2) (ΠTCL (P ), ΠTCL (Pb)) . (5.1) The first term on the right-hand side of Equation (5.1) addresses the error in estimation of pairwise correlations due to the difference in the structure of T and TCL . Looking at Equation (3.4), for each pair of nodes u, v ∈ V , pathT (u, v) and pathTCL (u, v) must be compared. We call this first term the loss due to graph estimation error. The second term on the right-hand side of Equation (3.4) addresses the propagation of error due to the parameter estimation error. Recall that the estimated parameters on the Chow-Liu tree are derived by matching correlations to the empirical values. Theorem 3.4 follows by separately bounding each term on the right-hand side of Equation (5.1). Proposition 5.1 (Loss due to edge estimation error). Given p p n > C max{e2β log , η −2 log } δ ηδ samples, with probability at least 1 − δ we have L(2) (ΠTCL (P ), ΠTCL (Pb)) < η . Proposition 5.2 (Loss due to graph estimation error). Given n > C max{e2β , η −2 } log p δ samples, with probability at least 1 − δ we have L(2) (P, ΠTCL (P )) < η . These two propositions are proved in full detail in Sections 7.1 and 7.2. In the remainder of this section we define probabilistic events of interest and sketch the proofs. Proposition 5.1 has a relatively straightforward proof, while the major technical contribution is in Proposition 5.2. The latter uses a careful inductive argument to control the errors arising from recovery of an incorrect tree. We define three highly probable events Ecorr (), Estrong () and Ecascade () as follows. Let Ecorr () be the event that all empirical correlations within  of population values:   Ecorr () = sup |µw,we − µ bw,we | ≤  . (5.2) w,w∈V e √ Let τ = 4/ 1 − tanh β and ETstrong = {(i, j) ∈ ET : | tanh(θi,j )| ≥ τ } (5.3) G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 12 consist of the set of strong edges in tree T and let TCL be the Chow-Liu tree as in Equation (3.1). Let Estrong () be the event that all strong edges in T as defined in (5.3) are recovered using the Chow-Liu algorithm:  Estrong () = ETstrong ⊂ ETCL . (5.4) Finally, define the event n o Ecascade () = L(2) (P, ΠT (Pb)) ≤  . (5.5) Recall that P factorizes according to T and Pb is the empirical distribution which is not factorized according to any tree. This event controls cascades of errors in correlations computed along paths as per (3.4). Lemma 5.3. The following hold: Pr[Ecorr ()] ≥ 1 − 2p2 exp(−n2 /2) Pr[Estrong ()] ≥ 1 − 2p2 exp(−n2 /2) Pr[Ecascade ()] ≥ 1 − 4p2 / exp(−2 n/32) . This Lemma is the restatement of Lemmas 9.2, 9.9 and 9.12. Sketch of proof of Proposition 5.1. The proof of Proposition 5.1 entails showing that on the event Ecorr ()∩Estrong ()∩Ecascade (γ) with  < min{e−β /20, η/3} and γ ≤ η/3 we have the desired inequality L(2) (ΠTCL (P ), ΠTCL (Pb)) < η. According to Lemma 5.3 this happens with probability at least 1 − 3δ with n > 2 2 max{800e2β log 4pδ , 300η −2 log 12p ηδ } samples, which gives the proposition. To bound L(2) (ΠTCL (P ), ΠTCL (Pb)), we consider the net error due to parameter estimation errors in every path in TCL . On the event Ecascade (γ), according to (5.5), the end-to-end error for each path in ET ∩ ETCL is bounded by γ. Next, we study the end-to-end error due to parameter estimation in paths containing (falsely added) edges in ETCL \ ET . For any pair of nodes w, w e denote by t the number of falsely added edges |pathTCL (w, w) e \ ET |. As discussed in the proof, these edges correspond to missed edges in T and thus Estrong () guarantees that these edges are weak (as defined in (5.3)). These t weak edges break up pathTCL (w, w) e into at most t+1 contiguous segments F0 , F1 , · · · , Ft each entirely within ET ∩ ETCL . The error on each segment Fi , 0 ≤ i ≤ t, is bounded by γ as already discussed, but now there are t + 1 such segments and the errors add up. This effect is counterbalanced by the fact that the falsely added edges are weak and hence scale Q Q down the error in a multiplicative fashion. The error be − e∈path CL (w,w) e∈pathTCL (w,w) e µ e µe T dependence on t therefore has a linearly increasing factor and an exponentially decaying factor. If  ≤ e−β /20, then this gives a uniform upper bound of 3 max{, γ} for this quantity for any number t of falsely added edges. Putting it all together shows that if  ≤ min{e−β /20, η/3} and γ ≤ η/3 then L(2) (ΠTCL (P ), ΠTCL (Pb)) < η on the events Ecorr () ∩ Estrong () ∩ Ecascade (γ) . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 13 Sketch of proof of Proposition 5.2. The goal is to show that the event η Ecorr () ∩ Estrong () with  < min{ 16 , e−β /24} implies L(2) (P, ΠTCL (P )) < η. 2 Lemma 5.3 then implies that n > 1200 max{e2β , η −2 } log 2pδ suffices for Ecorr ()∩ Estrong () to occur with probability at least 1 − 2δ. The proof of the proposition sets up a careful induction on the distance between nodes for which we wish to bound the error in correlation. The key technical ingredient is a combinatorial lemma relating trees TCL and T. Lemma 10.1 studies any two spanning trees on p nodes and the paths between two given nodes w and w. e It proves the existence of at least one pair of corresponding edges f ∈ pathT (w, w) e and g ∈ pathTCL (w, w) e satisfying a collection of properties illustrated in Figure 7.2 (and specified in the Lemma). A consequence is that the true correlation across g according to P can be expressed as a function of the correlation on f as µg = µf µA µC µAeµCe , hence |µg | ≤ |µf | . But |b µf | ≥ |b µg |, since the Chow-Liu algorithm chose g in TCL instead of f . In the proof of Proposition 5.2 a recurrence ∆(d) is defined. ∆(d) provides an upper bound for the error due to graph estimation error for any pair of nodes w, w e with |pathTCL (w, w)| e = d . Using the relationship between the edges f and g , the paths pathT (w, w) e and pathTCL (w, w) e are compared. It is proved that the recurrence ∆(d) increases linearly and decays exponentially with d. With η , e−β /24}, convergence of ∆(d) with the upper bound η is shown.  < min{ 16 6. Truncation Algorithm In the regime where exact recovery of the tree is impossible, a reasonable goal is to instead find a forest approximation to the tree. In this section we analyze a natural truncation algorithm, which thresholds to zero edges with correlation below a specified value τ . There is extensive literature on estimating forests in the fully observed setting of this paper, including [28, 18]. [21] studied the problem of learning phylogenetic forests, where samples are only observed at the leaves of the tree. They quantified the idea that most edges of phylogenies are easy to reconstruct, and in the regime that the sample complexity of the structure learning is too high, they instead reconstruct several edge disjoint trees. An upper bound on the number of edges necessary to glue together the forest to get the original tree is provided as a function of number of leaves, the minimum edge weight, and the metric distortion bounds. Our results in this section are consistent with the asymptotic conditions on the thresholds given in [28] for the general distributions over trees. The truncation algorithm considered in pthis section thresholds the edges with 4 for  = 2/n log(2p2 /δ) to zero. This is equivcorrelations below τ = √1−tanh β alent to finding the maximum-weight spanning forest over the complete graph b = (V, Eb ) is a truncated version with edge weights |b µe | − τ −  . The output T T CL of T such that the empirical correlation between any pair of nodes (i, j) ∈ ETb satisfies |b µij | ≥ τ + . Proposition 6.1. Given n > C max{e2β /η 2 log pδ , 1/η 2 log p ηδ } samples, the G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 14 truncation algorithm guarantees that with probability 1 − δ we have ETb ⊆ ET and L(2) (P, ΠTb (Pb)) < η . Proof. We will provide  and γ such that on the event Ecorr () ∩ Estrong () ∩ Ecascade (γ) the ssTV bound holds. All the weak edges e ∈ ET such that |µe | ≤ τ (for which we cannot guarantee correct recovery by Chow-Liu algorithm) have |b µe | ≤ τ + on event Ecorr (), hence these edges are truncated by the thresholding process. It follows that ETb ⊆ ET . On event Estrong (), the strong edges defined in Equation (5.3) are recovered by the Chow-Liu algorithm, i.e., for all e ∈ ET , with |µe | ≥ τ + 2 , e ∈ TCL . On event Ecorr (), these edges also satisfy |b µe | ≥ τ +  and these edges are retained. This implies that all of the strong edges in the original tree T (with |µe | ≥ τ +2) are recovered correctly by the truncation algorithm (i.e., ETstrong ⊆ ETb ). To bound the ssTV, we decompose into two terms as per (5.1). We first study the loss due to graph estimation error L(2) (P, ΠTb (P)). For any pair of nodes w, w e b in T, since ETb ⊆ ET , if there is a path between them, then this is the same as the path between them in T. Hence looking at (3.4), EP [Xw Xwe ] = EΠTb (P) [Xw Xwe ] . b then EΠ (P) [Xw Xwe ] = 0 . This implies If there is no path between w, w e in T, b T that there is an edge e ∈ pathT (w, w) e such that e ∈ / ETb . As proved, all the b missing edges in T are weak edges, hence |µe | ≤ τ + 2. This implies that |EP [Xw Xwe ]| ≤ |µe | ≤ τ + 2 and it follows that L(2) (P, ΠTb (P)) ≤ τ + 2 . To bound L(2) (ΠTb (P), ΠTb (Pb)), we again consider an arbitrary pair of nodes b Since Eb ⊆ ET , under the event Ecascade (γ), w, w e with a path between them in T. T b |EΠTb (P) [Xw Xwe ] − EΠb (Pb) [Xw Xwe ]| ≤ γ . If there is no path between w, w e in T, T then EΠ (P) [Xw Xwe ] = E b [Xw Xwe ] = 0 . Hence, L(2) (Πb (P), Πb (Pb)) ≤ γ . b T ΠTb (P ) T T Combining the two error terms gives L(2) (P, ΠTb (Pb)) ≤ τ + 2 + γ . If  ≤ √ ηe−β /8 and γ ≤ η/4 then τ = 4/ 1 − tanh β ≤ 4eβ ≤ η/8 and L(2) (P, ΠTb (Pb)) ≤ 2 2 τ +2+γ ≤ η . By Lemma 5.3, using n > max{128e2β /η 2 log 2pδ , 512/η 2 log 32p ηδ } corr strong cascade samples, the event E ()∩E ()∩E (γ) happens with probability 1−3δ with  ≤ ηe−β /8 ≤ η/8 and γ < η/4 which proves the result. Comparing the above statement with Proposition 5.2 shows that in general the loss due to graph estimation using the truncation algorithm is (asymptotically) strictly greater than the loss incurred by the Chow-Liu algorithm. 7. Proof of main result As stated in Section 5, Theorem 3.3 is a direct consequence of Propositions 5.1 and 5.2, proved in Sections 7.1 and 7.2. 7.1. Proof of Proposition 5.1 By Lemma 5.3, the event E(, γ) := Ecorr () ∩ Estrong () ∩ Ecascade (γ) occurs with probability at least 1−3δ provided n > max{2/2 log(4p2 /δ), 32/γ 2 log(4p2 /γδ). G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 2 15 2 By assumption n > max{800e2β log 4pδ , 300η −2 log 12p ηδ }, hence γ ≤ η/3 and  ≤ min{e−β /20, η/3} . We also assume  < γ for given n number of samples and δ. It remains to show that on the event E(, γ) if  ≤ min{e−β /20, η/3} and γ ≤ η/3 , then √ L(2) (ΠTCL (P ), ΠTCL (Pb)) < η. Let τ = 4/ 1 − tanh β be the threshold used in (5.3) to define ETstrong . For any pair of nodes w, w, e consider pathTCL (w, w). e Let 0 ≤ t < p be the number of weak edges e1 , · · · , et ∈ pathTCL (w, w) e such that |µei | < τ . There are at e consisting of strong edges. We most t + 1 contiguous sub-paths in pathTCL (w, w) call these segments F0 , F1 , . . . , Ft where Fi ⊆ pathTCL (w, w) e could be empty in which case we define µFi = µ bFi = 1. By definition, all edges f ∈ Fi are strong, i.e., |µf | ≥ τ . According to Lemma 9.9, under the event Estrong () all strong edges as in (5.3) are recovered in TCL . Thus, Fi ⊆ ET , which guarantees |b µFi − µFi | ≤ γ under the event Ecascade (γ). Note that Lemma 9.12 gives the bound for t = 0 which corresponds to no weak edges in the path in TCL . For t ≥ 1 we have: Y e∈pathTCL (w,w) e (a) = µ bF0 (b) µ be − t Y i=1 Y µe e∈pathTCL (w,w) e µ bFi µ bei − µF0 ≤ |b µF0 − µF0 | t Y t Y µFi µei i=1 |µFj µej | j=1 + t X i=1 (c) |b µFi µ bei − µFi µei | · |b µF0 | ≤ γτ t + (τ + )t−1 (d) t ≤ γτ + (τ + ) t−1 t X i−1 Y j=1 |b µFi µ bei − µFi µei | i=1 " t X t Y |µFj µej | j=i+1 # |µFi (b µei − µei )| + |b µei (b µFi − µFi )| i=1 (e) |b µFj µ bej | (f ) ≤ (τ + )t−1 (2t + 1) max{γ, } ≤ (τ + )t−1 (2t + 1)η/3  t−1 (g) (h) 4 ≤ √ + (2t + 1)η/3 ≤ [4eβ + ]t−1 (2t + 1)γ 1 − tanh β (i) (j) 2t + 1 (k) t−1 ≤ 5eβ (2t + 1)γ ≤ η/3 ≤ η . t−1 4 Qn In (a) we use pathTCL (w, w) e = {F0 , e1 , · · · , Ft , et , Ft }. (b) uses the bound | i=1 ai − Qi−1 Qn Qn Pn i=1 |ai −bi | j=1 |aj | k=i+1 |bk | obtained via telescoping sum and i=1 bi | ≤ triangle inequality. In (c) we use |µFi | ≤ 1, |b µFi | ≤ 1, |µei | ≤ τ , |b µei | ≤ τ +  G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 16 under Ecorr () and |b µFi − µFi | ≤ γ under Ecascade (γ). In (d) telescoping sum . (f) is true is used again. In (e), we use |b µFi − µFi | ≤ γ and |b µei − µ i | ≤ √ under the assumption γ ≤ η/3. (g) uses the definition of τ = 4/ 1 − tanh β. (h) and (i) use inequality 1 − tanh β ≥ e−2β and β ≥ 0. (j) uses the assumption  ≤ min{e−β /20, η/3} and (k) holds for all t ≥ 1. 7.2. Proof of Proposition 5.2 Recall that P factorizes according to T. The error in correlation between any two variables Xw , Xwe computed along the path TCL as compared to T is errorP,TCL (w, w) e = 2 EP Xw Xwe − EΠTCL (P ) Xw Xwe = 2 Y µe − e∈pathT (w,w) e Y (7.1) µe . e∈pathTCL (w,w) e e . errorP,TCL (w, w) Our goal is to bound L(2) (P, ΠTCL (P )) = supw,w∈V e 2β −2 2 With n > 1200 max{e , η } log(2p /δ) , by Lemma 5.3, the event Ecorr () ∩ strong E () occurs with probability 1 − 2δ with  < min{η/16, e−β /24} . In the following we prove that for  < min{η/16, e−β /24} on the event Ecorr ()∩Estrong () we have the inequality L(2) (P, ΠTCL (P )) < η . We derive a recurrence on the maximum of errorP,TCL (w, w) e in terms of the distance between the nodes w, w e in TCL . Define ∆(k) , sup w,w∈V e |pathTCL (w,w)|=k e e . errorP,TCL (w, w) For each d > 1, we want to bound ∆(d) in terms of ∆(k) for k < d. For nodes at distance one, |pathTCL (w, w)| e = 1 and it follows that errorP,TCL (w, w) e = 0 from the definition of the projected distribution ΠTCL (P ) (matching pairwise marginals across edges). Hence, ∆(1) ≤ η, and we define ∆(0) = 0. e = 0 (again beNote that if pathTCL (w, w) e = pathT (w, w), e then errorP,TCL (w, w) cause correlations are matched across edges). Thus, we assume pathTCL (w, w) e 6= pathT (w, w). e Lemma 10.1 shows the existence of a pair of edges f = (u, u e) and g = (v, ve) with the following properties: • • • • f ∈ pathT (w, w) e and g ∈ pathTCL (w, w). e f∈ / pathTCL (w, w) e and g ∈ / pathT (w, w). e f ∈ pathT (v, ve) and g ∈ pathTCL (u, u e). u, v ∈ SubTreeT,f (w) and u e, ve ∈ SubTreeT,f (w). e Here SubTreeT,f (w) = {i ∈ V; f ∈ / pathT (w, i)} is the set of nodes connected to w in T after removing edge f (see Figure 7.2). We define several sub-paths (see Figure 7.2): A = pathT (u, w) ∩ pathT (u, v) , C = pathT (u, v) \ pathT (u, w) , B = pathT (u, w) \ pathT (u, v) , D = pathTCL (w, v) . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions w B Su bT ree T, C e u f u Ae A D f( w) v g ve Ce e D S Be w e ee Tr b u f T, (we 17 ) Fig 2. Schematic for the proof of Proposition 5.2. The thin solid lines represent paths in T and the dashed lines represent paths in TCL . Edge f is in T but not in TCL , while g is in TCL e may overlap with A ∪ B and A e ∪ B, e respectively. The property but not in T. The sets D and D that g ∈ pathTCL (v, v e) is not shown in this figure. Q Recall that for set of edges S, we defined µS = e∈S µe . Since pathT (w, v) = B ∪ C and B ∩ C = ∅, we have µw,v = µB µC . Similarly, in SubTreeT,f (w) e we define Ae = pathT (e u, w) e ∩ pathT (e u, ve) , Ce = pathT (e u, ve) \ pathT (e u, w) e , Be = pathT (e u, w) e \ pathT (e u, ve) , e = pathTCL (w, D e ve) . The sets are defined so that pathT (v, ve) = C ∪ A ∪ {f } ∪ Ce ∪ Ae where f = (u, u e) and g = (v, ve) ∈ ETCL . Thus, µg = µf µA µC µAeµCe. Since pathT (w, w) e = A∪B∪ e our goal amounts to finding an {f } ∪ Ae ∪ Be and pathTCL (w, w) e = D ∪ {g} ∪ D upper bound for the quantity |µD µg µDe − µA µB µf µAeµBe|. Lemma 10.3 applied to the edges f and g gives |µf | − 4 ≤ |µf µA µC µAeµCe| ≤ |µf | . Thus,     |µf | 1 − |µ2C µ2Ce| ≤ 2|µf | 1 − |µC µCe| ≤ 2|µf | 1 − |µA µC µAeµCe| ≤ 8 . (7.2) Since f ∈ ET and f ∈ / ETCL , under the event Estrong (), f cannot be√a strong edge as defined in Equation (5.3). It follows that |µf | ≤ τ for τ = 4/ 1 − tanh β . e = |pathTCL (w, Let k = |D| = |pathTCL (w, v)| and e k = |D| e ve)|, so d = k + e k + 1. By definition of ∆(·) function: errorP,TCL (w, v) = |µD − µB µC | ≤ ∆(k) , errorP,TCL (w, e ve) = |µDe − µBeµCe| ≤ ∆(e k) (7.3) G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 18 Using µg = µA µC µf µAeµCe and subsequently Equation (7.3), e errorP,TCL (w, w) = |µD µg µDe − µA µB µf µAeµBe| = |µD µA µC µf µAeµCeµDe − µA µB µf µAeµBe| = |µA µf µAe| · |µD µC µCeµDe − µB µBe| = |µA µf µAe| · |µC µCe(µD − µB µC + µB µC )(µDe − µBeµCe + µBeµCe) − µB µBe|  ≤ |µA µf µAe| · |µC µCeµB µC µBeµCe − µB µBe| + |µC µCe(µD − µB µC )(µD − µB µC )|  + |µC µCeµBeµCe(µD − µB µC )| + |µC µCeµB µC (µDe − µBeµCe)|   (a) ≤ |µf µA µAeµB µBe||µ2C µ2Ce − 1| + |µf | ∆(k)∆(e k) + ∆(k) + ∆(e k)   (b) 4 ∆(k) + ∆(e k) + ∆(k)∆(e k) ≤ 8 + √ 1 − tanh β (c) ≤ 8 + 4eβ (2η + η 2 ) ≤ η . Inequality (a) follows from (7.3). Inequality (b) uses Equation (7.2) and |µf | ≤ τ . We showed that ∆(1) ≤ η. In (c) and using ∆(1) ≤ η, we use induction on the η function ∆: the assumption  < min{ 16 , e−β /24} and ∆(k) < η for all k < d gives ∆(d) ≤ η . 8. Sample complexity for exact structure learning problem 8.1. Samples necessary for structure learning (proof of Theorem 3.2) We construct a family of trees that is difficult to distinguish. Suppose that p is odd (for simplicity) and let the graph T0 be a path with associated parameters 0 0 θ0 given by θi,i+1 = α for odd values of i and θi,i+1 = β for even values of i. For i i each odd value of i ≤ p − 2 we let θ be equal to θ0 everywhere except θi,i+1 =0 i 0 and θi,i+2 = α. There are (p + 1)/2 models in total (including θ ). The symmetrized KL-divergence between two zero-field Ising models θ and θ0 has the convenient form X 0 J(θkθ0 ) , D(θkθ0 ) + D(θ0 kθ) = (θij − θij )(µij − µ0ij ) . i<j Here µij and µ0ij are the pairwise correlations between nodes i and j. A small calculation leads to J(θ0 kθi ) = 2α(tanh α − tanh α tanh β) = 2α(tanh α) ≤ 4α2 e−2β . 2e−β eβ + e−β (8.1) G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 19 Here we used tanh α ≤ α for α ≥ 0. Equation (8.1) can be plugged into Fano’s inequality to complete the proof of Theorem 3.2. We use the following version of Fano’s inequality, which can be found, for example, as Corollary 2.6 in [30]. It gives a lower bound on the error probability in terms of the KL-divergence between pairs of points in the parameter space, where KL-divergence between two distributions P and Q on a space X is defined as X P (x) . D(P kQ) = P (x) log Q(x) x∈X Lemma 8.1 (Fano’s inequality). Assume that M ≥ 2 and that Θ contains elements θ0 , θ1 , . . . , θM . Let Qθj denote the probability law of the observation X under model θj . If M 1 X D(Qθj kQθ0 ) ≤ γ log M M + 1 j=1 for 0 < γ < 1/8, then the probability of error is bounded as pe ≥ (8.2) log (M +1)−1 −γ log M . 8.2. Sufficient samples for structure learning (proof of Theorem 3.3) Using Definition 5.4, Chow-Liu tree, TCL recovers strong edges under the event Estrong (). Thus, if the weakest edges in the original tree, T is strong enough, we can guarantee that with high probability, TCL = T. Note that using lemma 9.9, the event Estrong () defined in Equation (5.4) occurs with probability 1 − δ with p  = 2/n log(2p2 /δ) . Assuming that the original tree has parameters θ ∈ Ωα,β , the weakest edge should satisfy the following property to guarantee the correct recovery of all the egdes of the tree T under the event Estrong () : tanh α ≥ √ 4 . 1 − tanh β Thus the number of samples should satisfy: n> 16 2p2 log . δ tanh2 (α)(1 − tanh β) 1 β 2β Also tanh−1 (x) ≤ 1/x + 1 and 1−tanh max{α−2 , 1} log β ≤ e . Hence n > 6e CL guarantees T = T with probability at least 1 − δ. p δ Theorem 3.5. We assume that the tree we study is a Markov chain such that x1 → x2 → · · · → xp . We choose M different models over this Markov chain each denoted by the edge parameters θ(m) . We assume that for i = 1, · · · , p − 1, (1) we have θi,i+1 = atanh(η). We also assume that in the m-th model we have G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions (m) 20 (m) θm,m+1 = 0 and the remaining edge weights θi,i+1 = atanh(η). Thus, the number of models we try to discriminate is M = p. max |Eθ(m0 ) [Xi Xj ] − Eθ(m) [Xi Xj ]| ≥ η i,j 0 J(θm kθm ) ≤ 2η atanh(η) Using Fano’s inequality in Lemma 8.1 gives the bound. 9. Control of events Ecorr (), Estrong (), and Ecascade () We state a standard form of Hoeffding inequality: Lemma 9.1 (Hoeffding’s Inequality). Let Z 1 , · · · , Z n be n i.i.d. random  variables taking values in the interval [−1, 1] and let Sn = n1 Z 1 + · · · + Z n . Then, Pr [|Sn − EZ| > t] ≤ 2 exp(−nt2 /2) . Lemma 9.2. The event Ecorr () defined in (5.2) occurs with probability at least 1 − 2p2 exp(−n2 /2). Proof. For each pair of nodes w, w, e we define Z = Xw Xwe and Hoeffding’s inequality stated in Lemma 9.1 to get Pr [|µw,we − µ bw,we | > ] ≤ 2 exp(−n2 /2) . Union bound over pairs of nodes completes the proof. We use the standard Bernstein’s inequality quoted from [30]. Lemma 9.3 (Bernstein’s Inequality). Let Z 1 , ..., Z n be i.i.d. random variables. Suppose that for all i, |Z i − E[Z]| ≤ M almost surely. Then, for all positive t, # " n   X t2 i Pr Z − nE[Z] ≥ t ≤ 2 exp − 2nVAR(Z) + 23 M t i=1 For a given pair of nodes u, u e and edge e = (w, w) e ∈ pathT (u, u e), we define the random variable Ze,u,eu = Xw Xwe − Xu Xue = Xw Xwe (1 − Xu Xw Xwe Xue ) . (9.1) This random variable is used to study the event e ∈ / TCL and (u, u e) ∈ TCL which happens only if |b µueu | ≥ |b µe |. To bound the probability of this event we study the deviation bounds on the random variable Ze,u,eu . Let A = pathT (u, u e) \ {e} so that µueu = µA µe . Lemma 9.4. For all u, u e ∈ V and e = (w, w) e ∈ pathT (u, u e), given n samples (2) (n) (1) Ze,u,eu , Ze,u,eu , · · · , Ze,u,eu defined in (9.1), with probability at least 1 − δ/2 n X i=1 where  = n o p (i) Ze,u,eu − nµe (1 − µA ) ≤ max 16n2 , 4n 1 − µA , p 2/n log(2p2 /δ) and A = pathT (u, u e) \ {e} . (9.2) G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 21 Proof. It follows from the fact that P is Markov with respect to T and e = (w, w) e ∈ pathT (u, u e) that Xw Xwe and Xu Xw Xwe Xue are independent. Note that P (Xw Xwe = 1) = 1 + µe , 2 P (Xw Xwe = −1) = 1 − µe . 2 Similarly, the distribution of Xu Xw Xue Xwe is function of µA . As a result, the random variable Ze,u,eu ∈ {−2, 0, 2} defined in (9.1) has the following distribution:  e 1−µA  w.p. 1−µ −2 2 2 A Z= 0 w.p. 1+µ 2   e 1−µA +2 w.p. 1+µ . 2 2 The first and second moments of Z are E[Ze,u,eu ] = µe (1 − µA ) and Var[Ze,u,eu ] = (1−µA )[2−µ2e (1−µA )] . By Bernstein’s inequality (Lemma 9.3), with probability at least 1 − δ/2 ( ) r n X 4Var[Ze,u,eu ] 8 4 4 (i) Ze,u,eu − nE[Z] ≤ n max log( ), log( ) . 3n δ n δ i=1 Using a union bound for all pairs of nodes u, u e and edges e = (w, w) e ∈ pathT (u, u e), n X (i) Ze,u,eu − nµe (1 − µA ) i=1 ≤ n max ( 8 4p3 log( ), 3n δ r ) 4(1 − µA )[2 − µ2e (1 − µA )] 4p3 log( ) . n δ q 3 8(1−µA )[2−µ2e (1−µA )] 2 − µ2e (1 − µA ) ≤ 2 and definition of  gives log( 4pδ ) ≤ n 3 √ 8 4 1 − µA . Also, 3n log( 4pδ ) ≤ 42 which gives the lemma. Similarly to the above discussion, let Ye,u,eu = Xw Xwe + Xu Xue . The proof of the following lemma follows the same steps as Lemma 9.4. p Lemma 9.5. Given n samples, let  = 2/n log(2p2 /δ) . Then, with probability at least 1 − δ , for all u, u e ∈ V and e = (w, w) e ∈ pathT (u, u e), and (1) (2) (n) Ye,u,eu , Ye,u,eu , · · · , Ye,u,eu defined in (9.1), n X i=1 n o p (i) Ye,u,eu − nµe (1 + µA ) ≤ max 16n2 , 4n (1 + µA ) . (9.3) We defined the event Estrong () in (5.4) as the event that all the strong edges in T as defined in (5.3) are recovered in TCL . In Lemma 9.8 we show that the deviation bounds for the variables Ze,u,eu and Ye,u,eu stated in (9.2) and (9.3) imply that Estrong () holds. The following lemma is a well-known consequence of max-weight spanning tree algorithm used to construct the Chow-Liu tree. G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 22 Lemma 9.6 (Error characterization in Chow-Liu tree). Consider the complete graph on p nodes with weights |b µij | on each edge (i, j). Let TCL be the maximum weight spanning tree of this graph. If edge (w, w) e ∈ / TCL , then |b µwwe | ≤ |b µij | for all (i, j) ∈ pathTCL (w, w) e . Proof. We include a proof for completeness. For edge (w, w) e ∈ / TCL , if there is CL an edge (i, j) ∈ pathTCL (w, w) e such that |b µwwe | ≥ |b µij |, then T cannot be the maximum weight spanning tree. To show that, we look at the tree T0 such that (w, w) e ∈ T0 and / T0 P and all other edges of TCL appear in T0 . Note that: P (i, j) ∈ 0 weight(T ) , e∈T0 |b µe | = e∈TCL |b µe | + |b µwwe | − µ bij ≥ weight(TCL ) . Lemma 9.7. If there exists a pair of edges f = (w, w) e and g = (u, u e) such that f ∈ T, f ∈ / TCL , g ∈ TCL , g ∈ / T and additionally f ∈ pathT (u, u e) and g ∈ pathTCL (w, w). e Then, ! n ! n X X (i) (i) Zf,u,eu Yf,u,eu < 0 i=1 i=1 Proof. Using Lemma 9.6, f = (w, w) e ∈ / TCL and g = (u, u e) ∈ pathTCL (w, w) e gives 2 2 |b µf | ≤ |b µg |. Hence |b µf | ≤ |b µg | and 0 ≥ |b µf |2 − |b µg |2 = (b µf − µ bg )(b µf + µ bg ) n X 1 = 2 n i=1 n X 1 = 2 n i=1 (i) Xw(i) Xwe (i) Zf,u,eu ! − (i) Xu(i) Xue n X i=1 (i) Yf,u,eu ! ! n X i=1 (i) (i) Xw Xwe + (i) Xu(i) Xue ! where in the last equality we used f ∈ pathT (u, u e) and the definition of random variables Zf,u,eu and Yf,u,eu . Lemma 9.8. Under the event described in Lemmas 9.4 and 9.5, if there is an 4 edge f ∈ T missing from the Chow-Liu tree, f ∈ / TCL , then |µf | ≤ τ = √1−tanh . β Proof. We use Lemma 10.1 for (w, w) e = f to show that for the edge f ∈ T and f ∈ / TCL , there exists an edge g = (u, u e) ∈ TCL such that g ∈ / T, f ∈ pathT (u, u e) and g ∈ path e (Figure 3). Then according to Lemma CL (w, w) T  P  Pn (i) (i) n < 0. Note that EZf,u,eu = µf (1 − µA ) and 9.7, i=1 Zf,u,e i=1 Yf,u,e u u EYf,u,eu = µf (1+µA) using the definition e)\{f } . Hence EZf,u,eu EYf,u,eu ≥  P A = path  T (u, u Pn (i) (i) n 0 . Thus, to satisfy i=1 Zf,u,e i=1 Yf,u,e u u < 0, either one of the following inequalities must hold: | n X | i=1 n X i=1 (i) Zf,u,eu − nEZf,u,eu | ≥ n|EZf,u,eu | (i) Yf,u,eu − nEYf,u,eu | ≥ n|EYf,u,eu | . or G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 23 Under the events described in Lemmas 9.4 and 9.5, this holds only if either one of these inequalities holds: n o p |µf (1 − µA )| ≤ max 42 , 4 (1 − µA ) n o p |µf (1 + µA )| ≤ max 42 , 4 (1 + µA ) . This implies that  4 42 4 162 , ,√ , 1 − µA 1 − µA 1 + µA 1 + µA   4 162 ≤ max √ . , 1 − tanh β 1 − tanh β |µf | ≤ max Note that if √ 4 1−tanh β √ 4 1−tanh β ≤ 1, then √  ≥ 1 then the bound on |µf | ≤ 1 is tirivial. And if √ 4 1−tanh β > 162 1−tanh β . Hence, |µf | ≤ √ 4 . 1−tanh β p Lemma 9.9. With  = 2/n log(2p2 /δ), event Estrong () defined in (5.4) happens with probability at least 1 − δ. Proof. Lemma 9.8 shows that, under the event described in Lemmas 9.4 and 9.5 the missing edges f ∈ T and f ∈ / TCL satisfy |µf | ≤ τ . Hence, Lemmas 9.4 and 9.5 show that with probability at least 1 − δ, all edges e ∈ T such that |µe | ≥ τ are recovered by Chow-Liu algorithm e ∈ TCL . Lemma 9.10. Let the distribution P (x) ∈ P(T) come from the class of zerofield Ising models on the tree T = (V, E). For all e = (i, j) ∈ E let Ye = Xi Xj . Then the set of random variables Ye are jointly independent. This lemma follows from the factorization of distribution P (x) ∈ P(T) in Equation (1.1). The following lemma is restatement of Theorem 9 in [4] for our desired application. Lemma 9.11. [[4], Theorem 9] Let Y1 , · · · , Yd ∈ {−1, +1}d be d independent (i) random variables with E[Yj ] = µj . Having n i.i.d. samples yj for j = 1, · · · , d P (i) n and i = 1, · · · , n , let µ bj = n1 i=1 yj be the empirical average of Yj . Then for any γ > 0 ,  Y  d d Y 8 Pr µ bj − µj ≥ γ ≤ exp(−γ 2 n/32) . γ j=1 j=1 Proof. d Y j=1 µ bj = d  X n Y 1 j=1 n i=1 (i) yj  = d n 1 Y X (ij ) 1 yj = d d n j=1 i =1 n j n X d Y i1 ,··· ,id =1 j=1 (ij ) yj G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 24 For every l ∈ {1, · · · , n} , one can write d Y j=1 µ bj = 1 nd d Y n X (ij +l) yj i1 ,··· ,id =1 j=1 where ij + l are taken modulo n . When we take average over all l , we have d Y j=1 µ bj = 1 nd n X i1 ,··· ,id n d 1 X Y (ij +l) yj n =1 j=1 (9.4) l=1 For every initial multi-indes i∗ = (i1 , · · · , id ) , we define ( Pn Qd Qd (i +l) − j=1 µj ≥ γ/2 0 if n1 l=1 j=1 yj ∗ d(i∗ ) = 2 otherwise . By definition of d(i∗ ), we have n d d 1 X Y (i∗ +l) Y yj − µj ≤ d(i∗ ) + γ/2 n j=1 j=1 (9.5) l=1 Qd Qd (i +1) (i +n) Also, note that for any fixed i∗ , the random variables j=1 yj ∗ , · · · , j=1 yj ∗ Qd are independent with expectation j=1 µj . Therefore, using Hoeffding inequality 9.1, we have E[d(i∗ )] ≤ 4 exp(−γ 2 n/32) . (9.6) We use Equations (9.4) and (9.5) to get the bound:    Y d d Y 1 µ bj − µj ≥ γ = Pr Pr nd j=1 j=1  1 ≤ Pr d n  1 ≤ Pr d n n X i1 ,··· ,id  n d d 1 X Y (ij +l) Y yj − µj ≥ γ n =1 j=1 j=1 l=1  n d d 1 X Y (ij +l) Y yj − µj ≥ γ n i1 ,··· ,id =1 j=1 l=1 j=1  n X d(i∗ ) ≥ γ/2 n X i1 ,··· ,id =1 8 ≤ exp(−γ 2 n/32) , γ where in the last inequality we used Markov inequality and Equation (9.6). Lemma 9.12. The event Ecascade () defined in (5.5) occurs with probability at 2 least 1 − 4p exp(−2 n/32). G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions e u f u w v g ve 25 w e Fig 3. The schematics showing the pairs of edges f and g satisfying properties given in b lemma 10.1. The solid lines represent the tree T and the dashed lines represent the tree T. There always exists pairs of edges f and g such that f = (u, u e) ∈ pathT (w, w) e ∩ pathT (v, v e) and g = (v, v e) ∈ pathT e ∩ pathT e). b (w, w) b (u, u Proof. For given pair of nodes w, w, e define pathT (w, w) e = {e1 , e2 , · · · , ed } and use the notation µi = µei and µ bi = µ bei . We apply Lemma 9.11 to show d d Y  Y 8 Pr | µ bj − µj | ≤ ] ≥ exp(−2 n/32) .  j=1 j=1 Applying a union bound over for probability of Ecascade (). p 2  ≤ p2 /2 pairs of nodes w, w e provides a lower 10. Two trees lemma b be two spanning trees on set of nodes V. Let w, w Lemma 10.1. Let T and T e e Then there exists a pair be a pair of nodes such that pathT (w, w) e 6= pathTb (w, w). of edges f , (u, u e) ∈ pathT (w, w) e and g , (v, ve) ∈ pathTb (w, w) e such that (i) f ∈ / pathTb (w, w) e and g ∈ / pathT (w, w) e e) (ii) f ∈ pathT (v, ve) and g ∈ pathTb (u, u Since f ∈ pathT (w, w) e and f ∈ pathT (v, ve), we can choose the labeling of the end points of the edges f = (u, u e) and g = (v, ve) such that u, v ∈ SubTreeT,f (w) and u e, ve ∈ SubTreeT,f (w). e [as in Figure 3] Proof. Define a graph G such that the nodes on this graph are the nodes in pathT (w, w) e ∪ pathTb (w, w). e We define two types of edges in this graph corresponding to the edges in pathT (w, w) e and the edges in pathTb (w, w). e Then, we merge any pair of nodes between which there are both types of edges. Note that since pathT (w, w) e 6= pathTb (w, w), e the nodes w and w e will not be merged with each other during this process. The remaining nodes in the pathT (w, w) e are labeled u1 , u2 , · · · , uK−1 and the remaining edges are labeled f1 , f2 , · · · , fK . Similarly, the remaining nodes in pathTb (w, w) e are labeled v1 , v2 , · · · , vL−1 and the remaining edges are labeled g1 , g2 , · · · , gL . Where K and L are positive integers. We label these edges so that fk = (uk−1 , uk ) and gl = (vl−1 , vl ). This G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 26 notation is consistent if we define u0 = v0 = w and uK = vL = w. e Note that in this notation one node may have several labels. According to the definition, fk ∈ pathT (w, w) e and gl ∈ pathTb (w, w) e for all k = 1, · · · , K and l = 1, · · · , L. The process of merging nodes as described guarantees that fk ∈ / pathTb (w, w) e and gl ∈ / pathT (w, w). e Thus, in order to prove the existence of edges with the properties given in the lemma, all we have to do is to find a pair of edges fk∗ and gl∗ such that fk∗ ∈ pathT (vl∗ −1 , vl∗ ) and gl∗ ∈ pathTb (uk∗ −1 , uk∗ ). b to be the graph with the nodes V b = {w, w, Now we define another graph G e u1 , u2 , · · · , uK , v1 , v2 , · · · , vL }. There are two types of edges in this graph correb We denote the edges sponding to the connectivity in the spanning tree T and T. b corresponding to the tree T by E and the edges corresponding to the tree T b Consequently, E and Eb both construct two different spanning trees of the by E. b on the nodes V. graph G The set of edges E determine a spanning tree denoted by S and satisfy all the conditional independence properties satisfied by the original spanning tree b Concretely, any pair of nodes (i, j) in V b are connected by an T on the nodes V. edge in E if and only if all the nodes in pathT (i, j) have been removed from V b i.e., V b ∩ pathT (i, j) = {i, j}. during construction of G, b Similarly, the edges E are chosen so that the spanning tree implied them, denoted by b S satisfies all the conditional independence properties satisfied by b the original spanning tree T. We define the set Dk = {l; gl ∈ pathbS (w, w) e ∩ pathbS (uk−1 , uk )} to be the set e which are also in the path connecting the two ends of of edges in pathbS (w, w) fk in the tree b S. Similarly, for l = 1, · · · , L we define the sets Cl = {k; fk ∈ ∗ ∗ pathS (w, w)∩path e S (vl−1 , vl )}. If there exists the pair integers k and l such that ∗ ∗ l ∈ Dk∗ and k ∈ Cl∗ , then they correspond to the edges fk∗ ∈ pathT (vl∗ −1 , vl∗ ) and gl∗ ∈ pathTb (uk∗ −1 , uk∗ ). As stated previously, this pair of edges satisfy all the properties given in the lemma. To find such pair of l and k we prove a “no gap” property of the sets {Cl }, with a similar statement holding for {Dk }. We will use the following notation in the statement of the “no gap” lemma. Let’s define 0 D k0 = k [ k=1 Dk , D k0 = K [ k=K−k0 0 Dk , C l0 = l [ Cl , l=1 C l0 = L [ Cl . l=L−l0 Lemma 10.2 (“No gap” lemma). For any l0 > 0, if C l0 6= ∅, there exists k 0 > 0 such that C l0 = {1, 2, · · · , k 0 }. For any l0 > 0, if C l0 6= ∅, then there exists k 0 ≥ 0 such that C l0 = {K − k 0 , · · · , K}. To prove that the “no gap” property of the sets {Cl } and {Dk }, we define the following function M : {0, 1, 2, · · · , K} → {−1, 0, 1, 2, · · · , K} such that M(0) = −1 and for 1 ≤ k 0 ≤ K, M (k 0 ) = max{i; i ∈ ∪l∈Dk0 Cl }. (10.1) G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 27 Note that Dk0 ⊆ Dk0 +1 and consequently ∪l∈Dk0 Cl ⊆ ∪l∈Dk0 +1 Cl . Thus, the function M(k 0 ) is non-decreasing over its domain. Also, due to the no gap property of the sequence of sets {Cl } and {Dk }, we know that DK = {1, · · · , L} and ∪L l=1 Cl = C L = {1, · · · , K}. Thus, M(K) = K. Define k ∗ = min{k : 1 ≤ k ≤ K and k ≤ M (k)}. Thus, we know that k ∗ ≤ M(k ∗ ) and M (k ∗ − 1) < k ∗ − 1 < k ∗ . So, M(k ∗ − 1) < k ∗ ≤ M(k ∗ ). According to the definition given by equation (10.1), there exists some l∗ ∈ Dk∗ such that k ∗ ∈ Cl∗ . As mentioned before, this pair integers determine the edges that satisfy the properties given in the lemma. Proof of Lemma 10.2. For each node vl we define a pointer pv (l) = max{k; uk ∈ pathS (w, vl )}. Note that pv (0) = 0 and pv (L) = K. Similarly we define the sequence of pointers pu (k) = max{{l; vl ∈ pathbS (w, uk )}}. These pointers determine the sequence of sets Cl ’s (and similarly for Dk ’s) as follows: For any l > 0, if pv (l) > pv (l−1), Cl = {pv (l−1)+1, · · · , pv (l)}. If pv (l) = pv (l−1), then Cl = ∅. And if pv (l) < pv (l−1), then Cl = {pv (l)+1, · · · , pv (l−1)}. Based on this characterization of the sets Cl ’s, the nested version of the sets Cl ’s is o n C l0 = 1, · · · , max0 pv (l) . l≤l This is nonempty if and only if maxl≤l0 pv (l) > 0. Similarly, we have that n o C l0 = min 0 pv (l), · · · , K . l≥L−l Similar reasoning gives n o Dk0 = 1, · · · , max0 pu (k) k≤k and D k0 = n o min 0 pu (k), · · · , L . k≥K−k Observe that maxl≤l0 pv (l) as a function of 0 ≤ l0 ≤ L, is monotonically increasing, where pv (0) = 0 and pv (L) = K. Similarly, maxk≤k0 pu (k) as a function of 0 ≤ k 0 ≤ K, is monotonically increasing, where pu (0) = 0 and pu (K) = L. Consequently, there exists a pair of integers l and k such that k ∈ Cl and l ∈ Dk . Lemma 10.3. Suppose that the distribution P (x) is from an Ising model on tree T with pairwise correlations µw,we for each w, w e ∈ V. Assume event Ecorr () b be the Chow-Liu tree. For any pair of edges (u, u holds. Let T e) ∈ pathT (v, ve) and b (v, ve) ∈ pathTb (u, u e) with (u, u e) ∈ / T and (v, ve) ∈ / T, we have |µu,eu | − 4 ≤ |µv,ev | ≤ |µu,eu | . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 28 b and (v, ve) ∈ pathb (u, u Proof. Lemma 9.6 applied to (u, u e) ∈ /T e) gives |b µv,ev | ≥ T |b µu,eu |. The first inequality now follows from the fact that on the event Ecorr () we have |b µu,eu − µu,eu | ≤ 2 and |b µv,ev − µv,ev | ≤ 2. Q The second inequality follows as |µv,ev | = | e∈pathT (v,ev) µe | ≤ |µu,eu |, since µu,eu appears in the product and |µe | ≤ 1 for all e. 11. Information-projection lemmas Lemma 11.1. For a given tree T = (V, E), the projection of the distribution P (x) onto the class of the Ising models on T with no external field (as in Equation (1.1)) Pe(x) = ΠT (P ) , arg min D(P kQ) with the parameter vecQ∈PT tors θe ∈ Ω0,∞ (T ) has the following property: tanh(θeij ) = µij for all (i, j) ∈ E, where µij = EP Xi Xj is the pairwise correlation of the variables under the disP 1+µ tribution P (x). Also, we would have D(P kPe) = −H(P ) + (i,j)∈ET HB ( 2 ij ) 1 is the binary entropy function. where HB (x) = x log x1 + (1 − x) log 1−x Proof. This lemma is a direct corollary of Theorem 3.3 in [11]. Note that Pe(x) is the reverse I-projection of distribution P (x) onto the exponential family with potential functions Xi Xj for (i, j) ∈ E. Hence EPe Xi Xj = EP Xi Xj for (i, j) ∈ E which gives tanh(θeij ) = µij . Section 3.4.2 in [32] also addresses this problem in depth. We provide the proof for the sake of completeness here: For the tree T = (V, E) and any Q Q ∈ PT with parameter vector θ, using (1.1), Q could be factorized as Q(x) = (i,j)∈E (1 + tanh θij xi xj )/2, where EQ [Xi Xj ] = tanh θij . Let spin random variables Ye = Xi Xj for all e = (i, j) ∈ E so that Q(Ye = +) = (1 + tanh θij )/2 and P (Ye = +) = (1 + µij )/2 where µij = EP [Xi Xj ]. Given the general distribution P and any Q ∈ PT with parameters θ, P ] = −H(P ) − EP [log Q(X)] Q Y 1 + tanh θij Xi Xj = −H(P ) − EP [log ] 2 D(P kQ) = EP [log (i,j)∈E = −H(P ) − X e=(i,j)∈E = −H(P ) − X EP [log 1 + tanh θij Ye ] 2 EP [log Q(Ye )] = e∈E = −H(P ) + X e∈E HB (P (Ye )) + X D(P (Ye )kQ(Ye )) e∈E Pe = arg minQ∈PT D(P kQ) with parameters θe satisfies the property Pe(Ye ) = P (Ye ) for all e ∈ E, hence θeij = µij for all (i, j) ∈ E. Consequently, D(P kPe) = P 1+µ −H(P ) + e∈E HB ( 2 ij ) . G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 29 Lemma 11.2. Given distribution Pb, the tree TCL defined in Definition 3.1 can be found as the maximum weight spanning tree over a complete weighted graph where the weights of each edge (i, j) is |b µij | = |EPb [Xi Xj ]| . Proof. Using Lemma 11.1, X X 1+µ bij 1+µ bij TCL = arg min ) − H(Pb) = arg min ). HB ( HB ( 2 2 T∈T T∈T (i,j)∈ET (i,j)∈ET The maximum weight spanning tree can be implemented greedily using Kruskal algorithm or Prim’s algorithm [10]. So, finding maximum weight spanning tree only depends on the order of the edges of the graph after being sorted. 1+b µ µij | . So, sorting all the HB ( 2 ij ) is a monotonically increasing function of |b 1+b µ edges (i, j) in the complete graph based HB ( 2 ij ) or |b µij | gives the same order. This gives X X 1+µ bij ) = arg min |b µij | . TCL = arg min HB ( 2 T∈T T∈T (i,j)∈ET (i,j)∈ET Discussion Learning the structure of Ising models on trees with finite number of samples is proved to be impossible in the presence of extremely weak edges. Yet, we proved that using the maximum likelihood tree as an estimation of the structure would enable us to have an accurate estimation of the the original distribution for the purpose of subsequent inference tasks. The sample complexity of this estimation is given in this paper. Acknowledgment We thank Gregory Wornell, Lizhong Zheng, Gabor Lugosi, Devavrat Shah, David Gamarnik, Elchanan Mossel and Andrea Montanari for stimulating discussions. References [1] Abbeel, P., Koller, D., and Ng, A. Learning factor graphs in polynomial time and sample complexity. JMLR (2006). [2] Agarwala, R., Bafna, V., Farach, M., Paterson, M., and Thorup, M. On the approximability of numerical taxonomy (fitting distances by tree metrics). SIAM Journal on Computing 28, 3 (1998), 1073–1085. [3] Anandkumar, A., Huang, F., Hsu, D., and Kakade, S. Learning mixtures of tree graphical models. In NIPS (2012). [4] Babichenko, Y., Barman, S., and Peretz, R. Empirical distribution of equilibrium play and its testing application. arXiv preprint arXiv:1310.7654 (2013). G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 30 [5] Bento, J., and Montanari, A. Which graphical models are difficult to learn? In NIPS (2009). [6] Bresler, G. Efficiently learning ising models on arbitrary graphs. In Proceedings of the Forty-Seventh Annual ACM on Symposium on Theory of Computing (2015), ACM, pp. 771–782. [7] Bresler, G., Mossel, E., and Sly, A. Reconstruction of Markov random fields from samples: Some observations and algorithms. In APPROX (2008). [8] Chow, C., and Liu, C. Approximating discrete probability distributions with dependence trees. IEEE Trans. on Info. Theory 14, 3 (1968), 462–467. [9] Chow, C.-Y., and Wagner, T. Consistency of an estimate of treedependent probability distributions (corresp.). Information Theory, IEEE Transactions on 19, 3 (1973), 369–371. [10] Cormen, T. H., Leiserson, C. E., Rivest, R. L., and Stein, C. Introduction to algorithms, vol. 6. MIT press Cambridge, 2001. [11] Csiszár, I., and Shields, P. C. Information theory and statistics: A tutorial. Now Publishers Inc, 2004. [12] Dasgupta, S. Learning polytrees. In UAI (1999). [13] Daskalakis, C., Mossel, M., and Roch, S. Phylogenies without branch bounds: Contracting the short, pruning the deep. Research in Computational Molecular Biology: 13th Annual International Conference, RECOMB 2009, Tucson, AZ, USA, May 18-21, 2009. Proceedings (2009), 451 – 465. [14] Erdös, P. L., Steel, M. A., Székely, L., and Warnow, T. J. A few logs suffice to build (almost) all trees: Part ii. Theoretical Computer Science 221, 1 (1999), 77–118. [15] Heinemann, U., and Globerson, A. Inferning with high girth graphical models. In Proceedings of the 31st International Conference on Machine Learning (ICML-14) (2014), pp. 1260–1268. [16] Jog, V., and Loh, P.-L. On model misspecification and KL separation for Gaussian graphical models. In Information Theory (ISIT), 2015 IEEE International Symposium on (2015), IEEE, pp. 1174–1178. [17] Lauritzen, S. Graphical models. Oxford University Press, 1996. [18] Liu, H., Xu, M., Gu, H., Gupta, A., Lafferty, J., and Wasserman, L. Forest density estimation. The Journal of Machine Learning Research 12 (2011), 907–951. [19] Meila, M., and Jordan, M. I. Learning with mixtures of trees. The Journal of Machine Learning Research 1 (2001), 1–48. [20] Meinshausen, N., and Bühlmann, P. High-dimensional graphs and variable selection with the lasso. The Annals of Statistics (2006), 1436– 1462. [21] Mossel, E. Distorted metrics on trees and phylogenetic forests. IEEE/ACM Transactions on Computational Biology and Bioinformatics 4 (2007). [22] Narasimhan, M., and Bilmes, J. PAC-learning bounded tree-width graphical models. in Uncertainty in Artificial Intelligence: Proceedings of the Twentieth Conference (2004), 410–417. G. Bresler and M. Karzand/ Structure Learning for Trees to Make Predictions 31 [23] Pearl, J. Probabilistic Reasoning in Intelligent Systems: Networks of Plausible Inference. Morgan Kaufmann, 1988. [24] Ravikumar, P., Wainwright, M., and Lafferty, J. High-dimensional Ising model selection using `1 -regularized logistic regression. Annals of Statistics 38, 3 (2010), 1287–1319. [25] Santhanam, N. P., and Wainwright, M. J. Information-theoretic limits of selecting binary graphical models in high dimensions. IEEE Trans. on Info. Theory 58, 7 (2012), 4117–4134. [26] Srebro, N. Maximum likelihood bounded tree-width Markov networks. In UAI (2001). [27] Tan, V. Y., Anandkumar, A., Tong, L., and Willsky, A. S. A large-deviation analysis of the maximum-likelihood learning of Markov tree structures. Information Theory, IEEE Transactions on 57, 3 (2011), 1714– 1735. [28] Tan, V. Y., Anandkumar, A., and Willsky, A. S. Learning highdimensional Markov forest distributions: Analysis of error rates. The Journal of Machine Learning Research 12 (2011), 1617–1653. [29] Tandon, R., Shanmugam, K., Ravikumar, P. K., and Dimakis, A. G. On the information theoretic limits of learning Ising models. In Advances in Neural Information Processing Systems (2014), pp. 2303–2311. [30] Tsybakov, A. B. Introduction to nonparametric estimation. Springer, 2008. [31] Wainwright, M. Estimating the “wrong” graphical model: Benefits in the computation-limited setting. The Journal of Machine Learning Research 7 (2006), 1829–1857. [32] Wainwright, M., and Jordan, M. Graphical models, exponential families, and variational inference. Foundations and Trends in Machine Learning 1, 1-2 (2008), 1–305. [33] Wainwright, M. J. Tree-reweighted belief propagation algorithms and approximate ML estimation via pseudo-moment matching. IN AISTATS (2003). [34] Wu, R., Srikant, R., and Ni, J. Learning loosely connected Markov random fields. Stochastic Systems 3, 2 (2013), 362–404.
10math.ST
Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach ∗ Favio Ezequiel Miranda-Perea Lourdes del Carmen González-Huesca Departamento de Matemáticas, Facultad de Ciencias UNAM Circuito Exterior S/N, Cd. Universitaria, 04510, México D.F., México [email protected] [email protected] We present an extension of the second-order logic AF2 with iso-style inductive and coinductive definitions specifically designed to extract programs from proofs à la Krivine-Parigot by means of primitive (co)recursion principles. Our logic includes primitive constructors of least and greatest fixed points of predicate transformers, but contrary to the common approach, we do not restrict ourselves to positive operators to ensure monotonicity, instead we use the Mendler-style, motivated here by the concept of monotonization of an arbitrary operator on a complete lattice. We prove an adequacy theorem with respect to a realizability semantics based on SAT (saturated) sets and SATvalued functions and as a consequence we obtain the strong normalization property for the proof-term reduction, an important feature which is absent in previous related work. Keywords: Mendler-style, (co)inductive definitions, primitive (co)recursion, strong normalization, saturated set, monotonization, second-order logic, programming with proofs. 1 Introduction The system AF2 for second-order intuitionistic logic introduced by Leivant and Krivine [5, 4], is one of the most fruitful systems obtained by the Curry-Howard correspondence. It types exactly the same terms as the system F of Girard and Reynolds and shares with it the properties of strong normalization and subject reduction. Its main improvement with respect to system F is that it allows the extraction of programs via the programming-with-proofs paradigm of Krivine and Parigot. This method, originally developed in [3] (see also [5]) ensures the correctness of programs (λ -terms) extracted from proofs of termination statements of functions involving formal data types, that is, from proofs of totality. Well known results ensure the extraction of programs for all functions whose termination is provable in second order Peano arithmetic. Nevertheless this result, satisfactory from the extensional point of view does not suffice for an intensional view concerning programs. In AF2 we can get programs for all needed functions, but these do not have necessarily the intended behavior, see [13]. To solve this problem some extensions of AF2 with least fixed points (TTR [14]) and also with greatest fixed points (AF2µν [15]) have been introduced. These features allow for the (co)inductive definition of predicates and are suitable for programming with proofs. However the strong normalization is lost due to the use of a fixed-point combinator in the proof-term system, which encodes derivations with lambda terms. The situation is that an iterative function f can be defined within AF2 and therefore its extracted program f¯ is automatically terminating, but the extracted program for a primitive recursive function employs a fixed-point combinator in the extensions of AF2 and therefore its termination is not obvious at all. ∗ This research is being supported by PAPIIT-UNAM projects IN117711 and IN108810. Ronchi della Rocca, S., Pimentel, E. (Eds.): 6th Workshop on Logical and Semantic Frameworks with Applications 2011 (LSFA 2011). EPTCS 81, 2012, pp. 30–46, doi:10.4204/EPTCS.81.3 c Miranda-Perea and González-Huesca This work is licensed under the Creative Commons Attribution License. Miranda-Perea and González-Huesca 31 This has lead to sophisticated methods to verify that these programs indeed terminate [6], even when they fit into a well-known terminating recursion pattern captured in Gödel’s T for the case of natural numbers and generalized to all (co)inductive types in [9, 7, 8], for example. The main contribution of this paper is the introduction of a new extension of AF2 with primitive (co)recursion over least and greatest fixed points, called AF2Mµν , that enjoys the strong normalization property. Instead of using a fixed-point combinator we use the Mendler-style approach of [8] but with two important differences: we use a natural deduction approach, and we do not restrict ourselves to positive operators. This shows that such syntactical restriction is irrelevant to the strong normalization proof of the whole Mendler-system, a feature first discovered by Matthes ([7], p.83) for the inductive fragment. Another contribution of our work is the use of the iso-style, meaning that a (co)inductive predicate and its folding/unfolding are not considered equal but isomorphic. It is important to mention that previous extensions of AF2 with (co)inductive definitions deal only with equi-style predicates, but in our opinion the use of the iso-style is closer to the usual mechanisms of data type definition in functional programming languages. As a consequence of our definition of saturated sets, the proof of the adequacy theorem of our logic does not employ ordinal recursion. Moreover, the rules of our logic are specifically designed to derive statements of totality of functions involving (co)inductive predicates, that is, formulas of the form ∀x.P(x) → R( f (x)). The paper is organized as follows: in section 2 we review the required concepts of fixed-point theory needed to motivate the definition of our logic, which is given in section 3, together with some examples of its expressivity. Section 4 develops the constructions on saturated sets employed in section 5 to define an intuitionistic semantics of the logic. Finally, we discuss related work in section 6 and provide some closing remarks in section 7. 2 Fixed-point theory d d In this section we recall some tools of fixed-point theory involving a complete lattice hL , v, i, where is the infimum operator. Given a monotone operator Φ : L → L the Knaster-Tarski theorem guarantees the existence of the least (greatest) fixed-point of Φ, denoted lfp(Φ) or gfp(Φ), respectively. Proposition 1 (Conventional (co)induction principles). Let Φ : L → L be a monotone operator on a d complete lattice hL , v, i. The following holds for every M ∈ L . ◦ Induction: if Φ(M) v M then lfp(Φ) v M. d  ◦ Extended induction: if Φ lfp(Φ) M v M then lfp(Φ) v M. ◦ Coinduction: if M v Φ(M) then M v gfp(Φ). F  ◦ Extended coinduction 1 : if M v Φ gfp(Φ) M then M v gfp(Φ). Proof. Straightforward. The following concepts of monotonization of an arbitrary operator are taken from [7]. Definition 1. Given an arbitrary operator Φ : L → L , we define its upper monotonization Φw : L → F L and its lower monotonization Φv : L → L as Φw (M) = {Φ(X) | X v M} and Φv (M) = d {Φ(X) | M v X}. The properties and relationships between Φ and its monotonizations are given in the following Proposition 2. If Φ : L → L is an arbitrary operator then Φv and Φw are monotone. Moreover, 1 Recall that in a complete lattice the supremum operator F can be defined from the infimum operator d . 32 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach ◦ For any M ∈ L , Φv (M) v Φ(M) v Φw (M). ◦ If Φ is monotone then Φv = Φ = Φw and if Φv = Φ or Φ = Φw then Φ is monotone. ◦ Φ(lfp(Φw )) v lfp(Φw ) and gfp(Φv ) v Φ(gfp(Φv )). Proof. Straightforward. Next we justify the Mendler-style (co)induction principles by means of the monotonizations. This justification is not present in the original work of Mendler ([8]). However, the inductive part is discussed in [7]. Proposition 3 (Mendler (Co)induction principles). The following holds for any Φ : L →L and M∈ L .  ◦ Induction: if ∀X X v M → Φ(X) v M then lfp(Φw ) v M.  ◦ Extended Induction: if ∀X X v lfp(Φw ) → X v M → Φ(X) v M then lfp(Φw ) v M.  ◦ Coinduction: if ∀X M v X → M v Φ(X) then M v gfp(Φv ).  ◦ Extended Coinduction: if ∀X gfp(Φv ) v X → M v X → M v Φ(X) then M v gfp(Φv ). Proof. The conventional (co)induction principles for Φv and Φw yield the required principles. For details see [11]. 3 The Logic AF2Mµν We present now the logic AF2Mµν , which is an extension of AF2 with Mendler-style (co)inductive definitions. ◦ Terms: the object terms are defined as usual from a signature Σ including function symbols f of a given arity. t ::= x | f (t1 , . . . ,tn ) ◦ Predicates: apart from the usual predicates (second-order variables or predicate symbols of a signature Σ) we have comprehension predicates, inductive predicate µ(Φ) and coinductive predicates ν(Φ). P ::= X | P | F | µ(Φ) | ν(Φ) here F is a comprehension predicate of the form F =de f λ~x.A, where A is a formula and its arity is the length of the vector of variables ~x, this predicate intends to represent the set {~t | A[~x :=~t ]}. On the other hand, Φ is an arbitrary predicate transformer, which is a closed expression of the form Φ =de f λ X.P, depending on a second-order variable X. Observe that we do not require any syntactic restriction, like positivity, on the occurrences of X in P. ◦ Formulas: these are defined as usual A, B ::= P(t1 , . . . ,tn ) | A → B | ∀xA | ∀XA ◦ On equations: term equations are formulas which play an important role in the logic and are defined as usual in second-order logic: the equation r = s stands for the formula ∀X.X(r) → X(s). Miranda-Perea and González-Huesca 33 The judgments of the logic are of the form Γ `E t : A where Γ = {x1 : A1 , . . . , xn : An } is a context of formulas annotated by proof-term variables, E = {r1 = s1 , . . . , rn = sn } is a context of equations, A is a formula and t is a proof-term, which is a lambda term not to be confused with an object term, for even when we use the same meta-variables for both, object and proof-terms, we consider them to be two completely separated syntactic categories. The derivation relation is inductively defined by means of the following inference rules, where A[x := r] (A[X := P]) always denotes capture-avoiding substitution of first-order (second-order) variables by a term (predicate) in the formula A. ◦ Rules of AF2: Γ, x : A ` x : A (Var) Γ, x : A ` r : B (→ I) Γ ` λ xr : A → B Γ`t :A x∈ / FV (Γ) (∀I) Γ ` t : ∀xA Γ`t :A X ∈ / FV (Γ) 2 (∀ I) Γ ` t : ∀XA Γ`r:A→B Γ`s:A (→ E) Γ ` rs : B Γ ` t : ∀xA (∀E) Γ ` t : A[x := r] Γ ` t : ∀XA (∀2 E) Γ ` t : A[X := P] Γ `E t : A[x := r] E B r = s (Eq) Γ `E t : A[x := s] Here E B r = s means a derivation of r = s from the set of equations E according to the following rules: – E B r = s, if r = s is a particular case of an equation in E. That is an equation of the form r1 [~x :=~t ] = r2 [~x :=~t ] or r2 [~x :=~t ] = r1 [~x :=~t ], where r1 = r2 ∈ E and ~t are arbitrary terms. – r = s was obtained from E by reflexivity, transitivity or compatibility with functions, that is, by one of the following rules: EBr = r EBr = s EBs = t EBr = t E B r1 = s1 . . . E B rn = sn E B f (r1 , . . . , rn ) = f (s1 , . . . , sn ) ◦ Rules involving (co)inductive definitions: these rules are specifically designed to construct (destruct) elements of an inductive (coinductive) predicate and to prove statements of totality of functions. Given two n-ary2 predicates P, R, and a vector ~g of n function symbols, the following notation will be used: P ⊆~g R is the formula ∀~x.P(~x ) → R(~g(~x )), where, in general, a vector application of ~f =de f f1 , . . . , fn to ~t =de f t1 , . . . ,tn , denoted ~f (~t ), is defined as ~f (~t ) =de f f1 (t1 ), . . . , fn (tn ). In particular P ⊆ R is the formula ∀~x.P(~x) → R(~x) or even P → R, if the predicates have arity 0. Given a predicate transformer Φ =de f λ X.P and a predicate R, the application of Φ to R, is defined by Φ(R) =de f P[X := R], clearly Φ(R) is a predicate. The following rules are motivated by the last part of proposition 2 and by proposition 3, for lattices of sets. It is important to observe that in each rule we employ µ(Φ) or ν(Φ) instead of the expected µ(Φw ) or ν(Φv ). This choice will be justified by the semantics. 2 We are mostly interested in predicates for data types, which means n = 1. However we present the system for any arity for the sake of generality. 34 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach – Inductive construction and coinductive destruction: for any (co)inductive predicate µ(Φ) or ~ called the constructors ν(Φ) of arity n, we assume a fixed set of n function symbols ~c or d, of µ(Φ) or the destructors of ν(Φ). Γ ` r : Φ(µ(Φ))(~t ) (µI) Γ ` in r : µ(Φ)(~c(~t ) ) Γ ` r : ν(Φ)(~t ) ~ ~t )) Γ ` out r : Φ(ν(Φ))(d( (νE) These rules correspond to the last part of proposition 2, but observe that our (co)inductive ~ Morepredicates are in iso-style, due to the presence of the constructors ~c (destructors d). over, the equi-style can be easily recovered by using as constructors/destructors the identity function symbol id while adding id(x) = x to the equational axioms. – Primitive recursion: this rule is modelled after the Mendler extended induction principle given by proposition 3. Here we regard a composition f ◦ c as a new function symbol defined by the equation ( f ◦ c)(x) = f (c(x)) and a composition of tuples ~f ◦~c as the tuple f1 ◦ c1 , . . . , fn ◦ cn .  Γ ` s : ∀X X ⊆ µ(Φ) → X ⊆~f K → Φ(X) ⊆~f ◦~c K Γ ` r : µ(Φ)(~t ) (µE) Γ ` MRec s r : K (~f (~t )) – Primitive corecursion: the Mendler extended coinduction principle of proposition 3 inspires the following rule. Observe that in both rules (recursion and corecursion), we can recover the corresponding exact principle of proposition 3 by using the equi-style and by regarding f as the identity function via the equation f (x) = x.  Γ ` s : ∀X ν(Φ) ⊆ X → K ⊆~f X → K ⊆d◦ Γ ` r : K (~t ) ~ ~f Φ(X) (νI) Γ ` MCoRec s r : ν(Φ)(~f (~t )) ◦ Operational semantics: To end the definition of our logic, we define the operational semantics of the proof-term reduction, which is given by the one-step reduction relation t →β t 0 defined as the closure of the following axioms under all term formers. (λ xr)s → 7 β MRec s(int) → 7 β out(MCoRec s t) 7→β r[x := s] s(λ xx)(MRec s)t s(λ xx)(MCoRec s)t Here and troughout the paper MRec s means λ x. MRec s x and the same is true for MCoRec s. ◦ Derived rules: To simplify the presentation of examples we will employ the usual second-order encodings for conjunctions, disjunctions and existential formulas, which allow to obtain the following derived rules for judgements and operational semantics: Γ`r:A Γ`s:B (∧I) Γ ` hr, si : A ∧ B Γ ` s : A∧B (∧EL ) Γ ` fst s : A Γ`r:A (∨IL ) Γ ` inl r : A ∨ B Γ ` s : A∧B (∧ER ) Γ ` snd s : B Γ`r:B (∨IR ) Γ ` inr r : A ∨ B Γ ` r : A ∨ B Γ, x : A ` s : C Γ, y : B ` t : C (∨E) Γ ` case(r, x.s, y.t) : C Miranda-Perea and González-Huesca 35 Γ ` t : ∃x.A Γ, u : A ` r : B x ∈ / FV (Γ, B) Γ ` open(t, u.r) : B Γ ` t : A[x := r] Γ ` packt : ∃x.A fsthr, si → 7 β case(inl r, x.s, y.t) → 7 β r s[x := r] sndhr, si → 7 β case(inr r, x.s, y.t) → 7 β s t[y := r] open(packt, u.r) 7→β r[u := t] The proof-reduction behaves well with respect to the derivation relation, as ensured by the following Proposition 4 (Subject-reduction of AF2Mµν ). If Γ `E t : A and t →? t 0 then Γ `E t 0 : A. Proof. The proof is not trivial since AF2Mµν is formulated in Curry-style and it is analogous to the one developed in [9] for a similar system. 3.1 On (Co)Iteration In fixed-point theory, (co)iteration can be easily derived from primitive (co)recursion. This is not the case for conventional (co)induction principles in type theory like the ones developed in [9] (see section 4.5 of [7] for a deep discussion on this subject) and therefore (co)iterators must be defined apart from (co)recursors. For the Mendler-style, (co)iterators correspond to the (co)induction principles of proposition 3, and are again superfluous (as noticed also in [7]). Let us define MIt s r =de f MRec s0 r and MCoIt s r =de f MCoRec s0 r, where s0 =de f λ .s and is a dummy variable. The following rules for inference and proof-reduction are derivable: ◦ Iteration ◦ Coiteration  Γ ` s : ∀X X ⊆~f K → Φ X ⊆~f ◦~c K Γ ` r : µ(Φ)(~t ) (µE − ) Γ ` MIt s r : K (~f (~t )) Γ ` s : ∀X K ⊆~f X → K ⊆d◦ ~ ~f Φ X  Γ ` MCoIt s r : ν(Φ)(~f (~t )) MIt s(int) → s(MIt s)t Γ ` r : K (~t ) (νI − ) out(MCoIt s t) → s(MCoIt s)t We will use both the (co)iteration and the primitive (co)recursion rules in the examples that we discuss next. 3.2 Examples In this section we develop some examples of (co)inductive predicates that show the expressivity of our logic. Due to lack of space a deep discussion about the advantages and disadvantages of both the iso-style and the equi-style is missing. Instead, we provide some examples that show some of such (dis)advantages. Every program (λ -term) f presented here is extracted from a proof of totality for a function f involving (co)inductive predicates and specified by a set of equations in the logic. Moreover, the reader can verify that in each case f is operationally correct. Example 1 (Iso-inductive ad-hoc Natural Numbers). Let h i =de f λ x.x = ? where ? is a fixed constant, this comprehension predicate is called unit predicate and represents a type with unique inhabitant ?. We define the predicate of natural numbers as N =de f µ(Φ) where Φ =de f λ X.λ x.hhi(x) ∨ X(x), taking the 36 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach successor function suc as constructor and suc(?) = 0 as equational axiom. Defining 0 =de f in(inl()),3 and suc =de f λ x. in(inr x) we can show that ` 0 : N(0) and ` suc : ∀x.N(x) → N(suc x). We call this an ad-hoc definition, for zero is in the image of the successor and therefore our representation is not compatible with Peano’s axioms. This is an unpleasant feature which can be avoided at some cost (see example 3). However, operationally, our definition is adequate. For instance, the sum and factorial are programmed as follows: ◦ Sum: from Esum = {sum n 0 = n, sum n (suc m) = suc (sum n m)} , we get `Esum sum : ∀n.∀x.N(n) → N(x) → N(sum n x), where sum =de f λ n. MIt s and s =de f λ yλ z.case(z, u.n, v.suc(yv)). This program behaves correctly: sum n 0 →? n and sum n (suc m) →? suc(sum n m). ◦ Factorial: using the equations Efac = {fac 0 = 1, fac (suc n) = (suc n) ∗ (fac n)}, we can derive `Efac fac : ∀x.N(x) → N(fac x), where fac =de f MRec s and the step term s is defined as s =de f λ yλ zλ w.case(w, u.1, v.suc(yv)∗(zv)). The reader should convince herself that the naive definition of natural numbers coming from fixed point theory, given by the predicate transformer Φ =de f λ X.λ x.x = 0 ∨ X(x), does not work. In the equi-inductive approach we cannot construct any number other than zero, and in the iso-inductive case we cannot construct the zero. Another possibility is the one taken in [16], discussed next. Example 2 (Equi-inductive Natural Numbers). We define N =de f µ(Φ) with the predicate transformer Φ = λ X.λ x.Z(x) ∨ X(p(x)) where Z =de f λ x.x = 0 and p is a function symbol, whose intended meaning is the predecessor function. We have ` 0 : N(0) and ` p : ∀x.N(p(x)) → N(x) where 0 =de f in(inl()) and p =de f λ x. in(inr x). In this case we have the following derivation: f0 : ∀x.Z(x) → It(x), f p : ∀x.It(p(x)) → It(x) ` MIt s : ∀x.N(x) → It(x), where s =de f λ x.λ y.case(y, u. f0 (u), v. f p (xv)) and It(x) is a predicate representing the fact that the image of a given function f on x was defined by iteration,. If we set g =de f MIt s then g 0 →? f0 () and g (p n) →? f p (g n). This example shows that our logic subsumes the Mendler-style programming methodology of [16]. However, this approach does not correspond to the idea of programming with proofs that we pursuit. Our final version of natural numbers shows the full use of the iso-inductive style and depends on the disjoint union of predicates ] which is a predicate that can be defined under the presence of the Parigot’s restriction operator  (see [14]). This operator can be added to our logic without a problem and behaves as a conjunction where the right formula is an equation without algorithmic content.4 Defining P ] R =de f λ x.∃z.(P(z)x = lf z) ∨ (R(z)x = rg z) we get that Γ ` r : P(t) implies Γ ` pack(inl r) : (P ] R)(lf t) or Γ ` pack(inr r) : (R ] P)(rgt). One important advantage of using this predicate together with our iso-style is that we do not need to deal directly with existential formulas in definitions, and therefore the following examples are closer to the data type definition mechanisms of functional programming languages. Example 3 (Iso-inductive Natural Numbers). The natural numbers are given now by the inductive definition N =de f µ(Φ) where Φ = λ X.hhi ] X, and we use a generic constructor cnat, which yields the usual constructors by adopting the equational axioms 0 = cnat(lf ?) and suc x = cnat(rg x). These constructors are implemented by 0 =de f in(pack(inl())) and suc =de f λ z. in(pack(inr z)). Let us present the extracted programs for sum, factorial and predecessor: ◦ Sum: from Esum = {sum n 0 = n, sum n (suc m) = suc(sum n m)}, we derive `Esum λ n. MIt s : ∀n.∀x.N(n) → N(x) → N(sum n x) where s =de f λ y.λ z.open(z, u.case(u, v.n, w.suc(yw))). Therefore we get sum =de f λ n. MIt s. 3 Sometimes 4 That an equation is involved directly in a judgment and we agree to give it the void proof-term () as code. is, an equation that is not codified by a proof-term. Miranda-Perea and González-Huesca 37 ◦ Factorial: from Efac = {fac(0) = 1, fac(suc(n)) = suc(n) ∗ fac(n)}, we derive `Efac MRec s : ∀x.N(x) → N(fac x) where s =de f λ y.λ z.λ w.open(w, u.case(u, u1 .1, u2 .suc(yu2 )?(zu2 ))). Therefore fac =de f MRec s is a correct program for the factorial. ◦ Predecessor: an efficient handling-error predecessor specified by Epred = {error = lf ?, pred 0 = error, pred (suc n) = rg n}, is implemented by pred =de f MRec s, where the step function is s =de f λ y.λ z.λ w.open(w, u.case(u, u1 . pack(inl()), u2 . pack(inr(yu2 ))), for we derive ` Epred MRec s : ∀x.N(x) → (hhi ] N)(pred x). In a similar way to the last example, we can define all usual inductive data types like finite lists or trees (see [11, 9] for several related examples). We present next, coinductive predicates corresponding to the conatural numbers and the lazy data type of streams or strictly infinite lists. These examples show that we can deal with infinite objects within a terminating system. It is important to observe that in the former case the iso-style is more convenient, and for the latter the equi-style suffices. The implementation of the predicate for the so-called conatural numbers, corresponding to the ordinal ω + 1, gives us the opportunity to show the use of corecursion to construct inhabitants of data types with infinite objects, in this case the ordinal ω. We observe that the implementation of conatural numbers, as well as the implementations for natural numbers discussed above, do not correspond to Church numerals, as it happens in AF2. In particular the normal proof-term coding the fact that CoNat(ω) holds does not involve an “infinite” Church numeral, which would be a non-terminating term, for ω is specified as a conatural number that equals its predecessor and will be constructed by means of corecursion. Example 4 (Iso-coinductive conatural numbers). The conatural numbers are defined by CoNat =de f ν(Φ), where Φ =de f λ X.λ x.hhi(x) ∨ X(x), and taking the predecessor function pred as destructor with implementation pred =de f out. Let us construct the conatural numbers by means of corecursion. ◦ Zero: let 0 be a constant, z be a unary function symbol and Ez = {pred(z(x)) = ?, 0 = z(?)}. If we define 0̄ =de f MCoRec s (), where s =de f λ xλ y.λ u. inl u, then `Ez 0 : CoNat(0) and pred 0 →? inl(). ◦ Succesor: let suc be a unary function and Esuc = {pred(suc x) = x}. We have ` suc : ∀x.CoNat(x)→ CoNat(suc(x)), where suc =de f MCoRec s and s =de f λ xλ y.λ z. inr(xz). Moreover, the operational semantics yields pred(suc n) →? inr n. ◦ Omega: to define the infinite ordinal ω, we use a unary function ω † and axioms Eω † = {ω = ω † (?), pred(ω † (x)) = ω † (x)}. Then we get ` ω † : ∀x.hhi(x) → CoNat(ω † (x)). By defining ω =de f ω † () we get ` ω : CoNat(ω). The needed proof-term is given by ω † =de f MCoRec s, where s =de f λ xλ yλ z. inr(yz). Our last example of a coinductive predicate corresponds to streams or strictly infinite lists. Example 5 (Equi-coinductive Streams). The streams over a data type A are defined as SA =de f ν(Φ) where Φ =de f λ X.λ x.A(head(x))∧X(tail(x)), and the destructor d is the identity function. The programs for the usual destructors are head =de f λ x. fst(out x) and tail =de f λ x. snd(out x), extracted from ` head : ∀x.SA (x) → A(head x) and ` tail : ∀x.SA (x) → SA (tail x). We present now some programs involving streams: ◦ The function from, that generates the stream of natural numbers from a given one, is specified by Efrom = {head(from x) = x, tail(from x) = from(suc x)}. The reader can verify that `Efrom from : ∀x.N(x) → SN (from x) where from =de f MCoIt s and s =de f λ yλ z.hz, y(suc z)i, and that head(from x) →? x and tail(from x) →? from(suc x). 38 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach ◦ The constructor cons is defined by Econs = {head(cons x y) = x, tail(cons x y) = y} and requires corecursion to be implemented. We get a program cons from the proof `Econs cons : ∀x∀y.A(x) → SA (y) → SA (cons x y) where cons =de f λ x. MCoRec s and s =de f λ f1 λ f2 λ w.hx, f1 wi. ◦ The function map on streams is specified by Emap = {head(map f `) = f (head `), tail(map f `) = map f (tail `)}. An extracted program from `Emap map : (∀x.A(x) → B( f (x))) → ∀z.SA (z) → SB (map f z) is map =de f λ f . MCoIt s, where s =de f λ yλ z.h f (head x), y(tail x)i. ◦ A function similar to map but that requires corecursion in the implementation is maphd, which applies a given function only to the head of a stream. It is defined by Emaphd = {head(maphd f `) = f (head `), tail(maphd f `) = tail `}. We get the program `Emaphd maphd : (∀x.A(x) → A( f (x))) → ∀z.SA (z) → SA (maphd f z) where maphd =de f λ f . MCoRec s and the step function s is defined by λ y.λ z.λ w.h f (head x), tail xi. We finish the section with a couple of examples involving binary predicates. Example 6 (Iso-inductive order in natural numbers). The following recursive definition of order for natural numbers: n<m N(n) 0 < suc n suc n < suc m is implemented by the iso-inductive definition L = µ(Φ) where the predicate transformer is Φ =de f λ X (2) .λ x, y. (x = 0 ∧ N(y)) ∨ ∃z.X(z, y)  (x = suc z), and the constructors are the identity and the successor functions ~c =de f Id, suc. The derivations ` λ n. in(inlh(), ni) : ∀n.N(n) → L(0, suc n) and ` λ w. in(inr(pack w)) : ∀n∀m.L(n, m) → L(suc n, suc m) can be easily verified. Example 7 (Equi-coinductive observational equality for streams). Leibniz equality is not always adequate for reasoning about streams (see [15]), in some cases it is better to employ the observational equality. This equality relation is defined by the equi-coinductive binary predicate E =de f ν(Φ) where Φ =de f λ X (2) .λ x, y. head x = head y ∧ X(tail x, tail y). It is immediate to verify that ` λ x. fst(out x) : ∀x∀y.E (x, y) → head x = head y and ` λ x. snd(out x) : ∀x.∀y.E (x, y) → E (tail x, tail y). Moreover, the corecursion rule yields ` e : ∀x∀y. head x = head y → E (tail x, tail y) → E (x, y), where the proof term e is given by e =de f λ xλ y. MCoRec s hx, yi and s =de f λ w.λ u.λ v.hfst v, w(snd v)i. These proofs imply that two streams are observationally equal if and only if their heads are equal and their tails are again observationally equal. 4 Saturated Sets We develop here all constructions on a complete lattice of so-called saturated sets needed to define the semantics of the logic. It is important to emphasize that in this section a term is exclusively a λ -term belonging to the set Λ = {t | t is a proof-term of AF2Mµν }. Definition 2. A term t is called an I-term if it was generated by an introduction rule, i.e., I-terms are terms of the following shapes: λ xr, in r, MCoRec s r. Analogously E-terms are terms generated by an elimination rule, i.e. they are terms of the following shapes: rs, out r, MRec s r . Observe that any term is either a variable, an I-term or an E-term. Instead of reasoning with infinite reduction sequences we will work with an inductive definition of a set SN including all strongly normalizing terms. We discuss its definition now. Miranda-Perea and González-Huesca 39 Definition 3. Evaluation contexts are defined by the following grammar:         E • ::= • | E • s | out E • | MRec s E • Let us observe that an evaluation context may be considered as an E-term with a unique placeholder •. Therefore, evaluation contexts   are sometimes called elimination contexts or multiple eliminations. In the following, we will write E r for the E-term obtained by substituting the placeholder • by the term r     in E • . That is E r =de f E • [• := r] where the substitution is defined as if • were a term variable. A term of the form E x is called a neutral term. The notion of weak head reduction, denoted →whd , needed to define the set SN is defined as follows: t →β t 0    E t →whd E t 0 The final concept involved in the inductive definition of the set SN is the set ist(t) of immediate subterms of a given term t, defined as follows: ist(x) = ∅, ist(λ xr) = ist(in r) = ist(out r) = {r}, ist(rs) = ist(MRec s r) = ist(MCoRec s r) = {s, r}. We will also need the set ist(E[•]) of immediate subterms of a given evaluation context which is defined as if E[•] were a term. Definition 4. The set SN is defined by means of the following inductive definition: (SN - VAR) x ∈ SN     E x ∈ SN ist(E • ) ⊆ SN    (SN - E) E 0 E x ] ∈ SN t is an I-term ist(t) ⊆ SN (SN - I) t ∈ SN      E t 0 ∈ SN E t →whd E t 0 prt(t) ⊆ SN  (SN - W) E t ∈ SN where for a redex t, prt(t) is the set of problematic subterms of t, which are the terms that might break the strong normalization of t, even knowing that its reduct t 0 strongly normalizes. This set is defined as follows: prt((λ x.r)s) = {s}, prt(MRec s (in r)) = prt(out(MCoRec s r)) = ∅. It can be proved that the characterization SN of the set of strongly normalizing terms is sound, that is: if t ∈ SN then there is no infinite reduction sequence t → t1 → t2 → . . . . Now we can define a concept of saturated set, modelled after the definition of SN. Definition 5 (SAT-set). A set of terms M is saturated if and only if it consists only of terms in SN, it contains all neutral terms of SN, and it is closed under weak head expansion of SN terms. This can elegantly be defined by the following rules: t ∈M (SAT- SN) t ∈ SN E[t 0 ] ∈ M E[t] →whd E[t 0 ] E[t] ∈ M E[x] ∈ SN (SAT- N) E[x] ∈ M prt (t) ⊆ SN (SAT- W) It is easy to see that SAT =de f {M | M is saturated} is closed under intersection. Therefore the T triple hSAT, ⊆, i forms a complete lattice. The next concept will be fundamental for reasoning with saturated sets. Definition 6. Given a set of terms M, the set cl(M) := saturated closure or SAT-closure of M. {N ∈ SAT | M ∩ SN ⊆ N } is called the T cl(M) is the least saturated superset of M ∩ SN. Observe that M ⊆ cl(M) if and only if M ⊆ SN. 40 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach 4.1 Saturated sets for the implication The following construction is standard, we recall it here for the sake of self-containtment. Definition 7. We define M ⇒ N = cl({r ∈ Λ | ∀s ∈ M . rs ∈ N }), so that ⇒: SAT × SAT → SAT is a binary operation on saturated sets. Proposition 5 (Soundness). Let M , N ∈ SAT. 1. If Sx (M , N ) = {t | ∀s ∈ M . t[x := s] ∈ N } and t ∈ Sx (M , N ) then λ xt ∈ M ⇒ N . 2. If r ∈ M ⇒ N and s ∈ M then rs ∈ N . Proof. Straightforward. See for example [9]. 4.2 SAT valued functions for coinductive predicates The goal of this section is to develop the main technical contribution of our paper, to construct fixed points of SAT-valued functions, which will be needed later for the semantics of coinductive predicates. For the case of inductive predicates we point to our extended version [11]. The methodology is based on the one developed in section 9.4 of [7] for inductive types. These constructions and their soundness properties will play an essential role in the proof of the adequacy theorem for AF2Mµν . Let us start by fixing a non-empty set M and by defining for all n ∈ N, the set of SAT-valued n-ary functions SATn =de f {F | F : M n → SAT}, with SAT0 = SAT. The set SATn forms a complete lattice T hSATn , ⊆, i with the pointwise inherited definitions F ⊆ G ⇔de f ∀~x ∈ M n .F(~x ) ⊆ G(~x ) and defining T T T for any F ⊆ SATn , the function F : M n → SAT as ( F )(~x ) =de f F∈F F(~x ). Through this section we fix a higher-order function Φ : SATn → SATn , and tuples of functions ~d = d1 , . . . , dn ,~f = f1 , . . . , fn with di , fi : M → M. Let us begin with the constructions for coinductive predicates. The idea is that given a coinductive predicate ν(Ψ), where the interpretation of the predicate transformer Ψ is the function Φ : SATn → SATn , its interpretation will be defined as the greatest fixed-point ν(Θv ) of the lower monotonization of some operator Θ : SATn → SATn associated to the arbitrary function Φ. Definition 8. We define Eν : SATn → M n → P(Λ) by Eν (F)(~t ) =de f {r ∈ SN | out r ∈ Φ(F)(~d(~t ))} where F : M n → SAT and ~t ∈ M n . Lemma 1. Let ΘE : SATn → SATn be defined as ΘE (F)(~t ) =de f cl(Eν (F)(~t )). Then, for any F ∈ SATn , Eν (F) = ΘE (F) Proof. It suffices to show that for any ~t ∈ M n , Eν (F)(t) ∈ SAT. See [11]. The post-fixed points of ΘE are characterized as follows: Lemma 2. F ⊆ ΘE (F) ⇔ ∀~t ∈ M n ∀r ∈ F(~t ). out r ∈ Φ(F)(~d(~t )). Proof. Straightforward. We would like to obtain a greatest fixed-point of ΘE , but as we do not assume that Φ is monotone, we cannot prove either that ΘE is monotone. Therefore we cannot apply the Knaster-Tarski fixed-point theorem to ΘE to obtain a greatest fixed-point of ΘE , which is what we need to interpret coinductive Miranda-Perea and González-Huesca 41 predicates. However, we can proceed by using an adequate version of its lower monotonization (see definition 1), Eν⊆ : SATn → M n → P(Λ) defined by Eν⊆ (F)(~t ) = \ {Eν (F 0 )(~t ) | F ⊆ F 0 } F 0 ∈SATn ⊆ ~ It is easy to see that Eν⊆ is monotone. Therefore the operator Θ⊆ E : SATn → SATn given by ΘE (F)(t ) =de f ⊆ ⊆ cl(Eν (F)(~t )) is also monotone and the function ν(Φ) ∈ SATn defined by ν(Φ) =de f gfp(ΘE ) exists due T to the completeness of the lattice hSATn , ⊆, i. Proposition 6. ν(Φ) is a post-fixed point of ΘE . ⊆ Proof. By definition, ν(Φ) is a post-fixed point of Θ⊆ E , that is ν(Φ) ⊆ ΘE (ν(Φ)). Moreover, it is ⊆ straightforward to show that ΘE (ν(Φ)) ⊆ ΘE (ν(Φ)), which yields ν(Φ) ⊆ ΘE (ν(Φ)). Next, we define an operator ΘI useful to prove the soundness of the inference rule for Mendler corecursion. Definition 9. Given Φ : SATn → SATn and F ∈ SATn we define Iν : SATn → M n → P(Λ) as follows: if ~s ∈ M n and ~s 6=~f(~t ) then Iν (F)(~s ) =de f ∅, and n Iν (F)(~f(~t )) =de f MCoRec s r H ∈ SATn , r ∈ H(~t), o  T s ∈ G∈SATn (F  G) ⇒ (H ~f G) ⇒ H ~d◦~f Φ(G) where for any F, G ∈ SATn and ~g a tuple of functions gi : M → M we define the SAT-set F ~g G as T T follows: F ~g G =de f ~t∈Mn F(~t ) ⇒ G(~g(~t )), in particular, F  G =de f ~t∈Mn F(~t ) ⇒ G(~t ). Finally we define the function ΘI : SATn → SATn as ΘI (F)(~t ) =de f cl(Iν (F)(~t )). Lemma 3. For any F ∈ SATn , Iν (F) ⊆ ΘI (F). Proof. It suffices to show that for any ~s ∈ M n , Iν (F)(~s ) ⊆ SN. See [11]. The pre-fixed points of ΘI are characterized as follows: Lemma 4. Let F ∈ SATn . ΘI (F) ⊆ F ⇔ ∀~t ∈ M n .∀H ∈ SATn . ∀r ∈ H(~t ). ∀s ∈ T G∈SATn  (F  G) ⇒ (H ~f G) ⇒ H ~d◦~f Φ(G) . MCoRec s r ∈ F(~f(~t )) Proof. Straightforward. To show the soundness of Mendler corecursion we will use the following Proposition 7. ν(Φ) is a pre-fixed point of ΘI . Proof. We will proceed by extended conventional coinduction, as defined in proposition 1 . 0 Let J =de f ν(Φ) and J0 =de f J ∪ ΘI (J). We have to prove that ΘI (J) ⊆ Θ⊆ E (J ) and for this, it suffices to show that Iν (J)(~s ) ⊆ Eν⊆ (J0 )(~s ) for all ~s ∈ M n . ~~ If ~s 6=~f(~t) then Iν (J)(~s ) = ∅ ⊆ Eν⊆ (J0 )(~s ). For the case ~s =~f(~t ) let us take MCoRec  s r ∈ Iν (J)(f(t)) T with r ∈ H(~t), H ∈ SATn and s ∈ G∈SATn (J  G) ⇒ (H ~f G) ⇒ H ~d◦~f Φ(G) . According to the definition of Eν⊆ (J0 )(~f(~t )) we have to prove that MCoRec s r ∈ Eν (J00 )(~f(~t )) for any J00 ∈ SATn such 42 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach that J0 ⊆ J00 . Let us observe that MCoRec s r ∈ SN, for Iν (J)(~f(~t )) ⊆ SN. Therefore, we only need to verify that out(MCoRec s r) ∈ Φ(J0 )(~d(~f(~t ))). Since Φ(J0 )(~d(~f(~t ))) ∈ SAT, it suffices to show that s(λ xx)(MCoRec s)r ∈ Φ(J0 )(~d(~f(~t ))). We know that s ∈ (J  J0 ) ⇒ (H ~f J0 ) ⇒ (H ~d◦~f Φ(J0 )) and also that λ xx ∈ J  J0 , for J ⊆ J0 . Hence, by part 2 of proposition 5 , s(λ xx) ∈ H ~f J0 ⇒ H ~d◦~f Φ(J0 ). Next, we show that MCoRec s ∈ H ~f J0 . By part 1 of proposition 5 we only need to show that for all~t ∈ M n , MCoRec s x ∈ Sx (H(~t ), J0 (~f(~t ))), which happens if and only if for all e ∈ H(~t ), (MCoRec s x)[x := e] ∈ J0 (~f(~t )). Therefore we assume e ∈ H(~t ) and need to prove that MCoRec s e ∈ J0 (~f(~t )), but we have MCoRec s e ∈ Iν (J)(~f(~t )) and therefore, by lemma 3 , MCoRec s e ∈ ΘI (J)(~f(~t )), but as ΘI (J)(~f(~t )) ⊆ J0 (~f(~t )) we have proven that MCoRec s ∈ H f J0 . Using again the second part of proposition 5 , we conclude that s(λ xx)(MCoRec s) ∈ H ~d◦~f Φ(J0 ). Finally r ∈ H(~t ) implies that s(λ xx)(MCoRec s)r ∈ Φ(J0 )(~d(~f(~t ))). To finish this section we summarize the soundness properties of the (co)inductive constructions on SAT-valued functions. Proposition 8 (Soundness of the (co)inductive constructions). Let Φ : SATn → SATn ,~c,~d,~f be tuples of functions ci , di , fi : M → M, 1 ≤ i ≤ n, and ~t ∈ M n . Then 1. If r ∈ Φ(µ(Φ))(~t ) then in r ∈ µ(Φ)(~c(~t )). 2. If r ∈ µ(Φ)(~t ), H ∈ SATn and s ∈ MRec s r ∈ H(~f(~t )).   H then H) ⇒ Φ(G)  (G  µ(Φ)) ⇒ (G  ~ ~ G∈SATn f◦~c f T 3. If r ∈ ν(Φ)(~t ) then out r ∈ Φ(ν(Φ))(~d(~t )).   T 4. If r ∈ H(~t ), H ∈ SATn , and s ∈ G∈SATn (ν(Φ)  G) ⇒ (H ~f G) ⇒ H ~d◦~f Φ(G) then MCoRec s r ∈ ν(Φ)(~f(~t )). Proof. Part 3 is consequence of proposition 6 and lemma 2 . For part 4 we just use proposition 7 and lemma 4 . For the inductive cases we refer to [11] . We are now ready to define an intuitionistic semantics for our logic. 5 Semantics for AF2Mµν We present here a realizability semantics for AF2Mµν where an object-term will be interpreted as an element of a universe set M, a formula as a SAT-set and a predicate as a SAT-valued function in SATn . Definition 10. A model for a second-order language L is a pair M = hM, I i where M is a non-empty set and I is an interpretation function for L such that I ( f ) : M n → M, for every n-ary function symbol f ∈ L and I (P) : M n → SAT, for every n-ary predicate symbol P ∈ L. From now on we fix a model M = hM, I i. Definition 11. A state or variable assignment is a function σ : Var → M ∪ SATn such that σ (x) ∈ M and σ (X (n) ) ∈ SATn . Given m ∈ M or G ∈ SATn , the modified assignments σ [x/m] and σ [X/G] are defined as usual. Next, we recursively define the interpretation of terms, predicates and formulas. Miranda-Perea and González-Huesca 43 Definition 12. Given a variable assignment σ , we define the interpretation function Iσ , such that Iσ (r) ∈ M, Iσ (P) ∈ SATn and Iσ (A) ∈ SAT, as follows: ◦ Term interpretation – Iσ (x) = σ (x) – Iσ ( f (t1 , . . . ,tn )) = I ( f )(Iσ (t1 ), . . . , Iσ (tn )) ◦ Predicate interpretation: – Predicate variables: Iσ (X) = σ (X) – Predicate symbols: Iσ (P) = I (P) – Comprehension predicates: if F =de f λ~xA, we define Iσ (F ) = GF where GF : M n → SAT is given by GF (~m ) = Iσ [~x/~m ] (A), for all ~m ∈ M n . – Predicate transformers: if Φ =de f λ X.P, where w.l.o.g., P =de f λ~x.A, we define Iσ (Φ) : SATn → SATn by Iσ (Φ)(F)(~m ) = Iσ [X/F,~x/~m ] (A), for all ~m ∈ M n . This way, it can be proved that for any predicate R, we have Iσ (Φ(R)) = Iσ (Φ)(Iσ (R)). – (Co)inductive predicates: ∗ Iσ (µ(Φ)) = µ(Iσ (Φ)) ∗ Iσ (ν(Φ)) = ν(Iσ (Φ)) where of course, the operators µ and ν on the right-hand side of the equalities refer to the constructions on SAT-valued functions developed in section 4 . ◦ Formula interpretation:   – Iσ P(t1 , . . . ,tn ) = Iσ (P) Iσ (t1 ), . . . , Iσ (tn ) – Iσ (A → B) = Iσ (A) ⇒ Iσ (B) T – Iσ (∀xA) = {Iσ [x/m] (A) | m ∈ M } T – Iσ (∀XA) = {Iσ [X/G] (A) | G ∈ SATn } We observe that as equations are a special case of a second-order universal formula, there is no need to give a specific semantics for them. However we are only interested in models that satisfy a set of equations in the following sense. Definition 13. Let M = hM, I i be a model and σ be a state. We say that the interpretation Iσ satisfies the equation r = s if and only if Iσ (r) = Iσ (s). Moreover if E is a set of equations, we say that Iσ satisfies E if and only if Iσ satisfies every equation in E. Now we can prove the main theorem of this paper. Theorem 1 (Adequacy or soundness). Let M = hM, I i be a model such that the interpretation Iσ satisfies the set of equations E. If Γ `E t : A, with Γ = {x1 : A1 , . . . , xn : An } and for all 1 ≤ i ≤ n, ri ∈ Iσ (Ai ) then t[~x :=~r ] ∈ Iσ (A). Proof. Induction on Γ `E t : A. We discuss the case for the rule  (νI), for the remaining rules see [11]. ~ We need to show that (MCoRec s r)[~x :=~r] ∈ Iσ ν(Φ)( f (~t )) . That is, (MCoRec s[~ x :=~r] r[~x :=~r]) ∈ ν(Iσ (Φ))(~j), where ~j = Iσ ( f1 (t1 )), . . . , Iσ ( fn (tn )). The I.H. yields s[~x :=~r] ∈ Iσ ∀X ν(Φ) ⊆ X →  K ⊆~f X → K ⊆d◦ Φ(X) . From this and by defining Φ0 = Iσ (Φ), ~f = Iσ ( f1 ), . . . , Iσ ( fn ), ~d = ~ ~f  T Iσ (d1 ), . . . , Iσ (dn ) and H = Iσ (K ) it is easy to verify that s[~x :=~r] ∈ G∈SATn (ν(Φ0 )  G) ⇒ (H ~f  G) ⇒ (H ~d◦~f Φ0 (G)) . Moreover we also have r[~x :=~r] ∈ H(~l), where ~l = Iσ (t1 ), . . . , Iσ (tn ), by I.H. Therefore we can apply part 4 of proposition 8 to conclude that MCoRec s[~x :=~r] r[~x :=~r] ∈ ν(Φ0 ))(~f(~l )), which is equivalent to (MCoRec s r)[~x :=~r] ∈ Iσ (ν(Φ)(~f (~t ))). 44 5.1 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach Strong normalization The strong normalization property for the logic AF2Mµν can be proved by adapting the proof of AF2 which embeds this logic into its propositional fragment, system F (see [4]). However, our semantics of saturated sets allows for an easy proof of strong normalization which is a direct consequence of the adequacy theorem. Let us start by building a model and an interpretation that satisfies a given set of equations E as required by the adequacy theorem. Definition 14. Given a judgement ∆ =de f Γ `E t : A we define a model M∆ = hM, I i as follows: ◦ Let ≈E be the binary relation on terms given by r = s ⇔de f E B r = s. It is easy to prove that ≈E is an equivalence relation. ◦ The universe of M∆ is the set M = TermL / ≈E , of the equivalence classes [t] of the relation ≈E . ◦ The interpretation function I is defined as follows: – f I : M n → M, f I ([t1 ], . . . , [tn ]) =de f [ f (t1 , . . . ,tn )] – PI : M n → SAT, PI ([t1 ], . . . , [tn ]) =de f cl({s ∈ Λ | Γ `E s : P(t1 , . . . ,tn )}) It is easy to see that the interpretation function is well-defined and therefore M∆ is a model. The next lemma shows that in M∆ term interpretation is given by a specific substitution.   Lemma 5. Let σ be a state and r ∈ TermL such that Var(r) =~x. If σ (xi ) = [si ] then Iσ (r) = r[~x :=~s ] . Proof. Induction on r. We can now define an interpretation that satisfies a given set of equations E. Lemma 6. For any judgement ∆ =de f Γ `E t : A there is a state σ of M∆ such that the interpretation Iσ satisfies E. Proof. We define the state σ of M∆ , as follows: ◦ For any first-order variable x, σ (x) = [x]. ◦ For any second-order variable X, σ (X) = G, where G([t1 ], . . . , [tn ]) =de f cl({s ∈ Λ | Γ `E s : X(t1 , . . . ,tn )}). It is easy to verify that the state is well-defined. Moreover Iσ satisfies E, for if r = s ∈ E then r ≈E s and therefore [r] if Var(r) = = ~y, then by definition of σ and by lemma 5 we  = [s]. But,   ~x and Var(s)  have Iσ (r) = r[~x :=~x] = [r] = [s] = s[~y :=~y] = Iσ (s). The strong normalization of AF2Mµν is now easily gained from lemma 6 and the adequacy theorem. Theorem 2 (Strong normalization of AF2Mµν ). If Γ `E t : A then t is strongly normalizing Proof. Assume ∆ is the judgement Γ `E t : A, with Γ = {x1 : A1 , . . . , xk : Ak }. By lemma 6 the set of equations E is satisfied by an interpretation Iσ in the model M∆ . Moreover, we have xi ∈ Iσ (Ai ), for Iσ (Ai ) is a SAT-set and every SAT-set contains all variables. Therefore the adequacy theorem yields t = t[~x := ~x ] ∈ Iσ (A). Finally, as Iσ (A) ⊆ SN, we get t ∈ SN which implies that t strongly normalizes. Miranda-Perea and González-Huesca 6 45 Related Work Nowadays, there are several lines of research concerning fixed-point logics in computer science. In relation to our work we can mention for instance [12] which presents a sequent calculus for positive equi(co)inductive equational definitions and which handles conventional (co)iteration only. In this paper the equality relation is primitive and corresponds to unification with respect to β η-reduction. Moreover, the cut-elimination property holds only after restricting the coinductive rules. Recently [2] develops an extension of the linear logic MALL and a focused proof system for it where the mechanism of conventional equi-(co)inductive definitions is similar to ours. In this weak normalizable logic, which only handles (co)iteration, all predicate operators are assumed to be monotone, proofs of functoriality are given for positive definitions and the treatment of equality originates from logic programming. Finally we mention the work of [1] which is closer to ours and presents two strongly normalizing propositional logics (type systems) with Mendler-style positive equi-(co)inductive types whose semantics of so-called guarded saturated sets makes heavy use of transfinite ordinal recursion, which obliges to restrict the (co)iteration rules by means of a kind system that distinguishes between guarded and unguarded types. On the other hand this feature allows for a definition of a system of sized types that encompasses primitive (co)recursion and course of value recursion. 7 Closing remarks We have presented the logic AF2Mµν , an extension of the second order logic AF2 with Mendler-style primitive (co)recursion over least and greatest fixed points of predicate transformers. To our knowledge, this is the first such extension that includes Mendler-style (co)inductive predicates while keeping the strong normalization property. Thus, the programs extracted from the termination statements of functions are guaranteed to terminate, independently of the syntactical shape of the proof and therefore the particular methodologies to show termination, like the one in [6] are not needed. Based on the concept of monotonization of an operator we have developed a realizability semantics of SAT-sets and SAT-valued functions for (co)inductive predicates that does not employ the usual positivity restriction. This was first achieved in [7] for essentially the propositional inductive fragment of our logic. Furthermore, our adequacy theorem does not require any ordinal recursion in contrast to the work in [14, 15]. The iso-style of our (co)inductive definitions allows to define data types in a similar way to the definition mechanisms of functional programming by using a generic constructor (destructor), a feature that can be easily enhaced to use several specific constructors by means of clausular definitions (see [10]), a mechanism which also allows not to use neither existential nor restricted formulas. By means of examples, we have shown the suitability of the logic to extract programs from proofs. However, the concept of formal data type and other semantical foundations of the program extraction method, like the issue of equality for coinductive data types, as well as the development of more sophisticated case studies, are work in progress. Acknowledgements We are thankful to the anonymous referees for the helpful comments regarding the contents of this paper, in particular for the gentle hint to include the conatural numbers as an example. We also gratefully acknowledge Martha Elena Buschbeck Alvarado for improving the English manuscript. 46 Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach References [1] A. Abel (2007): Mixed Inductive/Coinductive Types and Strong Normalization, LNCS 4087, Springer, pp. 286-301, doi:10.1007/978-3-540-76637-7 19 [2] D. Baelde (2011): Least and Greatest Fixed Points in Linear Logic. Accepted for publication at the ACM Transactions on Computational Logic, http://arxiv.org/abs/0910.3383v4 [3] J.L. Krivine & M. Parigot (1990): Programming with Proofs. In Journal of Information Processing and Cybernetics EIK (Formerly Elektronische Informationsverarbeitung und Kybernetik) 26(3), pp. 149-167. [4] J.L. Krivine (1993): Lambda-Calculus, Types and Models. Ellis Horwood Series in Computers and their Applications. Ellis Horwood, Masson. [5] D. Leivant (1983): Reasoning about Functional Programs and Complexity Classes associated with Type Disciplines.. In Proceedings of 24th Annual Symposium on Foundations of Computer Science, IEEE Computer Science Press, pp.460-469, doi:10.1109/SFCS.1983.50 [6] P. Manoury & M. Simonot (1994): Automatizing termination proofs of recursively defined functions.. Theoretical Computer Science 135, pp. 319-343, doi:10.1016/0304-3975(94)00021-2 [7] R. Matthes (1999): Extensions of System F by Iteration and Primitive Recursion on Monotone Inductive Types. Dissertation Universität München, http://www.irit.fr/~Ralph.Matthes/ dissertation/matthesdiss.pdf [8] N.P. Mendler (1987): Recursive Types and Type Constraints in Second-Order Lambda Calculus. In Proceedings of the 2nd Annual Symposium on Logic in Computer Science, Ithaca N.Y. IEEE Computer Society Press, pp. 30-36. [9] F.E. Miranda-Perea (2009): Two Extensions of System F with (Co)iteration and Primitive (Co)recursion Principles. Theoretical Informatics and Applications 43(4), pp. 703–766, doi:10.1051/ita/2009015 [10] F. E. Miranda-Perea (2005): Realizability for Monotone and Clausular (Co)inductive Definitions. Electronic Notes in Theoretical Computer Science 123. pp. 179-193, doi:10.1016/j.entcs.2004.04.048 [11] F.E. Miranda-Perea & L. C. González-Huesca (2012): Mendler-style Iso-(Co)inductive predicates: a strongly normalizing approach (Extended Version). Technical report, Facultad de Ciencias UNAM. Available upon request. [12] A. Momigliano & A. Tiu (2003): Induction and Co-induction in Sequent Calculus. LNCS 3085, Springer, pp. 293-308, doi:10.1007/978-3-540-24849-1 19 [13] M. Parigot (1989): On the Representation of Data in Lambda-Calculus. LNCS 440, doi:10.1007/3540-52753-2 47 [14] M. Parigot (1992): Recursive programming with proofs. Theoretical Computer Science 94, pp. 335356, doi:10.1016/0304-3975(92)90042-E [15] C. Raffalli (1993): Data Types, Infinity and Equality in System AF2. LNCS 832, Springer, pp. 280294, doi:10.1007/BFb0049337 [16] T. Uustalu (1998): Natural deduction for intuitionistic least and greatest fixedpoint logics, with an application to program construction (PhD thesis). Dissertation TRITA-IT AVH 98:03, Dept. of Teleinformatics, Royal Inst of Technology (KTH), Stockholm. [17] T. Uustalu & V. Vene (2002): Least and greatest fixed-points in intuitionistic natural deduction. Theoretical Computer Science 272, pp. 315-339, doi:10.1016/S0304-3975(00)00355-8
6cs.PL
1 For Solving Linear Equations Recombination is a Needless Operation in Time-Variant Adaptive Hybrid Algorithms Abstract Recently hybrid evolutionary computation (EC) techniques are successfully implemented for solving large sets of linear equations. All the recently developed hybrid evolutionary algorithms, for solving linear equations, contain both the recombination and the mutation operations. In this paper, two modified hybrid evolutionary algorithms contained time-variant adaptive evolutionary technique are proposed for solving linear equations in which recombination operation is absent. The effectiveness of the recombination operator has been studied for the time-variant adaptive hybrid algorithms for solving large set of linear equations. Several experiments have been carried out using both the proposed modified hybrid evolutionary algorithms (in which the recombination operation is absent) and corresponding existing hybrid algorithms (in which the recombination operation is present) to solve large set of linear equations. It is found that the number of generations required by the existing hybrid algorithms (i.e. the Gauss-Seidel-SR based time variant adaptive (GSBTVA) hybrid algorithm and the Jacobi-SR based time variant adaptive (JBTVA) hybrid algorithm) and modified hybrid algorithms (i.e. the modified Gauss-Seidel-SR based time variant adaptive (MGSBTVA) hybrid algorithm and the modified Jacobi-SR based time variant adaptive (MJBTVA) hybrid algorithm) are comparable. Also the proposed modified algorithms require less amount of computational time in comparison to the corresponding existing hybrid algorithms. As the proposed modified hybrid algorithms do not contain recombination operation, so they require less computational effort, and also they are more efficient, effective and easy to implement. Keyword: Adaptive, evolutionary computation, hybrid algorithm, time-variant, successive relaxation. Major area of the paper: Algorithm Statement of Achievement: The time variant adaptive Hybrid algorithms require no Recombination operation for solving linear equations. 1. Introduction Solving a large set of simultaneous linear equations is a fundamental problem that occurs in diverse applications in engineering and science, as well as with applications of mathematics to the social sciences and the quantitative study of business, statistical and economic problems. Also for appropriate decision making related to the same physical problem, sometimes of the physical an appropriate algorithm which converges rapidly and efficiently for solving large set of linear equations is desired. For example, in cases of short-term weather forecast, image processing, simulation to predict aerodynamics performance where solution of very large set of simultaneous linear equations by numerical methods are required and time is an important factor for practical application of the results. For large set of linear equations, especially for sparse and structured coefficients, iterative 2 methods are preferable, as iterative method are unaffected by round off errors [1]. The rate of convergence of the well-known classical numerical iterative methods namely the Jacobi method and the Gauss-Seidel method is very slow for the both methods and can be accelerated by using successive relaxation (SR) technique [2, 3]. But the speed of convergence depends on the relaxation factor ω (0 < ω < 2) and SR technique is very much sensitive to the relaxation factor [4, 5]. However, it is often very difficult to estimate the optimal relaxation factor, which is a key parameter of the SR technique [4, 6]. On the other hand the evolutionary algorithms (EA) are developed from some natural phenomena: genetic inheritance and Darwinian strife for survival [7, 8, 9]. Obvious biological evidence is that a rapid change is observed at early stages of life and a slow change is observed at later stages of life in all kinds of animals/plants. These changes are more often occurred dynamically depending on the situation exposed to them. By mimicking this emergent natural evidence, a special dynamic timevariant mutation (TVM) operator is proposed by Hashem [10], Watanabe and Hashem [11] and Michalewicz et. al. [12,13, 14] in global optimization problems. Generally, most of the works on EA can be classified as evolutionary optimization (either numerical or combinatorial) or evolutionary learning. Recently, Gauss-Seidel based uniform adaptive (GSBUA) hybrid evolutionary algorithm [15] and Jacobi based uniform adaptive (JBUA) hybrid evolutionary algorithm [16] have been developed for solving large set of linear equations by integrating classical numerical methods with uniform adaptive (UA) evolutionary techniques. In these algorithms both recombination and mutations operations are present. Furthermore, Gauss-Seidel based Time variant adaptive (GSBTVA) hybrid evolutionary algorithm [17] and Jacobi based Time variant adaptive (JBTVA) hybrid evolutionary algorithm [18] have been developed for solving large set of linear equations by integrating classical numerical methods with Time variant adaptive (TVA) evolutionary techniques. In these algorithms both recombination and mutations operations are also present. The idea of self-adaptation was also applied in many different fields [14, 19, 20]. Moreover Fogel and Atmar [21] used linear equation solving as test problems for comparing recombination, inversion operations and Gaussian mutation in an evolutionary algorithm. However, the emphasis of their study was not on equation solving, but rather 3 on comparing the effectiveness of recombination relative to mutation and only small size of problems (n = 10) was considered [21]. In this paper, two modified time variant hybrid evolutionary algorithms (i.e. modified GSBTVA and the modified JBTVA algorithms) are proposed to solve large set of linear equations. The proposed modified hybrid algorithms are modified from the existing GSBTVA and the JBTVA algorithms and contain all the evolutionary operations valuable in the existing algorithms except recombination operation. The proposed modified hybrid algorithms initialize uniform relaxation factors in a given domain and “evolve” it by time-variant adaptation technique as well. The main mechanisms of the proposed modified algorithms are initialization, mutation, time variant adaptation, and selection mechanisms (i.e. recombination operation is absent). It makes better use of a population by employing different equation-solving strategies for different individuals in the population. The errors are minimized by mutation and selection mechanisms. We have tried to investigate the necessity of the recombination operation presented in the existing time variant adaptive hybrid evolutionary algorithms [17, 18] and also to investigate where absent of recombination operations hamper the process. The effectiveness of the proposed modified hybrid algorithms is compared with that of corresponding the existing GSBTVA and the JBTVA hybrid evolutionary algorithms. The preliminary investigation has showed that the both proposed modified algorithms are comparable with the corresponding existing hybrid evolutionary algorithms in terms of number of generation required for expected result. Also the proposed modified algorithms are more efficient and effective than the corresponding existing GSBTVA and JBTVA algorithms in terms of computational effort. Moreover the proposed modified hybrid algorithms are more easy to implement and required less memory allocation. 2. The Basic Equations of Classical Methods The system of n linear equations with n unknown x1 , x2 , L ,K, xn can be written as n ∑a x j =1 ij j = bi , (i = 1, 2,L, n ) or equivalently, in matrix form 4 Ax = b (1) where A ∈ ℜ n × ℜ n , x ∈ ℜn and b ∈ ℜn , here ℜ is real number field. We know that for unique solution | A |≠ 0 . Let us assume, without loss of generality, that none of the diagonal entries of A are zero; otherwise rows will be interchanged. Now the coefficient matrix A can be decomposed as A = (D + U + L) where D = (d ij ) is a diagonal matrix, L = (lij ) is a strictly lower triangular matrix and U = (uij ) is a strictly upper triangular matrix. Then according to classical Jacobi method, Eq.(1) can be rewritten as x ( k +1) = H j x ( k ) + V j ( with x ( k ) = x1( k ) , x 2( k ) , L , x n( k ) ) t and k = 0, 1, 2,L (2) where H j = D −1 (−L − U ) is the Jacobi iteration matrix and V j = D −1b . On introducing SR technique [3, 6] Eq. (2),can be written as x (k +1) = H j (ω ) x (k ) + V j (ω ) (3) where, H j (ω ) = D −1{(1 − ω)I − ω (L + U )} , V j ( ω ) = ω D -1b , , ω ∈ ( ωL , ωU ) is the relaxation factor which influences the convergence rate greatly and I is the identity matrix; also ωL and ωU are the lower and upper bound of ω . Similarly according to the classical Gauss-Seidel method by introducing SR technique [3, 6], Eq. (2), can be again written as x (k +1) = H g (ω ) x (k ) + Vg (ω ) (4) where H g (ω ) = (I + ω D -1L) −1{(1 − ω ) I − ω D -1U} is the Gauss-Seidel-SR iteration matrix and Vg ( ω) = ω (I + ω D −1L) −1 D -1b . 3. Time Variant Adaptive Hybrid Evolutionary Algorithms 3.1 The Existing Hybrid Evolutionary Algorithms The main aim of the hybridization of the classical SR methods with the evolutionary computation techniques is to self-adapt the relaxation factor used in the classical SR technique. And the time variant adaptation technique is used to escape from disadvantage of the uniform adaptation and for 5 introducing fine-tuning to the rate of convergence. The relaxation factors are adapted on the basis of the fitness of individuals (i.e. how well an individual solves the equations). Similar to many other evolutionary algorithms, the hybrid algorithm always maintains a population of approximate solutions to the linear equations. Each solution is represented by an individual. The initial population is generated randomly from the field ℜ n . Different individuals use different relaxation factors. Recombination in the hybrid algorithm involves all individuals in a population. If the population is of size N, then the recombination will have N parents and generates N offspring through linear combination. Mutation is achieved by performing one iteration of classical (Gauss-Seidel or Jacobi) method with SR technique. The mutation is stochastic since ω, used in the iteration are initially determined between ωL (=0) and ωU (=2), is adapted stochastically in each generation and adaptation nature is also time-variant. The fitness of an individual is evaluated on the basis of the error of an approximate solution. For example, given an approximate solution (i.e., an individual) z, its error is defined by ||e(z)|| = ||Az – b|| . The relaxation factors are adapted after each generation, depending on how well an individual performs (in terms of the error). The main steps of the existing JBTVA and the GSBTVA hybrid algorithms are – Initialization, Recombination, Mutation, Adaptation and Selection mechanism [17, 18]. The pseudo-code structures of the existing hybrid evolutionary algorithms [17, 18] is given bellow: Algorithm_JBTVA/GSBTVA() begin t ← 0 ; /* Initialize the generation counter */ (0) ) Initialize population: X( 0 ) = {x1(0) , x (0 2 Kx N } ; /* Here x i( t ) i ⇒ i-th individual at t-th generation */ ⎧⎪ω + d L 2 ⎪⎩ωi −1 + d Initialize relaxation factors: ω = ⎨ i Evaluate population: | |e( X)|| = {||e(z )|| : z ∈ X} ; While (not termination-condition) do begin Select individuals for reproduction: Apply operators: for i = 1 for 1 < i ≤ N , d = ωU − ωL N 6 ( )′ Crossover: X ( k + c ) = R X ( k ) ; /* R is stochastic matrix & Superscript c indicates Crossover */ ( k + m) Mutation: x i = H q (ωi ) x i( k +c ) + Vq (ωi ) ; /* where q ∈ { j , g} , “j” indicate Jacobi based method and “g” indicate Gauss-Seidel based method */ x ( k + m) )|| : ~ x ( k + m) ∈ X ( k + m) } ; Evaluate newborn offspring: | |e(X ( k + m ) )|| = {||e( ~ Adaptation of ω : ω x = f x (ω x , ω y , p x ) & ω y = f y (ω x ,ω y , p y ) ; /* p x and p y are adaptive probability functions */ Selection and reproduction: X( k +1) = ς ( X( k + m ) ) ; k ← k + 1 ; /* Increase the generation counter */ end end As the adaptation and the selection are the main characteristic mechanisms of the existing hybrid algorithms(as well as proposed modified algorithm also), so we have described them in brief bellow: Adaptation: Let x (k + m ) and y (k + m ) be two offspring individuals with relaxation factors ω x and ω y and with errors (fitness values) || e(x m ) || and || e(y m ) || respectively. Then the relaxation factors ω x and ω y are adapted as follows: (a) If || e(x m ) ||>|| e(y m ) ||, (i) then ω x is moved toward ω y by setting ωxm = (0.5 + p x )(ωx + ωy ) and (5) (ii) ω y is moved away from ωx by setting ⎧ωy + p y( ωU − ωy ), when ωy > ωx ω my = ⎨ ⎩ ωy + p y( ωL − ωy ), when ωy < ωx where px = E x × N (0,0.25 ) × Tω and (6) p y = E y × |N(0,0.25)| × Tω , are the time-variant adaptive (TVA) probability parameters of ωx and ωy respectively. 7 Here Tω = λ ln(1 + 1 ) , λ > 10 t+λ (7) which gives the basic time-variant parameter (BTV) [18] in which λ is an exogenous parameter. λ is used to increase or decrease the rate of change of curvature with respect to the number of iterations t (see Figure 1). Also N (0, 0.25) is the Gaussian distribution with mean 0.0 and standard deviation 0.25. Now Ex and Ey indicate the approximate initial boundary of the variation of TVA parameters of ωx i.e. (-Ex, Ex) and ωy i.e. (0, Ey) respectively. Note that ω xm and ω ym are adapted relaxation factors correspond to ωx and ω y respectively. (b) If || e(x m ) ||<|| e(y m ) || , then ωx and ωy are adapted in the same way as above but in the reverse order of ω xm and ω my . (c) If || e (x m ) ||=|| e (y m ) ||, no adaptation will take place i.e. ωxm = ωx and ωym = ωy . The characteristics of BTV parameter including TVA probability parameter px and py are shown in Figures 1, 2 and 3 respectively. 0.014 0.04 1.0 λ = 50 and Ex = 0.125 0.8 0.010 0.008 0.00 Tω 0.6 py - 0.02 0.4 λ = 50 and Ey = 0.03125 0.012 0.02 px λ= 20 λ= 50 λ= 200 0.006 0.004 0.2 - 0.04 0.0 -0.06 0.002 0.000 -0.002 0 200 400 600 800 1000 0 100 Generation Figure 1 200 300 400 Generation Figure 2 500 0 100 200 300 400 500 Generation Figure 3 Selection and Reproduction: The best N/2 offspring individuals are selected according to their fitness values (errors). Then the selected offspring are reproduced (i.e. each parent individuals generate two offspring). Thus the next generation of N individuals is formed. 8 3.2 The Proposed Modified Hybrid Evolutionary Algorithms The key idea behind the proposition of the modified algorithms (Modified Jacobi Based Time Variant Adaptive (MJBTVA) hybrid evolutionary algorithm and the Modified Gauss-Seidel Based Time Variant Adaptive (MGSBTVA) hybrid evolutionary algorithm is to examine the necessity of recombination operation for solving linear equations. So the proposed modified hybrid evolutionary algorithms contains all steps of the JBTVA and GSBTVA hybrid evolutionary algorithms except the step – recombination. And we do not repeat the pseudo-code structures of the both modified time variant hybrid evolutionary algorithms here. 4. Performance of The Modified Algorithms In order to evaluate the effectiveness of the proposed MJBTVA and the MGSBTVA hybrid algorithm, a number of numerical experiments have been carried out to solve the Eq. (1). The following settings were valid for all the experiments: The dimension of unknown variable n = 200 , Population size N =2, boundary of relaxation factors ( ωL ,ωU ) = (0, 2), the approximate initial boundaries, Ex and Ey were set at 0.125 and 0.03125 respectively, the exogenous parameter λ was set at 50, each individual x of population X was initialized from the domain ℜ 200 ∈ (-30, 30) randomly and uniformly, the threshold error was η set at 10 −7 and the stochastic matrix R was generated randomly. The first problem was set by considering aii ∈ (100,200); aij ∈ (-10,10); bi ∈ (100,200), i, j = 1, L , n and (problem P1 in Table 1 & 2). A single set of parameters was generated randomly from the abovementioned problem and the following two experiments were carried out. The problem was solved with an error smaller than 10 −7 (threshold error). In the first experiment, the comparison between the JBTVA [17] and the proposed MJBTVA had been made. Figure 4 shows the numerical results of this experiment. From this experiment, two important observations came out. Firstly the proposed MJBTVA algorithm is comparable with the 9 JBTVA algorithm in terms of generation. Secondly the proposed MJBTVA algorithm required less amount of time than that of JBTVA algorithm. 1.E+07 1.0E+06 1.0E+04 1.E+04 Time for MJBTVA =0.406 sec Time for JBTVA =0.390 sec 1.0E+02 1.E+01 1.0E+00 MJBTVA 1.0E-02 MGSBTVA Error Error Time for MGSBTVA = 0.265 sec Time for GSBTVA = 0.301 sec GSBTVA 1.E-02 JBTVA 1.0E-04 1.E-05 1.0E-06 1.0E-08 Figure 4: Comparison between t MJBTVA and JBTVA algorithms 31 26 21 16 6 1 Generation 11 1.E-08 1 10 19 28 37 46 55 Generation Figure 5: Comparison between MGSBTVA and GSBTVA algorithms In the second experiment, the comparison between the GSBTVA [18] and the proposed MGSBTVA had been made. Figure 5 shows the numerical results of this experiment. Again two observations came out – (i) the proposed MGSBTVA algorithm is comparable with the GSBTVA algorithm in terms of generation and (ii) the proposed MGSBTVA algorithm required less amount of time than that of GSBTVA algorithm. Elapse time (mili sec) JBTVA Alg. Generation (elapsed) MJBTVA Alg. Elapse time (mili sec) Domain of the elements of the coefficient matrix A & the right side constant vector b of the test Problems Generation (Elapsed) Label of Test Problems Table 1: Comparison between the JBTVA and the MJBTVA hybrid algorithms for several randomly generated test problems P1 57 390 58 aii∈(100,200); aij ∈(-10,10); bi∈(100,200) 406 P2 171 968 168 aii∈(1,400); aij ∈(-4,4); bi= 100 1046 P3 39 579 37 aii∈(-50,50); aij ∈(-1,1); bi∈(-1,1) 625 P4 42 539 40 aii= 100; aij ∈(-1,1); bi∈(-00,100) 562 In Pthe second experiment, the comparison between the GSBTVA [17] and the proposed MGSBTVA 10 157 10 aii = 50; aij ∈(-10,10); bi∈(-5,5) 187 5 P6 aii =50; aij = (-1,1); bi = 2 10 172 10 187 wasP studied. numerical of this experiment. There are also aii Figure =20i; 5 shows aijthe =(100-j) /20 ; bresults 71 1125 84 two observations 1359 7 i =10 i P8 aii= 20n; aij =j; bi= i 64 1060 70 1410 – (i) MGSBTVA algorithmbi∈(-2,3) is comparable475 with the7422 GSTVA algorithm in 7625 terms of P9 the proposed 489 aii =(-20, 200); aij ∈(-2,3); P10 74 1203 75 aii =40; aij ∈(-4,4); bi =200 1250 generation. the proposed less amount35of time than the GSBTVA.625 P11 531 that of 38 a(ii) aij MJBTVA ∈(-1,1); required bi∈(-1,1) ii∈(-50,50); 10 P1 P2 P3 P4 P5 P6 P7 P8 P9 P10 P11 aii∈(100,200); aii∈(1,400); aii∈(-50,50); aii= 100; aii = 50; aii =50; aii =20i; aii= 20n; aii =(-20, 200); aii =40; aii∈(-50,50); aij ∈(-10,10); bi∈(100,200) aij ∈(-4,4); bi= 100 aij ∈(-1,1); bi∈(-1,1) aij ∈(-1,1); bi∈(-00,100) aij ∈(-10,10); bi∈(-5,5) aij = (-1,1); bi = 2 aij =(100-j) /20 ; bi =10 i aij =j; bi= i aij ∈(-2,3); bi∈(-2,3) aij ∈(-4,4); bi =200 aij ∈(-1,1); bi∈(-1,1) 31 105 39 39 08 13 117 64 571 109 13 265 828 562 485 141 203 1500 875 736 1439 110 32 108 42 41 08 13 116 69 583 111 13 Elapse time (mili sec) GSBTVA Alg. Generation (elapsed) MGSBTVA Alg. Elapse time (mili sec) Domain of the elements of the coefficient matrix A & the right side constant vector b of the test Problems Generation (Elapsed) Label of Test Problems Table 2: Comparison between the GSBTVA and the proposed MGSBTVA hybrid algorithms for several randomly generated test problems 301 843 579 578 156 219 1547 968 7547 1469 141 Table 1and 2 represent eleven test problems, labeled from P1 to P11, with dimension, n = 200 . For each test problem Pi: i = 1, 2, . . ., 11, the coefficient matrix A and constant vector b were all generated uniformly and randomly within given domains. Table 1 shows the comparison between the number of generation (iteration) of the JBTVA and the proposed MJBTVA hybrid algorithms to the given threshold error, η . One observation can be made immediately from this table that the proposed MJBTVA hybrid algorithm is comparable with the existing JBTVA hybrid algorithm for all the problems. Another observation is that the proposed MJBTVA required less amount of time than that of JBTVA for all the problems. Table 2 shows the comparison between the number of generation (iteration) of the GSBTVA and the proposed MGSBTVA hybrid algorithms to the given threshold, η . One observation can be made immediately from this table that the proposed MGSBTVA hybrid algorithm is comparable with the GSBTVA hybrid algorithm for all the problems. Another observation is that the proposed MGSBTVA required less amount of time than that of MGSBTVA for all the problems. It is to be mentioned here that a total of ten independent runs with different sample paths were conducted. The average results are reported here. Also for all the experiments, the times were measured in the same environment. 11 5. Concluding Remarks In this paper, two modified ( Jacobi based and Gass-Seidel based) hybrid evolutionary algorithm with time-variant adaptive (TVA) technique has been proposed for solving large set of linear equations. These proposed MJBTVA and MGSBTVA hybrid algorithms have been modified by omitted completely the recombination operation from the JBTVA and the GSBTVA hybrid algorithms respectively. The effectiveness of the proposed modified algorithms is compared with that of the JBTVA and the GSBTVA hybrid algorithms respectively. This preliminary investigation has showed that both the proposed MJBTVA and MGSBTVA hybrid algorithms are comparable in terms of generation (iteration) with the JBTVA and GSBTVA respectively. Also both the proposed MJBTVA and MGSBTVA hybrid algorithms required less amount of time than the JBTVA and GSBTVA hybrid algorithm respectively. Furthermore since proposed modified hybrid algorithms have no recombination operation, so they require less memory allocation and computational effort to solve the problems. Moreover, the proposed modified hybrid algorithms are also very simple and easier to implement both in sequential and parallel computing environments. References 1. F. Curtis, Geraid Patrick and O. Wheatley, Applied Numerical Analysis, 5th edition AddisonWesley, New York, (1998). 2. D. Young, Iterative Solution for Large Linear System, New York Academic, (1971). 3. G. Engeln-Mullges and F. Uhlig, Numerical Algorithms with C, Springer, Berlin, (1996). 4. L. A. Hagaman, and D. M. Young, Applied Iterative, Methods, New York. Academic Press, (1981). 5. J. Stoer, R. Bulirsch, An Introduction to Numerical Analysis, 2nd edition, Springer, New York (1991). 6. A. Gourdin and M. Boumahrat, Applied Numerical Methods, Prentice Hall of India, New Delhi, (1996). 7. T. Bäck, U. Hammel and H. -P. Schwefel, Evolutionary Computation: Comments on the History and Current State, IEEE Trans. On Evolutionary Computation, Vol. 1, No. 1, (1997), 3-17. 8. T. Bäck and H. P Schwefel, An Overview of Evolutionary Algorithms for Parameter Optimization, Evolutionary Computation, Vol.1, No. 1, (1993), 1-23. 12 9. M. Schoenauer, and Z. Michalewicz, Evolutionary Computation, Control and Cybernetics Vol. 26, No. 3, (1997), 303-388. 10. M. M. A. Hashem, Global Optimization Through a New Class of Evolutionary Algorithm, Ph.D. dissertation, Saga University, Japan, (1999), 29-30. 11. K. Watanabe and M. M. A. Hashem, Evolutionary Computations: New Algorithms and their Applications to Evolutionary Robots, Series: Studies in Fuzziness and Soft Computing, Vol. 147, Springer-Verlag, Berlin/New York, (2004), 12. Z. Michalewicz, Evolutionary Computation Technique for Nonlinear Programming Problem, International Trans. on Operation Research, Vol. 1, No. 2, (1994), 223-240. 13. Z. Michalewicz, and N. F. Attia, Evolutionary Optimization of Constrained Problems, Proceeding of the 3rd Annual Conference on Evolutionary Programming, River Edge, N3, World Scientific, (1996), 98-108. 14. R. Salomon and J. L. Van Hemmen, Accelerating Back Propagation Through Dynamic Selfadaptation, Neural Networks Vol. 9 No-4, (1996), 589-601. 15. Jun He, J. Xu, and X. Yao, Solving Equations by Hybrid Evolutionary Computation Techniques, Transactions on Evolutionary Computation, Vol.4, No-3, (Sept-2000), 295-304. 16. Jamali, A. R. M. Jalal Uddin, M. M. A. Hashem and M. B. Rahman, An Approach to Solve Linear Equations Using a Jacobi-Based Evolutionary Algorithm, Proceeding of the ICEECE, December 22–24, Dhaka, Bangladesh, (2003), 225-230. 17. Jamali, A. R. M. Jalal Uddin, M. M. A. Hashem and M. B. Rahman, An Approach to Solve Linear Equations Using Time-Variant Adaptive Based Hybrid Evolutionary Algorithm, The Jahangirnagar University Journal of Science, Jahangirnagar University, Bangladesh, Vol. 27, (2004), 277-289. 18. Jamali, A. R. M. Jalal Uddin, M. M. A. Hashem and M. B. Rahman, Solving Linear Equations Using a Jacobi Based Time-Variant Adaptive Hybrid Evolutionary Algorithm, Proceedings of The 7th International Conference on Computer and Information Technology (ICCIT) 2004, BRAC University, pp. 688-693 (December 2004). 19. T. Bäck, Self-adaptation, in Handbook of Evolutionary Computation, Oxford University Press. (1997). 20. H.-G. Beyer and K. Deb, On Self adaptive features in Real-Parameter Evolutionary Algorithms, Trans-actions on Evolutionary Computation, Vol.5, No-3, (June 2001), 250-270. 21. D. B. Fogel and J. W. Atmar, Comparing Genetic Operators with Gaussian Mutations in Simulated Evolutionary Process Using Linear Systems, Biol. Cybernetics, Vol. 63, No-2, (1990), 111-114.
9cs.NE
Linear-Time Tree Containment in Phylogenetic Networks Mathias Weller1 1 LIRMM, IBC, Montpellier, France February 21, 2017 Abstract We consider the NP-hard Tree Containment problem that has important applications in phylogenetics. The problem asks if a given leaflabeled network contains a subdivision of a given leaf-labeled tree. We develop a fast algorithm for the case that the input network is indeed a tree in which multiple leaves might share a label. By combining this algorithm with a generalization of a previously known decomposition scheme, we improve the running time on reticulation visible networks and nearly stable networks to linear time. While these are special classes of networks, they rank among the most general of the previously considered classes. 1 Introduction The quest to find the infamous “tree of life” has been popular in live sciences since the widespread adoption of evolution as the source of biodiversity on earth. With the discovery of DNA, the task of constructing a history of the evolution of a set of species has become both a blessing and a curse. A blessing because we no longer rely on phenotypical characteristics to distinguish between species and a curse because we are being overwhelmed with data that has to be cleaned, interpreted and visualized in order to draw conclusions. The use of DNA also lead to the realization that trees are not always suited to display ancestral relations, as they fail to model recombination evens such as hybridization (occurring frequently in plants) and horizontal gene transfer (a dominating factor in bacterial evolution) [3, 12]. Thus, researchers are more and more interested in evolutionary networks and algorithms dealing with them (see the monographs by Gusfield [9] and Huson et al. [10]). The particular question that we consider in this work is to tell whether a given evolutionary network “displays” an evolutionary tree, that is, whether the tree-like information that we might have come to believe in the past is consistent with a proposed recombinant evolution. This problem is known as Tree Containment and it has been studied extensively. As it is NP-hard for general networks [11, 13], researchers considered biologically relevant types of networks and developed polynomial-time strategies to solve Tree Containment on them [2, 5, 6, 8, 11, 13] and moderately exponential time algorithms [7]. 1 Using a generalization of the decomposition of Gunawan et al. [8] to general networks, we show that Tree Containment can be solved in polynomial time on networks in which each tree vertex with a reticulation parent is stable 1 on some leaf. This running time degenerates to linear time if the length of a longest “reticulation chain” (directed path consisting only of reticulations) is constant. This class of network contains the following two prominent classes: • nearly stable networks (introduced by Gambette et al. [6]) for which Tree Containment can be solved in O(n2 ) time [6], and • reticulation visible networks (introduced by Cordue et al. [4]) for which Tree Containment can be solved in O(n3 ) time [2, 8] or O(n2 ) time [8]. Preliminaries. Let N be a weakly connected, direct, acyclic graph (DAG) such that N has a single source, called the root r(N ) of N and such that each of the sinks L(N ) of N (called leaves), carries a label (its “taxon”). Then, we call N an evolutionary (or phylogenetic) network (or “network” for short). We call the vertices of indegree at least two in N reticulations and all other vertices tree vertices and we demand that no leaf is a reticulation. N is called binary if all non-leaves have degree (= indegree + outdegree) exactly three, except for the root that has degree two or zero. If N has no reticulations, then it is called a tree. If each label occurs at most k times in N , we call it k-labeled or, if the value of k is unknown or inconsequential, multi-labeled. If not explicitly stated otherwise, all networks and trees are considered to be binary and 1-labeled. We define the relation ≤N such that u ≤N v ⇐⇒ u is a descendant of v (that is, v is an ancestor of u) in N . Note that u ≤N r(N ) for all u ∈ V (N ). For each vertex v of N , we define Nv to be the subnetwork rooted at v, that is, the subnetwork of N that contains exactly the vertices u with u ≤N v and all arcs of N between those vertices. We call any vertex v of N stable on another vertex u if all r(N )-u-paths contain v and we call v stable if v is stable on a leaf of N . Then, N is called reticulation visible if each reticulation r is stable. Further, N is called nearly stable if, for each vertex v, either v or its parents are stable. For all k, a k-labeled network N is said to contain a possibly non-binary tree T if T is a subgraph of N (respecting the leaf-labeling). Further, N is said to display T if N contains a subdivision of T (that is, the result of a series of arc-subdivisions in T ). In this work, we consider the following problem. Tree Containment (TC) Input: a network N , a tree T Question: Does N display T ? Network Decomposition. In the following, we generalize the decomposition theorem introduced by Gunawan et al. [8] to develop a quadratic-time algorithm for Tree Containment in reticulation visible networks. To this end, we have to do some initial cleanup using the following reduction. (EC 1) Let ab be a cherry of N . If ab is a cherry in T , then delete a in both N and T and contract the arc incoming to b in T , otherwise, reject (N, T ). 1u is stable on ℓ if all root-ℓ-paths contain u. 2 Tip r(P ) ℓ4 Base ℓ1 ℓ2 ℓ3 Foundation Figure 1: A leaf ρ of the component DAG Q of N implies a layering of the pyramid P = Nρ into its tip P T (tree nodes ), its base P B (reticulations ), and its foundation P F (leaves below reticulations). Note that leaves may also be in the tip of P . Definition 1. Let N be reduced with respect to (EC 1) and let F be the forest that results from removing all reticulations from N . Then, each tree of F is called tree component of N and each tree component that contains only a leaf of N is called trivial. Let R be the set of roots of the non-trivial tree components of N . The restriction of “≤N ” to R forms a DAG Q and we call it the component DAG of N . More formally, Q := (R, (≤N ) ∩ (R × R)). The goal will be to repeatedly find a leaf ρ of Q and the best possible v of T such that Nρ displays Tv . Then, we shrink both Nρ and Tv to a single leaf and remove ρ from Q. We make use of the special structure of Nρ that follows from the fact that all tree nodes that have a reticulation ancestor in N ρ are leaves of N (as otherwise, they would be part of a tree component below ρ in Q, contradicting ρ being a leaf of Q). Observation 1. Let ρ be a leaf of Q, let r be a reticulation of N with r < N ρ, and let t be a tree vertex of N with t <N r. Then, t is a leaf of N . Definition 2. Let ρ be a leaf of Q. Then, P := Nρ consists of a tree with root r(P ) := ρ, some reticulations and some leaves of N . By Observation 1, P can be divided into “layers” (see Figure 1) and we call P a pyramid with a tip P T (layer of tree vertices), a base P B (layer of reticulations) and a foundation P F (layer of leaves below reticulations). Assumptions. Throughout this work, we will sometimes need access to certain data in constant time. This paragraph justifies why this is possible. In the following, we call a path of N reticulation path if all its vertices except the end vertex are reticulations. 3 Assumption 1. Let r be a reticulation of N that has a reticulation path to a leaf ℓ in N . Knowing r, we can get ℓ in constant time. To assure Assumption 1 we initially go bottom-up from each leaf, updating the information for the reticulations that we meet until we find a tree vertex of N . Then, whenever we create a leaf and assign a label to it, we repeat this procedure starting from this leaf. Furthermore, whenever we delete a leaf, we will also delete all vertices on reticulation paths to this leaf so, once computed, the information is never changed. Hence, we can establish Assumption 1 using only O(|N |) total time. Assumption 2. We can produce a leaf of Q in constant time. Let R denote the roots of the tree components of N . To assure Assumption 2, we initially compute Q from N in O(|N |) time by a bottom-up scan that, upon encountering an arc xy, deletes y if y ∈ / R, or contracts xy if y ∈ R but x ∈ / R. Each time we work on a leaf ρ, the algorithm will replace the tip of Nρ by a single leaf in N (see (PP 1)). To keep Q up to date we just need to delete ρ from Q at that point. This is because the tree component of ρ is no longer non-trivial, but none of the other tree components are affected. Assumption 3. Given a label L, we can compute all leaves of a (multi-labeled) tree that have label L in output-linear time (that is, constant time per leaf ). 2 Multi-Labeled Tree Containment The following is a simple dynamic-programming approach to decide if a multilabeled tree N displays a tree T . To this end, for each vertex v of T , we define D(v) to be the set of vertices u of N such that Nu displays Tv , and we define M (v) to be the set of minima with respect to ≤N of D(v). Lemma 1. Let v ∈ V (T ) with children v1 and v2 . Then,              LCAN (u1 , u2 )) \ (M (v1 ) ∪ M (v2 ) . M (v) = min  ≤N       u1 ∈ M (v1 ) u2 ∈ M (v2 )  Proof. We abbreviate M ′ (v) := ( u1 ∈M (v1 ),u2 ∈M (v2 ) LCAN (u1 , u2 )) \ (M (v1 ) ∪ M (v2 ). First, we show D(v) ⊇ M ′ (v). To this end, consider some u ∈ M ′ (v). Then, there are u1 ∈ M (v1 ) and u2 ∈ M (v2 ) such that u = LCAN (u1 , u2 ). If u1 and u2 are incomparable in N , we can combine a subdivision of Tv1 contained in Nu1 and a subdivision of Tv2 contained in Nu2 with the unique u-u1 -path and the unique u-u2 -path in N to construct a subdivision of Tv in Nu . Otherwise, by symmetry, u1 ≤N u2 , implying u = LCAN (u1 , u2 ) = u2 ∈ M (v2 ), contradicting u ∈ M ′ (v). “⊇”: Consider some w ∈ min≤N M ′ (v) and assume towards a contradiction that w ∈ / M (v). Since, by the argument above, we have w ∈ D(v), we know that there is some u <N w with u ∈ M (v). We show that u ∈ M ′ (v), contradicting minimality of w wrt. ≤N . To this end, let S be a subdivision of Tv contained 4 in Nu and let w1 be such that Sw1 displays Tv1 . Then, w1 ∈ D(v1 ) and there is some u1 ∈ M (v1 ) with u1 ≤N w1 . Let u2 be defined analogously for v2 . Then, z := LCAS (u1 , u2 ) ≤N u as u is the root of the subgraph S in N . Furthermore, z ∈ D(v), implying u ≤N z since u ∈ M (v). Since S is a subtree of the tree N , the LCAs in S and N coincide, implying u = z = LCAS (u1 , u2 ) = LCAN (u1 , u2 ). Finally, as u1 , u2 <S u, we have u ∈ / M (v1 ) ∪ M (v2 ), implying u ∈ M ′ (v). “⊆”: Consider some u ∈ M (v) and assume towards a contradiction that u∈ / min≤N M ′ (v). Consider any subdivision S of Tv that is contained in Nu . Let u1 be such that Su1 displays Tv1 (thus, u1 ∈ D(v1 )) and u1 <S u, implying u1 <N u and let u2 be defined analogously for v2 . Then, by minimality of u wrt. ≤N , we know that LCAN (u1 , u2 ) = u. Let S maximize the lengths of the u-u1 -path and the u-u2 -path (as N is a tree, these lengths are independent). If u1 ∈ / M (v1 ), then there is a vertex u∗1 <N u1 in D(v), contradicting this choice of S. Thus, u ∈ M ′ (v). Furthermore, u ∈ / M (v1 ) ∪ M (v2 ) since u1 , u2 <N u. Hence, u is not minimal in M ′ (v), that is, there is some u′ ∈ M ′ (v) with u′ <N u. However, as shown in the beginning of the proof, M ′ (v) ⊆ D(v) and, thus, u′ ∈ D(v), contradicting u ∈ M (v). Lemma 2. Let N be a k-labeled tree, let T be a tree and let v ∈ V (T ). Then, |M (v)| ≤ k. Proof. The proof is by induction over the height of v in T . As the claim clearly holds for all leaves of N , we assume that it holds for the children v1 and v2 of v in T . Assume towards a contradiction that |M (v)| > k By pigeonhole principle, there is some u1 ∈ M (v1 ) and some two vertices u2 , u′2 ∈ M (v2 ) such that LCAN (u1 , u2 ) ∈ M (v) and LCAN (u1 , u′2 ) ∈ M (v). However, both these vertices are ancestors of u1 in N , contradicting minimality of M (v). Lemma 3. Let N be a k-labeled tree and let T be a tree. Then, we can find the maxima (wrt. ≤T ) of the set of all vertices v such that N displays Tv in O(|N | + min{|N |, |T |} · k 2 ) time. Proof. In order to answer LCA queries in N in constant time, we prepend an O(|N |)-time preprocessing (see, for example [1]). In the following, we say that a vertex v of T is marked if M (v) has been computed. Initially, we compute M (ℓ) for all leaves ℓ of T that have a label occurring in N either by traversing all leaves of N in O(|N |) time (if |N | ≤ |T |) or by checking for each leaf of T whether its label occurs in N in O(|T |) time (if |N | > |T |). Then, we proceed in a bottom-up manner in T , considering vertices that have two marked children. Note that such a vertex can be found in constant time since, whenever we mark a vertex, we can check whether its sibling is marked and, if so, add the parent to a queue. Each time we find a vertex v of T whose children v1 and v2 are both marked, we use Lemma 1 to compute M (v) in O(|M (v1 )| · |M (v2 )|) time which, by Lemma 2 is in O(k 2 ). If Tv is not displayed by N , that is, M (v) = ∅, then we add v1 and v2 to the output list. If v is the root and M (v) = ∅, then we add v to the (at this point empty) output list. If the queue of vertices with marked children runs out, we terminate the algorithm and return the constructed output list. The correctness of this algorithm follows immediately from the fact that v is maximal among all vertices with M (v) = ∅ if and only if M (v) = ∅ and M (u) = ∅ for the parent u of v in T . 5 Lemma 3 immediately implies the following theorem. Theorem 1. Let N be a k-labeled tree and let T be a tree. Then, we can decide if N displays T in O(|N | + |T | · k 2 ) time. 3 Tree Containment in Networks In this section, we show how Lemma 3 can be applied to pyramids (see Definition 2). Given a pyramid P in N , our goal is to display as much of T as possible in P and reduce N using this information. To use Lemma 3 with pyramids, we consider only the tip P T of P and, for each arc xy from the tip to the base, we hang onto x a copy of the unique leaf ℓ with ℓ <N y. Note that Assumption 1 lets us find ℓ in constant time. Lemma 4. Let P be a pyramid and let k be the height of its base. In O(|P T | · min{|P T |, 2k }) time, we can find the maxima (wrt. ≤T ) of the set of all vertices v such that P displays Tv . Proof. Let R := V (P B ) denote the set of vertices in the base of P . Let P ′ denote the multi-labeled tree that results from P T by, for each arc xy ∈ V (P T )×V (P B ), removing xy and hanging a leaf onto x that is labeled with the same label as the unique leaf ℓ with ℓ <N y. Note that P ′ is indeed φ-labeled with φ := min{|P T |, 2k } as no leaf of P can be reached by more than 2k vertices of the tip of P . Also note that |P ′ | ≤ 2|P T | + 1 and, by Assumption 1, P ′ can be constructed in O(|P T |) time. Having constructed P ′ , we use Lemma 3 to compute the maximum (wrt. ≤T ) of the set of all vertices v such that P ′ displays Tv . It remains to show for all v of T that P displays Tv if and only if P ′ does. “⇒”: Let P contain a subdivision S of Tv . Let S ′ be the result of contracting all arcs of S that are incoming to a vertex of R. Since S is a tree, all vertices of R have indegree one and outdegree one in S and, thus, S ′ also displays Tv . To show that P ′ contains S ′ , let xℓ be an arc of S ′ that is not in P ′ . Since neither x nor ℓ can be in R, we know that x is a tree vertex. Since all tree vertices of P that are not in P ′ are leaves in the foundation of P , we know that ℓ is such a leaf. Let p be the unique minimum wrt. ≤S among all ancestors of ℓ in S that are in the tip of P . Let r be the second vertex (after p) of the unique p-ℓ-path in S. Then, pr is an arc between the tip and the base of P and ℓ <N r and thus, P ′ contains a leaf ℓ′ hanging from p that has the same label as ℓ. “⇐”: Let P ′ contain a subdivision S ′ of Tv . To turn S ′ into a subdivision S of Tv that is contained in P , we repeatedly find an arc xℓ in S ′ that is not in P and replace it by a path. Note that ℓ is a leaf of P ′ and x is in the tip of P and there is some x-ℓ-path p in P whose inner vertices are in R. We thus replace xℓ by this path. Let S denote the result of this operation for each such arc xℓ in S ′ . Clearly, S is a subdivision of S ′ and, thus, of Tv . To show that P contains S, it suffices to show that none of the new paths p introduces vertices that were already in S ′ or in any previously added path. For the first claim, note that all newly added vertices are in R and, thus, not in P ′ . For the second claim, note that each label of P ′ occurs at most once in S ′ and each vertex in R is ancestor of a unique leaf in P . Thus, P contains S and, therefore, P displays Tv . It is noteworthy that Lemma 4 might return many vertices v such that Tv is displayed by P and, without any more assumptions in N , the number 6 of possible combinations grows exponentially. Thus, we restrict the class of networks that we are considering by demanding that each tree vertex of N that has a reticulation parent is stable. Hence, r(P ) is stable for all tree components P , which form the tips of the pyramids that we are seeing in the algorithm. In the following, let c denote the leaf that r(P ) is stable on and observe that the set of all vertices v such that P displays Tv and c ≤T v has a unique maximum wrt. ≤T . Thus, at most one of the maxima obtained by Lemma 4 is an ancestor of c in T and we can find it in O(|P T |) time by scanning all subtrees of T induced by the obtained maxima. We then apply the following reduction that places Tv into P and removes all arcs that disagree. (PP 1) Let r(P ) be stable on a leaf c and let v be the unique maximum wrt. ≤T such that c ≤T v and P displays Tv . Then, remove all leaves of N whose label occurs in Tv , remove all vertices in the tip of P except r(P ), remove all arcs outgoing of r(P ), remove all vertices of Tv except v, and label v and r(P ) with the same new label L. Proof of correctness of (PP 1). Let S v be a subdivision of Tv in P and let (N ′ , T ′ ) be the result of applying (PP 1) to (N, T ). “⇐”: Let N ′ contains a subdivision S ′ of T ′ . We show that the result S of replacing r(P ) with S v in S ′ is contained in N (since S is clearly a subdivision of T ). Since S v is contained in P , it suffices to show that S ′ and S v are vertex disjoint (except for r(P )). Towards a contradiction, assume that S ′ and S v both contain a vertex u = r(P ) of P . Since L(S ′ ) and L(S v ) are disjoint, u is ancestor to at least two different leaves in N . Thus, u is in the tip of P , contradicting that u is in N ′ . “⇒”: Let N contain a subdivision S of T and let u := LCAS (L(Tv )). Since r(P ) is stable on c and c ∈ L(Tv ), we have u ≤N r(P ), implying L(Sr(P ) ) ⊇ L(Tv ). Further, maximality of v implies L(Sr(P ) ) ⊆ L(Tv ). Let S ′ result from S by contracting Sr(P ) into a single vertex and labeling this vertex L. Since L(Sr(P ) ) = L(Tv ), we know that S ′ is a subdivision of T ′ and it suffices to show that N ′ contains S ′ . To do this, we show that all vertices of S ′ are in N ′ . Assume towards a contradiction that S ′ contains a vertex w that is not in N ′ . Then, w is in the tip of P , implying L(Sw ) ⊆ L(Sr(P ) ). Thus, w is a vertex of Sr(P ) contradicting w being in S ′ . The algorithm terminates when (PP 1) has been applied to the last pyramid of N and we return yes if and only if both r(N ) and r(T ) have the same label. The overall running time can be bounded by O( i |PiT | · min{|PiT |, 2k }) where k is the length of a longest reticulation path in N and the summation is over all applications of (PP 1). Since the tip of P does not survive an application of (PP 1) to P , we conclude i |PiT | ≤ |N |. Theorem 2. Let T be a tree, let N be a network such that each tree vertex of N that has a reticulation parent is stable, and let k be the length of a longest reticulation path in N . Then, we can determine if N displays T in O(|N | · min{|N |, 2k }) time. It is easy to observe that reticulation visible networks cannot have reticulation paths of length 2 and, as each reticulation is stable, each tree vertex with a reticulation parent is also stable. Furthermore, nearly stable networks cannot have reticulation paths of length 3 and, as each node is either stable or has a 7 stable parent, each tree vertex with a reticulation parent is stable. We thus conclude that Theorem 2 is applicable to these classes of networks. Corollary 1. Let T be a tree and let N be reticulation-visible or nearly stable. Then, we can decide if N displays T in O(|N |) time. 4 Conclusion In conclusion, we continued existing efforts to speed up solving the Tree Containment problem in special types of networks. We showed that, if N is a tree in which each label occurs at most k times, we can solve the problem in O(|N |+|T |·k 2 ) time. Together with a powerful network decomposition inspired by Gunawan et al. [8], this implies an O(|N |)-time algorithm for reticulation visible and nearly stable networks. It is interesting to know what implications this has on known moderately exponential time algorithms, as they are based on the reticulation visible case. Furthermore, we are highly interested in developing parameterized algorithms for Tree Containment and the distance of the input network to being reticulation visible or nearly stable seems to be the canonical starting point. References [1] M. A. Bender and M. Farach-Colton. The LCA problem revisited. volume 1776 of LNCS, pages 88–94. Springer, 2000. [2] M. Bordewich and C. Semple. Reticulation-visible networks. Advances in Applied Mathematics, (78):114–141, 2016. [3] J. M. Chan, G. Carlsson, and R. Rabadan. Topology of viral evolution. Proceedings of the National Academy of Sciences, 110(46):18566–18571, 2013. [4] P. Cordue, S. Linz, and C. Semple. Phylogenetic networks that display a tree twice. Bulletin of mathematical biology, 76(10):2664–2679, 2014. [5] J. Fakcharoenphol, T. Kumpijit, and A. Putwattana. A faster algorithm for the tree containment problem for binary nearly stable phylogenetic networks. In 12th International Joint Conference on Computer Science and Software Engineering (JCSSE’15), pages 337–342. IEEE, 2015. [6] P. Gambette, A. D. M. Gunawan, A. Labarre, S. Vialette, and L. Zhang. Locating a tree in a phylogenetic network in quadratic time. volume 9029 of LNCS, pages 96–107. Springer, 2015. [7] A. D. Gunawan, B. Lu, and L. Zhang. A program for verification of phylogenetic network models. Bioinformatics, 32(17):i503–i510, 2016. [8] A. D. M. Gunawan, B. DasGupta, and L. Zhang. Locating a phylogenetic tree in a reticulation-visible network in quadratic time. In Proceedings of the 20th Annual International Conference on Research in Computational Molecular Biology (RECOMB’16), volume 9649 of LNBI. Springer, 2016. [9] D. Gusfield. ReCombinatorics: the algorithmics of ancestral recombination graphs and explicit phylogenetic networks. MIT Press, 2014. [10] D. H. Huson, R. Rupp, and C. Scornavacca. Phylogenetic networks: concepts, algorithms and applications. Cambridge University Press, 2010. [11] I. A. Kanj, L. Nakhleh, C. Than, and G. Xia. Seeing the trees and their branches in the network is hard. Theoretical Computer Science, 401(1-3):153–164, 2008. [12] T. J. Treangen and E. P. Rocha. Horizontal transfer, not duplication, drives the expansion of protein families in prokaryotes. PLoS Genet, 7(1):e1001284, 2011. [13] L. Van Iersel, C. Semple, and M. Steel. Locating a tree in a phylogenetic network. Information Processing Letters, 110(23):1037–1043, 2010. 8
8cs.DS
arXiv:1707.09870v2 [cs.CV] 13 Sep 2017 Extremely Low Bit Neural Network: Squeeze the Last Bit Out with ADMM Cong Leng, Zesheng Dou, Hao Li, Shenghuo Zhu, Rong Jin Alibaba Group, Hang Zhou, China {lengcong.lc, zesheng.dzs, lihao.lh, shenghuo.zhu, jinrong.jr}@alibaba-inc.com Abstract Although deep learning models are highly effective for various learning tasks, their high computational costs prohibit the deployment to scenarios where either memory or computational resources are limited. In this paper, we focus on compressing and accelerating deep models with network weights represented by very small numbers of bits, referred to as extremely low bit neural network. We model this problem as a discretely constrained optimization problem. Borrowing the idea from Alternating Direction Method of Multipliers (ADMM), we decouple the continuous parameters from the discrete constraints of network, and cast the original hard problem into several subproblems. We propose to solve these subproblems using extragradient and iterative quantization algorithms that lead to considerably faster convergency compared to conventional optimization methods. Extensive experiments on image recognition and object detection verify that the proposed algorithm is more effective than state-of-theart approaches when coming to extremely low bit neural network. 1 Introduction These years have witnessed the success of convolutional neural networks (CNNs) in a wide range computer vision tasks, such as image classification, object detection and segmentation. The success of deep learning largely owes to the fast development of computing resources. Most of the deep learning models are trained on high-ended GPUs or CPU clusters. On the other hand, deeper networks impose heavy storage footprint due to the enormous amount of network parameters. For example, the 16-layers VGG involves 528 MBytes of model parameters. Both the high computational and storage cost become impediments to popularize the deep neural networks to scenarios where either memory or computational resources are limited. The great interest to deploy deep learning systems on low-ended devices motives the research in compressing deep models to have smaller computation cost and memory footprints. Considerable efforts have been mounted to reduce the model size and speed up the inference of deep models. Denil et al. pointed out that network weights have a significant 1 redundancy, and proposed to reduce the number of parameters by exploiting the linear structure of network [1], which motivated a series of low-rank matrix/tensor factorization based compression algorithms, e.g. [2, 3, 4]. Alternatively, multiple studies were devoted to discritizing network weights using vector quantization methods [5, 6], which often outperformed the matrix/tensor factorization based methods [6]. Han et al. presented the deep compression method that integrates multiple compression methods to achieve a large reduction in model size [7]. Another line of work for model compression is to restrict network weights to low precision with a few bits. The advantage of this restriction is that an expensive floating-point multiplication operation can now be replaced by a sequence of cheaper and faster binary bit shift operations. This not only reduces the memory footprints but also accelerates the computation of the network. These approaches work well when pretrained weights are quantized into 4-12 bits [8, 9, 10, 11]. When coming to extremely low bit networks, i.e. only one or two bits are used to represent weights [12, 13, 14], they only work well on simple datasets (e.g. MNIST and CIFAR10), and usually incur a large loss on challenging datasets like ImageNet. In this work, we focus on compressing and accelerating deep neural networks with extremely low bits weights, and present a unified strategy for learning such low bits networks. We overcome the limitation of the existing approaches by formulating it as a discretely constrained non-convex optimization problem, which is usually referred to as mixed integer programs (MIP). Given the NP hard nature of MIPs, we proposed a framework for learning extremely low bit neural network using the technique of alternating direction method of multipliers (ADMM) [15]. The main idea behind our method is to decouple the continuous variables from the discrete constraints using an auxiliary variable in the discrete space. This leads to a convenient form of the objective which is amenable to existing nonconvex optimization algorithms. Unlike previous low bit quantization methods [12, 16, 17] that incorporate an ad-hoc modification of the gradients for continuous weights, we simultaneously optimize in both continuous and discrete spaces, and connect the two solutions using an augmented Lagrangian. This is consistent with the previous observation from [18] that, by decoupling discrete constraints in MIP, one can use the information from the dual problem through ADMM to obtain a better upper bound. As a result of this reformulation, we can divide the problem of low bits quantized neural network into multiple subproblems which are significantly easier to solve. The main contributions of this paper are summarized as follows: • We model the low bits neural network as a discretely constrained nonconvex optimization problem, and introduce auxiliary variables to decouple the continuous weights from the discrete constraints. With the use of ADMM, the originally hard problem are decomposed into several subproblems including proximal step, projection step and dual update. • We show how the resulting subproblems can be efficiently solved. We utilize extragra2 dient method to accelerate the convergence of proximal step, and propose an iterative quantization algorithm to solve the projection step. The proposed algorithm enjoys a fast convergence in practice. • We apply the proposed method to various well-known convolutional neural networks. Extensive experiments on multiple vision tasks including image classification and object detection demonstrate that the proposed method significantly outperforms the state-of-the-art approaches. 2 Related Work Due to the high efficiency in both computation and memory footprints, low bits quantization of deep neural networks have received much attention in the literature. In this section, we have a brief review of the representative techniques. We also give a brief introduction to ADMM algorithm and its nonconvex extension. 2.1 Low bits quantization of neural network The research of low bits quantization of neural network can be traced back to 1990s [19, 20]. Most of the benefits of low bits quantization, such as memory efficiency and multiplication free, had already been explored in these papers. However, the networks are shallow at that age so these approaches do not verify their validity in deep networks and large scale datasets. In recent years, with the explosion of deep learning in various tasks, low bits quantization techniques have been revisited. Some early works quantize the pretrained weights with 4-12 bits and find such approximations do not decrease predictive performance [10, 8, 9, 11]. More recent works focus on training extremely low bits network from scratch with binary or ternary weights. Among these works, BinaryConnect [12] is the most representative one. BinaryConnect directly optimizes the loss of the network with weights W replaced by sign(W ). In order to avoid the zero-gradient problem of sign function, the authors approximate it with the “hard tanh” function in the backward process. This simple idea inspired many following works. BinaryConnect only achieves good results on simple datasets such as MNIST, CIFAR10 and SVHN, but suffers a large degradation on challenging datasets like ImageNet. Many efforts have been devoted to improve the performance of BinaryConnect. For example, Binary Weight Network (BWN) [16] proposes to improve the performance of BinaryConnect with a better approximation by introducing scale factors for the weights during binarization. Ternary Weight Network (TWN) [17] extends the idea of BWN to network with ternary weights and achieves a better performance. Inspired by BinaryConnect, in order to avoid the zero-gradient problem, both BWN and TWN modify the backward process by applying the gradients of the loss at the quantized weights. 3 Unlike previous works, we mathematically formulated the low bits quantization problem as a discretely constrained problem and present a unified framework based on ADMM to solve it in an efficient way. We simultaneously optimize the problem in both continuous and discrete space, and the two solutions are closely connected in the learning process. 2.2 ADMM and its nonconvex extension Alternating Direction Method of Multipliers (ADMM) [15] is an algorithm that is intended to blend the decomposability of dual ascent with the superior convergence properties of the method of multipliers. The algorithm solves problems in the form: min f (x) + g(z) s.t. Ax + Bz = c (1) with variables x ∈ Rn and z ∈ Rm , where A ∈ Rp×n , B ∈ Rp×m and c ∈ Rp . The augmented Lagrangian of Eq.(1) can be formed as: Lρ (x, z, y) = f (x) + g(z) + yT (Ax + Bz − c) + (ρ/2)kAx + Bz − ck22 (2) where y is the Lagrangian multipliers, and ADMM consists of three step iterations: xk+1 := arg min Lρ (x, zk , yk ) x zk+1 := arg min Lρ (xk+1 , z, yk ) z yk+1 k := y + ρ(Axk+1 + Bzk+1 − c) Even though ADMM was originally introduced as a tool for convex optimization problems, it turns out to be a powerful heuristic method even for NP-hard nonconvex problems. Recently, this tool has successfully been used as a heuristic to find approximate solutions to nonconvex mixed program problems [18, 21], which is very similar to our problem as noted later. 3 The Proposed Method Let us first define the notion in this paper. Denote f (W ) as the loss function of a normal neural network, where W = {W1 , W2 , · · · , WL }. Wi denotes the weights of the i-th layer in the network, which for example can be a 4-dimension tensor in convolutional layer or a 2-dimension matrix in fully connected layer. For the simplicity of notation, we regard all the entries in Wi as a di -dimension vector in Rdi , and take W as the concatenation of P d these vectors so that W ∈ R with d = i di . In this work, we concentrate on training extremely low bits quantized neural networks. In specific, the weights of the network are restricted to be either zero or powers of two so 4 that the expensive floating-point multiplication operation can be replaced by cheaper and faster bit shift operation. In this section, we aim to mathematically model this problem and efficiently solve it. 3.1 Objective function Intuitively, training a low bits neural network can be modeled as discretely constrained optimization, or in particular, mixed integer programs. For example, the weights in a ternary neural network are restricted to be −1, 0 or +1. Training such network can be mathematically formulated as mixed integer programs: min f (W ) W s.t. W ∈ C = {−1, 0, +1}d Since the weights are restricted to be zero or powers of two, we have constraints of this form C = {−2N , · · · , −21 , −20 , 0, +20 , +21 , · · · , +2N } where N is an integer which determines the number of bits. As in [16], we further introduce a scaling factor α to the constraints, i.e., instead of requiring C = {· · · , −2, −1, 0, +1, +2. · · · }, we simply restrict C to C = {· · · , −2α, −α, 0, +α, +2α, · · · } with an arbitrary scaling factor α > 0 that is strictly positive. It is worthy noting that the scale factor α in various layers can be different. In other words, for a neural network with L layers, we actually introduce L different scaling factors {α1 , α2 , · · · , αL }. Formally, the objective function of low bits quantized neural networks can be formulated as: min f (W ) W s.t. W ∈ C = C1 × C2 × · · · × CL (3) where Ci = {0, ±αi , ±2αi , · · · , ±2N αi } and αi > 0. We emphasize that the scaling factor αi in each layer doesn’t incur more computation to the convolutional operator, because it can be multiplied after the efficient convolution with {0, ±1, ±2, · · · , ±2N } done. From the perspective of constrained optimization, the scaling factor αi helps to expand the constraint space. As an example, Fig.1 gives an illustration of how it works for ternary network. In two dimensional space, for constraint {−1, 0, +1}, the possible solutions of ternary neural network are nine discrete points in the space. In contrast, with the scaling factor added, the constrained space is expanded to be four lines in the space. This large expansion of the constrained space will make the optimization easier. 3.2 Decouple with ADMM The optimization in Eq.(3) is NP-hard in general because the weights are constrained in a discrete space. Most previous works try to directly train low bits models to minimize the 5           (a) (b) Figure 1: In ternary neural network, scaling factor expands the constrained space from (a) nice discrete points to (b) four lines in the space (two dimensional space as an example). loss. For example, BinaryConnect [12] replace the weights W with sign(W ) in the forward process so that the constraints will be automatically satisfied. Since the gradients of sign(W ) to W is zero everywhere, the authors replace the sign function with “hard tanh” in the backward process. The same idea is also adopted by BWN [16] and TWN [17]. However, as indicated in [22], the use of different forward and backward approximations causes the mismatch of gradient, which makes the optimization instable. We overcome the limitation of previous approaches by converting the problem into a form which is suitable to existing nonconvex optimization techniques. We introduce an auxiliary variable which is subject to the discrete restriction and equal to original variable. This is used with ADMM, which will result in the effect that the discrete variables being decoupled when we consider their minimization. Our basic idea is largely inspired by recent successful application of ADMM in mixed integer programs [18, 21]. First of all, defining an indicator function IC for whether W ∈ C, the objective in Eq.(3) can be written as min f (W ) + IC (W ) (4) W where IC (W ) = 0 if W ∈ C, otherwise IC (W ) = +∞. By introducing an auxiliary variable G, we can rewrite the optimization in Eq.(4) with an extra equality constraint so that the weights is constrained to be equal to the discrete variable, but not subject to that restriction. In detail, the objective can be reformulated as: min f (W ) + IC (G) s.t. W =G W,G (5) Now we are considering a nonconvex optimization with convex linear constraints. Prob6 lems of such form can be conveniently solved with ADMM. The augmented Lagrange of Eq.(5), for parameter ρ > 0, can be formulated as: ρ Lρ (W, G, µ) = f (W ) + IC (G) + kW − Gk2 + hµ, W − Gi 2 (6) where µ denotes the Lagrangian multipliers and h·, ·i denotes the inner product of two vectors. With some basic collection of terms and a change of variable λ = (1/ρ)µ, Eq.(6) can be equivalently formed as: ρ ρ Lρ (W, G, λ) = f (W ) + IC (G) + kW − G + λk2 − kλk2 2 2 (7) Following the standard process of ADMM, this problem can be solved by repeating the following iterations: W k+1 := arg min Lρ (W, Gk , λk ) (8) W Gk+1 := arg min Lρ (W k+1 , G, λk ) (9) G λk+1 := λk + W k+1 − Gk+1 (10) which is respectively the proximal step, projection step and dual update. Unlike previous works, we simultaneously optimize the problem in both continuous space (i.e., proximal step) and discrete space (i.e., projection step), and the two solutions are brought together by ADMM in the learning process. 3.3 Algorithm subroutines In this section, we elaborate on how the consequent subproblems in the above algorithm can be efficiently solved. 3.3.1 Proximal step For the proximal step, we optimize in the continuous space. Formally, we need to find the weights that minimize ρ Lρ (W, Gk , λk ) = f (W ) + kW − Gk + λk k2 2 (11) Due to the decouple of ADMM, we are dealing with an unconstrained objective here. The loss can be interpreted as a normal neural network with a special regularization. Naturally, this problem can be solved with standard gradient decent method. It is easy to obtain the gradient with respect to the weights W : ∂W L = ∂W f + ρ(W − Gk + λk ) 7 However, we find the vanilla gradient descent method converges slowly in this problem. Since the second quadratic term occupies a large proportion of the whole lost, SGD will quickly pull the optimizer to the currently quantized weights so that the second term vanishes, and stack in that point. This results in a suboptimal solution since the loss of neural network is not sufficiently optimized. To overcome this challenge, we resort to the extragradient method [23]. An iteration of the extragradient method consists of two very simple steps, prediction and correction: W (p) := W − βp ∂W L(W ), W (c) := W − βc ∂W L(W (p) ) where βp and βc are the learning rates. A distinguished feature of the extragradient method is the use of an additional gradient step which can be seen as a guide during the optimization process. Particularly, this additional iteration allows to foresee the geometry of the problem and take the curvature information into account, which leads to a better convergency than standard gradient descent [24]. Specific to our problem, there is a more intuitive understanding of the above iterations. For the prediction step, the algorithm will quickly move to a point close to Gk − λk so that the loss of quadratic regularization vanishes. Then in the correction step, the algorithm moves another step which tries to minimize the loss of neural network f (W ). These two steps avoid the algorithm stacking into a less valuable local minima. In practice, we find this extragradient method largely accelerate the convergence of the algorithm. A key observation of (??) is that while minimizing over G, all the components Gi are decoupled, therefore the auxiliary variables of each layer can be optimized independently. Recall that Wi , Gi , λi , Ci denote the weights, auxiliary variables, Lagrangian multipliers and constraints of the i-th layer respectively. We are essentially looking for the Euclidean projection of (Wik+1 + λki ) onto a discrete set Ci . Since the constraint is discrete and nonconvex, this optimization is nontrivial. For convenience, we denote (Wik+1 + λki ) as Vi . The projection of Vi onto Ci can be formulated as min kVi − Gi k2 s.t. Gi ∈ {0, ±αi , ±2αi , · · · , ±2N αi }di Gi ,αi (12) Taking the scaling factor away from the constraints, the objective can be equivalently formulated as: min kVi − αi · Qi k2 s.t. Qi ∈ {0, ±1, ±2, · · · , ±2N }di Qi ,αi (13) We propose an iterative quantization method to solve this problem. The algorithm alternates between optimizing αi with Qi fixed and optimizing Qi with αi fixed. In specific, 8 with Qi fixed, the problem becomes an univariate optimization. The optimal αi can be easily obtained as V T Qi αi = iT (14) Qi Qi With αi fixed, the optimal Qi is actually the projection of namely,   Vi Qi = Π{0,±1,±2,··· ,±2N } αi Vi αi onto {0, ±1, ±2, · · · , ±2N }, (15) where Π denotes the projection operator. Moreover, the projection onto a discrete set is simply the closest point in it. This iterative quantization algorithm is guaranteed to converge to a local minimum since we can get a decrease of loss in each step. In practice, we also find such a simple algorithm converges very fast. In most cases, we only need less than five iterations to get a stable solution. 3.3.2 Dual update In ADMM, dual update is actually gradient ascent in the dual space [15]. The iterate λk+1 in Eq.(10) can be interpreted as a scaled dual variable, or as the running sum of the error values W k+1 − Gk+1 . 4 Experiments In order to verify the effectiveness of the proposed algorithm, in this section we evaluate it on two benchmarks: ImageNet for image classification and Pascal VOC for object detection. 4.1 Image Classification To evaluate the performance of our proposed method on image recognition task, we perform extensive experiments on the large scale benchmark ImageNet (ILSVRC2012), which is one of the most challenging image classification benchmarks. ImageNet dataset has about 1.2 million training images and 50 thousand validation images, and these images cover 1000 object classes. We comprehensively evaluate our method on almost all well-known deep CNN architectures, including AlexNet [25], VGG-16 [26], ResNet-18 [27], ResNet-50 [27] and GoogleNet [28]. 4.1.1 Experimental setup In the ImageNet experiments, all the images are resized to 256 × 256. The images are then randomly clipped to 224 × 224 patches with mean subtraction and randomly flipping. No other data augmentation tricks are used in the learning process. We report both the 9 AlexNet VGG-16 Accuracy Top-1 Top-5 Top-1 Top-5 Binary 0.570 0.797 0.689 0.887 BWN 0.568 0.794 0.678 0.881 Ternary 0.582 0.806 0.700 0.896 TWN 0.575 0.798 0.691 0.890 {-2, +2} 0.592 0.818 0.717 0.907 {-4, +4} 0.600 0.822 0.722 0.909 Full Precision 0.600 0.824 0.711 0.899 Table 1: Accuracy of AlexNet and VGG-16 on ImageNet classification. Resnet-18 Resnet-50 Accuracy Top-1 Top-5 Top-1 Top-5 Binary 0.648 0.862 0.687 0.886 BWN 0.608 0.830 0.639 0.851 Ternary 0.670 0.875 0.725 0.907 TWN 0.618 0.842 0.656 0.865 {-2, +2} 0.675 0.879 0.739 0.915 {-4, +4} 0.680 0.883 0.740 0.916 Full Precision 0.691 0.890 0.753 0.922 Table 2: Accuracy of ResNet-18 and ResNet-50 on ImageNet classification. top-1 and top-5 classification accurate rates on the validation set, using single-view testing (single-crop on central patch only). We study different kinds of bit width for weight quantization. Specifically, we tried binary quantization, ternary quantization, one-bit shift quantization and two-bits shift quantization. For one-bit shift quantization, the weights are restricted to be {-2a, -a, 0, +a, +2a}, which we denote as {-2, +2} in the comparison. Similarly, two-bits shift quantization are denoted as {-4, +4}. Binary quantization and ternary quantization need one bit and two bits to represent one weight respectively. Both {-2, +2} quantization and {-4, +4} quantization need three bits to represent one weight. For binary and ternary quantization, we compare the proposed algorithm with the stateof-the-art approaches Binary Weight Network (BWN) [16] and Ternary Weight Network (TWN) [17]. Both BWN1 and TWN2 release their source code so we can evaluate their performance on different network architectures. Our method is implemented with Caffe [29]. The referenced full precision CNN models VGG-16, ResNet-50 and GoogleNet are taken from the Caffe model zoo3 . 4.1.2 Results on AlexNet and VGG-16 AlexNet and VGG-16 are “old fashion” CNN architectures. AlexNet consists of 5 convolutional layers and 3 fully-connected layers. VGG-16 uses much wider and deeper structure than AlexNet, with 13 convolutional layers and 3 fully-connected layers. Table 1 demonstrates the comparison results on these two networks. For fair comparison with BWN, we 1 https://github.com/allenai/XNOR-Net https://github.com/fengfu-chris/caffe-twns 3 https://github.com/BVLC/caffe/wiki/Model-Zoo 2 10 Accuracy Top-1 Top-5 Binary 0.603 0.832 BWN 0.590 0.824 Ternary 0.631 0.854 TWN 0.612 0.841 {-2, +2} 0.659 0.873 {-4, +4} 0.663 0.875 Full Precision 0.687 0.889 Table 3: Accuracy of GoogleNet on ImageNet classification. report the performance of the batch normalization [30] version of AlexNet. The accuracy of the improved AlexNet is higher than the original one (Top-1 60.0% vs. 57.4%, Top-5 82.4% vs. 80.4%). On these two architectures, the proposed algorithm achieves a lossless compression with only 3 bits compared with the full precision references. For {-2, +2} and {-4, +4} quantization, the performance of the our quantized networks is even better than the original full precision network on VGG-16. Similar results are observed in BinaryConnect on small datasets. This is because discrete weights could provide a form of regularization which can help to generalize better. These results also imply the heavy redundancy of the parameters in full precision AlexNet and VGG-16 models. This finding is consistent with that in other studies such as SqueezeNet [31]. In SqueezeNet, the authors suggest that one can achieve AlexNet-level accuracy on ImageNet with 50x fewer parameters. Our binary quantization and ternary quantization slightly outperforms BWN and TWN on these two architectures. Comparing the accuracy of ternary quantization and binary quantization, we find that ternary network consistently works better than binary network. We also emphasize that the ternary network is more computing efficient than binary network because of the existence of many zero entries in the weights, as indicated in [32]. 4.1.3 Results on ResNet The results on ResNet-18 are shown in Table 2. ResNet-18 has 18 convolutional layers with shortcut connections. For the proposed method, both the binary and ternary quantization substantially outperform their competitors on this architecture. For example, our binary network outperforms BWN by 4 points in top-1 accuracy and 3.2 points in top5 accuracy. The proposed ternary quantization outperforms TWN by 5.2 points and 3.3 points in top-1 and top-5 accuracy respectively. All these gaps are significant on ImageNet. We also observe over two percent improvement for our ternary quantization over binary quantization. The effectiveness of our method is also verified on very deep convolutional network such as ResNet-50. Besides significantly increased network depth, ResNet-50 has a more complex network architecture than ResNet-18. Table 2 details the results on ResNet-50. It is easy to observe the similar trends as in ResNet-18. Our method is considerably better than the compared BWN and TWN. For example, our binary quantization obtains about 5 points improvement on top-1 accuracy over BWN. For both ResNet-18 and ResNet-50, there is a more noticeable gap between the low 11 bits quantized networks and full precision reference. Different from AlexNet and VGG-16, on ResNet we notice about 1 point gap in top-1 accuracy between {-4, +4} quantized network and full precision reference. These results suggest that training extremely low bits quantized network is easier for AlexNet and VGG than for ResNet, which also implies the parameters in AlexNet and VGG-16 are more redundant than those in ResNet-18 and ResNet-50. 4.1.4 Results on GoogleNet The results on GoogleNet are illustrated in Table 3. GoogleNet is a 22 layers deep network, organized in the form of the “Inception module”. Similar to ResNet, GoogleNet is more compact than AlexNet and VGG-16, so it will be more difficult to compress it. There exists a gap of more than 2 points in top-1 accuracy between {-4, +4} quantized network and full precision version. The loss of binary quantization is more significant, which reaches 8 points in top-1 accuracy. Despite this, our method stills outperforms BWN4 and TWN on this network. 4.1.5 Compare with the most recent works To our knowledge, Trained Ternary Quantization (TTN) [33] and Incremental Network Quantization (INQ) [34] are two of the most recent published works on low bits quantization of deep neural network. Instead of quantizing the ternary weights to be {−α, 0, +α}, TTN makes it less restrictive as {−α, 0, +β}. Note that our method can be easily extended to deal with constraints of such form. Nevertheless, the computation of such form of ternary network is less efficient than the original one. As an example, for fast implementation the inner product between vector x and vector (−α, −α, 0, +β) will be decomposed as βx · (0, 0, 0, 1) − αx · (1, 1, 0, 0), having to do two floating-point multiplications with α and β. Since TTN only reports its results on AlexNet and ResNet-18, we compare the performance on these two architectures. Detailed results are summarized in Table 4 and Table 5. Our approach performs better than TTN on AlexNet (the results of ternary INQ on AlexNet is not available), and better than both TTN and INQ on ResNet-18. INQ shows more results on 5-bits networks in the paper. For example, the reported top-1 and top-5 accuracy of ResNet-50 with 5-bits are 73.2% and 91.2% [34]. In contrast, our method achieves such accuracy with only 3 bits. 4.1.6 INT8 quantized 1×1 kernel We notice the extremely low bits quantization of GoogleNet suffers a large degradation. We guess this may be due to the 1×1 kernel in each inception. In order to verify this 4 Note that the GoogleNet used in BWN paper is an improved variant of the original version used in this paper. 12 Method TTN [33] Ours (Ternary) Top-1 accuracy 0.575 0.582 Top-5 accuracy 0.797 0.806 Table 4: Comparison with TTN on AlexNet. Method TTN [33] INQ [34] Ours (Ternary) Top-1 accuracy 0.666 0.660 0.670 Top-5 accuracy 0.872 0.871 0.875 Table 5: Comparison with TTN and INQ on ResNet-18. point, we perform another experiment on GoogleNet. In this version, the 1×1 kernels in the network are quantized with relatively more bits, i.e., INT8, and kernels of other size are quantized as usual. Table 6 shows the results. By comparing the results in Table 6 and those in Table 3, we observe a considerable improvement, especially for binary and ternary quantization. As we have discussed, discrete weights can be interpret as a strong regularizer to the network. However, the parameters in 1×1 kernel is much less than those in other kernels. Imposing a very strong regularizer to such kernels may lead to underfitting of the network. These results suggest that we should quantize different parts of the networks with different bit width in practice. Letting the algorithm automatically determine the bit width will be our future work. 4.2 Object Detection In order to evaluate the proposed method on object detection task, we apply it to the state of arts detection framework SSD [35]. The models are trained on Pascal VOC2007 and VOC2012 train dataset, and tested on Pascal VOC 2007 test dataset. For SSD, we adopt the open implementation released by the authors5 . In all experiments, we follow the same setting as in [35] and the input images are resized to 300 × 300. The proposed method are evaluated on two base models, i.e., VGG-16 and Darknet reference model. Both base networks are pre-trained on ImageNet dataset. The VGG-16 network here is a variant of original one [26]. In detail, the fc6 and fc7 are converted to convolutional layers with 1 × 1 kernel, and the fc8 layer is removed. The parameters of fc6 and fc7 are also subsampled. The darknet reference model is borrowed from YOLO [36], which is another fast detection framework. Darknet is designed to be small yet power, which attains comparable accuracy performance as AlexNet but only with about 10% of the parameters. We utilize the base darknet model downloaded from the website6 . 5 6 https://github.com/weiliu89/caffe/tree/ssd https://pjreddie.com/darknet/imagenet/ 13 Acc. Top-1 Top-5 Binary 0.654 0.867 Ternary 0.667 0.877 {-2, +2} 0.674 0.883 {-4, +4} 0.676 0.883 Full 0.687 0.889 Table 6: Accuracy of GoogleNet. 1×1 kernels are quantized with INT8. mAP Ternary {-4, +4} Full Precision Darknet+SSD 0.609 (0.621) 0.624 (0.639) 0.642 VGG16+SSD 0.762 0.776 0.778 Table 7: mAP of VGG16+SSD and Darknet+SSD on Pascal VOC 2007 To the best of our knowledge, there is no other works on low bits quantization applied their algorithms to the object detection tasks. We compare our quantized network with full precision network in this experiment. We only implement ternary and {-4,+4} quantization for this experiment. Darknet has utilized many 1×1 kernels as in GoogleNet to accelerate the inference process. We implement two versions of Darknet. In the first version, the 1×1 kernels are also quantized as usual, while in the second version these kernels are quantized with INT8. Table 7 shows the mean average precision (mAP) on both models. For {-4,+4} quantization, we find that the mAP of both modes are very close to the full precision version. On VGG16+SSD, we only suffer a loss of 0.002 in mAP. Comparing two versions of Darknet+SSD, the first version achieves a mAP of 0.624, and the second version obtains a improvement of 1.5 points. For ternary quantization, the accuracy degradation of Darknet+SSD is larger than VGG16+SSD, because the parameters of Darknet is less redundant than VGG-16. All these results indicate that our proposed method is also effective on the object detection tasks. 5 Conclusion This work focused on compression and acceleration of deep neural networks with extremely low bits weight. Inspired by the efficient heuristics proposed to solve mixed integer programs, we proposed to learn low bits quantized neural network in the framework of ADMM. We decoupled the continuous parameters from the discrete constraints of network, and cast the original hard problem into several subproblems. We proposed to solve these subproblems using extragradient and iterative quantization algorithms that lead to considerably faster convergency compared to conventional optimization methods. Extensive experiments on convolutional neural network for image recognition and object detection have shown the effectiveness of the proposed method. 14 References [1] M. Denil, B. Shakibi, L. Dinh, N. de Freitas et al., “Predicting parameters in deep learning,” in Advances in Neural Information Processing Systems, 2013, pp. 2148–2156. [2] X. Zhang, J. Zou, K. He, and J. Sun, “Accelerating very deep convolutional networks for classification and detection,” IEEE transactions on pattern analysis and machine intelligence, 2016. [3] E. L. Denton, W. Zaremba, J. Bruna, Y. LeCun, and R. Fergus, “Exploiting linear structure within convolutional networks for efficient evaluation,” Advances in Neural Information Processing Systems, 2014. [4] V. Lebedev, Y. Ganin, M. Rakhuba, I. Oseledets, and V. Lempitsky, “Speeding-up convolutional neural networks using fine-tuned cp-decomposition,” arXiv preprint arXiv:1412.6553, 2014. [5] Y. Gong, L. Liu, M. Yang, and L. Bourdev, “Compressing deep convolutional networks using vector quantization,” arXiv preprint arXiv:1412.6115, 2014. [6] J. Wu, C. Leng, Y. Wang, Q. Hu, and J. Cheng, “Quantized convolutional neural networks for mobile devices,” Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2016. [7] S. Han, H. Mao, and W. J. Dally, “Deep compression: Compressing deep neural networks with pruning, trained quantization and huffman coding,” arXiv preprint arXiv:1510.00149, 2015. [8] Z. Lin, M. Courbariaux, R. Memisevic, and Y. Bengio, “Neural networks with few multiplications,” arXiv preprint arXiv:1510.03009, 2015. [9] T. Dettmers, “8-bit approximations for parallelism in deep learning,” arXiv preprint arXiv:1511.04561, 2015. [10] M. Courbariaux, Y. Bengio, and J.-P. David, “Low precision arithmetic for deep learning,” arXiv preprint arXiv:1412.7024, 2014. [11] D. D. Lin, S. S. Talathi, and V. S. Annapureddy, “Fixed point quantization of deep convolutional networks,” arXiv preprint arXiv:1511.06393, 2015. [12] M. Courbariaux, Y. Bengio, and J.-P. David, “Binaryconnect: Training deep neural networks with binary weights during propagations,” Advances in Neural Information Processing Systems, 2015. [13] I. Hubara, D. Soudry, and R. E. Yaniv, “Binarized neural networks,” arXiv preprint arXiv:1602.02505, 2016. [14] Z. Cheng, D. Soudry, Z. Mao, and Z. Lan, “Training binary multilayer neural networks for image classification using expectation backpropagation,” arXiv preprint arXiv:1503.03562, 2015. [15] S. Boyd, N. Parikh, E. Chu, B. Peleato, and J. Eckstein, “Distributed optimization and statistical learning via the alternating direction method of multipliers,” Foundations and Trends R in Machine Learning, vol. 3, no. 1, pp. 1–122, 2011. [16] M. Rastegari, V. Ordonez, J. Redmon, and A. Farhadi, “Xnor-net: Imagenet classification using binary convolutional neural networks,” European Conference on Computer Vision, 2016. [17] F. Li, B. Zhang, and B. Liu, “Ternary weight networks,” arXiv preprint arXiv:1605.04711, 2016. [18] R. Takapoui, N. Moehle, S. Boyd, and A. Bemporad, “A simple effective heuristic for embedded mixed-integer quadratic programming,” International Journal of Control, pp. 1–11, 2017. [19] E. Fiesler, A. Choudry, and H. J. Caulfield, “Weight discretization paradigm for optical neural networks,” in The Hague’90, 12-16 April. International Society for Optics and Photonics, 1990, pp. 164–173. [20] M. Marchesi, G. Orlandi, F. Piazza, and A. Uncini, “Fast neural networks without multipliers,” IEEE transactions on Neural Networks, vol. 4, no. 1, pp. 53–62, 1993. 15 [21] A. Alavian and M. C. Rotkowitz, “Improving admm-based optimization of mixed integer objectives,” in Information Sciences and Systems (CISS), 2017 51st Annual Conference on. IEEE, 2017, pp. 1–6. [22] Z. Cai, X. He, J. Sun, and N. Vasconcelos, “Deep learning with low precision by half-wave gaussian quantization,” arXiv preprint arXiv:1702.00953, 2017. [23] G. M. Korpelevich, “An extragradient method for finding saddle points and for other problems,” Matecon, 1976. [24] A. Nemirovski, “Prox-method with rate of convergence o(1/t) for variational inequalities with lipschitz continuous monotone operators and smooth convex-concave saddle point problems,” SIAM Journal on Optimization, 2004. [25] A. Krizhevsky, I. Sutskever, and G. E. Hinton, “Imagenet classification with deep convolutional neural networks,” Advances in neural information processing systems, 2012. [26] K. Simonyan and A. Zisserman, “Very deep convolutional networks for large-scale image recognition,” arXiv preprint arXiv:1409.1556, 2014. [27] K. He, X. Zhang, S. Ren, and J. Sun, “Deep residual learning for image recognition,” Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2016. [28] C. Szegedy, W. Liu, Y. Jia, P. Sermanet, S. Reed, D. Anguelov, D. Erhan, V. Vanhoucke, and A. Rabinovich, “Going deeper with convolutions,” Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2015. [29] Y. Jia, E. Shelhamer, J. Donahue, S. Karayev, J. Long, R. Girshick, S. Guadarrama, and T. Darrell, “Caffe: Convolutional architecture for fast feature embedding,” arXiv preprint arXiv:1408.5093, 2014. [30] S. Ioffe and C. Szegedy, “Batch normalization: Accelerating deep network training by reducing internal covariate shift,” arXiv preprint arXiv:1502.03167, 2015. [31] F. N. Iandola, S. Han, M. W. Moskewicz, K. Ashraf, W. J. Dally, and K. Keutzer, “Squeezenet: Alexnet-level accuracy with 50x fewer parameters and¡ 0.5 mb model size,” arXiv preprint arXiv:1602.07360, 2016. [32] G. Venkatesh, E. Nurvitadhi, and D. Marr, “Accelerating deep convolutional networks using lowprecision and sparsity,” in Acoustics, Speech and Signal Processing (ICASSP), 2017 IEEE International Conference on. IEEE, 2017, pp. 2861–2865. [33] C. Zhu, S. Han, H. Mao, and W. J. Dally, “Trained ternary quantization,” International Conference on Learning Representations, 2017. [34] A. Zhou, A. Yao, Y. Guo, L. Xu, and Y. Chen, “Incremental network quantization: Towards lossless cnns with low-precision weights,” International Conference on Learning Representations, 2017. [35] W. Liu, D. Anguelov, D. Erhan, C. Szegedy, S. Reed, C.-Y. Fu, and A. C. Berg, “Ssd: Single shot multibox detector,” European Conference on Computer Vision, 2016. [36] J. Redmon, S. Divvala, R. Girshick, and A. Farhadi, “You only look once: Unified, real-time object detection,” Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, 2016. 16
1cs.CV
arXiv:1611.08461v2 [cs.CV] 17 Jan 2018 Discriminative Correlation Filter Tracker with Channel and Spatial Reliability Alan Lukežič1 , Tomáš Vojı́ř2 , Luka Čehovin Zajc1 , Jiřı́ Matas2 and Matej Kristan1 1 Faculty of Computer and Information Science, University of Ljubljana, Slovenia 2 Faculty of Electrical Engineering, Czech Technical University in Prague, Czech Republic {alan.lukezic, luka.cehovin, matej.kristan}@fri.uni-lj.si {vojirtom, matas}@cmp.felk.cvut.cz Abstract et al, 2013, 2014, 2015, 2016c; Liang et al, 2015; Smeulders et al, 2014; Mueller et al, 2016). Diverse factors – occlusion, illumination change, fast object or camera motion, appearance changes due to rigid or non-rigid deformations and similarity to the background – make shortterm tracking challenging. Recent short-term tracking evaluations (Wu et al, 2013; Kristan et al, 2013, 2014, 2015) consistently confirm the advantages of semi-supervised discriminative tracking approaches (Grabner et al, 2006; Babenko et al, 2011; Hare et al, 2011; Bolme et al, 2010). In particular, trackers based on the discriminative correlation filter (DCF) method (Bolme et al, 2010; Danelljan et al, 2014a; Henriques et al, 2015; Li and Zhu, 2014a; Danelljan et al, 2015a) have shown state-of-the-art performance in all standard benchmarks. Discriminative correlation methods learn a filter with a pre-defined response on the training image. The latter is obtained by slightly extending the region around the target to include background samples. The standard formulation of DCF uses circular correlation which allows to implement learning efficiently by Fast Fourier transform (FFT). However, the FFT requires the filter and the search region size to be equal which limits the detection range. Due to the circularity, the filter is trained on many examples that contain unrealistic, wrapped-around circularly-shifted versions of the target. A naive approach to the reduction of the windowing problems is to learn the filter from a larger region. However, due to the large area of the background in the region, the tracking performance of the DCF drops significantly as shown in Figure 2. The windowing problems were recently addressed by Short-term tracking is an open and challenging problem for which discriminative correlation filters (DCF) have shown excellent performance. We introduce the channel and spatial reliability concepts to DCF tracking and provide a learning algorithm for its efficient and seamless integration in the filter update and the tracking process. The spatial reliability map adjusts the filter support to the part of the object suitable for tracking. This both allows to enlarge the search region and improves tracking of non-rectangular objects. Reliability scores reflect channel-wise quality of the learned filters and are used as feature weighting coefficients in localization. Experimentally, with only two simple standard feature sets, HoGs and Colornames, the novel CSR-DCF method – DCF with Channel and Spatial Reliability – achieves state-of-theart results on VOT 2016, VOT 2015 and OTB100. The CSR-DCF runs close to real-time on a CPU. Keywords— Visual tracking, Correlation filters, Channel reliability, Constrained optimization 1 Introduction Short-term, model-free visual object tracking is the problem of continuously localizing a target in a videosequence given a single example of its appearance. It has received significant attention of the computer vision community which is reflected in the number of papers published on the topic and the existence of multiple performance evaluation benchmarks (Wu et al, 2013; Kristan 1 overcomes both the problems of circular shift enabling an arbitrary search (and training) region size and the limitations related to the rectangular shape assumption. An important benefit of a large training region is that background samples from a wider area around the target are obtained to improve the filter discriminative power. The spatial reliability map is estimated using the output of a graph labeling problem solved efficiently in each frame. An efficient optimization procedure is applied for learning a correlation filter with the support constrained by the spatial reliability map since the standard closed-form solution cannot be generalized to this case. Figure 2 shows that tracking performance of our spatially constrained correlation filter (denoted as S-DCF) does not degrade with increasing training and search region size as is the case with the standard DCF. In contrast, the performance of S-DCF improves from better treatment of training samples and increased search region size. Experiments show that the novel filter optimization procedure outperforms related approaches for constrained learning in DCFs. Channel reliability is the second novelty the CSRDCF tracker introduces. The reliability is estimated from the properties of the constrained least-squares solution to filter design. The channel reliability scores are used for weighting the per-channel filter responses in localization (Figure 1). The CSR-DCF shows state-of-the-art performance on standard benchmarks – OTB100 (Wu et al, 2015), VOT2015 (Kristan et al, 2015) and VOT2016 (Kristan et al, 2015) while running close to real-time on a single CPU. The spatial and channel reliability formulation is general and can be used in most modern correlation filters, e.g. those using deep features. The remainder of the paper is structured as follows. In Section 2 we review most closely related work, our approach is described in Section 3, experimental results are presented in Section 4 and conclusions are drawn in Section 5. Learning - Update stage: Spa Channel weights tial m ap Tra inin g Sp atia pa tch ly c filteonstr rs aine d Localization stage: Channel weights Fin al r esp ons e = Tes t Fil ter res p on pat ch se s Figure 1: Overview of the CSR-DCF approach. An automatically estimated spatial reliability map restricts the correlation filter to the parts suitable for tracking (top) improving localization within a larger search region and performance for irregularly shaped objects. Channel reliability weights calculated in the constrained optimization step of the correlation filter learning reduce the noise of the weight-averaged filter response (bottom). Kiani Galoogahi et al (2015) who propose zero-padding the filter during learning and by Danelljan et al (2015a) who introduce spatial regularization to penalize filter values outside the target boundaries. Both approaches train from image regions much larger than the target and thus increase the detection range. Another limitation of the published DCF methods is the assumption that the target shape is well approximated by an axis-aligned rectangle. For irregularly shaped objects or those with a hollow center, the filter eventually learns the background, which may lead to drift and failure. The same problem appears for approximately rectangular objects in the case of occlusion. The Kiani Galoogahi et al (2015) and Danelljan et al (2015a) methods both suffer from this problem. In this paper we introduce the CSR-DCF, the Discriminative Correlation Filter with Channel and Spatial Reliability. The spatial reliability map adapts the filter support to the part of the object suitable for tracking which 2 Related work The discriminative correlation filters for object detection date back to the 80’s with seminal work of Hester and Casasent (1980). They have been popularized only recently in the tracking community, starting with the Bolme et al (2010) MOSSE tracker. Using a gray-scale tem2 4 3 2 0.5 1 Expected average overlap 0.4 get segmentation probability map. Danelljan et al (2016) addressed a multiple-resolution feature map issue in correlation filters by formulating filter learning in continuous space, while Qi et al (2016) proposed a mechanism to combine correlation responses from multiple convolutional layers. A correlation filter tracker which is able to handle drifts in longer sequences was proposed by Wang et al (2016). It clusters similar target appearances together and uses the clusters for target localization instead of a single online learned filter. Since most of the correlation filter trackers represent the target with a single filter, it can easily get corrupted when occlusion or a target deformation happen. In general, part-based trackers are better in addressing these issues. Therefore several part-based correlation filter methods were proposed. Liu et al (2015) use an efficient method to combine correlation outputs of multiple parts and Liu et al (2016) proposed a tracking method for modeling the target structure with multiple parts using multiple correlation filters. Lukežič et al (2017) treat the parts correlation filter responses and their constellation constraints jointly as an equivalent spring system. They derive a highly efficient optimization to infer the most probable target deformation. Recently, Kiani Galoogahi et al (2015) addressed the problem that occurs due to learning with circular correlation from small training regions. They proposed a learning framework that artificially increases the filter size by implicitly zero padding the filter. This reduces the boundary artifacts by increasing the number of training examples in constrained filter learning. Danelljan et al (2015a) reformulate the learning cost function to penalize nonzero filter values outside the object bounding box. Performance better than (Kiani Galoogahi et al, 2015) is reported, but the learned filter is still a trade-off between the correlation response and regularization, and it does not guarantee that filter values are zero outside of object bounding box. S-DCF DCF 0.3 0.2 0.1 0 0 0.5 1 2 3 4 Target template padding factor Figure 2: Tracking performance measured by the Expected Average Overlap (EAO) of the standard DCF and our spatially constrained DCF (S-DCF) as a function of search region size, expressed as the multiple of the target size (right, x-axis). The filter is learned from a training region equal in size to the search region. The search region sizes are visualized by black-white dashed rectangles (left image) and the target bounding box is shown in yellow. plate, MOSSE achieved state-of-the-art performance on a tracking benchmark (Wu et al, 2013) at a remarkable processing speed. Significant improvements have been made since and in 2014 the top-performing trackers on a recent benchmark (Kristan et al, 2014) were all from this class of trackers. DCF improvements fall into two categories, introduction of new features and conceptual improvements in filter learning. In the first group, Henriques et al (2015) replaced the grayscale templates by HoG (Dalal and Triggs, 2005), Danelljan et al (2014b) proposed multi-dimensional color attributes and Li and Zhu (2014b) applied feature combination. Recently, convolutional network features learned for object detection have been applied (Ma et al, 2015; Danelljan et al, 2015b, 2016), leading to a performance boost, but at a cost of significant speed reduction. Conceptually, the first successful theoretical extension of the standard DCF was the kernelized formulation by Henriques et al (2015) which achieved remarkable tracking performance, but still preserved high speed. Later, a correlation filter based scale adaptation was proposed by Danelljan et al (2014a) introduced a scale-space pyramid learned within a correlation filter framework. Zhang et al (2014) introduced spatio-temporal context learning in the DCFs. To improve localization with correlation filters, Bertinetto et al (2016a) proposed a tracking method that combines the output of the correlation filter with the tar- 3 Spatially constrained correlation filters The use of multiple channels in correlation filters (Henriques et al, 2015; Danelljan et al, 2017; Galoogahi et al, 3 Σ= CN Gray d=1 diag(f̂d )ĥd − ĝk2 + λ Nc X 0.1 0.08 0.06 0.04 0.02 0 HoG Gra Colornames y Figure 3: Correlation responses of different feature channels (27 HoG, 10 colornames and one grayscale channel) are summed to obtain the final (single channel) correlation response (middle). Note that maximum values of channel responses may vary by orders of magnitude (right). (2) response, irrespective of its discriminative power. Since features (e.g., HoG, colornames and grayscale template) vary in scale, some channels might suppress the others by an order of magnitude. This is demonstrated in Figure 3 where each HoG channel on its own contributes to the final response very little. To avoid the issue with different scales we consider each channel independently. This means that each filter channel is optimized to fit the desired output separately. The cost function is thus defined as where g is the desired output g ∈ Rcw ×ch , which is typically a 2-D Gaussian function centered at the target location. Efficient tracking performance is achieved by expressing the cost (2) into the Fourier domain Nc X Final response Max response values HoG d=1 ε(h) = k Per-channel correlation responses 0.12 The symbol ? represents circular correlation between fd ∈ Rcw ×ch and hd ∈ Rcw ×ch , where cw and ch are the training/search region width and height, respectively. The optimal correlation filter h is estimated by minimizing ε(h) = kg̃(h) − gk2 + λkhk2 , 0.14 Channel responses 2013) has become very popular in visual tracking. In the following we present the main ideas behind learning these filters. Given a set of Nc channel features f = {fd }d=1:Nc and corresponding target templates (filters) h = {hd }d=1:Nc , the object position is estimated as the location of the maximum of correlation response g̃(h), Nc X g̃(h) = fd ? hd . (1) kĥk2 , (3) d=1 where the operator â = vec(F[a]) is a Fourier transform of a reshaped into a column vector, i.e., â ∈ RD×1 , with Nc X D = cw · ch , diag(â) being a D × D diagonal matrix kfd ? hd − gk2 + λkhd k2 . (5) ε(h) = formed from â and (·) is the complex-conjugate operator. d=1 The closed-form solution for d-th filter channel ĥd which minimizes the cost function (3) is equal to Additionally, we introduce channel weights w = {w̃d }d=1:Nc which can be considered as scaling factors   X  Nc based on the discriminative power of each feature chan−1 ĥd = diag(f̂d )ĝ diag(f̂d )f̂ d + λ , (4) nel. These weights are called channel reliability weights d=1 in the rest of the paper and they are applied when correla−1 where is element-wise division. The solution (4) tion response is calculated in the target localization stage: considers all feature channels jointly and is used in most Nc X of the recent correlation filter trackers. Note that the fig̃ = fd ? hd · w̃d . (6) nal response is obtained as summation over correlation d=1 responses of all channels (1) and the location of the maximum in the final response represents the new position of We present our method for constrained correlation filter the target. learning in Section 3.1. The most reliable parts of the filNote that a filter for the d-th channel is computed in (4) ter are identified by introducing the spatial reliability map by dividing d-th feature with the sum over all feature (Section 3.2). The method for channel reliability wd estichannels. This means that the feature scale crucially im- mation is presented in Section 3.3, the proposed tracker is pacts the level by which a channel contributes to the final described in Section 3.4. 4 3.1 Constrained correlation filter learning A standard scheme for updating the constraint penalty µ values (Boyd et al, 2011) is applied, i.e., µi+1 = βµi . Since filter learning is independent across the channels Computations of (12,11) are fully carried out in the frein our formulation (5), we assume only a single channel quency domain, the solution for (13) requires a single inin the following derivation (i.e., Nc = 1) and drop the verse FFT and another FFT to compute the ĥi+1 . A single channel index for clarity. optimization iteration thus requires only two calls of the Let m ∈ {0, 1} be a spatial reliability map with elFourier transform, resulting in a very fast optimization. ements either zero or one, that identifies pixels which The computational complexity is that of the Fourier transshould be set to zero in the learned filter. The constraint form, i.e., O(D log D). Filter learning is implemented in can be formalized as h ≡ m h, where represents less than five lines of Matlab code and is summarized in the Hadamard (element-wise) product. Such constraint the Algorithm 1. does not lead to a closed-form solution, but an iterative approach akin to Kiani Galoogahi et al (2015) can be derived Algorithm 1 : Constrained filter optimization. for efficiently solving the optimization problem. In the following we summarize the main steps of our approach Require: Features extracted from training region f , ideal correand report the full derivation in Appendix 6. lation response g, We start by introducing a dual variable hc and the conbinary mask m. straint Ensure: hc − m h ≡ 0, (7) b Optimized filter h. which leads to the following augmented La- Procedure: grangian (Boyd et al, 2011) b 0 by ht−1 . 1: Initialize filter h 2: Initialize Lagrangian coefficients: b l0 ← zeros. λ L(ĥc , h, l̂|m) = kdiag(f̂ )ĥc − ĝk2 + khm k2 + (8) 3: while stop condition do 2 4: Calculate ĥi+1 from ĥi and l̂i using (12). c [l̂H (ĥc − ĥm ) + l̂H (ĥc − ĥm )] + µkĥc − ĥm k2 , i+1 and l̂i using (13). 5: Calculate h from ĥi+1 c and 6: Update the Lagrangian l̂i+1 from ĥi+1 where l̂ is a complex Lagrange multiplier, µ > 0, and c i+1 h (11). we use the definition hm = (m h) for compact no7: end while tation. The augmented Lagrangian (8) can be iteratively minimized by the alternating direction method of multipliers, e.g. Boyd et al (2011), which sequentially solves the following sub-problems at each iteration: 3.2 ĥi+1 = arg min L(ĥc , hi , l̂i |m), c (9) Once the target is localized, a training region is extracted and used to update the filter. Our constrained filter learning (13) requires estimation of spatial reliability map m (i.e., segmentation) that identifies pixels in the training region which likely belong to the target (see Figure 4). In the following we briefly outline the segmentation model which is used to estimate m. During tracking, the object foreground/background color models are maintained as color histograms c = {cf , cb }. Let yi = [yic , yix ] be the observation, i.e., the color yic and position yix at i-th pixel in the training region and let mi ∈ {0, 1} be a random variable denoting the unknown foreground/background label. The joint hc i+1 h = i arg min L(ĥi+1 c , h, l̂ |m), h (10) and the Lagrange multiplier is updated as l̂i+1 = l̂i + µ(ĥi+1 − ĥi+1 ). c (11) Minimizations in (9,10) have at each iteration a closedform solution, i.e.,   ĥi+1 = f̂ ĝ + (µĥim − l̂i ) −1 f̂ f̂ + µi , (12) c hi+1 = m   λ  F −1 l̂i + µi ĥi+1 / + µi . c 2D Constructing spatial reliability map (13) 5 Training region Spatial prior Backprojection Posterior Overlayed training region Figure 4: Spatial reliability map construction from the training region. From left to right: a training region with the target bounding box, t the foreground-background color models, the posterior object probability after Markov random field regularization, and the training region masked with the final binary reliability map. The probabilities are color-coded in a blue (0.0) – green (0.5) – yellow (1.0) colormap. probability of observing yi is defined as 1 X 3.2.1 Inference In practice the likelihood p(yi |mi ) is noisy and requires (14) regularization for our filter learning. We thus apply a j=0 MRF from (Diplaros et al, 2007; Kristan et al, 2016a), 1 X which treats the prior and posterior label distributions p(yic |mi = j)p(yix |mi = j)p(mi = j), over pixels as random variables and applies a MRF con= j=0 straint over these. This formulation affords an efficient c where p(yi |mi = j), p(yix |mi = j) and p(mi = j) are inference which avoids hard label assignment during opthe appearance likelihood, the spatial likelihood and the timization and can be implemented as a series of convoforeground/background prior probability. The appearance lutions. The prior over the i-th pixel is defined compactly likelihood term p(yic |mi = j) is computed by Bayes rule from the object foreground/background color models cf as πi = [πi0 , πi1 ] with πij = p(mi = j) and and cb . The prior probability p(mi = j) is defined by the a standard approximation is made (Diplaros et al, ratio between the region sizes for foreground/background 2007) that decomposes the joint pdf over priors π = [π1 , ..., πM ] into a product of local conditional distrihistogram extraction. QM The central pixels in axis-aligned approximations of an butions p(π) = i=1 p(πi |πNi ), where M is number elongated rotating, articulated or deformable object are of pixels, πNi is a mixture distributionPover the priors likely to contain the object regardless of the specific de- of i-th pixel’s neighbors, i.e., πNi = P j∈Ni ,j6=i λij πj formation. On the other hand, in the absence of measure- and λij are fixed weights satisfying j λij = 1. In ments, pixels away from the center belong to the object or Diplaros et al (2007) the weights are fixed to a norbackground equally likely. This deformation invariance malized Gaussian and are shared across all pixel loof central elements reliability is enforced in our approach cations. The potentials in the MRF are defined as by defining a weak spatial prior p(πi |πNi ) ∝ exp − 12 E(πi , πNi ) ,with exponent defined as E(πi , πNi ) = D(πi ||πNi ) + H(πi ).The p(yix |mi = j) = k(x; σ), (15) term D(πi ||πNi ) is the Kullback-Leibler divergence where k(x; σ) is a modified Epanechnikov kernel, which penalizes the difference between prior distribuk(r; σ) = 1 − (r/σ)2 , with size parameter σ equal to the tions over the neighboring pixels (πi and πNi ), while minor bounding box axis and clipped to interval [0.5, 0.9] thePterm H(πi ) is the entropy defined as H(πi ) = 1 such that the object prior probability at center is 0.9 and − j=0 πij log πij ,which penalizes uninformative priors changes to a uniform prior away from the center (Fig- πi . ure 4). For smooth solutions Diplaros et al (2007) propose usp(yi ) = p(yi |mi = j)p(mi = j) = 6 Filter response Training image ing a similar constraint over the posteriors pi = [pi0 , pi1 ] with pij being the posterior probability of class j at i-th pixel, leading to the following energy function M  X   1 F = log p(yi ) − E(πi , πNi ) + E(pi , pNi ) . 2 i=1 (16) Minimization of the energy (16) w.r.t. π and p is efficiently solved by the solver from Diplaros et al (2007). The final mask m for learning the filter in Section 3.1 is obtained by thresholding the posterior at 0.5. Max: 0.58 m Channel #20 Feature channel Channel #17 Spatial reliability map Max: 0.17 Discriminative case Non-discriminative case Figure 5: A filter is learned on feature channels from a training region using the constrained optimization with a 3.3 Channel reliability estimation binary segmentation mask m. Correlation responses beChannel reliability w̃d in (6) reflects the importance of tween the learned filter and the training region for two each channel at the target localization stage. In our ap- feature channels are shown on the right. On a discrimiproach it consists of two types of reliability measures: native feature channel the filter response is much stronger (lrn) (i) channel learning reliability w̃d , which is calculated and less noisy than on a non-discriminative channel. in the filter learning stage, and (ii) channel detection reli(det) ability w̃d which is calculated in the target localization Channel detection reliability. The second part of stage. The joint channel reliability w̃d in (6) at target lothe channel reliability reflects how uniquely each chancalization stage is computed as the product of both relianel votes for a single target location. Note that Bolme bility measures, i.e., et al (2010) proposed a similar approach to detect loss (lrn) (det) w̃d = w̃d · w̃d (17) of target. Our measure is based on the ratio between the second and first highest non-adjacent peaks in the chanP max2 /ρmax1 . The two largest and normalized s.t. d w̃d = 1. The reliability measures nel response map, i.e., 1 − ρd d peaks in the response map are obtained as two largest valare described in following paragraphs. Channel learning reliability. Constrained minimiza- ues after a 3×3 non-maximum suppression. Note that this tion of (8) solves a least squares problem averaged over all ratio penalizes situations in which multiple similar objects circular displacements of the filter on a feature channel. appear in the target vicinity (i.e., response map contains A discriminative feature channel fd produces a filter hd many well expressed modes), even if the major mode acwhose output fd ∗ hd nearly exactly fits the ideal response curately depicts the target position. To mitigate such peg. On the other hand, since the response is highly noisy on nalizations, the final values are note allowed to fall below channels with low discriminative power, a global error re- 0.5. The detection reliability of d-th channel is estimated duction in the least squares significantly reduces the max- as (det) imal response. This effect is demonstrated in Figure 5, w̃d = max(1 − ρmax2 /ρmax1 , 0.5). (19) d d which shows correlation responses for a highly discriminative and non-discriminative channels. Thus a straight(lrn) forward measure of channel learning reliability w̃d is 3.4 Tracking with channel and spatial reliability the maximum response value of a learned channel filter, which is computed as A single tracking iteration of the proposed channel and (lrn) w̃d = max(fd ∗ hd ). (18) spatial reliability correlation filter tracker (CSR-DCF) is summarized in Algorithm 2 and visualized in Figure 6. The localization and update steps proceed as follows. 7 Update step Localization step Correlation Spatial reliability map estimation Weighted sum Correlation filter channels Reliability weights Filter optimization & weights estimation New target location Figure 6: The CSR-DCF tracking iteration: localization step is shown on the left and update step on the right side of the image. Localization step. Features are extracted from a search region centered at the target estimated position in the previous time-step and correlated with the learned filter ht−1 . The object is localized by summing the correlation responses weighted by the estimated channel reliability scores wt−1 . The scale is estimated by a single scale-space correlation filter as in Danelljan et al (2014a). Per-channel filter responses are used to compute the corresponding detection reliability values w̃(det) = (det) (det) [w̃1 , . . . , w̃Nc ]T according to (19). learning reliability (17). The filters and channel reliability weights are updated by exponential moving average (current and from previous frame) with learning rate η (steps 10 and 11 in the Algorithm 2). Note that we compute the spatial reliability map in each frame independently to capture large target appearance changes, e.g. caused by rotation or deformation. 3.5 Comparison with prior work Kiani Galoogahi et al (2015) and Danelljan et al (2015a) have previously considered constrained filter learning. Here we highlight the differences of our approach. The LBCF tracker (Kiani Galoogahi et al, 2015) addresses the circular boundary effect of the Fourier transform and implicitly increases the filter search region size. In contrast, the CSR-DCF primarily reduces the impact of the background in the filter. The solution of Kiani Galoogahi et al (2015) is similar to our filter optimization, but it is derived for a rectangular mask only. Since rotating and deformable targets are poorly approximated by an axis-aligned bounding box their filter is contaminated by background leading to a reduced performance. The LBCF updates the auto-spectral and cross-spectral ener- Update step. The training region is centered at the target location estimated at localization step. The foreground and background histograms c̃ are extracted and updated by exponential moving average with learning rate ηc (step 5 in Algorithm 2). The foreground histogram is extracted by an Epanechnikov kernel within the estimated object bounding box and the background is extracted from the neighborhood twice the object size. The spatial reliability map m (Sect. 3.2) is constructed and the optimal filters h̃ are computed by optimizing (8). The per-channel learning (lrn) (lrn) reliability weights w̃(lrn) = [w̃1 , . . . , w̃Nc ]T are estimated from the correlation responses (18). Current frame reliability weights w̃ are computed from detection and 8 Algorithm 2 : The CSR-DCF tracking algorithm. Require: Image It , object position on previous frame pt−1 , scale st−1 , filter ht−1 , color histograms ct−1 , channel reliability wt−1 . Ensure: Position pt , scale st and updated models. Localization and scale estimation: 1: New target location pt : position of the maximum in correlation between ht−1 and image patch features f extracted on position pt−1 and weighted by the channel reliability scores w (Sect. 3.3). 2: Using per-channel responses, estimate detection reliability w̃(det) (Sect. 3.3). 3: Using location pt , estimate new scale st . Update: 4: Extract foreground and background histograms c̃f , c̃b . 5: Update foreground and background histograms cft = (1 − ηc )cft−1 + ηc c̃f , cbt = (1 − ηc )cbt−1 + ηc c̃b . to converge. In CSR-DCF the map serves as a hard constraint resulting in a filter with values off the target set to zero. In contrast, the SRDCF (Danelljan et al, 2015a) filter is a compromise between target position regression and a penalty term that prefers potentially non-zero values in the filter center and close-to-zero values away from the center, but does not guarantee zero values outside the mask. 4 Experimental analysis This section presents a comprehensive experimental evaluation of the CSR-DCF tracker. Implementation details are discussed in Section 4.1, convergence of the filter optimization method is presented in Section 4.2, Section 4.3 reports comparison of the proposed constrained learning to the related state-of-the-art and the ablation study is provided in Section 4.4. Tracking performance on three recent benchmarks: OTB-100 (Wu et al, 2015), VOT2015 (Kristan et al, 2015) and VOT2016 (Kristan et al, 2016b) is reported in Sections 4.6, 4.7 and 4.8, respectively. The detailed analysis of the tracker, including per-attribute tracking performance is presented in Section 4.9 and tracking speed analysis in Section 4.10. Estimate reliability map m (Sect. 3.2). Estimate a new filter h̃ using m (Algorithm 1). Estimate learning channel reliability w̃(lrn) from h (Sect. 3.3). 9: Calculate channel reliability w̃ = w̃(lrn) w̃(det) 10: Update filter ht = (1 − η)ht−1 + η h̃. 11: Update channel reliability wt = (1 − η)wt−1 + η w̃. 6: 7: 8: 4.1 Implementation details and parameters A popular implementation Felzenszwalb et al (2010) of the standard HoG (Dalal and Triggs, 2005) and Colorgies (f̂ f̂ and f̂ ĝ in (12)) separately, which approxi- names (van de Weijer et al, 2009) features are used in the mates computation of a single filter from a weighted sum correlation filter and HSV foreground/background color of errors over past training samples. This adaptation is histograms with 16 bins per color channel are used in rereasonable since it is derived for a rectangular mask that liability map estimation with parameter αmin = 0.05. All remains constant throughout tracking. The CSR-DCF es- the parameters are set to values commonly used in literatimates the mask separately for each training sample and ture (Danelljan et al, 2015a; Kiani Galoogahi et al, 2015). learns a corresponding filter. For articulated objects in Histogram adaptation rate is set to ηc = 0.04, correlation particular the mask varies significantly with time, there- filter adaptation rate is set to η = 0.02, and the regufore it is beneficial to compute the exact filter for each larization parameter is set to λ = 0.01. The augmented 0 frame. Robustness is increased by moderately averaging Lagrangian optimization parameters are set to µ = 5 and β = 3. All parameters have a straight-forward interprethe filters temporally. tation, do not require fine-tuning, and were kept constant Similarly to our approach, the SRDCF (Danelljan et al, throughout all experiments. Our Matlab implementation1 2015a) uses a spatial map in filter learning. In contrast 1 The CSR-DCF Matlab source is publicly available on: to our approach, their map does not adapt to the target and is required to be highly smooth for their optimization https://github.com/alanlukezic/csr-dcf 9 runs at 13 frames per second on an Intel Core i7 3.4GHz standard desktop. 4.2 plemented to emphasize the difference in boundary constraints: the first uses our spatial reliability boundary constraint formulation from Section 3 (TSC ) the second applies the spatial regularization constraint (Danelljan et al, 2015a) (TSR ) and the third applies the limited boundaries constraint (Kiani Galoogahi et al, 2015) (TLB ). The three variants were compared on the challenging VOT2015 dataset (Kristan et al, 2015) by applying a standard no-reset one-pass evaluation from OTB (Wu et al, 2013) and computing the AUC on the success plot. The tracker with our constraint formulation TSC achieved 0.32 AUC, while the alternatives achieved 0.28 (TSR ) and 0.16 (TLB ). The only difference between these tackers is in the constraint formulation, which indicates superiority of the proposed spatial-reliability-based constraints formulation over the recent alternatives (Kiani Galoogahi et al, 2015; Danelljan et al, 2015a). Convergence of constrained learning The constrained filter learning described in Section 3.1 is an iterative optimization method that minimizes the cost function (8). This experiment demonstrates how the cost changes with the number of iterations during filter optimization. Figure 7 shows the average squared difference between the result of the correlation of the filter constrained by the spatially constrained function and the ideal output. This graph was obtained by averaging 60 examples of initializing a filter on a target (one per VOT2015 sequence) and scaling each to an interval between zero and one. It is clear that the error drops by 80% within the first few iterations. Already after four iterations, the performance improvements become negligible, therefore we set number of iterations to N = 4. 4.3.1 Figure 7: Convergence speed of constrained filter learning from Section 3.1 shown as a relative drop of the initial cost. 4.3 Impact of the boundary constraint formulation This section compares our proposed boundary constraints formulation (Sect. 3) with recent state-of-the-art approaches (Danelljan et al, 2015a; Kiani Galoogahi et al, 2015). In the first experiment, three variants of the standard single-scale HoG-based correlation filter were im- Robustness to non-axis-aligned target initialization The CSR-DCF tracker from Section 3 was compared to the original recent state-of-the-art trackers SRDCF (Danelljan et al, 2015a) and LBCF (Kiani Galoogahi et al, 2015) that apply alternative boundary constraints. For fair comparison, the source code of SRDCF and LBCF was obtained from the authors, all three trackers used only HoG features and tracked on the same single scale. An experiment was designed to evaluate initialization and tracking of non axis-aligned targets, which is the case for most realistic deforming and non-circular objects. Trackers were initialized on frames with non-axis aligned targets and left to track until the sequence end, resulting in a large number of tracking trajectories. The VOT2015 dataset (Kristan et al, 2015) contains non-axis-aligned annotations, which allows automatic identification of tracker initialization frames, i.e., frames in which the ground truth bounding box significantly deviates from an axis-aligned approximation. Frames with overlap (intersection over union of predicted and groundtruth bounding boxes) of the ground truth and the axisaligned approximation lower than 0.5 were identified and filtered to obtain a set of initialization frames at least hundred frames apart. This constraint fits half the typical short-term sequence length (Kristan et al, 2015) and reduces the potential correlation across the initializations 10 Figure 9: Qualitative results for trackers CSR-DCF (red) tracker, SRDCF (blue) and LBCF (green). by the average tracking length (number of frames before the overlap drops to zero) weighted by trajectory lengths. The weighted average tracking lengths in frames, Γfrm , and proportions of full trajectory lengths, Γprp , are shown Figure 8: The number of trajectories with tracking suc- in Table 1. The CSR-DCF by far outperforms SRDCF and cessful up to frame Θfrm (upper left), the success plots LBCF in all measures indicating significant robustness in (upper right) and initialization examples of non-axis- the initialization of challenging targets that deviate from aligned targets (bottom). axis-aligned templates. This improvement is further confirmed by the graph in Figure 8 (top-right) which shows Table 1: Comparison of three most related trackers on the OTB success plots (Wu et al, 2013) calculated on these non-axis-aligned initialization experiment: weighted av- trajectories and summarized by the AUC values, which erage tracking length in frames Γfrm and proportions are equal to the average overlaps (Čehovin et al, 2016). Γprp , and weighted average overlaps using the original Table 1 shows the average overlaps computed on the origand axis-aligned ground truth, Φrot and Φaa , respectively. inal ground truth on VOT2015 (Φrot ) and on ground truth approximated by the axis-aligned bounding box (Φaa ). Again, the CSR-DCF by far outperforms the competing Tracker Γprp Γfrm Φaa Φrot alternatives SRDCF and LBCF. Tracking examples for the 1 0.58 1 221 1 0.31 1 0.24 CSR-DCF SRDCF (ICCV2015) 2 0.31 2 95 2 0.16 2 0.12 three trackers are shown in Figure 9. 3 0.12 3 37 3 0.06 3 0.04 LBCF (CVPR2015) In summary, the results show that the quality of spatial constraints significantly affects the relative tracking performance when a large portion of the training region in the target vicinity is occupied by background. The rela(see Figure 8 (bottom) for examples). tive performance of LBCF (Kiani Galoogahi et al, 2015) Initialization robustness is estimated by counting the is lowest among the three trackers since this tracker treats number of trajectories in which the tracker was still track- all pixels within axis-aligned bounding box equally as taring (overlap with ground truth greater than 0) Θfrm frames get. The SRDCF (Danelljan et al, 2015a) mostly focuses after initialization. The graph in Figure 8 (top-left) shows on the central pixels of the training region and suppresses these values with increasing the threshold Θfrm . The the filter values at the borders, thus outperforming the CSR-DCF graph is consistently above the SRDCF and LBCF (Kiani Galoogahi et al, 2015). The spatial reliaLBCF for all thresholds. The performance is summarized bility map in CSR-DCF most successfully reduces the in11 fluence of background in filter learning resulting in considerable robustness to poor initializations. 4.4 Spatial and channel reliability ablation study An ablation study on VOT2016 was conducted to evaluate the contribution of spatial and channel reliability in CSR-DCF. Results of the VOT primary measure expected average overlap (EAO) and two supplementary measures accuracy and robustness (A,R) are summarized in Table 2. For the details of performance measures and evaluation protocol we refer the reader to the Section 4.7. Performance of the various modifications of CSR-DCF is discussed in the following. Channel reliability weights. Setting the channel reliability weights to uniform values (CSR-DCFc− ) is equivalent to treating all channels as independent and equally important. The performance drop in EAO compared to CSR-DCF is 12%. Spatial reliability map. Replacing the spatial reliability map in CSR-CDF by a constant map with uniform values within the bounding box and zeros elsewhere (CSRDCFsu ), results in a 21% drop in EAO. The other parts of the tracker remained unchanged in this experiment, including the channel reliability. This clearly shows the importance of our segmentation-based spatial reliability map estimation from Section 3.2. Channel and spatial reliability. Making both replacements in the original tracker means that this version (CSR-DCFc− su ) does not use channel reliability weights and it uses uniform spatial reliability map (uniform values within the bounding box and zeros elsewhere). The performance drops by 24% compared to CSR-DCF. Removal of the uniform spatial reliability map from CSR-DCFc− su results in the CSR-DCFc− s− . This version reduces our tracker to a standard DCF with a large receptive field. Since the learned filter captures a significant amount of background, the performance drops by over 50%. ADMM Filter optimization method. To demonstrate the importance of the constrained optimization method we modify the proposed tracker as follows. The filter h is calculated with a naive approach, i.e., a closed-form solution followed by masking with the spatial reliability map m: ĥ = F(F −1 (ĥ) m). For a fair comparison the tracker, Table 2: Ablation study of CSR-DCF. The use of channel reliability is indicated in the Chan. column, the the type of spatial reliability map in the Spat. column. The Opt. column indicates whether the constrained optimization is used. Tracker Chan. Spat. Opt. EAO Rav Aav CSR-DCF x segm. x 1 0.338 1 0.85 1 0.51 CSR-DCFc− – segm. x 2 0.297 2 1.08 2 0.51 CSR-DCFsu x unif. x 3 0.264 3 1.18 3 0.49 0.256 1.33 2 0.51 CSR-DCFc− su – unif. x 0.251 1.47 2 0.51 CSR-DCFc− o− – segm. – – – 0.152 2.85 0.47 CSR-DCFc− s− – denoted as CSR-DCFc− o− , does not use channel reliability weights. The performance drop in EAO compared to CSR-DCFc− is 15%. 4.5 Spatial reliability map quality analysis In this section we evaluate the quality of our spatial reliability map estimation (Section 3.2) from a visual tracking perspective. We compare the CSR-DCF tracker with the version of CSR-DCF that uses ideal spatial reliability map (the tracker is denoted as CSR*-DCF). In the VOT2016 challenge (Kristan et al, 2016b), the ground truth bounding boxes were automatically computed by optimizing coverage over manually segmented targets in each frame. The VOT2016 has recently made their perframe segmentations freely available (Vojir and Matas, 2017). We use these per-frame segmentation masks in CSR*-DCF as spatial reliability map m. Results of evaluation on VOT2016 (Kristan et al, 2016b) are reported in Table 3. The performances of the CSR-DCF and CSR*-DCF are very similar. The trackers achieve an equal expected average overlap (EAO) and average accuracy (Aav ). But the CSR*-DCF has a single failure less than CSR-DCF on 60 sequences which is 0.02 on average. In Table 3 the average number of failures is denoted as robustness (Rav ). These results show that our approach for spatial reliability estimation (Section 3.2) generates near ideal maps from a tracking perspective. Figure 10 qualitatively compares the spatial reliabil- 12 Table 3: Tracking performance comparison of the two versions of CSR-DCF on VOT2016. The proposed method is denoted as CSR-DCF while the version using ground-truth segmentation masks instead of color-based spatial reliability map is denoted as CSR*-DCF. Tracker CSR-DCF CSR*-DCF EAO 0.338 0.338 Aav 0.51 0.51 Rav 0.85 0.83 the maps are different. But from the perspective of tracking they are nearly equivalent since the tracking performance remains unchanged. For example, in the case of a basketball player, the legs are not well segmented by our approach. But since the legs constantly move, they are in fact non-informative for object localization from the perspective of the correlation filter template matching and do not contribute to improved tracking. 4.6 Figure 10: Qualitative comparison of the spatial reliability maps during tracking. The dashed bounding box represents area from which correlation filter is obtained. This is also the area where spatial reliability map is calculated. In addition, the ground-truth segmentation masks are visualized on the right side under each frame. ity maps to the ground-truth segmentation masks on VOT2016 (Kristan et al, 2016b). Note that at pixel level, The OTB100 benchmark (Wu et al, 2015) The OTB100 (Wu et al, 2015) benchmark contains results of 29 trackers evaluated on 100 sequences by a noreset evaluation protocol. Tracking quality is measured by precision and success plots. The success plot shows the fraction of frames with the overlap between th epredicted and ground truth bounding box greater than a threshold with respect to all threshold values. The precision plot shows similar statistics on the center error. The results are summarized by areas under these plots. To reduce clutter, we show here only the results for top-performing recent baselines, i.e., Struck (Hare et al, 2011), TLD (Kalal et al, 2012), CXT (Dinh et al, 2011), ASLA (Xu Jia, 2012), SCM (Wei Zhong, 2012), LSK (Liu et al, 2011), CSK (Henriques et al, 2012) and results for recent topperforming state-of-the-art trackers SRDCF (Danelljan et al, 2015a) and MUSTER (Hong et al, 2015). The CSR-DCF is ranked top on the benchmark (Fig. 11). It significantly outperforms the best performers reported in (Wu et al, 2015) and outperforms the current state-of-the-art SRDCF (Danelljan et al, 2015a) and MUSTER (Hong et al, 2015). The average CSRDCF performance on success plot is slightly lower than SRDCF (Danelljan et al, 2015a) due to poorer scale estimation, but yields better performance in the average precision (center error). Both, precision and success plot, show that the CSR-DCF tracks on average longer than competing methods. 4.7 The VOT2015 benchmark (Kristan et al, 2015) The VOT2015 (Kristan et al, 2015) benchmark contains results of 63 state-of-the-art trackers evaluated on 60 chal13 2@ k s e w q 5! 4& 4$ 4) 3% 3@ 2* 2% ; f y r 5^ 5$ 5) 4^ 4! 3( 3# 3! 2& 2# l 5( 5& 5% 5# 4* 4% 6! 5* ait 6@ 3* 3$ 3) 2^ 2! j g o u 6) 5@ 4( 4# 4@ 3& 3^ 2( 2$ 2) h d 0.8 Success rate 0.8 CSR-DCF [0.733] Precision Success plots 1 0.6 SRDCF [0.725] MUSTER [0.709] Struck [0.599] 0.4 TLD [0.550] SCM [0.540] SRDCF [0.598] 0.6 MUSTER [0.572] Struck [0.463] 0.4 SCM [0.446] TLD [0.427] CXT [0.414] CXT [0.521] 0.2 CSR-DCF [0.587] 0.2 CSK [0.496] ASLA [0.410] ASLA [0.491] LSK [0.386] LSK [0.478] CSK [0.386] 60 50 40 0 0 0 10 20 30 40 Location error threshold 50 0 0.2 0.4 0.6 0.8 1 Frag 3% ACT 5& CT 5* Track 6@ amt g DAT 2( ggt AOG Deep HMM 2# Tracker w SRDCF ; TxD ASMS DFT 2) 4( 4% HT baseline DSST 3@ 3* 5$ IVT 4@ bdf 2& dtracker 4) KCF2 kcf 3$ cmil e EBT 3^ mtsa CMT fct 5^ 4^ 4# kcfdp CSRFoT q DCF 5) 3# kcfv2 Overlap threshold Figure 11: Evaluation on OTB100 (Wu et al, 2015) benchmark. lenging sequences. In contrast to related benchmarks, the VOT2015 dataset was constructed from over 300 sequences by an advanced sequence selection methodology that favors objects difficult to track and maximizes a visual attribute diversity cost function (Kristan et al, 2015). This makes it arguably the most challenging sequence set available. The VOT methodology (Kristan et al, 2016c) resets a tracker upon failure to fully use the dataset. The basic VOT measures are the number of failures during tracking (robustness) and average overlap during the periods of successful tracking (accuracy), while the primary VOT2015 measure is the expected average overlap (EAO) on short-term sequences. The latter can be thought of as the expected no-reset average overlap (AUC in OTB methodology), but with reduced bias and the variance as explained in (Kristan et al, 2015). Figure 12 shows the VOT EAO plots with the CSRDCF and the VOT2015 state-of-the-art approaches considering the VOT2016 rules that do not consider trackers learned on video sequences related to VOT to prevent over-fitting. The CSR-DCF outperforms all trackers and achieves the top rank. The CSR-DCF significantly outperforms the related correlation filter trackers like SRDCF (Danelljan et al, 2015a) as well as trackers that apply computationally-intesive state-of-the-art deep features e.g., deepSRDCF (Danelljan et al, 2015b) and SO-DLT (Wang et al, 2015b). For completeness, detailed results for the ten top-performing trackers are shown in Table 4. Rank 30 20 mkcf 5@ L1APG 2! plus t LDP 3) muster 3& LGT 2% mvcft loft 6) lite 6! ncc LT_FLO 5! i nsamf mat 4& flow 5# OAB l MCT k OACF h MEEM 4$ PKLTF 3( MIL a rajssc 10 1 Rob j Struck s3 s tracker 2* samf 4* SCBT u scebt 4! sKCF 2$ sme f SODLT y sPST 0.4 Expected Average Overlap Precision plots 1 0.3 0.2 0.1 0.0 2^ srat r srdcf 5% STC o struck d sumshift 3! TGPR 2@ tric 5( zhang Figure 12: Expected average overlap (EAO) plot for CSR-DSF (#1) and all trackers participating in the VOT 2015 (Kristan et al, 2015) benchmark listed below the plot in alphabetical order with their numerical codes. Table 4: The ten top-performing trackers on the VOT2015 benchmark. Tracker CSR-DCF DeepSRDCF EBT srdcf LDP sPST scebt nsamf struck rajssc 4.8 EAO 0.320 0.318 3 0.313 0.288 0.278 0.277 0.255 0.254 0.246 0.242 1 2 Aav 0.55 0.56 0.45 3 0.55 0.49 0.54 0.54 0.53 0.46 1 0.57 3 2 Rav 0.93 1.00 1 0.81 1.18 1.30 1.42 1.72 1.45 1.50 1.75 2 3 The VOT2016 benchmark (Kristan et al, 2016b) Finally, we assess our tracker on the most recent visual tracking benchmark, VOT2016 (Kristan et al, 2016b). The dataset contains 60 sequences from VOT2015 (Kris14 70 4& ACT 3$ ANT ART 4( DSST 3# ASMS 6@ BDF 3^ BST 2& CCCT w CCOT 5! CDTT 7) CMT Color 2^ KCF CSRq DCF 60 6* CTF 3@ DAT u DDC deep 2# MKCF Deep g SRDCF 5$ DFST 6! DFT s DNT 2! DPT 4^ DPTG DSST 4$ 2014 i EBT 50 40 Rank k FCF 6) FCT 5* FoT 6& FRT 3) GCF 2) GGTv2 2( HCF HMM 2$ TxD 5% HT 6$ IVT KCF 3* 2014 KCF 3! SMXPC 30 20 4* LGT LoFT 6( Lite 6# LT_FLO 3% MAD Mat 5@ Flow 6% Matrioska MDNet jN 5) MIL t MLDF 4# MWCF 7! ncc 2% NSAMF 0.4 0.3 0.2 0.1 1 0.0 10 3( OEST 5^ PKLTF RFD ; CF2 SAMF 4! 2014 4) SCT4 h SHCT 2@ SiamAN f SiamRN 5# sKCF 5& SMPR 2* SODLT o SRBT Expected Average Overlap 4& 4$3& 3@ 2( 2@ h f rw q 6#6! 5* 5$ 5) 4^ 4@ 3^ 3! 2^ 2! g a t 6( 6% 6) 5& 5# 4( 4% 4) 3# 3) 2$ l 7) 6^ 6@ 5( 5^ 5! 7! 6& k su e 4# 3( 3$ 2* 2% 2) j o y 6* 6$ 5% 5@ 4* 4! 3*3% 2& 2# ; d i l SRDCF r SSAT d SSKCF y Staple a STAPLEp 6^ STC STRUCK 5( 2014 4@ SWCF e TCNN 4% TGPR Tric 3& TRACK performing trackers come from various classes e.g., correlation filter methods: CCOT (Danelljan et al, 2016), Staple (Bertinetto et al, 2016a), DDC (Kristan et al, 2016b), deep convolutional network based: TCNN (Kristan et al, 2016b), SSAT (Kristan et al, 2016b; Nam and Han, 2016), MLDF (Kristan et al, 2016b; Wang et al, 2015a), FastSiamnet (Bertinetto et al, 2016b) and different detection-based approaches: EBT (Zhu et al, 2016) and SRBT (Kristan et al, 2016b). Figure 13 shows the EAO performance on the VOT2016. The CSR-DCF outperforms all 70 trackers with the EAO score equal to 0.338. The CSR-DCF significantly outperforms correlation filter approaches that do not apply deep ConvNets. Even though the CSR-DCF applies only simple features, it outperforms all trackers that apply computationally intensive deep features. Detailed performance scores for the ten top-performing trackers are shown in Table 5. 4.9 Figure 13: Expected average overlap (EAO) plot for CSR-DSF (#1) and all trackers participating in the VOT 2016 (Kristan et al, 2016b) benchmark listed below the plot in alphabetical order with their numerical codes. Table 5: The ten top-performing trackers on the VOT2016 benchmark. Tracker CSR-DCF CCOT TCNN SSAT MLDF Staple DDC EBT SRBT STAPLEp 1 2 3 EAO 0.338 0.331 0.325 0.321 0.311 0.295 0.293 0.291 0.290 0.286 3 1 3 2 Aav 0.51 0.52 0.54 0.57 0.48 0.54 0.53 0.44 0.50 0.55 Rav 0.85 0.85 0.96 1.04 1 0.83 1.35 1.23 3 0.90 1.25 1.32 2 2 tan et al, 2015) with improved annotations. The benchmark evaluated a set of 70 trackers which includes the recently published and yet unpublished state-ofthe-art trackers. The set is indeed diverse, the top- Per-attribute analysis The VOT2016 (Kristan et al, 2016b) dataset is per-frame annotated with visual attributes and allows detailed analysis of per-attribute tracking performance. Figure 14 shows per-attribute plot for ten top-performing trackers on VOT2016 in EAO. The CSR-DCF is consistently ranked among top three trackers on five out of six attributes. In four attributes (size change, occlusion, camera motion, unassigned) the tracker is ranked top. The only attribute on which our CSR-DCF is outperformed by four of the compared trackers (MLDF, CCOT, SSAT and TCNN) is illumination change. All of these trackers use deep CNN features which are much more complex than the features in CSR-DCF and better handle illumination change. 4.10 Tracking speed analysis Tracking speed is an important factor of many real-world tracking problems. Table 6 thus compares several related and well-known trackers (including the best-performing tracker on the VOT2016 challenge) in terms of speed and VOT performance measures. Speed measurements on a single CPU are computed on Intel Core i7 3.4GHz standard desktop. The CSR-DCF performs on par with the VOT2016 best-performing CCOT (Danelljan et al, 2016), which 15 CSR-DCF Staple+ CCOT DDC TCNN EBT SSAT SRBT Table 6: Speed in frames per second (fps) of correlation trackers and Struck – a baseline. The EAO, average accuracy (Aav ) and average failures (Rav ) are shown for reference. Staple MLDF DNT Overall (0.27, 0.34) Unassigned Camera motion (0.10, 0.21) (0.28, 0.37) Motion change Illumination change (0.20, 0.46) (0.20, 0.46) Size change Occlusion (0.25, 0.38) (0.16, 0.29) Tracker EAO Aav 1 0.338 2 0.51 CSR-DCF CCOT ECCV2016 2 0.331 1 0.52 CCOT* ECCV2016 3 0.274 1 0.52 SRDCF ICCV2015 0.247 1 0.52 KCF PAMI2015 0.192 3 0.48 DSST PAMI2016 0.181 3 0.48 Struck ICCV2011 0.142 0.42 Figure 14: Expected averaged overlap performance on different visual attributes on the VOT2016 (Kristan et al, 2016b) benchmark. The CSR-DCF and the top 10 performing trackers from VOT2016 are shown. The scales of visual attribute axes are shown below the attribute labels. applies deep ConvNets, with respect to VOT measures, while being 20 times faster than the CCOT. The CCOT was modified by replacing the computationally intensive deep features with the same simple features used in CSRDCF. The resulting tracker, indicated by CCOT*, is still ten times slower than CSR-DCF, while the performance drops by over 15%. The CSR-DCF performs twice as fast as the related SRDCF (Danelljan et al, 2015a), while achieving approximately 25% better tracking results. The speed of baseline real-time trackers like DSST (Danelljan et al, 2014a) and Struck (Hare et al, 2011) is comparable to CSR-DCF, but their tracking performance is significantly poorer. The fastest compared tracker, KCF (Henriques et al, 2015) runs much faster than real-time, but delivers a significantly poorer performance than CSR-DCF. The experiments show that the CSR-DCF tracks comparably to the state-of-the-art trackers which apply computationally demanding high-dimensional features, but runs considerably faster and delivers top tracking performance among the real-time trackers. Rav fps 0.85 3 13.0 0.85 0.6 1.18 1.0 3 1.50 7.3 2.03 1 115.7 2.52 2 18.6 3.37 8.5 1 1 2 The average speed of our tracker measured on the VOT 2016 dataset is approximately 13 frames-per-second2 or 77 milliseconds per-frame. Figure 15 shows the processing time required by each step of the CSR-DCF. A tracking iteration is divided into two steps: (i) target localization and (ii) the visual model update. Target localization takes in average 35 milliseconds at each frame and is composed of two sub-steps: estimation of object translation (23ms) and scale change estimation (12ms). The visual model update step takes on average 42 milliseconds. It consists of three sub-steps: spatial reliability map estimation (16ms), filter update (12ms) and scale model update (14ms). Filter optimization, which is part of the filter update step, takes on average 7 milliseconds. 4.11 Qualitative evaluation Figure 16 shows four examples of tracking with the CSRDCF. In the following we describe tracking performance on each sequence. The first example shows tracking of an octopus along with channel reliability weights. The first eighteen weights correspond to HoG channels, the 19th weight is reliability of a grayscale template and the last ten weights correspond to colornames. Note that the colors in boxes are not the actual colors of the colornames, because these features are subspace of original colornames, designed to 2 With some basic code optimization and refactoring we speed-up our algorithm to 19 FPS without significant performance drop (only one additional failure on VOT2016 dataset). 16 Localization Scale estimation 12ms Reliability map 16ms Translation 23ms Scale update 14ms Update Filter update 12ms Figure 15: A single iteration processing time decomposed across the main steps of the CSR-DCF. improve correlation filter tracking (see (Danelljan et al, 2014b)). Observe that when the octopus changes shape significantly, some channels become more discriminative than the others – this is particularly evident in the first eighteen channels that represent the HoG features. Tracking a gymnast is shown in the second example. The target is deforming and rotating over the sequence significantly, while our tracker is able to successfully track it. Additionally, the correlation response from the localization step is shown for each frame. The peak in the response is well expressed, which means that the filter accurately represents the target and that the discriminative channels overrule the less discriminative ones by our channel reliability estimation approach. The third example shows tracking a sprinter. The spatial reliability map is visualized next to each frame. In the bottom-right corner of each frame the tracking patch is overlaid with the spatial reliability map. The reliability maps fit the target well and prevent the filter from learning the background. The last example shows tracking under occlusion, i.e., a motorcyclist driving on the road while being repeatedly occluded by the trees. This example demonstrates that our tracker is robust to short-term full occlusions and that it is able to recover and localize the target despite the full occlusion. This is possible due to the robust learning with channel and spatial reliability map and the large capture range that our learning scheme provides. 5 Conclusion The Discriminative Correlation Filter with Channel and Spatial Reliability (CSR-DCF) was introduced. The spatial reliability map adapts the filter support to the part of the object suitable for tracking which overcomes both the problems of circular shift enabling an arbitrary search region size and the limitations related to the rectangular shape assumption. A novel efficient spatial reliability map estimation method was proposed and an efficient optimization procedure was used for learning a correlation filter with the support constrained by the estimated map. The second novelty of CSR-DCF is the channel reliability. The reliability is estimated from the properties of the constrained least-squares solution. The channel reliability scores were used for weighting the per-channel filter responses in localization. Experimental comparison with recent related state-ofthe-art boundary-constraints formulations showed significant benefits of using our formulation. The CSR-DCF achieves state-of-the-art performance on standard benchmarks: OTB100 (Wu et al, 2015), VOT2015 (Kristan et al, 2015) and VOT2016 (Kristan et al, 2016b) while running close to the real-time on a single CPU. Despite using simple features like HoG and Colornames, the CSR-DCF performs on par with trackers that apply computationally complex deep ConvNet, but is significantly faster. To the best of our knowledge, the proposed approach is the first of its kind to introduce constrained filter learning with arbitrary spatial reliability map and the use of channel reliabilities. The spatial and channel reliability formulation is general and can be used in most modern correlation filters, e.g. those using deep features. 6 Appendix 1: Derivation of the augmented Lagrangian minimizer This section provides a complete derivation of the relations (12, 13) in the Section 3.1. The augmented La17 grangian from Equation (8) is The partial complex gradients are: λ khm k2 + 2 L(ĥc , h, l̂) = kdiag(f̂ )ĥc − ĝk2 + (20) [l̂H (ĥc − ĥm ) + l̂H (ĥc − ĥm )] + µkĥc − ĥm k2 , = λ L(ĥc , h, l̂) = kdiag(f̂ )ĥc − ĝk2 + khm k2 + (21) 2   √ √ l̂H (ĥc − DFMh) + l̂H (ĥc − DFMh) + √ µkĥc − DFMhk2 , = diag(f̂ )H diag(f̂ )ĥc − diag(f̂ )ĝ, ∇ĥ L2 = 0, where F denotes D × D orthonormal matrix of Fourier coefficients, such √ that the Fourier transform is defined as x̂ = F(x) = DFx and M = diag(m). For clearer representation we denote the four terms in the summation (21) as (32) c (22) = where T    L1 = diag(f̂ )ĥc − ĝ diag(f̂ )ĥc − ĝ , (31) ∇ĥ L1 = c  T   diag(f̂ )ĥc − ĝ diag(f̂ )ĥc − ĝ = ∂ ĥc  ∂ = ĥTc diag(f̂ )H diag(f̂ )ĥc − ĥTc diag(f̂ )H ĝ− ∂ ĥc  ĝH diag(f̂ )ĥc + ĝH ĝ = with hm = (m h). For the purposes of derivation we will rewrite (20) into a fully vectorized form L(ĥc , h, l̂) = L1 + L2 + L3 + L4 ,  ∂  = ∂  ∂ ĥc  ∂ l̂H H  (33) ∇ĥ L3 = c    √ √ H ĥc − DFMh + l̂ ĥc − DFMh = l̂ ĥc − l̂ H √ T DFMh + l̂ ĥc − l̂ T √  DFMh = ∂ ĥc (23) = l̂, L2 = L3 = l̂H (ĥc − √ λ khm k2 , 2 (24) DFMh) + l̂H (ĥc − L4 = µkĥc − √ √ DFMh), (25) DFMhk2 . (26) Minimization of Equation (8) in Section 3.1 is an iterative process at which the following minimizations are required: ĥopt = arg min L(ĥc , h, l̂), c (27) hopt = arg min L(ĥopt c , h, l̂). (28) hc h Minimization w.r.t. to ĥc is derived by finding ĥc at which the complex gradient of the augmented Lagrangian vanishes, i.e., ∇ĥ L ≡ 0, (34) ∇ĥ L4 = c    T   √ √ ∂ = µ ĥc − DFMh ĥc − DFMh = ∂ ĥc   √ ∂ H DFMh− = µ ĥH c ĥc − ĥc ∂ ĥc  √ T Dh MFH ĥc + DhT MFH FMh = √ = µĥc − µ DFMh. √ Note that DFMh = ĥm according to our original definition of ĥm . Plugging (31-34) into (30) yields (29) c ∇ĥ L1 + ∇ĥ L2 + ∇ĥ L3 + ∇ĥ L4 ≡ 0. c c c diag(f̂ )H diag(f̂ )ĥc − diag(f̂ )ĝ + l̂ + µĥc − µĥm = 0, (35) ĥc = (30) c 18 diag(f̂ )ĝ + µĥm − l̂ diag(f̂ )H diag(f̂ ) + µ , which can be rewritten into Plugging (39-43) into (38) yields Next we derive the closed-form solution of (28). The optimal h is obtained when the complex gradient w.r.t. h vanishes, i.e., √ √ λ Mh − DMFH l̂ − µ DMFH ĥc + µDMh = 0, 2 (44) √ DFH (l̂ + µĥc ) Mh = M . λ 2 + µD ∇h L ≡ 0 (37) Using the definition of the inverse Fourier transform, i.e., F −1 (x̂) = √1D FH x̂, (44) can be rewritten into ∇h L1 + ∇h L2 + ∇h L3 + ∇h L4 ≡ 0. (38) ĥc = ĝ + µĥm − l̂ f̂ f̂ . (36) f̂ + µ m The partial gradients are h=m F −1 (l̂ + µĥc ) . λ 2D + µ (45) (39) The values in m are either zero or one. Elements in h that correspond to the zeros in m can in principle not be recovered from (45) since this would result in division by ∇h L 2 = (40) zero. But our initial definition of the problem was to seek     T ∂ λ ∂ λ H solutions for the filter that satisfies the following relation = (Mh) (Mh) = h MMh . h ≡ h m. This means the values corresponding to zeros ∂h 2 ∂h 2 in m should be zero in h. Thus the proximal solution Since we defined mask m as a binary mask, the product to (45) is MM can be simplified into M and the result for ∇h L2 is F −1 (l̂ + µĥc ) λ h=m . (46) λ (41) ∇h L2 = Mh. 2D + µ 2 ∇h L1 = 0, The remaining gradients are as follows: ∇h L 3 = (42)       √ √ ∂ H H l̂ ĥc − DFMh + l̂ ĥc − DFMh = = ∂h   √ √ ∂ H = l̂ ĥc − l̂H DFMh + l̂T ĥc − l̂T DFMh = ∂h √ = − DMFH l̂, Acknownledgements This work was supported in part by the following research programs and projects: Slovenian research agency research programs and projects P2-0214 and L2-6765. Jiři Matas and Tomáš Vojı́r̃ were supported by The Czech Science Foundation Project GACR P103/12/G084 and Toyota Motor Europe. We would also like to thank dr. Rok Žitko for discussion on complex differentiation. ∇h L 4 = (43) References       T √ √ ∂ = µ ĥc − DFMh ĥc − DFMh = Babenko B, Yang MH, Belongie S (2011) Robust object ∂h   tracking with online multiple instance learning. IEEE √ ∂ H Trans Pattern Anal Mach Intell 33(8):1619–1632 = µ ĥH ĥ − ĥ DFMh− c c c ∂h   Bertinetto L, Valmadre J, Golodetz S, Miksik O, Torr PHS √ H Dh MFH ĥc + DhH Mh = (2016a) Staple: Complementary learners for real-time √ tracking. In: Comp. Vis. Patt. Recognition, pp 1401– = −µ DMFH ĥc + µDMh. 1409 19 Bertinetto L, Valmadre J, Henriques JF, Vedaldi A, Torr PH (2016b) Fully-convolutional siamese networks for object tracking. arXiv preprint arXiv:160609549 Bolme DS, Beveridge JR, Draper BA, Lui YM (2010) Visual object tracking using adaptive correlation filters. In: Comp. Vis. Patt. Recognition, IEEE, pp 2544–2550 Boyd S, Parikh N, Chu E, Peleato B, Eckstein J (2011) Distributed optimization and statistical learning via the alternating direction method of multipliers. Foundations and Trends in Machine Learning 3(1):1–122 Čehovin L, Leonardis A, Kristan M (2016) Visual object tracking performance measures revisited. IEEE Trans Image Proc 25(3):1261–1274 Dalal N, Triggs B (2005) Histograms of oriented gradients for human detection. In: Comp. Vis. Patt. Recognition, vol 1, pp 886–893 Danelljan M, Häger G, Khan FS, Felsberg M (2014a) Accurate scale estimation for robust visual tracking. In: Proc. British Machine Vision Conference, pp 1–11 Danelljan M, Khan FS, Felsberg M, van de Weijer J (2014b) Adaptive color attributes for real-time visual tracking. In: 2014 IEEE Conference on Computer Vision and Pattern Recognition, CVPR 2014, Columbus, OH, USA, June 23-28, 2014, pp 1090–1097 Danelljan M, Hager G, Shahbaz Khan F, Felsberg M (2015a) Learning spatially regularized correlation filters for visual tracking. In: Int. Conf. Computer Vision, pp 4310–4318 Danelljan M, Häger G, Khan FS, Felsberg M (2015b) Convolutional features for correlation filter based visual tracking. In: IEEE International Conference on Computer Vision Workshop (ICCVW), pp 621–629 Danelljan M, Robinson A, Khan FS, Felsberg M (2016) Beyond correlation filters: learning continuous convolution operators for visual tracking. In: Proc. European Conf. Computer Vision, Springer, pp 472–488 Danelljan M, Häger G, Khan FS, Felsberg M (2017) Discriminative scale space tracking. IEEE Trans Pattern Anal Mach Intell 39(8):1561–1575 Dinh TB, Vo N, Medioni G (2011) Context tracker: Exploring supporters and distracters in unconstrained environments. In: Comp. Vis. Patt. Recognition, pp 1177–1184 Diplaros A, Vlassis N, Gevers T (2007) A spatially constrained generative model and an em algorithm for image segmentation. IEEE Trans Neural Networks 18(3):798 – 808 Felzenszwalb P, Girshick R, McAllester D, Ramanan D (2010) Object detection with discriminatively trained part-based models. IEEE Trans Pattern Anal Mach Intell 32(9):1627–1645 Galoogahi HK, Sim T, Lucey S (2013) Multi-channel correlation filters. In: Int. Conf. Computer Vision, pp 3072–3079 Grabner H, Grabner M, Bischof H (2006) Real-time tracking via on-line boosting. In: Proc. British Machine Vision Conference, vol 1, pp 47–56 Hare S, Saffari A, Torr PHS (2011) Struck: Structured output tracking with kernels. In: Int. Conf. Computer Vision, IEEE Computer Society, Washington, DC, USA, pp 263–270 Henriques JF, Caseiro R, Martins P, Batista J (2012) Exploiting the circulant structure of tracking-by-detection with kernels. In: Fitzgibbon A, Lazebnik S, Perona P, Sato Y, Schmid C (eds) Proc. European Conf. Computer Vision, Springer Berlin Heidelberg, Berlin, Heidelberg, pp 702–715 Henriques JF, Caseiro R, Martins P, Batista J (2015) Highspeed tracking with kernelized correlation filters. IEEE Trans Pattern Anal Mach Intell 37(3):583–596 Hester CF, Casasent D (1980) Multivariant technique for multiclass pattern recognition. Applied Optics 19(11):1758–1761 Hong Z, Chen Z, Wang C, Mei X, Prokhorov D, Tao D (2015) Multi-store tracker (muster): A cognitive psychology inspired approach to object tracking. In: Comp. Vis. Patt. Recognition, pp 749–758 20 Kalal Z, Mikolajczyk K, Matas J (2012) Trackinglearning-detection. IEEE Trans Pattern Anal Mach Intell 34(7):1409–1422 Liang P, Blasch E, Ling H (2015) Encoding color information for visual tracking: Algorithms and benchmark. IEEE Trans Image Proc 24(12):5630–5644 Kiani Galoogahi H, Sim T, Lucey S (2015) Correlation filters with limited boundaries. In: Comp. Vis. Patt. Recognition, pp 4630–4638 Liu B, Huang J, Yang L, Kulikowsk C (2011) Robust tracking using local sparse appearance model and kselection. In: Comp. Vis. Patt. Recognition, pp 1313– 1320 Kristan M, Pflugfelder R, Leonardis A, Matas J, Porikli F, Čehovin L, Nebehay G, Fernandez G, Vojir Tea (2013) The visual object tracking vot2013 challenge results. In: Vis. Obj. Track. Challenge VOT2013, In conjunction with ICCV2013, pp 98–111 Liu S, Zhang T, Cao X, Xu C (2016) Structural correlation filter for robust visual tracking. In: Comp. Vis. Patt. Recognition, pp 4312–4320 Kristan M, Pflugfelder R, Leonardis A, Matas J, Čehovin Liu T, Wang G, Yang Q (2015) Real-time part-based visual tracking via adaptive correlation filters. In: Comp. L, Nebehay G, Vojir T, et al Fernandez G (2014) The viVis. Patt. Recognition, pp 4902–4912 sual object tracking vot2014 challenge results. In: Proc. European Conf. Computer Vision, pp 191–217 Lukežič A, Č Zajc L, Kristan M (2017) Deformable parts correlation filters for robust visual tracking. IEEE Kristan M, Matas J, Leonardis A, Felsberg M, Čehovin Transactions on Cybernetics PP(99):1–13 L, Fernandez G, Vojir T, Häger G, Nebehay G, et al Pflugfelder R (2015) The visual object tracking vot2015 challenge results. In: Int. Conf. Computer Vi- Ma C, Huang JB, Yang X, Yang MH (2015) Hierarchical convolutional features for visual tracking. In: Int. Conf. sion Computer Vision, pp 3074–3082 Kristan M, Kenk VS, Kovačič S, Perš J (2016a) Fast image-based obstacle detection from unmanned surface Mueller M, Smith N, Ghanem B (2016) A benchmark and vehicles. IEEE Transactions on Cybernetics 46(3):641– simulator for uav tracking. In: Proc. European Conf. 654 Computer Vision Kristan M, Leonardis A, Matas J, Felsberg M, Pflugfelder Nam H, Han B (2016) Learning multi-domain convoluR, Čehovin L, Vojir T, Häger G, Lukežič A, et al Fertional neural networks for visual tracking. In: Comp. nandez G (2016b) The visual object tracking vot2016 Vis. Patt. Recognition, pp 4293–4302 challenge results. In: Proc. European Conf. Computer Vision Qi Y, Zhang S, Qin L, Yao H, Huang Q, Lim J, Yang MH (2016) Hedged deep tracking. In: CVPR, pp 4303– Kristan M, Matas J, Leonardis A, Vojir T, Pflugfelder 4311 R, Fernandez G, Nebehay G, Porikli F, Cehovin L (2016c) A novel performance evaluation methodolSmeulders A, Chu D, Cucchiara R, Calderara S, Deogy for single-target trackers. IEEE Trans Pattern Anal hghan A, Shah M (2014) Visual tracking: An experMach Intell imental survey. IEEE Trans Pattern Anal Mach Intell 36(7):1442–1468 Li Y, Zhu J (2014a) A scale adaptive kernel correlation filter tracker with feature integration. In: Proc. European Vojir T, Matas J (2017) Pixel-wise object segmentaConf. Computer Vision, pp 254–265 tions for the VOT 2016 dataset. Research Report Li Y, Zhu J (2014b) A scale adaptive kernel correlation filCTU–CMP–2017–01, Center for Machine Perception, ter tracker with feature integration. In: Proc. European K13133 FEE Czech Technical University, Prague, Conf. Computer Vision, pp 254–265 Czech Republic 21 Wang L, Ouyang W, Wang X, Lu H (2015a) Visual tracking with fully convolutional networks. In: Int. Conf. Computer Vision, pp 3119–3127 Wang N, Li S, Gupta A, Yeung D (2015b) Transferring rich feature hierarchies for robust visual tracking. CoRR abs/1501.04587 Wang S, Zhang S, Liu W, Metaxas DN (2016) Visual tracking with reliable memories. In: Proceedings of the Twenty-Fifth International Joint Conference on Artificial Intelligence, pp 3491–3497 Wei Zhong MHY Huchuan Lu (2012) Robust object tracking via sparsity-based collaborative model. In: Comp. Vis. Patt. Recognition, pp 1838–1845 van de Weijer J, Schmid C, Verbeek J, Larlus D (2009) Learning color names for real-world applications. IEEE Trans Image Proc 18(7):1512–1523 Wu Y, Lim J, Yang MH (2013) Online object tracking: A benchmark. In: Comp. Vis. Patt. Recognition, pp 2411– 2418 Wu Y, Lim J, Yang MH (2015) Object tracking benchmark. IEEE Trans Pattern Anal Mach Intell 37(9):1834–1848 Xu Jia MHY Huchuan Lu (2012) Visual tracking via adaptive structural local sparse appearance model. In: Comp. Vis. Patt. Recognition, pp 1822–1829 Zhang K, Zhang L, Liu Q, Zhang D, Yang MH (2014) Fast visual tracking via dense spatio-temporal context learning. In: Proc. European Conf. Computer Vision, Springer International Publishing, pp 127–141 Zhu G, Porikli F, Li H (2016) Beyond local search: Tracking objects everywhere with instance-specific proposals. In: The IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp 943–951 22 Figure 16: Qualitative results of tracking with the CSR-DCF on four video sequences. 23
1cs.CV
Fast Distributed Approximation for TAP and 2-Edge-Connectivity Keren Censor-Hillel∗ Michal Dory∗ arXiv:1711.03359v1 [cs.DS] 9 Nov 2017 November 10, 2017 Abstract The tree augmentation problem (TAP) is a fundamental network design problem, in which the input is a graph G and a spanning tree T for it, and the goal is to augment T with a minimum set of edges Aug from G, such that T ∪ Aug is 2-edge-connected. TAP has been widely studied in the sequential setting. The best known approximation ratio of 2 for the weighted case dates back to the work of Frederickson and JáJá, SICOMP 1981. Recently, a 3/2-approximation was given for the unweighted case by Kortsarz and Nutov, TALG 2016, and recent breakthroughs by Adjiashvili, SODA 2017, and by Fiorini et al., 2017, give approximations better than 2 for bounded weights. In this paper, we provide the first fast distributed approximations for TAP. We present a distributed 2-approximation for weighted TAP which completes in O(h) rounds, where h is the height of T . When h is large, we √ show a much faster 4-approximation algorithm for the unweighted case, completing in O(D + n log∗ n) rounds, where n is the number of vertices and D is the diameter of G. Immediate consequences of our results are an O(D)-round 2-approximation algorithm for the minimum size 2-edge-connected spanning subgraph, which significantly√improves upon the running time of previous approximation algorithms, and an O(hM ST + n log∗ n)-round 3-approximation algorithm for the weighted case, where hM ST is the height of the MST of the graph. Additional applications are algorithms for verifying 2-edge-connectivity and for augmenting the connectivity of any connected spanning subgraph to 2. Finally, we complement our study with proving lower bounds for distributed approximations of TAP. ∗ Technion, Department of Computer Science, {ckeren,smichald}@cs.technion.ac.il. Supported in part by the Israel Science Foundation (grant 1696/14). 1 Introduction The tree augmentation problem (TAP) is a central problem in network design. In TAP, the input is a 2-edge-connected1 graph G and a spanning tree T of G, and the goal is to augment T to be 2-edge-connected by adding to it a minimum size (or a minimum weight) set of edges from G. Augmenting the connectivity of T makes it resistant to any single link failure, which is crucial for network reliability. TAP is extensively studied in the sequential setting, with several classical 2-approximation algorithms [8, 12, 14, 17], as well as recent advances with the aim of achieving better approximation factors [1, 4, 7, 20]. TAP is part of a wider family of connectivity augmentation problems. Finding a minimum spanning tree (MST) is another prime example for a problem in this family, but, although an MST is a low-cost backbone of the graph, it cannot survive even one link failure. Hence, in order to guarantee stronger reliability, it is vital to find subgraphs with higher connectivity. The motivation for considering TAP is for the case that adding any new edge to the backbone incurs a cost, and hence if we are already given a subgraph with some connectivity guarantee then we would naturally like to augment it with additional edges of minimum number or weight, rather than to compute a well-connected low-cost subgraph from scratch. Connectivity augmentation problems also serve as building blocks in other connectivity problems, such as computing the minimum k-edge-connected subgraph. A natural approach is to start with building a subgraph that satisfies some connectivity guarantee (e.g., a spanning tree), and then augment it to have stronger connectivity. Since the main motivation for TAP is improving the reliability of distributed networks, it is vital to consider TAP also from the distributed perspective. In this paper, we initiate the study of distributed connectivity augmentation and present the first distributed approximation algorithms for TAP. We do so in the CONGEST model [28], in which vertices exchange messages of O(log n) bits in synchronous rounds, where we show fast algorithms for both the unweighted and weighted variants of the problem. In addition to fast approximations for TAP, our algorithms have the crucial implication of providing efficient algorithms for approximating the minimum 2-edge-connected spanning subgraph, as well as several related problems, such as verifying 2-edge-connectivity and augmenting the connectivity of any spanning connected subgraph to 2. Finally, we complement our study with proving lower bounds for distributed approximations of TAP. 1.1 Our Contributions Distributed approximation algorithms for TAP Our first main contribution is the first distributed approximation algorithm for TAP. In particular, our algorithm provides a 2-approximation for weighted TAP in the CONGEST model, summarized as follows. Theorem 1.1. There is a distributed 2-approximation algorithm for weighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . The approximation ratio of our algorithm matches the best approximation ratio for weighted TAP in the sequential setting. Its round complexity of O(h) is tight if h = O(D), where D is the diameter of G. This happens, for example, when T is a BFS tree, and follows from a lower bound of Ω(D) rounds which we show in Section 6. However, the height h of the spanning tree T may be large, even if the diameter of G is small, which raises the question of whether the dependence on h is necessary. We address this question 1 A graph G is 2-edge-connected if it remains connected after the removal of any single edge. 1 √ by providing an algorithm for unweighted TAP that has a round complexity of O(D + n log∗ n) rounds, which is significantly smaller for large values of h. This only comes at the price of a slight increase in the approximation ratio, from 2 to 4. Theorem 1.2. There is a distributed 4-approximation algorithm for unweighted TAP in the CON√ GEST model that runs in O(D + n log∗ n) rounds. Applications The key application of our TAP approximation algorithm is an O(D)-round 2-approximation algorithm for the minimum size 2-edge-connected spanning subgraph problem (2-ECSS), which is obtained by building a BFS tree and augmenting it to a 2-edge-connected subgraph using our algorithm. Theorem 1.3. There is a distributed 2-approximation algorithm for unweighted 2-ECSS in the CONGEST model that completes in O(D) rounds. The time complexity of our algorithm improves significantly upon the time complexity of previous approximation algorithms for 2-ECSS, which are O(n) rounds for a 32 -approximation [21] √ and O(D + n log∗ n) rounds for a 2-approximation [33]. In addition, our weighted TAP algorithm implies a 3-approximation for weighted 2-ECSS. Other applications of our algorithms are an O(D)-round algorithm for verifying 2-edge-connectivity, and an algorithm for augmenting the connectivity of any connected spanning subgraph H of G from 1 to 2. Lower bounds We complement our algorithms by presenting lower bounds for TAP. We first show that approximating TAP is a global problem which requires Ω(D) rounds even in the LOCAL model [24], where the size of messages is not bounded. Theorem 1.4. Any distributed α-approximation algorithm for weighted TAP takes Ω(D) rounds in the LOCAL model, where α ≥ 1 can be any polynomial function of n. This holds also for unweighted TAP, if 1 ≤ α < n−1 2c for a constant c > 1. Theorem 1.4 implies that if h = O(D) then our TAP approximation algorithms have an optimal round complexity. We also consider the case of h = ω(D) and show a family of graphs, based on the construction in [32], for which Ω(h) rounds are needed in order to approximate weighted TAP, √ n were h = Θ( log n ). Theorem 1.5. For any polynomial function α(n), there is a Θ(n) − vertex graph of diameter Θ(log n) for which any (perhaps randomized) distributed α(n)-approximation algorithm for weighted √ n TAP with an instance tree T ⊆ G of height h = Θ( log n ) requires Ω(h) rounds in the CONGEST model. Theorem 1.5 implies that our algorithm for weighted TAP is optimal on these graphs. In particular, there cannot be an algorithm with a complexity of O(f (h)) for a sublinear function f . 2 1.2 Technical overview of our algorithms As an introduction, we start by showing an O(h)-round 2-approximation algorithm for unweighted TAP, which allows us to present some of the key ingredients in our algorithms. Later, we explain how we build on these ideas and extend them to give an algorithm for the weighted case, and a faster algorithm for unweighted TAP. Unweighted TAP A natural approach for constructing a distributed algorithm for unweighted TAP could be to try to simulate the sequential 2-approximation algorithm of Khuller and Thurimella [17]. In their algorithm, the input graph G is first converted into a modified graph G0 . Then, the algorithm finds a directed MST in G0 , which induces a corresponding augmentation in G. When considered in the distributed setting, this approach imposes two difficulties. The first is that we cannot simply modify the input graph, because it is the graph that represents the underlying distributed network, whose topology is given and not under our control. The second is in the directed MST procedure, as finding a directed MST efficiently in the distributed setting seems to be difficult. The currently best known time complexity of this problem is O(n2 ) for an asynchronous setting [13], which is trivial in the CONGEST model. We overcome the above using two key ingredients. First, we bring into our construction the tool of computing lowest common ancestors (LCAs). We show that building G0 and simulating a distributed computation over it can be done by an efficient computation of LCAs, and we achieve the latter by leveraging the labeling scheme for LCAs presented in [2]. Second, we drastically diverge from the Khuller-Thurimella framework by replacing the expensive directed MST construction by a completely different procedure. Roughly speaking, we show that the simple structure of G0 allows us to find an optimal augmentation in G0 efficiently by scanning the input tree T from the leaves to the root and performing the following procedure. Each vertex sends to its parent information about edges that may be useful for the augmentation since they cover many edges of the tree, and the vertices use the LCA labels in order to decide which edges to add to the augmentation. While a direct implementation of this would result in much information that is sent through the tree, we show that at most two edges need to actually be sent by each vertex. Thus, applying the labeling scheme and scanning the tree T result in a time complexity of O(h) rounds, where h is the height of T . Finally, we prove that an optimal augmentation in G0 gives a 2-approximation augmentation for G, which gives a 2-approximation for unweighted TAP in O(h) rounds. Weighted TAP Our algorithm for the unweighted case relies heavily on the fact that we can compare edges and decide which one is the best for the augmentation according to the number of edges they cover in the tree. However, once the edges have weights, it is not clear how to compare edges. This is because of the tension between light edges that cover only few edges and heavier edges that cover many edges. Therefore, Theorem 1.1, which applies for the weighted case, cannot be directly obtained according to the above description. Hence, sending two edges per vertex up in the tree, as we do for the unweighted case, is insufficient. That is, the number of edges that should be considered for the augmentation could be much larger and vertices cannot decide locally which edges are useful without feedback from their ancestors in the tree. Nevertheless, we show how to overcome this by introducing a technique of having each vertex send to its parent edges with altered weights. The trick here is that we modify the weight that is sent for 3 an edge in a way that captures the cost for covering each edge of the tree. This successfully addresses the competing needs of covering as many tree edges as possible, while using the lightest possible edges, and allows focusing on a smaller number of edges that may be useful for the augmentation. Finally, using standard pipelining, this gives a time complexity of O(h) rounds for the weighted case as well. Faster unweighted TAP Both of our aforementioned algorithms rely on scanning the tree T , which results in a time complexity that is linear in the height h of the tree T . In order to avoid the dependence on h, one must be a able to add edges to the augmentation without scanning the whole tree. However, if a vertex v does not get information about the edges added to the augmentation by the vertices in the whole subtree rooted at v, then it may add additional edges in order to cover tree edges that are already covered. But then we are no longer guaranteed to get an optimal augmentation in G0 , or even a good approximation for it. Nevertheless, we are still able to show a faster algorithm for unweighted TAP, which completes in √ O(D + n log∗ n) rounds. The key ingredient in our algorithm is breaking the tree T into fragments and applying our 2-approximation for unweighted TAP algorithm on each fragment separately, as well as on the tree of fragments. Since our algorithm does not scan the whole tree, it may add different edges to cover the same tree edges, which makes the analysis much more involved. The approximation ratio analysis is based on dividing the edges to different types and bounding the number of edges of each type separately, using a subtle case-analysis. Although our algorithm does not find an optimal augmentation in G0 , it gives a 2-approximation for it, which results in a 4-approximation augmentation for the original graph G. 1.3 Related Work Sequential algorithms for TAP TAP is intensively studied in the sequential setting. Since TAP is NP-hard, approximation algorithms for it have been studied. The first 2-approximation algorithm for weighted TAP was given by Frederickson and JáJá [8], and was later simplified by Khuller and Thurimella [17]. Other 2approximation algorithms for weighted TAP are the primal-dual algorithm of Goemans et al. [12], and the iterative rounding algorithm of Jain [14]. Recently, a new algorithm achieved a 1.5-approximation for unweighted TAP [20], and recent breakthroughs give approximations better than 2 for bounded weights [1,7]. Achieving approximation better than 2 for the general weighted case is a central open question. See [16, 19] for surveys about approximation algorithms for connectivity problems. Also, the related work in [1] gives an overview of many recent sequential algorithms for TAP. Related work in the distributed setting While ours are the first distributed approximation algorithms for TAP itself, there are important related studies in the distributed setting. MST: In the distributed setting, finding an MST, which is a minimum weight subgraph with connectivity 1, is a fundamental and well studied problem (see, e.g., [5, 6, 9, 10, 22, 27]). The first distributed algorithm for this problem is the GHS algorithm that works in O(n log n) time [9]. √ Following algorithms improved the round complexity to O(D + n log∗ n) [10, 22]. 4 k-ECSS: For the minimum weight 2-edge-connected spanning subgraph (2-ECSS) problem, there is a distributed algorithm of Krumke et al. [21]. Their approach is finding a specific spanning tree and then augmenting it to a 2-edge-connected graph. In the unweighted case, they augment a DFS tree following the sequential algorithm of Khuller and Vishkin [18], which results in an O(n)-round 32 -approximation algorithm for 2-ECSS. In the weighted case they augment an MST and suggest a general O(n log n)-round 2-approximation algorithm for weighted TAP, which gives an O(n log n)-round 3-approximation algorithm for 2-ECSS. Our algorithms for TAP imply faster approximations for unweighted and weighted 2-ECSS. √ Another distributed algorithm for unweighted k-ECSS is an O(k(D + n log∗ n))-round algorithm of Thurimella [33] that finds a sparse k-edge-connected subgraph. The general framework of the algorithm is to repeatedly find maximal spanning forests in the graph and remove their edges from the graph (this framework is also described in sequential algorithms [16, 25]). This gives a k-edge-connected spanning subgraph with at most k(n − 1) edges. Since any k-edge-connected subgraph has at least kn 2 edges, since the degree of each vertex is at least k, this approach guarantees a 2-approximation for unweighted k-ECSS. Fault-tolerant tree structures: Another related problem is the construction of fault-tolerant tree structures. Distributed algorithms for constructing fault tolerant BFS and MST structures are given in [11], producing sparse subgraphs of the input graph G that contain a BFS (or an MST) of G \ {e} for each edge e, for the purpose of maintaining the functionality of a BFS (or an MST) even when an edge fails. However, TAP is different from these problems in several aspects. First, we augment a specific spanning tree T rather then build the whole structure from scratch. In addition, since we need to preserve only connectivity when an edge fails and not the functionality of a BFS or an MST, optimal solutions for TAP may be much cheaper. Additional related problems: Another connectivity augmentation problem studied in the distributed setting is the Steiner Forest problem [15, 23]. There are also distributed algorithms for finding the 2-edge-connected and 3-edge-connected components of a connected graph [29, 30], and distributed algorithms that decompose a graph with large connectivity into many disjoint trees, while almost preserving the total connectivity through the trees [3]. 1.4 Preliminaries For completeness, we first formally define the notion of edge connectivity. Definition 1.1. An undirected graph G is k-edge-connected if it remains connected after the removal of any k − 1 edges. The Tree Augmentation Problem (TAP). In TAP, the input is an undirected 2-edgeconnected graph G with n vertices, and a spanning tree T of G. The goal is to add to T a minimum size (or a minimum weight) set of edges Aug from G, such that T ∪ Aug is 2-edge-connected. In the weighted version, each edge has a non-negative weight, and we assume that the weights of the edges can be represented in O(log n) bits. Definition 1.2. An edge e in a connected graph G is a bridge in G if G \ {e} is disconnected. Definition 1.3. A non-tree edge e = {u, v} covers the tree edge e0 if e0 is on the unique path in T between u and v, i.e., if e0 is not a bridge in T ∪ {e}. 5 A graph G is 2-edge-connected if and only if it does not contain bridges. Hence, augmenting the connectivity of T requires covering of all the tree edges. Models of distributed computation. In the distributed CONGEST model [28], the network is modeled as an undirected connected graph G = (V, E). Communication takes place in synchronous rounds. In each round, each vertex can send a message of O(log n) bits to each of its neighbors. The time complexity of an algorithm is measured by the number of rounds. Our algorithms work in the CONGEST model, where some of our lower bounds hold also in the stronger LOCAL model [24], where the size of messages is not bounded. In the distributed setting, the input to TAP is a rooted spanning tree T of G with root r, whose height is denoted by h. The tree T is given to the vertices locally, that is, each vertex knows which of its adjacent edges is in T and which of those leads to its parent in T .2 For each vertex v 6= r, we denote by p(v) the parent of v in T . The output is a set of edges Aug, such that T ∪ Aug is 2-edge-connected. In the distributed setting it is enough that at the end of the algorithm each vertex knows which of the edges incident to it are added to Aug. All the messages sent in our algorithms consist of a constant number of ids, labels and weights, hence the maximal message size is bounded by O(log n) bits, as required in the CONGEST model. Roadmap: In Section 2, we describe our O(h)-round 2-approximation algorithm for unweighted TAP, and in Section 3 we extend it to the weighted case. In Section 4, we show applications of these algorithms, in particular for approximating 2-ECSS, and in Section 5 we present our faster algorithm for unweighted TAP. We present lower bounds for TAP in Section 6, and discuss questions for future research in Section 7. Full details and proofs appear in the Appendix. 2 A 2-approximation for Unweighted TAP in O(h) rounds As an introduction, we start by describing an O(h)-round 2-approximation algorithm, AT AP , for unweighted TAP. Here we give a high-level description of AT AP . Full details and proofs appear in Appendix A. The general structure of AT AP is as follows. It starts by building a related virtual graph G0 as in [17]. Afterwards, we diverge completely from the approach of [17] since we cannot simulate it efficiently in the distributed setting, as explained in the introduction. Instead, AT AP finds an optimal augmentation in G0 , and converts it to an augmentation Aug in G. We show that the size of Aug is at most twice the size of an optimal augmentation in G. All the communication in the algorithm is on the edges of the graph G, since G0 is a virtual graph. In order to simulate the algorithm on G we use labels that represent the edges of G0 . Building G0 from G: AT AP starts by building a related undirected virtual graph G0 . To simplify the presentation of the algorithm it is convenient to give an orientation to the edges of G0 . However, we emphasize that G0 is an undirected graph, that is, we do not address the notion of directed connectivity. The graph G0 is defined as follows (as in [17]). The graph G0 includes all the edges of T , and they are all oriented towards the root r of T . For every non-tree edge e = {u, v} in G there are two cases (see Figure 1). If u is an ancestor of v in T , we add the edge {u, v} to G0 , oriented from u to v. Otherwise, denote t = LCA(u, v). In this case we add to G0 the edges {t, u} and {t, v}, oriented from t to u and to v, respectively. 2 If a root and orientation are not given, we can find a root r and orient all the edges towards r in O(h) rounds using standard techniques. 6 Figure 1: There are two cases for every non-tree edge in G. The left graph shows the first case, where the edge {u, v} is between an ancestor and a descendant in T . The right graph shows the second case, where t = LCA(u, v). In order to build the graph G0 in the distributed setting, we use the labeling scheme for LCAs of Alstrup et al. [2]. This labeling scheme assigns labels of size O(log n) bits to the vertices of a rooted tree with n vertices, such that given the labels of u and v it is possible to infer the label of their LCA. The algorithm for computing the labels can be implemented in O(h) rounds in the distributed setting. Since G0 is a virtual graph, the rest of the communication in the algorithm is only over the tree edges. In order to simulate the rest of the algorithm over G0 , it is enough that each vertex knows only the tree edges incident to it (which is its input), and the labels of the non-tree edges incoming to it in G0 . Using the labeling scheme, each vertex learns this information by exchanging labels with all of its neighbors. For more details, see Appendix A.1. The Correspondence between G and G0 : A non-tree edge e = {u, v} in G covers all the edges in the unique path in T between u in v. To build G0 from G, for each non-tree edge e ∈ G, we added one or two corresponding edges to G0 , which together cover exactly the same tree edges as e. This allows us to show that an optimal augmentation in G0 gives a 2-approximation augmentation in G, when we replace each edge of the augmentation in G0 by a corresponding edge in G. For full details and proofs see Appendix A.2. Finding an optimal augmentation in G0 : In the graph G0 , all the edges that are not tree edges are between an ancestor and a descendant of it in T . This allows us to compare edges and define the notion of maximal edges. Intuitively, the notion of maximal edges would capture our goal that during the algorithm, when we cover a tree edge, we would like to cover it by an edge that reaches the highest ancestor possible, allowing us to cover many tree edges simultaneously. This motivates the following definition. Let v be a vertex in the tree, and let e = {u, w} and e0 = {u0 , w0 } be two edges between ancestors u, u0 of v and descendants w, w0 of v. We say that e is the maximal edge among e and e0 if and only if u is an ancestor of u0 . If u = u0 we can choose arbitrarily one of them to be the maximal edge. In order to cover all tree edges of G0 , we assign each vertex v 6= r in G0 with the responsibility of covering the tree edge {v, p(v)}. In our algorithm AAug for finding an optimal augmentation in G0 , the tree T is scanned from the leaves to the root, and whenever a tree edge that is still not covered is reached, it is covered by the vertex responsible for it, using the maximal edge possible. For doing so, it is enough that each vertex v sends to its parent information about at most two edges. One of them is the maximal edge that was already added to the augmentation in order to cover the tree edge {v, p(v)}, and one is the maximal edge possible to cover the tree edge {v, p(v)}. We show that using the LCA labels of edges, vertices can compute easily if a tree edge is covered, and which edge is the maximal edge. The full description of the algorithm AAug is given in Appendix A.3. 7 Correctness proof: Denote by A the solution obtained by AAug , and by A∗ an optimal augmentation in G0 . We show in Appendix A.4 that A is an optimal augmentation in G0 . The key ingredient is to show a one-to-one mapping from A to A∗ . For each edge e ∈ A, we look at the tree edge t(e) = {v, p(v)} where v is the vertex that decides to add e to the augmentation. We map e to an edge e∗ ∈ A∗ that covers t(e). Showing that this mapping is one-to-one is based on the fact that when we add a new edge to the augmentation, it is the maximal edge possible. In addition, we show that the time complexity of the algorithm is O(h) rounds. Since an optimal augmentation in G0 corresponds to a 2-approximation augmentation in G, this gives the following. Theorem 2.1. There is a distributed 2-approximation algorithm for unweighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . 3 A 2-approximation for Weighted TAP in O(h) rounds In this section, we give a high-level description of our algorithm for weighted TAP. Full details and proofs appear in Appendix B. Our algorithm for weighted TAP, AwT AP , has the same structure of AT AP . It starts by building the same virtual graph G0 , and then it finds an optimal augmentation in G0 . The only difference in building G0 is that now each edge e is replaced by one or two edges in G0 with the same weight that e has. The proof that an optimal augmentation in G0 corresponds to an augmentation in G with at most twice the cost of an optimal augmentation in G is the same as in the unweighted case. The difference is in finding an optimal augmentation in G0 . In the unweighted case, for each vertex v, the only edge incoming to v in G0 that was useful for the algorithm was the maximal edge. However, when edges have weights, potentially all the edges incoming to v may be useful for the algorithm, and we can no longer use the notion of maximal edges in order to compare edges. This is because of the tension between heavy edges that cover many edges of the tree, and light edges that cover less edges of the tree. To overcome this obstacle, we introduce a new technique of altering the weights of the edges we send in the algorithm. We next describe how our new approach allows us to find an optimal augmentation in G0 . Finding an Optimal Augmentation in G0 : In the weighted case, it is not clear anymore how to compare edges. A vertex v may have many optional edges that cover {v, p(v)}, where one of them has the minimum weight, but other edges cover more tree edges. In order to cover the tree edge between v and its parent, it is best to add the edge with minimum weight. However, in order to cover additional tree edges, we may want to add one of the other edges. Since v alone does not have enough information to resolve this trade-off, one could have the vertices propagate all the edges up in the tree, but this would accumulate to too much information, which would render the algorithm very slow. Instead, we pinpoint the exact source of the trade-off between length and weight of covering edges, as follows. Let minv be the weight of the minimum weight edge that covers {v, p(v)}. The intuition behind our approach is that in order to cover the tree edge {v, p(v)} we must pay at least minv . Thus, minv captures the cost of covering this tree edge. Therefore, before sending to its parent information about relevant edges, v alters their weights by reducing from them the weight minv . In terms of p(v), the reduced weights represent the extra cost incurred when choosing any of these edges in order to cover additional tree edges. Using the reduced weights in our algorithm instead of the original ones is crucial for selecting which edges to add to the augmentation, and allows to divide the weight of an edge in a way that captures the cost for covering each tree edge. In addition, we show that using this approach, sending information about at most h edges from 8 each vertex to its parent suffices for selecting the best edges for the augmentation. The Algorithm: Our algorithm consists of two traversals of the tree: from the leaves to the root and vice versa. As in AAug , each vertex v is responsible for covering the tree edge {v, p(v)}. In the first traversal, each vertex v computes the weight minv of the minimum weight edge that covers the tree edge {v, p(v)} according to the weights of the edges it receives from its children, and the weights of the edges incoming to it. It also computes the weights of the minimum weight edges that cover the path from v to each of its ancestors u, according to the weights v receives in the algorithm. Then, v subtracts minv from the weights of these edges, and sends them to its parent with the altered weights. In the second traversal, we scan the tree from the root to the leaves. Each child v of r adds to the augmentation the edge having weight minv . It informs the relevant child who sent it, if exists, and informs its other children it did not add their edges. Each internal vertex v receives from its parent a message that indicates whether one of the edges it sent was added to the augmentation by one of its ancestors or not. In the former case, v learns that this edge was added to the augmentation and forwards the message to the relevant child who sent it, if such exists. Otherwise, the tree edge {v, p(v)} is still not covered, and v adds to the augmentation the edge having weight minv . It informs the relevant child who sent it, if exists, and informs its other children that their edges were not added to the augmentation. A full description of the algorithm is given in Appendix B.1. Time analysis: In our algorithm, each vertex sends to its parent information about at most h edges. If each vertex waits to receive all the messages from its children, before sending messages to its parent, it would result in a time complexity of O(h2 ) rounds. However, using pipelining we get a time complexity of O(h) rounds. The main intuition is that although each vertex v may receive h different messages from each of its children during the algorithm, in order for v to send to its parent p(v) the message concerning an ancestor u, the vertex v only needs to receive one message from each of its children concerning the ancestor u. Hence, if all the vertices send the messages according to increasing order of heights of their ancestors, we can pipeline the messages and get a time complexity of O(h) rounds. The full proof appears in Appendix B.2. Correctness proof : In Appendix B.3, we give a correctness proof for the algorithm. The challenge in establishing the correctness of our algorithm lies in the fact that the vertices use altered weights rather than the original ones. Nevertheless, we show that our intuition behind choosing these altered weights faithfully captures the essence of finding an augmentation in the weighted case. The key ingredient we use in our proof is giving a cost to each edge of T . For a tree edge t = {v, p(v)}, we assign the cost c(t) = minv . We are then able to prove the following. (I) The sum of the costs of the edges of T is equal to the cost of the augmentation obtained by the algorithm. (II) The cost of any augmentation of G0 is at least the sum of costs of the edges of T . To show (I), for each edge e added to the augmentation, we assign a tree path Pe , as follows. For an edge e = {u, x} added to the augmentation by a vertex v, where u is an ancestor P of x in the tree, we assign the tree path Pe between x to p(v). Then, we show that w(e) = t∈Pe c(t). The proof is based on the fact P that the cost of the tree edge {v, p(v)} is minv by definition, however, its cost is also w(e) − v0 ∈V 0 minv0 where V 0 are all the vertices on the path between x and v, excluding v. This is since each vertex v 0 in this path reduces minv0 from the weight of e before 9 sending it to itsPparent, and since P e is the edge v chooses to add to the augmentation. This gives w(e) = minv + v0 ∈V 0 minv0 = t∈Pe c(t). In addition, we show that the paths Pe are disjoint and their union is the entire tree T , which proves (I). The proof is based on the fact that the edges of the augmentation cover all tree edges, and that a vertex v adds an edge to the augmentation only if the tree edge {v, p(v)} is not already covered by an edge added by one of its ancestors. We prove (II) in a similar way. In conclusion, our algorithm gives an optimal augmentation in G0 , which gives a 2-approximation augmentation in G. Theorem 1.1. There is a distributed 2-approximation algorithm for weighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . 4 Applications In this section, we discuss applications of our algorithms, and show they provide efficient algorithms for additional related problems. Minimum Weight 2-Edge-Connected Spanning Subgraph: In the minimum weight 2edge-connected spanning subgraph problem (2-ECSS), the input is a 2-edge-connected graph G, and the goal is to find the minimum weight 2-edge-connected spanning subgraph of G. Using AT AP we have the following. Theorem 1.3. There is a distributed 2-approximation algorithm for unweighted 2-ECSS in the CONGEST model that completes in O(D) rounds. Proof. We apply AT AP on G and a BFS tree T of G. Finding a BFS tree takes O(D) rounds [28], and AT AP takes O(D) rounds since T is a BFS tree. The size of the augmentation Aug is at most n − 1 because in the worst case we add a different edge in order to cover each tree edge. Hence, T ∪ Aug is a 2-edge-connected subgraph with at most 2(n − 1) edges. Note that any 2-edge-connected graph has at least n edges, which implies a 2-approximation, as claimed. The above algorithm has a better time complexity compared to the algorithm of [21], which finds a 32 -approximation to 2-ECSS in O(n) rounds. In the algorithm of [21], the augmented tree T is a DFS tree rather then a BFS tree. The same proof of [18, 21] gives that if we apply AT AP on G and a DFS tree we also obtain a 32 -approximation to 2-ECSS in O(n) rounds. For weighted 2-ECSS, using AwT AP gives the following. Theorem 4.1. There is a distributed 3-approximation algorithm for weighted 2-ECSS in the √ CONGEST model that completes in O(hM ST + n log∗ n) rounds, where hM ST is the height of the MST. Proof. We follow the same approach of [21]. We start by constructing an MST, which takes √ O(D + n log∗ n) rounds [22], and then we augment it using AwT AP in O(hM ST ) rounds.3 Let w(A) be the weight of an optimal solution A to weighted 2-ECSS. Since both the MST and an optimal augmentation have weights at most w(A), and since our algorithm for weighted TAP gives a 2-approximation, this approach gives a 3-approximation for weighted 2-ECSS. 3 We assume that the MST is unique. Otherwise, hM ST is the height of the MST we construct. 10 This algorithm has a better time complexity compared to the algorithm of [21], which takes O(n log n) rounds, with the same approximation ratio. Increasing the Edge-Connectivity from 1 to 2: AwT AP is a 2-approximation algorithm for TAP, but can also be used to increase the connectivity of any spanning subgraph H of G from 1 to 2. In order to do so, we start by finding a spanning tree T of H. Note that it is not enough to apply AT AP on T and take the augmentation obtained, since edges from H can be added to the augmentation with no cost. Hence, we apply AwT AP on G and T , where we set the weights of all the edges of H to be 0. The augmentation Aug we obtain is a set of edges such that T ∪ Aug is 2-edge-connected, which also implies that H ∪ Aug is 2-edge-connected. In addition, its cost is at most twice the cost of an optimal augmentation of H, because any augmentation of H corresponds to an augmentation of T with the same cost, and Aug is a 2-approximation to the optimal augmentation of T . The time complexity is O(DH ) rounds where DH is the diameter of H, since finding a spanning tree T of H takes O(DH ) rounds and applying AwT AP takes O(DH ) rounds because it is the height of T . Verifying 2-Edge-Connectivity: The algorithm AT AP can be used in order to verify if a connected graph G is 2-edge-connected in O(D) rounds, where at the end of the algorithm all the vertices know if G is 2-edge-connected.4 We start by building a BFS tree T of G and then apply AT AP to G and T . Note that when we find an optimal augmentation in G0 by AAug , each vertex v is responsible to cover the tree edge {v, p(v)}. If the graph G is 2-edge-connected, all the edges can be covered. If the graph G is not 2-edge-connected, then there is a tree edge {v, p(v)} that is a bridge in the graph, and hence cannot be covered by any edge in G. In such a case, v identifies that it cannot cover the edge and hence the graph is not 2-edge-connected. Therefore, after scanning the tree from the leaves to the root in AAug , we can distinguish between these two cases, which takes O(D) rounds. The root r can distribute the information to all the vertices in O(D) rounds as well. e + √n) rounds A 4-approximation for Unweighted TAP in O(D 5 The time complexity of AT AP and AwT AP is linear in the height of T . When h is large, we suggest √ a much faster O(D + n log∗ n)-round algorithm for unweighted TAP. Here we give a high-level description of the algorithm, full details and proofs appear in Appendix C. The structure of the algorithm is the same as the structure of AT AP . It starts by building the same virtual graph G0 , and then it finds an augmentation in G0 . However, since we want to reduce the time complexity, our algorithm cannot scan the whole tree anymore. Therefore, we can no longer use directly the LCA labeling scheme and the algorithm AAug for finding an optimal augmentation. To overcome this, we break the tree T into fragments, and we divide the algorithm into local parts, in which we communicate in each fragment separately, and to global parts, in which we coordinate between different fragments over a BFS tree. This approach is useful also in other distributed algorithms for global problems, such as finding an MST [22] or a minimum cut [26]. The challenge is showing that this approach guarantees a good approximation. Since our algorithm does not scan the whole tree T it may add different edges in order to cover the same tree edges, which makes the analysis much more involved. Building G0 from G: In order to build G0 from G we use the labeling scheme for LCAs that 4 A verification algorithm with the same complexity can also be deduced from the edge-biconnectivity algorithm of Pritchard [29]. 11 we used in AT AP . However, applying this scheme directly takes O(h) rounds. We show how to √ compute all the relevant LCAs more efficiently in O(D + n) rounds. The idea is to apply the labeling scheme on each fragment separately to obtain local labels, and to apply the labeling scheme on the tree of fragments to obtain global labels. We show that using the local and global labels, and additional information on the structure of the tree of fragments, each vertex can compute all the edges incoming to it in G0 . For full details see Appendix C.1. Finding an optimal augmentation in G0 : In order to find an augmentation in G0 , we need to cover tree edges between fragments (global edges) and tree edges in the same fragment (local edges). For doing so, we start by computing all the maximal edges that cover the global edges. To cover all the global edges, one approach could be to add all these maximal edges to the augmentation. However, this cannot guarantee a good approximation. Instead, we apply AAug on the tree of fragments in order to cover all the global edges. Then, we apply it on each fragment separately in order to cover the local edges in the fragment that are still not covered. This algorithm requires coordination between different fragments, since each vertex v needs to learn if the tree edge {v, p(v)} is already covered after the first part of the algorithm. In addition, although the second part is applied on each fragment separately, a vertex v may need to add an edge incoming to another fragment to cover the tree edge {v, p(v)}. For achieving an efficient time complexity, we show how √ to use only O( n) different messages for the whole coordination of the algorithm. For full details see Appendix C.2. Approximation Ratio: We show that this approach gives a 2-approximation to the optimal augmentation in G0 . Denote by A the solution obtained by the algorithm and by A∗ an optimal augmentation in G0 . In the correctness proof of AT AP we show a one-to-one mapping from A to A∗ , but this mapping is no longer one to one here. However, if we could show that each edge in A∗ is mapped to by at most two edges from A, we can obtain a 2-approximation. Unfortunately, this does not hold either. Our approach is to divide the edges in A to two types A1 , A2 as follows. We map each edge e ∈ A to a corresponding path Pe in T . If Pe contains an internal vertex with more than one child in the tree we say that e ∈ A1 , otherwise e ∈ A2 . Then, we show that |A1 | ≤ 2|A∗ |, and |A2 | ≤ 2|A∗ |. The main idea is that the number of edges in A1 is related to the degrees of internal vertices in T , which affects the number of leaves in the tree. We use this in order to show that |A1 | ≤ 2` where ` is the number of leaves in T . Note that ` is a lower bound on the size of any augmentation in G0 , since we need to add to the augmentation a different edge in order to cover each one of the leaves. This gives |A1 | ≤ 2|A∗ |. In order to show that |A2 | ≤ 2|A∗ |, we use the fact that the edges of A2 correspond to tree paths with a simple structure. This allows us to show a mapping between A2 to A∗ in which each edge in A∗ is mapped to by at most two edges from A2 , giving |A2 | ≤ 2|A∗ |. In conclusion, |A| = |A1 ∪ A2 | ≤ 4|A∗ |. A more delicate analysis extending these ideas gives |A| ≤ 2|A∗ |. This gives a 2-approximation to the optimal augmentation of G0 , which results in a 4-approximation to the optimal augmentation in G. A full proof of the approximation ratio is given in Appendix C.3, and gives the following. Theorem 1.2. There is a distributed 4-approximation algorithm for unweighted TAP in the CON√ GEST model that runs in O(D + n log∗ n) rounds. 12 6 Lower Bounds An Ω(D) Lower Bound for TAP in the LOCAL model: We show that TAP is a global problem, which admits a lower bound of Ω(D) rounds, even in the LOCAL model where the size of messages is unbounded. Theorem 1.4. Any distributed α-approximation algorithm for weighted TAP takes Ω(D) rounds in the LOCAL model, where α ≥ 1 can be any polynomial function of n. This holds also for unweighted TAP, if 1 ≤ α < n−1 2c for a constant c > 1. The proof is based on considering two similar graphs G1 , G2 , defined as follows. The graph G1 consists of a path T of n = 2k + 1 vertices {v0 , v1 , ..., v2k }, and the edges {v2i , v2(i+1) } for 0 ≤ i < k, where G2 = G1 ∪ {v0 , v2k }. In G2 , adding the edge {v0 , v2k } already covers all the edges of the tree T , where in G1 we must add many edges to the augmentation. However, a vertex in the middle of the path T cannot distinguish between the graphs G1 , G2 in less than Ω(D) rounds. Based on these ideas, we show that approximating TAP takes Ω(D) rounds. The full proof appears in Appendix D.1. A Lower Bound for weighted TAP in the CONGEST model: By Theorem 1.4, when h = O(D) our algorithms AT AP , AwT AP are optimal up to a constant factor. But what about the case of h = ω(D) for the CONGEST model? In Appendix D.2, we show a family of graphs where h = ω(D), in which Ω(h) rounds are needed in order to approximate weighted TAP, where √ h = O( n). The lower bound is proven using a reduction from the 2-party set-disjointness problem, in which there are two players, Alice and Bob, that have to decide whether their input strings are disjoint. Our construction is based on a construction presented in [5, 32]. In order to use this construction for showing lower bounds for TAP, we add to it additional parallel edges5 and give weights to the edges in such a way that all the edges of the input tree T can be covered by parallel edges of weight 0, except for k edges, {ei }ki=1 . The edge ei may be covered either by a corresponding B parallel edge eA i , or by a distant edge ei that closes a cycle that contains ei (see Figure 2 for an B illustration). However, the weights of the edges eA i and ei depend on the i’th bit in the input strings of Alice and Bob, such that there is a light edge that covers ei if and only if this bit equals 0 at least in one of the input strings. It follows that all the k edges can be covered by light edges if and only if the input strings of Alice and Bob are disjoint. Using a known lower bound on the communication complexity of set-disjointness, we prove Theorem 1.5. Full details and proofs appear in Appendix D.2. Theorem 1.5. For any polynomial function α(n), there is a Θ(n) − vertex graph of diameter Θ(log n) for which any (perhaps randomized) distributed α(n)-approximation algorithm for weighted √ n TAP with an instance tree T ⊆ G of height h = Θ( log n ) requires Ω(h) rounds in the CONGEST model. 7 Discussion In this paper, we present the first distributed approximation algorithms for TAP. Many intriguing problems remain open. First, can we get efficient distributed algorithms for TAP with an approximation ratio better than 2? In the sequential setting, achieving an approximation better than 2 for weighted TAP is a central open question. However, there are several recent algorithms achieving better approximations for unweighted TAP [4, 20] or for weighted TAP with bounded weights [1, 7]. 5 We also show a construction with no parallel edges. 13 𝑟 = 𝑢0 𝑢1 𝑢2 𝑢𝑑𝑝−1 𝑣01 𝑣𝑑1𝑝 −1 𝑣02 𝑣𝑑2𝑝 −1 𝑣0𝑘 𝑣𝑑𝑘𝑝 −1 Figure 2: The structure of the graph G. The edges of the input tree T are marked with solid lines, other edges are marked with dashed lines. The edge ei = {r, v0i } can be covered either by a parallel B i edge eA i , or by the corresponding edge ei = {udp −1 , vdp −1 } (additional options are expensive). Second, can we show algorithms for weighted TAP and weighted 2-ECSS that are more efficient? √ For unweighted TAP, we showed an algorithm with a time complexity of O(D + n log∗ n) rounds. √ In addition, for unweighted k-ECSS, the O(k(D + n log∗ n))-round algorithm of Thurimella [33] gives a 2-approximation. However, currently there are no algorithms for the weighted problems with a similar time complexity. There are many additional connectivity augmentation problems, such as increasing the edge connectivity from k to k + 1 or to some function f (k), as well as augmentation for increasing the vertex connectivity. Such problems have been widely studied in the sequential setting, and a natural question is to design distributed algorithms for them. Finally, it is interesting to study TAP and additional connectivity problems also in other distributed models, such as the dynamic model where edges or vertices may be added or removed from the network during the algorithm. An interesting question is how to maintain highly-connected backbones when the network can change dynamically. References [1] David Adjiashvili. Beating approximation factor two for weighted tree augmentation with bounded costs. In Proceedings of the Twenty-Eighth Annual ACM-SIAM Symposium on Discrete Algorithms (SODA), pages 2384–2399. SIAM, 2017. [2] Stephen Alstrup, Cyril Gavoille, Haim Kaplan, and Theis Rauhe. Nearest common ancestors: A survey and a new algorithm for a distributed environment. Theory of Computing Systems, 37(3):441–456, 2004. [3] Keren Censor-Hillel, Mohsen Ghaffari, and Fabian Kuhn. Distributed connectivity decomposition. In Proceedings of the 2014 ACM symposium on Principles of distributed computing (PODC), pages 156–165. ACM, 2014. [4] Joseph Cheriyan and Zhihan Gao. Approximating (unweighted) tree augmentation via lift-andproject, part II. Algorithmica, pages 1–44, 2015. 14 [5] Michael Elkin. An unconditional lower bound on the time-approximation trade-off for the distributed minimum spanning tree problem. SIAM Journal on Computing, 36(2):433–456, 2006. [6] Michael Elkin. A simple deterministic distributed MST algorithm, with near-optimal time and message complexities. In Proceedings of the ACM Symposium on Principles of Distributed Computing (PODC), pages 157–163, 2017. [7] Samuel Fiorini, Martin Groß, Jochen Könemann, and Laura Sanità. A 3/2-approximation algorithm for tree augmentation via chvátal-gomory cuts. CoRR, abs/1702.05567, 2017. [8] Greg N Frederickson and Joseph JáJá. Approximation algorithms for several graph augmentation problems. SIAM Journal on Computing, 10(2):270–283, 1981. [9] Robert G. Gallager, Pierre A. Humblet, and Philip M. Spira. A distributed algorithm for minimum-weight spanning trees. ACM Transactions on Programming Languages and systems (TOPLAS), 5(1):66–77, 1983. [10] Juan A Garay, Shay Kutten, and David Peleg. A sublinear time distributed algorithm for minimum-weight spanning trees. SIAM Journal on Computing, 27(1):302–316, 1998. [11] Mohsen Ghaffari and Merav Parter. Near-optimal distributed algorithms for fault-tolerant tree structures. In Proceedings of the 28th ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pages 387–396. ACM, 2016. [12] Michel X Goemans, Andrew V Goldberg, Serge A Plotkin, David B Shmoys, Eva Tardos, and David P Williamson. Improved approximation algorithms for network design problems. In SODA, volume 94, pages 223–232, 1994. [13] P Humblet. A distributed algorithm for minimum weight directed spanning trees. IEEE Transactions on Communications, 31(6):756–762, 1983. [14] Kamal Jain. A factor 2 approximation algorithm for the generalized steiner network problem. Combinatorica, 21(1):39–60, 2001. [15] Maleq Khan, Fabian Kuhn, Dahlia Malkhi, Gopal Pandurangan, and Kunal Talwar. Efficient distributed approximation algorithms via probabilistic tree embeddings. Distributed Computing, 25(3):189–205, 2012. [16] Samir Khuller. Approximation algorithms for finding highly connected subgraphs. In Approximation algorithms for NP-hard problems, pages 236–265. PWS Publishing Co., 1996. [17] Samir Khuller and Ramakrishna Thurimella. Approximation algorithms for graph augmentation. Journal of Algorithms, 14(2):214–225, 1993. [18] Samir Khuller and Uzi Vishkin. Biconnectivity approximations and graph carvings. Journal of the ACM (JACM), 41(2):214–235, 1994. [19] Guy Kortsarz and Zeev Nutov. Approximating minimum cost connectivity problems. In Dagstuhl Seminar Proceedings. Schloss Dagstuhl-Leibniz-Zentrum für Informatik, 2010. [20] Guy Kortsarz and Zeev Nutov. A simplified 1.5-approximation algorithm for augmenting edge-connectivity of a graph from 1 to 2. ACM Transactions on Algorithms (TALG), 12(2):23, 2016. 15 [21] Sven O Krumke, Peter Merz, Tim Nonner, and Katharina Rupp. Distributed approximation algorithms for finding 2-edge-connected subgraphs. In International Conference On Principles Of Distributed Systems (OPODIS), pages 159–173. Springer, 2007. [22] Shay Kutten and David Peleg. Fast distributed construction of k-dominating sets and applications. In Proceedings of the fourteenth annual ACM symposium on Principles of distributed computing (PODC), pages 238–251. ACM, 1995. [23] Christoph Lenzen and Boaz Patt-Shamir. Improved distributed steiner forest construction. In Proceedings of the 2014 ACM symposium on Principles of distributed computing (PODC), pages 262–271. ACM, 2014. [24] Nathan Linial. Locality in distributed graph algorithms. SIAM J. Comput., 21(1):193–201, 1992. [25] Hiroshi Nagamochi and Toshihide Ibaraki. A linear-time algorithm for finding a sparse kconnected spanning subgraph of a k-connected graph. Algorithmica, 7(1):583–596, 1992. [26] Danupon Nanongkai and Hsin-Hao Su. Almost-tight distributed minimum cut algorithms. In International Symposium on Distributed Computing, pages 439–453. Springer, 2014. [27] Gopal Pandurangan, Peter Robinson, and Michele Scquizzato. A time-and message-optimal distributed algorithm for minimum spanning trees. In Proceedings of the 49th Annual ACM SIGACT Symposium on Theory of Computing (STOC), pages 743–756. ACM, 2017. [28] David Peleg. Distributed Computing: A Locality-Sensitive Approach. SIAM, 2000. [29] David Pritchard. Robust network computation. Master’s thesis, MIT, 2005. [30] David Pritchard and Ramakrishna Thurimella. Fast computation of small cuts via cycle space sampling. ACM Transactions on Algorithms (TALG), 7(4):46, 2011. [31] Alexander A. Razborov. On the distributional complexity of disjointness. Theoretical Computer Science, 106(2):385–390, 1992. [32] Atish Das Sarma, Stephan Holzer, Liah Kor, Amos Korman, Danupon Nanongkai, Gopal Pandurangan, David Peleg, and Roger Wattenhofer. Distributed verification and hardness of distributed approximation. SIAM Journal on Computing, 41(5):1235–1265, 2012. [33] Ramakrishna Thurimella. Sub-linear distributed algorithms for sparse certificates and biconnected components. In Proceedings of the fourteenth annual ACM symposium on Principles of distributed computing (PODC), pages 28–37. ACM, 1995. A A 2-approximation for Unweighted TAP in O(h) rounds: full details and proofs In this section, we give full details and proofs for the algorithm AT AP , and show the following. Theorem 2.1. There is a distributed 2-approximation algorithm for unweighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . 16 In Section A.1, we describe how we build the virtual graph G0 . Then, we show in Section A.2 that an optimal augmentation in G0 gives a 2-approximation augmentation in G. In Section A.3, we describe the algorithm for finding an optimal augmentation in G0 , and we prove its correctness in Section A.4. A.1 Building G0 from G AT AP starts by building a related virtual graph G0 . Building G0 requires efficient computation of lowest common ancestors (LCAs), which we next explain how to obtain in the distributed setting. A.1.1 Computing LCAs We use the labeling scheme for LCAs of Alstrup et al. [2]. This labeling scheme assigns labels of size O(log n) bits to the vertices of a rooted tree with n vertices, such that given the labels of u and v it is possible to infer the label of their LCA. The algorithm for computing the labels takes O(n) rounds in a centralized setting, and we observe that it can be implemented in O(h) rounds in the distributed setting, where h is the depth of the tree, as was also observed by [30]. This is because the algorithm consists of a constant number of traversals of the tree, from the root to the leaves or vice versa. Thus, we have: Lemma A.1. Constructing the labeling scheme for LCAs of Alstrup et al. [2] takes O(h) rounds. AT AP starts by applying the labeling scheme, which takes O(h) rounds. We next explain how we use it in order to build G0 . A.1.2 The Graph G0 The graph G0 is defined as follows (as in [17]). The graph G0 includes all the edges of T , and they are all oriented towards the root r of T . For every non-tree edge e = {u, v} in G there are two cases (see Figure 3): 1. If u is an ancestor of v in T , we add the edge {u, v} to G0 , oriented from u to v. 2. Otherwise, denote t = LCA(u, v). In this case we add to G0 the edges {t, u} and {t, v}, oriented from t to u and to v, respectively. Figure 3: There are two cases for every non-tree edge in G. The left graph shows the first case, where the edge {u, v} is between an ancestor and a descendant in T . The right graph shows the second case, where t = LCA(u, v). We emphasize that G0 is an undirected graph, but we associate an orientation with every edge, which we use in the algorithm. Note that in the second case, the edges {t, u} and {t, v} added to G0 are not necessarily in G, and therefore we cannot use them for communication. Hence, the rest of the communication in the algorithm is only over the tree edges. In order to simulate the algorithm over G0 , it is enough 17 that each vertex knows only the tree edges incident to it (which is its input), and the labels of the non-tree edges incoming to it in G0 . In order to achieve this, each vertex v sends its label to all of its neighbors in G, and receives their labels. From them, each vertex v computes the edges incoming to it in G0 using the labeling scheme: for each edge e = {u, v} that is not a tree edge, v uses the labels of v and u in order to compute t = LCA(u, v). If t = u, i.e., u is an ancestor of v in T , the edge {u, v} is incoming to v in G0 . Otherwise t 6= u, and if t 6= v, the edge {t, v} is incoming to v in G0 . Since v knows the labels of u and t, using LCA computations it learns the labels of all the edges incoming to it in G0 . The construction of G0 takes O(h) time, for constructing the labeling scheme by Lemma A.1. The rest of the computations take one round. This gives the following. Lemma A.2. Building G0 from G takes O(h) rounds. A.2 The Correspondence between G and G0 We next show that an optimal augmentation in G0 corresponds to an augmentation in G with size at most twice the size of an optimal augmentation. To build G0 from G, for each edge e ∈ G that is not a tree edge, we added one or two edges to 0 G . These edges are the edges corresponding to e in G0 . Equivalently, for each such edge ee ∈ G0 , the edge e is an edge corresponding to ee in G. An edge ee ∈ G0 may have several corresponding edges in G. Claim A.3. If the non-tree edge e = {u, v} covers the tree edge e0 in G, then one of the edges corresponding to e in G0 covers e0 in G0 . Proof. If e is in G0 the claim is immediate. Otherwise, the edges {t, u} and {t, v}, where t = LCA(u, v), are the edges corresponding to e in G0 . The path from u to v in T is the union of a simple path between u and t and another simple path from t to v, so the edge e0 must be on one of these paths, hence one of the edges {t, u} or {t, v} covers it. Claim A.4. If the non-tree edge ee in G0 covers the tree edge e0 , and e is an edge corresponding to ee in G, then e covers e0 in G. Proof. If e = ee then the claim is immediate. Otherwise, ee = {t, u} for some t, u, and e = {u, v} where t = LCA(u, v). The edge ee covers e0 in G0 , so e0 is on the unique path in T between t and u. The unique path in T between u and v is the union of a simple path between u and t and another simple path from t to v. In particular, the edge e = {u, v} covers the edge e0 in G, as needed. Assume that A0 is an augmentation in G0 , and A is the set of corresponding edges in G, where each edge in A0 is replaced by a corresponding edge in G. Corollary A.5. A is an augmentation in G. Proof. A0 is an augmentation so it covers all tree edges and hence from Claim A.4, A covers all tree edges, i.e., A is an augmentation in G. Lemma A.6. Assume that A0 is an α-approximation to the optimal augmentation in G0 , then A is a 2α-approximation to the optimal augmentation in G. 18 Proof. Note that |A| ≤ |A0 | because each edge in A0 is replaced by one edge in A. Assume that OP T is an optimal augmentation in G and OP T 0 is the set of corresponding edges in G0 , where each edge in G is replaced by the corresponding one or two edges in G0 . OP T covers all tree edges, so OP T 0 covers all tree edges by Claim A.3, i.e, it is an augmentation in G0 . It holds that |OP T 0 | ≤ 2|OP T | because each edge is replaced by at most two edges. Moreover, |A0 | ≤ α|OP T 0 | because A0 is an α-approximation to the optimal augmentation in G0 . We conclude that |A| ≤ |A0 | ≤ α|OP T 0 | ≤ 2α|OP T |. A.3 Finding an Optimal Augmentation in G0 The goal of AT AP now is to find an optimal augmentation in G0 . In G0 all the edges that are not tree edges are between an ancestor and a descendant of it in T . This allows us to compare edges and define the notion of maximal edges. Let v be a vertex in the tree, and let e = {u, w} and e0 = {u0 , w0 } be two edges between ancestors u, u0 of v and descendants w, w0 of v. We say that e is the maximal edge among e and e0 if and only if u is an ancestor of u0 . If u = u0 we can choose arbitrarily one of them to be the maximal edge. Among the edges incoming to v, the maximal edge is the edge {u, v} from the ancestor u of v that is closest to the root. Note that using the LCA labels of such edges e, e0 , a vertex v can learn which is the maximal by computing LCA(u, u0 ). Moreover, using the labels of the edge e, a vertex v can check if e covers the tree edge {v, p(v)} using LCA computations: it checks if v is an ancestor of w and if u is an ancestor of p(v). In our algorithm, each time a vertex sends an edge e, it sends the labels of e which allow these computations. In order to cover all tree edges of G0 , each vertex v 6= r in G0 is responsible to cover the tree edge {v, p(v)}. The idea behind the algorithm is to scan the tree T from the leaves to the root, and whenever we get to a tree edge that is still not covered, we cover it by the maximal edge possible. The algorithm AAug for finding an optimal augmentation in G0 starts at the leaves of T and works as follows: • Each leaf v covers the tree edge {v, p(v)} by the maximal edge e incoming to v, it adds e to the augmentation and sends e to its parent. We call this a necessary edge. • Each internal vertex v receives from each of its children at most 2 edges: one is necessary and one is optional. Denote by necv the maximal necessary edge received from v’s children, and denote by optv the maximal edge among all the optional edges v receives from its children and the edges incoming to v. There are two cases: 1. The tree edge {v, p(v)} is already covered by necv . In this case necv is the necessary edge v sends to its parent. In addition, v sends to its parent optv as an optional edge. 2. The tree edge {v, p(v)} is not covered by necv . In this case v adds to the augmentation the edge optv . From the definition of optv , it follows that it is the maximal edge that covers {v, p(v)}. In this case optv is the edge v sends to its parent as a necessary edge, and it does not send an optional edge. If optv is an optional edge received from one of v’s children, v updates the relevant child that this edge is necessary and has been added to the augmentation. It also updates its other children that their edges are not necessary. • When an internal vertex receives from its parent indication if the optional edge it sent is necessary, it forwards the answer to the relevant child, if such exists. • At the end, each vertex knows if the maximal edge incoming to it is necessary or not. The augmentation consists of all the necessary edges. 19 A.4 Correctness Proof Denote by A the solution obtained by AAug , and by A∗ an optimal augmentation in G0 . Lemma A.7. The algorithm AAug finds an optimal augmentation in G0 . Proof. First, A is an augmentation in G0 . Consider a tree edge e = {v, p(v)}. There are edges in G that cover e because G is 2-edge-connected, hence from Claim A.3 there are edges in G0 that cover e. Therefore, v adds such an edge in order to cover e, if it is not already covered by necv . Now we show that |A| ≤ |A∗ |, by showing a one-to-one mapping from A to A∗ . Since A is an augmentation in G0 , it follows that A is an optimal augmentation. When an edge e ∈ A is added to A in AAug , it is in order to cover some tree edge that is still not covered, denote this edge by t(e). Let t(A) be all such tree edges. We map e ∈ A to an edge e∗ ∈ A∗ that covers t(e). This mapping is one-to-one: assume to the contrary that there are two edges e1 , e2 ∈ A that are mapped to the same edge e∗ ∈ A∗ . Note that e∗ is an edge between an ancestor and its descendant in T that covers both t(e1 ) = {v1 , p(v1 )} and t(e2 ) = {v2 , p(v2 )}. Hence, t(e1 ) and t(e2 ) are on the same path in the tree between an ancestor and its descendant. Assume that t(e2 ) is closer to the root r on this path. Note that the tree edge t(e1 ) is not covered by necv1 since t(e1 ) ∈ t(A). Hence, v1 adds the edge e1 in order to cover it, which is the maximal edge possible. Since the edge e∗ covers both t(e1 ) and t(e2 ), it follows that e1 covers t(e2 ) as well, contradicting the fact that t(e2 ) ∈ t(A). This completes the proof that |A| ≤ |A∗ |. We complete AT AP by replacing each edge in A by a corresponding edge in G. Lemma A.8. The time complexity of AT AP is O(h) rounds. Proof. Building G0 from G takes O(h) rounds by Lemma A.2. Finding an optimal augmentation in G0 takes O(h) rounds as well: the algorithm AAug consists of two traversals of the tree, from the leaves to the root, and vice versa. Hence, the total time complexity of AT AP is O(h) rounds. Theorem 2.1. There is a distributed 2-approximation algorithm for unweighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . Proof. The algorithm AAug finds an optimal augmentation in G0 , as proven in Lemma A.7. By Lemma A.6, this corresponds to an augmentation in G with size at most twice the optimal augmentation of G. The time complexity follows from Lemma A.8. B A 2-approximation for weighted TAP in O(h) rounds: full details and proofs In this section, we give full details and proofs for the algorithm AwT AP , and show the following. Theorem 1.1. There is a distributed 2-approximation algorithm for weighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . As explained in Section 3, the algorithm AwT AP has the same structure of AT AP , but it differs from it in the algorithm for finding an optimal augmentation in G0 . In Section B.1, we describe our algorithm for finding an optimal augmentation in G0 . In Section B.2, we analyze the time complexity of the algorithm, and in Section B.3 we prove its correctness. 20 B.1 The algorithm A description of the algorithm is given in Algorithm 1. For simplicity of presentation, we start by describing an algorithm which takes O(h2 ) rounds. Later, in Section B.2, we explain how using pipelining we improve the time complexity to O(h) rounds. Algorithm 1 Finding an Optimal Augmentation in G0 The code is for every vertex v 6= r 1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: Initialization: ev,u ← the minimum weight edge incoming to v that covers the path between v and its ancestor u or ⊥ if there is no such edge. wv (u) ← w(ev,u ) for each ancestor u of v such that ev,u 6= ⊥, and wv (u) ← ∞ otherwise. Av ← the union of v and its children in T . Augv ← ∅ First Traversal: if v is a leaf then for each ancestor u of v: senderv (u) ← v else wait for receiving wv0 (u) for all ancestors u of v, from each child v 0 of v for each ancestor u of v: wv (u) ← minv0 ∈Av wv0 (u), senderv (u) ← argminv0 ∈Av wv0 (u) end if minv ← wv (p(v)) for each ancestor u of v: wv (u) ← wv (u) − minv for each ancestor u 6= p(v) of v send (u, wv (u)) to p(v) Second Traversal: u ← p(v) if v is not a child of r then wait for a message m from p(v) if m 6= ⊥ then u ← m end if end if s ← senderv (u) if s = v then Augv ← Augv ∪ {ev,u } else send u to s end if for each child v 0 6= s of v send ⊥ to v 0 Technical Details: We assume in the algorithm that each vertex knows all the ids of its ancestors in T . We justify it in the next claim. Note that when we construct G0 , if {u, v} is an edge between an ancestor u and its descendant v in T , v learns the label of u according to the LCA labeling scheme and not the id of u. However, once v learns about the ids and labels of all its ancestors, it knows the id of u as well, and can use it in the algorithm. 21 Claim B.1. All the vertices can learn the ids and labels of all their ancestors in O(h) rounds. Proof. In order to do this, at the first round each vertex sends to its children its id and label. In the next round, each vertex sends to its children the id and label it received in the previous round, and we continue in the same way until each vertex learns about all its ancestors. Clearly, after h rounds each vertex learns all the ids and labels of all its ancestors. Claim B.2. If a vertex v adds ev,u to Augv in line 25 of its algorithm, then ev,u 6= ⊥. Proof. Since G0 is 2-edge-connected, we can cover all tree edges by edges from G0 . Hence, the minimum weight of an edge that covers some tree edge is never infinite. It follows that if a vertex v adds ev,u to Augv , then ev,u 6= ⊥. B.2 Time analysis We next analyze the time complexity of the algorithm. In the second traversal of the tree, each parent sends to each of its children one message, which takes O(h) rounds. In the first traversal of the tree, each vertex sends to its parent at most h edges. If each vertex waited until it got all the messages from its children before sending messages to its parent, it would result in a time complexity of O(h2 ) rounds. We show how to get a time complexity of O(h) rounds for this part using pipelining. To show this, we carefully design each vertex v to send the messages (u, wv (u)) in increasing order of heights of its ancestors. The main intuition is that although each vertex v may receive h different messages from each of its children during the algorithm, in order for v to send to its parent p(v) the message concerning an ancestor u, the vertex v only needs to receive one message from each of its children concerning the ancestor u. Hence, if all the vertices send the messages according to increasing order of heights of their ancestors, we can pipeline the messages and get a time complexity of O(h) rounds. We formalize this intuition in the next lemma. Lemma B.3. A vertex v at height i sends to its parent until round i + j the message (u, wv (u)) such that u is an ancestor of v at height j. Proof. We prove the lemma by induction. For a vertex at height 0 (a leaf) the claim holds since v sends the messages according to increasing order of heights. We assume that the claim holds for each vertex at height at most i − 1, and show that it also holds for each vertex v at height i. If j ≤ i the claim holds trivially, since v does not have ancestors at height j. We assume that the claim holds for i and j − 1 and we show that it also holds for i and j. Let v be a vertex at height i, and let u be an ancestor of v at height j. Note that by the induction hypothesis, by round i − 1 + j all the children v 0 of v already sent to v the messages (u, wv0 (u)). Therefore, v can compute wv (u) ← minv0 ∈Av wv0 (u). Note that by round i + j − 1, v already sent all the messages concerning ancestors at height at most j − 1 and sends the message concerning u to its parent until round i + j as needed (in the case that u = p(v) no message is sent in the algorithm). Note that v also knows and sends the new weight wv (u): denote by i0 the height of the parent of v (i < i0 ), then each other ancestor of v is at height greater than i0 . Until round i + i0 , v knows minv = wv (p(v)), so for all the relevant values of j (i0 ≤ j) it can compute the new weight wv (u) ← wv (u) − minv until round i + j. From the lemma we get that by round 2h all the children of r learn about the minimum weight edge that covers the tree edge between them and r, so the first traversal is completed after O(h) rounds. It follows that the overall time complexity of the algorithm is O(h) rounds as needed, giving the following. 22 Lemma B.4. Algorithm 1 completes in O(h) rounds. B.3 Correctness Proof Lemma B.5. Algorithm 1 finds an optimal augmentation in G0 . Proof. Note that the solution obtained by the algorithm is an augmentation of G0 because each vertex v adds an edge in order to cover the tree edge {v, p(v)} if it is not already covered by an edge which one of its ancestors decides to add to the augmentation. In order to show that the augmentation is optimal we give costs to the edges of T such that the sum of the costs is equal to both the cost of the solution obtained by the algorithm and the cost of an optimal augmentation of G0 . Hence, we conclude that the cost of the solution obtained by the algorithm is optimal. Giving costs to the edges of T : Fix a vertex v = 6 r and let t = {v, p(v)}. We define c(t) = minv (the value of wv (p(v)) in line 13 of the algorithm). For an edge e = {u, x} that covers t, such that u is an ancestor of x in T , let P be the path of tree edges between x and p(v) in T . For a vertex v 0 such that {v 0 , p(v 0 )} ∈ P , let Pv0 be the path of tree edges between x and v 0 . Note that minv is the weight of the minimum weight edge covering the tree edge t = {v, p(v)} according to the weights v receives in the algorithm. Denote this edge by ev . P Claim B.6. w(ev ) = t0 ∈P c(t0 ). Proof. Let ev = {u, x}, where u is an ancestor of x in T . For each vertex v 0 on the path between x and v, ev is the minimum weight edge covering the path between v 0 and its ancestor p(v), according to the weights v 0 receives in the algorithm, as otherwise we get a contradiction to the definition of ev . Each vertex on this path reduces minv0 from the weight of ev it receives before sending it to its parent. Denote by V 0 all the vertices on the path between x and v, excluding v. It follows that X X c(t) = minv = w(ev ) − minv0 = w(ev ) − c(t0 ), t0 ∈Pv v 0 ∈V 0 which gives w(ev ) = P t0 ∈P c(t0 ). Claim B.7. For each edge e that covers t, it holds that w(e) ≥ P t0 ∈P c(t0 ). Proof. Let e = {u, x} be an edge that covers t = {v, p(v)} where u is an ancestor of x in T . Denote by Pv = {x = v1 , ..., vk = v} the path of tree edges between x and v in T . We prove by induction that X wvi (p(v)) ≤ w(e) − c(t0 ), t0 ∈Pvi where wvi (p(v)) is the value obtained in line 11 of the algorithm of vi (or at the initialization if vi is a leaf). For i = 1, let ev1 ,p(v) be the minimum weight edge incoming to v1 that covers the path between v1 and p(v) in T . Note that w(ev1 ,p(v) ) ≤ w(e) because e is an edge incoming to v1 that covers the path between v1 and p(v). The value of wv1 (p(v)) is the weight of the minimum weight edge covering the path between v1 and p(v), according to the weights v1 receives. In particular, wv1 (p(v)) ≤ w(ev1 ,p(v) ), P and therefore wv1 (p(v)) ≤ w(e). Since Pv1 is an empty path, we have t0 ∈Pv c(t0 ) = 0, which gives 1 wv1 (p(v)) ≤ w(e) − X t0 ∈Pv1 23 c(t0 ). Assume the claim holds for i, and we prove it holds for i + 1. Denote by ti the tree edge {vi , vi+1 }. Note that vi sends to vi+1 the message (p(v), wvi (p(v)) − minvi ) since it reduces minvi from the value of wvi (p(v)) before sending it to its parent. The value of wvi+1 (p(v)) is the weight of the minimum weight edge covering the path between vi+1 and p(v), according to the weights vi+1 receives.PIn particular, wvi+1 (p(v)) ≤ wvi (p(v)) − minvi . By the induction hypothesis wvi (p(v)) ≤ w(e) − t0 ∈Pv c(t0 ), which gives i wvi+1 (p(v)) ≤ w(e) − X c(t0 ) − minvi = w(e) − t0 ∈Pvi X c(t0 ). t0 ∈Pvi+1 For i = k we get c(t) = wv (p(v)) ≤ w(e) − X t0 ∈P which implies that w(e) ≥ P t0 ∈P c(t0 ), c(t0 ), v as claimed. Claim B.8. The sum of the costs of the edges of T is equal to the cost of the solution obtained by the algorithm. Proof. We map each edge e added to the augmentation to a path Pe of tree edges, such that: (I) The paths that correspond to different augmentation edges are disjoint, and their union is the entire tree T . That is, Pe ∩ Pe0 = ∅ for e 6= e0 , and ∪Pe = T . (II) The weight P of e is equal to the sum of costs of tree edges in the corresponding path, i.e., w(e) = t0 ∈Pe c(t0 ). Let e = {u, x} be an edge added to the augmentation, such that u is an ancestor of x in T . Let v be the vertex that decides to add e to the augmentation. Note that v decides to add e to the augmentation because it covers the tree edge {v, p(v)}, which is not covered yet by an edge that one of v’s ancestors decides to add to the augmentation. We map e to the tree path Pe that consists of all the tree edges on the path between x and p(v). Note that e covers all the edges on this path (and it may also cover other tree edges, on the path between p(v) and u in T ). This divides the tree edges to disjoint paths because the vertices on the path between x and p(v) do not decide to add other edges to the augmentation, since all the relevant tree edges are already covered by e. In addition, these paths include all tree edges because the edges added to the augmentation cover all tree edges. This proves (I). Note that v adds e to the augmentation because the tree edge {v, p(v)} is not covered yet. So v chooses e because P it is the minimum weight edge ev that covers {v, p(v)}. By Claim B.6, it holds that w(ev ) = t0 ∈P c(t0 ) where P = Pe is the path of tree edges between x and p(v). This proves (II). (I) and (II) complete the proof that the cost of all the edges added to the augmentation is equal to the sum of costs of the edges in T . Claim B.9. The cost of any augmentation of G0 is at least the sum of costs of the edges of T . Proof. Let A be an augmentation in G0 . We map a subset of edges E 0 ⊆ A to paths {Pe0 }e∈E 0 in T such that: (I) The paths that correspond to different edges are disjoint, and their union is the entire tree T . (II) The weight of an edge e ∈ E 0 is at least the sum of costs of tree edges on the path Pe0 . 24 We cover tree edges by edges from A as follows. While there is a tree edge that is still not covered, we choose a tree edge that is still not covered and is closest to the root {v, p(v)}, where initially p(v) = r. Since A is an augmentation, there is an edge e = {u, x} in A such that u is an ancestor of x in T and e covers {v, p(v)}. We map e to the tree path Pe0 between x and p(v). The edge e covers all the tree edges on this path, and may cover additional edges closer to the root that are already covered by other edges from A. We continue in the same manner until all the tree edges are covered. From the construction, the paths Pare disjoint and include all tree edges, proving (I). From Claim B.7, it holds that w(e) ≥ t0 ∈P c(t0 ) where P = Pe0 is the path of tree edges between x and p(v), proving (II). To conclude, the cost of all the edges in A is at least the sum of costs of all the edges of T . Note that there might be edges from A that are not mapped to paths in T , which can only increase the cost of A. From Claims B.8 and B.9 we have that the cost of the augmentation obtained by the algorithm is smaller or equal to the cost of any augmentation of G0 , hence the solution obtained by the algorithm is optimal. This completes the proof of Lemma B.5. Theorem 1.1. There is a distributed 2-approximation algorithm for weighted TAP in the CONGEST model that runs in O(h) rounds, where h is the height of the tree T . Proof. By Lemma B.5, Algorithm 1 finds an optimal augmentation in G0 . Its time complexity is O(h) rounds by Lemma B.4. This augmentation corresponds to an augmentation in G with cost at most twice the cost of an optimal augmentation of G by Lemma A.6 (the proof is for the unweighted case, but the same proof shows it holds for the weighted case as well). Building G0 is the same as in the unweighted case and takes O(h) rounds by Lemma A.2. C e + √n) rounds: A 4-approximation for Unweighted TAP in O(D full details and proofs In this section, we show an alternative algorithm for unweighted TAP, proving the following. Theorem 1.2. There is a distributed 4-approximation algorithm for unweighted TAP in the CON√ GEST model that runs in O(D + n log∗ n) rounds. The idea of the algorithm is to break the tree T into fragments, such that each fragment is a √ √ tree with diameter at most O( n) and there are at most O( n) fragments. We do this by using the √ MST algorithm of Kutten and Peleg [22] which has a time complexity of O(D + n log∗ n) rounds. We say that a tree edge is a local edge if its vertices are in the same fragment, and is a global edge if it connects two fragments. The tree of fragments TF is the tree obtained by contracting each fragment F into one vertex vF and having an edge between vF1 and vF2 if the two fragments are √ √ connected by a global edge. Since there are at most O( n) fragments, TF is of size O( n). Each fragment has a root, which is the vertex v closest to r in the fragment. Our algorithm is divided to local parts, in which we communicate in each fragment separately, √ which results in time complexity proportional to the fragments’ diameter, O( n), and to global parts, in which we coordinate between different fragments. The communication between different fragments is done over a BFS tree rooted at r. Building a BFS tree rooted at r takes O(D) rounds [28]. Using the BFS tree we can distribute k different messages from vertices in the tree to all the vertices in the tree in O(D + k) rounds: we first collect all the messages in the root r using upcast, and then r broadcasts the messages to all the vertices in the tree. Each of these parts takes 25 √ O(D + k) rounds [28]. We show that it is enough to distribute O( n) different messages for the √ coordination, which results in time complexity of O(D + n) rounds. The overall time complexity √ of the algorithm is O(D + n log∗ n) rounds. The structure of the algorithm is the same as the structure of AT AP : it starts by building the same virtual graph G0 . Afterwards, it finds an augmentation in G0 , and converts it to an augmentation in G. However, now we do not necessarily obtain an optimal augmentation in G0 , but rather a 2-approximation to the optimal augmentation of G0 , which results in a 4-approximation to the optimal augmentation in G. In order to build G0 from G we use the labeling scheme for LCAs that we used in AT AP . However, now we compute for each vertex a local label and a global label, and show how to use them in order to compute all the edges incoming to a vertex. In order to find an augmentation in G0 , the general idea is to apply AAug on TF in order to cover global edges, and then to apply it on each fragment separately in order to cover local edges that are still not covered. C.1 Building G0 from G In order to build G0 from G, it is enough that each vertex knows all the edges incoming to it in G0 . In order to obtain this, we use the labeling scheme for LCAs that we used for AT AP . However, applying this scheme takes O(h) rounds, and in order to avoid the dependence on h we break the label to a local part and a global part in the following way: • We first apply the labeling scheme for LCAs on each fragment separately, to obtain local labels. • Next, we apply the labeling scheme for LCAs on TF , such that each fragment gets a label. This is the global label of all the vertices in the fragment. The first part takes O(hF ) rounds on a fragment F of height hF . Since the diameter of each √ √ fragment is O( n), it follows that this part takes O( n) rounds. In order to implement the second part efficiently, we first distribute information about the global edges to all the vertices. Note that each global edge connects two fragments. We assume that each fragment has an id known to all the vertices in the fragment, say, the id of the root of the √ fragment, which it can distribute to all the vertices in the fragment in O( n) rounds. For each global edge e = {v, p(v)}, the vertex v distributes the message (id1 , id2 , `1 , `2 ) where id1 , id2 are the ids of the fragments of v and p(v), and `1 , `2 are the local labels of v and p(v). Since there √ are O( n) global edges, we can distribute this information over the BFS tree to all the vertices in √ O(D + n) rounds. After distributing the information about the global edges to all the vertices, they all learn the whole structure of TF . Now each vertex can compute locally the labeling scheme for LCAs on TF and, in particular, learn its global label. Note that applying the labeling scheme √ does not require communication, so the total round complexity of the second part is O(D + n). We now explain how we use the local and global labels in order to compute LCAs in T . Assume the vertices v, u have the local labels `v , `u and the global labels gv , gu , respectively: • If gv = gu then v and u are in the same fragment. It follows that their LCA is in this fragment, since the root of the fragment is an ancestor of both of them. In this case we use the local labels `v , `u in order to compute the local label of their LCA in the fragment, whose global label is gv . 26 • If gv 6= gu then v and u are in different fragments Fv , Fu . They use the global labels in order to compute the global label g of the fragment F that is the LCA of Fv , Fu in TF . In this case it follows that the LCA of v and u in T is in F , and its global label is g. If F = Fv it follows that v is the LCA of v and u, so its local label is `v . Similarly, if F = Fu then its local label is `u . Otherwise, in order to find the local label of the LCA, note that v and u know the whole structure of TF . In particular, they can find the paths between Fv to F in TF , and between Fu to F in TF . The last edges on these paths are global edges of the form e1 = {v1 , p(v1 )}, e2 = {v2 , p(v2 )} where p(v1 ), p(v2 ) are in F (e1 = 6 e2 , otherwise we get a contradiction to the fact that F is the LCA of Fv , Fu in TF ). Note that v and u know the local labels of all the vertices in global edges, and in particular they know the local labels `1 , `2 of p(v1 ), p(v2 ). They can use `1 , `2 in order to compute the local label of the LCA of p(v1 ), p(v2 ) in F . This is the LCA of v, u in T . In conclusion, using gv , gu , v and u can compute the local and global labels of their LCA in T . The computation is based on the information about global edges all vertices know, and does not require communiction. We explained how all the vertices get local and global labels, and how they use these labels in order to compute LCAs in T . As in AT AP , in one round each vertex can send its labels to all its neighbors in G, and get their labels. From these labels each vertex can compute the local and global labels of all the edges incoming to it in G0 by computing LCAs, which does not require √ communication. The overall time complexity of constricting G0 is O(D + n) rounds, for applying the labeling scheme. This gives, √ Lemma C.1. Building G0 from G takes O(D + n) rounds. C.2 Finding an Augmentation in G0 √ We next explain how to find an augmentation in G0 in O(D + n) rounds. In AAug , when we find an augmentation in G0 , we scan T from the leaves to the root, and whenever we get to a tree edge that is still not covered we cover it by the maximal edge possible. An edge e is the maximal edge between e = {u, w} and e0 = {u0 , w0 }, where u, u0 are ancestors of w, w0 respectively, if and only if u is an ancestor of u0 . We define a variant of this algorithm, A0Aug , whose input is the tree T , the graph G, and a set T0 of tree edges from T that are already covered. A0Aug finds an augmentation in G by applying AAug , with the difference that now we cover only the tree edges that are not in T0 . When we cover an edge, we still cover it by the maximal edge possible. The general structure of the algorithm for finding an augmentation in G0 is as follows: • Each leaf v covers the tree edge {v, p(v)} by the maximal edge possible. • We cover global edges that are still not covered by applying A0Aug on TF . • We cover local edges that are still not covered by applying A0Aug on each fragment separately. We next describe how to implement the above efficiently in a distributed way. C.2.1 Covering Leaf Edges For a leaf v in T , we say that the tree edge {v, p(v)} is a leaf edge. We start the algorithm by covering leaf edges: each leaf v covers the tree edge {v, p(v)} by the maximal edge possible. Since each vertex knows the labels of all the edges incoming to it in G0 , it knows which is the maximal one as in AAug . This computation does not require any communication. 27 However, for the rest of the algorithm each vertex u needs to know if the tree edge {u, p(u)} is covered by one of the edges we added in order to cover leaf edges. In order to do that, we need coordination between the vertices. We divide this task into a local coordination at each fragment, and a global coordination between fragments. Local coordination: In this part, each vertex v learns about the maximal edge that covers {v, p(v)} among edges added to the augmentation by leaves in its fragment, if such exists. In order to do this, we apply the following algorithm in each fragment separately: we scan the fragment from its leaves to its root by having each leaf v of the fragment that is also a leaf in T send to its parent the labels of the edge it added. Any leaf of the fragment that is not a leaf in T sends to its parent an empty message. Each internal vertex v gets messages from all its children. If at least one of the messages is an edge that covers {v, p(v)}, v sends to its parent the labels of the maximal edge among those it received from its children. Otherwise, it sends an empty message. Note that using the labels of an edge e = {u, w}, where u is an ancestor of w, a vertex v knows if this edge covers {v, p(v)} using LCA computations: it checks if v is an ancestor of w and if u is an ancestor of p(v). It can also learn which is the maximal edge by LCA computations. Note that by the end of the algorithm each vertex v learns if the tree edge {v, p(v)} is covered by an edge that one of the leaves of the fragment adds to the augmentation, and the root of the fragment, v 0 , learns the labels of the maximal edge added to the augmentation by leaves of the fragment that covers the global edge {v 0 , p(v 0 )}, if such exists. The round complexity of this part is √ proportional to the diameter of the fragment, and is bounded by O( n). Global coordination: Each vertex v that is a root of a fragment, excluding r, sends over the BFS tree the labels of the maximal edge added to the augmentation by leaves of the fragment √ that covers {v, p(v}, if such exists. Since there are at most O( n) fragments, there are at most √ O( n) messages sent. So we can distribute these messages over the BFS tree to all the vertices in √ O(D + n) rounds. Note that using the labels of an edge e, a vertex v knows if this edge covers {v, p(v)} using LCA computations. In particular, each vertex v knows if the tree edge {v, p(v)} is covered by one of the √ O( n) edges sent to all the vertices. √ Note that although there may be ω( n) leaves in T , and each one adds an edge to the augmentation, after the local coordination and the global coordination, in which each vertex receives √ information about O( n) edges, each vertex v knows if the tree edge {v, p(v)} is covered by an edge added by a leaf in T . This is proven in the next claim. Claim C.2. After the local and global coordination, each vertex v knows if the tree edge {v, p(v)} is covered by an edge added by a leaf in T . Proof. Let v be a vertex and assume there is an edge e = {u, w} added by a leaf u in T , which covers the tree edge {v, p(v)}. If u is in the same fragment as v, in the local coordination v learns about the maximal edge added by a leaf in the fragment that covers {v, p(v)}, and in particular it learns that there is an edge that covers {v, p(v)}, as needed. Assume now that u, v are in different fragments, Fu , Fv , and there is no leaf in Fv that adds an edge that covers {v, p(v)}. Let ru be the root of Fu , and let eu be the edge ru sends over the BFS tree. Note that eu covers {v, p(v)} because the edge e covers {ru , p(ru )} and covers {v, p(v)}, and eu is the maximal edge that covers {ru , p(ru )}. So v learns there is an edge added by a leaf that covers {v, p(v)}, as needed. 28 Claim C.3. After the global coordination, each vertex knows if a global edge {v, p(v)} is covered by an edge added by a leaf in T . Proof. Note that all the vertices know the labels of all the global edges. If a global edge {v, p(v)} is covered by an edge {u, w}, where u is a leaf and u is in the fragment Fu , then the edge eu sent by the root ru of Fu covers {v, p(v)} as well. Since all vertices learn about the labels of eu , by LCA computations they can learn that there is an edge added by a leaf that covers {v, p(v)}. C.2.2 Covering Global Edges The goal now is to cover global edges that are still not covered by applying A0Aug to TF . Note that the maximal edge that covers a global edge must be a maximal edge incoming to a fragment: assume that e = {vF1 , vF2 } is the maximal edge that covers the global edge e0 in TF and that e is incoming to F1 , then the maximal edge eM incoming to F1 covers e0 as well. Since e is the maximal edge that covers e0 , it follows that e = eM . Therefore, in order to apply A0Aug it is enough to know the maximal incoming edge to each fragment in TF (they are the only edges that may be added to the augmentation), and which global edges are already covered. Note that all the vertices know which global edges are already covered after the global coordination, according to Claim C.3. In order to learn the maximal edge incoming to a fragment, each fragment computes this edge by scanning the fragment from its leaves to its root. A leaf sends to its parent the labels of the maximal edge incoming to it. Each internal vertex v, excluding the root of the fragment, sends to its parent the labels of the maximal edge covering {v, p(v)} among the edges it receives from its children and the maximal edge incoming to it (it can compute the maximal edge by LCA computations using the labels of the edges). At the end, the root v of each fragment learns about the maximal edge incoming to the fragment that covers the global edge {v, p(v)}, if such exists. The root of each fragment (excluding r) distributes over the BFS tree the (local and global) labels of the maximal edge e incoming to its fragment. Note that the global labels of e indicate √ which fragments are connected by e. Since there are O( n) fragments, we can distribute all this √ information over the BFS tree to all the vertices in O(D + n) rounds. √ The computation at each fragment takes O( n) rounds and the communication between √ fragments takes O(D + n) rounds. So the overall time complexity of this part is bounded by √ O(D + n) rounds. After all the vertices learn the maximal edge incoming to each fragment and which global edges are already covered, each vertex can apply A0Aug on TF locally, without any communication. When a vertex covers a global edge, it covers it by the maximal edge possible with respect to T . This is also a maximal edge with respect to TF , but there may be several edges in TF that connect the same fragments, in which case we use the local labels in order to choose the maximal between them. Note that after applying A0Aug , each vertex knows which of the maximal edges incoming to a fragment is added to the augmentation and, in particular, a vertex v knows if the maximal edge incoming to it is added to the augmentation and if there is an edge added to the augmentation that covers the tree edge {v, p(v)}. The edges added to the augmentation cover all the global edges and some of the local edges. We next cover the local edges that are still not covered. C.2.3 Covering Local Edges In this part, we cover local edges that are still not covered by applying A0Aug locally in each fragment. The idea is to scan the fragment from its leaves to its root, and each time we get to a tree edge that is still not covered, we cover it by the maximal edge possible. 29 Note that the maximal edge covering a tree edge {v, p(v)} may be the maximal edge incoming to any vertex in the subtree rooted at v. In particular, it may be incoming to a vertex in another fragment F . However, in this case it must be the maximal edge incoming to F . Since each vertex knows the maximal edges incoming to each fragment, we can compute the maximal edge covering a tree edge without communication with other fragments. Note that we also know which edges are already covered by edges already added to the augmentation. Denote by T0 all the tree edges that are covered by edges added to the augmentation in order to cover leaf edges or global edges. The distributed implementation of A0Aug is very similar to AAug . However, there are several differences: • We cover only tree edges that are not in T0 . Note that each vertex v knows if the edge {v, p(v)} is in T0 . • In order to apply the algorithm we need to compute for each edge the maximal edge that covers it. A leaf v of the fragment computes this edge among the edges incoming to it and the maximal edges incoming to a fragment. An internal vertex computes it as in AAug , using the edges it receives from its children and the edges incoming to it. • At the end of the algorithm, as in AAug , each vertex knows if the maximal edge it sent to its parent is added to the augmentation. In particular, each vertex in the fragment learns if the maximal edge incoming to it is added to the augmentation by another vertex in the fragment. However, we may decide to add to the augmentation edges incoming to other fragments. We explain next how to distribute this information between fragments. √ The computation on each fragment takes O( n) rounds. In order to end the algorithm, each vertex needs to know if the maximal edge incoming to it is added to the augmentation, which we achieve using global coordination between the fragments. Global coordination: Note that when we apply A0Aug , a vertex may decide to add to the √ augmentation one of the O( n) maximal edges incoming to a fragment. A vertex that decides to √ add such an edge sends the labels of this edge over the BFS tree. Since there are at most O( n) such √ edges, there are at most O( n) different messages sent over the BFS tree, and we can distribute √ this information over the BFS tree to all the vertices in O(D + n) rounds. So, at the end each vertex knows if the maximal edge incoming to it is added to the augmentation as needed. Note that we covered all the edges that were still not covered, so the solution obtained is an augmentation. The overall time complexity of the algorithm for finding an augmentation in G0 is √ O(D + n) rounds. We next show that it is a 2-approximation to the optimal augmentation in G0 . As in AT AP , after we have an augmentation in G0 we can convert it to an augmentation in G that is at most twice the size, which implies that we get a 4-approximation to the optimal augmentation in G. √ Lemma C.4. The time complexity of the algorithm is O(D + n log∗ n) rounds. √ Proof. Breaking the tree T into fragments takes O(D + n log∗ n) rounds, using the MST algorithm √ of Kutten and Peleg [22]. Building G0 from G takes O(D + n) rounds by Lemma C.1, Finding an √ augmentation in G0 takes O(D + n) rounds, as discussed throughout. C.3 Approximation Ratio We now show that the size of our solution is at most twice the size of an optimal augmentation in G0 . Denote by A the solution obtained by the algorithm and by A∗ an optimal augmentation in G0 . 30 In the correctness proof of AT AP we show a one-to-one mapping from A to A∗ , but this mapping is no longer one to one here. However, if we could show that each edge in A∗ is mapped to by at most two edges from A, we can obtain a 2-approximation. Unfortunately, this does not hold either. Our approach is to divide the edges in A to two types A1 , A2 such that |A21 | ≤ |A∗ |, and we show a map between A2 to A∗ in which each edge in A∗ is mapped to by at most two edges from A2 , giving |A2 | ≤ 2|A∗ |. Extending these ideas gives a 2-approximation. Each edge e ∈ A is added to A in the algorithm in order to cover some tree edge that is still not covered, denote this edge by t(e). Let t(A) be all such tree edges. For each edge t(e) ∈ t(A), we go up in the tree until we get to another tree edge t0 ∈ t(A), or to the root in case there is no such edge. If t0 exists, we denote it by t2 (e). Claim C.5. Let e ∈ A, such that t(e) is a global edge and t2 (e) exists. Then there is no edge that covers both t(e) and t2 (e). Proof. Note that t(e), t2 (e) ∈ t(A), i.e., when we get to them in the algorithm they are still not covered. Also, since t(e) is a global edge and t2 (e) is on the path between t(e) to r, we get to t(e) before t2 (e) in the algorithm. When we get to t(e) in the algorithm we cover it by the maximal edge possible. This edge does not cover t2 (e), otherwise t2 (e) 6∈ t(A). Let V>1 be the set of vertices with more than one child in T . We write A = A1 ∪A2 in the following way: let e ∈ A, t(e) = {v, p(v)}, and t2 (e) = {u, p(u)} if it exists. Let P (e) = {p(v) = v1 , ..., vk } be the vertices on the tree path between p(v) and vk = u if t2 (e) exists, or between p(v) and vk = r otherwise. If there is a vertex v 0 ∈ P (e) such that v 0 ∈ V>1 , we say that e ∈ A1 , and otherwise e ∈ A2 . Claim C.6. There is at most one edge e ∈ A2 such that t2 (e) does not exist. Proof. Assume there are two edges e1 , e2 ∈ A2 such that t2 (e1 ), t2 (e2 ) does not exist. Then, on the path P1 between t(e1 ) to r and on the path P2 between t(e2 ) and r there is no vertex in V>1 . It can only happen if one of P1 , P2 is contained in the other. Assume without loss of generality that P1 contains P2 . But then on the path P1 there is another edge in t(A), so t2 (e1 ) exists. Claim C.7. Let t = {v, p(v)} ∈ t(A) and e ∈ A2 such that t2 (e) = {u, p(u)} where u is an ancestor of p(v). Then t(e) is on the tree path P 0 = {v, p(v), ..., u} between t to t2 (e). Proof. If t = t(e) we are done. Note that since e ∈ A2 , on the tree path P (e) between t(e) to t2 (e) there are no vertices in V>1 and no other edges in t(A). If t(e) is not on the path P 0 between t to t2 (e), it follows that there is a vertex v 0 ∈ P (e) such that v 0 ∈ V>1 , at the point where P (e) and P 0 diverge, or t ∈ t(A) is in P (e). Either case gives a contradiction. Let A∗1 be the edges in A∗ that cover leaf edges. Let ` be the number of leaves in T . Claim C.8. |A∗1 | = `. Proof. Each leaf edge is covered by a different edge in A∗ since all the edges in G0 are between an ancestor and its descendant in the tree. Also, each leaf edge is covered by exactly one edge in A∗ , because if there are two edges e1 , e2 that cover the same leaf edge, and assume without loss of generality that e1 is the maximal between them, then it covers all the edges covered by e2 , which contradicts the optimality of A∗ . 31 We divide the leaves to two types in the following way: we map each leaf v to the edge ev ∈ A∗1 that covers the corresponding leaf edge. For each edge ev in A∗1 we look at the corresponding path of tree edges that it covers. If one of the vertices in this path is in V>1 we say that v ∈ L1 , otherwise v ∈ L2 . Let `1 = |L1 | and `2 = |L2 |, giving ` = `1 + `2 . Claim C.9. If there is an edge in A∗1 of the form {v, r} that covers a leaf v ∈ L2 then the solution given by the algorithm is optimal. Proof. Note that if there is an edge in A∗1 of the form {v, r} that covers a leaf v ∈ L2 it follows that T is just the path between v to r and there is one edge that covers it. In such a case, our algorithm is optimal because it starts by adding the maximal edges that cover leaves, and hence it adds this edge and no other edge. We next assume that there are no edges in A∗1 of the form {v, r} that cover a leaf v ∈ L2 . According to our assumption, each edge in A∗1 that covers a leaf edge ev such that v ∈ L2 is of the form {v, u} where u = 6 r. There are exactly `2 tree edges of the form {u, p(u)} for all such veritces u, denote them by E2 . Let A∗2 be all the edges in A∗ that cover edges in E2 . Claim C.10. A∗1 ∩ A∗2 = ∅. Proof. Let e = {u, p(u)} ∈ E2 , so there is a leaf v ∈ L2 such that {v, u} ∈ A∗1 . Note that e is not covered by edges from A∗1 because by the definition of L2 , the subtree rooted at u is the path between v to u, and the only edge from A∗1 that covers edges on this path is {v, u}, which does not cover {u, p(u)}. Claim C.11. |A∗2 | ≥ `2 . Proof. There are exactly `2 edges in E2 . We show that each of them is covered by a different edge from A∗2 . Note that if {u, p(u)} ∈ E2 then the subtree rooted at u is a path, in which all edges are covered by an edge from A∗1 . In particular, in this path there are no other tree edges from E2 . It follows that edges in E2 cannot be on the same path between a leaf and r in the tree, and cannot be covered by the same edge because all the edges in G0 are between an ancestor to its descendant in the tree. The claim follows. Let A∗3 = A∗ \ (A∗1 ∪ A∗2 ). In order to show that |A| ≤ 2|A∗ |, we prove the following two lemmas: Lemma C.12. |A1 | ≤ 2|A∗1 | − 2. Lemma C.13. |A2 | ≤ 2|A∗2 | + 2|A∗3 | + 1. Proof of Lemma C.12. For each internal vertex (including r) we choose one child and call it the main child, and we call the other children extra children. Note that all the vertices in T except r are children of some parent, so there are n − 1 children in T . Denote by x the number of extra children in T . There are n−` internal vertices, so there are n−` main children, giving x = n−1−(n−`) = `−1. We map edges in A1 to vertices in V>1 in the following way: Let e ∈ A1 , such that t(e) = {v, p(v)}. By definition of A1 , on the path P (e) there is a vertex in V>1 . We map e to a vertex u ∈ V>1 that is closest to v on this path. Claim C.14. If u ∈ V>1 has k children then it is mapped to by at most k edges. 32 Proof. The edges e mapped to u are such that t(e) is in the subtree rooted at u. We divide this subtree to k parts according to its children. Let u0 be a child of u, let Tu0 be the subtree rooted at u0 , and let T 0 = Tu0 ∪ {u, u0 }. We show that there is at most one edge e where t(e) ∈ T 0 that is mapped to u. Assume there are 2 edges e1 , e2 ∈ A1 such that t(e1 ), t(e2 ) ∈ T 0 that are mapped to u. Let P1 , P2 be the paths between t(e1 ) and u, and between t(e2 ) and u respectively. If one of P1 , P2 is contained in the other, and assume without loss of generality that P1 contains P2 , then t(e2 ) is on the path between t(e1 ) to u. From the definition of A1 there is a vertex v 0 ∈ V>1 between t(e1 ) to t(e2 ), which is closer to t(e1 ) than u, a contradiction to the fact that e1 is mapped to u. Otherwise, P1 and P2 diverge in some vertex v 0 in Tu0 , but then v 0 is a vertex in V>1 that is closer to t(e1 ) and t(e2 ), a contradiction. It follows that if u has k − 1 extra children, we map to it at most k edges from A1 . In the worst case, the number of edges in A1 is twice the number of extra children. In conclusion, |A1 | ≤ 2x = 2` − 2 = 2|A∗1 | − 2, which completes the proof. Proof of Lemma C.13. According to Claim C.6, there is at most one edge e0 ∈ A2 such that t2 (e0 ) does not exist. We map all the edges in A2 except e0 to edges in A∗ in the following way: let e ∈ A2 . If t(e) is a leaf edge or a local edge, we map e to an edge in A∗ that covers t(e). Otherwise, we map e to an edge in A∗ that covers t2 (e). Our proof is based on the following claims: (I) There are at most `2 edges in A2 that are mapped to edges in A∗1 . (II) Each edge in A∗ is mapped to by at most two edges. (III) Each edge in A∗2 is mapped to by at most one edge. From the above three claims we get that the number of edges in A2 is bounded by 1 + `2 + |A∗2 | + as follows: there is at most one edge e0 that is not included in the mapping, there are at most `2 edges in A2 that are mapped to edges in A∗1 , at most |A∗2 | edges that are mapped to edges in A∗2 , and at most 2|A∗3 | edges that are mapped to edges in A∗3 . Note that by Claim C.11, |A∗2 | ≥ `2 . It follows that |A2 | ≤ 2|A∗2 | + 2|A∗3 | + 1 as needed. 2|A∗3 | Proof of (I). Let e∗ ∈ A∗1 . Then e∗ covers a leaf edge t = {v, p(v}. Let P be the path of tree edges that e∗ covers. Note that t is the only edge in P such that t ∈ t(A): since we start the algorithm by covering each leaf edge by the maximal edge possible, then if e ∈ A is added in the algorithm in order to cover t, it covers also all the edges in P . Since the only edges that may be mapped to e∗ are edges ee such that t(e e) or t2 (e e) are in P , it follows that the only edge in A that may be mapped ∗ to e is the edge e. Note that if e ∈ A2 , in the path P (e) there are no vertices in V>1 , it follows that in P there are no vertices in V>1 , so v ∈ L2 by definition. It follows that there are at most `2 edges in A2 that are mapped to edges in A∗1 . Proof of (II). Assume that there are two edges e1 , e2 in A2 that are mapped to the same edge e ∈ A∗ . Claim C.15. If t(e1 ), t(e2 ) are both global edges that are not leaf edges then e1 , e2 cannot be mapped to the same edge e ∈ A∗ . Proof. Assume that t(e1 ), t(e2 ) are both global edges that are not leaf edges. In this case, e covers both t2 (e1 ), t2 (e2 ), so the path P between them is between a descendant to its ancestor in the tree. Assume without loss of generality that t2 (e2 ) is closer to the root in P . By Claim C.7, t(e2 ) is in P , and it follows that e covers t(e2 ), t2 (e2 ) where t(e2 ) is a global edge, a contradiction to Claim C.5. 33 Claim C.16. If t(e1 ), t(e2 ) are both local or leaf edges then e1 , e2 cannot be mapped to the same edge e ∈ A∗ . Proof. Assume that t(e1 ), t(e2 ) are both local or leaf edges. In this case, e covers both t(e1 ), t(e2 ). Assume without loss of generality that t(e2 ) is closer to the root. Note that t(e1 ), t(e2 ) cannot be in the same fragment, and t(e1 ) cannot be a leaf edge, because when we get to t(e1 ) in the algorithm, we cover it by the maximal edge possible, which covers t(e2 ) because the edge e covers t(e1 ) and t(e2 ). If t(e1 ) is a leaf edge or is in the same fragment as t(e2 ), it follows that t(e2 ) 6∈ t(A). The same argument shows that t(e1 ), t2 (e1 ) are not in the same fragment (t2 (e1 ) is on the path between t(e1 ) and t(e2 ) and is covered by e also). Hence, there is a global edge on the path P between t(e1 ) and t2 (e1 ). Let g be a global edge in P that is closest to t(e1 ). If g ∈ t(A), then when we get to g in the algorithm it is still not covered, and we add the maximal edge possible in order to cover it. This edge covers t2 (e1 ) because the edge e covers both g and t2 (e1 ). This contradicts the fact that t2 (e1 ) ∈ t(A). Hence, g 6∈ t(A), and when we get to it in the algorithm it is already covered by an edge ee added in order to cover a tree edge g 0 . The edge g 0 may be a leaf edge or a global edge, so g 0 6= t(e1 ). Note that t(e1 ) is on the path P between g 0 and g, otherwise we have a vertex in V>1 on the path P 0 between t(e1 ) to g (and in particular between t(e1 ) and t2 (e1 )) at the point where P and P 0 diverge, or another global edge g 0 between t(e1 ) and g (if g 0 is a leaf edge it cannot be on the path between t(e1 ) and g). Either case gives a contradiction. Hence, ee covers t(e1 ), but then t(e1 ) 6∈ t(A). It follows that there is no edge in A∗ that is mapped to by three or more edges. Assume there are three edges e1 , e2 , e3 that are mapped to the same edge e ∈ A∗ . At least two of t(e1 ), t(e2 ), t(e3 ) are local or leaf edges, or at least two of them are global edges that are not leaf edges. Either case gives a contradiction. It follows that each edge in A∗ is mapped to by at most two edges as needed. Proof of (III). Let e∗ ∈ A∗2 , and let P be the path of tree edges covered by e∗ . By definition, there is an edge t = {u, p(u)} ∈ E2 that is covered by e∗ , and the subtree Tu rooted at u is a path which is covered by an edge e1 = {u, v} ∈ A∗1 where v is a leaf. Note that there is only one edge e2 such that t(e2 ) ∈ Tu , which is the edge e2 that covers {v, p(v)}, since all other edges in Tu are already covered by e2 (it is the maximal edge possible, and in particular covers all tree edges covered by e1 ), and e2 is mapped to e1 6∈ A∗2 . The only edges that may be mapped to e∗ are edges e such that t(e) or t2 (e) are in P . There may be at most one edge e mapped to e∗ such that t(e) is a local edge, according to Claim C.16. So, if there is another edge e3 mapped to e∗ it must be a global edge such that t2 (e3 ) is in P . Note that t(e3 ) cannot be in P , otherwise we have a contradiction to Claim C.5, and it cannot be in Tu as explained above. Let v 0 be the first vertex in P on the path P (e3 ) between t(e3 ) to t2 (e3 ). Note that v 0 ∈ V>1 , since it has a child not in P on the path P (e) and another child in P because it is an ancestor of u. In such a case e3 cannot be in A2 . Hence, there is at most one edge in A2 that is mapped to each edge in A∗2 as needed. This completes the proof that |A2 | ≤ 2|A∗2 | + 2|A∗3 | + 1. Theorem 1.2. There is a distributed 4-approximation algorithm for unweighted TAP in the CON√ GEST model that runs in O(D + n log∗ n) rounds. Proof. By Lemma C.12 and Lemma C.13, we have: |A| = |A1 ∪ A2 | ≤ 2|A∗1 | + 2|A∗2 | + 2|A∗3 | − 1 ≤ 2|A∗ |. 34 Hence, A is an augmentation in G0 , whose size is at most twice the size of an optimal augmentation in G0 . It corresponds to an augmentation in G whose size is at most 4 times the size of an optimal √ augmentation in G according to Lemma A.6. The running time is O(D + n log∗ n) rounds by Lemma C.4. D Lower Bounds: full details and proofs In this section, we give full details and proofs for our lower bounds. In Section D.1 we present our lower bound in the LOCAL model, and in Section D.2 we present our lower bound for weighted TAP in the CONGEST model. D.1 An Ω(D) Lower Bound for TAP in the LOCAL model In this section, we prove our Ω(D) lower bound. In the LOCAL model, a vertex can learn in r rounds its r-neighborhood, which consists of all the vertices and edges at distance at most r from it. In addition, if the r-neighborhood of a vertex is the same in two different graphs it cannot distinguish between them in any algorithm that takes at most r rounds. Based on this, we show the following. Theorem 1.4. Any distributed α-approximation algorithm for weighted TAP takes Ω(D) rounds in the LOCAL model, where α ≥ 1 can be any polynomial function of n. This holds also for unweighted TAP, if 1 ≤ α < n−1 2c for a constant c > 1. Proof. Let k be an even integer, and consider the graph G1 that consists of a path P of n = 2k + 1 vertices {v0 , v1 , ..., v2k }, and the edges {v2i , v2(i+1) } for 0 ≤ i < k. Consider also the graph G2 = G1 ∪ {v0 , v2k }. Both graphs have diameter D = Θ(k). Consider an instance for TAP where T is the path P for both graphs G1 and G2 . It is easy to verify that an optimal augmentation in G1 includes all the edges {v2i , v2(i+1) } for 0 ≤ i < k, as this is the only way to cover all the edges. However, in G2 an optimal augmentation includes only the edge {v0 , v2k }. Note that the ( k2 − 1)-neighborhood of vk is the same in both G1 and G2 , so it cannot distinguish between them in any algorithm that takes at most k2 − 1 rounds. Hence, vk must have the same output in both cases. However, in G1 , both of the edges {vk−2 , vk }, {vk , vk+2 } are included in an optimal augmentation, and in G2 they are not, so any distributed algorithm that solves TAP exactly must take Ω( k2 − 1) = Ω(D) rounds. This lower bound holds also for approximation algorithms for the weighted problem: give the weight 1 to the edge {v0 , v2k } and the weight α + 1 to the edges {v2i , v2(i+1) } for 0 ≤ i < k. Any algorithm that adds at least one of the edges {v2i , v2(i+1) } to the augmentation has weight at least α + 1, and hence is not an α-approximation to weighted TAP. Therefore, any distributed α-approximation algorithm for weighted TAP must take Ω(D) rounds. A similar proof shows that approximating unweighted TAP takes Ω(D) rounds for appropriate values of α. In the unweighted case, an algorithm that adds all the edges {v2i , v2(i+1) } for 0 ≤ i < k, gives a k-approximation to the optimal augmentation in G1 . However, if we want a better approximation we need Ω(D) rounds. Assume  k that c > 1 is a constant and we want an α-approximation where α < kc = n−1 . Consider the 2c c edges {v2i , v2(i+1) } that are closest to vk . Each of the vertices on these edges is at distance Ω(k) = Ω(D) from the vertices v0 , v2k . Hence, they cannot distinguish between G1 , G2 in less than Ω(D) rounds. It follows that any distributed α-approximation algorithm for unweighted TAP must take Ω(D) rounds. 35 D.2 A Lower Bound for weighted TAP in the CONGEST model We start by presenting a construction that includes parallel edges, and later explain how to change it to a similar construction that does not include parallel edges. The lower bound is proven using a reduction from the 2-party set-disjointness problem, in which there are two players, Alice and Bob. Each player gets a binary input string of length k: a = (a1 , ..., ak ), b = (b1 , ..., bk ), and the players have to decide whether their inputs are disjoint, i.e., whether there is an index i such that ai = bi = 1 or not. It is known that in order to solve this problem, Alice and Bob have to exchange at least Ω(k) bits, even when using random protocols [31]. D.2.1 Construction with Parallel Edges We follow the constructions presented in [5, 32]. Let G1 = G(k, d, p) be a graph that consists of k paths P1 , ..., Pk of length dp , where the vertices on the path Pi are denoted by vji , for 0 ≤ j ≤ dp − 1, and a tree S of depth p, where each internal vertex has degree d, so it has dp leaves denoted by uj , for 0 ≤ j ≤ dp − 1. In addition, there is an edge between uj to vji for 1 ≤ i ≤ k, 0 ≤ j ≤ dp − 1. Let G2 be a weighted graph with the same structure as G1 , and with parallel edges on the paths i , for 0 ≤ j < dp − 1, and and in the tree. That is, there are two parallel edges between vji and vj+1 there are two parallel edges between a parent to each one of its d children in S. All of the above parallel edges have weight 0. In addition, there are two parallel edges between u0 to v0i , one of them with weight 0. The edges between uj to vji for 0 < j < dp − 1 have weight x = αk + 1. Given two binary input strings of length k: a = (a1 , ..., ak ), b = (b1 , ..., bk ), the second edge between u0 and v0i has weight x if ai = 1 and has weight 1 otherwise. Similarly, the edge between udp −1 and vdi p −1 has weight x if bi = 1 and has weight 1 otherwise. The input to the TAP problem is the graph G2 with a spanning tree TG2 rooted at r = u0 (see Figure 4). TG2 includes one copy of all the path edges, and one copy of all the edges of S, and the edges between r = u0 and v0i that have weight 0 for 1 ≤ i ≤ k. Since we can cover all the path edges and the edges of S by their parallel edges having weight 0, in order to cover all tree edges in TG2 optimally we need to cover the edges between r and v0i optimally. Figure 4: The structure of the graph G2 . The edges of TG2 are marked with solid lines, other edges are marked with dashed lines. Claim D.1. The cost of an optimal augmentation is k if the input strings a and b are disjoint, and it is at least x = αk + 1 otherwise. 36 Proof. In order to cover the tree edge {r, v0i } we can use any other edge between uj to vji . Each such edge has weight x unless at least one of ai or bi is equal to 0, in which case the second edge between r = u0 to v0i or the edge between udp −1 and vdi p −1 has weight 1. These are the only edges that cover the tree edge {r, v0i }. All the other edges in TG2 can be covered with parallel edges of weight 0. It follows that if a and b are disjoint then we can cover all the edges in TG2 with cost k, otherwise the cost is at least x because we need at least one edge of weight x. By Claim D.1, an α-approximation algorithm that computes the weight of an optimal augmentation on the graph G2 with spanning tree TG2 can be used in order to solve the set-disjointness problem: if the input strings are disjoint the weight of an optimal augmentation is k, in which case the output of the algorithm is at most αk. Otherwise, the output of the algorithm is at least x = αk + 1. Note that if A is a distributed α-approximation algorithm for weighted TAP that takes R rounds, then there is a distributed α-approximation algorithm A1 for computing the weight of the optimal augmentation that completes in O(R + D) rounds, where at the end of A1 all the vertices know the weight of an optimal augmentation. This done by having A1 simulate A and then collect the weight of the augmentation over a BFS tree and distribute it to all the vertices. Since R = Ω(D) by Theorem 1.4, it follows that the time complexity of A1 is O(R) rounds, so a lower bound on the time complexity of A1 gives a lower bound on the time complexity of A. Our algorithms work in the CONGEST model where the maximal message size is bounded by Θ(log n) bits, however the proof of the lower bound is based on the proof in [32] which works in a more general model where the maximal message size is bounded by B bits. Hence, the lower bound we show holds for this generalized model as well. Claim D.2. If there is a distributed (perhaps randomized) α-approximation algorithm for computing p the weight of an optimal augmentation in G2 that has time complexity of R rounds where R ≤ d 2−1 , then set-disjointness can be solved by exchanging O(dpBR) bits. Proof. The proof of the claim follows from the proof of Theorem 3.1 in [32], in which it is shown how Alice and Bob can simulate a distributed algorithm on the graph G1 by exchanging at most 2dpBR bits, where at the end of the simulation each player knows the output of one of the vertices r, udp −1 . In the algorithm for computing the weight of an optimal augmentation all the vertices know the weight at the end, so it is enough that each of Alice and Bob knows the output of one vertex. Note that the graphs G1 and G2 have the same structure, but in G2 there may be two parallel edges between vertices v, u that have only one edge between them in G1 . It follows that v, u can exchange 2B bits between them in a round in each direction, instead of B bits. Therefore, in order to simulate a distributed algorithm on G2 , Alice and Bob can use the same simulation but may need to exchange twice as many bits in order to simulate one round, and 4dpBR bits for the whole simulation, which is still O(dpBR) bits, as claimed. At the end of the simulation, both Alice and Bob know an α-approximation to the weight of an optimal augmentation, and can deduce if their input strings are disjoint according to Claim D.1. Theorem D.3. (equivalent to Theorem 7.1 in [32]) For any polynomial function α(n), integers p > 1, B ≥ 1 and n ∈ {22p+1 pB, 32p+1 pB, ...}, there is a Θ(n) − vertex graph of diameter 2p + 2 for which any (perhaps randomized) distributed α(n)-approximation algorithm for weighted TAP 1 with an instance tree T ⊆ G of height h requires Ω((n/(pB)) 2 1 − 2(2p+1) ) rounds which is Ω(h). k Proof. By Claim D.2 and the lower bound on set-disjointness [31] we have R = Ω(min(dp , dpB )). k Choosing k = dp+1 pB gives Ω(min(dp , dpB )) = Ω(dp ). As in [5, 32], G1 and G2 have n = Θ(kdp ) = 37 Θ(d2p+1 pB) vertices and diameter 2p + 2. In addition, h = dp + 1 since the height of TG2 is determined by the length of the paths. Hence, we have R = Ω(dp ) = Ω(h) where h = Θ(dp ) = 1 Θ((n/(pB)) 2 1 − 2(2p+1) ). Choosing B = p = Θ(log n) in Theorem D.3 gives the following. Theorem 1.5. For any polynomial function α(n), there is a Θ(n) − vertex graph of diameter Θ(log n) for which any (perhaps randomized) distributed α(n)-approximation algorithm for weighted √ n TAP with an instance tree T ⊆ G of height h = Θ( log n ) requires Ω(h) rounds in the CONGEST model. D.2.2 Construction without Parallel Edges We next explain how to modify the above construction to avoid parallel edges. We define G3 as follows: • If there is a single edge between the vertices v and u in G2 , then this edge is in G3 and has the same weight as it has in G2 . • For every pair of vertices v, u which have two parallel edges between them in G2 , we add in G3 a new vertex vu and replace one of the two parallel edges between v and u which has weight 0 by two edges {v, vu} and {vu, u}, both with weight 0.6 The tree TG3 in the TAP problem in G3 is constructed according to the tree TG2 in G2 , such that if {v, u} is a tree edge in TG2 , then {v, vu}, {vu, u} are tree edges in TG3 . Note that the edge {v, u} covers both {v, vu}, {vu, u}. Since all the edges on the paths and in the tree S in G2 have weight 0, all the edges on the corresponding paths and tree SG3 in TG3 can be covered by edges of weight 0. In order to cover all tree edges in TG3 optimally we need to cover the edges {r, rv0i }, {rv0i , v0i } optimally. Similarly to the case in G2 , we can cover them by any one of the edges between uj and vji . All those edges have weight x unless at least one of ai or bi is equal to 0, so Claim D.1 holds for G3 as well. If n is the number of vertices in G2 , then in G3 the number of vertices is 2n − 1 = Θ(n) because we add one vertex for each edge of TG2 (the parallel edges in G2 are only on the tree TG2 ). Similarly, the height of TG3 is 2h = Θ(h) where h is the height of TG2 , and the diameter of G3 is Θ(D) where D is the diameter of G2 . Assume that A is an α-approximation algorithm for weighted TAP that takes R rounds in G3 , then there is an α-approximation algorithm A1 for weighted TAP that takes R rounds in G2 . A1 simulates A: all the vertices that are both in G2 and in G3 simulate themselves. For each vertex vu, one of the vertices v, u simulates vu, and assume w.l.o.g that v simulates vu. Note that there are two parallel edges between v and u in G2 . One of them is used in order to simulate the messages sent on the edge {v, u} in A, and the other is used in order to simulate the messages sent on the edge {vu, u} in A. Note that there is no need for communication in order to simulate messages sent on the edge {v, vu} because the vertex v simulates both v, vu. It follows that the simulation of A in G2 takes R rounds. In addition, from the correspondence between G2 and G3 , any augmentation in G3 is an augmentation in G2 , and vice versa. The above implies that the lower bound holds for G3 (which has no parallel edges) as well, and hence Theorem D.3 holds also for simple graphs. 6 Notice that at least one of the two parallel edges indeed has weight 0. 38
8cs.DS
Spectral theorems for random walks on mapping class groups and Out(FN ) François Dahmani and Camille Horbez arXiv:1506.06790v2 [math.GR] 23 Nov 2016 November 24, 2016 Abstract We establish spectral theorems for random walks on mapping class groups of connected, closed, oriented, hyperbolic surfaces, and on Out(FN ). In both cases, we relate the asymptotics of the stretching factor of the diffeomorphism/automorphism obtained at time n of the random walk to the Lyapunov exponent of the walk, which gives the typical growth rate of the length of a curve – or of a conjugacy class in FN – under a random product of diffeomorphisms/automorphisms. In the mapping class group case, we first observe that the drift of the random walk in the curve complex is also equal to the linear growth rate of the translation lengths in this complex. By using a contraction property of typical Teichmüller geodesics, we then lift the above fact to the realization of the random walk on the Teichmüller space. For the case of Out(FN ), we follow the same procedure with the free factor complex in place of the curve complex, and the outer space in place of the Teichmüller space. A general criterion is given for making the lifting argument possible. Contents 1 Random walks on groups acting on hyperbolic spaces 7 2 Translation lengths of random elements: abstract setting 12 3 Spectral theorem for random walks on Mod(S) 19 4 Spectral theorem for random walks on Out(FN ) 26 Introduction In a famous work on random products of matrices [19], Furstenberg and Kesten proved that, under very general conditions, the norm of a random product of n matrices grows as a deterministic exponential function of n. This result was later improved by Furstenberg, who established in [18, Theorems 8.5 and 8.6] that if (Ai )i∈N is a sequence of matrices 1 chosen uniformly at random among a finite generating set for SL(N, Z), then there exists λ > 1 such that for all vectors v ∈ RN r {0}, almost surely, one has p lim n ||An . . . A1 .v|| = λ n→+∞ (and log λ is usually called the Lyapunov exponent of the random process). Furstenberg’s theorem was a starting point in the study of growth of vectors under random products of matrices, which had many further developments, including the famous multiplicative ergodic theorem of Oseledets [42]. Guivarc’h established in [22, Théorème 8] a spectral theorem, relating the asymptotics of the top eigenvalue λ(An . . . A1 ) of the matrix An . . . A1 to the Lyapunov exponent, showing that almost surely, one has p lim n λ(An . . . A1 ) = λ n→+∞ (Guivarc’h actually relates the whole spectrum of the matrix An . . . A1 to the set of all Lyapunov exponents of the process). The goal of the present paper is to establish spectral theorems for the random walks on either the mapping class group Mod(S) of a closed, connected, oriented, hyperbolic surface S – i.e. the group of all isotopy classes of orientation-preserving diffeomorphisms of S – or on the group Out(FN ) of outer automorphisms of a finitely generated free group. Mapping class groups. We fix once and for all a hyperbolic metric ρ on S. Given a simple closed curve c on S, we will denote by lρ (c) the smallest length with respect to ρ of a curve in the isotopy class of c. An important theorem of Thurston describes the possible growth rates of the lengths of essential simple closed curves on S under iteration of a single mapping class of the surface: Thurston proved in [47, Theorem 5] that for all Φ ∈ Mod(S), there is a finite set 1 ≤ λ1 < λ2 < · · · < λK of algebraic integers such that for any essential simple closed curve c on S, there exists i ∈ {1, . . . , K} such that q lim n lρ (Φn (c)) = λi . n→+∞ In addition, the mapping class Φ is pseudo-Anosov if and only if K = 1 and λ1 > 1. In [33], Karlsson proved a version of Thurston’s theorem for random products of mapping classes, describing the growth of simple closed curves on S under such products. Given a probability measure µ on Mod(S), the (right) random walk on (Mod(S), µ) is the Markov chain whose value at time n is a product Φn of n independent random mapping classes si , all distributed with respect to the law µ, i.e. Φn = s1 . . . sn . In the following statement, a subgroup of Mod(S) is nonelementary if it contains two pseudo-Anosov diffeomorphisms of the surface that generate a free subgroup of Mod(S) (equivalently [40], it is not virtually cyclic, and does not virtually preserve the isotopy class of any proper essential subsurface of S). 2 Theorem 0.1. (Karlsson [33, Corollary 4]) Let µ be a probability measure on Mod(S), with finite first moment with respect to the Teichmüller metric, whose support generates a nonelementary subgroup of Mod(S). Then there exists λ > 1 such that for all essential simple closed curves c on S, and almost every sample path (Φn )n∈N of the random walk on (Mod(S), µ), one has q lim n n→+∞ lρ (Φ−1 n (c)) = λ. The real number log λ > 0, which we call the Lyapunov exponent of the random walk on (Mod(S), µ), is deterministic: it is equal to the drift of the realization of the random walk on the Teichmüller space of the surface, with respect to the Teichmüller metric. On the other hand, when µ has finite support, it is known that the mapping class obtained at time n from the random walk on Mod(S) is pseudo-Anosov with probability tending to 1 exponentially fast [43, 45, 36, 9]. Using the Borel–Cantelli Lemma, this implies that almost surely, eventually all mapping classes Φn are pseudo-Anosov (and hence they have a well-defined stretching factor λ(Φn )). We prove the following spectral theorem for random walks on Mod(S), which relates the asymptotics of the stretching factors λ(Φn ) to the Lyapunov exponent of the random walk. Theorem 0.2. Let S be a closed, connected, oriented, hyperbolic surface, and let µ be a probability measure on Mod(S), whose support is finite and generates a semigroup containing two independent pseudo-Anosov elements. Then for almost every sample path (Φn )n∈N of the random walk on (Mod(S), µ), we have p lim n λ(Φn ) = λ, n→+∞ where log λ is the Lyapunov exponent of the random walk. Finiteness of the support of µ can be replaced by the assumption that µ has finite second moment with respect to the Teichmüller metric, see Remarks 2.7 and 3.2 below. If µ is only assumed to have finite first moment with respect to the Teichmüller metric, then the probability that Φn is pseudo-Anosov still converges to 1 [37, Theorem 1.4] but we do not know whether the speed of convergence still ensures that eventually all Φn are pseudo-Anosov. However, in this situation, Theorem 0.2 remains valid if one replaces the limit by a limsup. We also note that Theorem 0.2 remains valid if S is a compact surface with one boundary component, in which case it may be viewed as a particular case of Theorem 0.4. At the cost of an anticipation on the tools and methods (which are detailed later in this introduction), we would like to insist on the difference in nature between Theorems 0.1 and 0.2. On the one hand, the geometric interpretation of the growth described by Theorem 0.1 is an expression of the drift of the realization of the random walk in the Teichmüller space T (S), in terms of a certain (random) limiting horofunction. On the other hand, the geometric interpretation of our main result (Theorem 0.2) is a description of the growth of the translation length log λ(Φn ) along the axis of Φn in T (S). While the 3 distance to the origin in T (S) is subadditive along the trajectories of the random walk (which allows the use of Kingman ergodic theorem to deduce the existence of the drift), the translation length log λ(Φn ) along an axis is not, in fact it can be very different for two very close elements. Therefore, the existence of the limit in Theorem 0.2 is far from obvious. The best straightforward analogue in a free group of the quantity we want to measure would be the length of a cyclic reduction of a word. However, as we are measuring all distances in the Teichmüller space T (S), which is not Gromov hyperbolic, understanding the behaviour of log λ(Φn ) is much more difficult in our setting. This being said, Karlsson formulated a wish, in [33, (iii) page 220], to compare his result “that random walk trajectories eventually look pseudo-Anosov from [the growth] perspective” to the genericity of being pseudo-Anosov. We believe that our result is a very relevant piece of comparison. We would finally like to emphasize that, although the mapping class group Mod(S) has relations with the linear group GL(N, Z) (for example through the symplectic representation), our main result cannot be deduced from Guivarch’s: in fact, Theorem 0.2 also applies to highly non-linear situations, for example it applies to generic random walks on the Torelli group of the surface. Out(FN ). The same question also makes sense for Out(FN ). An element Φ ∈ Out(FN ) is fully irreducible if no power Φk (with k 6= 0) fixes the conjugacy class of a proper free factor of FN . Every fully irreducible outer automorphism Φ ∈ Out(FN ) has a well-defined stretching factor λ(Φ) > 0, which gives the exponential growth rate of all primitive conjugacy classes in FN under iteration of Φ (an element of FN is primitive if it belongs to some free basis of FN ). The analogue of Thurston’s theorem, giving possible growth rates of conjugacy classes of FN under iteration of a single automorphism of FN , also holds true in this context – this can be established using train track theory, see [7, 35]. The second author of the present paper proved in [26, Corollary 5.4] an analogue of Karlsson’s theorem for random walks on Out(FN ), showing that all primitive conjugacy classes in FN grow exponentially fast along typical sample paths of the random walk, with a deterministic exponential growth rate λ. Here, the length ||g|| of a nontrivial element g ∈ FN should be understood as the smallest word length of a conjugate of g, written in some prescribed free basis of FN . A subgroup of Out(FN ) is nonelementary if it is not virtually cyclic, and does not virtually preserve the conjugacy class of any proper free factor of FN . Theorem 0.3. (Horbez [26, Corollary 5.4]) Let µ be a probability measure on Out(FN ), with finite first moment with respect to the Lipschitz metric on outer space, whose support generates a nonelementary subgroup of Out(FN ). Then there exists λ > 1 such that for all primitive elements g ∈ FN , and almost every sample path of the random walk on (Out(FN ), µ), we have q lim n→+∞ n ||Φ−1 n (g)|| = λ. 4 As above, we call log λ the Lyapunov exponent of the random walk, which is also equal to the drift of the realization of the walk on Culler–Vogtmann’s outer space, with respect to the (asymmetric) Lipschitz metric, i.e. log λ = lim n→+∞ 1 dCVN (y0 , Φn .y0 ) n for almost every sample path (Φn )n∈N of the random walk on (Out(FN ), µ) and any y0 ∈ CVN . Here again, if µ has finite support, then the automorphism Φn obtained at time n of the process is fully irreducible with high probability [43, 45, 9], and therefore it has a well-defined stretching factor λ(Φn ). We prove the following spectral theorem for Out(FN ). Theorem 0.4. Let µ be a probability measure on Out(FN ), whose support is finite and generates a semi-group containing two independent fully irreducible elements of Out(FN ). Then for P-a.e. sample path of the random walk on (Out(FN ), µ), we have q n lim λ(Φ−1 n ) = λ, n→+∞ where log λ is the Lyapunov exponent of the random walk. Contrary to the mapping class group case, the stretching factor of an outer automorphism of FN can be different from the stretching factor of its inverse. It is therefore important in the above statement to consider λ(Φ−1 n ) and not λ(Φn ). As in the mapping class group case, finiteness of the support can be replaced by the assumption that µ has finite second moment with respect to the Lipschitz metric on outer space, see Remarks 2.7 and 4.2 below. If µ is only assumed to have finite first moment with respect to the Lipschitz metric, then one should replace the limit by a limsup. Strategy of proofs. We now explain the general idea of the proofs of Theorems 0.2 and 0.4. The mapping class group Mod(S) acts both on the Teichmüller space T (S), and on the curve complex C(S), which is known to be Gromov hyperbolic thanks to work of Masur and Minsky [39]. The behaviour of the realization of the random walk of Mod(S) on the hyperbolic complex C(S) is well-understood: there is a rich literature on random walks on hyperbolic spaces [29, 9, 37]. Typical sample paths of the realization of the random walk on Mod(S) converge to a boundary point ξ ∈ ∂∞ C(S). The length of the overlap between the geodesic ray from a basepoint x0 ∈ C(S) to ξ and a quasi-axis of the mapping class Φn obtained at time n of the process grows linearly with n. In particular the translation length of Φn in C(S) grows linearly with n, with speed equal to the drift of the realization on C(S) of the random walk on Mod(S). On the other hand, the logarithm of the stretching factor of Φn is equal to the translation length of Φn on the Teichmüller space T (S), equipped with the Teichmüller metric. Therefore, we need to establish the same property as above for the realization 5 of the random walk on T (S): namely, we need to show that the translation length of Φn in T (S) grows linearly fast at a speed given by the drift of the random walk in the Teichmuller metric. The rough idea is that typical geodesics in T (S) have a hyperboliclike behaviour. To make this precise, we appeal to a contraction property established by Dowdall, Duchin and Masur in [14]. This asserts that any Teichmüller geodesic segment I whose projection to C(S) makes progress in C(S), is contracting in T (S), in the sense that every other Teichmüller geodesic with same projection as I in C(S), must pass uniformly close to I in T (S). We then prove that the realization in T (S) of a typical sample path of the random walk on (Mod(S), µ) stays close to a geodesic ray which contains infinitely many such subsegments. Since the quasi-axis of Φn in C(S) passes close to x0 , the contraction property implies that the translation axis of Φn in T (S) has to pass close to these subsegments, and hence close to the basepoint y0 (we call this a lifting argument). This implies that the translation length of Φn in T (S) grows linearly fast, at a speed equal to the drift of the realization of the random walk in T (S), as required. Our lifting argument is presented in a more abstract setting, see Theorem 2.6 for a precise statement. We require having two actions of a group G on both a metric space Y and a hyperbolic metric space X, with a coarsely G-equivariant map from Y to X, such that geodesics in Y map to unparameterized quasigeodesics in X. Typical geodesics in Y are required to contain infinitely many subsegments satisfying the above contraction property. Under such assumptions, if typical elements of G act with a translation axis in Y , then the translation length in Y of the element obtained at time n of the random walk on G grows linearly fast, with speed equal to the drift of the realization of the random walk in Y . Similarly, the group Out(FN ) acts both on Culler–Vogtmann’s outer space CVN , and on the free factor complex F FN , whose hyperbolicity was established by Bestvina and Feighn [6]. Again, the logarithm of the stretching factor of the automorphism Φn obtained at time n of the process is equal to the translation length of Φn in outer space, equipped with the (asymmetric) Lipschitz metric. We give in Section 4.3 a similar – though more technical – condition ensuring that a folding path in outer space satisfies the above contraction property, and prove that typical folding paths in CVN contain infinitely many such subsegments. Theorem 0.4 then follows from the same general criterion established in Section 2. Structure of the paper. The paper is organized as follows. In Section 1, we review properties of random walks on groups acting on hyperbolic spaces, which mainly come from the work of Calegari–Maher [9] and Maher–Tiozzo [37]. In Section 2, we state our general criterion for making the lifting argument possible. We check in Section 3 that typical Teichmüller geodesics in T (S) contain infinitely many subsegments that have the required contraction property, and we use this to derive Theorem 0.2. We check in Section 4 that typical folding lines in outer space contain infinitely many subsegments 6 having the required contraction property, and we use this to derive Theorem 0.4. Acknowledgements. We would like to thank Ursula Hamenstädt for discussions during the Young Geometric Group Theory IV meeting held in Spa in January 2015, regarding contraction properties of folding lines in outer space. We also thank the anonymous referees for their careful reading of the paper and their valuable suggestions. The authors acknowledge support from ANR-11-BS01-013, from the Institut Universitaire de France (FD) and from the Lebesgue Center of Mathematics (CH). 1 1.1 Random walks on groups acting on hyperbolic spaces Random walks on groups: background and notations General notations. Given a probability measure µ on a group G, the (right) random walk on G with respect to the measure µ is the Markov chain on G whose initial distribution is the Dirac measure at the identity element, with transition probabilities p(x, y) := µ(x−1 y). The step space for the random walk is the product probability space ∗ ∗ Ω := (GN , µ⊗N ). The position of the random walk at time n is given from its position g0 = e at time 0 by successive multiplications on the right of independent µ-distributed increments si , i.e. gn = s1 . . . sn . We equip the path space P := GN with the σ-algebra generated by the cylinders {g ∈ P|gi = g} for all i ∈ N and all g ∈ G, and the probability measure P induced by the map (s1 , s2 , . . . ) 7→ (g0 , g1 , g2 , . . . ). Elements of the path space P are called sample paths of the random walk. We will also need to work with the space P := GZ of bilateral paths g := (gn )n∈Z corresponding to bilateral sequences of independent µ-distributed increments (sn )n∈Z by the formula gn = gn−1 sn , with g0 = e. We let Ω := (GZ , µ⊗Z ), and we equip P with the probability measure P induced by the map (sn )n∈Z 7→ (gn )n∈Z . We denote by µ̌ the probability measure on G defined by µ̌(g) := µ(g −1 ) for all g ∈ G, and by (P̌, P̌) the corresponding path space. Then there is a natural isomorphism between (P, P) and the product space (P̌, P̌) ⊗ (P, P), mapping a bilateral path (gn )n∈Z to the pair of unilateral paths ((g−n )n≥0 , (gn )n≥0 ) (note that both paths are initialized by g0 = e). The Bernoulli shift σ, defined in Ω by σ((sn )n∈Z ) := (sn+1 )n∈Z , induces an ergodic transformation U on the space of bilateral paths which satisfies (U k .g)n = gk−1 gn+k for all k, n ∈ Z. Moment and drift. Assume now that G acts by isometries on a metric space (X, dX ), and let x0 ∈ X. We say that a probability measure µ on G has finite first moment with respect to dX if Z dX (x0 , g.x0 )dµ(g) < +∞. G 7 We say that µ has finite second moment with respect to dX if Z dX (x0 , g.x0 )2 dµ(g) < +∞. G It follows from Kingman’s subadditive ergodic theorem [34] that if µ has finite first moment with respect to dX , then for P-a.e. sample path of the random walk on (G, µ), the limit 1 lim dX (x0 , gn .x0 ) n→+∞ n exists. It is called the drift of the random walk on (G, µ) with respect to the metric dX . 1.2 General definitions in coarse geometry Given two metric spaces X and Y , and a constant K ∈ R, a K-quasi-isometric embedding from X to Y is a map f : X → Y such that for all x, x0 ∈ X, one has 1 dX (x, x0 ) − K ≤ dY (f (x), f (x0 )) ≤ KdX (x, x0 ) + K. K A K-quasigeodesic in X is a K-quasi-isometric embedding from an interval in R to X. A K-unparameterized quasigeodesic is a map τ 0 : I 0 → X, where I 0 ⊆ R is an interval, such that there exists an interval I ⊆ R and a non-decreasing homeomorphism θ : I → I 0 such that τ 0 ◦ θ is a K-quasigeodesic. 1.3 Background on Gromov hyperbolic spaces Let (X, dX ) be a metric space, and let x0 ∈ X be some basepoint. For all x, y ∈ X, the Gromov product of x and y with respect to x0 is defined as 1 (x|y)x0 := (dX (x0 , x) + dX (x0 , y) − dX (x, y)). 2 A metric space X is Gromov hyperbolic if there exists a constant δ ≥ 0 such that for all x, y, z, x0 ∈ X, one has (x|y)x0 ≥ min{(x|z)x0 , (y|z)x0 } − δ. When X is geodesic, hyperbolicity of X is equivalent to a thin triangles condition: there exists δ 0 ≥ 0 such that for every geodesic triangle ∆ in X, any side of ∆ is contained in the δ 0 -neighborhood of the union of the other two sides. The smallest such δ 0 is then called the hyperbolicity constant of X. Let X be a Gromov hyperbolic metric space. A sequence (xn )n∈N ∈ X N converges to infinity if the Gromov product (xn |xm )x0 goes to +∞ as n and m both go to +∞. Two sequences (xn )n∈N and (yn )n∈N that both converge to infinity are equivalent if the Gromov product (xn |ym )x0 goes to +∞ as n and m go to +∞. It follows from the hyperbolicity of (X, d) that this is indeed an equivalence relation. The Gromov boundary 8 ∂∞ X is defined to be the collection of equivalence classes of sequences that converge to infinity. An isometry φ of X is loxodromic if for all x ∈ X, the orbit map Z → X n 7→ φn .x is a quasi-isometric embedding. Given K > 0, we say that a line γ : R → X is a Kquasi-axis for φ if γ is a K-quasigeodesic, and there exists T ∈ R such that for all t ∈ R and all k ∈ Z, one has dX (φk .γ(t), γ(t + kT )) ≤ K. We note that there exists K, only depending on the hyperbolicity constant of X, such that all loxodromic isometries of X have a K-quasi-axis in X. Any loxodromic isometry has exactly two fixed points in ∂∞ X and acts with north-south dynamics on X ∪ ∂∞ X. 1.4 Random walks on groups acting on Gromov hyperbolic spaces In this section, we review work by Calegari–Maher [9], further developed by Maher– Tiozzo [37], concerning random walks on groups acting by isometries on Gromov hyperbolic spaces (these extend previous work of Kaimanovich [29] who considered the case of proper actions on proper hyperbolic spaces). We will not always seek for optimal assumptions on the measure µ, we refer to [37] for more precise statements, see also Remark 2.7 below. Let X be a Gromov hyperbolic space, and let G be a countable group acting on X by isometries. A probability measure on G is then called nonelementary (for the action on X) if the subsemigroup of G generated by its support contains a pair of loxodromic elements with disjoint pairs of fixed points in the Gromov boundary of X. Theorem 1.1. (Convergence to the boundary) (Calegari–Maher [9, Theorem 5.34], Maher–Tiozzo [37, Theorem 1.1]) Let G be a countable group that acts by isometries on a separable Gromov hyperbolic space X, and let µ be a nonelementary probability measure on G. Then for any x0 ∈ X, and P-a.e. sample path Φ := (Φn )n∈N of the random walk on (G, µ), the sequence (Φn .x0 )n∈N converges to a point bnd(Φ) ∈ ∂∞ X. Theorem 1.2. (Positive drift) (Calegari–Maher [9, Theorem 5.34], Maher–Tiozzo [37, Theorem 1.2]) Let G be a countable group which acts by isometries on a separable Gromov hyperbolic metric space (X, dX ), and let µ be a nonelementary probability measure on G with finite first moment with respect to dX . Then there exists L > 0 such that for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), one has lim n→+∞ 1 dX (x0 , Φn .x0 ) = L. n As recalled above, the existence of the limit in Theorem 1.2 is an application of Kingman’s subadditive ergodic theorem and only requires that µ has finite first moment with respect to dX (without any assumption on X, in particular X need not be hyperbolic). 9 The hard part of Theorem 1.2 is to prove positivity of L, for which hyperbolicity of X and nonelementarity of µ are crucial. Theorem 1.3. (Sublinear tracking by quasi-geodesic rays) (Maher–Tiozzo [37, Theorem 1.3]) Let G be a countable group which acts by isometries on a separable Gromov hyperbolic geodesic metric space (X, dX ), and let µ be a nonelementary probability measure on G with finite first moment with respect to dX . Let L > 0 be the drift of the random walk on (G, µ) with respect to dX . Then for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (G, µ), there exists a quasi-geodesic ray τ : R+ → X limiting at bnd(Φ) such that 1 lim dX (Φn .x0 , τ (Ln)) = 0. n→+∞ n Theorem 1.4. (Random isometries are loxodromic) (Calegari–Maher [9, Theorem 5.35], Maher–Tiozzo [37, Theorem 1.4]) Let G be a countable group which acts by isometries on a separable Gromov hyperbolic metric space X, and let µ be a nonelementary probability measure on G with finite support. Then for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), there exists n0 ∈ N such that for all n ≥ n0 , the element Φn acts loxodromically on X. Proof. Calegari and Maher prove in [9, Theorem 5.35] that the probability that Φn be loxodromic converges exponentially fast to 1. Theorem 1.4 then follows by applying the Borel–Cantelli lemma. Given κ > 0, a quasigeodesic segment γ : J → X (where J ⊆ R is a segment), and a quasigeodesic γ 0 : I → X (where I ⊆ R is an interval), we say that γ 0 crosses γ up to distance κ if there exists an increasing map θ : J → I such that dX (γ(t), γ 0 (θ(t))) ≤ κ for all t ∈ J (notice in particular that the orientations of γ and γ 0 are required to be the same on their “overlap”). The following proposition is a slight elaboration on Theorem 1.4. Proposition 1.5. (Axes of random isometries pass close to the basepoint) Let G be a group acting by isometries on a separable geodesic Gromov hyperbolic space X, and let µ be a nonelementary probability measure on G with finite support. For all K > 0, there exists κ > 0 such that for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), and all  ∈ (0, 1), there exists n0 ∈ N such that for all n ≥ n0 , the element Φn acts loxodromically on X, and for all geodesic segments γ from x0 to Φn .x0 , every K-quasi-axis of Φn crosses a subsegment of γ of length at least (1 − )dX (x0 , Φn .x0 ) up to distance κ. We will now prove Proposition 1.5. Our proof follows the same argumentation as in recent work by Taylor–Tiozzo [46], and is based on the following fact. Proposition 1.6. Let G be a countable group acting by isometries on a separable Gromov hyperbolic metric space (X, dX ), let x0 ∈ X, and let µ be a nonelementary probability measure on G with finite support. Then for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), and all  > 0, there exists n0 ∈ N such that for all n ≥ n0 , we have (Φn .x0 |Φ−1 n .x0 )x0 ≤ n. 10 The idea behind the proof of Proposition 1.6 is that the first increments in the product Φn are independent from the first increments in the product Φ−1 n . Hyperbolicity of X then forces the geodesic segments [x0 , Φn .x0 ] and [x0 , Φ−1 .x ] 0 to diverge rapidly with n high probability. To make this precise, we will use the following two lemmas. These basically follow from Maher–Tiozzo’s work. Lemma 1.7. (Maher–Tiozzo [37, Lemmas 5.9 and 5.11]) Let G be a countable group acting by isometries on a separable Gromov hyperbolic space (X, dX ), and let µ be a nonelementary probability measure on G with finite support. Let LX > 0 denote the drift of the random walk on (G, µ) with respect to dX . Then for all  > 0, there exists C > 0 such that for all n ∈ N, one has   LX .n n P (Φn .x0 |Φb 2 c .x0 )x0 ≥ ≥ 1 − e−Cn 4 and   LX .n −1 n P (Φ−1 .x |Φ Φ ≥ .x ) ≥ 1 − e−Cn 0 n n−b 2 c 0 x0 n 4 and  P (Φ−1 c .x0 |Φb n c .x0 )x0 n Φn−b n 2 2 LX .n ≤ 5  ≥ 1 − e−Cn . Proof. This is a version of [37, Lemmas 5.9 and 5.11], where basically one only replaces m = b n2 c by b n 2 c (all arguments work in the same way). As noticed in Maher–Tiozzo’s paper, the exponential rate follows from exponential decay of shadows, which was already established in [36]. The first two estimates play symmetric roles and correspond to [37, Lemma 5.11], and the third one corresponds to [37, Lemma 5.9]. Lemma 1.8. (Maher–Tiozzo [37, Lemma 5.9]) Let X be a Gromov hyperbolic space, and let x0 ∈ X. Then there exist κ1 , κ2 > 0 that only depend on the hyperbolicity constant of X such that for all a, b, c, d ∈ X, if there exists A > 0 such that (a|b)x0 ≥ A, (c|d)x0 ≥ A and (a|c)x0 ≤ A − κ1 , then |(a|c)x0 − (b|d)x0 | ≤ κ2 . Proof of Proposition 1.6. For all  > 0, there exists C > 0 such that all three events considered in Lemma 1.7 happen simultaneously with probability greater than 1 − e−Cn . −1 −1 Applying Lemma 1.8 to a := Φb n c .x0 , b := Φn .x0 , c := Φn Φn−b n c .x0 and d := Φn .x0 , 2 2 .n with A = LX 4 , one deduces that for all  > 0, there exists C > 0 such that for all n ∈ N, one has  −Cn P (Φn .x0 |Φ−1 . n .x0 )x0 ≤ n ≥ 1 − e Proposition 1.6 then follows by applying the Borel–Cantelli Lemma. Proof of Proposition 1.5. Consider a K-quasi-axis for Φ, and y0 a closest point to x0 on it. By hyperbolicity and the minimising property for y0 , all geodesic segments [Φ−1 .x0 , Φ−1 .y0 ], [Φ−1 .y0 , Φ.y0 ] and [Φ.y0 Φ.x0 ] remain κ0 = κ0 (K, δ)-close to any geodesic [Φ−1 .x0 , Φ.x0 ]. Since the lengths of [Φ−1 .x0 , Φ−1 .y0 ], [x0 , y0 ] and [Φx0 , Φy0 ] are within 11 κ1 (K, δ) of (Φ.x0 |Φ−1 .x0 )x0 , we know that for every K > 0, there exists κ = κ(K, δ) (where δ is the hyperbolicity constant of X) such that all K-quasi-axes of loxodromic isometries Φ cross the central subsegment of length dX (x0 , Φ.x0 ) − 2(Φ.x0 |Φ−1 .x0 )x0 of any geodesic segment [x0 , Φ.x0 ], up to distance κ. Proposition 1.5 is therefore a consequence of Theorem 1.2 (Positive drift) and Proposition 1.6, together with the fact that P-a.s., the element Φn is loxodromic for all n large enough (Theorem 1.4). Given  > 0, a quasi-geodesic ray γ : R+ → X, and n ∈ N, we denote by t,γ 1 (n) (resp. t,γ (n)) the infimum of all real numbers such that d (γ(0), γ(t (n))) ≥ L 1 X X .n 2 (resp. dX (γ(0), γ(t2 (n))) ≥ (1 − )LX .n). Combining Theorem 1.1 (convergence to the boundary), Theorem 1.3 (sublinear tracking) and Proposition 1.5 (axes of random isometries pass close to the basepoint), one can establish the following. Details of the proof are left to the reader. Proposition 1.9. Let X be a separable geodesic Gromov hyperbolic metric space, with hyperbolicity constant δ. For all K > 0, the exists κ = κ(K, δ), such that the following holds. Let G be a group acting by isometries on X, and let µ be a nonelementary probability measure on G with finite support. Let LX > 0 denote the drift of the random walk on (G, µ) with respect to dX . Then for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (G, µ), all  > 0, and all K-quasi-geodesic rays γ : R+ → X converging to bnd(Φ), there exists n0 ∈ N such that for all n ≥ n0 , any K-quasi-axis of Φn crosses ,γ γ|[t,γ up to distance κ. 1 (n),t2 (n)] 2 Translation lengths of random elements: abstract setting The goal of this section is to provide the general setting for the lifting argument we wish to use for proving our spectral theorems. We will establish sufficient conditions under which, if G is a group acting by isometries on two metric spaces Y and X, where X is a hyperbolic coarse Lipschitz G-equivariant image of Y , then elements obtained along a typical sample path of the random walk on G have linearly growing translation length in Y . The main result of this section is Theorem 2.6 below. Let G be a countable group acting by isometries on a (possibly asymmetric) geodesic metric space (Y, dY ) (i.e. dY need not be symmetric, but it satisfies the triangle inequality, as well as the separation property that dY (a, b) = 0 if and only if a = b). We denote by dsym the symmetrized version of the metric, defined by letting dsym Y Y (x, y) := dY (x, y) + dY (y, x) for all x, y ∈ Y . A bordification of Y is a Hausdorff, second-countable topological space Y such that Y is homeomorphic to an open dense subset of Y , and such that the G-action on Y extends to an action on Y by homeomorphisms. We let ∂Y := Y r Y . From now on, when we talk about a metric G-space (Y, dY ), we assume that the G-action is by isometries, but we do not necessarily assume that the metric dY is symmetric. Note that one can talk about geodesics in a non-symetric metric space (Y, dY ): a geodesic is a map γ : I → Y where I is an interval in R, for which, for all a < b in I, dY (γ(a), γ(b)) = b − a. 12 Definition 2.1. (Boundary convergence) Let G be a countable group, let Y be a metric G-space which admits a bordification Y . Let µ be a probability measure on G. We say that (G, µ) is Y -boundary converging if for P-a.e. bilateral sample path Φ := (Φn )n∈Z of the random walk on (G, µ), there exist bnd− (Φ), bnd+ (Φ) ∈ ∂Y such that for all y0 ∈ Y , the sequence (Φn .y0 )n∈N converges to bnd+ (Φ), and the sequence (Φ−n .y0 )n∈N converges to bnd− (Φ). Definition 2.2. (Hyperbolic electrification) A hyperbolic G-electrification is a pair of G-spaces (Y, X), together with a map π : Y → X, such that • the space (Y, dY ) is a (possibly asymmetric) geodesic metric G-space, and • the space (X, dX ) is a separable Gromov hyperbolic (symmetric) geodesic metric G-space, and • there exists K1 > 0 such that for all x, y ∈ Y and all g ∈ G, we have dX (gπ(x), π(gx)) ≤ K1 (we say that π is coarsely G-equivariant) and dX (π(x), π(y)) ≤ K1 dY (x, y) + K1 (we say that π is coarsely Lipschitz), and • there exists K2 > 0 such that for all x, y ∈ Y , there exists a geodesic segment from x to y whose π-image in X is a K2 -unparameterized quasigeodesic. We fix from now on a hyperbolic G-electrification (Y, X), a map π : Y → X, and real numbers K1 , K2 > 0 given by the above definition. We also assume that Y admits a bordification Y . From now on, nonelementarity of a probability measure on G will always be meant with respect to the G-action on X. Given an interval I ⊆ R, we say that a geodesic γ : I → Y is electric if π ◦ γ : I → X is a K2 -unparameterized quasigeodesic (the last property in the above definition states the existence of an electric geodesic between any two points in Y ). We denote by Γel Y the collection of all electric geodesics in Y . We let κ = κ(K2 , δ) be the constant given by Proposition 1.9. Definition 2.3. (Contraction) Let γ : R → Y be an electric geodesic line, and let y ∈ Y be a point that lies on the image of γ. Given B, D > 0, we say that γ is (B, D)contracting at y if the following holds. Let a ∈ R be such that γ(a) = y, and let b ∈ R be the infimum of all real numbers such that π ◦ γ([a, b]) has dX -diameter at least B. Then for all geodesic lines γ 0 : R → Y , if π ◦ γ 0 crosses π ◦ γ|[a,b] up to distance κ, then there exists a0 ∈ R such that dY (γ 0 (a0 ), γ(a)) ≤ D. The following definition was first given in [1, Definition 6.13]: roughly speaking, a point y ∈ Y is high if for all y 0 ∈ Y , it is shorter to go from y to y 0 than to go from y 0 to y. 13 Definition 2.4. (Highness) Given M > 0, we say that a point y ∈ Y is M -high if for 0 0 all y 0 ∈ Y , we have dsym Y (y , y) ≤ M dY (y , y). We define the density θ(A) of a subset A ⊆ Z as   |A ∩ [−n, 0]| |A ∩ [0, n]| θ(A) := min lim inf . , lim inf n→+∞ n→+∞ n n The following definition is inspired by [48, Theorem 6]. Definition 2.5. (Contracting pencils of geodesics) Let G be a countable group, let (Y, X) be a hyperbolic G-electrification, and let y0 ∈ Y . Let µ be a nonelementary probability measure on G, such that the random walk on (G, µ) is Y -boundary converging. Denote by ν̌ and ν the hitting measures on ∂Y for the random walks on (G, µ̌) and (G, µ). We say that (G, µ) has contracting pencils of geodesics if there exists a G-equivariant map P : ∂Y × ∂Y → P(Γel Y ) which associates to any pair of points (x, y) ∈ ∂Y a set of electric geodesics in Y joining x to y, so that • the map D : ∂Y × ∂Y (x, y) → R 7→ supγ∈P (x,y) dsym Y (y0 , γ(R)) is measurable and ν̌ ⊗ ν-a.e. finite, and • for all θ ∈ (0, 1), there exist B, D, M > 0 such that for P-a.e. bilateral sample path Φ := (Φn )n∈Z of the random walk on (G, µ), and all geodesic lines γ ∈ P (bnd− (Φ), bnd+ (Φ)), the set of integers k ∈ Z such that for all dsym Y -closest-point projections z of Φk .y0 to γ, the point z is M -high, and γ is (B, D)-contracting at z, has density at least θ. Let Φ ∈ G be a loxodromic isometry of X. We say that Φ has an electric translation axis in Y if there exists a Φ-invariant electric geodesic line γ : R → Y such that for all y ∈ γ(R), the line γ restricts to a geodesic segment from Φ.y to y, and dY (Φ.y, y) = inf dY (Φ.y 0 , y 0 ). 0 y ∈Y We then denote by lY (Φ) the translation length of Φ, defined as lY (Φ) := dY (Φ.y, y) for all y lying on the image of an electric axis of Φ. We notice that the translation length of Φ is well-defined, i.e. it does not depend on the choice of an axis for Φ, and in addition, for all y ∈ Y , we have lY (Φ) ≤ dY (Φ.y, y). Notice that with the above definition, the action of Φ on an electric translation axis is by translation in the negative direction. Therefore, with our definitions, any electric geodesic axis for Φ in Y projects (as an oriented line) to a K2 -quasi-axis for Φ−1 in X. These conventions may sound a bit awkward, however they will turn out to be quite natural in the context where Y is either the Teichmüller space of a surface or Culler– Vogtmann’s outer space, because the natural actions of either Mod(S) or Out(FN ) on these spaces are right actions (so that one needs to pass to inverses when considering left actions). 14 Theorem 2.6. Let G be a countable group, and let (Y, X) be a G-hyperbolic electrification, with a basepoint y0 ∈ Y . Assume that Y admits a bordification Y . Let µ be a nonelementary probability measure on G with finite support. Assume that all elements of G acting loxodromically on X have an electric translation axis in Y . If the random walk on (G, µ) is Y -boundary converging and has contracting pencils of geodesics, then for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), we have lY (Φ−1 n ) = LY , n→+∞ n lim where LY denotes the drift of the random walk on (G, µ) with respect to dY . Remark 2.7. Since the support of µ is assumed to be finite, it follows from Theorem 1.4 that for P-a.e. sample path (Φn )n∈N of the random walk on (G, µ), eventually all elements Φn act as loxodromic isometries of X, which justifies that it makes sense to write lY (Φ−1 n ) in Theorem 2.6. Combining Benoist–Quint’s arguments from [4] with Maher–Tiozzo’s results on random walks on nonproper hyperbolic spaces [37], one can actually show that Proposition 1.5 remains valid if µ is only assumed to have finite second moment with respect to dX (see [28, Section 2]). Therefore, Theorem 2.6 remains true if µ is only assumed to have finite second moment with respect to dY . If the support of µ is only assumed to have finite first moment with respect to dY , then we don’t know whether infinitely many Φn fail to satisfy the conclusion of Proposition 1.5 (or even fail to be loxodromic), however the conclusion of Theorem 2.6 remains valid if one takes the limit along the subsequence corresponding to those integers n for which Φn satisfies the conclusion of Proposition 1.5. Therefore, Theorem 2.6 remains valid in this situation if one replaces the limit by a limsup. The general idea of the proof of Theorem 2.6 is the following, it is illustrated in Figure 1. Typical sample paths of the realization in Y of the random walk on (G, µ) stay close to a (random) geodesic ray τY . Using the existence of contracting pencils of geodesics, for all n ∈ N, we can find a contracting subsegment J of the image of τY , whose distance to y0 is small compared to LY .n (Step 1 in the proof below). Using the properties of random walks on isometry groups of hyperbolic spaces recalled in Section 1, one can also arrange so that every quasi-axis of Φn in X crosses π(J) up to distance κ (Step 2). The contraction property implies that Φ−1 n has an electric axis in Y that passes at small distance from y0 (Step 3). This is enough to deduce that the translation length of Φ−1 n in Y is close to LY .n, as required (Step 4). Proof of Theorem 2.6. By Theorem 1.2, the drift LX of the realization of the random walk on X (with respect to the metric dX ) is positive. Since π is coarsely G-equivariant and coarsely Lipschitz, this implies that the drift LY of the realization of the random walk on Y (with respect to the metric dY ) is also positive. Let K1 ≥ 1 be a constant (provided by the definition of a hyperbolic G-electrification) such that for all x, y ∈ Y , we have dX (π(x), π(y)) ≤ K1 dY (x, y) + K1 . 15 Figure 1: The situation in the proof of Theorem 2.6. Let K2 ≥ 1 be a constant such that for all electric geodesics γ : I → Y (where I ⊆ R is an interval), we have that π ◦ γ : I → X is an unparameterized K2 -quasigeodesic. Let  > 0. We fix a basepoint y0 ∈ Y , and let x0 := π(y0 ). Since (G, µ) is Y -boundary converging, we have that for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (G, µ), the sequence (Φn .y0 )n∈N converges to a point bndY (Φ) ∈ ∂Y , and by Theorem 1.1, the sequence (Φn .x0 )n∈N converges to a point bndX (Φ) ∈ ∂∞ X. Let θ := 78 , and let B, D > 0 and M ≥ 1 be the corresponding constants provided by the definition of having contracting pencils of geodesics (Definition 2.5). Claim. For P-a.e. sample path Φ := (Φn )n∈N of the random walk on (G, µ), there exists an integer n0 ∈ N and an electric geodesic ray τY : R+ → Y , such that for all n ≥ n0 , the element Φn acts as a loxodromic isometry of X, and letting τX := π ◦ τY , we have (i) |dY (y0 , Φn .y0 ) − LY .n| ≤ LY .n, and (ii) dsym Y (Φn .y0 , τY (LY .n)) ≤ min{LY ,LX } .n 6K1 (iii) |dX (τX (0), Φn .x0 ) − LX .n| ≤ LX .n 12 , − 1, and and sym (iv) there are at least 6n 7 integers k ∈ {0, . . . , n} such that for all dY -closest-point projections z of Φk .y0 to τY , the point z is M -high, and τY is (B, D)-contracting at z, and (v) every K2 -quasi-axis of Φn in X crosses τX ([t1 (n), t2 (n)]) up to distance κ, where κ = κ(K2 , δ) is the constant provided by Proposition 1.9, and t1 (n) (resp. t2 (n)) is the infimum of all real numbers such that dX (τX (0), τX (t1 (n))) ≥ LX .n (resp. dX (τX (0), τX (t2 (n))) ≥ (1 − )LX .n). 16 Proof of the Claim. Let us explain how to choose τY . For P-a.e. bilateral path Φ of the random walk on (G, µ), Tiozzo produces in [48, Theorem 6] a bi-infinite geodesic between the boundary limit points bnd− (Φ) and bnd+ (Φ), in the pencil of geodesics D(bnd− (Φ), bnd+ (Φ)), from which the random walk has sublinear tracking. We choose τY to be a positive ray in this geodesic. Property (ii) follows from the sublinear tracking, and property (iv) follows from the properties of our pencil of geodesics. Properties (i) and (iii) come from the definition of the drifts of the random walk on Y and X. Property (v) is guaranteed by Proposition 1.9. We let Φ := (Φn )n∈N be a sample path that satisfies the conclusion of the above claim. By choosing n0 sufficiently large, we may also assume that B + K1 ≤ LX .n0 , that D ≤ LY .n0 , that dsym Y (y0 , τY (0)) ≤ LY .n0 and that 2K1 ≤ LX .n0 . Step 1: We show the existence of a point y close to y0 at which τY is contracting. Let n ∈ N be such that n ≥ n0 . Then the interval [5n, 6n] contains an integer n2 fulfilling the Property (iv) above. In addition, by Property (ii), we have dsym Y (Φn2 .y0 , τY (LY .n2 )) ≤ min{LY , LX }.n2 − 1, 6K1 so in particular we have dsym Y (Φn2 .y0 , τY (LY .n2 )) ≤ LY .n2 ≤ LY .n. 6 Let y be a dsym Y -closest point projection of Φn2 .y0 to τY . By definition of a closest-point projection, we necessarily have dsym Y (Φn2 .y0 , y) ≤ LY .n. It then follows from the triangle inequality that dsym Y (y, τY (LY .n2 )) ≤ 2LY .n, so y ∈ τY ([3LY .n, 8LY .n]). We now let a ∈ R be such that τY (a) = y, and let b ≥ a be the infimum of all real numbers such that τX ([a, b]) has diameter at least B. We let J := [a, b]. By definition for all  > 0, τX ([a, b − ]) has diameter at most B, thus τX (J) has diameter at most B + K1 . Step 2: We show that every K2 -quasi-axis of Φn in X crosses (τX )|J up to distance κ. 17 Recall from above that dsym Y (Φn2 .y0 , τY (LY .n2 )) ≤ LX .n2 − 1, 6K1 and hence by definition of a closest-point projection dsym Y (Φn2 .y0 , y) ≤ LX .n2 − 1. 6K1 Using the fact that π is coarsely Lipschitz and that dY ≤ dsym Y , we get that dX (π(Φn2 .y0 ), π(y)) ≤ LX .n. By Property (iii) above, we also have |dX (Φn2 .x0 , τX (0)) − LX .n2 | ≤ LX .n2 LX .n ≤ . 12 2 Finally, since π is coarsely G-equivariant, we have dX (π(Φn2 .y0 ), Φn2 .x0 ) ≤ K1 ≤ LX .n . 2 Together with the triangle inequality, the above three inequalities imply that |dX (π(y), τX (0)) − LX .n2 | ≤ 2LX .n. As B + K1 ≤ LX .n, and τX (J) has diameter at most B + K1 , this implies that |dX (π(y 0 ), τX (0)) − LX .n2 | ≤ 3LX .n for all y 0 ∈ τY (J). By Property (v) above, we know in addition that every K2 -quasiaxis of Φn in X crosses τX ([t1 (n), t2 (n)]) up to distance κ (where t1 (n) and t2 (n) are defined as in Property (v)). Assuming that  > 0 had been chosen small enough such that 9 ≤ 1−, we get that every K2 -quasi-axis of Φn in X crosses (τX )|J up to distance κ. Step 3: We show that the element Φ−1 n has an electric axis in Y that passes close to y0 . By hypothesis, all elements of G acting loxodromically on X have an electric axis. In particular, the element Φ−1 n has an axis in Y , whose projection to X is a K2 -quasiaxis for Φn , and hence crosses (τX )|J up to distance κ. Since τY is (B, D)-contracting at y (Property (iv)), there exists a point y 0 lying on the axis of Φ−1 n in Y such that sym 0 0 dY (y , y) ≤ D, and hence dY (y, y ) ≤ M D since y is M -high. Hence we have sym sym sym 0 0 dsym Y (y0 , y ) ≤ dY (y0 , τY (0)) + dY (τY (0), y) + dY (y, y ) sym sym ≤ dY (y0 , τY (0)) + M dY (τY (0), y) + dY (y, y 0 ) ≤ dsym Y (y0 , τY (0)) + 8M LY .n + M D ≤ 10M LY .n. 18 Notice here that the second inequality uses the fact that y is M -high. Step 4: End of the proof. sym 0 By G-invariance of dsym Y , we also have dY (Φn .y0 , Φn .y ) ≤ 10M LY .n. Using the tri0 0 angle inequality, we get dY (y , Φn .y ) ≥ dY (y0 , Φn .y0 ) − 20M LY .n. Property (i) above then implies that dY (y 0 , Φn .y 0 ) ≥ (1 − 21M )LY .n. Since y 0 belongs to the translation 1 −1 axis of Φ−1 n , we obtain n lY (Φn ) ≥ (1 − 21M )LY . As  > 0 was chosen arbitrary small, and since the above inequality holds for all sufficiently large n ∈ N, we have lim inf n→+∞ 1 lY (Φ−1 n ) ≥ LY . n Notice in addition that for all n ∈ N, we have 1 1 lY (Φ−1 dY (y0 , Φn .y0 ), n )≤ n n and hence 1 lim sup lY (Φ−1 n ) ≤ LY . n n→+∞ This completes the proof of Theorem 2.6. 3 Spectral theorem for random walks on Mod(S) Let S be a closed, connected, oriented, hyperbolic surface. We will now prove our spectral theorem for random walks on Mod(S). We fix a hyperbolic metric ρ on S. We refer to Section 3.1 below for definitions. Theorem 3.1. Let S be a closed, connected, oriented, hyperbolic surface, and let µ be a nonelementary probability measure on Mod(S) with finite support. Then for P-a.e. sample path (Φn )n∈N of the random walk on (Mod(S), µ), we have lim n→+∞ 1 log(λ(Φn )) = LT , n where λ(Φn ) denotes the stretching factor of the pseudo-Anosov mapping class Φn , and LT > 0 is the drift of the random walk on (Mod(S), µ) with respect to the Teichmüller metric. Remark 3.2. We recall that when µ has finite support, then with probability equal to 1, all Φn are eventually pseudo-Anosov, so that the stretching factor λ(Φn ) is well-defined (notice also that in this context, we have λ(Φn ) = λ(Φ−1 n ), as their logarithms are the translation lenghts in Teichmüller space equipped with the Teichmüller metric which is symmetric). Theorem 3.1 will be established by applying Theorem 2.6 to the Mod(S)hyperbolic electrification made of the Teichmüller space T (S) and the curve graph C(S). In view of Remark 2.7, Theorem 3.1 remains valid if µ is only assumed to have finite 19 second moment with respect to the Teichmüller metric dT . However, if µ is only assumed to have finite first moment with respect to dT , then one has to replace the limit by a limsup in the statement. The section is organized as follows. In Section 3.1, we record the necessary background on mapping class groups. In Section 3.2, we establish a sufficient criterion for a subsegment of a Teichmüller geodesic in T (S) to have the required contraction property: namely, we prove that if the projection of this subsegment to the curve graph C(S) makes progress, then this subsegment is contracting. We prove in Section 3.3 that typical Teichmüller geodesics contain infinitely many such subsegments. This will enable us to conclude the proof of Theorem 3.1 in Section 3.4 by applying Theorem 2.6. 3.1 Background on mapping class groups We review some rather classical background on mapping class groups of surfaces. The familiar reader may skip directly to Section 3.2. Let S be a closed, connected, oriented, hyperbolic surface. The mapping class group Mod(S) is the group of isotopy classes of orientation-preserving diffeomorphisms of S. The group Mod(S) acts on the Teichmüller space T (S), and on the curve graph C(S) of the surface, whose definitions we now recall. The Teichmüller space T (S) is the space of isotopy classes of conformal structures on S. It can be equipped with several metrics; we review the definition of the Teichmüller metric. Given x, y ∈ T (S), the Teichmüller distance dT (x, y) is defined as 1 dT (x, y) := inff log K(f ), 2 where the infimum is taken over all quasiconformal diffeomorphisms f : (S, x) → (S, y) that are isotopic to the identity, and where K(f ) denotes the quasiconformal dilatation of f . (We note that the Teichmüller metric is a true metric which satisfies the symmetry property.) Teichmüller space, equipped with the Teichmüller metric, is a uniquely geodesic space, and Mod(S) acts by isometries on (T (S), dT ). A simple closed curve c on S is essential if it does not bound a disk on S. We denote by S the collection of all isotopy classes of essential simple closed curves on S. Given c ∈ S and x ∈ T (S), we denote by lx (c) the smallest length of a curve in the isotopy class c, measured in the unique hyperbolic metric in the conformal class x. Thurston has defined a compactification of T (S) by taking the closure of the map T (S) → PRS x 7→ (lx (c))c∈S and he identified the boundary with the space PMF of projective measured foliations on S (up to Whitehead equivalence), see [16, Exposé 8]. The curve graph C(S) is the graph whose vertices are the isotopy classes of essential simple closed curves on S, two vertices being joined by an edge if there are disjoint representatives in the isotopy classes of the corresponding curves. We denote by dC the 20 simplicial metric on C(S). Masur and Minsky have proved in [39] that (C(S), dC ) is Gromov hyperbolic. There is a coarsely Mod(S)-equivariant, coarsely Lipschitz map π : T (S) → C(S), mapping every point in T (S) to one of the essential simple closed curves whose length is minimal in S. It also follows from the work of Masur and Minsky [39] that projections of Teichmüller geodesics to the curve graph of S are uniform unparameterized quasi-geodesics. We sum up the above discussion in the following proposition, with the terminology from Section 2. Proposition 3.3. Let S be a closed, connected, oriented, hyperbolic surface. Then (T (S), C(S)) is a hyperbolic Mod(S)-electrification. Teichmüller geodesics are electric. A measured foliation in PMF is arational if it does not contain any simple closed curve on S. It is uniquely ergodic if in addition, every foliation in PMF with the same topological support as F is equal to F . We denote by UE the subspace of PMF consisting of uniquely ergodic arational foliations, and by ∆ the diagonal subset of UE × UE. Given F, F 0 ∈ U E × UE r ∆, there is a parameterized Teichmüller line γ : R → T (S), unique up to precomposition by a translation of R, which is a geodesic line for the Teichmüller metric, and such that limt→−∞ γ(t) = F and limt→+∞ γ(t) = F 0 ([20], see also the exposition in [44, §2.5], for instance). We will usually denote its image by [F, F 0 ], which one may still name Teichmüller line, though unparameterized. Similarly, a point x0 ∈ T (S) together with a foliation F ∈ UE determine a unique Teichmüller ray. In addition, given a pair (F, F 0 ) ∈ UE × UE r ∆, and a sequence ((Fn , Fn0 ))n∈N ∈ (UE × UE r ∆)N that converges to (F, F 0 ), the Teichmüller lines [Fn , Fn0 ] admit parameterizations γn : R → T (S) (as geodesics) that converge uniformly on compact sets to a geodesic parameterization γ : R → T (S) of [F, F 0 ]. An element Φ ∈ Mod(S) is pseudo-Anosov if there exists a pair of transverse measured foliations (F s , µs ) and (F u , µu ) on S, together with a real number λ(Φ) > 1, such that 1 Φ.(F s , µs ) = (F s , µs ) λ(Φ) and Φ.(F u , µu ) = (F u , λ(Φ)µu ). The coefficient λ(Φ) is called the stretching factor of Φ. It was shown by Thurston [47] that Φ is pseudo-Anosov if and only if no power Φk with k 6= 0, (k ∈ N) fixes the isotopy class of an essential simple closed curve on S. The stretching factor λ(Φ) is also equal to the exponential growth rate of the length of any essential simple closed curve on S under iteration of Φ. Pseudo-Anosov mapping classes are precisely the elements of Mod(S) which act as loxodromic isometries of C(S), see [39]. When acting on T (S), every pseudo-Anosov element Φ ∈ Mod(S) preserves the Teichmüller line γ from F s to F u , and acts on γ by translation, with dT -translation length equal to log λ(Φ). With our terminology from the previous section, pseudo-Anosov mapping classes have electric translation axes. 21 We finally review work by Kaimanovich–Masur [30] concerning random walks on Mod(S). We note that a subgroup H of Mod(S) is nonelementary with respect to its action on C(S) if and only if it contains two pseudo-Anosov elements that generate a nonabelian free subgroup of H. Equivalently [40], the subgroup H is nonelementary if H is not virtually cyclic, and H does not virtually preserve the conjugacy class of any essential simple closed curve on S. As in the previous sections, we say that a probability measure on Mod(S) is nonelementary if the semigroup generated by its support is a nonelementary subgroup of Mod(S). Kaimanovich and Masur have proved the following theorem. Theorem 3.4. (Kaimanovich–Masur [30, Theorem 2.2.4]) Let µ be a nonelementary probability measure on Mod(S). Then for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (Mod(S), µ), there exists a point bnd(Φ) ∈ UE such that for all y0 ∈ T (S), the sequence (Φn .y0 )n∈N converges to bnd(Φ). The hitting measure ν defined by setting ν(S) := P(bnd(Φ) ∈ S) for all Borel subsets S ⊆ PMF is nonatomic. With the terminology from Section 2, the random walk on Mod(S) is T (S)-boundary converging. Kaimanovich–Masur’s theorem implies that for P-almost every bilateral sample path Φ := (Φn )n∈Z of the random walk on (Mod(S), µ), denoting by bnd− (Φ) (resp. bnd+ (Φ)) the limit of the sequence (Φ−n .y0 )n≥0 (resp. (Φn .y0 )n≥0 ), then we have (bnd− (Φ), bnd+ (Φ)) ∈ UE × U E r ∆. In particular, the Teichmüller geodesic line [bnd− (Φ), bnd+ (Φ)] is P-a.s. well-defined. 3.2 Teichmüller geodesics that make progress are contracting. The goal of the next three sections is to prove Theorem 3.1, by applying Theorem 2.6 to the hyperbolic Mod(S)-electrification (T (S), C(S)). The key point is to prove that (Mod(S), µ) has contracting pencils of geodesics. Proposition 3.6 below will be crucial for establishing the contraction property. Let δ be the hyperbolicity constant of C(S), let K2 > 0 be a constant such that π-images of Teichmüller geodesics are K2 -unparameterized quasigeodesics in C(S), and let κ = κ(K2 , δ) be the constant provided by Proposition 1.9. The notion of (B, D)contracting geodesics will be understood with respect to this value of κ. Definition 3.5. (Progress for Teichmüller geodesics) Given B0 , C > 0, a Teichmüller line γ : R → T (S), and a point y ∈ T (S) lying on the image of γ, we say that γ is (C; B0 )-progressing at y if the π-image in C(S) of the subsegment of γ of dT -length C starting at y has diameter at least B0 . Proposition 3.6. There exists a constant B0 > 0 such that for all B ≥ B0 and all C > 0, there exists D > 0, such that for all Teichmüller lines γ : R → T (S) and all y ∈ T (S) lying on the image of γ, if γ is (C; B)-progressing at y, then γ is (B, D)contracting at y. 22 The proof of Proposition 3.6 relies on the following result, due to Dowdall–Duchin– Masur [14, Theorem A], which is stated there in terms of the -thick proportion of I. However, the important fact in the proof of [14, Theorem A] is that I makes definite progress when projected to the curve graph C(S). Proposition 3.7. (Dowdall–Duchin–Masur [14, Theorem A]) For all κ > 0, there exist B1 , B2 > 0 such that the following holds. For all C > 0, there exists D0 = D0 (C, κ) > 0 such that if [x, y] is a Teichmüller segment that contains a subsegment I of dT -length C such that diamC(S) (π(I)) ≥ B1 , then for all z ∈ T (S), if π([x, z]) crosses π(I) up to distance κ, then [x, z] contains a subsegment J at dT -Hausdorff distance at most D0 from a subsegment I 0 ⊆ I, such that π(J) has diameter at least diamC(S) (π(I)) − B2 . Sketch of proof. The proof follows the arguments from the proof of [14, Theorem A]. We only sketch the argument, and refer the reader to [14] for further details. Let τ ≥ κ be a constant so that every K2 -quasi-triangle in C(S) is τ -thin. By choosing B1 > 0 large enough, we can ensure that there exists w ∈ I such that dC (π(w), π(x)) ≥ 2τ + 6, and dC (π(w), π([y, z])) ≥ 2τ + 6. For each such w, there exists u ∈ [x, z] so that dC (π(w), π(u)) ≤ τ . Dowdall–Duchin–Masur then prove that dV (w, u) is bounded (with a bound only depending on C) for all proper subsurfaces V S (where dV denotes the distance between the projections in the curve complex of V ). Using the distance formula [14, Proposition 2.4] relating the distance in the Teichmüller space to the sum of the distances between the projections to the curve complexes of the various subsurfaces of S, this implies that dT (u, w) is bounded. The claim follows. Proof of Proposition 3.6. We let κ = κ(K2 , δ) be the constant provided by Proposition 1.9. Let B0 , C > 0, and let γ : [a, b] → T (S) be a Teichmüller segment of length C such that π ◦ γ([a, b]) has diameter at least B0 in C(S). Let γ 0 : R → T (S) be a Teichmüller line whose projection to C(S) crosses π ◦ γ up to distance κ. This implies that for all t ∈ [a, b], there exists t0 ∈ R such that dC (π(γ 0 (t0 )), π(γ(t))) ≤ κ. There exists κ0 = κ0 (K2 , δ) such that for t2 ∈ R sufficiently large, the π-image of the Teichmüller segment [γ(a), γ 0 (t2 )] crosses π ◦ γ up to distance κ0 . Let B1 = B1 (κ + κ0 ) ≥ B1 (κ0 ) and B2 = B2 (κ0 ) be the constants provided by Proposition 3.7. Assume that B0 ≥ B1 + B2 . Proposition 3.7 implies that [γ(a), γ 0 (t2 )] contains a subsegment J at Hausdorff distance at most D0 = D0 (C, κ0 ) from a subsegment of γ([a, b]), whose projection π(J) has diameter at least B1 in C(S). In particular, the segment J has diameter at most 2D0 + C in T (S). In addition, there exists t1 ∈ R (chosen sufficiently close to −∞) such that the π-image of [γ 0 (t1 ), γ 0 (t2 )] crosses the π-image of J up to distance κ + κ0 . Let D00 := D0 (2D0 + C, κ + κ0 ). Applying Proposition 3.7 again to the segment [γ 0 (t1 ), γ 0 (t2 )], we get that dT (γ 0 , J) ≤ D00 , so dT (γ 0 , γ([a, b])) ≤ D0 + D00 and hence dT (γ(a), γ 0 (R)) ≤ C + D0 + D00 . 3.3 Typical geodesics are infinitely often progressing. We now fix once and for all the constant B0 provided by Proposition 3.6. We also fix a basepoint y0 ∈ T (S). 23 Proposition 3.8. Let µ be a nonelementary probability measure on Mod(S). Then for all θ ∈ (0, 1), there exists C > 0 such that for P-a.e. bilateral sample path Φ := (Φn )n∈N of the random walk on (Mod(S), µ), the set of integers k ∈ Z such that all subsegments of [bnd− (Φ), bnd+ (Φ)] of length C in T (S) starting at a closest-point projection of Φk .y0 have a π-image of diameter at least B0 in C(S), has density at least θ. Before proving Proposition 3.8, we first establish a general lemma. Lemma 3.9. Let X be a topological space, and let f : X → R be a map. If f is locally bounded from above, then f is bounded from above by an upper semicontinuous map. Proof. Let f : X → R, and assume that f is locally bounded from above. Let fb : X → R be the map defined by fb(x) := lim sup f (x0 ) < +∞. x0 →x Then fb satisfies the required conditions. Lemma 3.10. There exists an upper semicontinuous map C : UE × UE r ∆ → R such that for ν̌⊗ν-a.e. (F − , F + ) ∈ UE ×UE r∆, all segments of dT -length C(F − , F + ) starting at a closest-point projection of y0 to the Teichmüller line [F − , F + ] have a π-image of diameter at least B0 in C(S). Proof. Let C 0 be the map defined on UE × U E r ∆, by sending any pair (F − , F + ) to the infimum of all real numbers C > 0 such that all segments of dT -length C starting at a closest-point projection of y0 to the Teichmüller line joining F − to F + , project under π to a region of C(S) of diameter at least B0 . In view of Lemma 3.9, it is enough to check that C 0 is finite and locally bounded from above. Assume towards a contradiction that it is not. Then we can find (F − , F + ) ∈ UE × UE r ∆, and a sequence ((Fn− , Fn+ ))n∈N ∈ (UE × UE r ∆)N converging to (F − , F + ), such that for all n ∈ N, we have C 0 ((Fn− , Fn+ )) > n. The Teichmüller geodesics [Fn− , Fn+ ] converge uniformly on compact sets to [F − , F + ] (for good choices of parameterizations). For all n ∈ N, let xn be a closest-point projection of y0 to [Fn− , Fn+ ] at which [Fn− , Fn+ ] is not (n; B0 )-progressing. Then up to passing to a subsequence, we can assume that the sequence (xn )n∈N converges to a point x ∈ T (S), and x is a closest-point projection of y0 to the Teichmüller line from F − to F + . Let K1 > 0 be such that for all y, y 0 ∈ T (S), we have dC (π(y), π(y 0 )) ≤ K1 dT (y, y 0 ) + K1 . Let z ∈ T (S) be a point lying on [F − , F + ], to the right of x, such that dC (π(x), π(z)) ≥ B0 +4K1 . Let (zn )n∈N ∈ T (S)N be a sequence converging to z, with zn lying on [Fn− , Fn+ ] for all n ∈ N. For all n ∈ N, since [Fn− , Fn+ ] is not (n; B0 )-progressing at xn , we have dC (π(xn ), π(zn )) ≤ B0 for all sufficiently large n ∈ N. We choose n ∈ N sufficiently large so that we also have dT (xn , x) < 12 and dT (zn , z) < 21 . Then dC (π(xn ), π(x)) < 2K1 and dC (π(zn ), π(z)) < 2K1 . These inequalities lead to a contradiction. 24 Proof of Proposition 3.8. Let C be the map provided by Lemma 3.10, and let Ψ: P → R − Φ 7→ C(bnd (Φ), bnd+ (Φ)) (where we recall that P denotes the space of bilateral sample paths of the random walk on (Mod(S), µ)). Lemma 3.10 implies that Ψ is a Borel map and P-a.e. finite. Let U be the transformation of P induced by the Bernoulli shift on the space of bilateral sequences − of increments. Then for all k ∈ Z and all Φ ∈ P, we have bnd− (U k .Φ) = Φ−1 k bnd (Φ) + k and bnd+ (U k .Φ) = Φ−1 k bnd (Φ). Hence all subsegments of dT -length Ψ(U .Φ) starting − at a closest-point projection of Φk .y0 to the Teichmüller geodesic [bnd (Φ), bnd+ (Φ)] project under π to a region of diameter at most B0 in C(S). As Ψ is a Borel map and P-a.e. finite, we can choose M > 0 such that P(Ψ(Φ) ≤ M ) > θ. An application of Birkhoff’s ergodic theorem to the ergodic transformation U then implies that for P-a.e. bilateral sample path Φ := (Φn )n∈Z of the random walk on (Mod(S), µ), if γ denotes the Teichmüller line joining bnd− (Φ) to bnd+ (Φ) (which almost surely exists because the hitting measures are nonatomic and concentrated on UE), then the density of times k ∈ Z such that all subsegments of γ of dT -length M starting at a closest-point projection of Φk .y0 has a π-image of diameter at least B0 in C(S), is at least θ. Proposition 3.11. Let µ be a nonelementary probability measure on Mod(S). Then for all θ ∈ (0, 1), there exist B, D > 0 such that for P-a.e. bilateral sample path Φ := (Φn )n∈Z of the random walk on (Mod(S), µ), the set of integers k ∈ Z such that [bnd− (Φ), bnd+ (Φ)] is (B, D)-contracting at all dT -closest-point projections of Φk .y0 to [bnd− (Φ), bnd+ (Φ)], has density at least θ. Proof. This follows from Propositions 3.6 and 3.8. 3.4 End of the proof of the spectral theorem Proof of Theorem 3.1. We will check that (Mod(S), µ) satisfies the hypotheses in Theorem 2.6. The pair (T (S), C(S)) is a hyperbolic Mod(S)-electrification (Proposition 3.3). All elements of Mod(S) acting loxodromically on C(S) (i.e. pseudo-Anosov mapping classes) have an electric translation axis in T (S). In addition (Mod(S), µ) is T (S)boundary converging (Theorem 3.4). The first item in the definition of contracting pencils of geodesics (Definition 2.5) was established by Tiozzo [48, Lemma 19] for the collection of Teichmüller lines between any two transverse measured foliations. In view of Proposition 3.11, the second item in this definition is also satisfied by this collection of lines (notice that all points in T (S) are 2-high since the Teichmüller metric on T (S) is symmetric). Therefore, Theorem 2.6 applies to (Mod(S), µ). Since the translation length of any pseudo-Anosov mapping class Φ on T (S) is equal to the logarithm of its 25 stretching factor, and λ(Φ) = λ(Φ−1 ), we get that for P-a.e. sample path of the random walk on (Mod(S), µ), we have 1 log λ(Φn ) = LT , n→+∞ n lim as claimed. 4 Spectral theorem for random walks on Out(FN ) Let N ≥ 3, let FN be a finitely generated free group of rank N , and let Out(FN ) be its outer automorphism group. The goal of this section is to prove the following spectral theorem for random walks on Out(FN ). We refer to Section 4.1 below for definitions. Theorem 4.1. Let µ be a nonelementary probability measure on Out(FN ) with finite support. Then for P-a.e. sample path (Φn )n∈N of the random walk on (Out(FN ), µ), we have 1 lim log(λ(Φ−1 n )) = L, n→+∞ n −1 where λ(Φ−1 n ) is the stretching factor of the automorphism Φn , and L is the drift of the random walk with respect to the Lipschitz metric on outer space. Remark 4.2. We recall that when µ has finite support, then with probability equal to 1, eventually all automorphisms Φn are fully irreducible, and therefore the stretching factor λ(Φ−1 n ) is well-defined. Theorem 4.1 will be proved by applying Theorem 2.6 to the hyperbolic Out(FN )-electrification made of Culler–Vogtmann’s outer space CVN and the free factor graph F FN . Again, in view of Remark 2.7, if µ is only assumed to have finite second moment with respect to the Lipschitz metric on CVN , then Theorem 4.1 remains true. If µ is only assumed to have finite first moment with respect to the Lipschitz metric on CVN , then one has to replace the limit by a limsup. Remark 4.3. In the context of automorphisms of free groups, Kapovich also defined in [31] a notion of generic stretching factor λA (Φ) of an outer automorphism Φ ∈ Out(FN ) with respect to a free basis A of FN , which measures the growth under Φ of an element obtained along a typical trajectory of the nonbacktracking simple random walk on FN with respect to the generating set A. Generic stretching factors of random outer automorphisms of FN also satisfy the same spectral property as the one established in Theorem 4.1, namely 1 lim log(λA (Φ−1 n )) = L, n→+∞ n as soon as the measure µ has finite first moment with respect to the Lipschitz metric on CVN (the proof of this fact does not require to apply the arguments from the present paper: this follows from [32, Theorem 1.6], for instance). The section is organized as follows. In Section 4.1, we review background on Out(FN ) and spaces it acts on. We then establish one more property we will need concerning the 26 geometry of the free factor graph in Section 4.2. The next three sections are devoted to proving Theorem 4.1 by applying Theorem 2.6 to the actions of Out(FN ) on Culler– Vogtmann’s outer space, and on the free factor graph. In Section 4.3, we establish a sufficient condition for a subsegment of a folding line to satisfy the required contraction property, and we then check in Section 4.4 that typical folding lines contain infinitely many subsegments satisying this condition. The proof of Theorem 4.1 is completed in Section 4.5. 4.1 General background on Out(FN ) The group Out(FN ) acts on Culler–Vogtmann’s outer space CVN and on the free factor graph F FN . We start by reviewing background about these spaces. Outer space and its metric. Outer space CVN is the collection of equivalence classes of free, simplicial, minimal and isometric actions of FN on simplicial metric trees [13]. Two trees T and T 0 are equivalent whenever there is an FN -equivariant homothety from T to T 0 . Unparameterized outer space cvN is defined by considering trees up to FN equivariant isometry, instead of homothety. The group Out(FN ) acts on CVN and cvN on the right by precomposing the actions (one can also consider a left action by setting Φ.T := T.Φ−1 ). Outer space may be viewed as a simplicial complex with missing faces. The simplex ∆(S) of a tree S is the subspace of CVN obtained by making all edge lengths of S vary (we allow some edges to have length 0, as soon as the corresponding collapse map does not change the isotopy type of the graph). Given  > 0, the -thick part CVN is defined as the subspace of CVN made of those trees T ∈ CVN such that the volume one representative of T /FN contains no embedded loop of length smaller than . Given a tree T ∈ CVN and an element g ∈ FN , the translation length of g in T is defined as ||g||T := inf dT (x, gx). x∈T Culler–Morgan have compactified outer space [12] by taking the closure of the image of the map i : CVN → PRFN g 7→ (||g||T )g∈FN in the projective space PRFN . This compactification CVN was identified by Cohen–Lustig [10] and Bestvina–Feighn [5] (see also [25]) with the space of equivariant homothety classes of minimal, very small FN -trees (i.e. trees whose arc stabilizers are either trivial, or maximally cyclic, and whose tripod stabilizers are trivial). Outer space is equipped with a natural asymmetric metric for which the action of Out(FN ) is by isometries: the distance dCVN (T, T 0 ) between two trees T, T 0 ∈ CVN is defined as the logarithm of the infimal Lipschitz constant of an FN -equivariant map from the covolume 1 representative of T to the covolume 1 representative of T 0 , see [17]. White has proved (see [17, Proposition 3.15] or [2, Proposition 2.3]) that for all FN -trees 27 T ,T 0 ∈ CVN , we also have dCVN (T, T 0 ) = log ||g||T 0 , g∈FN r{e} ||g||T sup where T and T 0 are identified with their covolume 1 representatives. Furthermore, the supremum is achieved for an element g ∈ FN r {e} that belongs to a finite set Cand(T ) only depending on T , made of primitive elements of FN , called candidates in T , whose translation length in the covolume 1 representative of T is at most 4. The Lipschitz metric on CVN is not symmetric. However, the following result follows from work by Algom-Kfir and Bestvina. Proposition 4.4. (Algom-Kfir–Bestvina [3]) For all  > 0, there exists M > 0 such that all trees in CVN are M -high. The Lipschitz metric on outer space is geodesic: any two points in outer space are joined by a (nonunique) geodesic segment, that can be obtained [17, Theorem 5.6] as a concatenation of a segment contained in a simplex, and a greedy folding path, as defined in the following paragraph. Folding lines. Let T and T 0 be two R-trees. A morphism from T to T 0 is a map f : T → T 0 such that every segment of T can be subdivided into finitely many subsegments, in restriction to which f is an isometry. A direction at a point x ∈ T is a connected component of T r {x}. A train track structure on T is a partition of the set of directions at each point x ∈ T . Elements of the partition are called gates at x. A pair (d, d0 ) of directions at x is illegal if d and d0 belong to the same gate. Any morphism f : T → T 0 determines a train track structure on T , two directions d, d0 at a point x ∈ T being in the same class of the partition if there are intervals (x, a] ⊆ d and (x, b] ⊆ d0 which have the same f -image. Given T ∈ cvN and T 0 ∈ cvN , and a map f : T → T 0 which is linear on edges of T , we say that f is optimal if it realizes the infimal Lipschitz constant of an FN -equivariant map from T to T 0 , and there are at least two gates at every point in T for the train track structure defined by f . An optimal folding path in unprojectivized outer space is a continuous map γ : I → cvN , where I is an interval of R, together with a collection of FN -equivariant optimal morphisms ft,t0 : γ(t) → γ(t0 ) for all t < t0 in I, such that for all t < t0 < t00 , one has ft,t00 = ft0 ,t00 ◦ ft,t0 . We say that γ is a greedy folding path if in addition, for all t0 ∈ R, there exists  > 0 such that for all t ∈ [t0 , t0 + ], the tree γ(t) is obtained from γ(t0 ) by folding small segments of length  at all illegal turns of γ(t). The projection to CVN of a (greedy) folding path in cvN will again be called a (greedy) folding path. A train track structure on a tree T ∈ CVN is recurrent if for every edge e ⊆ T , there exists a legal segment in T that crosses e, whose projection to T /FN is a (possibly non-embedded) loop. Bestvina and Reynolds have proved in [8, Lemma 6.9] that for all T ∈ CVN , and all simplices ∆ ⊆ CVN , there exists a tree T0 ∈ ∆ such that there exists an optimal morphism from a tree homothetic to T0 to T , and any such morphism induces a recurrent train track structure on T0 . As noticed in [8, Remark 6.10], this continues 28 to hold if T ∈ ∂CVN r ∆. In this situation, we will say that T0 is fully recurrent with respect to T . The free factor graph and its Gromov boundary. A free factor of FN is a subgroup A ⊆ FN such that there exists a subgroup B ⊆ FN with FN = A ∗ B. The free factor graph F FN is the graph whose vertices are the conjugacy classes of proper free factors of FN , two vertices [A] and [B] being joined by an edge if there are representatives A and B in their conjugacy classes so that either A ( B or B ( A. The group Out(FN ) has a natural left action on F FN . The free factor graph was proven to be Gromov hyperbolic by Bestvina and Feighn [6]. One can define a coarsely Out(FN )equivariant (with respect to the left actions on both CVN and F FN ), coarsely Lipschitz map π : CVN → F FN , by sending any tree T to the conjugacy class of a proper free factor that is elliptic in a simplicial tree obtained by equivariantly collapsing some edges in T to points. Bestvina and Feighn also proved that π-images in F FN of greedy folding lines in CVN are uniform unparameterized quasi-geodesics. The Gromov boundary of the free factor graph was described by Bestvina–Reynolds [8] and independently Hamenstädt [23]. Given a tree T ∈ CVN and a subgroup A ⊆ FN which does not fix any point in T , there exists a unique minimal nonempty A-invariant subtree of T , which is called the A-minimal subtree of T . A tree T ∈ ∂CVN is arational if no proper free factor of FN is elliptic in T , and all proper free factors of FN act freely and simplicially on their minimal subtree in T . We denote by AT the subspace of CVN made of arational FN -trees. Theorem 4.5. (Bestvina–Reynolds [8], Hamenstädt [23]) There exist M ∈ R and a map ψ : CVN → F FN ∪ ∂∞ F FN which agrees with π on CVN , and such that • for all T ∈ AT , and all sequences (Tn )n∈N ∈ CVNN converging to T , the sequence (π(Tn ))n∈N converges to ψ(T ), and • [8, Lemma 6.16] for all T ∈ CVN rAT , and all greedy folding lines γ : R+ → CVN , if γ(t) converges to T as t goes to +∞, then ψ(γ(t)) eventually stays at distance at most M from ψ(T ). We will fix once and for all a map ψ provided by Theorem 4.5. We denote by UE the subspace of CVN consisting of trees T ∈ AT such that ψ −1 ({ψ(T )}) = T – this notation is used to mimic the corresponding notation for uniquely ergodic foliations in the mapping class group case; more accurately, trees in UE are precisely the uniquely ergometric trees in the sense of [11]. We denote by ∆ the diagonal subset of UE × UE. We mention the following property of greedy folding paths, which follows from work by Bestvina–Reynolds. Proposition 4.6. (Bestvina–Reynolds [8, Corollaries 6.7 and 6.8, Lemma 6.11]) Let (T, T 0 ) ∈ UE × UE r ∆. Let ((Tn , Tn0 ))n∈N ∈ (UE × UE r ∆)N be a sequence that converges 29 to (T, T 0 ). For all n ∈ N, let γn : R → CVN be a greedy folding line from Tn to Tn0 . Then there exist translations τn : R → R such that the sequence (γn ◦ τn )n∈N converges uniformly on compact sets to a greedy folding line from T to T 0 . Projections to folding paths. In their proof of the hyperbolicity of the free factor graph, Bestvina and Feighn introduced a notion of projection of a free factor to a greedy folding path in the following way. Let I ⊆ R be an interval, and let γ : I → CVN be a greedy folding path in CVN determined by a morphism f . The morphism f determines a train track structure on all trees γ(t) with t ∈ I. Given a primitive element g ∈ FN , we let rightγ (g) be the supremum of all times t ∈ I such that the axis of g in the covolume 1 representative of γ(t) contains a segment of length MBF that does not contain any legal subsegment of length 3, where MBF is a fixed constant that only depends on the rank N of the free group, see [6, Section 6]. As follows from the work by Bestvina–Feighn, the projection satisfies the following property. Lemma 4.7. (Bestvina–Feighn [6]) There exists K0 > 0 (only depending on the rank N of the free group) such that the following holds. Let γ : I → CVN be a greedy folding path, let g ∈ FN be a primitive element, and let t, t0 ≥ rightγ (g) with t ≤ t0 . Then dCVN (γ(t), γ(t0 )) − log ||g||γ(t0 ) ≤ K0 . ||g||γ(t) Proof. Let σ be a loop obtained by projecting a fundamental domain of the axis of g to the volume 1 representative of the quotient graph γ(t)/FN . Then all subsegments of length MBF in σ contain a legal subsegment of length 3 for the train-track structure k j 1 on γ(t). It follows from the estimate in [6, Lemma 4.4] that σ contains MBF ||g||γ(t) legal segments of length 3, whose middle subsegments of length 1 all grow exponentially fast with maximal speed along the folding path γ, and never get identified with one another during the folding procedure: exponential growth is stated in [6, Corollary 4.8], and the fact that the segments never get identified also follows from Bestvina–Feighn’s arguments because these segments grow faster than their extremities get folded. The required estimate follows from this observation. Given a tree S ∈ CVN , we let rightγ (S) := sup rightγ (g). g∈Cand(S) We then let Prγ (S) := γ(rightγ (S)) (we will sometimes also use the notation PrI (S) when it turns out to be more convenient). The following contraction property for projections of greedy folding paths to F FN was established by Bestvina and Feighn. This is stated in [6] with a slightly different notion of projection (namely, the left projection instead of the right projection), however it follows from [6, Proposition 6.4] that this other projection lies at bounded distance apart from the one we consider. 30 Lemma 4.8. (Bestvina–Feighn [6, Proposition 7.2]) There exists D1 > 0 such that for all greedy folding paths γ : I → CVN (where I ⊆ R is an interval), and all H, H 0 ∈ CVN , if dCVN (H, H 0 ) ≤ dCVN (H, Im(γ)), then dF FN (π(Prγ (H)), π(Prγ (H 0 ))) ≤ D1 . The following lemma, due to Dowdall and Taylor, relates the Bestvina–Feighn projection to the closest-point projection in F FN . Given a greedy folding path γ : I → CVN , we should denote by nπ◦γ the closest-point projection to the image of π ◦ γ in F FN . However, this is a priori a subset, and it is sometimes convenient to have chosen a single point in it, thus we rather define nπ◦γ to be the leftmost closest-point projection in the sense that, in the parametrisation of π ◦ γ as a path, it has smaller parameter value among the closest point projections. Lemma 4.9. (Dowdall–Taylor [15, Lemma 4.2]) There exists a constant D2 > 0 such that for any H ∈ CVN , and any greedy folding path γ : I → CVN , we have dF FN (π(Prγ (H)), nπ◦γ (π(H))) ≤ D2 . Fully irreducible automorphisms. An element Φ ∈ Out(FN ) is fully irreducible if no power Φk with k 6= 0 fixes the conjugacy class of a proper free factor of FN . Any fully irreducible automorphism of FN has a well-defined stretching factor λ(Φ), which satisfies that for all primitive elements g ∈ FN , we have p lim n ||Φn (g)|| = λ(Φ), n→+∞ where ||Φn (g)|| denotes the smallest word length of a conjugate of Φn (g), written in some fixed free basis of FN . Bestvina and Feighn have shown [6] that an element Φ ∈ Out(FN ) acts as a loxodromic isometry of F FN if and only if Φ is fully irreducible. Any fully irreducible element Φ ∈ Out(FN ) has a translation axis in CVN , which is a folding line [24]. The amount of translation is equal to log(λ(Φ)). With the terminology from Section 2, all elements in Out(FN ) acting as fully irreducible isometries of F FN have an electric axis. Random walks on Out(FN ). We finally record a result of Namazi–Pettet–Reynolds concerning random walks on Out(FN ). A subgroup H ⊆ Out(FN ) is nonelementary if H contains two fully irreducible automorphisms that generate a free subgroup of Out(FN ): with the terminology from Section 1, this is equivalent to nonelementarity of the Haction on F FN . We say that a probability measure on Out(FN ) is nonelementary if the subsemigroup generated by the support of µ is a nonelementary subgroup of Out(FN ). With the terminology from Section 2, the following theorem asserts that (Out(FN ), µ) is CVN -boundary converging. Theorem 4.10. (Namazi–Pettet–Reynolds [41]) Let µ be a nonelementary probability measure on Out(FN ) with finite first moment with respect to dCVN . Then for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (Out(FN ), µ), and any y0 ∈ CVN , the 31 sequence (Φn .y0 )n∈N converges to a point bnd(Φ) ∈ UE. The hitting measure ν defined by setting ν(S) := P(bnd(Φ) ∈ S) for all measurable subsets S ⊆ ∂CVN is nonatomic. 4.2 More on the geometry of the free factor graph We will need to establish the following proposition concerning the geometry of the projection of folding paths to the free factor graph. We refer to the statement of Theorem 4.5 above for the definition of the map ψ. Proposition 4.11. There exists M > 0 such that for all sufficiently large D > 0, all y0 , y1 ∈ CVN , all trees T ∈ CVN and all sequences (Tn )n∈N ∈ CVNN converging to T , if (π(Tn )|π(y1 ))π(y0 ) ≥ D for all n ∈ N, then (ψ(T )|π(y1 ))π(y0 ) ≥ D − M . Proposition 4.11 follows from Theorem 4.5 in the particular case where all trees in the sequence (Tn )n∈N lie on the image of a greedy folding path in CVN . We need to extend this to arbitrary sequences. Our proof of Proposition 4.11 will make use of yet another Out(FN )-graph, namely the cyclic splitting graph F ZN . This is the graph whose vertices correspond to the splittings of FN as a graph of groups with cyclic (possibly trivial) edge groups, two splittings being joined by an edge if they have a common refinement. Hyperbolicity of F ZN was established by Mann [38], and its geometry was further studied in [27]. There is a coarsely Out(FN )-equivariant map Θ from F ZN to F FN : given any cyclic splitting T of FN , there exists a proper free factor of FN which is elliptic in a tree obtained by equivariantly collapsing some edges of T , and Θ maps T to one of these free factors. We will denote by πZ the natural map from CVN to F ZN . Images in F ZN of greedy folding paths in CVN are uniform unparameterized quasigeodesics [38]. Proof. Let f be an optimal morphism from a tree whose homothety class belongs to the closure ∆(y0 ) of the simplex of y0 , to T . Let (fn )n∈N be a sequence of optimal morphisms which converges to f for the Gromov–Hausdorff topology on morphisms introduced in [21, Section 3.2], such that for all n ∈ N, the map fn is a morphism from a tree yn0 whose homothety class belongs to ∆(y0 ), to Tn . Let γ : R+ → CVN be the greedy folding path determined by f , and for all n ∈ N, let γn : R+ → CVN be the greedy folding path from yn0 to Tn determined by fn . By [21, Proposition 2.4], the folding paths γn converge uniformly on compact sets to γ. There exists a constant M1 > 0, only depending on K2 and the hyperbolicity constant of F FN , such that the following holds. Let y2 ∈ CVN be such that π(y2 ) lies at bounded distance apart from a geodesic segment from π(y0 ) to π(y1 ) in F FN , and dF FN (π(y0 ), π(y2 )) = D − M1 . Then for all n ∈ N, the π-images in F FN of all greedy folding paths γn pass through the M1 -neighborhood U1 of π(y2 ). Recall that greedy folding paths in CVN project to uniform unparameterized quasigeodesics in both complexes F ZN and F FN . Therefore, there exists M2 > 0 (only 32 depending on the hyperbolicity constants of F FN and F ZN ), a bounded neighborhood U2 of π(y2 ) in F FN , and a tree S ∈ CVN whose π-image in F FN lies in U2 , such that for all n ∈ N, one can find a tree Sn lying on the image of γn , whose projection to F ZN lies at distance at most M2 from πZ (S). Let S∞ ∈ CVN be a limit point of the sequence (Sn )n∈N . By [21, Proposition 2.4], the tree S∞ belongs to γ(R+ ∪ {+∞}). Since the sequence (ψZ (Sn ))n∈N is bounded, the tree S∞ is not Z-averse in the sense of [27]. It follows from [27, Proposition 8.8] that there exists M3 > 0 such that the set of reducing Z-splittings of S∞ (defined in [27, Section 5.1]) lies in the M3 -neighborhood U3 of πZ (S) in F ZN , and the image of γ in F ZN meets U3 . The projection of U3 to F FN is a bounded neighborhood of π(y2 ), and the π-image of γ meets this neighborhood. The last item from Theorem 4.5 implies that all points π ◦ γ(t) with t sufficiently large belong to a bounded neighborhood of ψ(T ). The claim follows from these observations. From Proposition 4.11, where one chooses y0 such that π(y0 ) is close to ψ(T ), and y1 such that π(y1 ) belongs to the bounded region of F FN that contains all points π(Tn ), one deduces the following analogue for F FN of [27, Proposition 8.8] (which was established for F ZN there). Corollary 4.12. For all D > 0, there exists M > 0 such that the following holds. Let T ∈ CVN , and let (Tn )n∈N ∈ CVNN be a sequence of trees that converges to T . Assume that all projections π(Tn ) belong to a common region of F FN of diameter D. Then T is not arational, and for all n ∈ N, we have dF FN (π(Tn ), ψ(T )) ≤ M . 4.3 A contraction property for folding lines in outer space Let δ be the hyperbolicity constant of F FN . Let K2 > 0 be a constant such that all π-images of greedy folding lines in CVN are K2 -unparameterized quasigeodesics in F FN , and let κ = κ(K2 , δ) be the constant provided by Proposition 1.9. We now introduce our definition of progress for folding paths in outer space, which will play the same role in our arguments as in the case of mapping class groups in the previous section. This is illustrated in Figure 2. Definition 4.13. (Progress for folding paths) Let (T, T 0 ) ∈ U E × UE r ∆. Let γ : R → CVN be a greedy folding line from T to T 0 , and let S be a tree lying on the image of γ. Given C, A0 , B0 , C0 > 0, we say that γ is (C; A0 , B0 , C0 )-progressing at S if the following holds. Let • Se ∈ CVN be a tree lying to the right of S on the image of γ, satisfying the inequality e ≤ A0 , and dF FN (π(S), π(S)) • R ∈ CVN be a tree such that nπ◦γ (π(R)) is to the right of π(S) and satisfies e nπ◦γ (π(R))) ≥ B0 for all trees Se as above, and dF FN (π(S), 33 Figure 2: Progress for folding paths. • γ 0 : [a, b] → CVN (where [a, b] ⊆ R is a segment) be a greedy folding path from a e to R, where either S 0 = S, e or else S 0 is fully recurrent tree S 0 in the simplex ∆(S) with respect to R. 0 Then for all c ∈ [a, b], if γ 0 ([a, c]) has dsym CVN -diameter at least C, then π ◦ γ ([a, c]) has diameter at least C0 in F FN . Remark 4.14. The above definition of progress implies in particular that the smallest subsegment on the image of γ of dsym CVN -diameter C starting at S has a projection of diameter at least C0 in F FN . This is shown by choosing R to lie sufficiently to the right on the image of γ, and letting γ 0 be a subpath of γ starting at S. We do not know however whether Proposition 4.17 below remains valid if we took the above property as a definition of progress (in other words, we do not know whether the exact analogue of Proposition 3.6 holds in the Out(FN ) context). As recalled in the proof sketch of Proposition 3.7, Dowdall–Duchin–Masur’s proof in the case of mapping class groups uses a distance formula relating the distance in T (S) to the distances in curve graphs associated to various subsurfaces of S. However, to our knowledge, finding an analogous distance formula in the Out(FN ) context is still an open question. The goal of the present section is to prove that greedy folding paths which make progress are high and satisfy the contraction property from Definition 2.3: this is the content of Propositions 4.15 and 4.17 below. We first prove that progress implies highness, using an argument of Dowdall–Taylor [15, Lemma 4.3]. Proposition 4.15. Let A0 , B0 , C0 > 0. There exists α > 0 such that if C0 > α, then the following holds. For all C > 0, there exists M > 0 such that for all (T, T 0 ) ∈ UE × UE r ∆, all greedy folding lines γ : R → CVN from T to T 0 , and all S ∈ CVN lying on the image of γ, if γ is (C; A0 , B0 , C0 )-progressing at S, then S is M -high. 34 Proof. In view of Proposition 4.4, it is enough to prove that S belongs to the thick part CVN for some value of  > 0 only depending on C. Let  < exp(−C). Assume towards a contradiction that S ∈ / CVN . Then there exists g ∈ FN whose translation length is at most  in the covolume one representative of S. By assumption (see Remark 4.14 above), there exists a tree S 0 lying on the image of γ such that dCVN (S, S 0 ) ≤ C and dF FN (π(S), π(S 0 )) ≥ C0 . If C0 has been chosen sufficiently large, then g cannot have translation length smaller than 1 in the covolume one representative of S 0 . However, this implies that ||g||S 0 1 dCVN (S, S 0 ) ≥ log ≥ log > C, ||g||S  a contradiction. We will now prove that progress implies contraction. The following lemma is an exercise in hyperbolic metric spaces; we recall that nτ and nτ 0 denote the leftmost closest-point projections to the corresponding quasigeodesics. Lemma 4.16. For all K, K2 > 0, there exists κ0 = κ0 (K2 , K, δ) such that for all y ∈ F FN , and all K2 -quasigeodesic segments τ : [a, b] → F FN and τ 0 : [a0 , b0 ] → F FN , if dF FN (τ (a), τ 0 (a0 )) ≤ K and dF FN (τ (b), τ 0 (b0 )) ≤ K, then dF FN (nτ (y), nτ 0 (y)) ≤ κ0 . Proposition 4.17. There exist α0 , β0 , γ0 such that for all A0 ≥ α0 , all B0 ≥ β0 and all C0 ≥ γ0 , there exists B > 0 such that the following holds. For all C > 0, there exists D > 0 such that for all (T, T 0 ) ∈ UE × UE r ∆, all greedy folding lines γ : R → CVN from T to T 0 , and all S ∈ CVN lying on the image of γ, if γ is (C; A0 , B0 , C0 )-progressing at S, then γ is (B, D)-contracting at S. Proof. The situation in the following proof is illustrated on Figure 3. Let K1 > 0 be such that dF FN (π(x), π(y)) ≤ K1 dCVN (x, y) + K1 for all x, y ∈ CVN . We let B := B0 + K1 + 2κ. Let a ∈ R be such that γ(a) = S, and let b ≥ a be the infimum of all real numbers b0 such that π ◦ γ([a, b0 ]) has dF FN -diameter at least B: this implies in particular that π ◦ γ([a, b]) has dF FN -diameter at least B0 + 2κ. We let I := [a, b], and let S 0 := γ(b). Let γ 0 : R → CVN be a geodesic line, whose π-image in F FN crosses π ◦ γ|I up to distance κ. It is enough to prove that the image of γ 0 in CVN passes at bounded dCVN -distance of γ(I). Step 1: Estimates coming from progress. Since π ◦ γ 0 crosses π ◦ γ|I up to distance κ, there exists a point U ∈ CVN lying on the image of γ 0 such that dF FN (π(U ), π(S)) ≤ κ. So dF FN (nπ◦γ|I (π(U )), π(S)) ≤ 2κ. Lemma 4.9 then implies that dF FN (π(PrI (U )), π(S)) ≤ 2κ + D2 . Let U 0 be the point lying to the right of U on the image of γ 0 , and such that dCVN (U, U 0 ) = dCVN (U, γ(I)). Let S0 be a point lying on γ(I) such that dCVN (U, U 0 ) = dCVN (U, S0 ). By Lemma 4.8, we have dF FN (π(PrI (U )), π(PrI (S0 ))) ≤ D1 . In view of 35 Lemma 4.9, we also have dF FN (π(S0 ), π(PrI (S0 ))) ≤ D2 . Using the triangle inequality, this implies that dF FN (π(S0 ), π(S)) ≤ 2κ + D1 + 2D2 . Both trees S and S0 lie on the image of γ (and S0 lies to the right of S). Assume that C0 ≥ 2κ + D1 + 2D2 . Since γ is (C; A0 , B0 , C0 )-progressing at S, by choosing the point R from Definition 4.13 to lie sufficiently far apart from S (see Remark 4.14), this implies that dsym CVN (S0 , S) ≤ C. (1) By Lemma 4.8, we also have dF FN (π(PrI (U 0 )), π(PrI (U ))) ≤ D1 . The triangle inequality then implies that dF FN (π(PrI (U 0 )), π(S)) ≤ 2κ + D1 + D2 . As above, this implies that 0 dsym CVN (S, PrI (U )) ≤ C. (2) Since π◦γ 0 crosses π◦γ|I up to distance κ, there exists a point U 00 lying on the image of γ 0 , such that dF FN (π(U 00 ), π(S 0 )) ≤ κ. In particular, we have dF FN (π(S), nπ◦γ (π(U 00 ))) ≥ 0 0 ^ B − 2κ = B0 . Let f be a morphism from a tree Pr I (U ) in the simplex ∆(PrI (U )) 00 00 0 ^ to U 00 , where Pr I (U ) is fully recurrent with respect to U , and let γ be the greedy ^ folding path determined by f . Notice that dF F (π(PrI (U )), π(Pr I (U ))) ≤ K0 for some N uniform constant K0 . Applying Lemma 4.16 to τ := π ◦ γ|I and τ 0 := π ◦ γ 00 with K := 2κ + D1 + D2 + K0 , we get dF FN (nπ◦γ|I (π(U 0 )), nπ◦γ 00 (π(U 0 ))) ≤ κ0 . Therefore, it follows from Lemma 4.9 that dF FN (π(PrI (U 0 )), π(Prγ 00 (U 0 ))) ≤ κ0 + 2D2 . We also recall from the previous paragraph that dF FN (π(S), π(PrI (U 0 ))) ≤ 2κ + D1 + D2 . Assume that A0 ≥ 2κ + D1 + D2 . Since γ is (C; A0 , B0 , C0 )-progressing at S, the same argument as in 0 ^ the proof of Proposition 4.15 implies that both PrI (U 0 ) and Pr I (U ) are thick, so there exists K > 0 (only depending on C and on the rank N of the free group) such that 0 ^0 dsym CVN (PrI (U ), PrI (U )) ≤ K. (3) 0 00 0 0 ^ Both trees Pr I (U ) and Prγ 00 (U ) lie on the image of γ (with Prγ 00 (U ) to the right of 0 0 ^ Pr I (U )). Assume that C0 ≥ κ + 2D2 . Since γ is (C; A0 , B0 , C0 )-progressing at S, we also have 0 ^0 (4) dsym CVN (PrI (U ), Prγ 00 (U )) ≤ C. Using Equations (3) and (4) and the triangle inequality, we obtain 0 0 dsym CVN (PrI (U ), Prγ 00 (U )) ≤ K + C. (5) Step 2: Estimates coming from the definition of the projection to a folding path. We will now prove that the length of the concatenation of the paths from U 0 to Prγ 00 (U 0 ) and from Prγ 00 (U 0 ) to U 00 represented in plain green lines on Figure 3 is close to being equal to the distance from U 0 to U 00 (this is the meaning of Equation (8) below). This will imply in the next step of the proof that the total green length (both plain and 36 dotted) is close to being equal to the distance from U to U 00 , and therefore U 0 has to be close to the image of γ. Let α ∈ FN be a candidate in U 0 (as defined in Section 4.1, in the paragraphs before Proposition 4.4) such that dCVN (U 0 , Prγ 00 (U 0 )) = log ||α||Prγ 00 (U 0 ) ||α||U 0 . (6) Lemma 4.7 applied to the folding path γ 00 implies that there exists a constant K0 (only depending on the rank of the free group) such that dCVN (Prγ 00 (U 0 ), U 00 ) ≤ log ||α||U 00 + K0 . ||α||Prγ 00 (U 0 ) (7) By adding Equations (6) and (7), we obtain that dCVN (U 0 , Prγ 00 (U 0 )) + dCVN (Prγ 00 (U 0 ), U 00 ) − K0 ≤ log ||α||U 00 ≤ dCVN (U 0 , U 00 ). ||α||U 0 (8) Step 3: End of the proof. sym 0 0 0 Recall that dsym CVN (PrI (U ), S) ≤ C (Equation (2)) and dCVN (PrI (U ), Prγ 00 (U )) ≤ K + C (Equation (5)). Together with Equation (8), this implies that there exists a constant K 0 , only depending on C (and on the rank of the free group), such that dCVN (U 0 , U 00 ) ≥ dCVN (U 0 , S) + dCVN (S, U 00 ) − K 0 . (9) Hence dCVN (U 0 , S) ≤ dCVN (U 0 , U 00 ) − dCVN (S, U 00 ) + K 0 ≤ dCVN (U 0 , U 00 ) − dCVN (U, U 00 ) + dCVN (U, S) + K 0 = −dCVN (U, U 0 ) + dCVN (U, S) + K 0 ≤ −dCVN (U, U 0 ) + dCVN (U, S0 ) + dCVN (S0 , S) + K 0 ≤ C + K0 Indeed, the first inequality is Equation (9) and the second comes from the triangle inequality. The equality on the third line follows from the fact that γ 0 is a geodesic, and that the trees U , U 0 and U 00 lie in this order on the image of γ 0 (at least if B0 has been chosen sufficiently large). The inequality on the fourth line follows from the triangle inequality. The last inequality uses the definition of U 0 (which says in particular that dCVN (U, U 0 ) = dCVN (U, S0 )) and the fact that dsym CVN (S0 , S) ≤ C (Equation (1)). 4.4 Typical rays are infinitely often progressing. Let (T, T 0 ) ∈ U E × UE r ∆. For every neighborhood U of (T, T 0 ) in UE × U E, we let Tube(U) be the collection of all greedy folding lines joining pairs in U. Given a point y0 ∈ CVN and A0 > 0, we then let Tubey0 (U; A0 ) be the set of all trees U ∈ CVN such that there exists γ ∈ Tube(U) such that 37 Figure 3: Schematic picture of the situation in the proof of Proposition 4.17. The blue parts all have uniformly bounded dsym CVN -diameter. • the tree U = γ(t) belongs to the image of γ, and • there exists a dsym CVN -closest-point projection U0 = γ(t0 ) of y0 to the image of γ, with t0 ≤ t, such that π ◦ γ([t0 , t]) has diameter at most A0 in F FN . Lemma 4.18. Let A0 > 0, y0 ∈ CVN , and (T, T 0 ) ∈ UE × UE r ∆. There exists a neighborhood U of (T, T 0 ) in UE × UE, such that the set Tubey0 (U; A0 ) is a compact subset of CVN . Proof. Assume otherwise. Then we can find a sequence ((Tn , Tn0 ))n∈N ∈ (CVN × CVN )N converging to (T, T 0 ), together with greedy folding paths γn from Tn to Tn0 for all n ∈ N, and a sequence (Un )n∈N ∈ CVNN with the following properties: • for all n ∈ N, the tree Un lies on the image of γn , and • for all n ∈ N, there exists a dsym CVN -closest-point projection Sn of y0 to γn , such that Un lies to the right of Sn , and the π-image of the subsegment of γn joining Sn to Un has diameter at most A0 in F FN , and • the sequence (Un )n∈N leaves every compact subspace of CVN . However, in view of Proposition 4.6, the sequence (γn )n∈N accumulates on a folding line γ from T to T 0 . It follows from [8, Theorem 6.6] that the sequence (Sn )n∈N should accumulate to a dsym CVN -closest-point projection S of y0 to γ, and that the only possible accumulation points of the sequence (Un )n∈N in the compact space CVN are the trees T and T 0 . In view of Theorem 4.5, the sequence (π(Un ))n∈N has a subsequence that 38 converges to a point in ∂∞ F FN . However, the π-images of the trees Un remain in a bounded neighborhood of π(S) in F FN , which yields the desired contradiction. Let U be a neighborhood of (T, T 0 ) provided by Lemma 4.18. Recall the definition of ψ : CVN → F FN ∪ ∂∞ F FN from Theorem 4.5. Given A0 > 0 and B ≥ 0, we let Righty0 (U; A0 , B) be the subspace of CVN made of those trees U ∈ CVN such that for all γ ∈ Tube(U), the projection of ψ(U ) to the image of π ◦ γ in F FN is to the right, at distance at least B from all trees in π(Tubey0 (U; A0 )) (recall that ψ(U ) may belong to ∂∞ F FN ; we define in this case the projection of ψ(U ) to the image of π ◦ γ as the leftmost possible accumulation point of a sequence of leftmost closest-point projections of zn to the image of π ◦ γ, over all sequences (zn )n∈N ∈ F FNN converging to ψ(U )). Lemma 4.19. For all A0 > 0, there exists M > 0 such that for all sufficiently large B > 0, one has Righty0 (U; A0 , B) ⊆ Righty0 (U; A0 , B − M ). Proof. This follows from Proposition 4.11. We now fix a point y0 ∈ CVN , a neighborhood U of (T, T 0 ) provided by Lemma 4.18, and we let M be the maximum of the constants provided by Theorem 4.5 and Lemma 4.19. Given A0 , B0 > 0, we let X0 (A0 , B0 ) be the subset of CVN made of those trees U such that there exists S ∈ Tubey0 (U; A0 ) satisfying U ∈ ∆(S), and either U = S, or else U is fully recurrent with respect to some tree in Righty0 (U; A0 , B0 ). Lemma 4.20. For all A0 > 0, there exists β > 0 such that for all B0 > β, the space X0 (A0 , B0 ) ⊆ CVN is compact. Proof. Let A0 > 0, and let B0 > 0 be such that B0 − M is sufficiently large (where sufficiently large will be understood from the rest of the proof). Assume towards a contradiction that X0 (A0 , B0 ) is not contained in CVN . Then there exists a sequence (Un )n∈N ∈ X0 (A0 , B0 )N that leaves every compact subset of CVN . Since we already know that Tubey0 (U; A0 ) is compact (Lemma 4.18), we can assume that for all n ∈ N, there exists a tree Un0 ∈ Righty0 (U; A0 , B0 ) such that Un is fully recurrent with respect to Un0 . Since Tubey0 (U; A0 ) has compact closure in CVN , it meets only finitely many simplices of CVN . Hence up to passing to a subsequence, we can assume that all trees Un belong to a common open simplex in CVN , and that (Un )n∈N converges to a point U ∈ ∂CVN . Up to passing to a further subsequence, we can also assume that the sequence (Un0 )n∈N converges to a tree U 0 ∈ CVN . By Lemma 4.19, we have U 0 ∈ Righty0 (U; A0 , B0 − M ). It follows from [8, Lemma 6.11] that there exists a proper free factor of FN that is elliptic in both U and U 0 . However if B0 has been chosen so that B0 − M is sufficiently large, then ψ(U ) and ψ(U 0 ) are far apart in F FN . This is a contradiction. Let cv0 (FN ) ⊆ cvN be the subset made of those trees T such that the Lipschitz constant of an optimal map from y0 to T is equal to 1. Given subsets X ⊆ CVN and Y ⊆ CVN , we denote by Opt(X, Y ) the set of all optimal FN -equivariant maps from a tree in cv0 (FN ) representing an element in X to a tree in cv0 (FN ) representing an element in Y , which are linear on edges. This set is equipped with the equivariant 39 Gromov–Hausdorff topology introduced in [21, Section 3.2]. If X is a compact subset of CVN , then the subsets of cv0 (FN ) representing X is also compact, so there is a bound on the Lipschitz constant of elements of Opt(X, Y ). Let A0 , B0 > 0 be given by Lemma 4.20, and let X0 := X0 (A0 , B0 ). We let M := Opt(X0 , Righty0 (U; A0 , B0 )). In view of Lemma 4.20, the set M is compact, and Lemma 4.19 implies that M ⊆ Opt(X0 , Righty0 (U; A0 , B0 − M )). Given C0 > 0 and f ∈ Opt(X0 , Righty0 (U; A0 , B0 − M )), we let C(f ; C0 ) be the smallest real number C such that the smallest initial subsegment of dsym CVN -diameter C of the greedy folding path determined by f projects to a region of F FN of diameter at least C0 := B0 − 3M (here we need that B0 was chosen sufficiently large so that C0 is large enough). Using Theorem 4.5, we have C(f ; C0 ) < +∞ for all f ∈ Opt(X0 , Righty0 (U; A0 , B0 − M )) (otherwise the folding path directed by f would leave the interior of outer space before having made enough progress in F FN ). In particular, we have C(f ; C0 ) < +∞ for all f ∈ M. Lemma 4.21. There exist β1 , β2 > 0 such that if C0 > β1 and B0 > C0 + β2 , then the map C: M → R f 7→ C(f ; C0 ) is bounded from above. Proof. We proceed as in the proof of Lemma 3.10. Let K1 > 0 be such that dF FN (π(x), π(y)) ≤ K1 dCVN (x, y) + K1 for all x, y ∈ CVN . Assume towards a contradiction that C(f ; C0 ) is unbounded. Then N there exists a sequence (fn )n∈N ∈ M such that for all n ∈ N, we have C(fn ; C0 ) > n. For all n ∈ N, we denote by γn the greedy folding path determined by fn . Then for all n ∈ N, there exists a dsym CVN -closest point projection xn of y0 on the image of γn , so that the smallest subsegment σn of the image of γn of dsym CVN -diameter n starting at xn projects to a subset of F FN of diameter at most C0 . Compactness of the space M ensures that up to passing to a subsequence, we can assume that the maps fn converge to a map f ∈ M. The greedy folding paths γn then converge uniformly on compact sets to the greedy folding path γ determined by f . Thus the sequence (xn )n∈N accumulates to a point x lying on the image of γ. Let then z be to the right of x on the image of γ, such that dF FN (π(x), π(z)) ≥ C0 + 4K1 . There exists a sequence (zn )n∈N of points zn on the image of γn that converges to z. For n large enough in our subsequence, sym 1 1 we have dsym CVN (xn , x) < 2 and dCVN (zn , z) < 2 , and hence dF FN (π(xn ), π(x)) < 2K1 and dF FN (π(zn ), π(z)) < 2K1 . Therefore dF FN (π(xn ), π(zn )) > C0 . However the point zn is eventually in the segment σn , since its dsym CVN -distance to x is bounded, and this contradicts the fact that the diameter of the projection of σn to F FN is at most C0 . 0 Given A0 , B0 , C0 > 0 and (T, T 0 ) ∈ U E × UE r ∆, we let CA (T, T 0 ) be the 0 ,B0 ,C0 infimum of all real numbers C > 0 such that all greedy folding lines γ : R → CVN from 40 T to T 0 are (C; A0 , B0 , C0 )-progressing at all dsym CVN -closest point projections of y0 to γ. As a consequence of Lemma 4.21, we obtain the following fact. Corollary 4.22. For all A0 > 0, there exist β1 , β2 > 0 such that for all C0 > β1 and all B0 > 0 such that B0 > C0 + β2 , the map 0 CA : UE × UE r ∆ → R 0 ,B0 ,C0 is locally bounded from above. Corollary 4.23. There exist A0 , B0 , C0 > 0 satisfying the hypotheses from Proposition 4.17, and an upper semi-continuous map C : UE ×U E r∆ → R such that for all (T, T 0 ) ∈ UE×UEr∆, all greedy folding lines γ : R → CVN from T to T 0 are (C(T, T 0 ); A0 , B0 , C0 )progressing at all dsym CVN -closest-point projections of y0 to γ. Proof. This follows from Lemma 3.9 and Corollary 4.22. We now deduce that typical geodesic rays contain infinitely many progressing (and hence contracting and high) subsegments. We fix constants A0 , B0 , C0 > 0 provided by Corollary 4.23. Proposition 4.24. Let µ be a nonelementary probability measure on Out(FN ) with finite first moment with respect to dCVN . Then for all θ ∈ (0, 1), there exists C > 0 such that for P-a.e. bilateral sample path Φ of the random walk on (Out(FN ), µ), and all greedy folding lines γ : R → CVN from bnd− (Φ) to bnd+ (Φ), the set of integers k ∈ Z such that γ is (C; A0 , B0 , C0 )-progressing at all dsym CVN -closest-point projections of y0 , has density at least θ. Proof. We recall that P denotes the space of bilateral sample paths of the random walk on (Out(FN ), µ). By Corollary 4.23, the map e: P → C R Φ 7→ C(bnd− (Φ), bnd+ (Φ)) is measurable. Let U be the transformation of P induced by the Bernoulli shift on the space of bilateral sequences of increments. Then for P-a.e. bilateral sample path Φ of the random walk and all k ∈ Z, all greedy folding lines γ : R → CVN from bnd− (Φ) to e k .Φ); A0 , B0 , C0 )-progressing at all dsym -closest-point projections of bnd+ (Φ) are (C(U CVN Φk .y0 to γ. Let θ ∈ (0, 1). We can choose C > 0 such that e P(C(Φ) ≤ C) > θ. As in the proof of Proposition 3.11 in the case of mapping class groups, an application of Birkhoff’s ergodic theorem to the ergodic transformation U then implies that for P-a.e. sample path Φ := (Φn )n∈N of the random walk on (Out(FN ), µ), the density of integers k ∈ N such that γ is (C; A0 , B0 , C0 )-progressing at all dsym CVN -closest point projections of Φk .y0 to γ, is at least θ. 41 Proposition 4.25. Let µ be a nonelementary probability measure on Out(FN ) with finite first moment with respect to dCVN . Then for all θ ∈ (0, 1), there exist B, D, M > 0 such that for P-a.e. bilateral sample path Φ of the random walk on (Out(FN ), µ), and all greedy folding lines γ : R → CVN from bnd− (Φ) to bnd+ (Φ), the set of integers k ∈ Z such that γ is (B, D)-contracting and M -high at all dsym CVN -closest-point projections of y0 , has density at least θ. Proof. This follows from Propositions 4.15, 4.17 and 4.24. 4.5 End of the proof of the spectral theorem Proof of Theorem 4.1. We will check that (Out(FN ), µ) satisfies the hypotheses in Theorem 2.6. The pair (CVN , F FN ) is a hyperbolic Out(FN )-electrification. All elements of Out(FN ) acting loxodromically on F FN (i.e. fully irreducible outer automorphisms) have an electric translation axis in CVN , and (Out(FN ), µ) is CVN -boundary converging (Theorem 4.10). The first item in the definition of contracting pencils of geodesics (Definition 2.5) was established by Namazi–Pettet–Reynolds [41, Lemmas 7.16 and 7.17] for the collection of greedy folding lines between any two distinct trees in UE. In view of Proposition 4.25, the second item in this definition is also satisfied by this collection of lines. Therefore, Theorem 2.6 applies to (Out(FN ), µ). Recall that the translation length of any fully irreducible outer automorphism on CVN is equal to the logarithm of its stretching factor. Therefore, for P-a.e. sample path of the random walk on (Out(FN ), µ), we have 1 lim log λ(Φ−1 n ) = L, n→+∞ n where L is the drift of the random walk on (Out(FN ), µ) with respect to dCVN . References [1] Y. Algom-Kfir, The Lipschitz metric on Outer Space, Ph.D. thesis, University of Utah, 2010. , Strongly contracting geodesics in Outer Space, Geom. Topol. 15 (2011), no. 4, 2181– [2] 2233. [3] Y. Algom-Kfir and M. Bestvina, Asymmetry of outer space, Geom. Dedic. 156 (2012), no. 1, 81–92. [4] Y. Benoist and J.-F. Quint, Central limit theorem on hyperbolic groups, preprint (2014). [5] M. Bestvina and M. Feighn, Outer limits, preprint, 1994. [6] , Hyperbolicity of the complex of free factors, Adv. Math. 256 (2014), 104–155. [7] M. Bestvina and M. Handel, Train tracks and automorphisms of free groups, Ann. Math. 135 (1992), no. 1, 1–51. [8] M. Bestvina and P. Reynolds, The boundary of the complex of free factors, arXiv:1211.3608v2 (2013). [9] D. Calegari and J. Maher, Statistics and compression of scl, arXiv:1008.4952v4 (2012). 42 [10] M.M. Cohen and M. Lustig, Very small group actions on R-trees and Dehn twist automorphisms, Topology 34 (1995), no. 3, 575–617. [11] T. Coulbois, A. Hilion, and M. Lustig, Non-unique ergodicity, observers’ topology and the dual algebraic lamination for R-trees, Illinois J. Math. 51 (2007), no. 3, 897–911. [12] M. Culler and J.W. Morgan, Group actions on R-trees, Proc. London Math. Soc. 55 (1987), no. 3, 571–604. [13] M. Culler and K. Vogtmann, Moduli of graphs and automorphisms of free groups, Invent. math. 84 (1986), no. 1, 91–119. [14] S. Dowdall, M. Duchin, and H. Masur, Statistical Hyperbolicity in Teichmüller Space, Geom. Funct. Anal. 24 (2014), no. 3, 748–795. [15] S. Dowdall and S.J. Taylor, Hyperbolic extensions of free groups, arXiv:1406.2567v1 (2014). [16] A. Fathi, F. Laudenbach, and V. Poenaru, Travaux de Thurston sur les surfaces, Astérisque 66-67 (1979), 1–284. [17] S. Francaviglia and A. Martino, Metric Properties of Outer Space, Publ. Mat. 55 (2011), no. 2, 433–473. [18] H. Furstenberg, Noncommuting random products, Trans. Amer. Math. Soc. 108 (1963), 377–428. [19] H. Furstenberg and H. Kesten, Products of Random Matrices, Ann. Math. Stat. 31 (1960), no. 2, 457–469. [20] F. Gardiner and H. Masur, Extremal length geometry of Teichmüller space, Complex Variables 16 (1991), 209–237. [21] V. Guirardel and G. Levitt, The outer space of a free product, Proc. London Math. Soc. 94 (2007), no. 3, 695–714. [22] Y. Guivarc’h, Produits de matrices aléatoires et applications aux sous-groupes du groupe linéaire, Erg. Th. Dyn. Syst. 10 (1990), no. 3, 483–512. [23] U. Hamenstädt, The boundary of the free splitting graph and of the free factor graph, arXiv:1211.1630v5 (2014). [24] M. Handel and L. Mosher, Axes in Outer Space, Memoirs of the AMS 213 (2011), no. 1004. [25] C. Horbez, The boundary of the outer space of a free product, to appear in Israel J. Math. [26] , The horoboundary of outer space, and growth under random automorphisms, to appear in Ann. Scient. Ec. Norm. Sup. [27] , Hyperbolic graphs for free products, and the Gromov boundary of the graph of cyclic splittings, to appear in J. Topol. [28] , Central limit theorems for mapping class groups and Out(FN ), arXiv:1506.07244v2 (2015). [29] V.A. Kaimanovich, The Poisson formula for groups with hyperbolic properties, Ann. Math. 152 (2000), no. 3, 659–692. [30] V.A. Kaimanovich and H. Masur, The Poisson boundary of the mapping class group, Invent. math. 125 (1996), no. 2, 221–264. 43 [31] I. Kapovich, Currents on free groups, Topological and Asymptotic Aspects of Group Theory (R. Grigorchuk, M. Mihalik, M. Sapir, and Z. Sunik, eds.), AMS Contemp. Math. Series, vol. 394, 2006, pp. 149–176. [32] I. Kapovich and M. Lustig, Patterson–Sullivan currents, generic stretching factors and the asymmetric Lipschitz metric for Outer space, arXiv:1406.0434v3 (2015). [33] A. Karlsson, Two extensions of Thurston’s spectral theorem for surface diffeomorphisms, Bull. London Math. Soc. 46 (2014), no. 2, 217–226. [34] J.F.C. Kingman, The Ergodic Theory of Subadditive Stochastic Processes, J. Roy. Statist. Soc. B 30 (1968), no. 3, 499–510. [35] G. Levitt, Counting growth types of automorphisms of free groups, Geom. Funct. Anal. 19 (2009), no. 4, 1119–1146. [36] J. Maher, Exponential decay in the mapping class group, J. Lond. Math. Soc. 86 (2012), no. 2, 366–386. [37] J. Maher and G. Tiozzo, Random walks on weakly hyperbolic groups, arXiv:1410.4173v2 (2015). [38] B. Mann, Hyperbolicity of the cyclic splitting graph, Geom. Dedicata 173 (2014), no. 1, 271–280. [39] H.A. Masur and Y.N. Minsky, Geometry of the complex of curves I : Hyperbolicity, Invent. math. 138 (1999), no. 1, 103–149. [40] J. McCarthy and A. Papadopoulos, Dynamics on Thurston’s sphere of projective measured foliations, Comment. Math. Helv. 64 (1989), no. 1, 133–166. [41] H. Namazi, A. Pettet, and P. Reynolds, Ergodic decomposition for folding and unfolding paths in Outer space, arXiv:1410.8870v1 (2014). [42] V.I. Oseledets, A multiplicative ergodic theorem. Characteristic Ljapunov exponents of dynamical systems, Tr. Mosk. Mat. Obs. 19 (1968), 179–210. [43] I. Rivin, Walks on groups, counting reducible matrices, polynomials, and surface and free group automorphisms, Duke Math. J. 142 (2008), no. 2, 353–379. [44] C. Series, Lines of minima in Teichmüller space, Handbook of Teichmüller theory (Zürich) (A. Papadopoulos, ed.), IRMA Lectures in Mathematics and Theoretical Physics, vol. III, EMS Publishing House, 2012, pp. 123–156. [45] A. Sisto, Contracting elements and random walks, arXiv:1112.2666v2 (2013). [46] S.J. Taylor and G. Tiozzo, Random extensions of free groups and surface groups are hyperbolic, arXiv:1501.02846v1 (2015). [47] W.P. Thurston, On the geometry and dynamics of diffeomorphisms of surfaces, Bull. Amer. Math. Soc. (N.S.) 19 (1988), no. 2, 417–431. [48] G. Tiozzo, Sublinear deviation between geodesics and sample paths, Duke Math. J. 164 (2015), no. 3, 511–539. 44 François Dahmani, Université de Grenoble Alpes, Institut Fourier, F-38000 Grenoble, France. e-mail:[email protected] Camille Horbez, Laboratoire de Mathématiques d’Orsay, Univ. Paris-Sud, CNRS, Université Paris-Saclay, 91405 Orsay, France. e-mail:[email protected] 45
4math.GR
Power Synthesis of Maximally-Sparse Linear Arrays Radiating Shaped Patterns through a Compressive-Sensing Driven Strategy Andrea Francesco Morabito, Antonia Rita Laganà, Gino Sorbello, and Tommaso Isernia 1  Abstract—We present an innovative approach to the synthesis of linear arrays having the least possible number of elements while radiating shaped beams lying in completely arbitrary power masks. The approach, based on theory and procedures lend from Compressive Sensing, has two innovative key features. First, it exploits at best the multiplicity of equivalent field solutions corresponding to the many different power patterns lying in the given mask. Second, it a-priori optimizes those parameters that affect the performance of Compressive Sensing. The overall problem is formulated as two convex programming routines plus one local optimization, with the inherent advantages in terms of computational time and solutions’ optimality. An extensive numerical comparison against state-of-the-art procedures proves the effectiveness of the approach. Index Terms—Compressive Sensing, Maximally Sparse Arrays, Shaped Beams, Power Synthesis. I. INTRODUCTION The synthesis of non-uniformly spaced arrays [1] is of interest in a large number of applications. While the first design techniques date back to the Sixties (see for instance [1],[2]), the problem has been the subject of a renewed interest in the last years [3]-[20]. In particular, attention has been devoted to the synthesis of ‘maximally-sparse’ arrays [6]-[15], i.e., arrays fulfilling assigned mission requirements by exploiting the minimum number of active elements. Many different solution approaches have been proposed to deal with such problem, recently including global optimization [15], the Forward Backward Matrix Pencil Method (FBMPM) [11][13], and the Linear Programming (LP) procedure proposed in [14]. Finally, an important body of work is given by a number of techniques based on the Compressive Sensing (CS) theory [6]-[10]. On the other side, a brief look to the characteristics of the different approaches shows that there is indeed room for improvement, as detailed below. First, it is interesting to note that the MPM and FBMPM, although being very effective, have some theoretical flaw (as the authors themselves state at the end the introduction of [12]). In fact, in order to find the locations of the array elements, the MPM requires that the poles of the equation identified by organizing the desired pattern data as an Hankel matrix and performing its singular value decomposition lie on the unit circle in the complex plane [11]. However, this property usually does not hold true in the case of shaped beams, this being the main reason of replacing the MPM with the FBMPM in the synthesis of such kind of fields [12]. On the other side, as stated by authors, the additional relationships enforced by FBMPM, although being very useful, represent a necessary but not a sufficient condition in order to guarantee the unitary amplitude of the mentioned poles [12], so that it is still possible to further improve the achieved results. Second, both the FBMPM and the existing CS-based approaches aim to fit at best both the amplitude and phase distributions of a reference far-field pattern. Such a circumstance completely ignores the fact in array antennas synthesis one is generally interested in power distributions, rather than amplitude and phase far-field distributions. Obviously, a priori establishing given phase distributions implies a reduction of the degrees of freedom available to the designer, thus reducing the number of possible solutions [21]. The approach in [14] apparently overcomes such a limitation, as a formulation is given in terms of a ‘mask’ for the pattern. Unfortunately, this technique is based on the assumption that the radiated field is a real function, while it is known that in case of shaped beams the optimal far-field pattern, i.e., the one with the least dimension for given performances, is in general a complex function [21]. Hence (see Sections II and IV), a number of possibly convenient solutions are hidden to the designer also in such a case. In the following, we propose, discuss and test a new approach to the synthesis of shaped patterns by means of (maximally) sparse linear arrays. The approach is able to take into account the multiplicity of possible fields able to fulfill given upper and lower bounds on the power pattern. Although developed for the case of linear arrays, the approach can be extended to the case of patterns requiring a circular symmetry, and it can be used in the case of two-dimensional factorable patterns, which are of actual interest in several applications. The paper is organized as follows. In Section II we recall basic results of CS and discuss its strengths and weaknesses in relationship with synthesis problems. Moreover, we also briefly recall useful results already available in the synthesis of shaped beams, with particular emphasis on the case of linear arrays. The proposed approach is presented and assessed in Sections III and IV, respectively, the latter providing successful numerical comparisons with all methods and results in [7],[10],[12],[14]. Conclusions follow. II. A COUPLE OF B ASIC RESULTS In order to better clarify the usefulness of CS in synthesis problems, as well as the meaning and the interest of the approach we are proposing, in this Section we briefly review a couple of general theoretical results respectively related to the CS theory and to the synthesis of shaped beams. II.1 Interest and weaknesses of Compressive Sensing in synthesis problems The well-known circumstance that the aperture source and its far-field distribution are essentially related by a Fourier Transform constitutes a formidable basis in order to apply to array synthesis all theories and procedures arising from [22] and related (see for instance [23],[24]). Roughly speaking, the measurements one would use in the recovery of a sparse signal are substituted by the far-field specifications, while the array layout and excitation represent the sparse signal to be ‘recovered’ through CS [6]-[10]. In applying CS to such a problem, the common approach is that of looking for a fitting of both the amplitude and phase distributions of a reference far-field pattern, and the problem’s actual unknowns are both the array elements excitations and locations. In pursuing such a goal, inspired from [22]-[24], the crucial antenna-design operation is usually that of minimizing the (weighted) ℓ1 norm of excitations [6]-[10], as defined on a very dense auxiliary grid. One may argue that both terms ‘recovery’ and ‘Compressive Sensing’ are questionable, as one cannot be sure that a sparse array able to realize a given pattern certainly exists, so that one could talk in terms of ‘sparsity enhancing’ rather than of ‘Compressive Sensing’. On the other side, if a sparse array able to fulfill the assigned technical requirements exists then the CS theory provides the rigorous conditions and the actual algorithms allowing to unveil it, so that the adopted terminology (and framework) makes indeed sense. The CS-based procedures in [6]-[10] show excellent capabilities for the synthesis of sparse arrays. On the other hand, they also have a number of drawbacks, and it is indeed the CS theory which allows understanding weaknesses and developing a number of improvements. First, while the CS theory provides theoretical conditions and practical procedures for a faithful recovery in case of linear problems, it must be stressed that a power-pattern synthesis problem, even when looking for a generic (nonsparse) source distribution, is indeed a non-linear problem. In fact, as already stated, one is generally interested in power distributions, rather than amplitude and phase far-field distributions, and a-priori establishing given phase distributions, as it is done in the present CS-based procedures, implies a reduction of the degrees of freedom available to the designer, thus hiding possible solutions [21]. As a consequence, one should either develop a CS theory for non-linear problems, or devise possible ways to take advantage from the fact that many different complex patterns could equally fulfill the given power pattern specifications (which is our choice, see Section III). A second weakness of present procedures can be understood from a number of results including Theorem 1.3 in [22] and/or condition (6) in [23]. In these references, it is shown that the recovery of a signal having an original dimension equal to N and a ‘sparse’ or ‘compressed’ size equal to S results successful with overwhelming probability only if the number of independent measurement (say M) exceeds a threshold which grows with both S and logN [22][24]. Now, in the CS application to array synthesis, M, N, and S respectively map to the cardinalities of far-field specifications, initial array layout (including elements with zero excitation), and final sparse array layout (counting only active elements) [6]-[10]. As a consequence, since any field radiated by a finite-dimensional source has a finite number of degrees of freedom (and hence a limited value of M) [25], a very dense original array layout (and hence a very large value of N) may imply a violation of the conditions under which CS guarantees an effective recovery, i.e., an effective array synthesis. As a consequence, one should be careful about the choice of N, i.e., of the initial grid wherein CS is eventually applied, while still allowing in the overall procedure to locate the active antennas anywhere. II.2 A theoretical result in the synthesis of linear sources A number of procedures for the synthesis of shaped beams through standard ‘non-sparse’ arrays (such as the Woodward Lawson technique [26] and Gradient Search and Conjugate Matching) are reviewed in [20]. Another relevant and widely diffused approach to synthesis (which includes conjugate matching) is the so-called Alternating Projection technique [27]. On the other side, all these synthesis methods do not take into account that the synthesis of sources able to realize power patterns lying within a given mask is indeed a non-linear and non-convex problem. As a consequence, the final result of all the above synthesis methods depends indeed on the initial assumptions or on the starting point of the adopted algorithm. In fact, an exceptionally large number of procedures based on global optimization procedures has been devised (see [28],[29] and references therein). In case of equispaced linear arrays a completely different approach, which overcomes the non-convexity of the problem as well as the computational burden (and weaknesses [30]) associated to global optimization, is possible [21]. The approach can be naturally extended to the case of continuous sources by considering the limiting case of vanishing small spacings (and adding constraints on the invisible part of the spectrum) [31]. Such an alternative approach is based on the circumstance that the square-amplitude array factor of a linear equispaced array of Q antennas can be expressed as Q 1 D e P(u )  jqu q (1) q  Q  1 with u=βdsinα and β=2π/λ, λ, α, and d being the wavelength, the angle between the boresight and observation directions, and the spacing between adjacent elements, respectively. Since P must be a real and non-negative function, the conditions Dq  D* q q  1, 2, ..., Q  1 (2) where * means complex conjugation, and Q 1 D e q jqu 0 (3) q  Q 1 must hold true. Hence, one can identify a power pattern fulfilling given shape constraints by solving the following optimization problem: Q 1  Dq e jqu  UB (u )   q  Q 1  Q 1  Dq e jqu  LB(u )   q  Q 1   D  D * q  1, 2, ..., Q  1 q  q Q 1  Dq e jqu  0   q  Q 1  CS framework. Second, the consideration of all possible field determinations allows to keep under control (and take advantage from) the multiplicity of solutions available for each fixed power pattern. (4.a) (4.b) (4.c) (4.d) wherein the arbitrary (real and non-negative) functions UB and LB respectively denote the upper and lower bounds exploited to shape the field amplitude according to the particular application at hand. By taking into account the band-limitedness of P, expressions (4) can be substituted with a sufficiently fine discretization [21],[25] so that it can be seen as a system of ordinary linear inequalities in the Dq coefficients. Notably, such a problem can be easily solved by using any LP tool. Then, representation (1) can be factored in two polynomials being the complex conjugate each of the other, which can be interpreted as the array factor and its complex conjugate. As a consequence, one is able to solve the shaped beam synthesis problem through solution of (4) and suitable factorization techniques [21]. Notably, more than a single solution can be found, as the factorization of the reference power pattern P in complex conjugate factors is generally nonunique, so that the same power pattern corresponds to a (generally large) number of different far-field distributions. All of the solution can be easily generated, at least in principle, by means of the so called ‘zero-flipping’ operation [21]. With respect to the specific subject of this paper, the above result has a two-fold usefulness. First, it offers a natural way to translate power-pattern specifications into field specifications, thus allowing to exploit the standard (linear) III. THE PROPOSED APPROACH TO SYNTHESIS The aim of the procedure is to perform the power synthesis of a shaped beam lying in a fixed and arbitrary mask through an array antenna composed by the minimum number of elements. By taking into account limitations discussed in Section II.1, and taking advantage from the result recalled in Section II.2, the power synthesis problem at hand has been conveniently formulated as the following three-steps procedure. In the first step, determine some convenient nominal power pattern to be pursued, and find all the different field patterns corresponding to it. In the second step, by taking advantage from the field patterns determined in step one, use CS procedures in order to synthesize a sparse array having the minimum possible number of elements. The above two steps allow taking relevant advantage from the fact that a single power pattern corresponds to a large number of different patterns, but they still do not exploit all the available degrees of freedom. In fact, there may be many different power patterns lying in the same mask. The third step is hence devoted to perform a refinement of the solution by taking advantage from this circumstance. In particular, modifications of the initial power pattern are pursued in such a way to realize a further sparsification of the array layout. Obviously, the original mask is still enforced on the on the final power pattern. Details on the three steps are respectively given in the three following subsections. III.1. Step 1: Exploiting the multiplicity of solutions for a given power pattern Let us suppose a solution to (4) has been found. Then, by introducing the auxiliary variable z=eju, and exploiting the Fundamental Theorem of Algebra, representation (1) can be factored in terms of its zeroes. Their proper clustering allows the factorization of the reference power pattern P in complex conjugate factors. Notably, one will have many different clustering possibilities corresponding to number of different far-field distributions. To express this multiplicity of solutions, let us consider the matrix  a1  a  A  2 (5)      a W  where W is the overall number of different array factors corresponding to P and the vector aw=[aw,1,aw,2,…,aw,Q] denotes the excitation vector corresponding to the w-th array factor for w=1,2,…,W. As discussed in [21], the number of equivalent solutions is W=2R’/2, R’ being the number of zeroes of P which do not lie on the unit circle. As W grows very rapidly with R’, it makes sense to discuss the choice of the parameters Q and d, which determine the total number of roots of P, i.e., R=2Q-2, and the reference-array size, i.e., T=(Q-1)d. Due to the bandlimitedness of the fields radiated by nonsuperdirective sources [25],[31], the actual feasibility or unfeasibility of a power pattern mask is essentially determined by the antenna’s electrical size T/λ. In fact, for a fixed T, increasing Q means increasing R, thus apparently furnishing a larger number of degrees of freedom. On the other side, increasing Q also means to reduce the array elements spacing. The reduction of d, in turn, forces the user to add constraints in the invisible part of the spectrum in order to avoid superdirective sources [21],[31]. As a consequence, the additional roots which are apparently available must be used to bind the antenna’s reactive energy (and are indeed expected to lie on the unit circle). Therefore, provided d≤λ/2, different values of Q and d corresponding to the same value of T are expected to lead to very similar radiation performances in the visible part of the spectrum. We have verified this circumstance in a large set of synthesis problems, solving each of them by choosing d=0.5λ, d=0.4λ, and d=0.3λ. At the end of the overall proposed approach, they all led to identical results in terms of both radiation performance and sparse array’s final number of elements. Let us discuss now the choice, amongst all the equivalent solutions (5), of the field to be pursued through CS. A first possibility could be that of applying a CS-based procedure to all the different fields arising from the factorization step, and then to observe the resulting number of active array elements. A similar strategy has been adopted in [12] by Liu and coworkers which, starting from a power solution in [21], have applied the FBMPM to all the equivalent field solutions. A second possibility could be that of a-priori selecting (by exploiting some convenient ad-hoc criterion) one amongst the different field distributions fulfilling the initial constraints. This strategy, which is the one exploited by our approach, may allow avoiding a heavy computational burden in those test cases having a very large number of equivalent solutions. Following the CS-theory [22]-[24], an intuitive choice is to consider the excitations set corresponding to the array layout with the maximum amount of sparsity. Therefore, amongst all the available far-field distributions, a convenient choice is to select Q f r     ar , q e jqd sin  (6) q 1 where fr(u)fr*(u)=P(u), and ar 1  a w 1 w  1,2,...,W (7) as reference field for step 2 of our procedure. In fact, according to the CS-theory concerning relaxation of ℓ0-norm optimization problems, fr represents, by construction, the far-field distribution that more easily lends itself to a ‘sparsification’ process (see [22]-[24] for further details). As discussed with the help of some examples in the Section IV, application of (7) works very well even in those cases where d is chosen in the order of λ/2, which can be attributed again to the finite number of degrees of freedom of finite-dimensional sources [25]. III.2. Step 2: CS-driven engine to recover a preliminary array layout Once the ‘optimal’ reference far-field distribution has been identified, we apply a CS-inspired procedure to synthesize it. We denote with fb the optimized far field and with the vectors x and b the locations and excitations of the N-elements linear array radiating it, respectively. Many different procedures are commonly used in sparse recovery, such as greedy approaches [32], iterative thresholding [33], Basis Pursuit [34] or Least Absolute Shrinkage and Selection Operator (LASSO) [35]. Taking into account the theoretical results presented in [22], we adopt an approach based on a ℓ1 relaxation of the original problem, which is similar in spirit to the LASSO approach. In particular, we formulate the problem as follows: min b 1 b (8.a) subject to   f   2  g      b 1    f b    f r   2    2  f r   2  (8.b) (8.c) wherein N f b     bn e jx n sin  (9) n 1 Notably, the problem is reduced in such a way to a Convex Programming (CP) optimization. In such a formulation:  the cost function (8.a) is based on CS theory and has the same aim of the functional minimized in [7]-[10], i.e., to induce a minimization of the arrays’ active elements number;  constraint (8.b) is devoted to control the sidelobes amplitude and enforces an upper bound g(α) on the synthesized power pattern in the angular region denoted with τ1. Note g can be an arbitrary (real and positive) function so that field ‘notches’ can be eventually realized;  constraint (8.c) ensures that, in the angular region denoted by τ2, the optimized array factor fits the reference one with a precision ε. Notably, given its mathematical formulation, provided an intersection between constraints (8.b) and (8.c) does exist, problem (8) provides always a unique solution provably representing the global optimum. Moreover, provided conditions for the validity of CS sparse recovery hold true, such a solution also will be a maximally sparse solution to the synthesis problem [6]-[10]. As a final comment on this step, let us discuss the choice of N and x in (9). Once the array aperture size has been fixed on the basis of the particular radiation and geometrical specifications, following the theory in [6]-[10], we define x as a vector uniformly spanning it. Note that, in order to optimize the CS performance, we use values of N considerably smaller than those adopted in previous procedures. Such a choice (see also Section II.1) will boost potentialities of CS from both point of views of speed of convergence and optimality of final results [22]-[24]. On the other side, possible accuracy losses in identifying the array locations, deriving from choosing in such a step an elements spacing larger than in other approaches, are then recovered in the third step of the design procedure. III.3. Step 3: Further sparsification and solution refinement The last part of the synthesis is devoted to a further ‘sparsification’ and optimization of the array layout. In the first part of it, which is similar in spirit to the socalled iterative thresholding approaches [33], we further reduce the number of array elements by: 1) discarding the antennas having an excitation amplitude lower than a threshold υ; 2) recursively substituting each couple of remaining elements whose distance is lower than a threshold σ with a single element placed in the middle point between them. In the following, the elements number and the locations set coming out from these operations are denoted with S and y, respectively, while a sketch illustrating such modifications is given in Fig. 1. Fig. 1. Third step of the design procedure: sketch concerning the sparsification of the array layout coming out from step 3. Then, the solution is further improved by determining slight shifts on array locations (and the optimal excitations associated to them) so as to improve the overall radiation performances without increasing the number of elements. In particular, we look for vectors c and Δy such that the final far field distribution S f y1     c s e j  y s  y s sin  (10) s 1 is given by the solution the following optimization problem: min c , y f y1    f r   f r   2 2   2 (11.a) subject to 2 f y1    g     1 (11.b) In fact, provided that the minimum value of the functional in (11.a) does not result larger than ε, solving problem (11) guarantees a radiation performance equivalent to the one coming out from problem (8) while saving N-S array elements. Unfortunately, due to the way the unknown Δy appears in (10), the optimization problem (11) is a non-convex one. On the other side, one is just looking for ‘small’ shifts, so that (10) can be reasonably approximated by S f y 2     c s e jy s sin  (1  jy s sin  ) (12) s 1 As a consequence, the last step can be formulated as in (11) by using fy2 instead of fy1 and adding the convex constraint    y s  s (13) being η a user-defined constant such that 0<η<<1. Notably, even if the optimization problem, unlike (4) and (8), is still not of the CP class, it is nearly so by virtue of (13), so that occurrence of sub-optimal solutions can be avoided while local optimization procedures can still be used. Finally, the adopted formulation allows the addition of the convex constraint  y S  1  y S  1    y S  y S   s  1,2,..., S  1 (14) as a powerful way to avoid a too small spacing between adjacent elements (possibly leading to undesired mutualcoupling effects). It is worth noting that this last step allows counteracting possible drawbacks deriving from a value of N smaller than in other CS-based approaches, and compensating for possible mismatches deriving from the ‘discarding’ and ‘unification’ of elements described above. Moreover, it pursues a field fitting just in the main-beam zone, while upper bounds are used for the sidelobes regions. As already stated, the possibility of modifying the power pattern with respect to the nominal one fixed in step 1 allows recovering a significant number of degrees of freedom with respect to more usual approaches. IV. NUMERICAL ASSESSMENT In order to assess the actual capabilities of the proposed approach, we have compared its outcomes with those of the state-of-the-art techniques available for the synthesis of shaped beams through ‘maximally-sparse’ arrays. In order to provide a comparison as complete as possible, we discuss in the following six test cases. In particular, the first two examples respectively concern a comparison with two techniques which tackle the problem at hand without exploiting the CS theory, namely the LP procedure presented in [14] and the FBMPM introduced in [12]. Then, in the third, fourth, and fifth numerical examples two state-of-the-art techniques exploiting the CS theory, namely the Bayesian Compressive Sensing (BCS)-based procedure described in [7] and CS-based weighted-norm approach proposed in [10], are considered. Finally, the sixth test case concerns a simple extension of the approach to the synthesis of a planar array. By the sake of clarity, we resume in Table 1 the main parameters used for the different linear arrays. Test case W (Number of equivalent solutions) ε (Fitting precision inside 2 region) 2 (Fitting region) L/λ (Size) ψ/λ (Minimum elements spacing) S (Final elements number) Elements number saving vs. best case available in literature Cfr. vs. [14] (flat-top) Cfr. vs. [12] (cosecant) Cfr. vs. [7] (flat-top) Cfr. vs. [7] (cosecant) Cfr. vs. [10] (cosecant) 512 32 16 32 32 2x10-2 17x10-2 5x10-3 17x10-2 22x10-2 |sinα|≤0.37 -0.05≤sinα≤0.85 |sinα|≤0.31 0≤sinα≤0.83 -0.18≤sinα≤0.59 11.68 7.28 6.80 6.93 7.53 0.40 0.48 0.46 0.51 0.55 13 11 10 12 12 58% 15% 9% 8% 8% Tab. I. Simulation parameters adopted for the test cases concerning one-dimensional arrays. Notably, by virtue of the extremely low computational burden of the overall design algorithm, each example required less than 15 seconds to be generated by a calculator having an Intel Core i7-3537U 2.50GHz CPU and a 10 GB RAM. Finally, it is worth noting that, although the proposed procedure can manage any element factor in the synthesis, all the following power-pattern figures just refer to the squareamplitude distribution of the array factors. Fig. 2. Reference (blue curve, from [14]) and synthesized (red curve) power pattern in the test case of Susection IV.1. Exploited upper-bound constraint (green curve) is also depicted. Simulation parameters: d/λ=0.5; Q=29; N=201; ν=0.05; σ/=0.1; η/=0.025. IV.1 Comparison with [14] (flat-top beam) We adopted as reference the power pattern depicted in blue color in Fig. 2, which has been synthesized in [14] by means of a 31-elements sparse array. This flat-top field guarantees a ripple equal to 0.4455 dB for -20°≤α≤20°, and fulfills an upper-bound constraint (depicted in green color in Fig. 2) of 30 dB for -90°≤α≤-25° and 25°≤α≤90°. By factorizing this power pattern, we have been able to determine 512 equivalent field solutions. Then, we have selected amongst them the one corresponding to the excitation distribution having the minimum ℓ 1 norm and, by applying to the latter the proposed approach, we identified a 13-elements sparse array able to radiate the power-pattern distribution depicted in red color in Fig. 2. As it can be seen, the synthesized solution results equivalent, in terms of radiation performance, to the reference one. Therefore, the proposed procedure has allowed, with respect to the best solution shown in [14], a 58% elements saving without experiencing any power-pattern worsening. The synthesized sparse array’s excitation amplitudes and phases are respectively depicted in figures 3 and 4. Fig. 3. Excitation amplitudes of the maximally-sparse array radiating the red pattern of Fig. 2. IV.2 Comparison with [12] (cosecant beam) We used as reference square-amplitude array factor the power pattern depicted in blue color in Fig. 5. In [12], the FBMPM allowed generating it thorugh a sparse array composed by 13 elements located over an aperture of 7.5λ. By exploiting the proposed approach, we have been able to generate the power pattern depicted in red color in Fig. 9 by exploiting a sparse array composed by 11 elements located over an aperture of 7.4λ. Therefore, without experiencing any loss in terms of radiation performance, and exploiting a practically equivalent aperture size, we reduced of the 15.4% the elements number achieved in [12]. The amplitude and phase distributions of the synthesized array excitations are shown in figures 6 and 7, respectively. Fig. 7. Excitation phases of the maximally-sparse array radiating the red pattern of Fig. 5. Fig. 4. Excitation phases of the maximally-sparse array radiating the red pattern of Fig. 2. IV.3 Comparison with [7] (flat-top beam) In the third test case, we used as reference power pattern the flat-top beam depicted in blue color in Fig. 8, which has a maximum ripple of ±0.58 dB, a peak sidelobe level of -35.6 dB with respect to the maximum power pattern value for |α|≥27.5°. In [7], BCS has been effectively exploited to generate it through a sparse array composed by 11 elements located over an aperture of 7λ. Also, this power pattern has been generated in [12] by exploiting the FBMPM and using 10 radiating elements. Fig. 5. Adopted upper bound (green curve) and reference (blue curve, from [12]) and synthesized (red curve) power patterns for the second test case. Simulation parameters: d/λ=0.5; Q=16; N=321; ν=0.005; σ/=0.025; η/=0.05. Fig. 8. Third test case: adopted upper bound (green curve); reference (blue curve, from [7]) and synthesized (red curve) power patterns. Simulation parameters: d/λ=0.5; Q=15; N=38; ν=0.04; σ/=0.19; η/=0.09. Fig. 6. Excitation amplitudes of the maximally-sparse array radiating the red pattern of Fig. 5. As first design operation, we have generated this power pattern without changing any parameter with respect to [7] (see Table 1). Then, we have factorized the resulting polynomial and applied our CS-based routine to all the equivalent far-field distributions corresponding to it, with the aim of assessing the effectiveness of the adoption of (7). In particular, in each instance we have analyzed the ℓ 1 norm of the excitation set of the reference array factor and counted the active elements of the sparse array coming out from the CS routine. The outcomes of such experiments have been summarized in Fig. 9. As it can be seen, the excitation set having the minimum ℓ1 norm is also the one that leads to the minimum number of active elements in the array designed through CS. This circumstance (which has been also verified in the previous and following test cases) confirms the arguments in Section III.1 about the capability of identifying in a simple fashion the far-field distribution which more easily lends itself to a CS-based ‘sparsification’ process. Fig. 9. Concerning the impact on the CS performance of the ℓ1 norm of the excitations of the different solutions coming out from the statement of the reference power pattern. Notably, in this test case the results achieved by means of the proposed strategy are equivalent to those one reported in [12], while they turn out being improved with respect to [7] in all terms of number of elements, dimensions and performances. Finally, we highlight the important circumstance that the execution of the third step of the procedure allowed us to reduce N of about the 50% with respect to the case wherein just the first two steps of the approach are exploited. Fig. 11. Excitation phases corresponding to the red pattern of Fig. 8. IV.4 Comparison with [7] (cosecant beam) We adopted as reference power pattern the square-cosecant field shown in blue color in Fig. 12. In [7], by adopting BCS this pattern has been synthesized through a sparse array composed by 13 elements located over an aperture of 7.5λ. By exploiting the proposed approach, we have been able to reduce again the array’s number of elements and size, respectively, without any radiation-performance loss. Fig. 10. Excitation amplitudes corresponding to the red pattern of Fig. 8. By applying the post-processing procedure to the array layout having the minimum number of elements at the end of the CS routine, we have achieved a radiation performance which favorably compares to [7] through a sparse array composed by 10 elements located over an aperture of 6.8λ with a minimum spacing of 0.46λ. The achieved array locations and excitations are depicted in Fig. 10 (amplitude distribution) and Fig. 11 (phase distribution), respectively, while Fig. 8 shows the exploited upper-bound function and a superposition of the reference and synthesized square-amplitude array factors. As it can be seen, the achieved power pattern perfectly fits the reference one. Fig. 12. Synthesis of a maximally-sparse array radiating a square-cosecant pattern with a specific sidelobes decay. Reference (blue curve, from [7]) and synthesized (red curve) square-amplitude array factors. Adopted upper bound (green curve) also depicted. Simulation parameters: d/λ=0.5; Q=16; N=161; ν=0.03; σ/=0.05; η/=0.01. This circumstance is shown in Fig. 12, wherein a comparison between reference and synthesized patterns is reported. The designed array is composed by 12 elements located over an aperture of 6.9λ with a minimum spacing of 0.51λ. The corresponding excitation amplitudes and phases are depicted in figures 13 and 14, respectively. exploited to bind the sidelobes as desired, which also points out the flexibility of the overall synthesis procedure. Fig. 13. Excitation amplitudes of the maximally-sparse array radiating the red pattern of Fig. 12. Fig. 15. Synthesis of a maximally-sparse array radiating a square-cosecant pattern with a non-uniform, piecewise-constant sidelobe level behavior. Adopted upper bound (green curve); reference (blue curve, from [10]) and synthesized (red curve) square-amplitude array factors. Simulation parameters: d/λ=0.5; Q=16; N=161; ν=0.005; σ/=0.05; η/=0.08. Fig. 14. Excitation phases of the maximally-sparse array radiating the red pattern of Fig. 12. Fig. 16. Array excitation amplitudes corresponding to red pattern of Fig. 15. IV.5 Comparison with [10] (cosecant beam) In the fifth test case, we aimed at synthesizing the squarecosecant power pattern depicted in blue color in Fig. 15. In [10], CS has been exploited to generate it by means of a sparse array composed by 13 elements located over an aperture of 8λ. Notably, by means of the presented approach, we have achieved an equivalent radiation performance while reducing both the elements number and the aperture size. In particular, the synthesized sparse array is composed by 12 elements located over an aperture of 7.5λ with a minimum spacing of 0.56λ. The achieved antenna layout and excitations are depicted in Fig. 16 (amplitude distribution) and Fig. 17 (phase distribution), respectively. A superposition of the reference and synthesized patterns is shown in Fig. 15, wherein it can be noticed that all the design goals and constraints have been fulfilled. The same figure shows the upper-bound function Fig. 17. Array excitation phases corresponding to the red pattern of Fig. 15. IV.6 Synthesis of a factorable beam through a planar array As a final test case, we show the outcomes of a numerical experiment concerning a simple way to extend the proposed procedure to the synthesis of planar sparse arrays with factorable patterns. Coming to details, we aimed at synthesizing a beam having a flat-top behavior along the azimuth angle and a squarecosecant behavior along the elevation angle, which is of interest in radar applications as well as for radio-base stations. In so doing, we took as a reference the pattern generated from the factorization of the fields depicted in blue color in figures 8 and 12, respectively. Notably, exploitation of the results in [7] would require 13x11=143 elements to generate the desired radiation pattern. On the other side, a straightforward application of our results in Subsections IV.3 and IV.4 already reduces to 12x10=120 the number of required elements. This circumstance is coherent with the fact that, as long as a pattern is factorable, the elements number reduction in the planar array is roughly doubled with respect to the one experienced in the two underlying one-dimensional arrays. Fig. 20. Power pattern of the planar array having the refined layout of Fig. 18 and the excitations whose amplitude distribution is shown in Fig. 19. (a) (b) Fig. 21. Main cuts along ordinate [subplot (a)] and abscissa [subplot (b)] of the power pattern shown in Fig. 20: reference (blue color) and synthesized (red color) solutions. Fig. 18. Array layout achieved by factorizing the one-dimensional solutions shown in Subsections IV.3 and IV.4 and discarding those elements having a normalized excitation amplitude lower than 0.04: elements’ location before (blue circles) and after (red dots) running the final ‘refinement’ algorithm. Fig. 19. Normalized excitation amplitudes associated to the refined layout shown in Fig. 18. Interestingly, a simple application of the third step of the proposed procedure, i.e., of the techniques presented in Subsection III.3, allows a further considerable reduction of elements. In fact, by simply ‘eliminating’ those elements having an excitation amplitude lower than υ=0.04 we achieved the array layout depicted in Fig. 18 (blue circles), which is composed by 94 elements. Then, by adapting to the twodimensional layouts case the approach in (10),(11), in such a way to jointly refine both the x and y array locations, we finally achieved the layout depicted in Fig. 18 (red dots), and the corresponding optimal excitations depicted in Fig. 19 (just amplitude is shown). The achieved power pattern is shown in figures 20 (in the two-dimensional spectral plane) and 21 (along its two main cuts), wherein θ and ϕ respectively represent the elevation and azimuth angles. As it can be seen, a very good agreement is achieved between the reference field and the main cuts of the synthesized pattern. Notably, the overall approach allows to save roughly the 58% of the elements with respect to a fully populated array with a uniform /2 spacing, and roughly the 34% of elements (tolerating a slight worsening of the very low sidelobe levels) with respect to a simple factorization of the solutions in [7]. IV. CONCLUSIONS We have introduced and tested a new approach, inspired from CS, for the synthesis of shaped beams by means of linear arrays having the minimum possible number of elements. The presented technique takes maximum advantage from the multiplicity of different far field and source distributions (having different amounts of sparsity) corresponding to a fixed power pattern, and also from the circumstance that different power patterns may equally fulfill the initial constraints. These features, as well as the use of a reduced cardinality of the tentative array, has allowed us to improve the amount of sparsity of the synthesized array in a number of benchmark problems present in the state-of-the-art literature. In particular, different methods based on LP [14], FBMPM [12], CS [10] and BCS [7] have been considered for comparison. In all cases, the proposed approach always performed equally or better than the considered techniques. The procedure can be easily extended to other cases of interest in several applications, including the design of arrays with factorable patterns (see Section IV.6) as well as onedimensional simply reconfigurable arrays (by exploiting the ideas in [36]). REFERENCES [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] M. I. Skolnik, “Chapter 6. Nonuniform Arrays,” in Antenna Theory, Part I, R. E. Collin and F. Zucker (eds), New York, McGraw-Hill, 1969. R. E. Willey, “Space tapering of linear and planar arrays,” IRE Trans. on Antennas and Propagation, vol. 10, n. 4, pp. 369-377, 1962. T. A. Milligan, “Space-tapered circular (ring) array,” IEEE Antennas and Propagation Magazine, vol. 46, n. 3, pp. 70-73, 2004. O. M. Bucci, M. D’Urso, T. Isernia, P. Angeletti, and G. Toso, “Deterministic synthesis of uniform amplitude sparse arrays via new density taper techniques,” IEEE Transactions on Antennas and Propagation, vol. 58, n. 6, pp. 1949-1958, 2010. O. M. Bucci, T. Isernia, and A. F. Morabito, “An effective deterministic procedure for the synthesis of shaped beams by means of uniformamplitude linear sparse arrays,” IEEE Transactions on Antennas and Propagation, vol. 61, n. 1, pp. 169-175, 2013 G. Oliveri and A. Massa, “Bayesian compressive sampling for pattern synthesis with maximally sparse non-uniform linear arrays,” IEEE Transactions on Antennas and Propagation, vol. 59, n. 2, pp. 467-481, 2011. G. Oliveri, M. Carlin, and A. Massa, “Complex-weight sparse linear array synthesis by Bayesian Compressive Sampling,” IEEE Transactions on Antennas and Propagation, vol. 60, n. 5, pp. 23092326, 2012. G. Prisco and M. D’Urso, “Maximally sparse arrays via sequential convex optimizations,” IEEE Antennas and Wireless Propagation Letters, vol. 11, pp. 192–195, 2012. W. Zhang, L. Li, and F. Li, “Reducing the number of elements in linear and planar antenna arrays with sparseness constrained optimization,” IEEE Transactions on Antennas and Propagation, vol. 59, n. 8, pp. 3106–3111, 2011. B. Fuchs, “Synthesis of sparse arrays with focused or shaped beam pattern via sequential convex optimizations,” IEEE Transactions on Antennas and Propagation, vol. 60, n. 7, pp. 3499-3503, 2012. Y. Liu, Z. Nie, and Q. H. Liu, “Reducing the number of elements in a linear antenna array by the matrix pencil method, IEEE Transactions on Antennas and Propagation, vol. 56, n. 9, pp. 2955-2962, 2008. Y. Liu, Q. H. Liu, and Z. Nie, “Reducing the number of elements in the synthesis of shaped-beam patterns by the forward-backward matrix pencil method,” IEEE Transactions on Antennas and Propagation, vol. 58, n. 2, pp. 604-608, 2010. Y. Liu, Q. H. Liu, and Z. Nie, “Reducing the number of elements in multiple-pattern linear arrays by the extended matrix pencil methods,” IEEE Trans. on Antennas Propag., vol. 62, n. 2, pp. 652-660, 2014. S. E. Nai, W. Ser, Z. L. Yu, and H. Chen, “Beampattern synthesis for linear and planar arrays with antenna selection by convex optimization,” IEEE Transactions on Antennas and Propagation, vol. 58, n. 12, pp. 3923-3930, 2010. [15] A. Trucco and V. Murino, “Stochastic optimization of linear sparse arrays,” IEEE Journal of Oceanic Engineering, vol. 24, n. 3, pp. 291299, 1999. [16] D. Caratelli and M. C. Viganò, “A novel deterministic synthesis technique for constrained sparse array design problem,” IEEE Transactions on Antennas and Propagation, vol. 59, n. 11, pp. 40854093, 2011. [17] D. Caratelli and M. C. Viganò, “Analytical synthesis technique for linear uniform-amplitude sparse arrays,” Radio Science, vol. 46, n. 4, 2011. [18] A. K. Bhattacharyya, “Projection matrix method for shaped beam synthesis in phased arrays and reflectors,” IEEE Transactions on Antennas and Propagation, vol. 55 n. 3, pp. 675-683, 2007. [19] A. F. Morabito, T. Isernia, and L. Di Donato, “Optimal synthesis of phase-only reconfigurable linear sparse arrays having uniform-amplitude excitations,” Progress In Electromagnetics Research, vol. 124, pp. 405423, 2012. [20] A.K. Bhattacharyya, Phased Array Antennas: Floquet Analysis, Synthesis, BFNs, and Active Array Systems, Chapter 11, “Shaped-Beam Array Design: Optimization Algorithms,” pp. 357-374, Wiley, 2006. [21] T. Isernia, O. M. Bucci, and N. Fiorentino, “Shaped beam antenna synthesis problems: feasibility criteria and new strategies,” Journal of Electromagnetic Waves and Applications, vol. 12, pp. 103–137, 1998. [22] E. J. Candès, J. K. Romberg, and T. Tao, “Robust uncertainty principles: exact signal reconstruction from highly incomplete frequency information,” IEEE Transactions on Information Theory, vol. 52, n. 2, pp. 489-509, 2006. [23] E. J. Candès and M. B. Wakin, “An Introduction To Compressive Sampling”, IEEE Signal Processing Magazine, vol. 25, pp. 21–30, March 2008. [24] E. J. Candès, M. Wakin, and S. Boyd, “Enhancing sparsity by L 1 reweighted minimization,” Journal of Fourier Analysis and Applications, vol. 14, n. 5, pp. 877–905, 2008. [25] O. M. Bucci, G. Franceschetti, “On the degrees of freedom of scattered fields,” IEEE Transactions on Antennas and Propagation, vol. AP-37, pp. 918-926, 1989. [26] P. M. Woodward and J. D. Lawson, “The theoretical precision with which an arbitrary radiation-pattern may be obtained from a source of finite size,” Journal of the Institution of Electrical Engineers - Part III: Radio and Communication Engineering, vol. 95, n. 37, pp. 363-370, 1948. [27] O. M. Bucci, G. D’Elia, G. Mazzarella, and G. Panariello, “Antenna pattern synthesis: a new general approach,” Proceedings of the IEEE, vol. 82, n. 3, pp. 358-371, 1994. [28] L. Manica, N. Anselmi, P. Rocca, and A. Massa, “Robust maskconstrained linear array synthesis through an interval-based particle SWARM optimization,” IET Microw. Antennas Propag., vol. 7, n. 12, pp. 976-984, 2013. [29] A. Pirhadi, M. H. Rahmani, and Alireza Mallahzadeh, “Shaped beam array synthesis using particle swarm optimisation method with mutual coupling compensation and wideband feeding network,” IET Microw. Antennas Propag., vol. 8, n. 8, pp. 549-555, 2014. [30] G. W. Wasilkowski, “On average complexity of global optimization problems,” Mathematical Programming, vol. 57, n. 1-3, pp. 313-324, 1992. [31] O. M. Bucci, T. Isernia, A. F. Morabito, “Optimal synthesis of circularly symmetric shaped beams”, IEEE Transactions on Antennas and Propagation, vol. 62, n. 4, pp. 1954-1964, 2014. [32] S. G. Mallat and Z. Zhang, “Matching pursuits with time-frequency dictionaries,” IEEE Transactions on Signal Processing, vol. 41, n. 12, pp. 3397-3415, 1993. [33] T. Blumensath and M. E. Davies. “Iterative thresholding for sparse approximations,” Journal of Fourier Analysis and Applications, vol. 14, n. 5, 2008. [34] S. Chen, D. Donoho D., and D. Saunders D., “Atomic decomposition by basis pursuit,” SIAM Journal on Scientific Computing, vol. 20, n. 1, pp. 33-61, 1999. [35] R. Tibshirani, “Regression shrinkage and selection via the lasso,” Journal of the Royal Statistical Society: Series B, vol 58, no.1, pp.267288, 1996. [36] A. F. Morabito, A. Massa, P. Rocca, and T. Isernia, “An effective approach to the synthesis of phase-only reconfigurable linear arrays,” IEEE Transactions on Antennas and Propagation, vol. 60, n. 8, pp. 3622-3631, 2012.
7cs.IT
An algorithm to determine Hopf Galois structures and description of these on extensions of degree p2 and 2p Teresa Crespo and Marta Salguero Departament de Matemàtiques i Informàtica, Universitat de Barcelona (UB), Gran Via de les Corts Catalanes 585, E-08007 Barcelona, Spain, e-mail: [email protected], [email protected] arXiv:1802.09948v1 [math.GR] 26 Feb 2018 Abstract A Hopf Galois structure on a finite field extension L/K is a pair (H, µ), where H is a finite cocommutative K-Hopf algebra and µ a Hopf action. In this paper we present an algorithm written in the computational algebra system Magma which gives all Hopf Galois structures on separable field extensions of a given degree and several properties of those. We highlight the results obtained for extensions of degree 8. Besides, we present several results on Hopf Galois structures inspired by the algorithm results. For p an odd prime, we determine the Hopf Galois structures on separable extensions of degree 2p and those of cyclic type on separable extensions of degree p2 . Moreover we prove that if (H, µ) is an almost classically Hopf Galois structure, then it is the unique Hopf Galois structure with underlying Hopf algebra H, up to isomorphism. Keywords: Galois theory, Hopf algebra, computational system Magma. 1 Introduction A Hopf Galois structure on a finite extension of fields L/K is a pair (H, µ), where H is a finite cocommutative K-Hopf algebra and µ is a Hopf action of H on L, i.e a K-linear map µ : H → EndK (L) giving L a left H-module algebra structure and inducing a Kvector space isomorphism L ⊗K H → EndK (L). Hopf Galois structures were introduced by Chase and Sweedler in [3]. For separable field extensions, Greither and Pareigis [12] give the following group-theoretic equivalent condition to the existence of a Hopf Galois structure. e its Galois closure, Theorem 1. Let L/K be a separable field extension of degree g, L ′ e e G = Gal(L/K), G = Gal(L/L). Then there is a bijective correspondence between the set of Hopf Galois structures on L/K and the set of regular subgroups N of the symmetric group Sg normalized by λ(G), where λ : G ֒→ Sg is the monomorphism given by the action of G on the left cosets G/G′ . For a given Hopf Galois structure on a separable field extension L/K of degree g, we will refer to the isomorphism class of the corresponding group N as the type of the Hopf Galois structure. The Hopf algebra H corresponding to a regular subgroup N of e G of the group algebra L[N] e Sg normalized by λ(G) is the sub-K-Hopf algebra L[N] fixed e under the action of G, where G acts on L by K-automorphisms and on N by conjugation through λ. The Hopf action is induced by n 7→ n−1 (1), for n ∈ N, where we identify Sg with the group of permutations of G/G′ and 1 denotes the class of 1G in G/G′. It e G are in 1-to-1 correspondence with the is known that the sub-Hopf algebras of L[N] 2010 MSC: 12F10, 16T05, 33F10, 20B05 Both authors acknowledge support by grant MTM2015-66716-P (MINECO/FEDER, UE). 1 subgroups of N stable under the action of G (see e.g. [9] Proposition 2.2) and that, e 1 ]G given two regular subgroups N1 , N2 of Sg normalized by λ(G), the Hopf algebras L[N e 2 ]G are isomorphic if and only if the groups N1 and N2 are G-isomorphic. and L[N Childs [4] gives an equivalent condition to the existence of a Hopf Galois structure introducing the holomorph of the regular subgroup N of Sg . We state the more precise formulation of this result due to Byott [1] (see also [5] Theorem 7.3). Theorem 2. Let G be a finite group, G′ ⊂ G a subgroup and λ : G → Sym(G/G′ ) the morphism given by the action of G on the left cosets G/G′ . Let N be a group of order [G : G′ ] with identity element eN . Then there is a bijection between N = {α : N ֒→ Sym(G/G′ ) such that α(N) is regular} and G = {β : G ֒→ Sym(N) such that β(G′ ) is the stabilizer of eN } Under this bijection, if α ∈ N corresponds to β ∈ G, then α(N) is normalized by λ(G) if and only if β(G) is contained in the holomorph Hol(N) of N. As a corollary to the preceding theorem Byott [1], Proposition 1, obtains the following formula to count Hopf Galois structures. e its Galois closure, Corollary 3. Let L/K be a separable field extension of degree g, L ′ e e G = Gal(L/K), G = Gal(L/L). Let N be an abstract group of order g and let Hol(N) denote the holomorph of N. The number a(N, L/K) of Hopf Galois structures of type N on L/K is given by the following formula a(N, L/K) = | Aut(G, G′ )| b(N, G, G′ ) | Aut(N)| where Aut(G, G′ ) denotes the group of automorphisms of G taking G′ to G′ , Aut(N) denotes the group of automorphisms of N and b(N, G, G′ ) denotes the number of subgroups G∗ of Hol(N) such that there is an isomorphism from G to G∗ taking G′ to the stabilizer in G∗ of 1N . In Hopf Galois theory one has the following Galois correspondence theorem. Theorem 4 ([3] Theorem 7.6). Let (H, µ) be a Hopf Galois structure on the field extension L/K. For a sub-K-Hopf algebra H ′ of H we define ′ LH = {x ∈ L | µ(h)(x) = ε(h) · x for all h ∈ H ′ }, ′ where ε is the counity of H. Then, LH is a subfield of L, containing K, and FH : {H ′ ⊆ H sub-Hopf algebra} −→ {Fields E | K ⊆ E ⊆ L} H′ → LH ′ is injective and inclusion reversing. In [12] a class of Hopf Galois structures is identified for which the Galois correspondence is bijective. We shall say that a Hopf Galois structure (H, µ) on L/K is an almost classically Galois structure if the corresponding regular subgroup N of Sg normalized by λ(G) satisfies that its centralizer ZSg (N) in Sg is contained in λ(G). 2 Theorem 5 ([12] 5.2). If (H, µ) is an almost classically Galois Hopf Galois structure on L/K, then the map FH from the set of sub-K-Hopf algebras of H into the set of subfields of L containing K is bijective. In [8] the Hopf Galois character of separable field extensions of degree up to 7 and of some subextensions of its normal closure has been determined. In [9] Theorem 3.4, a family of extensions is given with no almost classically Galois structure but with a Hopf Galois structure for which the Galois correspondence is bijective. In [10] a degree 8 non-normal separable extension having two non-isomorphic Hopf Galois structures with isomorphic underlying Hopf algebras is presented. In this paper we present an algorithm which determines all Hopf Galois structures of a separable field extension of a given degree g and their corresponding type. Moreover our algorithm distinguishes almost classically Galois structures and decides for the remaining ones if the Galois correspondence is bijective. Finally it classifies the Hopf Galois structures in Hopf algebra isomorphism classes. In the case of prime degree, we obtain the results already found in [4] theorem 2 and [15] theorem 5.2, namely that if e its Galois closure, then L/K L/K is a separable field extension of prime degree and L e has a Hopf Galois structure if and only if Gal(L/K) is solvable and, in this case, the Hopf Galois structure is unique. We note that the case of degree 8 is especially interesting since there are 5 groups of order 8, up to isomorphism. We detail the results obtained in this case in Tables 1, 2 and 3. By performing an analysis of the outputs of our algorithm, we have deduced several general behaviours. We prove that a separable field extension of degree p2 , for p an odd prime, has at most one type of Hopf Galois structures and describe the ones of cyclic type. We determine the Hopf Galois structures of separable field extensions of degree 2p, for p an odd prime. We prove that an almost classically Hopf Galois structure stands alone in its Hopf algebra isomorphism class. 2 Extensions of degree p2, for p an odd prime For p prime, there are exactly two groups of order p2 , up to isomorphism, the cyclic one Cp2 and the direct product of two copies of Cp , hence two possible types for a Hopf Galois structure of a field extension of degree p2 . We shall prove that the two types do not occur simultaneously, when p 6= 2. This fact was suggested to us by the algorithm output for g = 9. The case p = 2 goes differently. Both Galois extensions of degree 4 and separable extensions of degree 4 whose Galois closure has Galois group the dihedral group D2·4 have Hopf Galois structures of cyclic type and of type C2 ×C2 . If we write Cp2 additively as Z/p2 Z, its holomorph is Z/p2 Z⋊(Z/p2 Z)∗ . For Cp ×Cp the automorphism group is isomorphic to GL(2, Fp ). Proposition 6. Let L/K be a separable field extension of degree p2 , p an odd prime, e e L/K its normal closure and G ≃ Gal(L/K). If L/K has a Hopf Galois structure of type Cp2 , then it has no structure of type Cp × Cp . Therefore a separable field extension of degree p2 , p an odd prime, has at most one type of Hopf Galois structures either cyclic or elementary abelian. Proof. By theorem 2, if L/K has a Hopf Galois structure of type Cp2 , then G is a transitive subgroup of Hol(Cp2 ). We shall see that all transitive subgroups of Hol(Cp2 ) contain an element of order p2 . Let us write Hol(Cp2 ) as Z/p2 Z ⋊ (Z/p2 Z)∗ and let σ be a generator of (Z/p2 Z)∗ . The immersion of Hol(Cp2 ) in the symmetric group Sp2 is 3 given by sending the generator 1 of Z/p2 Z to the p2 -cycle (1, 2, . . . , p2 ) and σ to itself, considered as a permutation. The stabilizer of 1 in the image H of Hol(Cp2 ) in Sp2 consists in the elements (1 − k j , σ j ), where k = σ(1) and 1 − k j is computed modulo p2 . We have |H| = |Hol(Cp2 )| = p3 (p − 1), hence H has a unique p-Sylow subgroup Syl(H) which is isomorphic to the only non-abelian group of order p3 having an element of order p2 (see [7]). Now, a subgroup H ′ of H is transitive if and only if [H ′ : StabH (1)∩H ′] = p2 . Let H ′ be a transitive subgroup of H. We have then p2 | |H ′ | and |H ′| | p3 (p − 1), hence H ′ has a unique p-Sylow subgroup Syl(H ′) which has order p3 or p2 . In the first case, Syl(H ′) = Syl(H) contains an element of order p2 . In the second case, Syl(H ′) is a subgroup of Syl(H) of order p2 . The group Syl(H) is isomorphic to the group ( ! ) 1 + pm b Gp := : m, b ∈ Z/p2 Z , 0 1 where m actually only matters modulo p. The group Gp has p3 − p2 elements of order p2 , those with b 6≡ 0 (mod p), hence p cyclic subgroups of order p2 and p2 − 1 elements of order p, those nontrivial with b ≡ 0 (mod p), hence one noncyclic subgroup of order p2 . Then H ′ contains an element of order p2 except in the case in which Syl(H ′) is isomorphic to the noncyclic subgroup of order p2 of Gp . The corresponding subgroup of Hol(Cp2 ) is generated by (p, Id) and (0, σ p−1 ). Its intersection with StabH (1) consists in the elements (1 − k l(p−1) , σ l(p−1) ), 1 ≤ l ≤ p, since k p−1 ≡ 1 (mod p), hence this intersection has order p. We have then that if Syl(H) is isomorphic to the noncyclic subgroup of order p2 of Gp , then p divides exactly [H ′ : StabH (1) ∩ H ′] and H ′ is not transitive. We have proved then that all transitive subgroups of Hol(Cp2 ) contain an element of order p2 . Let us look now at Hol(Cp × Cp ). By [13], Theorem 4.4, Hol(Cp × Cp ) has no elements of order p2 . Taking into account what we have proved above, this finishes the proof of the proposition. ✷ Remark 7. Kohl proves in [13] that any Hopf Galois structure on a cyclic extension of order pn , for p an odd prime, is of cyclic type. Childs studies in [6] these Hopf Galois structures in the case of cyclic extensions of order p2 . We give a more precise description of the Hopf Galois structures of cyclic type on separable field extensions of degree p2 in the next theorem. e Theorem 8. Let L/K be a separable field extension of degree p2 , p an odd prime, L/K e its normal closure and G ≃ Gal(L/K). The extension L/K has a Hopf Galois structure of cyclic type if and only if G is isomorphic to the semidirect product Cp2 ⋊ Cm , for m a divisor of p(p − 1). The number of structures is p for m = 1 and m = p and is equal to 1 in the remaining cases. Proof. We have proved that all transitive subgroups of Hol(Cp2 ) have an element of order p2 . Reciprocally a subgroup of Hol(Cp2 ) having an element of order p2 is transitive. Let us write Hol(Cp2 ) = h1, σi, as above. The subgroups of order p2 of Hol(Cp2 ) are h(1, σ j(p−1))i, for j = 0, . . . , p − 1. We obtain then that the transitive subgroups of Hol(Cp2 ) are these p groups of order p2 and one group isomorphic to Cp2 ⋊ Cm , for each divisor m of p(p − 1), m 6= 1, namely h(1, σ j(p−1)), (0, σ p(p−1)/m )i. We count the number of structures using Corollary 3. For G ≃ Cp2 , the number of structures is clearly equal to the number of transitive subgroups of Hol(Cp2 ) isomorphic to Cp2 , hence p. For G = ha, bi, with a = (1, σ j(p−1) ), b = (0, σ p(p−1)/m ), we have G′ = hbi. An automorphism 4 of G sending G′ to G′ must be the identity on G′ . Now the image of a must be ai , with gcd(i, p) = 1, when m 6= p, hence | Aut(G, G′ )| = | Aut(N)| and the number of structures is 1. When m = p, the image of a may be ai b(p−1)j , with gcd(i, p) = 1, and 0 ≤ j ≤ p − 1. Hence | Aut(G, G′ )| = p2 (p − 1) = p| Aut(N)| and the number of structures is p. ✷ 3 Extensions of degree 2p, for p an odd prime In the next two theorems we determine the Hopf Galois structures of separable field extensions of degree 2p, where p is an odd prime. This result was suggested by the output of our algorithm for degree 6 and 10 extensions. We note that the case of Galois extensions was already obtained by Byott in [2] and by Kohl in [14]. e Theorem 9. Let L/K be a separable field extension of degree 2p, p an odd prime, L/K e its normal closure and G ≃ Gal(L/K). L/K has a Hopf Galois structure of cyclic type if and only if G is isomorphic to either (i) the semidirect product C2p ⋊ Cm of a cyclic group of order 2p and a cyclic group of order m dividing p − 1 (ii) or the semidirect product Cp ⋊ Cm of a cyclic group of order p and a cyclic group of even order m dividing p − 1. The number of structures is 1, except in case (ii), for m = 1, when this number is p. In this last case, G is isomorphic to the dihedral group D2p . Proof. By theorem 2, if L/K has a Hopf Galois structure of type C2p , then G is a transitive subgroup of Hol(C2p ). We have that Hol(C2p ) ≃ C2p ⋊ Cp−1 = ha, b | a2p = 1, bp−1 = 1, bab−1 = ai i, where i has order p − 1 modulo 2p. By ordering the elements in C2p as a, a2 , · · · , a2p = 1, we obtain the embedding of Hol(C2p ) in the symmetric group S2p mapping a to (1, 2, · · · , 2p) and b to a permutation of order p − 1 sending any number in {1, 2, · · · , 2p} to one with the same parity. Let G be a transitive group of degree 2p. The order |G| of G is a multiple of 2p, then G contains an element of order p. Since the only subgroup of order p of Hol(C2p ) is ha2 i, then G contains a2 . Moreover, in order to be transitive, it must contain an element sending 2p to 1. Such elements in Hol(C2p ) are exactly those of the form aj bk , with j odd. Now ha2 , aj bk i = ha2 , abk i if j is odd. The transitive subgroups of Hol(C2p ) containing a are clearly ha, b(p−1)/m i ≃ C2p ⋊ Cm , where m ranges over the positive divisors of p − 1. This gives case (i). Let us assume now that a 6∈ G. If |G| = 2pm, then G contains exactly m elements sending 2p to 1. Let us determine the number of elements sending 2p to 1 in Gk := k k (l−1)k kl ha2 , abk i. Since (abk )a2 (abk )−1 = a2i , we have (abk )l = a1+i +···+i b and we obtain kl k that Gk contains the elements ab , with l odd. If the order of b is odd, then a ∈ Gk . If the order n of bk is even, then Gk contains n/2 elements sending 2p to 1, namely abkl , with l odd, 1 ≤ j ≤ n − 1. Moreover, the elements of order n in hbi are among the elements bkl , with l odd, 1 ≤ j ≤ n − 1. We have then that the transitive subgroups of Hol(C2p ) not containing a are ha2 , ab(p−1)/2m i ≃ Cp ⋊ Cm , where m ranges over the even positive divisors of p − 1. This gives case (ii). 5 We determine now the number of structures by using Corollary 3. For N = C2p , we have | Aut(N)| = p −1. We have exactly one subgroup of Hol(C2p ) for each isomorphism class of G. For the groups G = ha, b(p−1)/m i, the stabilizer G′ of 2p is hb(p−1)/m i. The image of a under an automorphism of G is aj , with j coprime with 2p. Since bab−1 = ai , we have that an automorphism of G sending G′ to G′ must send b(p−1)/m to itself. We obtain then | Aut(G, G′)| = | Aut(N)|, hence the number of Hopf Galois structures is 1. For the groups ha2 , ab(p−1)/2m i, the stabilizer G′ of 2p is hb(p−1)/m i. If m = 1, G ≃ D2p and we obtain | Aut(G, G′ )| = p(p − 1), hence the number of Hopf Galois structures is p. If m > 1, taking into account the conjugate of a2 by ab(p−1)/2m , we obtain that an automorphism of G sending G′ to G′ must send ab(p−1)/2m to itself, hence | Aut(G, G′ )| = | Aut(N)| and the number of Hopf Galois structures is 1. ✷ Theorem 10. Let L/K be a separable field extension of degree 2p, p an odd prime, e e L/K its normal closure and G ≃ Gal(L/K). The extension L/K has a Hopf Galois structure of dihedral type if and only if G is isomorphic to either (i) the semidirect product (Cp × Cp ) ⋊ Cm of the direct product of two cyclic groups of order p and a cyclic group of even order m dividing p − 1; (ii) or the semidirect product (Cp × Cp ) ⋊ (C2 × Cm ) of the direct product of two cyclic groups of order p and the direct product of a cyclic group of order 2 and a cyclic group of even order m dividing p − 1; (iii) or the semidirect product C2p ⋊ Cm of a cyclic group of order 2p and a cyclic group of order m dividing p − 1; (iv) or the semidirect product Cp ⋊ Cm of a cyclic group of order p and a cyclic group of even order m dividing p − 1. The number of structures is always 2. Proof. By theorem 2, if L/K has a Hopf Galois structure of type D2p , then G is a transitive subgroup of Hol(D2p ). Let us write D2p = hρ, σ | ρp = 1, σ 2 = 1, σρσ = ρ−1 i. The automorphism group of D2p is generated by ϕ and ψ determined by ϕ(ρ) = ρ, ϕ(σ) = σρ and ψ(ρ) = ρi , ψ(σ) = σ, where i is a generator of (Z/pZ)∗ , and satisfying ψϕψ −1 = ϕi . We obtain then that Hol(D2p ) is generated by ρ, σ, ϕ, ψ with the relations ρp = 1, σ 2 = 1, ϕp = 1, ψ p−1 = 1, σρσ = ρ−1 , ψϕψ −1 = ϕi , σϕσ = ρϕ, ψρψ −1 = ρi , ρϕ = ϕρ, σψ = ψσ and is isomorphic to (Cp × Cp ) ⋊ (C2 × Cp−1). By ordering the elements in D2p as ρ, ρ2 , · · · , ρp = 1, σρ, σρ2 , · · · , σρp = σ, we obtain the embedding of Hol(D2p ) in the symmetric group S2p mapping ρ to (1, 2, · · · , p)(2p, 2p − 1, · · · , p + 1), σ to (1, p + 1)(2, p + 2), · · · (p, 2p), ϕ to (p + 1, p + 2, · · · , 2p) and ψ to (1, i, i2 , · · · , ip−2)(p + 1, p + i, p + i2 , · · · , p + ip−2 ), where the powers of i are computed modulo p. If G is a transitive subgroup of Hol(D2p ), then 2p divides the order |G| of G, hence G contains an element of order p which belongs to the p-Sylow subgroup hρ, ϕi of Hol(D2p ). We distinguish two cases, depending on wether the p-Sylow subgroup of G has order p or p2 . 6 Case 1. If the p-Sylow subgroup of G has order p2 , then it is hρ, ϕi. If G is transitive, it must contain a permutation sending p to 2p and if |G| = 2mp, then it contains m elements sending p to 2p. The elements in Hol(D2p ) sending p to 2p are those of the form σx, with x ∈ Stab(p) = hϕ, ψi. We determine now the order of these elements. First the order of σ is 2. If 0 < j ≤ p − 1, we have (σϕj )n = ρjn/2 ϕjn , if n is even, and (σϕj )n = σρj(n−1)/2 ϕjn , if n is odd. Hence the order of σϕj is 2p. If 0 ≤ j ≤ p − 1 P(n−2)/2 2mk Pn−1 mk and 0 < k < p − 1, we have (σϕj ψ k )n = ρj( m=0 i ) ϕj( m=0 i ) , if n is even, and P(n−3)/2 (2m+1)k P mk ) j( n−1 (σϕj ψ k )n = σρj( m=0 i ϕ m=0 i ) , if n is odd. Hence the order of σϕj ψ k is equal to the order of ψ k if this order is even and equal to twice the order of ψ k if this order is odd. We obtain then the following transitive subgroups of Hol(D2p ) having a p-Sylow group of order p2 : a) hϕ, ρ, σ, ψ 2(p−1)/m i ≃ hϕ, ρ, σψ (p−1)/2 , ψ 2(p−1)/m i ≃ (Cp × Cp ) ⋊ Cm , for m a divisor of p − 1, exactly divisible by 2. b) hϕ, ρ, σψ (p−1)/m i ≃ (Cp × Cp ) ⋊ Cm , for m a divisor of p − 1, divisible by 4. c) hϕ, ρ, σ, ψ (p−1)/m i ≃ (Cp × Cp ) ⋊ (C2 × Cm ), for m an even divisor of p − 1. The groups of types a) and b) correspond to (i) in the statement and those of type c) correspond to (ii). We determine now the number of structures by using Corollary 3. For N = D2p , we have | Aut(N)| = p(p − 1). The stabilizer G′ of p is hϕ, ψ k i, where k = 2(p − 1)/m in cases a) and b) and k = (p − 1)/m in case c). We determine now the automorphisms of G sending G′ to G′ . Let h be such an automorphism. The image of ϕ under h must be ϕj1 , with 1 ≤ j1 ≤ p − 1 and, taking into account the action of ψ on ϕ, h must send ψ k to ϕj2 ψ k , with 0 ≤ j2 ≤ p − 1. The image of ρ under h must belong to hρ, ϕi and, since σ has order 2 and commutes with ψ, the image of σ under h must be an order 2 element in hσ, ψi, hence σ, or σψ (p−1)/2 , in case ψ (p−1)/2 belongs to G, i.e. for cases b) and c). Taking into account the action of σ on ϕ and ρ, we obtain that the elements in Aut(G, G′ ) are of one of the following forms, with 1 ≤ j1 ≤ p − 1, 0 ≤ j2 ≤ p − 1 and the second form not occurring in case a). ϕ 7→ ϕj1 ϕ 7→ ϕj1 ψ 7→ ϕj2 ψ ψ 7→ ϕj2 ψ ρ 7→ ρj1 ρ 7→ ρ−j1 ϕ−2j1 σ 7→ σψ (p−1)/2 σ 7→ σ We obtain then | Aut(G, G′ )| = | Aut(N)| in case a) and | Aut(G, G′ )| = 2| Aut(N)| in cases b) and c). Hence in all three cases, the number of Hopf Galois structures is 2. Case 2. We consider now the case when the p-Sylow subgroup of G has order p. The subgroups of order p of Hol(D2p ) are hρϕj i, with 0 ≤ j ≤ p − 1, and hϕi. To be transitive, G must contain an element sending p to 2p, hence an element in σhϕ, ψi. Since the normalizers in Hol(D2p ) of hρϕj i, if j 6∈ {0, 2}, and the one of hϕi reduce to hρ, ϕ, ψi, the p-Sylow subgroup of G is hxi, where x = ρ or x = ρϕ2 . If G ≃ D2p , G must contain an element y of order 2 satisfying yxy = x−1 and sending p to 2p. We obtain then the groups hρ, σi ≃ hρϕ2 , σψ (p−1)/2 i ≃ D2p . If G ≃ C2p , G must contain an element y of order 2 sending p to some element in {p + 1, · · · , 2p} and commuting with x. We have y = σψ (p−1)/2 (ρϕ2 )j , for x = ρ and y = σρk for x = ρϕ2 . We obtain 7 then the groups hσψ (p−1)/2 ρj+1 ϕ2j i ≃ hσρk ϕi ≃ C2p , 0 ≤ j ≤ p − 1, 0 ≤ k ≤ p − 1. If a subgroup of Hol(D2p ) contains one of these copies of C2p , then it is transitive. By computation, we obtain that the only subgroups of Hol(D2p ) strictly containing hσψ (p−1)/2 ρj+1 ϕ2j i and having a p-Sylow subgroup of order p are hσψ (p−1)/2 ρj+1 ϕ2j , l ϕj(−i +1)/2 ψ l i, where l = (p−1)/d, for some divisor d of p−1. Moreover hσψ (p−1)/2 ρj+1 ϕ2j i l is normal in such a group and the order of hσψ (p−1)/2 ρj+1 ϕ2j , ϕj(−i +1)/2 ψ l i is 2pd. Analogously, the only subgroups of Hol(D2p ) strictly containing hσρk ϕi and having a l p-Sylow subgroup of order p are hσρk ϕ, ϕ(i −1)((p+1)/2−k) ψ l i, where l = (p − 1)/d, for some divisor d of p − 1. Moreover hσρk ϕi is normal in such a group and the order of l hσρk ϕ, ϕ(i −1)((p+1)/2−k) ψ l i is 2pd. We have then 2p transitive subgroups of Hol(D2p ) isomorphic to the semidirect product C2p ⋊ Cd , for each divisor d of p − 1. This gives case (iii) in the statement. Finally, if G has no element of order 2p, it must contain an element sending p to 2p. Such elements in Hol(D2p ) are of the form σϕk ψ l . The order of σϕk ψ l is equal to the order of ψ l (resp. twice the order of ψ l ) if this order is even (resp. odd). Taking into account that σψ (p−1)/2 commutes with ρ, we obtain the groups hρ, σψ (p−1)/d i ≃ Cp ⋊Cd , for d a divisor of p − 1, such that d is divisible by 4, and the groups hρ, σψ 2(p−1)/d i ≃ Cp ⋊ Cd , for d a divisor of p − 1, such that d is exactly divisible by 2. Taking into account that σ commutes with ρϕ2 , we obtain the groups hρ, σψ (p−1)/d i ≃ Cp ⋊ Cd , for d an even divisor of p−1. We have then 2p transitive subgroups of Hol(D2p ) isomorphic to the semidirect product Cp ⋊ Cd , for each even divisor d of p − 1. This gives case (iv) in the statement. We determine now the number of structures by using Corollary 3. Taking into account that | Aut(N)| = | Aut(D2p )| = p(p − 1), that | Aut(C2p )| = | Aut(Cp )| = p − 1 and that for all groups G described above, an automorphism sending G′ to G′ must restrict on G′ to identity, we obtain that the number of structures is always 2. ✷ 4 Almost classically Galois Hopf Galois structures By looking at the distribution in Hopf algebra isomorphism classes of the Hopf Galois structures of a given separable extension provided by our algorithm we have deduced the following result. Proposition 11. Let L/K be a separable field extension of degree g. Let (H, µ) be an almost classically Galois structure on L/K and (H′ , µ′) a Hopf Galois structure on L/K. If the Hopf algebras H and H′ are K-isomorphic, then the Hopf Galois structures (H, µ) and (H′ , µ′) are isomorphic. Hence an almost classically Galois structure stands alone in its Hopf algebra isomorphism class. e be a Galois closure of L/K, G = Gal(L/K), e e Proof. Let L G′ = Gal(L/L), let λ : G → Sg be the monomorphism from G into the symmetric group Sg given by the action of G on the left cosets G/G′ . By Theorem 1 and [12] Proposition 4.1, (H, µ) corresponds to a regular subgroup N of Sg , normalized by λ(G) and such that the centralizer Z of N in Sg is contained in λ(G) and (H′ , µ′ ) corresponds to a regular subgroup N ′ of Sg , normalized by λ(G). We know also that an isomorphism from H to H′ corresponds to a λ(G)-isomorphism from N to N ′ . If f is such an isomorphism, we have σf (n)σ −1 = f (σnσ −1 ), for all σ ∈ λ(G) and n ∈ N. Now, since Z ⊂ λ(G), we have, for all z ∈ Z, n ∈ N, zf (n)z −1 = f (znz −1 ) = f (n). This implies that N ′ = f (N) is contained 8 in the centralizer of Z in Sg . Since N is regular, this centralizer coincides with N. We have then N ′ = N and, again by Theorem 1, this implies that the Hopf Galois structures (H, µ) and (H′ , µ′ ) are isomorphic. ✷ 5 Description of the algorithm e its Galois closure, G = Gal(L/K), e Given a separable field extension L/K of degree g, L ′ ′ e G = Gal(L/L), the action of G on the left cosets G/G is transitive, hence the morphism λ : G → Sg identifies G with a transitive subgroup of Sg , which is determined up to conjugation. Moreover, if we enumerate the left cosets G/G′ starting with the one containing 1G , λ(G′ ) is equal to the stabilizer of 1 in G. Therefore considering all separable field extensions L/K of degree g is equivalent to considering all transitive groups G of degree g, up to conjugation. The algorithm structure is as follows: Step 1 Given a transitive group G of degree g and a type of regular subgroups N of Sg , run over the conjugation class of N in Sg and determine whether N is normalized by G. In the affirmative case, check if the centralizer Z(N) of N in Sg is contained in G. If it is so, the Hopf Galois structure determined by N is almost classically Galois. Step 2 For each transitive group G of degree g and G′ = StabG (1), determine the number intf ields(G) of subgroups of G containing G′ , that is, by the fundamental theorem of classical Galois theory, the number of intermediate fields of the extension L/K. Step 3 For each pair (G, N) determined in Step 1, determine the number subGst(N) of G-stable subgroups of N, i.e. subgroups of N normalized by G, that is, the cardinal of the image of the map FH in Theorem 4 for the Hopf Galois structure given by N. Check if this number equals intf ields(G), that is if the Galois correspondence is bijective. Step 4 For each pair (G, N), (G, N ′ ), with N ≃ N ′ and subGst(N) = subGst(N ′ ), check if N and N ′ are G-isomorphic, that is if the corresponding Hopf algebras are isomorphic. To this end, we use that for a regular subgroup N of the symmetric group Sg , the automorphism group Aut(N) of N is isomorphic to the stabilizer of 1 in the holomorph Hol(N) of N and that Hol(N) is the normalizer of N in Sg . We note that in Step 1 we compute the transversal of the normalizer of N in Sg and the conjugate of N by each element in this transversal. This computation occurs to need a significantly shorter execution time than the use of the Magma function Class from degree 9 onwards. In the vector which collects the regular subgroups N of Sg giving a Hopf Galois structure we have added a numbering variable. In this way, each of these N’s is identified with an integer number. This numeration is respected all along the program so that, once the N’s have been computed in Step 1, we can easily know the properties of the corresponding Hopf Galois structures by searching the assigned number. This greatly simplifies the reading and interpretation of the results. The Magma code of this algorithm may be found in [11]. 9 6 Algorithm output We present the results obtained for separable field extensions of degree 8 in Tables 1, 2 and 3 in the appendix. We denote by kT i the ith transitive group of degree k called by TransitiveGroup(k, i) in the Magma program. In Tables 1 and 2, for each transitive group G of degree 8 and each group N of order 8, we give the total number T of Hopf Galois structures of type N for a separable field extension L/K of degree 8 such e over K is isomorphic to G. Moreover, that the Galois group of the normal closure L we give the number a-c of those which are almost classically Galois, the number BC of those for which the Galois correspondence is bijective and the number G-i of Hopf algebra isomorphism classes in which the Hopf Galois structures are partitioned. In particular the difference BC minus a-c gives the number of non almost classically Galois Hopf Galois structures for which the Galois correspondence is bijective. The transitive groups G such that the corresponding field extension L/K has no Hopf Galois structure are not included in the table. We note that the field extension with smallest degree having a non almost classically Galois Hopf Galois structure with bijective Galois correspondence is a Galois extension of degree 4 with Galois group C4 and Hopf Galois structure of type C2 × C2 . The nonGalois extension with smallest degree having this property is a separable extension of degree 6 whose Galois closure has group 6T 5 and the Hopf Galois structure is of type S3 . The field extension with smallest degree having non-isomorphic Hopf Galois structures with isomorphic Hopf algebras is a Galois extension of degree 6 with Galois group the symmetric group S3 for which the three Hopf Galois structures of cyclic type C6 have underlying isomorphic Hopf algebras. In table 3 we give the distribution of Hopf Galois structures in Hopf algebra isomorphism classes for transitive groups of degree 8 having some class with more that one element. For example, in the cell corresponding to G = N = C4 ×C2 , 10 = 5×1+1×2+1×3 means that for a Galois extension with Galois group C4 × C2 there are 10 Hopf Galois structures of type C4 × C2 which are distributed in 5 classes with 1 element, 1 class with 2 elements and 1 class with 3 elements. Table 4 is a compendium of the results obtained with the algorithm. In it we give for every degree g the order of the symmetric group Sg of degree g; the total number of transitive groups of degree g and the number Max of transitive groups of degree g whose order does not exceed the order of the holomorphs of all the groups of order g; the number of possible types of Hopf Galois structures; the total number of Hopf Galois structures and the number of the almost classically Galois ones; the number of Hopf Galois structures with bijective Galois correspondence and the number of those which are not almost classically Galois; the number of Hopf algebra isomorphism classes in which the Hopf Galois structures are partitioned (which correspond to G-isomorphism classes of the corresponding regular groups N) and the number of those for Galois extensions; and finally the execution times in seconds and the memory used in megabytes. We note that the presented program is very efficient up to degree 11. One may observe in particular that the computation for degree 8, which gives a large number of Hopf Galois structures, takes only about 17 seconds. The memory used reaches 160 megabytes for degree 11. The reader may find in [11] for each degree g up to 11, the output of the algorithm containing in particular, the precise description of the regular subgroups N of Sg 10 corresponding to the Hopf Galois structures as well as tables summarizing these results. 6.1 Conclusions The elaboration of the algorithm presented allows to determine all Hopf Galois structures of separable field extensions of a given degree up to degree 11. Such a determination has been obtained by theoretic tools only for prime degree extensions. Besides, a careful inspection of the data provided by the algorithm has led us to obtain several theoretic results. In proposition 6 we prove a partial result concerning Hopf Galois structures of separable field extensions of degree p2 , for p an odd prime, and describe in theorem 8 those of cyclic type. This result came up from the output of the algorithm for degree 9 extensions. In theorems 9 and 10 we determine Hopf Galois structures of separable field extensions of degree 2p, for p an odd prime. This result was suggested by the output for degrees 6 and 10 extensions. In general Hopf Galois structures may not be determined by theoretic reasoning, therefore it is valuable to have the presented algorithm at disposal. We specially highlight the richness of results obtained in the degree 8 case. 6.2 Example We consider a Galois extension L/K with Galois group G = C2 × C2 × C2 . As given in table 3, it has 42 Hopf Galois structures of type D2·4 partitioned in 7 Hopf algebra isomorphism classes of 6 elements each. We will examine in detail one of these classes and determine the corresponding Hopf algebra and Galois actions. We may write L = K(α, β, γ), with α2 , β 2 , γ 2 ∈ K and G is then generated by the automorphisms a, b, c given by a : α 7→ −α b : α 7→ α c : α 7→ α β . β 7→ β , β 7→ −β , β 7→ γ 7→ γ γ 7→ γ 7→ −γ γ The group C2 ×C2 ×C2 ≃ 8T 3 is given in Magma as the subgroup of the symmetric group generated by (1, 8)(2, 3)(4, 5)(6, 7), (1, 3)(2, 8)(4, 6)(5, 7), (1, 5)(2, 6)(3, 7)(4, 8). If we order the elements in G as Id, ab, b, ac, c, abc, bc, a, we have λ(a) = (1, 8)(2, 3)(4, 5)(6, 7), λ(b) = (1, 3)(2, 8)(4, 6)(5, 7), λ(c) = (1, 5)(2, 6)(3, 7)(4, 8) and we shall identify G with its image by λ. The following regular subgroups of S8 are isomorphic to D2·4 , normalized by G and mutually G-isomorphic. N1 = hs1 = (1, 8)(2, 3)(4, 5)(6, 7), r1 = (1, 6, 5, 2), (3, 4, 7, 8)i, N2 = hs2 = (1, 8)(2, 3)(4, 5)(6, 7), r2 = (1, 4, 7, 2), (3, 6, 5, 8)i, N3 = hs3 = (1, 6)(2, 5)(3, 4)(7, 8), r3 = (1, 4, 5, 8), (2, 3, 6, 7)i, N4 = hs4 = (1, 2)(3, 8)(4, 7)(5, 6), r4 = (1, 4, 3, 6), (2, 5, 8, 7)i, N5 = hs5 = (1, 6)(2, 5)(3, 4)(7, 8), r5 = (1, 2, 3, 8), (4, 5, 6, 7)i, N6 = hs6 = (1, 4)(2, 7)(3, 6)(5, 8), r6 = (1, 6, 7, 8), (2, 3, 4, 5)i. We check that ari a = ri3 , bri b = ri , cri c = ri , asi a = si , bsi b = si , csi c = si , 1 ≤ i ≤ 6, hence Ni is normalized by G, for 1 ≤ i ≤ 6 and si 7→ sj , ri 7→ rj defines a G-isomorphism from Ni to Nj , 1 ≤ i, j ≤ 6. 11 By computation, we obtain that the Hopf algebra corresponding to Ni is the K-Hopf algebra with basis 1, ri + ri3 , ri2 , α(ri − ri3 ), si , si ri + si ri3 , si ri2 , α(si ri − si ri3 ) and the Hopf actions are given by r1 7→ ab, r12 7→ c, r2 7→ ab, r22 7→ bc, r23 7→ ac, s2 7→ a, r3 7→ a, r32 7→ c, r33 7→ ac, s3 7→ abc, s3 r3 7→ b, r4 7→ abc, r42 7→ b, r43 7→ ac, s4 7→ ab, r53 7→ a, s5 7→ abc, s5 r5 7→ c, s5 r52 7→ ac, s5 r53 7→ bc s6 7→ ac, s6 r62 7→ ab, s6 r63 7→ c r5 7→ ab, r52 7→ b, r13 7→ abc, s1 7→ a, r6 7→ abc, r62 7→ bc, r63 7→ a, s1 r1 7→ bc, s1 r12 7→ ac, s2 r2 7→ c, s2 r22 7→ abc, s2 r23 7→ b s3 r32 7→ ab, s4 r4 7→ bc, s4 r42 7→ a, s6 r6 7→ b, s1 r13 7→ b s3 r33 7→ bc s4 r43 7→ c A different explicit example can be found in [16], Example 5.3.1. Acknowledgments We are grateful to Anna Rio and Montserrat Vela for valuable discussions on the subject of this paper and to Joan Nualart and Pawel Bogdan for their help with the Magma program. References [1] N.P. Byott, Uniqueness of Hopf Galois structure for separable field extensions. Comm. Algebra 24 (1996), 3217-3228. Corrigendum, ibid., 3705. [2] N.P. Byott, Hopf-Galois structures on Galois field extensions of degree pq. J. Pure App. Algebra 188 (2004), 45-57. [3] S.U. Chase, M. Sweedler, Hopf Algebras and Galois Theory. Lecture Notes in Mathematics, Vol. 97, Springer Verlag, 1969. [4] L. N. Childs, On the Hopf Galois theory for separable field extensions. Comm. Algebra 17 (1989), 809-825. [5] L. N. Childs, Taming wild extensions: Hopf algebras and local Galois module theory, AMS 2000. [6] L. N. Childs, Hopf Galois Structures on Degree p2 Cyclic Extensions of Local Fields, New York J. Math. 2 (1996), 86-102. [7] K. Conrad, Groups of order p3 , www.math.uconn.edu/∼conrad/blurbs/grouptheory/ groupsp3.pdf [8] T. Crespo, A. Rio, M. Vela, The Hopf Galois property in subfield lattices, Comm. Algebra 44 (2016), 336-353. [9] T. Crespo, A. Rio, M. Vela, On the Galois correspondence theorem in separable Hopf Galois theory, Publ. Mat. 60 (2016), 221-234. 12 [10] T. Crespo, A. Rio, M. Vela, Non-isomorphic Hopf Galois structures with isomorphic underlying Hopf algebras, J. Algebra 422 (2015), 270-276. [11] T. Crespo, M. Salguero, Algorithmic Hopf Galois theory: Magma code, tables and results, https://sites.google.com/site/algorithmichg/ [12] C. Greither, B. Pareigis, Hopf Galois theory for separable field extensions. J. Algebra 106 (1987), 239-258. [13] T. Kohl, Classification of the Hopf Galois Structures on Prime Power Radical Extensions, J. Algebra, 207 (1998), 525-546. [14] T. Kohl, Regular permutation groups of order mp and Hopf Galois structures. Algebra Number Theory 7 (2013), no. 9, 2203-2240. [15] B. Pareigis, Forms of Hopf algebras and Galois theory in “Topics in Algebra, Part 1” (Warsaw, 1988), 75-93, Banach Center Publ., 26, Part 1, PWN, Warsaw, 1990. [16] M. Salguero, Hopf Galois theory of separable field extensions, graduate thesis, June 2016, http://diposit.ub.edu/dspace/bitstream/2445/110365/2/memoria.pdf 13 Appendix - Tables Table 1: Degree 8 extensions Hopf Galois structures Type C4 × C2 Type C8 Galois Type C2 × C2 × C2 Type D2·4 Type Q8 14 group T a-c BC G-i T a-c BC G-i T a-c BC G-i T a-c BC G-i T a-c BC G-i 8T 1 ≃ C8 2 1 2 2 0 - - - 0 - - - 2 0 2 2 2 0 2 2 8T 2 ≃ C4 × C2 4 0 0 2 10 1 1 7 4 0 1 4 6 0 2 5 2 0 0 2 8T 3 ≃ (C2 )3 0 - - - 42 0 0 28 8 1 1 8 42 0 0 7 14 0 0 7 8T 4 ≃ D2·4 2 0 0 1 14 0 0 9 6 0 0 4 6 1 1 4 2 0 0 2 8T 5 ≃ Q8 6 0 0 3 6 0 6 3 2 0 2 1 6 0 6 6 2 1 2 2 8T 6 2 1 2 2 0 - - - 0 - - - 2 1 2 2 2 0 2 2 8T 7 2 2 2 2 0 - - - 0 - - - 2 0 2 2 2 0 2 2 8T 8 2 1 2 2 0 - - - 0 - - - 2 0 2 2 2 1 2 2 8T 9 0 - - - 10 1 1 9 4 1 1 4 6 2 2 5 2 0 0 2 8T 10 0 - - - 6 2 3 6 4 0 1 4 0 - - - 0 - - - 8T 11 2 0 0 1 6 2 6 5 2 0 2 2 6 1 6 6 2 1 2 2 8T 12 0 - - - 0 - - - 2 0 2 1 0 - - - 2 1 2 2 8T 13 0 - - - 0 - - - 2 1 1 2 0 - - - 2 0 0 1 8T 14 0 - - - 0 - - - 4 0 1 3 0 - - - 0 - - - 8T 15 2 2 2 2 0 - - - 0 - - - 2 1 2 2 2 1 2 2 8T 16 0 - - - 0 - - - 0 - - - 2 0 2 2 2 0 2 2 8T 17 0 - - - 0 - - - 0 - - - 2 1 2 2 2 1 2 2 8T 18 0 - - - 6 3 3 6 4 1 1 4 0 - - - 0 - - - Table 2: Degree 8 extensions (cont.) Hopf Galois structures Type C4 × C2 Type C8 Galois Type C2 × C2 × C2 Type D2·4 Type Q8 15 group T a-c BC G-i T a-c BC G-i T a-c BC G-i T a-c BC G-i T a-c BC G-i 8T 19 0 - - - 2 1 2 2 2 1 2 2 0 - - - 0 - - - 8T 20 0 - - - 2 0 2 2 2 0 2 2 0 - - - 0 - - - 8T 22 0 - - - 6 6 6 6 2 2 2 2 6 6 6 6 2 2 2 2 8T 23 0 - - - 0 - - - 0 - - - 0 - - - 2 1 2 2 8T 24 0 - - - 0 - - - 2 1 1 2 0 - - - 0 - - - 8T 25 0 - - - 0 - - - 1 1 1 1 0 - - - 0 - - - 8T 26 0 - - - 0 - - - 0 - - - 2 2 2 2 2 2 2 2 8T 29 0 - - - 2 2 2 2 2 2 2 2 0 - - - 0 - - - 8T 32 0 - - - 0 - - - 2 2 2 2 0 - - - 2 2 2 2 8T 33 0 - - - 0 - - - 1 1 1 1 0 - - - 0 - - - 8T 34 0 - - - 0 - - - 3 0 3 3 0 - - - 0 - - - 8T 36 0 - - - 0 - - - 1 1 1 1 0 - - - 0 - - - 8T 37 0 - - - 0 - - - 2 0 2 2 0 - - - 0 - - - 8T 39 0 - - - 0 - - - 2 2 2 2 0 - - - 0 - - - 8T 40 0 - - - 0 - - - 0 - - - 0 - - - 2 2 2 2 8T 41 0 - - - 0 - - - 1 1 1 1 0 - - - 0 - - - 8T 48 0 - - - 0 - - - 1 1 1 1 0 - - - 0 - - - Table 3: Hopf algebra isomorphism classes for degree 8 extensions Isomorphism classes Galois group Type C8 Type C4 × C2 Type C2 × C2 × C2 Type D2·4 Type Q8 8T 2 ≃ C4 × C2 4=2×2 10 = 5 × 1 + 1 × 2 + 1 × 3 4=4×1 6 =4×1+1×2 2=2×1 8T 3 ≃ (C2 )3 0 42 = 21 × 1 + 7 × 3 8=8×1 42 = 7 × 6 14 = 7 × 2 8T 4 ≃ D2·4 2=1×2 14 = 4 × 1 + 5 × 2 6 =2×1+2×2 6 =3×1+1×3 2=2×1 8T 5 ≃ Q8 6=3×2 6=3×2 2=1×2 6= 6×1 2=2×1 8T 9 0 10 = 8 × 1 + 1 × 2 4=4×1 6 =4×1+1×2 2=2×1 8T 11 2=1×2 6= 4×1+1×2 2=2×1 6= 6×1 2=2×1 8T 12 0 0 2=1×2 0 2=2×1 8T 13 0 0 2=2×1 0 2=1×2 8T 14 0 0 4 =2×1+1×2 0 0 Table 4: Summary of results Degree Order Transitive Groups 16 Total Types Max HG struct. G-iso BC Execution time Memory used Total a-c Total not a-c Total Galois (s) (MB) 2 2 1 1 1 1 1 1 0 1 1 ≈1 ≈ 10 3 6 2 2 1 2 2 2 0 2 1 ≈1 ≈ 10 4 24 5 5 2 10 6 7 1 10 6 ≈1 ≈ 11 5 120 5 3 1 3 3 3 0 3 1 ≈1 ≈ 11 6 720 16 10 2 15 7 9 2 13 6 ≈2 ≈ 11 7 5,040 7 4 1 4 4 4 0 4 1 ≈1 ≈ 11 8 40,320 50 48 5 348 74 147 73 262 111 ≈ 17 ≈ 40 9 362,880 34 26 2 38 26 28 2 33 8 ≈ 10 ≈ 16 10 3,628,800 45 21 2 27 11 17 6 23 6 ≈ 160 ≈ 45 11 39,916,800 8 4 1 4 4 4 0 4 1 ≈ 90 ≈ 160
4math.GR
Place classification with a graph regularized deep neural network model arXiv:1506.03899v1 [cs.RO] 12 Jun 2015 Yiyi Liao1 , Sarath Kodagoda2 , Yue Wang1 , Lei Shi2 , Yong Liu3 Abstract— Place classification is a fundamental ability that a robot should possess to carry out effective human-robot interactions. It is a nontrivial classification problem which has attracted many research. In recent years, there is a high exploitation of Artificial Intelligent algorithms in robotics applications. Inspired by the recent successes of deep learning methods, we propose an end-to-end learning approach for the place classification problem. With the deep architectures, this methodology automatically discovers features and contributes in general to higher classification accuracies. The pipeline of our approach is composed of three parts. Firstly, we construct multiple layers of laser range data to represent the environment information in different levels of granularity. Secondly, each layer of data is fed into a deep neural network model for classification, where a graph regularization is imposed to the deep architecture for keeping local consistency between adjacent samples. Finally, the predicted labels obtained from all the layers are fused based on confidence trees to maximize the overall confidence. Experimental results validate the effectiveness of our end-to-end place classification framework in which both the multi-layer structure and the graph regularization promote the classification performance. Furthermore, results show that the features automatically learned from the raw input range data can achieve competitive results to the features constructed based on statistical and geometrical information. I. I NTRODUCTION Place classification is one of the important problems in human-robot interactions and mobile robotics, which aims to distinguish differences between environmental locations and assign a label (corridor, office, kitchen, etc.) to each location [33], [17]. It allows robots to achieve spatial awareness through semantic understanding rather than having to rely on precise coordinates in communicating with humans. Furthermore, the semantic labels has the potential to efficiently facilitate other robotic functions such as mapping [20], behavior-based navigation [16], task planning [7] and active object search and rescue [1]. In general, place classification is carried out through environment sensing. Laser range finders, cameras and RGBD sensors are the mostly used sensing modalities. Location and topological information can also be informative in place classification. In this work, it is attempted to exploit both the sensory data and location information. We assume all the maps in this paper contain these two parts of information and some of the maps are labeled with human knowledge. Then 1 Yiyi Liao and Yue Wang are with the Institute of Cyber-Systems and Control, Zhejiang University, Zhejiang, 310027, China. 2 Sarath Kodagoda and Lei Shi are with the Centre for Autonomous Systems (CAS), The University of Technology, Sydney, Australia. 3 Yong Liu is with the State Key Laboratory of Industrial Control Technology and Institute of Cyber-Systems and Control, Zhejiang University, Zhejiang, 310027, China (He is the corresponding author of this paper, email: [email protected]). the place classification problem can be stated as predicting the labels of new environments given the labeled maps. By analysing those two forms of data, sensory data and location information, we can gain insights into the characteristics of the place classification problem. Raw sensory data encode the environment information at different locations which can provide discriminative information between different classes. However, this requires an effective feature extraction method and most of the previous works tend to extract hand-engineered features from the raw data [15], [27]. Our opinion is that the hand held features, may not fully exploit the potential to achieve higher generalization ability. On the other hand, the locations encode the spatial information of the environment and indicate the local consistency of the labels, which means the positions at spatial proximity have higher probability to having the same class labels. It is to be noted that another difficulty in place classification is the influence of different field of views (FOV) of the sensors used. For example, if a laser range finder collects 180◦ FOV data facing approximately to a corner of a corridor, it may not contain enough information for classification. If the laser range finder collects 360◦ FOV data at a door of an office room, the robot might be confused to with mixed information from two classes. In order to address these problems, in this paper, we propose a graph regularized deep learning approach classification on multi-layer inputs. The pipeline of our system is illustrated in Fig. 1, which can be split into three parts: 1) Construction of multi-layer inputs: The environmental information in this paper is represented through the generalized Voronoi graph (GVG) [4], a topological graph in which the nodes correspond to the sensory data and the edges denote the relationships. By fusing the information and eliminating the end-nodes, we implement a recursive algorithm to construct multi-layer inputs with hierarchical GVGs. The inputs of higher layers contain information of larger field of view, represented by increasingly succinct GVG. The features are extracted from each layer of input and classified independently. 2) The graph regularized deep architecture for feature learning and classification: We adopt the deep architecture that learns features from the raw data automatically. A graph regularizer is imposed to the deep architecture to keep the local consistency, where an adjacency graph is constructed to depict the adjacency and similarity between the samples. Our training map and testing maps are fed into the deep architecture for feature learning at the same time, which forms a semi-supervised learning framework. The output of this step is the predicted labels of different layers. Fig. 1. Pipeline of the semi-supervised learning system with multi-layer inputs. 3) The confidence tree for decision making: After receiving the classification results of multi-layer inputs, confidence trees are constructed according to the topological graph, and a decision making process is carried out to maximize the overall confidence. The remainder of this paper is organized as follows: Section II reviews the related literature. In Section III, we introduce the construction of our multi-layer inputs and the confidence tree for decision making. The semisupervised classification with graph regularization is given in Section IV. Experimental results are presented in Section V to validate the effectiveness of our end-to-end classification framework. Then the paper is concluded in Section VI. II. R ELATED W ORKS There are various sensors that help robots to sense environments, such as cameras and laser range finders. Previous works have demonstrated the effectiveness of both camera data and laser range finder data for classifying places. For example, Shi et al. [26] and Viswanathan et al. [31] extracted features from the vision data, while Mozos et al. [15] and Sousa et al. [27] classified the places based on laser range data. In this paper, we focus on the place classification based on laser range data, however, our approach can be easily extended to other modality of sensors such as vision data. Laser range finders can provide nonnegative beam sequences describing range and bearing to nearby objects. They contain structural information including clutter in the environment. Mozos et al. [15] extracted features from the 360◦ laser range data and those features were fed into an Adaboost classifier to label the environment. Sousa et al. [27] reported superior results on a binary classification task using a subset of above mentioned features, and the support vector machine as the classifier. In our past work, we implemented a logistic regression based classifier, as a binary and multiclass problem contributing to higher accuracies [24], [25]. The work was further extended to address the generalizability of the solution through a semi-supervised place classification over a generalized Voronoi graph (SPCoGVG) [23]. In all of these methods, the features were extracted from the laser range data based on statistical and geometrical information, or so-called hand-engineered features. For instance, the average and the standard deviation of the beam length, the area and perimeter of the polygon specified by the observed range data and bearing were included in the feature set. Recently, the unsupervised feature learning has drawn much attention as the deep learning methods was developed [12], [11], [2]. The deep learning methods achieved remarkable results in many areas, including object recognition [3], [13], natural language processing [5], [8] and speech recognition [6], which demonstrated that discovering and extracting features automatically can usually achieve better results on representation learning [22], [21], [30]. Inspired by the success of unsupervised feature learning, in this article we present an end-to-end framework with the deep learning method that can learn features automatically from the laser range data. We also exploit the local consistency of classes with the assumption that samples located in the same small region are more likely to have the same labels. Previous research has included this particular characteristic for performance promotion and many studies were carried out with consideration of the local consistency [20], [18], [15], [14], [19]. In this paper, we consider the local consistency during the feature learning process, where, the features learn to keep the local invariance with a graph regularization. There are some similar works on implementing the graph regularized deep learning models [9], [32]. Both [9] and [32] utilized a margin-based loss function proposed by Hadsell et at. [10]. These works have demonstrated the effectiveness of the graph embedding in dimensionality reduction and image classification. III. M ULTI - LAYER C ONSTRUCTION AND D ECISION M AKING In this paper, we assume a laser range finder with a typical field of view of 180◦ . This is a limited field of view which can give rise to many classification inaccuracies due to lack of crucial information. However, the full field of view may also lead to misclassifications at the boundaries of the two different classes of places. Therefore, considering these problems, we propose to construct multi-layer inputs for classification followed by fusion of the results. Algorithm 1: Generate higher layer of input from the previous layer. (l) Input: G(l) = {V (l) , E (l) }, the range data ri on each (l) node vi (l+1) Output: G = {V (l+1) , E (l+1) }, the range data (l+1) (l+1) ri on each node vi A. Construction of Multi-layer Inputs 1) Data Representation on GVG: In this paper, our multilayer inputs is represented by the hierarchical generalized Voronoi graph (GVG) [4], a topological graph which has been successfully applied to navigation, localization and mapping. The general representation of GVG is composed of meet-points (locations of three-way or more equidistance to obstacles) and edges (feasible paths between meet-points which are two-way equidistance to obstacles) [28]. We adopt the same resolution as in our previous work [23] to construct the first layer GVG, and then higher layers of GVGs are constructed to describe the environment at different levels of granularity. Let’s denote hierarchical GVGs as hG(1) , G(2) , · · · , G(L) i with G(l) = {V (l) , E (l) }, where L denotes the number of layer, V (l) denotes nodes in layer l and E (l) denotes edges in layer l. For each layer, the independent sensing information is carried by the nodes in V (l) , and the local connectivity is represented by the edges in V (l) . More specifically, each (l) node vi ∈ V (l) corresponds to a sequence of range data (l) (l) ri , assigned with the label yi for the training maps, while (l) (l) (l) eij ∈ E reveals the connection between nodes vi and (l) (l) vj with distance dij . (1) The first layer G = {V (1) , E (1) } describes the environment in most detailed level of granularity with the originally adopted laser range data. As the laser range finder is of 180◦ field of view with 1◦ angular resolution, each node (1) (1) vi ∈ V (1) corresponds to a sequence of range data ri with 180 dimension. 2) Recursive Higher Layer Construction Algorithm: The construction of a higher layer GVG is implemented by fusing the information carried by connected nodes and then eliminating those marginal nodes. Algorithm 1 demonstrates the process of building higher layer GVG from a given lower layer. We make some definitions here for better explanation of the algorithm. N (vi ) is defined as the directly connected neighbour set of vi , then vj ∈ N (vi ) means there is an edge eij ∈ E between vi and vj . In addition, numel(N ) is defined as the number of elements contained in N . Then numel(N (vi )) = 1 means vi is an “end-node”, i.e. the node without children. Further define M (vi ) as the set of endnodes connected to vi , which is obviously M (vi ) ⊆ N (vi ). As seen from Algorithm 1, the construction process fuses the information carried by vi ’s neighbors if vi is not an endnode (detailed fusion process is given in section III-A.3), otherwise vi is eliminated from the higher layer. The L layer of data can be generated by recursively applying Algorithm 1 for L−1 times, which means by taking the output of lth layer as the input of (l + 1)th layer. This process can be illustrated in Figure 2 with L = 3. In this 1 2 3 4 5 6 7 8 9 10 11 12 13 (l) for vi ∈ V (l) do (l) if numel(N (vi )) > 1 then (l) (l+1) (l) Preserve vi , i.e. vi = vi ; (l+1) (l+1) (l) Construct ri and r̂i from ri and all of (l) (l) (l) the rj carried by vj ∈ N (vi ); end (l) (l) for vj ∈ N (vi ) do (l) (l) if vj ∈ M (vi ) then (l) (l) Eliminate eij and vj ; else (l) (l+1) (l) Preserve eij , i.e. eij = eij ; end end end example, the end-nodes are denoted as red. It is to be noted that when moving to higher layers, the number of nodes in each layer decreases with the elimination of the end-nodes. More details are given in the caption of Figure 2. An illustration of the different G(l) = {V (l) , E (l) }, l = 1, 2, 3 layers constructed from a specific map is given in Figure 3. In the first layer, the nodes are distributed more densely in the map. When approaching higher layers, the tree structure represents more and more abstract information. It is to be noted that the number of the end-nodes (denoted as red asterisks) decreases as the progression of the layers which is a consideration for choosing the L = 3 in our experiments. 3) Data generation: This section describes the details (l+1) about the construction of the higher-layer range data ri (l+1) and r̂i , where the latter is generated from the former with (l) fixed length. As stated in Algorithm 1, given vi satisfying (l) (l) numel(N (vi )) > 1 (i.e. vi is not end-node), range data received at the respective nodes are integrated to achieve a better perception. (l) (l) Given each vi with numel(N (vi )) > 1, firstly a local map is generated using occupancy grid mapping [29] based on the respective range data in lth layer, including (l) (l) (l) (l) rj carried by vj ∈ N (vi ) and ri . This is achieved (l) (l) by transforming all rj to ri ’s coordinate frame, which assumes the knowledge of the global robot poses at all times. (l+1) In this local map, a virtual scan ri is then generated (l) by applying ray casting at position vi with 1◦ angular resolution, which is the same as the setting of the real laser range finder. (l+1) As the dimensions of the fused range data ri could be different in various nodes, linear interpolation on the data is Algorithm 2: Decision making on the confidence trees. (l) Input: Confidence trees where each node vi denotes (l) the predicted label ŷi and the corresponding (l) confidence ci . (1) Output: Optimized labels of leaf nodes ŷi∗ . 1 2 3 4 5 6 7 Fig. 2. An example of multi-layer GVG: The end-nodes are denoted as (1) (1) (1) red. The red nodes v1 , v2 and v6 in layer 1 are fused with their (1) (1) (1) (2) neighbours respectively, where, v1 is composed of (v1 , v2 , v5 ), (2) (1) (1) (1) (1) (2) v2 is composed of (v1 , v2 , v3 , v4 ) and v6 is composed of (1) (1) (1) (1) (v1 , v6 , v7 , v8 ). Then all the red nodes are eliminated from layer 1. This process will be performed recursively on layer 2 to generate layer 3. then performed to keep same dimension of data throughout (l+1) the process. This leads to an sequence r̂i with fixed dimension of 360. Acknowledging the fact that the interpolated points may not contain high information, a completeness rate, which is (l) the proportion of the laser measured data (dimension of ri (l) ◦ to the whole 360 data (dimension of r̂i ) is defined as: (l) (l) qi = length(ri ) (l) (1) length(r̂i ) where l = 2 · · · L. This measure is used in the decision making process which is discussed in the next section, thus (1) we denote qi = 180/360 = 0.5 for uniformity when l = 1. However, we don’t apply linear interpolation to the (1) layer 1 since the initial laser range data ri always has the same dimension of 180 and is not necessary for linear interpolation. By applying this data pre-processing approach, the laser range data in layer 2 to layer L are kept in the fixed (l) length of 360. Note that it is always ri which is employed (l) to construct the next layer, rather than the pre-processed r̂i . As an example, Figure 4 illustrates the construction of a sequence of input in layer 2 using the corresponding inputs in layer 1, followed by the result after linear interpolation. The details are given in the caption of Figure 4. B. Decision on Multi-layer Results 1) Construction of the Confidence Tree: With the L layer of inputs, we can obtain the predicted labels from L independent classifiers, which can be formed to be confidence trees with L layers shown in Figure 5(a), where each node (l) (l) denotes the predicted label ŷi of vi and its corresponding (l) confidence ci . By maximizing the overall confidence of 8 9 10 11 12 (1) (1) (1) (1) Initialize ci∗ = ci and ŷi∗ = ŷi ; for l = 2 · · · L do (l) for vi ∈ V (l) do (l) Average the optimized confidence of vi ’s P (l−1) (l−1) 1 children vj as c ; P (l−1) ni(l) j j∗ 1 if ni j cj∗ > ci then P (l−1) (l) Denote ci∗ = n1i j cj∗ ; else (l) (l) Denote ci∗ = ci ; (l) All descendants of vi are assigned with the (l) label ŷi∗ . end end end each tree structure, it is intended to obtain higher accuracy in classification. All of these tree structures are built from the dependencies in Algorithm 1 except for some minor difference — during (l+1) the construction of these tree structures, a parent node vi (l) (l) (l) owns its children vi and vj ∈ M (vi ), while the range (l+1) data of vi is constructed from the range data carried by (l) (l) (l) vi and vj ∈ N (vi ). The reason is that for those nodes (l) (l) (l) (l) vj ∈ N (vi ) and vj ∈ / M (vi ), they are also reserved (l+1) in the higher layer as vj and have their own predicted (l+1) labels, so we don’t consider the influence of vi to them. It is to be noted that the number of such tree structures is equal to the number of nodes left in the layer L, where the (L) vi are the root nodes of these trees. In our framework, two factors are considered when com(l) (l) puting the confidence ci , one is the probability pi obtained (l) from the classifier for labeling ŷi and the other is the (l) (l) completeness ratio qi obtained from the input sequence ri (l) which is given in (1). Then the confidence ci is constructed as: (l) (l) (l) ci = pi × qi (2) 2) Decision Algorithm: With the confidence trees denot(l) ing the predicted label ŷi and its corresponding confidence (l) (l) ci for each given vi , the aim of decision making is then to (l) search the optimized confidence ci∗ and assign the optimized (l) label ŷi∗ to each node, leading to the maximum value of the overall confidence. In each tree structure, we make decisions from children to parents while comparing two consecutive layers based on the decision Algorithm 2. It is to be noted that for the comparison (a) Layer 1 (b) Layer 2 (c) Layer 3 Fig. 3. Multi-layer of the GVG graph G(l) = {V (l) , E (l) }, l = 1, 2, 3 on Fr79. The red nodes correspond to the end-nodes, which will be eliminated in the next layer, and the black nodes will be preserved. The edges reveals the connection between these nodes. between layer l and layer l − 1, the confidence of the parent (l) vi is always compared to the average optimized confidence (l−1) of its children vj and we assume the optimized confidences in layer 1 are known as the original confidences. As for the optimized predicted labels, Algorithm 2 tells that they are only changed to follow their ancestor when this ancestor beats its children in confidence. In other words, if none ancestor of a leaf node gain advantages in confidence, (1) then this leaf node would keep the initial label ŷi as its (1) optimized label ŷi∗ . Note that although we can obtain the optimized labels for all nodes from this decision algorithm, only the labels of the leaf nodes are exported as output since the classification performance is evaluated based on these leaf nodes. An example is given in Figure 5(b) for better clarity. We can also evaluate the results obtained from those L independent classifiers separately with the help of these constructed trees. To ensure the fairness, results obtained from different layer of classifiers are all compared on the accuracy of bottom layer. Obviously, the results observed from the input of layer 1 do not need to be modified while the higher layers should spread their predicted labels to the bottom layer. Given a specific layer l (l > 1), all of the nodes on the bottom layer are assigned with the same label as their ancestor in layer l. For example, as shown in Figure 5(b), (l) (l) (l) (3) the v1 , v2 , · · · , v5 will be labeled by the v1 ’s predicted label when we evaluate the results of layer 3. IV. S EMI - SUPERVISED L EARNING AND C LASSIFICATION We have introduced the construction of multi-layer inputs and decision making on the multi-layer results in Section Fig. 4. (l) vj ∈ (2) An example of constructing ri (l) N (vi ), (2) and r̂i (l) where the axes are in meters. The left four figures illustrate ri where the black asterisk node denotes the position of (l) vi , the red asterisk nodes denote the position of (l) and all of the rj (l) vj carried by and the blue nodes denote (2) the range data collected from the real environment. Then the middle figure shows the constructed ri using ray casting. The interpolated sequence is (2) given on the right, where the magenta points correspond to the interpolated ones. In this example, we have qi = 332/360 = 0.9222. (a) Confidence tree (b) A decision example Fig. 5. Confidence trees built from Figure 2 and a corresponding example. (l+1) (l) (a) The confidence tree: Each parent node vi has children vi and (l) (l) vj ∈ M (vi ). (b) The decision example: in this example, let’s assume that the confidence of each node is known. By applying the decision method (1) (1) given in Algorithm 2, firstly we have the initialization ci∗ = ci and (1) (1) ŷi∗ = ŷi . And then average confidence of the children in bottom most layer are compared with their corresponding parents in the immediate upper (2) (1) (1) layer. In the left tree, c1 is larger than the average value of c1 and c5 , (2) (1) (1) and therefore c1∗ = 0.8 and both the respective children (v1 and v5 ) (2) (2) are assigned the label ŷ1 . The c2 is smaller than the average value of (1) (1) (1) c2 , c3 and c4 , hence these leaf nodes remain their initial label and (2) (3) c2∗ = (0.5 + 0.4 + 0.4)/3 = 0.4333. Finally c1 = 0.6 is compared (2) (2) with (c1∗ + c2∗ )/2 = 0.6167. Since the confidence of layer 3 is smaller than the optimized average confidence combined from layer 1 and layer 2, (3) the final optimized confidence is c1∗ = 0.6167 and the optimized labels do not change. By applying the same decision process on the right tree in (1) (1) (1) (3) the figure, v6 , v7 and v8 are labeled the same as v6 . III. In this section, we discuss the classification problem of how to train on each layer with the input data and obtain the predicted labels of the testing maps. This is implemented by a deep learning structure, with the capability to automatically learn features from the raw input data. The L layer of inputs are trained through L independent deep learning modes as indicated in Figure 1, though, these models have the same structure with raw laser range data being the input and predicted labels being the output as shown in Figure 6. Thus the discussion below in this section is not confined to any specific layer and hence the superscripts are omitted. It is to be noted that our training process is semi-supervised since both the training map and the testing map are employed for model training, where only the labels of the training map are available. The semi-supervised learning process has the advantage of gaining richer information of data distribution, while keeping the spatial consistency as we will introduce in this chapter. A. Semi-supervised Learning with Graph Regularization In the classification problem, we denote the training pairs as (Xl ∈ Rm×nl , Yl ∈ R1×nl ) as a convention, where m denotes the input dimension, nl denotes the number of training samples. Particularly, each column in Xl is a sequence of laser range data r, i.e. xil = ri . The testing data can be defined in the same way as Xu ∈ Rm×nu , where nu denotes the number of testing samples. Then the task of the classification problem is to obtain predicted labels of Xu given Xl and Yl . In addition, we denote X = [Xl Xu ] ∈ Rm×n as the combination of training data and testing data with n = nl + nu , since X is fed into the model as a whole during our semi-supervised training process. As illustrated in Figure 6, the input is firstly fed into a set of fixed parameters (denoted as red) to compute the differences between the consecutive beams in each raw scan, as the consecutive differences can also provide rich information to the place classification and is often employed for extracting geometric features in the previous works [15], In the work reported here, the softmax classifier is applied to the features learned from stacked auto-encoders for classification, which is formulated as follow: exp(wiT h) pi = P T j exp(wj h) Fig. 6. Model training in semi-supervised learning: The second layer has fixed parameters which computes the consecutive differences of our input (denoted as red). Then both the input and the output of the second layer will be fed into the latter process. For the fine-tuning process, the Jlabel is imposed to the softmax classifier and all of the parameters in the neural network (except the fixed layer) will be adjusted, while Jgraph is imposed to the last hidden layer and will only influence the feature learning process. [27]. In the practical experiments, we sort both of the input and consecutive differences to guarantee the rotational invariance. From this point on, both the input and output of this fixed layer are fed into the stacked auto-encoders for feature learning. Auto-encoder is the widely used structure for building deep architectures, which is composed of an encoder and a decoder. By feeding the representation learned from the previous encoder as the input into another autoencoder, we can obtain the stacked hidden representations as shown in Figure 6. Let’s denote sigmoid function as f (x) = 1/(1 + e−x ), then the ith layer of encoder and decoder can be represented as follow: Hi = f (Wi Hi−1 + bi ) Ĥi−1 = f (WiT Hi + ci ) (3) where Hi−1 and Ĥi−1 denote the input and its reconstruction, Hi denotes the hidden representation and Wi , bi , ci denote the weighted parameters respectively1 . In this paper, the weights in each pair of encoder and decoder are tied together as shown in (3). For each layer of auto-encoder, the unsupervised pretraining is applied to obtain better parameters than random initialization [12] by minimizing the reconstruction cost: Jpre = 1 kHi−1 − Ĥi−1 k2F m (4) Note that the decoder is discarded after pre-training while the encoder is preserved. The hidden representation learned by the last auto-encoder can be regarded as the feature for the input to the classifier. 1 When i=1, Hi−1 is the raw input — the combination of X and its consecutive differences Xs . (5) where pi corresponds to the probability that the hidden representation vector h belongs to ith class. After pre-training and classification, back propagation can be used to fine-tune the whole learning process for further promotion, which means the parameters of preserved encoders and softmax are trained together. In order to keep the local consistency, we add a graph regularization term during fine-tuning to learned representation. The cost function of the fine-tuning is given as follow: Jf ine = Jlabel + Jgraph nl n n 1 X λ XX sij khi − hj k2 = Jlabel (xil , yli ) + nl i=1 n i=1 j=1 (6) where the first term corresponds to the prediction error of the training data, and the second term is the graph regularization. Here hi and hj are the outputs of the last hidden layer with respect to the inputs xi and xj (xi and xj are two arbitrary columns in X), and sij is the similarity measurement between the samples xi and xj that connected in GVG, which is an element of the adjacency graph S = [sij ]n×n . Figure 6 also illustrates the way our cost function work. The costs caused by the prediction error is imposed on the softmax classifier and then our graph regularization is imposed on the last hidden layer. So during the fine-tuning the Jlabel will influence all of the parameters, while Jgraph will only influence the parameters for feature learning. B. Graph Regularization in Place Classification Problem As shown in (6), the learned features hi and hj with large weight sij will be pushed together with the graph regularization term. In this section, we describe the details about the construction of the adjacency graph S which can be built in two steps. Firstly we define the connected relationships between samples and then calculate their weights of the connected edges. In the place classification problem, the connected relationships in the topological graph GVG are directly employed to the adjacency graph. Then the samples with close coordinates are forced to be represented by the features with close distances. As for the weights which corresponds to the strength of the graph regularization, it is inversely associated with two distances, i.e. the distance between coordinates and the distance between the input data, which can be formulated as: α β + (7) sij = dij kxi − xj k2 where α and β are constant weights, dij denotes the Euclidean distance between the sample coordinates. The second term defines the Euclidean distance between the input data. This weighting scheme dose not only evaluate the geometrical information, but also considers the closeness between inputs. For example, given an edge that connects two nodes belonging to corridor and office respectively, although dij is small, kxi − xj k2 can be large. Therefore, these two nodes are not forced to be too close in the representation space however still keeps the discriminative information. V. E XPERIMENTS To validate the effectiveness of our end-to-end multi-layer learning system, we conduct experiments on six data sets collected from six international university indoor environments (including the Centre for Autonomous Systems at the University of Technology, Sydney, several buildings in the University of Freiburg, the German Research Centre for Artificial Intelligence in Saarbruecken, and the Intel Lab in Seattle). As we stated previously, the robot collected range data at the GVG nodes using the 2D laser range finder which has a maximum range of 30m and a horizontal field of view of 180◦ . It is to be noted that the classes defined by humans can be somewhat vague and plentiful according to the different functions of places. However, the 2D range data do not contain enough discriminative information to classify all these human-designed classes. Therefore, after careful thinking, we consider 3 target classes as: Class 1-space designed for a small number of individuals including cubicle, office, printer room, kitchen, bathroom, stairwell and elevator; Class 2-space for group activities including meeting room and laboratory; Class 3-corridor. Among these six data sets, two of them (Fr79 and Intellab) contain all of the 3 classes but the others contain only parts of these classes. We consider the leave-many-out training, which means one data set is utilized for training and others are used for testing. Therefore, we obtained two groups of results by training on Fr79 and Intellab respectively. The feature learning and classification model for each layer of input is shown in Figure 6. Given the input X ∈ Rm×n , the dimension configuration for our learning model is m − m − 100 − 24 − 3, which means the consecutive differences layer has the same dimension as the input, and the dimension of our hidden layers are 100 and 24 respectively. Thus the dimension of our learned features is 24. Finally the output of our model represents a probabilistic measure of data belonging to each class. Thus the output dimension is the same as the number of our classes. In addition, since we perform the interpolation to fix the dimension of the higher layers as introduced in Section III-A.3, so we have m = 180 for L = 1, and m = 360 for L = 2, 3, · · · . In this paper, we choose L = 3. A. Multi-layer Results without Graph Regularization We first conduct experiments to evaluate the performance of our multi-layer inputs. Table I and Table II shows the leave-many-out classification results training on Intellab and Fr79 respectively. It is to be noted that the graph regularization is not considered here and therefore, λ = 0 in the TABLE I M ULTI - LAYER RESULTS TRAINED ON I NTELLAB . Map UTS SarrB FrUA FrUB Fr79 Average L1(%) 85.20 86.55 86.23 90.29 81.99 86.05 L2(%) 89.49 87.64 92.96 98.87 85.87 90.97 L3(%) 91.24 91.32 91.69 99.84 87.90 92.40 TABLE II M ULTI - LAYER RESULTS TRAINED ON F R 79. Map UTS SarrB FrUA FrUB Intellab Average L1(%) 81.70 84.16 90.43 88.67 72.55 83.50 L2(%) 85.99 95.44 94.70 98.87 79.81 90.96 L3(%) 89.93 90.46 96.91 99.51 82.73 91.91 cost function (6). In general, results of higher layers are better than that of lower layers due to the richer information contained in each node on the higher layers. B. Multi-layer Results with Graph Regularization We also carried out experiments to validate the effectiveness of the graph regularization. The algorithm remains the same as previous settings, however, we changed the value of λ = 1 to add the graph regularization. In this experiments, we pay more attention to the geometrical neighborhood, thus we use α = 2/3 and β = 1/3 in (7) for the construction of the adjacency graph. The classification results are shown in Table III and Table IV, which are trained on Intellab and Fr79 respectively. The results have the similar trends as in Table I and Table II, where higher layers give rise to better accuracies. Further comparisons of Table I and Table III show that the feature learning with graph regularization performs better than without it. It reveals that the graph regularization has the advantage of improving classification performances by keeping the local consistency. C. Fusion Results Finally, we show the accuracies of the multi-layer graph regularized method with fusion in Table V and Table VI. When compared with the results of each single layer as TABLE III M ULTI - LAYER RESULTS TRAINED ON I NTELLAB WITH GRAPH REGULARIZATION . Map UTS SarrB FrUA FrUB Fr79 Average L1(%) 83.54 89.59 91.48 89.97 83.96 87.71 L2(%) 87.3 96.31 91.77 99.19 86.12 92.14 L3(%) 92.29 90.89 96.68 99.84 88.65 93.67 shown in Table III and Table IV, the fusion results achieved better accuracies. For the results trained on Intellab, the average accuracy of fusion results risen to 94.02% from L1:87.71%, L2:92.14% and L3:92.66%, and the results trained on Fr79 also reached 93.59% from L1:84.24%, L2:92.17% and L3:92.95%. The fused test results trained on Intellab are diagrammatically illustrated in Figure 7. It is to be noted that confusions between Class 1 (office room and other rooms) and Class 2 (meeting room) account for the major misclassifications especially in the test map of Fr79. The cause might be that Class 1 is featured with narrow environment including massive clutters while the Class 2 is featured with relatively larger spaces, therefore the corners of meeting room are mostly classified as office room and other rooms and some center positions of office room are assigned as office room. We also make comparisons with the results we achieved in our previous work SPCoGVG [23]. SPCoGVG is also a semi-supervised approach, which is composed of support vector machine (SVM) and conditional random field (CRF) to ensure the generalization ability. We use the 24dimensional hand-engineered features in SPCoGVG, which are extracted from the raw range data with geometrical knowledge. Notice that our learned features have the same dimension as the hand-engineered features in our experiments. Seen from Table V and Table VI, we achieve slightly better average results than SPCoGVG. In this paper, we presented an end-to-end place classification framework. We implemented a multi-layer learning framework, including the construction of multi-layer inputs and decision making on the multi-layer results. Each layer of inputs were fed into a semi-supervised model for feature TABLE IV M ULTI - LAYER RESULTS TRAINED ON F R 79 WITH GRAPH REGULARIZATION . L1(%) 80.47 87.20 91.06 89.48 73.00 84.24 L2(%) 89.23 96.75 96.12 98.87 79.89 92.17 L3(%) 90.02 95.23 97.47 99.51 82.51 92.95 TABLE V G RAPH REGULARIZED FUSION RESULTS TRAINED ON I NTELLAB AND RESULTS USING SPC O GVG. Map UTS SarrB FrUA FrUB Fr79 Average Multi-layer fusion(%) 91.24 96.53 95.02 99.84 89.76 94.48 RESULTS USING Map UTS SarrB FrUA FrUB Intellab Average SPC O GVG. Multi-layer fusion(%) 90.54 98.27 97.23 99.51 82.40 93.59 SPCoGVG(%) 89.84 93.71 97.71 99.19 86.89 93.47 learning and classification, which guaranteed the local consistency with a graph regularization. Experimental results showed that the higher layer input data led to higher classification accuracy, which validated the effectiveness of the multi-layer structure. By performing the semi-supervised learning with or without graph regularization, we also showed that graph regularization help promoting the classification performance by keeping the local consistency. Furthermore, the fusion results based on the confidence tree achieved comparable results to the stateof-art method. In a nutshell, we achieved the generalization ability and preserved the local consistency in our end-to-end place classification framework. Future work is to apply our framework on other type of sensor data, such as RGB-D data, which have more representative and discriminative ability. R EFERENCES VI. C ONCLUSIONS Map UTS SarrB FrUA FrUB Intellab Average TABLE VI G RAPH REGULARIZED FUSION RESULTS TRAINED ON F R 79 AND SPCoGVG(%) 90.72 88.72 96.52 98.71 92.04 93.39 [1] A. Aydemir, K. Sjoo, J. Folkesson, A. Pronobis, and P. Jensfelt. Search in the real world: Active visual object search based on spatial relations. In Robotics and Automation (ICRA), 2011 IEEE International Conference on, pages 2818–2824. IEEE, 2011. [2] Y. Bengio, P. Lamblin, D. Popovici, and H. Larochelle. Greedy layer-wise training of deep networks. Advances in neural information processing systems, 19:153, 2007. [3] Y.-L. Boureau, N. Le Roux, F. Bach, J. Ponce, and Y. LeCun. Ask the locals: multi-way local pooling for image recognition. In Computer Vision (ICCV), 2011 IEEE International Conference on, pages 2651– 2658. IEEE, 2011. [4] H. Choset and J. Burdick. Sensor based planning. i. the generalized voronoi graph. In Robotics and Automation, 1995. Proceedings., 1995 IEEE International Conference on, volume 2, pages 1649–1655. IEEE, 1995. [5] R. Collobert, J. Weston, L. Bottou, M. Karlen, K. Kavukcuoglu, and P. Kuksa. Natural language processing (almost) from scratch. The Journal of Machine Learning Research, 12:2493–2537, 2011. [6] G. E. Dahl, D. Yu, L. Deng, and A. Acero. Context-dependent pretrained deep neural networks for large-vocabulary speech recognition. Audio, Speech, and Language Processing, IEEE Transactions on, 20(1):30–42, 2012. [7] C. Galindo, J.-A. Fernández-Madrigal, J. González, and A. Saffiotti. Robot task planning using semantic maps. Robotics and Autonomous Systems, 56(11):955–966, 2008. [8] X. Glorot, A. Bordes, and Y. Bengio. Domain adaptation for largescale sentiment classification: A deep learning approach. In Proceedings of the 28th International Conference on Machine Learning (ICML-11), pages 513–520, 2011. [9] R. Hadsell, S. Chopra, and Y. LeCun. Dimensionality reduction by learning an invariant mapping. In Proceedings of the 2006 IEEE Computer Society Conference on Computer Vision and Pattern Recognition - Volume 2, CVPR ’06, pages 1735–1742, Washington, DC, USA, 2006. IEEE Computer Society. [10] R. Hadsell, S. Chopra, and Y. LeCun. Dimensionality reduction by learning an invariant mapping. In Computer vision and pattern recognition, 2006 IEEE computer society conference on, volume 2, pages 1735–1742. IEEE, 2006. (a) FrUA, Acc = 95.02% (c) SarrB, Acc = 96.53% (b) FrUB, Acc = 99.84% (d) UTS, Acc = 91.24% (e) Fr79, Acc = 89.76% Fig. 7. Test results corresponding to Table V, the GVG nodes are labeled with the graph regularized fusion results trained on Intelmap. [11] G. Hinton, S. Osindero, and Y. Teh. A fast learning algorithm for deep belief nets. Neural computation, 2006. [12] G. Hinton and R. Salakhutdinov. Reducing the dimensionality of data with neural networks. Science, 313(5786):504 – 507, 2006. [13] Q. V. Le. Building high-level features using large scale unsupervised learning. In Acoustics, Speech and Signal Processing (ICASSP), 2013 IEEE International Conference on, pages 8595–8598. IEEE, 2013. [14] O. Martinez Mozos, R. Triebel, P. Jensfelt, A. Rottmann, and W. Burgard. Supervised semantic labeling of places using information extracted from sensor data. Robotics and Autonomous Systems, 55(5):391–402, 2007. [15] O. M. Mozos, C. Stachniss, and W. Burgard. Supervised learning of places from range data using adaboost. In Robotics and Automation, 2005. ICRA 2005. Proceedings of the 2005 IEEE International Conference on, pages 1730–1735. IEEE, 2005. [16] A. Poncela, C. Urdiales, B. Fernández-Espejo, and F. Sandoval. Place characterization for navigation via behaviour merging for an autonomous mobile robot. In Electrotechnical Conference, 2008. MELECON 2008. The 14th IEEE Mediterranean, pages 350–355. IEEE, 2008. [17] A. Pronobis and P. Jensfelt. Hierarchical multi-modal place categorization. In ECMR, pages 159–164, 2011. [18] A. Pronobis and P. Jensfelt. Large-scale semantic mapping and reasoning with heterogeneous modalities. In Robotics and Automation (ICRA), 2012 IEEE International Conference on, pages 3515–3522. IEEE, 2012. [19] A. Ranganathan. Pliss: Detecting and labeling places using online change-point detection. In Robotics: Science and Systems, 2010. [20] A. Ranganathan and J. Lim. Visual place categorization in maps. In Intelligent Robots and Systems (IROS), 2011 IEEE/RSJ International Conference on, pages 3982–3989. IEEE, 2011. [21] S. Rifai, G. Mesnil, P. Vincent, X. Muller, Y. Bengio, Y. Dauphin, and X. Glorot. Higher order contractive auto-encoder. In Proceedings of the 2011 European conference on Machine learning and knowledge discovery in databases - Volume Part II, ECML PKDD’11, pages 645– 660, Berlin, Heidelberg, 2011. Springer-Verlag. [22] S. Rifai, P. Vincent, X. Muller, X. Glorot, and Y. Bengio. Contractive Auto-Encoders: Explicit invariance during feature extraction. In ICML, 2011. [23] L. Shi and S. Kodagoda. Towards generalization of semi-supervised [24] [25] [26] [27] [28] [29] [30] [31] [32] [33] place classification over generalized voronoi graph. Robotics and Autonomous Systems, 61(8):785–796, 2013. L. Shi, S. Kodagoda, and G. Dissanayake. Laser range data based semantic labeling of places. In Intelligent Robots and Systems (IROS), 2010 IEEE/RSJ International Conference on, pages 5941–5946. IEEE, 2010. L. Shi, S. Kodagoda, and G. Dissanayake. Multi-class classification for semantic labeling of places. In Control Automation Robotics & Vision (ICARCV), 2010 11th International Conference on, pages 2307–2312. IEEE, 2010. W. Shi and J. Samarabandu. Investigating the performance of corridor and door detection algorithms in different environments. In Information and Automation, 2006. ICIA 2006. International Conference on, pages 206–211. IEEE, 2006. P. Sousa, R. Araújo, and U. Nunes. Real-time labeling of places using support vector machines. In Industrial Electronics, 2007. ISIE 2007. IEEE International Symposium on, pages 2022–2027. IEEE, 2007. T. Tao, S. Tully, G. Kantor, and H. Choset. Incremental construction of the saturated-gvg for multi-hypothesis topological slam. In Robotics and Automation (ICRA), 2011 IEEE International Conference on, pages 3072–3077. IEEE, 2011. S. Thrun, W. Burgard, and D. Fox. Probabilistic robotics. MIT press, 2005. P. Vincent. A connection between score matching and denoising autoencoders. Neural Comput., 23(7):1661–1674, July 2011. P. Viswanathan, D. Meger, T. Southey, J. J. Little, and A. Mackworth. Automated spatial-semantic modeling with applications to place labeling and informed search. In Computer and Robot Vision, 2009. CRV’09. Canadian Conference on, pages 284–291. IEEE, 2009. J. Weston, F. Ratle, H. Mobahi, and R. Collobert. Deep learning via semi-supervised embedding. In Neural Networks: Tricks of the Trade, pages 639–655. Springer, 2012. L. Yuan, K. C. Chan, and C. G. Lee. Robust semantic place recognition with vocabulary tree and landmark detection. In Proc. IROS 2011 workshop on Active Semantic Perception and Object Search in the Real, World, 2011.
9cs.NE
Scalable Hash-Based Estimation of Divergence Measures Morteza Noshad and Alfred O. Hero III University of Michigan, Electrical Engineering and Computer Science, Ann Arbor, Michigan, U.S.A arXiv:1801.00398v1 [cs.IT] 1 Jan 2018 Abstract measures are two well studied generalizations of KLdivergence which comprise many important divergence measures such as KL-divergence, total variation distance, and α-divergence [4, 5]. We propose a scalable divergence estimation method based on hashing. Consider two continuous random variables X and Y whose densities have bounded support. We consider a particular locality sensitive random hashing, and consider the ratio of samples in each hash bin having non-zero numbers of Y samples. We prove that the weighted average of these ratios over all of the hash bins converges to fdivergences between the two samples sets. We show that the proposed estimator is optimal in terms of both MSE rate and computational complexity. We derive the MSE rates for two families of smooth functions; the Hölder smoothness class and differentiable functions. In particular, it is proved that if the density functions have bounded derivatives up to the order d/2, where d is the dimension of samples, the optimal parametric MSE rate of O(1/N ) can be achieved. The computational complexity is shown to be O(N ), which is optimal. To the best of our knowledge, this is the first empirical divergence estimator that has optimal computational complexity and achieves the optimal parametric MSE estimation rate. 1 Non-parametric estimators are a major class of divergence estimators, for which minimal assumptions on the density functions are considered. Some of the nonparametric divergence estimators are based on density plug-in estimators such as k-NN [6], KDE [7], and histogram [8]. A few researchers, on the other hand, have proposed direct estimation methods such as graph theoretic nearest neighbor ratio (NNR) [9]. In general, plug-in estimation methods suffer from high computational complexity, which make them unsuitable for large scale applications. Recent advances on non-parametric divergence estimation have been focused on the MSE convergence rates of the estimator. Singh et al in [7] proposed a plug-in KDE estimator for Rényi divergence that achieves the MSE rate of O(1/N ) when the densities are at least d times differentiable, and the support boundaries are sufficiently smooth. Kandasamy et al proposed a similar plug-in KDE estimator and extend the optimal MSE rate to densities that are at least d/2 differentiable [10]. However, they ignore a major source of error due to the boundaries. Moon et al proposed a weighted ensemble method to improve the MSE rate of plug-in KDE estimators [11]. The proposed estimator for f-divergence achieves the optimal MSE rate when the densities are at least (d + 1)/2 times differentiable. They also assume stringent smoothness conditions at the support set boundary. Introduction Information theoretic measures such as Shannon entropy, mutual information, and the Kullback-Leibler (KL) divergence have a broad range of applications in information theory, statistics and machine learning [1–3]. When we have two or more data sets and we are interested in finding the correlation or dissimilarity between them, Shannon mutual information or KL-divergence is often used. Rényi and f-divergence Noshad et al proposed a graph theoretic direct estimation method based on nearest neighbor ratios (NNR) [9]. Their estimator is simple and computationally more tractable than other competing estimators, and can achieve the optimal MSE rate of O(1/N ) for densities that are at least d times differentiable. Although their basic estimator does not require any smoothness assumptions on the support set boundary, the ensemble estimator variant of their estimator does. Proceedings of the 21st International Conference on Artificial Intelligence and Statistics (AISTATS) 2018, Lanzarote, Spain. JMLR: W&CP volume 7X. Copyright 2018 by the author(s). In spite of achieving the optimal theoretical MSE rate 1 by aforementioned estimators, there remain serious. The first challenge is the high computational complexity of the estimator. Most KDE based estimators require runtime complexity of O(N 2 ), which is not suitable for large scale applications. The NNR estimator proposed in [9] has the runtime complexity of O(kN log N ), which is faster than the previous estimators. However, in [9] they require k to grow sub-linearly with N , which results in much higher complexity than linear runtime complexity. The other issue is the smoothness assumptions made on the support set boundary. Almost all previously proposed estimators assume extra smoothness conditions on the boundaries, which may not hold practical applications. For example, the method proposed in [7] assumes that the density derivatives up to order d vanish at the boundary. Also it requires numerous computations at the support boundary, which become complicated when the dimension increases. The Ensemble NNR estimator in [9] assumes that the density derivatives vanish at the boundary. To circumvent this issue, Moon et al [11] assumed smoothness conditions at the support set boundary. However, these conditions may not hold in practice. two sample sets X and Y with a bounded density support. We use a particular two-level locality sensitive random hashing, and consider the ratio of samples in each bin with a number of Y samples. We prove that the weighted average of these ratios over all of the bins can be made to converge almost surely to f-divergences between the two samples populations. We also argue that using the ensemble estimation technique provided in [2], we can achieve the optimal parametric rate of O(1/N ). Furthermore, using a simple algorithm for online estimation method has O(N ) complexity and O(1/N ) convergence rate, which is the first optimal online estimator of its type. In this paper we propose a low complexity divergence estimator that can achieve the optimal MSE rate of O(1/N ) for the densities with bounded derivatives of up to d/2. Our estimator has optimal runtime complexity of O(N ), which makes it an appropriate tool for large scale applications. Also in contrast to other competing estimators, our estimator does not require stringent smoothness assumptions on the support set boundary. The f-divergence is defined as follows [5]. The structure of the proposed estimator borrows ideas from hash based methods for KNN search and graph constructions problems [12, 13], as well as from the NNR estimator proposed in [9]. The advantage of hash based methods is that they can be used to find the approximate nearest neighbor points with lower complexity as compared to the exact k-NN search methods. This suggests that fast and accurate algorithms for divergence estimation may be derived from hashing approximations of k-NN search. Noshad et al [9] consider the k-NN graph of Y in the joint data set (X, Y ), and show that the average exponentiated ratio of the number of X points to the number of Y points among all k-NN points is proportional to the Rényi divergence between the X and Y densities. It turns out that for estimation of the density ratio around each point we really do not need to find the exact k-NN points, but only need sufficient local samples from X and Y around each point. By using a randomized locality sensitive hashing (LSH), we find the closest points in Euclidean space. In this manner, applying ideas from the NNR estimation and hashing techniques to KNN search problem, we obtain a more efficient divergence estimator. Consider 2 Hash-Based Estimation In this section, we first introduce the f-divergence measure and propose a hash-based estimator. We outline the main theoretical results which will be proven in section 4. Consider two density functions f1 and f2 with common bounded support set X ⊆ Rd .  f1 (x) Dg (f1 (x)||f2 (x)) := g f2 (x)dx f2 (x)    f1 (x) , = Ef2 g f2 (x) Z  (1) where g is a smooth and convex function such that g(1) = 0. KL-divergence, Hellinger distance and total variation distance are particular cases of this family. Note that for estimation, we don’t need convexity of g and g(1) = 0. conditions. Assume that the densities are lower bounded by CL > 0 and upper bounded by CU . Assume f1 and f2 belong to the Hölder smoothness class with parameter γ: Definition Given a support X ⊆ Rd , a function f : X → R is called Hölder continuous with parameter 0 < γ ≤ 1, if there exists a positive constant Gf , possibly depending on f , such that |f (y) − f (x)| ≤ Gf ky − xkγ , (2) for every x 6= y ∈ X . The function g in (1) is also assumed to be Lipschitz continuous; i.e. g is Hölder continuous with γ = 1. Remark 1 The γ-Hölder smoothness family comprises a large class of continuous functions including continuously differentiable functions and Lipschitz continuous functions. Also note that for γ > 1, any γ–Hölder where c1 is a positive real constant. continuous function on any bounded and continuous support is constant. Remark 2 In order for the estimator to be asymptotically unbiased,  needsto be a function of N . The γ/(γ+d)  optimum bias rate of O N1 can be achieved γ/(γ+d) for  = N1 . Hash-Based Divergence Estimator: Consider the i.i.d samples X = {X1 , ..., XN } drawn from f1 and Y = {Y1 , ..., YM } drawn from f2 . Define the fraction η := M/N . We define the set Z := X ∪ Y . We define a positive real valued constant  as a user-selectable parameter of the estimator to be defined in 5. We define the hash function H1 : Rd → Zd as H1 (x) = [h1 (x1 ), h1 (x2 ), ..., h1 (xd )] , Theorem 2.2 Let η = M/N be fixed. The variance of the estimator 5 can be bounded as   h i 1 b V Dg (X, Y ) ≤ O . (6) N (3) where xi is the projection of x on the ith coordinate, and h1 (x) : R → Z is defined as  h1 (x) =  x+b ,  Remark 3 The same variance bound holds for the Ni random variable ρi := M . The bias and variance i results easily extend to Rényi divergence estimation. (4) Algorithm 1: Histogram Estimator of f-Divergence Input : Data sets X = {X1 , ..., XN }, Y = {Y1 , ..., YM } for fixed b. Let F := {1, 2, .., F }, where F := cH N and cH is a fixed real number. We define a random hash function H2 : Zd → F with a uniform density on the output and consider the combined hashing H(x) := H2 (H1 (x)), which maps the points in Rd to F. 1 Consider the mappings of the sets X and Y using the hash function H(x), and define the vectors N and M to respectively contain the number of collisions for each output bucket from the set F. We represent the bins of the vectors N and M respectively by Ni and Mi , 1 ≤ i ≤ F. The hash based f-divergence estimator is defined as          1 X  ηNi b g (X, Y ) := max Mi ge D , 0 , (5)   M Mi   i≤F   Mi >0 where ge(x) := max {g(x), g(CL /CU )}. Note that if the densities f1 and f2 are almost equal, b α (X, Y ) then for each point Yi , Ni ≈ Mi , and thus D b and Dg (X, Y ) tend to zero, as required. In the following theorems we state upper bounds on the bias and variance rates. Let B[T̂ ] = E[T̂ ] − T and V[T̂ ] = E[T̂ 2 ] − E[T̂ ]2 , respectively represent the bias and variance of T̂ , which is an estimator of the parameter T . Then, the following provides a bound on the bias of the proposed estimator. Theorem 2.1 Assume that f1 and f2 are density functions with bounded common support set X ∈ Rd and satisfying γ-Hölder smoothness. The bias of the proposed estimator for f-divergence with function g can be bounded as   h i 1 γ b B Dg (X, Y ) = O( ) + O , N d 2 3 4 5 6 /* Find the sets of all hashed points in X and Y */ X 0 ← H(X). Y 0 ← H(Y ). for each i ∈ F do /* Find the number of collisions at bin i */ Ni ← |X 0 = i| Mi ← |Y 0 = i|  b ← max 1 P D e(ηNi /Mi ) , 0 , Mi >0 Mi g M b Output : D We next show that, when f1 and f2 belong to the family of differentiable densities, we can improve the bias rate by applying the ensemble estimation approach in [3,11]. The Ensemble Hash-based (EHB) estimator is defined as follows. Definition Assume that the density functions are in the Hölder space Σ(γ, L), which consists of functions on X continuous derivatives up to order q = bγc ≥ d and the qth partial derivatives are Hölder continuous with exponent γ 0 =: γ − q. Let T := {t1 , ..., tT } be a set of index values withti < c, where c > 0 is a constant. Let  (t) := tN −1/2d . The weighted ensemble estimator is defined as b w := D X b (t) , w(t)D (7) t∈T b (t) is the hash based estimator of f-divergence, where D with the hashing parameter of (t). Theorem 2.3 Let T > d and w0 be the solution to: min w subject to Algorithm 2: Online Divergence Estimation Input kwk2 X w(t) = 1, t∈T X w(t)ti/d = 0, i ∈ N, i ≤ d. (8) t∈T 1 2 3 b w is Then the MSE rate of the ensemble estimator D 0 O(1/N ). 4 5 6 3 Online Divergence Estimation In this section we study the problem of online divergence estimation. In this setting we consider two data steams X = {X1 , X2 , ..., XN } and Y = {Y1 , Y2 , ..., YN } with i.i.d samples, and we are interested in estimating the divergence between two data sets. The number of samples increase over time and an efficient update of the divergence estimate is desired. The time complexity of a batch update, which uses the entire update batch to compute the estimate at each time point, is O(N ), and it may not be so effective in cases which we need quick detection of any change in the divergence function. Algorithm 2 updates the divergence with amortized runtime complexity of order O(1). Define the sets N N X N := {Xi }i=1 , Y N := {Yi }i=1 , the number of X and Y samples in each partition, and the divergence estimate between X N and Y N . Consider updating the estimator with new samples XN +1 and YN +1 . In the first and second lines of algorithm 2, the new samples are added to the datasets and the values of Ni and Mi of the bins in which the new samples fall. We can find these bins in O(1) using a simple hashing. Note that once Ni and Mi are updated, the divergence measure can be updated, but the number of bins is not increased, by Theorem 2.1, it is clear that the bias will not be reduced. Since increasing the number of bins requires recomputing the bin partitions, a brute force rebinning approach would have order O(N ) complexity, and it were updated N times, the total complexity would be O(N 2 ). Here we use a trick and update the hash function only when N + 1 is a power of 2. In the following theorem, which is proved in appendix, we show that the MSE rate of this algorithm is order O(1/N ) and the total rebinngn computational complexity is order O(N ). 7 N Add XN +1 and Update Nk s.t H(XN +1 ) = k. Add YN +1 and Update Ml s.t H(YN +1 ) = l. If N + 1 = 2i for some i, Then Update  to the optimum value Re-hash X and Y Recompute Ni and Mi for 0 ≤ i ≤ F b Update D b Output : D 4 Proofs In this section we derive the bias bound for the densities in Hölder smoothness class, stated in Theorem 2.1. For the proofs of variance bound in Theorem 2.2, convergence rate of EHB estimator in Theorem 2.3, and online divergence estimator in Theorem 3.1, we refer the reader to the Appendix, provided as a supplementary pdf file. Consider the mapping of the X and Y points by the L hash function H1 , and let the vectors {Vi }i=1 represent the distinct mappings of X and Y points under H1 . Here L is the number of distinct outputs of H1 . In the following lemma we prove an upper bound on L. Lemma 4.1 Let f (x) be a density function with bounded support X ⊆ Rd . Then if L denotes the number of distinct outputs of the hash function H1 (defined in (3)) of i.i.d points with density f (x), we have  L≤O 1 d  . (9) Proof Let x = [x1 , x2 , ..., xd ] and define XI as the region defined as XI := {x| − cX ≤ xi ≤ cX , 1 ≤ i ≤ d} , (10) where cX is a constant such that X ⊆ XI . L is clearly not greater than the total number of bins created by splitting the region X into partitions of volume d . So we have L≤ Theorem 3.1 MSE rate of the online divergence estimator shown in Algorithm 2 is order O(1/N ) and the total computational complexity is order O(N ). N : X N := {Xi }i=1 , Y N := {Yi }i=1  b =D b XN , Y N D (Ni , Mi ) (XN +1 , YN +1 ) (2cX )d . d (11)  L L Proof of Theorem 2.1 Let {Ni0 }i=1 and Mj0 j=1 respectively denote the number of collisions of X and Y points in the bins i and j, using the hash function H1 . Ei stands for the event that there is no collision L in bin i for the hash function H2 with inputs {Vi }i=1 . We have Thus, X   E Mi E i = i≤F Mi >0   L X E 1Ai (j)Mj0 Ei  X j=1 i≤F Mi >0   L L−1 1 1 F −1 P (Ei ) = 1 − +L F F F   L =1−O . (12) F  = L X X Mj0 E 1Ai (j) Ei   i≤F j=1 Mi >0 = L X X Mj0 P j ∈ Ai |Ei  i≤F j=1 Mi >0 By definition, =   X ηNi b g (X, Y ) := 1 Mi ge . D M Mi L X X P Mj0 i≤F j=1 Mi >0 i≤F Mi >0 j ∈ Ai , Ei  P (Ei ) , (16)  where P j ∈ Ai , Ei and P (Ei ) can be derived as Therefore     h i X ηNi  b g (X, Y ) = 1 E   E D Mi ge  M Mi  P j ∈ Ai , Ei  1 = F  F −1 1− F L−1 !  =O L F2  , (17) i≤F Mi >0     1 X ηNi = P (Ei )E Mi ge Ei M Mi i≤F Mi >0     ηNi 1 X Ei . + P (Ei )E Mi ge M Mi i≤F Mi >0 and  L P (Ei ) = 1 − P (Ei ) = O F  . (18) Plugging in (17) and (18) in (16) results in (13) We represent the second term in (13) by BH . BH has the interpretation as the bias error due to collisions in hashing. Remember that Ei is defined as the event that there is a collision at bin i for the hash L function H2 with inputs {Vi }i=1 . For proving as upper bound on BhH , we first i need to compute an upper bound PL j on i=1 E Mi Ei . This is stated in the following lemma. i≤F Mi >0   L X X   1 0 Mj O E Mi E i = F j=1 i≤F Mi >0 = X   E Mi Ei ≤ O(L) (14) i≤F Mi >0 Proof Define Ai := {j : H2 (Vj ) = i}. For each i we can rewrite Mi as i≤F Mi >0 M F  = O(L) , (19) Lemma 4.3 Let L denote the number of distinct outputs of the hash function H1 of the X and Y sample points. The bias of estimator (5) due to hashing collision can be upper bounded by  Mi =  O where in the third line we use η = M/N and F = cH N . Now in the following lemma we prove a bound on BH . Lemma 4.2 We have X X L X j=1 BH ≤ O 1 0 Ai (j)Mj . L2 N2  (15) Proof From the definition of BH we can write (20) BH : = (23) since there is no collision in H2 , Mi0 and Ni0 are equal to Mj and Nj for some i and j. Equation (24) is because the values Mi0 and Ni0 are independent of the hash function H2 and its outputs, and finally in equation (25), we used the fact that each set Ni0 and Mi0 are i.i.d random variables.     1 X ηNi Ei P (Ei )E Mi ge M Mi i≤F Mi >0 =     P (E1 ) X ηNi Ei E Mi ge M Mi N0 i≤F Mi >0 ≤ At this point, assuming that the variance of M10 is upper 1 bounded by O(1/N ) hand iusing (Lemma 3.2 in [9]), we  P (E1 )e g (Rmax ) X  E Mi E i M only need to derive E i≤F Mi >0 g (Rmax ) P (E1 )e O(L) M  2 L , =O N2 = (21) where in the second line we used the fact that P (Ei ) = P (E1 ). In the third line we used the upper bound for g̃, and in the fourth line we used the result in equation (19). Now we are ready to continue the proof of the bias bound in (13). Let E be defined as the event that there is no collision for the hash function H2 , and all of its outputs are distinct, that is, E = ∩F i=1 Ei Let Bi denote the area for which all the points map to the same vector Vi . E [Ni0 ] can be written as: E [Ni0 ] = N Z f1 (x)dx x∈Bi Z f1 (Yi ) + O(kx − Yi kγ )dx x∈Bi Z d = N  f1 (Yi ) + N O(kx − Yi kγ )dx Zx∈Bi d = N  f1 (Yi ) + N O(kxkγ )dx, (27) =N h i b g (X, Y ) E D       1 X ηNi L Ei + O P (Ei )E Mi ge M Mi F i≤F Mi >0       P (E1 ) X ηNi L = E Mi ge Ei + O M Mi F x∈Bi +Yi where in the second equality we have used the definition in (2). Let define Bi0 := 1 Bi + 1 Yi and Z i≤F Mi >0 Cγ (Yi ) :=       ηNi L P (E1 ) X E Mi ge E +O (22) = M Mi F i≤F Mi >0  , and then we can simply find the RHS in (25). Note that Ni0 and Mi0 are independent and have binomial distributions with the respective means of N PiX and M PiY , where PiX and PiY are the probabilities of mapping X and Y points with the respective densities f0 and f1 into bin i. Hence,   0 h i N1 0 0 −1 Y Y1 . (26) E 1 = E [N1 |Y1 ] E M1 0 M1 (13) can be written as = N10 M10      X  P (E1 )  ηNi L   = E Mi ge E + O M Mi F i≤F Mi >0 (28) Note that Cγ (Yi ) is a constant independent of , since the volume of Bi0 is independent of . By defining x0 = x/ we can write Z Z γ kxk dx = γ kxkγ (d dx0 ) = Cγ (Yi )γ+d x0 ∈Bi0 x0 ∈Bi0 (29) "   #   L 0 X P (E1 ) ηN L i 0 = E Mi ge E +O 0 M M F i i=1 "M  #   X 1 − O(L/F ) ηNi0 L = E ge + O 0 M M F i i=1       0 ηN1 L = EY1 ∼f2 (x) E ge Y + O , 1 M10 F kxkγ dx. x∈Bi0 (23) (24) Also note that since the number of X and Y points in each bin are independent we have E [Ni0 |Yi ] = E [Ni0 ], and therefore  E [Ni0 |Yi ] = N d f1 (Yi ) + O N γ+d Cγ (Yi ) . (30) (25) where in (22) we have used the fact that conditioned on Ei , Ni and Mi are independent of Ej for i 6= j. In Next, note that E [Mi0 |Yi ] has a non-zero binomial distribution, for which the first order inverse moment can be written as [14]: h i  −1 −1 E Mi0 |Yi = M d f2 (Yi ) + O M γ+d C(Yi )    1 × 1+O M d f2 (Yi )    −1 1 d γ = M  f2 (Yi ) 1 + O( ) + O M d (31) Thus, (26) can be simplified as    f1 (Y1 ) N10 1 γ Y1 = E . + O( ) + O M10 ηf2 (Y1 ) M d  (32) We use (Lemma 3.2 in [9]) and Remark 3, and obtain       ηN10 f1 (Y1 ) E ge Y1 = g + O(γ ) M10 f2 (Y1 )   1 1 + O(N − 2 ). (33) +O M d Finally from (25) we get   h i 1 1 L b g (X, Y ) = O(γ ) + O + O(N − 2 ) + O( ) B D d M F   1 = O(γ ) + O , (34) N d where in the second equation we have used the upper bound on L in Lemma 4.1 and the fact that M/N = η. Finally note that we can use a similar method with the same steps to prove the convergence of an estimator for Rényi divergence. 5 Discussion and Experiments In this section we compare and contrast the advantages of the proposed estimator with competing estimators, and provide numerical results. These show the efficiency of our estimator in terms of MSE rate and computational complexity. Table 1 summarizes the differences between the proposed optimum estimator (EHB) with other competing estimators: Ensemble NNR [9], Ensemble KDE [11] and Mirror KDE [15]. In terms of MSE rate, all of these estimators can achieve the optimal parametric MSE rate of O(1/N ). In terms of computational complexity, our estimator has the best runtime compared to others. The smoothness parameter required for the optimum MSE rate is stated in terms of number of Figure 1: MSE comparison of α-divergence estimators with α = 0.5 between two independent truncated 2D Gaussian densities with the respective expectations of [0, 0] and [0, 1], and equal variances of σ12 = σ22 = I2 , versus different number of samples. required derivatives of the density functions. The proposed estimator is the first divergence estimator that requires no extra smoothness at the boundaries. It is also the first divergence estimator that is directly applicable to online settings, retaining both the accuracy and linear total runtime. Finally, similar to NNR and Ensemble KDE estimators, the proposed estimator does not require any prior knowledge of the support of the densities. We next compare the empirical performance of EHB to NNR, and the Ensemble KDE estimators. The experiments are done for two different types of f-divergence; KL-divergence and α-divergence defined in [16]. Assume that X and Y are i.i.d. samples from independent truncated Gaussian densities. Figure 1, shows the MSE estimation rate of α-divergence with α = 0.5 of two Gaussian densities with the respective expectations of [0, 0] and [0, 1], and equal variances of σ 2 = I2 for different numbers of samples. For each sample size we repeat the experiment 50 times, and compute the MSE of each estimator. While all of the estimators have the same asymptotic MSE rate, in practice the proposed estimator performs better. The runtime of this experiment is shown in Figure 2. The runtime experiment confirms the advantage of the EHB estimator compared to the previous estimators, in terms of computational complexity. Figure 3, shows the comparison of the estimators of KLdivergence between two truncated Gaussian densities with the respective expectations of [0, 0] and [0, 1], and equal covariance matrices of σ12 = σ22 = I2 , in terms of their mean value and %95 confidence band. The confidence band gets narrower for greater values of N , and EHB estimator has the narrowest confidence band. In Figure 4 the MSE rates of the three α-divergence estimators are compared in dimension d = 4, α = 2, for Table 1: Comparison of proposed estimator to Ensemble NNR [9], Ensemble KDE [11] and Mirror KDE [15] Estimator HB NNR Ensemble KDE Mirror KDE MSE Rate O(1/N ) O(1/N ) O(1/N ) O(1/N ) Computational Complexity O(N ) O(kN log N ) O(N 2 ) O(N 2 ) Required Smoothness (γ) d/2 d (d + 1)/2 d/2 Extra Smooth Boundaries No Yes Yes Yes Online Estimation Yes No No No Knowledge about Boundary No No No Yes Figure 2: Runtime comparison of α-divergence with α = 0.5 between two independent truncated 2D Gaussian densities with the respective expectations of [0, 0] and [0, 1], and equal variances of σ12 = σ22 = I2 , versus different number of samples. Figure 4: MSE estimation rate of α-divergence with α = 2 between two independent truncated Gaussian densities with dimension d = 4 and equal expectations µ1 = µ2 and covariance matrices σ12 = σ22 = I4 , versus different number of samples. two independent truncated Gaussian densities with the expectations µ1 = µ2 and covariances σ12 = σ22 = I4 , versus different number of samples. 6 Conclusion In this paper we proposed a fast hash based estimation method for f-divergence. We obtained bias and variance convergence rates, and validated our results by numerical experiments. Extending the method to hashbased mutual information estimation is a worthwhile topic for future work. References [1] T. M. Cover and J. A. Thomas, Elements of information theory. John Wiley & Sons, 2012. Figure 3: Comparison of the estimators of KLdivergence between two truncated Gaussian densities with the respective expectations of [0, 0] and [0, 1], and equal covariance matrices of σ12 = σ22 = I2 , in terms of their mean value and %95 confidence band. [2] K. R. Moon and A. O. Hero, “Ensemble estimation of multivariate f-divergence,” in Information Theory (ISIT), 2014 IEEE International Symposium on, pp. 356–360, IEEE, 2014. [3] K. R. Moon, M. Noshad, S. Y. Sekeh, and A. O. Hero III, “Information theoretic structure learning with confidence,” in Proc IEEE Int Conf Acoust Speech Signal Process, 2017. [4] A. Rényi, “On measures of entropy and information,” in Proceedings of the Fourth Berkeley Symposium on Mathematical Statistics and Probability, Volume 1, pp. 547–561, University of California Press, 1961. [5] S. M. Ali and S. D. Silvey, “A general class of coefficients of divergence of one distribution from another,” Journal of the Royal Statistical Society. Series B (Methodological), pp. 131–142, 1966. [6] B. Póczos and J. G. Schneider, “On the estimation of alpha-divergences.,” in AISTATS, pp. 609–617, 2011. [7] S. Singh and B. Póczos, “Exponential concentration of a density functional estimator,” in Advances in Neural Information Processing Systems, pp. 3032–3040, 2014. [8] Q. Wang, S. R. Kulkarni, and S. Verdú, “Divergence estimation for multidimensional densities via-nearest-neighbor distances,” IEEE Transactions on Information Theory, vol. 55, no. 5, pp. 2392–2405, 2009. [9] M. Noshad, K. R. Moon, S. Y. Sekeh, and A. O. Hero III, “Direct estimation of information divergence using nearest neighbor ratios,” arXiv preprint arXiv:1702.05222, 2017. [10] K. Kandasamy, A. Krishnamurthy, B. Poczos, L. Wasserman, et al., “Nonparametric Von Mises estimators for entropies, divergences and mutual informations,” in NIPS, pp. 397–405, 2015. [11] K. R. Moon, K. Sricharan, K. Greenewald, and A. O. Hero, “Improving convergence of divergence functional ensemble estimators,” in IEEE International Symposium Inf Theory, pp. 1133–1137, IEEE, 2016. [12] Y.-m. Zhang, K. Huang, G. Geng, and C.-l. Liu, “Fast kNN graph construction with locality sensitive hashing,” in Joint European Conference on Machine Learning and Knowledge Discovery in Databases, pp. 660–674, Springer, 2013. [13] Q. Lv, W. Josephson, Z. Wang, M. Charikar, and K. Li, “Multi-probe LSH: efficient indexing for high-dimensional similarity search,” in Proceedings of the 33rd international conference on Very large data bases, pp. 950–961, VLDB Endowment, 2007. [14] M. Znidaric, “Asymptotic expansion for inverse moments of binomial and Poisson distributions,” arXiv preprint math/0511226, 2005. [15] S. Singh and B. Póczos, “Generalized exponential concentration inequality for Renyi divergence estimation.,” in ICML, pp. 333–341, 2014. [16] A. Cichocki, H. Lee, Y.-D. Kim, and S. Choi, “Nonnegative matrix factorization with α-divergence,” Pattern Recognition Letters, vol. 29, no. 9, pp. 1433–1440, 2008. A. Variance Proof Proof of Theorem 2.2: The proof is based on Efron-Stein inequality. We follow similar steps used to prove the variance of NNR estimator in [9]. Note that the proof for variance of ρi = Ni /(Mi ) is contained in the the variance b g (X, Y ). Assume that we have two sets of nodes Xi , 1 ≤ i ≤ N and Yj for 1 ≤ j ≤ M . Here for proof for D simplicity we assume that N = M , however, the extension of the proof to the case when M and N are not equal, is straightforward, by considering a number of virtual points, as considered in [9]. Define Zi := (Xi , Yi ). For using 0 the Efron-Stein inequality on Z := (Z1 , ..., ZN ), we consider another independent copy of Z as Z 0 := (Z10 , ..., ZN ) (i) 0 b b and define Z := (Z1 , ..., Zi−1 , Zi , Zi+1 , ..., ZN ). Define Dg (Z) := Dg (X, Y ). By applying Efron-Stein inequality we have  N h i 2  X b g (Z) ≤ 1 b g (Z) − D b g (Z (i) ) V D E D 2 i=1  2  N (1) b b = E Dg (Z) − Dg (Z ) 2  2  !   (1) X   ηNi N  1 X ηNi (1) 1   Mi ge Mi ge ≤ E −     (1) 2 N Mi N Mi i≤F i≤F Mi >0 = Mi >0 2  !!   (1)   ηNi ηNi (1)   Mi ge − Mi ge   (1) Mi Mi  X 1   E   2N i≤F Mi >0 1 1 O(1) = O( ). (35) 2N N where in the last line we used the fact that Mi and Mi0 can be different just for two of i ≤ F , and that difference is just O(1). So, the proof is complete. = B. Proof of Theorem 2.3 Assume that the densities have bounded derivatives up to the order q. Then the Taylor expansion of f (y) around f (x) is as follows X Di f (x) f (y) = f (x) + ky − xki + O(ky − xkq ) . (36) i! |i|≤q Therefore, similar to (27) and using (29) we can write E [Ni0 ] = N Z f1 (x)dx x∈Bi Z =N f (Yi ) + x∈Bi X Dj f (Yi ) kx − Yi kj + O(kx − Yi kq )dx j! |j|≤q X Dj f (Yi )  = N d f1 (Yi ) + N Cj (Yi )|j|+d + O N Cq (Yi )q+d j! |j|≤q " # q X d 0 l q = N  f1 (Yi ) + Cl (Yi ) + O(Cq (Yi ) ) , l=1 where 0 C|j| (Yi ) := X Dj f (Yi ) Cj (Yi ). j! |j|≤q (37) Similarly we obtain " E  (Mi0 )−1  =M −1 −d  f2 (Yi ) + q X Cl0 (Yi )l q #−1  + O(Cq (Yi ) ) 1+O l=1  1 d M  f2 (Yi )  . (38) The rest of the proof follows by using the same steps as used in equations (32)-(34), and we get   q h i X 1 00 i b , B Dg (X, Y ) = Ci  + O N d i=1 (39) where C100 , ..., C200 are constants. Now are ready to apply the ensemble theorem ( [11], Theorem 4). Let T := {t1 , ..., tT } be a set of index values   with ti < c, where c > 0 is a constant. Let (t) := tN −1/2d . The proof completes by using the ensemble theorem in ( [11], Theorem 4) with the parameters ψi (t) = ti/d and φ0i,d (N ) = φi,κ (N )/N i/d . So the following weighted ensemble has the MSE convergence rate of O(1/N ): b w := D X b (t) . w(t)D (40) t∈T C. Proof of Theorem 3.1: We first argue that amortized runtime complexity of the online estimation algorithm is order O(1) for each update after adding new samples. Note that when we add a new pair of samples XN +1 and YN +1 , if N + 1 6= 2k for some integer k, we only find H(XN +1 ) and H(YN +1 ) and update the corresponding Mi and Ni , which take a constant time. But, only when N + 1 = 2k for some integer k, we need O(N ) time complexity to update  and therefore the hash function. Thus, if we have N = 2k nodes added to the estimation algorithm, the total complexity due to rehashing, TH , is as follows: TH = 1 + 2 + 22 + ... + 2k = 2k+1 − 1 = 2N − 1. (41) So, the amortized runtime complexity per each time step is O( 2NN−1 ) = O(1). So overall, the amortized computational complexity is order O(1). Finally, note that since we update  when N doubles, it is at most by a factor of 2 away from the optimum . Since constant factor doesn’t affect the asymptotic order of the bias error, the bias bound always holds for online estimation algorithm.
7cs.IT
Published as a conference paper at ICLR 2018 U NDERSTANDING D EEP N EURAL N ETWORKS R ECTIFIED L INEAR U NITS WITH Raman Arora∗ Amitabh Basu† Poorya Mianjy‡ Anirbit Mukherjee§ Johns Hopkins University arXiv:1611.01491v6 [cs.LG] 28 Feb 2018 A BSTRACT In this paper we investigate the family of functions representable by deep neural networks (DNN) with rectified linear units (ReLU). We give an algorithm to train a ReLU DNN with one hidden layer to global optimality with runtime polynomial in the data size albeit exponential in the input dimension. Further, we improve on the known lower bounds on size (from exponential to super exponential) for approximating a ReLU deep net function by a shallower ReLU net. Our gap theorems hold for smoothly parametrized families of “hard” functions, contrary to countable, discrete families known in the literature. An example consequence of our gap theorems is the following: for every natural number k there exists a function representable by a ReLU DNN with k 2 hidden layers and total size k 3 , such that any ReLU DNN with at most k hidden layers will require at least 21 k k+1 − 1 total nodes. Finally, for the family of Rn → R DNNs with ReLU activations, we show a new lowerbound on the number of affine pieces, which is larger than previous constructions in certain regimes of the network architecture and most distinctively our lowerbound is demonstrated by an explicit construction of a smoothly parameterized family of functions attaining this scaling. Our construction utilizes the theory of zonotopes from polyhedral theory. 1 I NTRODUCTION Deep neural networks (DNNs) provide an excellent family of hypotheses for machine learning tasks such as classification. Neural networks with a single hidden layer of finite size can represent any continuous function on a compact subset of Rn arbitrary well. The universal approximation result was first given by Cybenko in 1989 for sigmoidal activation function (Cybenko, 1989), and later generalized by Hornik to an arbitrary bounded and nonconstant activation function Hornik (1991). Furthermore, neural networks have finite VC dimension (depending polynomially on the number of edges in the network), and therefore, are PAC (probably approximately correct) learnable using a sample of size that is polynomial in the size of the networks Anthony & Bartlett (1999). However, neural networks based methods were shown to be computationally hard to learn (Anthony & Bartlett, 1999) and had mixed empirical success. Consequently, DNNs fell out of favor by late 90s. Recently, there has been a resurgence of DNNs with the advent of deep learning LeCun et al. (2015). Deep learning, loosely speaking, refers to a suite of computational techniques that have been developed recently for training DNNs. It started with the work of Hinton et al. (2006), which gave empirical evidence that if DNNs are initialized properly (for instance, using unsupervised pre-training), then we can find good solutions in a reasonable amount of runtime. This work was soon followed by a series of early successes of deep learning at significantly improving the state-of-the-art in speech recognition Hinton et al. (2012). Since then, deep learning has received immense attention from the machine learning community with several state-of-the-art AI systems in speech recognition, image classification, and natural language processing based on deep neural nets Hinton et al. (2012); Dahl et al. (2013); Krizhevsky et al. (2012); Le (2013); Sutskever et al. (2014). While there is less of evidence now that pre-training actually helps, several other solutions have since been put forth ∗ Department of Computer Science, Email: [email protected] Department of Applied Mathematics and Statistics, Email: [email protected] ‡ Department of Computer Science, Email: [email protected] § Department of Applied Mathematics and Statistics, Email: [email protected] † 1 Published as a conference paper at ICLR 2018 to address the issue of efficiently training DNNs. These include heuristics such as dropouts Srivastava et al. (2014), but also considering alternate deep architectures such as convolutional neural networks Sermanet et al. (2014), deep belief networks Hinton et al. (2006), and deep Boltzmann machines Salakhutdinov & Hinton (2009). In addition, deep architectures based on new non-saturating activation functions have been suggested to be more effectively trainable – the most successful and widely popular of these is the rectified linear unit (ReLU) activation, i.e., σ(x) = max{0, x}, which is the focus of study in this paper. In this paper, we formally study deep neural networks with rectified linear units; we refer to these deep architectures as ReLU DNNs. Our work is inspired by these recent attempts to understand the reason behind the successes of deep learning, both in terms of the structure of the functions represented by DNNs, Telgarsky (2015; 2016); Kane & Williams (2015); Shamir (2016), as well as efforts which have tried to understand the non-convex nature of the training problem of DNNs better Kawaguchi (2016); Haeffele & Vidal (2015). Our investigation of the function space represented by ReLU DNNs also takes inspiration from the classical theory of circuit complexity; we refer the reader to Arora & Barak (2009); Shpilka & Yehudayoff (2010); Jukna (2012); Saptharishi (2014); Allender (1998) for various surveys of this deep and fascinating field. In particular, our gap results are inspired by results like the ones by Hastad Hastad (1986), Razborov Razborov (1987) and Smolensky Smolensky (1987) which show a strict separation of complexity classes. We make progress towards similar statements with deep neural nets with ReLU activation. 1.1 N OTATION AND D EFINITIONS We extend the ReLU activation function to vectors x ∈ Rn through entry-wise operation: σ(x) = (max{0, x1 }, max{0, x2 }, . . . , max{0, xn }). For any (m, n) ∈ N, let Anm and Lnm denote the class of affine and linear transformations from Rm → Rn , respectively. Definition 1. [ReLU DNNs, depth, width, size] For any number of hidden layers k ∈ N, input and output dimensions w0 , wk+1 ∈ N, a Rw0 → Rwk+1 ReLU DNN is given by specifying a sequence of k natural numbers w1 , w2 , . . . , wk representing widths of the hidden layers, a set of k affine transformations Ti : Rwi−1 → Rwi for i = 1, . . . , k and a linear transformation Tk+1 : Rwk → Rwk+1 corresponding to weights of the hidden layers. Such a ReLU DNN is called a (k + 1)-layer ReLU DNN, and is said to have k hidden layers. The function f : Rn1 → Rn2 computed or represented by this ReLU DNN is f = Tk+1 ◦ σ ◦ Tk ◦ · · · ◦ T2 ◦ σ ◦ T1 , (1.1) where ◦ denotes function composition. The depth of a ReLU DNN is defined as k + 1. The width of a ReLU DNN is max{w1 , . . . , wk }. The size of the ReLU DNN is w1 + w2 + . . . + wk . Definition 2. We denote the class of Rw0 → Rwk+1 ReLU DNNs with k hidden layers of widths {wi }ki=1 by F{wi }k+1 , i.e. i=0 i F{wi }k+1 := {Tk+1 ◦ σ ◦ Tk ◦ · · · ◦ σ ◦ T1 : Ti ∈ Aw wi−1 ∀i ∈ {1, . . . , k}, i=0 k+1 Tk+1 ∈ Lw wk } (1.2) Definition 3. [Piecewise linear functions] We say a function f : Rn → R is continuous piecewise linear (PWL) if there exists a finite set of polyhedra whose union is Rn , and f is affine linear over each polyhedron (note that the definition automatically implies continuity of the function because the affine regions are closed and cover Rn , and affine functions are continuous). The number of pieces of f is the number of maximal connected subsets of Rn over which f is affine linear (which is finite). Many of our important statements will be phrased in terms of the following simplex. Definition 4. Let M > 0 be any positive real number and p ≥ 1 be any natural number. Define the following set: ∆pM := {x ∈ Rp : 0 < x1 < x2 < . . . < xp < M }. 2 E XACT CHARACTERIZATION OF FUNCTION CLASS REPRESENTED BY R E LU DNN S One of the main advantages of DNNs is that they can represent a large family of functions with a relatively small number of parameters. In this section, we give an exact characterization of the 2 Published as a conference paper at ICLR 2018 functions representable by ReLU DNNs. Moreover, we show how structural properties of ReLU DNNs, specifically their depth and width, affects their expressive power. It is clear from definition that any function from Rn → R represented by a ReLU DNN is a continuous piecewise linear (PWL) function. In what follows, we show that the converse is also true, that is any PWL function is representable by a ReLU DNN. In particular, the following theorem establishes a one-to-one correspondence between the class of ReLU DNNs and PWL functions. Theorem 2.1. Every Rn → R ReLU DNN represents a piecewise linear function, and every piecewise linear function Rn → R can be represented by a ReLU DNN with at most dlog2 (n + 1)e + 1 depth. Proof Sketch: It is clear that any function represented by a ReLU DNN is a PWL function. To see the converse, we first note that any PWL function can be represented as a linear combination of piecewise linear convex functions. More formally, by Theorem 1 in (Wang & Sun, 2005), for every piecewise linear function f : Rn → R, there exists a finite set of affine linear functions `1 , . . . , `k and subsets S1 , . . . , Sp ⊆ {1, . . . , k} (not necessarily disjoint) where each Si is of cardinality at most n + 1, such that   p X sj max `i , (2.1) f= i∈Sj j=1 where sj ∈ {−1, +1} for all j = 1, . . . , p. Since a function of the form maxi∈Sj `i is a piecewise linear convex function with at most n + 1 pieces (because |Sj | ≤ n + 1), Equation (2.1) says that any continuous piecewise linear function (not necessarily convex) can be obtained as a linear combination of piecewise linear convex functions each of which has at most n + 1 affine pieces. Furthermore, Lemmas D.1, D.2 and D.3 in the Appendix (see supplementary material), show that composition, addition, and pointwise maximum of PWL functions are also representable by ReLU |x−y| DNNs. In particular, in Lemma D.3 we note that max{x, y} = x+y is implementable by a 2 + 2 two layer ReLU network and use this construction in an inductive manner to show that maximum of n + 1 numbers can be computed using a ReLU DNN with depth at most dlog2 (n + 1)e. While Theorem 2.1 gives an upper bound on the depth of the networks needed to represent all continuous piecewise linear functions on Rn , it does not give any tight bounds on the size of the networks that are needed to represent a given piecewise linear function. For n = 1, we give tight bounds on size as follows: Theorem 2.2. Given any piecewise linear function R → R with p pieces there exists a 2-layer DNN with at most p nodes that can represent f . Moreover, any 2-layer DNN that represents f has size at least p − 1. Finally, the main result of this section follows from Theorem 2.1, and well-known facts that the piecewise linear functions are dense in the family of compactly supported continuous functions and the family of compactly supported continuous functions are dense in Lq (Rn ) (RoydenR & Fitzpatrick, 2010)). Recall that Lq (Rn ) is the space of Lebesgue integrable functions f such that |f |q dµ < ∞, where µ is the Lebesgue measure on Rn (see Royden Royden & Fitzpatrick (2010)). Theorem 2.3. Every function in Lq (Rn ), (1 ≤ q ≤ ∞)Rcan be arbitrarily well-approximated in the Lq norm (which for a function f is given by ||f ||q = ( |f |q )1/q ) by a ReLU DNN function with at most dlog2 (n + 1)e hidden layers. Moreover, for n = 1, any such Lq function can be arbitrarily well-approximated by a 2-layer DNN, with tight bounds on the size of such a DNN in terms of the approximation. Proofs of Theorems 2.2 and 2.3 are provided in Appendix A. We would like to remark that a weaker version of Theorem 2.1 was observed in (Goodfellow et al., 2013, Proposition 4.1) (with no bound on the depth), along with a universal approximation theorem (Goodfellow et al., 2013, Theorem 4.3) similar to Theorem 2.3. The authors of Goodfellow et al. (2013) also used a previous result of Wang (Wang, 2004) for obtaining their result. In a subsequent work Boris Hanin (Hanin, 2017) has, among other things, found a width and depth upper bound for ReLU net representation of positive PWL functions on [0, 1]n . The width upperbound is n+3 for general positive PWL functions and n + 1 for convex positive PWL functions. For convex positive PWL functions his depth upper bound is sharp if we disallow dead ReLUs. 3 Published as a conference paper at ICLR 2018 3 B ENEFITS OF D EPTH Success of deep learning has been largely attributed to the depth of the networks, i.e. number of successive affine transformations followed by nonlinearities, which is shown to be extracting hierarchical features from the data. In contrast, traditional machine learning frameworks including support vector machines, generalized linear models, and kernel machines can be seen as instances of shallow networks, where a linear transformation acts on a single layer of nonlinear feature extraction. In this section, we explore the importance of depth in ReLU DNNs. In particular, in Section 3.1, we provide a smoothly parametrized family of R → R “hard” functions representable by ReLU DNNs, which requires exponentially larger size for a shallower network. Furthermore, in Section 3.2, we construct a continuum of Rn → R “hard” functions representable by ReLU DNNs, which to the best of our knowledge is the first explicit construction of ReLU DNN functions whose number of affine pieces grows exponentially with input dimension. The proofs of the theorems in this section are provided in Appendix B. 3.1 C IRCUIT LOWER BOUNDS FOR R → R R E LU DNN S In this section, we are only concerned about R → R ReLU DNNs, i.e. both input and output dimensions are equal to one. The following theorem shows the depth-size trade-off in this setting. Theorem 3.1. For every pair of natural numbers k ≥ 1, w ≥ 2, there exists a family of hard functions representable by a R → R (k + 1)-layer ReLU DNN of width w such that if it is also representable by a (k 0 + 1)-layer ReLU DNN for any k 0 ≤ k, then this (k 0 + 1)-layer ReLU DNN k has size at least 12 k 0 w k0 − 1. In fact our family of hard functions described above has a very intricate structure as stated below. Theorem 3.2. For every k ≥ 1, w ≥ 2, every member of the family of hard functions in Theorem 3.1 has wk pieces and this family can be parametrized by [ (∆w−1 × ∆w−1 × . . . × ∆w−1 (3.1) M M M ), {z } | M >0 k times i.e., for every point in the set above, there exists a distinct function with the stated properties. The following is an immediate corollary of Theorem 3.1 by choosing the parameters carefully. Corollary 3.3. For every k ∈ N and  > 0, there is a family of functions defined on the real line such that every function f from this family can be represented by a (k 1+ ) + 1-layer DNN with size  k 2+ and if f is represented by a k +1-layer DNN, then this DNN must have size at least 21 k ·k k −1. 2+ k Moreover, this family can be parametrized as, ∪M >0 ∆M −1 . A particularly illuminative special case is obtained by setting  = 1 in Corollary 3.3: Corollary 3.4. For every natural number k ∈ N, there is a family of functions parameterized by the 3 set ∪M >0 ∆kM −1 such that any f from this family can be represented by a k 2 + 1-layer DNN with k 3 nodes, and every k + 1-layer DNN that represents f needs at least 12 k k+1 − 1 nodes. We can also get hardness of approximation versions of Theorem 3.1 and Corollaries 3.3 and 3.4, with the same gaps (upto constant terms), using the following theorem. Theorem 3.5. For every k ≥ 1, w ≥ 2, there exists a function fk,w that can be represented by a (k + 1)-layer ReLU DNN with w nodes in each layer, such that for all δ > 0 and k 0 ≤ k the following holds: Z 1 inf |fk,w (x) − g(x)|dx > δ, g∈Gk0 ,δ x=0 where Gk0 ,δ is the family of functions representable by ReLU DNNs with depth at most k 0 + 1, and size at most k 0 w k/k0 (1−4δ)1/k 21+1/k0 0 . The depth-size trade-off results in Theorems 3.1, and 3.5 extend and improve Telgarsky’s theorems from (Telgarsky, 2015; 2016) in the following three ways: 4 Published as a conference paper at ICLR 2018 (i) If we use our Theorem 3.5 to the pair of neural nets considered by Telgarsky in Theorem 1.1 in Telgarsky (2016) which are at depths k 3 (of size also scaling as k 3 ) and k then for this purpose of approximation in the `1 −norm we would get a size lower bound for 2 the shallower net which scales as Ω(2k ) which is exponentially (in depth) larger than the k lower bound of Ω(2 ) that Telgarsky can get for this scenario. (ii) Telgarsky’s family of hard functions is parameterized by a single natural number k. In contrast, we show that for every pair of natural numbers w and k, and a point from the set in equation 3.1, there exists a “hard” function which to be represented by a depth k 0 network k would need a size of at least w k0 k 0 . With the extra flexibility of choosing the parameter w, for the purpose of showing gaps in representation ability of deep nets we can shows size lower bounds which are super-exponential in depth as explained in Corollaries 3.3 and 3.4. (iii) A characteristic feature of the “hard” functions in Boolean circuit complexity is that they are usually a countable family of functions and not a “smooth” family of hard functions. In fact, in the last section of Telgarsky (2015), Telgarsky states this as a “weakness” of the state-of-the-art results on “hard” functions for both Boolean circuit complexity and neural nets research. In contrast, we provide a smoothly parameterized family of “hard” functions in Section 3.1 (parametrized by the set in equation 3.1). Such a continuum of hard functions wasn’t demonstrated before this work. We point out that Telgarsky’s results in (Telgarsky, 2016) apply to deep neural nets with a host of different activation functions, whereas, our results are specifically for neural nets with rectified linear units. In this sense, Telgarsky’s results from (Telgarsky, 2016) are more general than our results in this paper, but with weaker gap guarantees. Eldan-Shamir (Shamir, 2016; Eldan & Shamir, 2016) show that there exists an Rn → R function that can be represented by a 3-layer DNN, that takes exponential in n number of nodes to be approximated to within some constant by a 2-layer DNN. While their results are not immediately comparable with Telgarsky’s or our results, it is an interesting open question to extend their results to a constant depth hierarchy statement analogous to the recent result of Rossman et al (Rossman et al., 2015). We also note that in last few years, there has been much effort in the community to show size lowerbounds on ReLU DNNs trying to approximate various classes of functions which are themselves not necessarily exactly representable by ReLU DNNs (Yarotsky, 2016; Liang & Srikant, 2016; Safran & Shamir, 2017). 3.2 A CONTINUUM OF HARD FUNCTIONS FOR Rn → R FOR n ≥ 2 One measure of complexity of a family of Rn → R “hard” functions represented by ReLU DNNs is the asymptotics of the number of pieces as a function of dimension n, depth k + 1 and size s of the ReLU DNNs. More precisely, suppose one has a family H of functions such that for every n, k, w ∈ N the family contains at least one Rn → R function representable by a ReLU DNN with depth at most k + 1 and maximum width at most w. The following definition formalizes a notion of complexity for such a H. Definition 5 (compH (n, k, w)). The measure compH (n, k, w) is defined as the maximum number of pieces (see Definition 3) of a Rn → R function from H that can be represented by a ReLU DNN with depth at most k + 1 and maximum width at most w. Similar measures have been studied in previous works Montufar et al. (2014); Pascanu et al. (2013); Raghu et al. (2016). The best known families H are the ones from Theorem 4 of (Montufar et al., 2014) and a mild generalization of Theorem 1.1 of (Telgarsky, 2016) to k layers  (k−1)n  Pn w of ReLU activations with width w; these constructions achieve b( n )c ( j=0 wj )and compH (n, k, s) = O(wk ), respectively. At the end of this section we would explain the precise sense in which we improve on these numbers. An analysis of this complexity measure is done using integer programming techniques in (Serra et al., 2017). Definition 6. Let b1 , . . . , bm ∈ Rn . The zonotope formed by b1 , . . . , bm ∈ Rn is defined as Z(b1 , . . . , bm ) := {λ1 b1 + . . . + λm bm : −1 ≤ λi ≤ 1, i = 1, . . . , m}. 5 Published as a conference paper at ICLR 2018 (a) H 1 , 1 ◦ N`1 2 2 (b) H 1 , 1 ◦ γZ(b1 ,b2 ,b3 ,b4 ) (c) H 1 , 1 , 1 ◦ γZ(b1 ,b2 ,b3 ,b4 ) 2 2 2 2 2 Figure 1: We fix the a vectors for a two hidden layer R → R hard function as a1 = a2 = ( 12 ) ∈ ∆11 Left: A specific hard function induced by `1 norm: ZONOTOPE22,2,2 [a1 , a2 , b1 , b2 ] where b1 = (0, 1) and b2 = (1, 0). Note that in this case the function can be seen as a composition of Ha1 ,a2 with `1 -norm N`1 (x) := kxk1 = γZ((0,1),(1,0)) . Middle: A typical hard function ZONOTOPE22,2,4 [a1 , a2 , c1 , c2 , c3 , c4 ] with generators c1 = ( 41 , 12 ), c2 = (− 12 , 0), c3 = (0, − 14 ) and c4 = (− 14 , − 14 ). Note how increasing the number of zonotope generators makes the function more complex. Right: A harder function from ZONOTOPE23,2,4 family with the same set of generators c1 , c2 , c3 , c4 but one more hidden layer (k = 3). Note how increasing the depth make the function more complex. (For illustrative purposes we plot only the part of the function which lies above zero.) The set of vertices of Z(b1 , . . . , bm ) will be denoted by vert(Z(b1 , . . . , bm )). The support function γZ(b1 ,...,bm ) : Rn → R associated with the zonotope Z(b1 , . . . , bm ) is defined as γZ(b1 ,...,bm ) (r) = max hr, xi. x∈Z(b1 ,...,bm ) The following results are well-known in the theory of zonotopes (Ziegler, 1995). Theorem 3.6. The following are all true.  Pn−1 1. | vert(Z(b1 , . . . , bm ))| ≤ i=0 m−1 . The set of (b1 , . . . , bm ) ∈ Rn × . . . × Rn such i that this does not hold at equality is a 0 measure set. 2. γZ(b1 ,...,bm ) (r) = maxx∈Z(b1 ,...,bm ) hr, xi = maxx∈vert(Z(b1 ,...,bm )) hr, xi, and γZ(b1 ,...,bm ) is therefore a piecewise linear function with | vert(Z(b1 , . . . , bm ))| pieces. 3. γZ(b1 ,...,bm ) (r) = |hr, b1 i| + . . . + |hr, bm i|. Definition 7 (extremal zonotope set). The set S(n, m) will denote the set of (b1 , . . . , bm ) ∈ Rn ×  P n−1 1 m m−1 . . . × Rn such that | vert(Z(b , . . . , b ))| = i=0 . S(n, m) is the so-called “extremal i zonotope set”, which is a subset of Rnm , whose complement has zero Lebesgue measure in Rnm . Lemma 3.7. Given any b1 , . . . , bm ∈ Rn , there exists a 2-layer ReLU DNN with size 2m which represents the function γZ(b1 ,...,bm ) (r). Definition 8. For p ∈ N and a ∈ ∆pM , we define a function ha : R → R which is piecewise linear over the segments (−∞, 0], [0, a1 ], [a1 , a2 ], . . . , [ap , M ], [M, +∞) defined as follows: ha (x) = 0 for all x ≤ 0, ha (ai ) = M (i mod 2), and ha (M ) = M − ha (ap ) and for x ≥ M , ha (x) is a linear continuation of the piece over the interval [ap , M ]. Note that the function has p + 2 pieces, with the leftmost piece having slope 0. Furthermore, for a1 , . . . , ak ∈ ∆pM , we denote the composition of the functions ha1 , ha2 , . . . , hak by Ha1 ,...,ak := hak ◦ hak−1 ◦ . . . ◦ ha1 . Proposition 3.8. Given any tuple (b1 , . . . , bm ) ∈ S(n, m) and any point [ (a1 , . . . , ak ) ∈ (∆w−1 × ∆w−1 × . . . × ∆w−1 M M M ), {z } | M >0 k times 1 m n 1 k ZONOTOPEk,w,m [a , . . . , a , b , . . . , b ] := the function Ha1 ,...,ak ◦ γZ(b1 ,...,bm ) has (m − 1)n−1 wk pieces and it can be represented by a k + 2 layer ReLU DNN with size 2m + wk. 6 Published as a conference paper at ICLR 2018 Finally, we are ready to state the main result of this section. Theorem 3.9. For every tuple of natural numbers n, k, m ≥ 1 and w ≥ 2, there exists a family of Rn → R functions, which we call ZONOTOPEnk,w,m with the following properties: (i) Every f ∈ ZONOTOPEnk,w,m is representable by a ReLU DNN of depth k + 2 and size P  n−1 m−1 2m + wk, and has wk pieces. i=0 i (ii) Consider any f ∈ ZONOTOPEnk,w,m . If f is represented by a (k 0 + 1)0 layerDNN for any k ≤ k, then this (k 0 +  1)-layer DNN has size at least k 1 (1− n ) k10 1 w k0 0 kk0 n 0 max 2 (k w ) · (m − 1) − 1 , n1/k0 k . (iii) The family ZONOTOPEnk,w,m is in one-to-one correspondence with [ S(n, m) × (∆w−1 × ∆w−1 × . . . × ∆w−1 M M M ). | {z } M >0 k times Comparison to the results in (Montufar et al., 2014) Firstly we note that the construction in (Montufar et al., 2014) requires all the hidden layers to have width at least as big as the input dimensionality n. In contrast, we do not impose such restrictions and the network size in our construction is independent of the input dimensionality. Thus our result probes networks with bottleneck architectures whose complexity cant be seen from their result. Secondly, in terms of our complexity measure, there seem to be regimes where our bound does n better. One such regime, for example, is when n ≤ w < 2n and k ∈ Ω( log(n) ), by setting in our construction m < n. Thirdly, it is not clear to us whether the construction in (Montufar et al., 2014) gives a smoothly parameterized family of functions other than by introducing small perturbations of the construction in their paper. In contrast, we have a smoothly parameterized family which is in one-to-one correspondence with a well-understood manifold like the higher-dimensional torus. 4 T RAINING 2- LAYER Rn → R R E LU DNN S TO GLOBAL OPTIMALITY In this section we consider the following empirical risk minimization problem. Given D data points (xi , yi ) ∈ Rn × R, i = 1, . . . , D, find the function f represented by 2-layer Rn → R ReLU DNNs of width w, that minimizes the following optimization problem D D  1 X 1 X min `(f (xi ), yi ) ≡ min ` T2 (σ(T1 (xi ))), yi (4.1) w 1 f ∈F{n,w,1} D T1 ∈An , T2 ∈Lw D i=1 i=1 where ` : R × R → R is a convex loss function (common loss functions are the squared loss, `(y, y 0 ) = (y − y 0 )2 , and the hinge loss function given by `(y, y 0 ) = max{0, 1 − yy 0 }). Our main result of this section gives an algorithm to solve the above empirical risk minimization problem to global optimality. Theorem 4.1. There exists an algorithm to find a global optimum of Problem 4.1 in time O(2w (D)nw poly(D, n, w)). Note that the running time O(2w (D)nw poly(D, n, w)) is polynomial in the data size D for fixed n, w. Proof Sketch: A full proof of Theorem 4.1 is included in Appendix C. Here we provide a sketch of the proof. When the empirical risk minimization problem is viewed as an optimization problem in the space of weights of the ReLU DNN, it is a nonconvex, quadratic problem. However, one can instead search over the space of functions representable by 2-layer DNNs by writing them in the form similar to (2.1). This breaks the problem into two parts: a combinatorial search and then a convex problem that is essentially linear regression with linear inequality constraints. This enables us to guarantee global optimality. 7 Published as a conference paper at ICLR 2018 Algorithm 1 Empirical Risk Minimization 1: function ERM(D) 2: S = {+1, −1}w 3: P i = {(P+i , P−i )}, i = 1, . . . , w 4: P = P1 × P2 × · · · × Pw 5: count = 1 6: for s ∈ S do 7: for {(P+i , P−i )}w P do i=1 ∈     minimize:   ã,b̃ 8: loss(count) =       subject to: n . Where D = {(xi , yi )}D i=1 ⊂ R × R . All possible instantiations of top layer weights . All possible partitions of data into two parts . Counter D X X j=1 `(si (ãi · xj + b̃i ), yj ) i i:j∈P+ ãi · xj + b̃i ≤ 0 ∀j ∈ P−i ãi · xj + b̃i ≥ 0 ∀j ∈ P+i 9: count + + 10: end for 11: OPT = argmin loss(count) 12: end for 13: return {ã}, {b̃}, s corresponding to OPT’s iterate 14: end function Let T1 (x) = Ax + b and T2 (y) = a0 · y for A ∈ Rw×n and b, a0 ∈ Rw . If we denote the i-th row of the matrix A by ai , and write bi , a0i to denote the i-th coordinates of the vectors b, a0 respectively, due to homogeneity of ReLU gates, the network output can be represented as f (x) = w X i=1 a0i max{0, ai · x + bi } = w X i=1 si max{0, ãi · x + b̃i }. where ãi ∈ Rn , b̃i ∈ R and si ∈ {−1, +1} for all i = 1, . . . , w. For any hidden node i ∈ {1 . . . , w}, the pair (ãi , b̃i ) induces a partition P i := (P+i , P−i ) on the dataset, given by P−i = {j : ãi · xj + b˜i ≤ 0} and P+i = {1, . . . , D}\P−i . Algorithm 1 proceeds by generating all combinations of the partitions P i as well as the top layer weights s ∈ {+1, −1}w , and minimizing the loss PD P i i i j=1 i:j∈P i `(si (ã · xj + b̃i ), yj ) subject to the constraints ã · xj + b̃i ≤ 0 ∀j ∈ P− and + ãi · xj + b̃i ≥ 0 ∀j ∈ P+i which are imposed for all i = 1, . . . , w, which is a convex program. Algorithm 1 implements the empirical risk minimization (ERM) rule for training ReLU DNN with one hidden layer. To the best of our knowledge there is no other known algorithm that solves the ERM problem to global optimality. We note that due to known hardness results exponential dependence on the input dimension is unavoidable Blum & Rivest (1992); Shalev-Shwartz & BenDavid (2014); Algorithm 1 runs in time polynomial in the number of data points. To the best of our knowledge there is no hardness result known which rules out empirical risk minimization of deep nets in time polynomial in circuit size or data size. Thus our training result is a step towards resolving this gap in the complexity literature. A related result for improperly learning ReLUs has been recently obtained by Goel et al (Goel et al., 2016). In contrast, our algorithm returns a ReLU DNN from the class being learned. Another difference is that their result considers the notion of reliable learning as opposed to the empirical risk minimization objective considered in (4.1). 5 D ISCUSSION The running time of the algorithm that we give in this work to find the exact global minima of a two layer ReLU-DNN is exponential in the input dimension n and the number of hidden nodes w. The exponential dependence on n can not be removed unless P = N P ; see Shalev-Shwartz & Ben-David (2014); Blum & Rivest (1992); DasGupta et al. (1995). However, we are not aware of any complexity results which would rule out the possibility of an algorithm which trains to global optimality in time that is polynomial in the data size and/or the number of hidden nodes, assuming that the input dimension is a fixed constant. Resolving this dependence on network size would be another step towards clarifying the theoretical complexity of training ReLU DNNs and is a good 8 Published as a conference paper at ICLR 2018 open question for future research, in our opinion. Perhaps an even better breakthrough would be to get optimal training algorithms for DNNs with two or more hidden layers and this seems like a substantially harder nut to crack. It would also be a significant breakthrough to get gap results between consecutive constant depths or between logarithmic and constant depths. ACKNOWLEDGMENTS We would like to thank Christian Tjandraatmadja for pointing out a subtle error in a previous version of the paper, which affected the complexity results for the number of linear regions in our constructions in Section 3.2. Anirbit would like to thank Ramprasad Saptharishi, Piyush Srivastava and Rohit Gurjar for extensive discussions on Boolean and arithmetic circuit complexity. This paper has been immensely influenced by the perspectives gained during those extremely helpful discussions. Amitabh Basu gratefully acknowledges support from the NSF grant CMMI1452820. Raman Arora was supported in part by NSF BIGDATA grant IIS-1546482. R EFERENCES Eric Allender. Complexity theory lecture notes. https://www.cs.rutgers.edu/ ˜allender/lecture.notes/, 1998. Martin Anthony and Peter L. Bartlett. Neural network learning: Theoretical foundations. Cambridge University Press, 1999. Sanjeev Arora and Boaz Barak. Computational complexity: a modern approach. Cambridge University Press, 2009. Avrim L. Blum and Ronald L. Rivest. Training a 3-node neural network is np-complete. Neural Networks, 5(1):117–127, 1992. George Cybenko. Approximation by superpositions of a sigmoidal function. Mathematics of control, signals and systems, 2(4):303–314, 1989. George E. Dahl, Tara N. Sainath, and Geoffrey E. Hinton. Improving deep neural networks for lvcsr using rectified linear units and dropout. In 2013 IEEE International Conference on Acoustics, Speech and Signal Processing, pp. 8609–8613. IEEE, 2013. Bhaskar DasGupta, Hava T. Siegelmann, and Eduardo Sontag. On the complexity of training neural networks with continuous activation functions. IEEE Transactions on Neural Networks, 6(6): 1490–1504, 1995. Ronen Eldan and Ohad Shamir. The power of depth for feedforward neural networks. In 29th Annual Conference on Learning Theory, pp. 907–940, 2016. Surbhi Goel, Varun Kanade, Adam Klivans, and Justin Thaler. Reliably learning the relu in polynomial time. arXiv preprint arXiv:1611.10258, 2016. Ian J Goodfellow, David Warde-Farley, Mehdi Mirza, Aaron Courville, and Yoshua Bengio. Maxout networks. arXiv preprint arXiv:1302.4389, 2013. Benjamin D. Haeffele and René Vidal. Global optimality in tensor factorization, deep learning, and beyond. arXiv preprint arXiv:1506.07540, 2015. Boris Hanin. Universal function approximation by deep neural nets with bounded width and relu activations. arXiv preprint arXiv:1708.02691, 2017. Johan Hastad. Almost optimal lower bounds for small depth circuits. In Proceedings of the eighteenth annual ACM symposium on Theory of computing, pp. 6–20. ACM, 1986. Geoffrey Hinton, Li Deng, Dong Yu, George E. Dahl, Abdel-rahman Mohamed, Navdeep Jaitly, Andrew Senior, Vincent Vanhoucke, Patrick Nguyen, Tara N Sainath, et al. Deep neural networks for acoustic modeling in speech recognition: The shared views of four research groups. IEEE Signal Processing Magazine, 29(6):82–97, 2012. Geoffrey E. Hinton, Simon Osindero, and Yee-Whye Teh. A fast learning algorithm for deep belief nets. Neural computation, 18(7):1527–1554, 2006. Kurt Hornik. Approximation capabilities of multilayer feedforward networks. Neural networks, 4 (2):251–257, 1991. 9 Published as a conference paper at ICLR 2018 Stasys Jukna. Boolean function complexity: advances and frontiers, volume 27. Springer Science & Business Media, 2012. Daniel M. Kane and Ryan Williams. Super-linear gate and super-quadratic wire lower bounds for depth-two and depth-three threshold circuits. arXiv preprint arXiv:1511.07860, 2015. Kenji Kawaguchi. Deep learning without poor local minima. arXiv preprint arXiv:1605.07110, 2016. Alex Krizhevsky, Ilya Sutskever, and Geoffrey E. Hinton. Imagenet classification with deep convolutional neural networks. In Advances in neural information processing systems, pp. 1097–1105, 2012. Quoc V. Le. Building high-level features using large scale unsupervised learning. In 2013 IEEE international conference on acoustics, speech and signal processing, pp. 8595–8598. IEEE, 2013. Yann LeCun, Yoshua Bengio, and Geoffrey Hinton. Deep learning. Nature, 521(7553):436–444, 2015. Shiyu Liang and R Srikant. Why deep neural networks for function approximation? 2016. Jiri Matousek. Lectures on discrete geometry, volume 212. Springer Science & Business Media, 2002. Guido F. Montufar, Razvan Pascanu, Kyunghyun Cho, and Yoshua Bengio. On the number of linear regions of deep neural networks. In Advances in neural information processing systems, pp. 2924–2932, 2014. Razvan Pascanu, Guido Montufar, and Yoshua Bengio. On the number of response regions of deep feed forward networks with piece-wise linear activations. arXiv preprint arXiv:1312.6098, 2013. Maithra Raghu, Ben Poole, Jon Kleinberg, Surya Ganguli, and Jascha Sohl-Dickstein. On the expressive power of deep neural networks. arXiv preprint arXiv:1606.05336, 2016. Alexander A. Razborov. Lower bounds on the size of bounded depth circuits over a complete basis with logical addition. Mathematical Notes, 41(4):333–338, 1987. Benjamin Rossman, Rocco A. Servedio, and Li-Yang Tan. An average-case depth hierarchy theorem for boolean circuits. In Foundations of Computer Science (FOCS), 2015 IEEE 56th Annual Symposium on, pp. 1030–1048. IEEE, 2015. H.L. Royden and P.M. Fitzpatrick. Real Analysis. Prentice Hall, 2010. Itay Safran and Ohad Shamir. Depth-width tradeoffs in approximating natural functions with neural networks. In International Conference on Machine Learning, pp. 2979–2987, 2017. Ruslan Salakhutdinov and Geoffrey E. Hinton. Deep boltzmann machines. In International Conference on Artificial Intelligence and Statistics (AISTATS), volume 1, pp. 3, 2009. R. Saptharishi. A survey of lower bounds in arithmetic circuit complexity, 2014. Pierre Sermanet, David Eigen, Xiang Zhang, Michael Mathieu, Rob Fergus, and Yann LeCun. Overfeat: Integrated recognition, localization and detection using convolutional networks. In International Conference on Learning Representations (ICLR 2014). arXiv preprint arXiv:1312.6229, 2014. Thiago Serra, Christian Tjandraatmadja, and Srikumar Ramalingam. Bounding and counting linear regions of deep neural networks. arXiv preprint arXiv:1711.02114, 2017. Shai Shalev-Shwartz and Shai Ben-David. Understanding machine learning: From theory to algorithms. Cambridge university press, 2014. Ohad Shamir. Distribution-specific hardness of learning neural networks. arXiv preprint arXiv:1609.01037, 2016. Amir Shpilka and Amir Yehudayoff. Arithmetic circuits: A survey of recent results and open questions. Foundations and Trends R in Theoretical Computer Science, 5(3–4):207–388, 2010. Roman Smolensky. Algebraic methods in the theory of lower bounds for boolean circuit complexity. In Proceedings of the nineteenth annual ACM symposium on Theory of computing, pp. 77–82. ACM, 1987. Nitish Srivastava, Geoffrey E. Hinton, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Dropout: a simple way to prevent neural networks from overfitting. Journal of Machine Learning Research, 15(1):1929–1958, 2014. 10 Published as a conference paper at ICLR 2018 Ilya Sutskever, Oriol Vinyals, and Quoc V. Le. Sequence to sequence learning with neural networks. In Advances in neural information processing systems, pp. 3104–3112, 2014. Matus Telgarsky. Representation benefits of deep feedforward networks. arXiv preprint arXiv:1509.08101, 2015. Matus Telgarsky. benefits of depth in neural networks. In 29th Annual Conference on Learning Theory, pp. 1517–1539, 2016. Shuning Wang. General constructive representations for continuous piecewise-linear functions. IEEE Transactions on Circuits and Systems I: Regular Papers, 51(9):1889–1896, 2004. Shuning Wang and Xusheng Sun. Generalization of hinging hyperplanes. IEEE Transactions on Information Theory, 51(12):4425–4431, 2005. Dmitry Yarotsky. Error bounds for approximations with deep relu networks. arXiv preprint arXiv:1610.01145, 2016. Günter M. Ziegler. Lectures on polytopes, volume 152. Springer Science & Business Media, 1995. A E XPRESSING PIECEWISE LINEAR FUNCTIONS USING R E LU DNN S Proof of Theorem 2.2. Any continuous piecewise linear function R → R which has m pieces can be specified by three pieces of information, (1) sL the slope of the left most piece, (2) the coordinates of the non-differentiable points specified by a (m − 1)−tuple {(ai , bi )}m−1 i=1 (indexed from left to right) and (3) sR the slope of the rightmost piece. A tuple (sL , sR , (a1 , b1 ), . . . , (am−1 , bm−1 ) uniquely specifies a m piecewise linear function from R → R and vice versa. Given such a tuple, we construct a 2-layer DNN which computes the same piecewise linear function. One notes that for any a, r ∈ R, the function  0 x≤a f (x) = r(x − a) x > a (A.1) is equal to sgn(r) max{|r|(x − a), 0}, which can be implemented by a 2-layer ReLU DNN with size 1. Similarly, any function of the form,  t(x − a) x ≤ a g(x) = (A.2) 0 x>a is equal to − sgn(t) max{−|t|(x − a), 0}, which can be implemented by a 2-layer ReLU DNN with size 1. The parameters r, t will be called the slopes of the function, and a will be called the breakpoint of the function.If we can write the given piecewise linear function as a sum of m functions of the form (A.1) and (A.2), then by Lemma D.2 we would be done. It turns out that such a decomposition of any p piece PWL function h : R → R as a sum of p flaps can always be arranged where the breakpoints of the p flaps all are all contained in the p − 1 breakpoints of h. First, observe that adding a constant to a function does not change the complexity of the ReLU DNN expressing it, since this corresponds to a bias on the output node. Thus, we will assume that the value of h at the last break point am−1 is bm−1 = 0. We now use a single function f of the form (A.1) with slope r and breakpoint a = am−1 , and m − 1 functions g1 , . . . , gm−1 of the form (A.2) with slopes t1 , . . . , tm−1 and breakpoints a1 , . . . , am−1 , respectively. Thus, we wish to express h = f + g1 + . . . + gm−1 . Such a decomposition of h would be valid if we can find values for r, t1 , . . . , tm−1 such that (1) the slope of the above sum is = sL for x < a1 , (2) the slope of the above sum is = sR for x > am−1 , and (3) for each i ∈ {1, 2, 3, .., m − 1} we have bi = f (ai ) + g1 (ai ) + . . . + gm−1 (ai ). The above corresponds to asking for the existence of a solution to the following set of simultaneous linear equations in r, t1 , . . . , tm−1 : sR = r, sL = t1 + t2 + . . . + tm−1 , bi = m−1 X j=i+1 tj (aj−1 − aj ) for all i = 1, . . . , m − 2 It is easy to verify that the above set of simultaneous linear equations has a unique solution. Indeed, r must equal sR , and then one can solve for t1 , . . . , tm−1 starting from the last equation bm−2 = 11 Published as a conference paper at ICLR 2018 tm−1 (am−2 − am−1 ) and then back substitute to compute tm−2 , tm−3 , . . . , t1 . The lower bound of p − 1 on the size for any 2-layer ReLU DNN that expresses a p piece function follows from Lemma D.6. One can do better in terms of size when the rightmost piece of the given function is flat, i.e., sR = 0. In this case r = 0, which means that f = 0; thus, the decomposition of h above is of size p − 1. A similar construction can be done when sL = 0. This gives the following statement which will be useful for constructing our forthcoming hard functions. Corollary A.1. If the rightmost or leftmost piece of a R → R piecewise linear function has 0 slope, then we can compute such a p piece function using a 2-layer DNN with size p − 1. Proof of theorem 2.3. Since any piecewise linear function Rn → R is representable by a ReLU DNN by Corollary 2.1, the proof simply follows from the fact that the family of continuous piecewise linear functions is dense in any Lp (Rn ) space, for 1 ≤ p ≤ ∞. B B.1 B ENEFITS OF D EPTH C ONSTRUCTING A CONTINUUM OF HARD FUNCTIONS FOR R → R R E LU DNN S AT EVERY DEPTH AND EVERY WIDTH Lemma B.1. For any M > 0, p ∈ N, k ∈ N and a1 , . . . , ak ∈ ∆pM , if we compose the functions ha1 , ha2 , . . . , hak the resulting function is a piecewise linear function with at most (p + 1)k + 2 pieces, i.e., Ha1 ,...,ak := hak ◦ hak−1 ◦ . . . ◦ ha1 is piecewise linear with at most (p + 1)k + 2 pieces, with (p + 1)k of these pieces in the range [0, M ] (see Figure 2). Moreover, in each piece in the range [0, M ], the function is affine with minimum value 0 and maximum value M . Proof. Simple induction on k. Proof of Theorem 3.2. Given k ≥ 1 and w ≥ 2, choose any point [ (a1 , . . . , ak ) ∈ (∆w−1 × ∆w−1 × . . . × ∆w−1 M M M ). {z } | M >0 k times By Definition 8, each hai , i = 1, . . . , k is a piecewise linear function with w + 1 pieces and the leftmost piece having slope 0. Thus, by Corollary A.1, each hai , i = 1, . . . , k can be represented by a 2-layer ReLU DNN with size w. Using Lemma D.1, Ha1 ,...,ak can be represented by a k + 1 layer DNN with size wk; in fact, each hidden layer has exactly w nodes. Proof of Theorem 3.1. Follows from Theorem 3.2 and Lemma D.6. Proof of Theorem 3.5. Given k ≥ 1 and w ≥ 2 define q := wk and sq := ha ◦ ha ◦ . . . ◦ ha where | {z } k times q−1 a = ( w1 , w2 , . . . , w−1 . Thus, sq is representable by a ReLU DNN of width w +1 and depth w ) ∈ ∆1 k + 1 by Lemma D.1. In what follows, we want to give a lower bound on the `1 distance of sq from any continuous p-piecewise linear comparator gp : R → R. The function sq contains b 2q c triangles of width 2q and unit height. A p-piecewise linear function has p − 1 breakpoints in the interval [0, 1]. k So that in at least b w2 c − (p − 1) triangles, gp has to be affine. In the following we demonstrate that 12 Published as a conference paper at ICLR 2018 1 0.8 0.6 0.4 0.2 0 -0.2 0 0.2 0.4 0.6 0.8 1 1.2 0 0.2 0.4 0.6 0.8 1 1.2 0 0.2 0.4 0.6 0.8 1 1.2 1 0.8 0.6 0.4 0.2 0 -0.2 1 0.8 0.6 0.4 0.2 0 -0.2 Figure 2: Top: ha1 with a1 ∈ ∆21 with 3 pieces in the range [0, 1]. Middle: ha2 with a2 ∈ ∆11 with 2 pieces in the range [0, 1]. Bottom: Ha1 ,a2 = ha2 ◦ ha1 with 2 · 3 = 6 pieces in the range [0, 1]. The dotted line in the bottom panel corresponds to the function in the top panel. It shows that for every piece of the dotted graph, there is a full copy of the graph in the middle panel. inside any triangle of sq , any affine function will incur an `1 error of at least Z 2i+2 wk x= 2i wk |sq (x) − gp (x)|dx = Z = 1 wk x=0 Z xwk − y1 − 2 wk x=0 sq (x) − (y1 + (x − 0) · wk x (y2 − y1 ) dx + 2 Z 2 wk x= 1 wk 1 . 2wk y2 − y1 ) dx 2 −0 wk 2 − xwk − y1 − wk x (y2 − y1 ) dx 2 1 2 1 1 z z z − y1 − (y2 − y1 ) dz + k 2 − z − y1 − (y2 − y1 ) dz k w z=0 2 w z=1 2   2 2 1 2y1 2(−2 + y1 ) = k −3 + y1 + + y2 + w 2 + y1 − y2 2 − y1 + y2 Z Z = The above integral attains its minimum of 2w1 k at y1 = y2 = 21 . Putting together,  k  w 1 wk − 1 − 2(p − 1) 1 2p − 1 kswk − gp k1 ≥ b c − (p − 1) · ≥ = − k k 2 2w 4w 4 4wk Thus, for any δ > 0, p≤ wk − 4wk δ + 1 1 1 2p − 1 =⇒ 2p − 1 ≤ ( − δ)4wk =⇒ − ≥ δ =⇒ kswk − gp k1 ≥ δ. 2 4 4 4wk The result now follows from Lemma D.6. B.2 A CONTINUUM OF HARD FUNCTIONS FOR Rn → R FOR n ≥ 2 Proof of Lemma 3.7. By Theorem 3.6 part 3., γZ(b1 ,...,bm ) (r) = |hr, b1 i| + . . . + |hr, bm i|. It suffices to observe |hr, b1 i| + . . . + |hr, bm i| = max{hr, b1 i, −hr, b1 i} + . . . + max{hr, bm i, −hr, bm i}. Proof of Proposition 3.8. The fact that ZONOTOPEnk,w,m [a1 , . . . , ak , b1 , . . . , bm ] can be represented by a k + 2 layer ReLU DNN with size 2m + wk follows from Lemmas 3.7 and D.1. The  Pn−1 number of pieces follows from the fact that γZ(b1 ,...,bm ) has i=0 m−1 distinct linear pieces by i parts 1. and 2. of Theorem 3.6, and Ha1 ,...,ak has wk pieces by Lemma B.1. Proof of Theorem 3.9. Follows from Proposition 3.8. 13 Published as a conference paper at ICLR 2018 C E XACT E MPIRICAL R ISK M INIMIZATION Proof of Theorem 4.1. Let ` : R → R be any convex loss function, and let (x1 , y1 ), . . . , (xD , yD ) ∈ Rn × R be the given D data points. As stated in (4.1), the problem requires us to find an affine transformation T1 : Rn → Rw and a linear transformation T2 : Rw → R, so as to minimize the empirical loss as stated in (4.1). Note that T1 is given by a matrix A ∈ Rw×n and a vector b ∈ Rw so that T (x) = Ax + b for all x ∈ Rn . Similarly, T2 can be represented by a vector a0 ∈ Rw such that T2 (y) = a0 · y for all y ∈ Rw . If we denote the i-th row of the matrix A by ai , and write bi , a0i to denote the i-th coordinates of the vectors b, a0 respectively, we can write the function represented by this network as f (x) = w X i=1 a0i max{0, ai · x + bi } = w X i=1 sgn(a0i ) max{0, (|a0i |ai ) · x + |a0i |bi }. In other words, the family of functions over which we are searching is of the form f (x) = w X i=1 si max{0, ãi · x + b̃i } (C.1) where ãi ∈ Rn , bi ∈ R and si ∈ {−1, +1} for all i = 1, . . . , w. We now make the following observation. For a given data point (xj , yj ) if ãi · xj + b̃i ≤ 0, then the i-th term of (C.1) does not contribute to the loss function for this data point (xj , yj ). Thus, for every data point (xj , yj ), P there exists a set Sj ⊆ {1, . . . , w} such that f (xj ) = i∈Sj si (ãi · xj + b̃i ). In particular, if we are given the set Sj for (xj , yj ), then the expression on the right hand side of (C.1) reduces to a linear function of ãi , b̃i . For any fixed i ∈ {1, . . . , w}, these sets Sj induce a partition of the data set into two parts. In particular, we define P+i := {j : i ∈ Sj } and P−i := {1, . . . , D} \ P+i . Observe now that this partition is also induced by the hyperplane given by ãi , b̃i : P+i = {j : ãi · xj + b̃i > 0} and P+i = {j : ãi · xj + b̃i ≤ 0}. Our strategy will be to guess the partitions P+i , P−i for each i = 1, . . . , w, and then do linear regression with the constraint that regression’s decision variables ãi , b̃i induce the guessed partition. More formally, the algorithm does the following. For each i = 1, . . . , w, the algorithm guesses a partition of the data set (xj , yj ), j = 1, . . . , D by a hyperplane. Let us label the partitions as follows (P+i , P−i ), i = 1, . . . , w. So, for each i = 1, . . . , w, P+i ∪ P−i = {1, . . . , D}, P+i and P−i are disjoint, and there exists a vector c ∈ Rn and a real number δ such that P−i = {j : c · xj + δ ≤ 0} and P+i = {j : c · xj + δ > 0}. Further, for each i = 1, . . . , w the algorithm selects a vector s in {+1, −1}w . For a fixed selection of partitions (P+i , P−i ), i = 1, . . . , w and a vector s in {+1, −1}w , the algorithm solves the following convex optimization problem with decision variables ãi ∈ Rn , b̃i ∈ R for i = 1, . . . , w (thus, we have a total of (n + 1) · w decision variables). The feasible region of the optimization is given by the constraints ãi · xj + b̃i ≤ 0 ∀j ∈ P−i ãi · xj + b̃i ≥ 0 ∀j ∈ P+i (C.2) which are imposed for all i = 1, . . . , w. Thus, we have a total of D · w constraints. Subject to PD P these constraints we minimize the objective j=1 i:j∈P i `(si (ãi · xj + b̃i ), yj ). Assuming the + loss function ` is a convex function in the first argument, the above objective is a convex function. Thus, we have to minize a convex objective subject to the linear inequality constraints from (C.2). We finally have to count how many possible partitions (P+i , P−i ) and vectors s the algorithm has to search through. It is well-known Matousek (2002) that the total number of possible hyperplane n partitions of a set of size D in Rn is at most 2 D n ≤ D whenever n ≥ 2. Thus with a guess for each nw i = 1, . . . , w, we have a total of at most D partitions. There are 2w vectors s in {−1, +1}w . This gives us a total of 2w Dnw guesses for the partitions (P+i , P−i ) and vectors s. For each such guess, we have a convex optimization problem with (n + 1) · w decision variables and D · w constraints, which can be solved in time poly(D, n, w). Putting everything together, we have the running time claimed in the statement. 14 Published as a conference paper at ICLR 2018  The above argument holds only for n ≥ 2, since we used the inequality 2 D ≤ Dn which n only holds for n ≥ 2. For n = 1, a similar algorithm can be designed, but one which uses the characterization achieved in Theorem 2.2. Let ` : R → R be any convex loss function, and let (x1 , y1 ), . . . , (xD , yD ) ∈ R2 be the given D data points. Using Theorem 2.2, to solve problem (4.1) it suffices to find a R → R piecewise linear function f with w pieces that minimizes the total loss. In other words, the optimization problem (4.1) is equivalent to the problem ( min D X ) `(f (xi ), yi ) : f is piecewise linear with w pieces . (C.3) i=1 We now use the observation that fitting piecewise linear functions to minimize loss is just a step away from linear regression, which is a special case where the function is contrained to have exactly one affine linear piece. Our algorithm will first guess the optimal partition of the data points such that all points in the same class of the partition correspond to the same affine piece of f , and then do linear regression in each class of the partition. Altenatively, one can think of this as guessing the interval (xi , xi+1 ) of data points where the w − 1 breakpoints of the piecewise linear function will lie, and then doing linear regression between the breakpoints. More formally, we parametrize piecewise linear functions with w pieces by the w slope-intercept values (a1 , b1 ), . . . , (a2 , b2 ), . . . , (aw , bw ) of the w different pieces. This means that between breakpoints j and j + 1, 1 ≤ j ≤ w − 2, the function is given by f (x) = aj+1 x + bj+1 , and the first and last pieces are a1 x + b1 and aw x + bw , respectively. Define I to be the set of all (w − 1)-tuples (i1 , . . . , iw−1 ) of natural numbers such that 1 ≤ i1 ≤ . . . ≤ iw−1 ≤ D. Given a fixed tuple I = (i1 , . . . , iw−1 ) ∈ I, we wish to search through all piecewise linear functions whose breakpoints, in order, appear in the intervals (xi1 , xi1 +1 ), (xi2 , xi2 +1 ), . . . , (xiw−1 , xiw−1 +1 ). Define also S = {−1, 1}w−1 . Any S ∈ S will have the following interpretation: if Sj = 1 then aj ≤ aj+1 , and if Sj = −1 then aj ≥ aj+1 . Now for every I ∈ I and S ∈ S, requiring a piecewise linear function that respects the conditions imposed by I and S is easily seen to be equivalent to imposing the following linear inequalities on the parameters (a1 , b1 ), . . . , (a2 , b2 ), . . . , (aw , bw ): Sj (bj+1 − bj − (aj − aj+1 )xij ) ≥ 0 Sj (bj+1 − bj − (aj − aj+1 )xij +1 ) ≤ 0 Sj (aj+1 − aj ) ≥ 0 (C.4) Let the set of piecewise linear functions whose breakpoints satisfy the above be denoted by PWL1I,S for I ∈ I, S ∈ S. Given a particular I ∈ I, we define D1 := {xi : i ≤ i1 }, Dj := {xi : ij−1 < i ≤ i1 } Dw := {xi : i > iw−1 } j = 2, . . . , w − 1, . Observe that  D w  X X X min{ `(f (xi )−yi ) : f ∈ PWL1I,S } = min{ `(aj ·xi +bj −yi ) : (aj , bj ) satisfy (C.4)} i=1 j=1 i∈Dj (C.5) The right hand side of the above equation is the problem of minimizing a convex objective subject to linear constraints. Now, to solve (C.3), we need to simply solve the problem (C.5) for all I ∈ I, S ∈ w w−1 we need to solve O(2w · Dw ) S and pick the minimum. Since |I| = D w = O(D ) and |S| = 2 convex optimization problems, each taking time O(poly(D)). Therefore, the total running time is O((2D)w poly(D)). 15 Published as a conference paper at ICLR 2018 D AUXILIARY L EMMAS Now we will collect some straightforward observations that will be used often. The following operations preserve the property of being representable by a ReLU DNN. Lemma D.1. [Function Composition] If f1 : Rd → Rm is represented by a d, m ReLU DNN with depth k1 + 1 and size s1 , and f2 : Rm → Rn is represented by an m, n ReLU DNN with depth k2 + 1 and size s2 , then f2 ◦ f1 can be represented by a d, n ReLU DNN with depth k1 + k2 + 1 and size s1 + s2 . Proof. Follows from (1.1) and the fact that a composition of affine transformations is another affine transformation. Lemma D.2. [Function Addition] If f1 : Rn → Rm is represented by a n, m ReLU DNN with depth k + 1 and size s1 , and f2 : Rn → Rm is represented by a n, m ReLU DNN with depth k + 1 and size s2 , then f1 + f2 can be represented by a n, m ReLU DNN with depth k + 1 and size s1 + s2 . Proof. We simply put the two ReLU DNNs in parallel and combine the appropriate coordinates of the outputs. Lemma D.3. [Taking maximums/minimums] Let f1 , . . . , fm : Rn → R be functions that can each be represented by Rn → R ReLU DNNs with depths ki + 1 and size si , i = 1, . . . , m. Then the function f : Rn → R defined as f (x) := max{f1 (x), . . . , fm (x)} can be represented by a ReLU DNN of depth at most max{k1 , . . . , km } + log(m) + 1 and size at most s1 + . . . sm + 4(2m − 1). Similarly, the function g(x) := min{f1 (x), . . . , fm (x)} can be represented by a ReLU DNN of depth at most max{k1 , . . . , km } + dlog(m)e + 1 and size at most s1 + . . . sm + 4(2m − 1). Proof. We prove this by induction on m. The base case m = 1 is trivial. For m ≥ 2, consider g1 := max{f1 , . . . , fb m2 c } and g2 := max{fb m2 c+1 , . . . , fm }. By the induction hypothesis (since m bm 2 c, d 2 e < m when m ≥ 2), g1 and g2 can be represented by ReLU DNNs of depths at most m m max{k1 , . . . , kb m2 c } + dlog(b m 2 c)e + 1 and max{kb 2 c+1 , . . . , km } + dlog(d 2 e)e + 1 respectively, m m and sizes at most s1 + . . . sb m2 c + 4(2b m 2 c − 1) and sb 2 c+1 + . . . + sm + 4(2b 2 c − 1), respectively. n 2 Therefore, the function G : R → R given by G(x) = (g1 (x), g2 (x)) can be implemented by a ReLU DNN with depth at most max{k1 , . . . , km } + dlog(d m 2 e)e + 1 and size at most s1 + . . . + sm + 4(2m − 2). We now show how to represent the function T : R2 → R defined as T (x, y) = max{x, y} = |x−y| x+y by a 2-layer ReLU DNN with size 4 – see Figure 3. The result now follows from the 2 + 2 fact that f = T ◦ G and Lemma D.1. 1 Input x1 1 2 1 -1 − 12 -1 -1 Input x2 1 2 1 1 x1 +x2 2 + |x1 −x2 | 2 1 2 -1 Figure 3: A 2-layer ReLU DNN computing max{x1 , x2 } = x1 +x2 2 + |x1 −x2 | 2 Lemma D.4. Any affine transformation T : Rn → Rm is representable by a 2-layer ReLU DNN of size 2m. 16 Published as a conference paper at ICLR 2018 Proof. Simply use the fact that T = (I ◦ σ ◦ T ) + (−I ◦ σ ◦ (−T )), and the right hand side can be represented by a 2-layer ReLU DNN of size 2m using Lemma D.2. Lemma D.5. Let f : R → R be a function represented by a R → R ReLU DNN with depth k + 1 and widths w1 , . . . , wk of the k hidden layers. Then f is a PWL function with at most 2k−1 · (w1 + 1) · w2 · . . . · wk pieces. 1 0.8 0.6 0.4 0.2 0 -0.2 0 0.2 0.4 0.6 0.8 1 1.2 0 0.2 0.4 0.6 0.8 1 1.2 0.6 0.4 0.2 0 -0.2 -0.4 -0.2 Figure 4: The number of pieces increasing after activation. If the blue function is f , then the red function g = max{0, f + b} has at most twice the number of pieces as f for any bias b ∈ R. Proof. We prove this by induction on k. The base case is k = 1, i.e, we have a 2-layer ReLU DNN. Since every activation node can produce at most one breakpoint in the piecewise linear function, we can get at most w1 breakpoints, i.e., w1 + 1 pieces. Now for the induction step, assume that for some k ≥ 1, any R → R ReLU DNN with depth k + 1 and widths w1 , . . . , wk of the k hidden layers produces at most 2k−1 · (w1 + 1) · w2 · . . . · wk pieces. Consider any R → R ReLU DNN with depth k + 2 and widths w1 , . . . , wk+1 of the k + 1 hidden layers. Observe that the input to any node in the last layer is the output of a R → R ReLU DNN with depth k + 1 and widths w1 , . . . , wk . By the induction hypothesis, the input to this node in the last layer is a piecewise linear function f with at most 2k−1 · (w1 + 1) · w2 · . . . · wk pieces. When we apply the activation, the new function g(x) = max{0, f (x)}, which is the output of this node, may have at most twice the number of pieces as f , because each original piece may be intersected by the x-axis; see Figure 4. Thus, after going through the layer, we take an affine combination of wk+1 functions, each with at most 2 · (2k−1 · (w1 + 1) · w2 · . . . · wk ) pieces. In all, we can therefore get at most 2·(2k−1 ·(w1 +1)·w2 ·. . .·wk )·wk+1 pieces, which is equal to 2k ·(w1 +1)·w2 ·. . .·wk ·wk+1 , and the induction step is completed. Lemma D.5 has the following consequence about the depth and size tradeoffs for expressing functions with agiven number of pieces. Lemma D.6. Let f : R → R be a piecewise linear function with p pieces. If f is represented by a ReLU DNN with depth k + 1, then it must have size at least 21 kp1/k − 1. Conversely, any piecewise linear function f that represented by a ReLU DNN of depth k + 1 and size at most s, can have at k most ( 2s k ) pieces. Proof. Let widths of the k hidden layers be w1 , . . . , wk . By Lemma D.5, we must have 2k−1 · (w1 + 1) · w2 · . . . · wk ≥ p. (D.1) By the AM-GM inequality, minimizing the size w1 + w2 + . . . + wk subject to (D.1), means setting w1 + 1 = w2 = . . . = wk . This implies that w1 + 1 = w2 = . . . = wk ≥ 12 p1/k . The first statement follows. The second statement follows using the AM-GM inequality again, this time with a restriction on w1 + w2 + . . . + wk . 17
2cs.AI
HOMOLOGY OF HOMOGENEOUS DIVISORS arXiv:1207.5862v1 [math.AC] 25 Jul 2012 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU A BSTRACT. One deals with arbitrary reduced free divisors in a polynomial ring over a field of characteristic zero, by stressing the ideal theoretic and homological behavior of the corresponding singular locus. A particular emphasis is given to both weighted homogeneous and homogeneous polynomials, allowing to introduce new families of free divisors which do not come from hyperplane arrangements nor as explicit discriminants from singularity theory. I NTRODUCTION Let Y be a reduced divisor on a smooth algebraic variety X over the complex field. According to [21], Y is called a free divisor on X if the OX −module DerX (− log Y ) := {θ ∈ Der(X) | θ(OX (−Y )) ⊆ OX (−Y )}, is free, where OX is the sheaf of regular functions on X. A special case is that of a non-smooth reduced divisor Y = V (F ) ⊂ P2 on the projective plane, where F is a squarefree homogeneous form of degree d in R := K[x, y, z]. F is called the defining polynomial of Y and the ideal JF of R generated by the partial derivatives Fx , Fy , Fz of F is the gradient ideal of F . Since F is squarefree and non-smooth, JF has codimension 2. Let Der(R) be the R−module of derivations on R, and let DF := {θ ∈ Der(R) : θ(F ) ∈ hF i} be the R−module of logarithmic derivations on F . Y is called a free divisor if and only if DF is a ∂ ∂ ∂ + y ∂y + z ∂z is in DF . In free R−module. Since dF = xFx + yFy + zFz , one has that θE = x ∂x fact, DF = θE R ⊕ DF0 , where DF0 is an R−submodule of DF whose elements are in one-to-one correspondence with the syzygies on JF . We have that Y is free if and only if JF is a perfect ideal (i.e., the ring R/JF is Cohen-Macaulay). The notion of a free divisor was originally associated with hyperplane arrangement theory. When Y is a hyperplane arrangement in a vector space of finite dimension, free divisors received a great deal of interest: [18, 21, 23, 28, 29, 33] to cite just a few. When X is not necessarily the projective or the affine space, [7] gives some insights on the freeness of divisors on X in this general setup. In the case of divisors on the projective space, or affine space, some important results were obtained, especially when X = P2 in [17, 22, 24, 25, 30]. The advantage of working with divisors on Pn is that Saito’s Criterion ([21]) translates into the following: the divisor Y is free if and only if the gradient ideal of Y is a perfect ideal of codimension 2. On P2 , because this ideal is generated by three homogeneous polynomials of the same degree, ideals of this type have been studied extensively (besides the already mentioned references, see [6, 11, 26]). The disadvantage is that for these divisors 2010 Mathematics Subject Classification. Primary: 13C14, 13D02, 14B05; Secondary: 14C20. Key words and phrases. free divisor, perfect ideal of codimension two, saturation, Cramer ideal. The first author is partially supported by a CNPq Grant. 1 2 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU one does not have a lattice of intersection, and hence the combinatorics plays a very minimal role in the game. The tone of free divisor theory as embedded in hyperplane arrangements is that the divisors come up naturally with many irreducible components. Discriminant theory gives another picture of the theory away from arrangements, but a systematization thereof is yet to come up in the literature. Even when keeping offshore from hyperplane arrangements, the results have remained close to generalizations thereof, such as arrangements of lines and smooth conics in P2 (as in [22]). A question arises as to whether there are families of homogeneous free divisors of arbitrary degrees which arise out of simple constructs in algebraic geometry. This question makes sense even for non-irreducible reduced homogeneous polynomials, but is reaches its pick interest in the irreducible case. By a suitable addition procedure one can turn some highly nonfree irreducible homogeneous divisors into free divisors (see Proposition 2.11 and Proposition 2.12). As an illustration, in 3 variables and arbitrary degree, this procedure yields a free divisor f = gh with just two irreducible factors, where g = y r z d−r − xd is a cuspidal type singularity and h = y is its multiple tangent line at (0 : 0 : 1). At the other end, there are homogeneous irreducible free divisors of linear type of degree 4 in 4 variables. One such example is the defining equation of the tangential surface (or the dual surface) to the rational normal curve in P3 ([24, Remark 4.4]) – it is highly suggestive that this is the case of the dual hypersurface V (F ) ⊂ (Pn )∗ of the rational normal curve Cn ⊂ Pn , for any n ≥ 3, an expectation that has been verified computationally for initial values of n. Alas, the degree of V (f ) is 2n − 2, so we get no examples in odd degrees. Thus, even in higher dimension, homogeneous irreducible free divisors are not so abundant, as it seems. But it is in dimension 2 that things get really tight, thus leaving the hope to be able to classify them. In most of the papers cited here, to be able to say something about the freeness of these “nonlinear” divisors, an extra condition about the singularities must be added: they must be locally everywhere weighted homogeneous. In terms of the gradient ideal, this ideal must be locally (at the minimal primes) a complete intersection (see [20] or, for some more detailed explanations, [22]). The overall goal of this work is an insight into the freeness of divisors on Pn , with particular emphasis in the case n = 2. Some of the main results are stated in Theorem 1.15, Theorem 2.6 and Theorem 2.12. Let us now briefly describe the contents of each section. The first section is a collection of known and new results about codimension 2 ideals I in the polynomial ring R := K[x, y, z] which are generated by three forms (almost complete intersection) of same degree. The goal is to have a priori properties enjoyed by the singular ideal (gradient ideal) of a homogeneous polynomial and to establish possible templates for the latter to fit in. These properties distant themselves from combinatorics in that they mainly appeal to the usual numerical invariants coming from commutative algebra and homology. In this line of quest, we discuss the syzygies and the regularity of an ideal of the above kind. The behavior of the latter helps to distinguish between a perfect such ideal (the case of the gradient ideal of a free divisor) and a nonperfect one. Some of these results are in line with with [11]. We then consider the symmetric and Rees algebras of the ideal since these configure a way of understanding when a free divisor is Koszul-free or of linear type, or even of syzygetic type. There is a deep entanglement between these pre-homological properties and the geometry of the divisor which is yet to be better understood. The last part of the first section is mainly devoted to analyzing the local cohomology module 0 Hhx,y,xi (R/I) = I sat /I in the special case in which it coincides with the socle of R/I. This led us naturally to introduce a class of ideals we call Cramer ideals. Of course, the whole section is moved by the spectrum of the following questions: given a 3 × 2 homogeneous matrix φ over R such that HOMOLOGY OF HOMOGENEOUS DIVISORS 3 the ideal I2 (φ) of 2-minors has codimension 2, when are these minors integrable (i.e., the partial derivatives of a form in R)? For which non-perfect homogeneous ideals J ⊂ R (not necessarily generated in same degree) is J sat the gradient ideal of a free divisor? The second section is totally devoted to a discussion of free divisors. We first get a glimpse of irreducible homogenous free divisors according to their degree, describing infinite families of such divisors of degree ≥ 5. Unfortunately, for any degree ≥ 6 the gradient ideal of a member fails for the property of being of linear type. It is as yet a challenge to exhibit explicit families of irreducible homogeneous free divisors of linear type for all degree ≥ 6. In the sequel, we study weighted homogeneous polynomials and their homogenization as regards to freeness. We show that the gradient ideal of the homogenization always has a linear syzygy, a result that turns out to be very basic in this part. Using it we are able to characterize the binary weighted homogenous divisors f ∈ K[x, y] whose homogenization F ∈ K[x, y, z] is a free divisor ; in particular, no irreducible such f has this property. We are likewise able to write down the minimal free resolution of JF in any case and note that the corresponding shifts depend only on deg(f ) (not on the integer weights of f ). We also discuss the so-called cone cone(f ) ∈ K[x1 , . . . , xn , t] of a weighted homogeneous f ∈ K[x1 , . . . , xn ] and give a sufficient condition for the cone of f to be a free divisor in terms of the homogenization of f . The rest of the section looks at the details of some constructs, some new, some known. Here we introduce some classes of homogenous divisors which give rise to free homogenous divisors by means of adding a free divisor. The procedure yields an iterative method to create new free divisors of arbitrary degrees asymptotically as the number of variables grows. Finally, we review some classical free divisors in regards to the ideal theoretic and homological tool introduced in earlier parts. 1. I DEAL THEORETIC AND HOMOLOGICAL PRELIMINARIES Let K stand for an algebraically closed field of characteristic zero (usually the complex numbers). The restriction on the characteristic may be lifted for much of the preparatory material in this part. 1.1. Syzygies and regularity. Almost all the results in this subsection are valid for more general classes of rings and ideals. Since our primary interests are codimension 2 ideals I ⊂ R := K[x, y, z] minimally generated by three homogeneous polynomials of the same degree, we will state the results accordingly to this setup. We will need a preliminary result of general interest. It will suffice to consider a restricted case though is admits more general formulations. Its contents follow essentially from a close inspection of a Hilbert series (see [11, Proof of Theorem 1.5, (13)]), but we chose to give a completely elementary proof that also clarifies its use. Lemma 1.1. Let I ⊂ R = K[x, y, z] be an ideal of codimension 2 generated by 3 forms of degree d. The following conditions are equivalent: (i) There exist two distinct minimal generating syzygies of degrees r1 and r2 such that r1 +r2 ≥ d + 1. (ii) I is not a perfect ideal. (iii) For any two distinct minimal generating syzygies of degrees r1 and r2 , one has r1 + r2 ≥ d + 1. Proof. (i) ⇒ (ii) This is clear: if I is perfect then it is generated by the 2 × 2 minors of a 3 × 2 matrix with columns of (standard) degrees that sum up to d. (ii) ⇒ (iii) This is the core implication. Suppose given two distinct minimal generating syzygies of degrees r1 and r2 such that r1 + r2 ≤ d. We can assume that the given syzygies are columns of the minimal graded presentation matrix φ of I; call ψ the 3 × 2 submatrix they form. Dualizing into 4 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU R, the kernel of the transposed φt is generated by a unique vector whose coordinates give, on one hand, a set of minimal generators of I and, on the other hand, are (up to sign) the 2 × 2 minors of the 2 × 3 submatrix ψ t of φt divided by their gcd. It follows that this gcd must be unit, hence a set of generators of I is the set of 2 × 2 minors of ψ. This means that I is a perfect ideal. (iii) ⇒ (i) This is trivial.  Let reg(M ) denote the Castelnuovo-Mumford regularity of a finitely generated graded module over a standard polynomial ring over a field. Corollary 1.2. Let R = K[x, y, z] and I ⊂ R denote an ideal of codimension 2, minimally then I is perfect and equality generated by 3 forms of degree d ≥ 2. If reg(R/I) ≤ 3d−4 2 reg(R/I) = 3d−4 2 holds, with d necessarily even. Proof. Pick two distinct minimal generating syzygies of I, of degrees r1 and r2 ≥ r1 . Clearly, reg(R/I) ≥ d + r2 − 2 ≥ d + r1 − 2, hence r1 + r2 ≤ d. By Lemma 1.1, I is perfect. But then reg(R/I) = d + r2 − 2 as it must be the case. An immediate calculation now yields reg(R/I) ≥ 3d−4  2 . It is obvious that d must be even. sat Suppose that I is not perfect. The condition indeg(I /I) ≥ d + 1 implies the upper bound reg(R/I) ≤ 2d − 4 ([11, Theorem 1.5]). This condition is necessary in general as the following simple example of a gradient ideal shows. Example 1.3. Let I be the gradient ideal of F = x(x2 + yz) (a conic and a transversal line). We have I = h3x2 + yz, xz, xyi and reg(R/I) = 2 which of course is not less or equal to 2d − 4 = 0. Also I sat = hx, yzi, and hence reg(R/I sat ) = 1. Note that indeg(I sat /I) = 1 < d + 1 = 3 and that st(I) = 2. st(I) The above example has reg(R/I) = 3d−4 2 + 2 . In [11, Corollary 1.7 (ii)] this value is shown to be attained whenever I is non-perfect, I sat /I is generated in a fixed degree and indeg(I sat /I) ≥ d + 1. It is remarkable that the last condition is very natural in the realm of gradient ideals of reduced forms in K[x, y, z]. We wonder whether this bound is attained for gradient ideals under relaxed assumptions. In fact, an answer is interesting enough even in the restricted case of gradients of line arrangements. A couple of examples may illustrate this point. Example 1.4. Let I ⊂ R denote the gradient ideal of the line arrangement xyz(x + y + z) ∈ R. Then I sat = hI, xyzi = hx, yi ∩ hx, zi ∩ hy, zi ∩ hx, y + zi ∩ hy, x + zi ∩ hz, x + yi is minimally generated by 4 forms of degree 3 and one has st(I) = 1. The minimal free resolution of R/I has the shape 0 → R(−6) −→ R(−5)3 −→ R(−3)3 −→ R, hence reg(R/I) = 3 = 3d−4 2 + st(I) 2 , with d = 3. Example 1.5. Let I ⊂ R denote the gradient ideal of the line arrangement Then xyz(x + y)(x + z)(y + z) ∈ R. I sat = hI, gi, where g is form of degree 6. Again, st(I) = 1, but this time around the additional two conditions stated in [11, Corollary 1.7 (ii)] hold true. The minimal free resolution of R/I has the shape 0 → R(−9) −→ R(−8)3 −→ R(−5)3 −→ R, HOMOLOGY OF HOMOGENEOUS DIVISORS hence reg(R/I) = 6 = 3d−4 2 + st(I) 2 , 5 with d = 5. We note en passant that both examples are of ideals of linear type, to be introduced in the next subsection. 1.2. Related algebras. To proceed, let I = hf1 , f2 , f3 i be a codimension 2 ideal in R. Then I has a presentation φ Rm → R3 → I → 0. Suppose that φ has columns the syzygies (ai , bi , ci ), i = 1, . . . , m. Then the symmetric algebra of I is SR (I) = R[T1 , T2 , T3 ]/ha1 T1 + b1 T2 + c1 T3 , . . . , am T1 + bm T2 + cm T3 i. n Let R(I) := ⊕∞ n=0 I denote the Rees algebra of I. Then we have a surjective map of R-algebras ψ : SR (I) → R(I) induced by mapping Ti 7→ fi , where fi is viewed in degree 1. The algebra R(I) has a similar, but more complicated, presentation ideal. Generators of these ideals are often referred to, respectively, as equations of the symmetric algebra and Rees equations (or equations of I). An ideal I is called of linear type if the above map is injective (in other words, if SR (I) ∼ = R(I)). By [17, Lemma 3.1 and Corollary 3.2] we have the following characterization (which is true for arbitrary number of variables): Proposition 1.6. Let I be an ideal of codimension 2 in R = K[x, y, z] minimally generated by three homogeneous forms. Then the following are equivalent: (1) I is of linear type. (2) I localized at any of its minimal primes is a complete intersection. φ (3) If Rm → R3 → I → 0 is the minimal presentation of I, then the ideal generated by the entries of φ has codimension 3. Actually, there is a more general statement ([26, Proposition 3.7], also [13, Remark 10.5] and [27, Proposition 5.1]): Proposition 1.7. Let I be an almost complete intersection in any Cohen-Macaulay ring R such that depth R/I ≥ dim R/I − 1. If I localized at any of its minimal primes is a complete intersection (i.e., generically a complete intersection), then SR (I) ∼ = R(I). The following result is very useful: Proposition 1.8. [30, Theorem 2.1] Let I ⊂ R be an ideal of codimension 2 minimally generated by three homogeneous polynomials of the same degree. Then the following are equivalent: (1) I is perfect of linear type. (2) I has a syzygy forming a regular sequence of length 3. We note that Proposition 1.8 is not true in more than 3 variables. Similar restriction on the number of variables can be found in [6, Theorem 1.7] which gives the following syzygetical interpretation of locally complete intersections. Proposition 1.9. Let I ⊂ R = K[x, y, z] be an ideal of codimension 2 minimally generated by three homogeneous polynomials. Then the following are equivalent: (1) I is locally a complete intersection (at its minimal primes) (2) The only syzygies on I with coordinates in I sat are the Koszul syzygies. 6 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU Note that I is perfect if and only if I = I sat . In the saturated case the above result has been established in [26, Proposition 2.3] for higher codimension almost complete intersections. Denoting Z(I) ⊂ R3 (respectively, K(I)) the module of syzygies (respectively, Koszul syzygies) of A, B, C, the second condition above reads as the equality Z(I) ∩ I sat R3 = K(I). The relevance of the condition that I be generically a complete intersection is discussed in [9, Corollary 2.6 and Question 2.7] in its connection to the theorem of Dolgachev on reduced homaloidal plane divisors. Now, a basic condition discussed in (1.1) for an ideal generated by forms of the same degree d is the lower bound indeg(I sat /I) ≥ d + 1. This bound holds true for the gradient ideal a homaloidal polynomial – more generally, for any Cremona map of Pn with base ideal I. For a proof of this fact see [19, Proposition 1.2] (also [1, Proposition 2.5.2] for the plane case). It seems timely to pose the following Question 1.10. Let I = JF denote the gradient ideal of a reduced form F ∈ K[x, y, z] of degree d + 1 satisfying the bound indeg(I sat /I) ≥ d + 1. When is Z(I) ∩ I sat R3 = K(I)? If I = I sat the bound is vacuously satisfied since indeg({0}) = +∞. In this case, the question asks which saturated gradient ideals are syzygetic in the sense of [15] (see also [26, Section 2]) – i.e., such that the so-called syzygy part Z(I) ∩ IR3 /K(I) vanishes. In Proposition 2.2 a manyparameter family of irreducible plane sextic curves with saturated gradient ideals is given that fail for the above implication. We now give a 3-parameter family of irreducible sextic curves, with non-saturated gradient ideals, for which the implication fails in the strong sense that the respective gradient ideals are not even syzygetic. Proposition 1.11. Let F = x6 + αx3 y 3 + βx2 y 4 + γy 5 z ∈ R := K[x, y, z], where α, β, γ ∈ K are nonzero. Then (i) The gradient ideal JF ⊂ R is not saturated. (ii) indeg(JFsat /JF ) ≥ 6. (iii) Z(JF ) ∩ JFsat R3 6= K(JF ) – more strongly, JF is not syzygetic. Proof. Everything is computable with [14], by either: assuming the coefficients are indeterminates, then virtually chopping off some superfluous relations in the results pretending these indeterminates are scalars; or else, taking random coefficients. However, often a little preliminary hand calculation can tell us quite a bit in the right direction. Set I = JF = h6x5 + 3αx2 y 3 + 2βxy 4 , 3αx3 y 2 + 4βx2 y 3 + 5γy 4 z, y 5 i. (i) We claim: • (0, −y 3 , 3αx3 + 4βx2 y + 5γy 2 z)t is a syzygy of I • x2 y 4 ∈ I : hx, y, zi \ I. The first is an immediate verification by looking at the shape of Fy , Fz . For the second, the following three relations are directly confirmed: HOMOLOGY OF HOMOGENEOUS DIVISORS 2 4 x·x y =   1 1 2 2 y Fy + − (4βx + 5γ yz) Fz = v1 Fy + w1 Fz 3αγ |3 α {z } | {z } v1 (1) y · x2 y 4 = 7 w1 1 2 x Fz = w2 Fz γ | {z } w2 2 4 z·x y = +   −α 2 4β 16 β 2 2 1 2 y Fx + x − xy + y Fy 10 γ 5γ 15 α γ 45 α2 γ | {z } {z } | u3 v3  αβ 4β 16 β 2 27 α − 128 β 2 x + xy + xz − yz Fz = u3 Fx + v3 Fy + w3 Fz . 90 α2 γ 2 5 γ2 αγ 9 α2 γ | {z }  4 3 w3 (The u, v, w’s introduced above will be revisited in Example 1.16). The first two relations are visible, while the third one requires a calculation (it will be readily available with [14] by letting α, β, γ be honest indeterminates). It remains to prove that x2 y 4 ∈ / I. For this we resort to [14]: a Gröbner basis computation shows 2 4 that x y is not a multiple of any monomial in the initial ideal of I. Thus, I is not saturated. (ii) We now show that the condition indeg(I sat /I) ≥ 6 holds. Write J := hI, x2 y 4 i. We have shown that J ⊂ I : hx, y, zi ⊂ I : hx, y, zi∞ = I sat . It now suffices to show that J is saturated, i.e., perfect. But one can read (1) as syzygies of J; moreover, it is immediately checked that the top 3 × 3 minor of the matrix of these syzygies gives y 2 x4 (up to nonzero scalars). From this it becomes apparent that J is perfect with minimal resolution of shape 0 → R(−7)3 −→ R(−5)3 ⊕ R(−6) −→ J → 0. It follows that I sat = J and indeg(I sat /I) = 6. (iii) To show the inequality Z(I) ∩ I sat R3 6= K(I) we can apply Proposition 1.9 by arguing that I is not a complete intersection locally at its unique minimal prime (x, y); alternatively, one can apply [20], or [22, Section 1.3] by showing that F is not weighted homogeneous locally at (x, y) which is quite immediate here. In addition, since I is not saturated and since it is generated in degree 5 it follows from Lemma 1.1 that the initial standard degree of the syzygies is 3 and the minimal number of syzygy generators is 3. From [11, Proposition 1.6 (i)] the minimal free resolution of I must be of the form 0 → R(−9) −→ R(−8)3 −→ R(−5)3 −→ I → 0. (Note that this resolution has identical Betti numbers as the one in Example 1.5. However, I is not of linear type as it was the case in loc. cit.) Thus, we are in total control of the homological nature of I and I sat . To show the inequality Z(I) ∩ I sat R3 6= K(I) in this variant it suffices to show that I is not a syzygetic ideal, i.e., the torsion δ(I) of the first Koszul homology module of I does not vanish. It is possible to show that δ(I) is cyclic generated by the residue of a syzygy of standard degree 7, hence yielding a Rees equation of I of bidegree (2, 2) not coming from the equations of the symmetric algebra of I. A remnant problem is: Question 1.12. Let f ⊂ K[x, y, z] denote a reduced Eulerian free divisor such that its gradient ideal Jf is syzygetic. When is Jf of linear type? 8 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU The question asks for such divisor for which the (Rees) equations not coming from the equations of the symmetric algebra of Jf have degree ≥ 3. At present we cannot pull out an example failing for this implication. 1.3. When I sat /I is the socle. By definition, the socle of R/I is I : hx, y, xi/I. Thus, I sat /I coincides with the socle if and only st(I) = 1. Before we proceed discussing this interesting case, we analyze a special type of ideals. 1.3.1. Ideals of Cramer type. Let R be a commutative ring, n ≥ 1 an integer and φ : Rn → Rn an R-homomorphism of well-defined rank n – that is, g := det(φ) is a nonzerodivisor on R. Given an element u ∈ Rn (target) there is a unique t ∈ Rn (source) such that φ(t) = u. Using matrix notation, letting ψ := [u | φ] : Rn+1 → Rn denote the augmented map induced by u, by Cramer the coordinates of t in the canonical basis of the source, over the total quotient ring of R, are the n-minors of ψ fixing the column u divided by g. It is suggestive to call the ideal of I ⊂ R generated by these minors {∆1 , . . . , ∆n } an ideal of Cramer type associated to the fixed column u. We may call g the companion minor of I. Further, “repeating” a row of ψ gives an (n + 1) × (n + 1) matrix with null determinant. This implies that the rows of ψ are syzygies of the Fitting ideal In (ψ) = hI, gi. If further R is Noetherian and In (ψ) has grade ≥ 2, then one direction of the Hilbert–Burch theorem says that ψt 0 → Rn −→ Rn+1 −→ In (ψ) → 0 is a free resolution. Here is one environment for Cramer ideals, based on a property of contents of ideals: Proposition 1.13. Let R be a Noetherian ring. Let I = hf1 , . . . , fn i ⊂ R and U = hu1 , . . . , un i ⊂ R be ideals, with I of grade ≥ 2. Let g ∈ (I : U ) and write (2) gu1 = a11 f1 + · · · a1n fn .. . gun = an1 f1 + · · · ann fn If the n-minors of the content matrix (3)  u1 a11 · · ·  .. .. .. Mg :=  . . . un an1 · · ·  a1n ..  .  ann generate an ideal of grade ≥ 2, then I is a Cramer ideal associated to the fixed column u := (u1 , . . . , un )t with companion g. Conversely, if I is a Cramer ideal associated to the fixed column u := (u1 , . . . , un )t with companion g then hI, gi ⊂ I : U where U is the ideal of R generated by {u1 , . . . , un } and the n-minors of the resulting extended content matrix generate an ideal of grade ≥ 2. Proof. By an earlier observation, the ideal In (Mg ) has a free resolution Mg 0 → Rn −→ Rn+1 −→ In (Mg ) → 0. Since In (Mg ) has grade at least 2, dualizing into R yields an exact sequence ρ ∗ (Mg )t 0 → R −→ Rn+1 −→ Rn∗ , where the coordinates of a matrix of ρ are the signed n-minors of Mg . On the other hand, the equations (2) show that (Mg )t is a matrix of syzygies of {−g, f1 , . . . , fn }. We can harmlessly HOMOLOGY OF HOMOGENEOUS DIVISORS 9 assume that this matrix is a submatrix of a full syzygy (n + 1) × p matrix N of the latter elements. Pick the corresponding presentation of the ideal J := h−g, f1 , . . . , fn i and dualize into R to get an exact sequence σ ∗ Nt 0 → R −→ Rn+1 −→ Rp∗ , where the coordinates of σ are the generators of J since this ideal has grade ≥ 2. On the other hand, the coordinates of σ are, up to signs and ordering, the n-minors of any n × (n + 1) submatrix of N t of (maximal) rank 2. Since (Mg )t sits as one of these, its n-minors must be, up to order and signs, coincide with a set of generators of J. This shows the first contention. The converse statement is obvious.  Ideals of Cramer type have been considered before in a larger realm ([2, 12]), but mainly in the generic case – say, when R is a polynomial ring over a field and the entries of ψ are independent indeterminates. In this case, the homological properties are quite known. For example, by [2, Theorem C] one has SR (I) = R(I), so I is of linear type, and these algebras are Cohen-Macaulay normal domains. In the non-generic case, the linear type question doesn’t have a precise answer. We’ll see later in this subsection that the gradient ideals considered in Example 1.5 and Proposition 1.11 are Cramer type ideals, yet the first one is of linear type and the second one is not. Under extra conditions, [2, Theorem D] gives a free resolution of I in the non-generic case, based upon the well-known Eagon-Northcott complex. Here is one version in the case where dim R = 3: Proposition 1.14. Let (R, m) be a Cohen-Macaulay local ring, and let I ⊂ m be as above. Then the following are equivalent: (1) The codimension of the ideal of R generated by the coordinates of u is 3 and I3 (ψ) has codimension 2. (2) I has a free resolution of the form 0 → R → R3 → R3 → I → 0. We are now driven to apply the above general ideas in the case of an ideal I = hf1 , f2 , f3 i ⊂ R = K[x, y, z] of codimension 2, minimally generated by three forms of degree d ≥ 2. Our basic assumption is that I has saturation exponent 1, i.e., that I sat = I : hx, y, xi. We harmlessly assume that gcd(fi , fj ) = 1, i 6= j. In this case, the content matrix (3) is of the form   x a1 b1 c1 (4) Mg :=  y a2 b2 c2  , z a3 b3 c3 where the a’s,b’s and c’s are forms of the same degree s ≥ 0. Fixing the set of generators of I, for given g the matrix Mg is not unique; however, any two such matrices are such that their respective transposes differ by a 3 × 3 matrix of syzygies of the given set of generators of I. All the same, we will say that the ideal I satisfies the generic saturation condition (short: GSC) if there exists a homogeneous element g ∈ I sat \ I for which codim(I3 (Mg )) = 2 (maximum possible). We will also refer to such an element g as a saturation pivot. We collect additional properties of such ideals in the following Theorem 1.15. Let I ⊂ R = K[x, y, z] be an ideal of codimension 2, minimally generated by three forms of degree d ≥ 2. If I has saturation exponent 1 and satisfies condition GSC, with saturation pivot g, then (i) I is a Cramer ideal with fixed column (x, y, z)t and companion g of degree d − 1 + s for some s ≥ 1. 10 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU I sat = hI, gi. d is an odd integer. deg(g) = 32 (d − 1) and indeg(I sat /I) ≥ d + 1 if and only if d ≥ 5. The minimal graded free resolution of R/I has the form  3d + 1    3 → R3 (−d) → R. 0 → R − (d + 1) → R3 − 2 2 Conversely, if I is a non-saturated Cramer ideal with fixed column (x, y, z)t and companion g then I has saturation exponent 1 and satisfies condition GSC, with saturation pivot g. (ii) (iii) (iv) (v) Proof. The assertion of (i) follows from Proposition 1.13. Here s is the common degree of the entries of the matrix   a1 b1 c1 (5) G :=  a2 b2 c2  , a3 b3 c3 which is ≥ 1 since g is not a scalar. To prove (ii), let J := hI, gi. By the proof of Proposition 1.13, J coincides with the ideal of n-minors of the content matrix Mg . Since the latter is saturated and contained in I sat , then it must be the case that they coincide. This proves (ii). To prove (iii), note that up to a nonzero scalar, g coincides with the determinant of the matrix G in (5). It follows that deg(g) = 3s, where s is the degree of the entries of G. On the other hand, we have seen that deg(g) = d − 1 + s. Therefore d = 2s + 1 is odd. Then the value of deg(g) in (iv) follows immediately and it is easy to see that deg(g) ≤ d if and only if d ≤ 3. Since I sat = hI, gi by (b), it is clear that indeg(I sat /I) = deg(g) ≥ d + 1 if and only if d ≥ 5. Finally, (v) follows from Proposition 1.14 by reading the twists off the resolution in [2] in the graded case. Alternatively, one could proceed as in the proof of [11, Theorem 2.14. (iii)], working from the minimal graded resolution of R/hI, gi:  3   3d − 1  M g −→ R3 (−d) ⊕ R − (d − 1) → R. 0 → R3 − 2 2 For the converse statement, by Proposition 1.13 we have g ∈ I : hx, y, xi and the n-minors of the extended content matrix Mg generate an ideal of codimension 2. Claim: g 6∈ I. To see this, suppose otherwise, letting g = αf1 + βf2 + γf3 . Plugging g into the equations above one obtains three syzygies of degree s = deg(g) + 1 − d = (d − 1)/2 of f1 , f2 , f3 :       a1 − xα a2 − yα a3 − zα  b1 − xβ  ,  b2 − yβ  and  b3 − zβ  . c1 − xγ c2 − yγ c3 − zγ Since we are assuming that I is not saturated and since s + s = d − 1, from Lemma 1.1 we must conclude that there is at most one minimal generating syzygy (A, B, C) of degree ≤ d − 1, hence the three above syzygies are multiple of this syzygy. Letting hi , i = 1, 2, 3 denote the respective corresponding multiplying factors, one finds   h1 A + xα h1 B + xβ h1 C + xγ g = det  h2 A + yα h2 B + yβ h2 C + yγ  = 0. h3 A + zα h3 B + zβ h3 C + zγ HOMOLOGY OF HOMOGENEOUS DIVISORS 11 This contradicts the hypothesis g 6= 0 (included in the definition of a Cramer ideal). This proves the claim. Now, since g ∈ I : hx, y, xi ⊂ I sat then hI, gi ⊂ I sat . Since hI, gi = In (Mg ) is unmixed, the equality hI, gi = I sat must be the case. It follows that I has satiety 1 and satisfies GSC with pivot g.  Example 1.16. Let us look back at Proposition 1.11, setting f1 = Fx , f2 = Fx + Fy , f3 = Fx + Fz – these are minimal generators of I such that gcd(fi , fj ) = 1, i 6= j. Then I is a Cramer ideal with associated fixed column (x, y, z)t and companion   −v1 − w1 v1 w1 −w2 0 w2  , g := −30 γ 2 det  u3 − v3 − w3 v3 w3 where ui , vj , wk are the polynomials considered in Proposition 1.11. 2. H OMOGENEOUS FREE DIVISORS AND THE LINEAR TYPE PROPERTY In the previous section we studied several homological properties of almost complete intersection ideals of codimension 2 in K[x, y, z]. As already suggested in that section, these results can be applied to the case when the ideal is the gradient ideal of a plane (projective or not) non-smooth divisor with defining polynomial being squarefree. In this respect, the role of the symmetric and Rees algebras of the gradient ideal of an affine or homogeneous divisor establishes itself naturally through the notion of Koszul freeness. Another natural carrier to introduce these algebras, in contrast to the classical situation of completely reducible divisors, the linear type property of gradient ideals is not satisfied in general. 2.1. Irreducible homogeneous divisors. Our knowledge of irreducible divisors in Pn is at present very poor. From what we could gather thus far, they seem to appear in isolated packets or special families. In contrast to the case of divisors that, by definition, inherit natural combinatorial features – such as divisors which are union of lines (and conics, see [22]) – they leave not much choice but to resort to the ideal theoretic and homological tool. 2.1.1. Irreducible divisors in P2 . We start with some elementary information on irreducible homogeneous divisors. 2.1.2. Degree ≤ 4. Proposition 2.1. Let K denote an algebraically closed field. An irreducible homogeneous f ∈ K[x, y, z] of degree at most 3 is a free divisor if and only if deg(f ) = 1. Proof. If deg(f ) = 1 with f = ax + by + cz , say, a 6= 0, then clearly it is smooth. An explicit determinantal form is  √  √ x −b/ √ a −c/ a , a f = det  y √0 a z 0 hence f is a free divisor – note that it suffices to assume that K is closed under arbitrary square roots. If deg(f ) = 2 and f is irreducible then Proj(K[x, y, z]/(f )) is smooth, hence the gradient ideal is a codimension 3 complete intersection (of linear forms). Therefore, f is not a free divisor. If deg(f ) = 3 and f is irreducible, again either Proj(K[x, y, z]/(f )) is smooth, hence the gradient ideal is a codimension 3 complete intersection (of quadrics), or else it has a cusp or a node singularity. If m = hx, y, xi and Jf is the corresponding gradient ideal, then xym ⊂ Jf while xy 6∈ Jf 12 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU in the cusp case, and with a little more effort xzm ⊂ Jf while xz 6∈ Jf in the node case. Therefore in any case, depthR/Jf = 0 hence Jf is not perfect.  Now assume that deg(f ) = 4, with f irreducible. If f is moreover rational then, based on [32], a classification of the corresponding families with fixed singular type has been given in [17] and it has been proved that the general member has a gradient ideal of linear type. Sweeping through the general member of each of these families with the help of a computer program (Macaulay) one can show that the corresponding gradient ideal has homological dimension 2 over R = K[x, y, z]. For irreducible quartics of higher genus a classification is roughly given in [16]. Based on this classification, a second run with Macaulay shows that the corresponding gradient ideal has homological dimension 2 over R = K[x, y, z]. Thus, it would seem that morally no irreducible homogeneous quartic is a free divisor. In [25] an example was given of a family of irreducible homogeneous free divisors of degree 6 in K[x, y, z] – a so-called family of Cayley sextics. This example is special in that quite some structure comes with the territory. 2.1.3. Degree ≥ 5. We now discuss a particular family of irreducible free divisors in P2 of any given degree ≥ 5. Proposition 2.2. Let F = y d−1 z + a1 xd + a2 x2 y d−2 + a3 xy d−1 + a4 y d ∈ K[x, y, z], with d ≥ 5 and a1 , a2 6= 0. Then: (1) V (F ) is an irreducible free divisor for any d ≥ 5. (2) JF is of linear type if and only if d = 5. Proof. First note that any member of the family with a1 6= 0 is an irreducible polynomial in K[x, y, z]. This is because on the affine piece z = 1 the resulting polynomial is the sum of two polynomials of successive degrees d − 1 and d with no common factor. The partial derivatives of F are: Fx = (d − 1)a1 xd−1 + 2a2 xy d−2 + a3 y d−1   Fy = (d − 2)a2 x2 + (d − 1)(a3 x + z)y + da4 y 2 y d−3 Fz = y d−1 . There is an obvious syzygy (0, −y 2 , (d − 2)a2 x2 + (d − 1)(a3 x + z)y + da4 y 2 )t . Some slightly painful but straightforward calculation yields: (d − 2)a2 y d−3 Fx − da1 xd−3 Fy a3 xd−2 y d−2 xd−3 y d−2 z = p(x, y)Fz − d(d − 1)a1 a3 xd−2 y d−2 − d(d − 1)a1 xd−3 y d−2 z a3 xd−4 yFy − q(x, y, z)y d−1 = (d − 2)a2 1 = xd−5 yzFy − r(x, y, z)y d−1 , (d − 2)a2 where p(x, y) is a homogeneous polynomial of degree d − 3 in the variables x, y, while q(x, y, z) and r(x, y, z) are homogeneous polynomials of degree d − 3 in K[x, y, z], with q(x, y, z) ∈ hx, yiK[x, y, z]. Moreover, xd−4 z (respectively, xd−5 z 2 ) is the only monomial in q (respectively, r) for this power of z. Since y d−1 = Fz , the above relations imply a syzygy of the shape t  (d − 2)a2 y d−3 , −da1 xd−3 + · · · , · · · + (d − 1)xd−5 z 2 HOMOLOGY OF HOMOGENEOUS DIVISORS 13 which is a syzygy of degree d − 3. Note that 2 + (d − 3) = d − 1. Therefore, to show that V (F ) is a free divisor it suffices, by Lemma 1.1, to argue that these syzygies cannot be both multiple of one same minimal syzygy. But this is clear by the nature of the first coordinate of each of them. Finally, again from the shape of the two generating syzygies, it is clear that their entries generate an hx, y, zi−primary ideal if and only if d = 5. Proposition 1.6 then implies the second part of the statement.  2.2. Weighted homogeneous divisors and their homogenization. Let f ∈ R := K[x1 , . . . , xn ] be an arbitrary polynomial. A natural question is to inquiry into what homological properties of the gradient ideal Jf of f are, so to say, inherited by the gradient ideal JF of the homogenization F ∈ R[t] of f with respect to a new variable t. 2.2.1. Recap of weighted homogeneous polynomials. We will assume throughout that f is not homogeneous in the standard grading of R, as otherwise the question is vacuous. Definition 2.3. A polynomial f ∈ R := K[x1 , . . . , xn ] is called weighted homogeneous (or quasi homogeneous) if there exist positive rational numbers 0 < a1 , . . . , an ≤ 12 (called rational weights) such that f (sa1 x1 , . . . , san xn ) = sf (x1 , . . . , xn ) where s is an indeterminate over R. Taking the partial derivative with respect to s and using the chain rule yields n X ai sai −1 xi fxi (sa1 x1 , . . . , san an ) = f (x1 , . . . , xn ). i=1 Evaluating at s = 1 gives f = a1 x 1 f x 1 + · · · + an x n f x n . Conversely, let f ∈ R be such that there exist positive rational numbers 0 < a1 , . . . , an ≤ f = a1 x1 fx1 + · · · + an xn fxn . Then by mapping xi 7→ sai xi , one obtains f (sa1 x1 , . . . , san xn ) = s 1 2 with ∂ (f (sa1 x1 , . . . , san xn )). ∂s This is possible only when f (sa1 x1 , . . . , san xn ) = sC(x1 , . . . , xn ), for some C(x1 , . . . , xn ) ∈ R. Evaluating at s = 1, yields C(x1 , . . . , xn ) = f (x1 , . . . , xn ). So f is a weighted homogeneous polynomial of rational weights a1 , . . . , an . Instead of using rational weights it is common to use integer weights w1 , . . . , wn ≥ 1 with gcd = 1, in which case there exists a positive integer λ such that f (sw1 x1 , . . . , swn xn ) = sλ f (x1 , . . . , xn ) and λf = w1 x1 fx1 + · · · + wn xn fxn . The rational weights in the first form are then ai := wλi , i = 1, . . . , n. The following is a key lemma in our analysis: Lemma 2.4. Let f ∈ R be a weighted homogeneous polynomial of (standard) degree d and rational weights a1 , . . . , an . Let F ∈ R[t] be the homogenization of f with respect to a new variable t. Then the partial derivatives of F admit the following linear syzygy (da1 − 1)x1 Fx1 + · · · + (dan − 1)xn Fxn − tFt = 0. 14 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU Proof. Dehomogenizing the Euler relation d F = x1 Fx1 + · · · + xn Fxn + tFt via t → 1 gives d f = x1 fx1 + · · · + xn fxn + Fet , where F̃t denotes the dehomogenization of Ft . Using the assumption f = a1 x1 fx1 + · · · + an xn fxn yields (da1 − 1)x1 fx1 + · · · + (dan − 1)xn fxn − Fet = 0. (6) On the other hand, writing f = h1 + · · · + hd , where hi ∈ R is homogeneous of degree i, one has F = h1 td−1 + · · · + hd−1 t + hd . Then, (6) implies the following relations (da1 − 1)x1 (h1 )x1 + · · · + (dan − 1)xn (h1 )xn = (d − 1)h1 (da1 − 1)x1 (h2 )x1 + · · · + (dan − 1)xn (h2 )xn = (d − 2)h2 .. . (da1 − 1)x1 (hd−1 )x1 + · · · + (dan − 1)xn (hd−1 )xn = hd−1 (da1 − 1)x1 (hd )x1 + · · · + (dan − 1)xn (hd )xn = 0. Multiplying each of these equations by a suitable power of t and adding up the resulting relations yields (da1 − 1)x1 Fx1 + · · · + (dan − 1)xn Fxn − tFt = 0,  as was to be shown. 2.2.2. Homogenization of binary weighted homogeneous polynomials. We have the following immediate characterization of weighted homogenous polynomials in two variables, with positive integral weights. Proposition 2.5. The weighted homogeneous polynomials in K[x, y] with positive integral weights form a family with typical member of the form X f = cx xsq + cy y sp + cr x(s−r)q y rp , 1≤r<s for a triple (p, q, s), with p, q, s ∈ N>0 , such that gcd(p, q) = 1 and, moreover, weights pe, qe, with e ≥ 1 arbitrarily chosen. Proof. The proof follows immediately from the definitions.  Furthermore, note the following additional attributes of a binary weighted homogeneous polynomials: • Homogeneous: case p = q = 1 • Irreducibility: at least both cx 6= 0, cy 6= 0 • Partial irreducibility: neither x nor y is a factor of f if and only if at least one of the rational weights is 1/ deg(f ) (standard degree) • Smoothness at (0, 0): irreducible plus sq = 1 or sp = 1 (i.e., s = 1 and either p = 1 or q = 1). For the case of divisors on P2 obtained by homogenization of weighted homogeneous polynomials in two variables, we obtain a complete homological characterization as follows. Theorem 2.6. Let f ∈ R := K[x, y] be a (non-homogeneous) weighted homogeneous polynomial of degree d ≥ 3, with f = axfx + byfy , a, b > 0. Let F ∈ S := R[z] be the homogenization of f with respect to a new variable z. Then HOMOLOGY OF HOMOGENEOUS DIVISORS (1) If a 6= 1 d 15 and b 6= 1d , then JF is perfect of linear type with graded minimal free resolution: 0 → S(−(2d − 3)) ⊕ S(−d) → S 3 (−(d − 1)) → JF → 0. (2) If a = 1d or b = d1 , then JF is an ideal of linear type, but it is not perfect. In this case, JF has a graded minimal free resolution: 0 → S(−(2d − 1))→S(−d) ⊕ S(−2(d − 1))2 →S(−(d − 1))3 →JF → 0. Proof. (1) By Lemma 2.4, ((da − 1)x, (db − 1)y, −z) is a syzygy on JF . Clearly, its coordinates form a regular sequence of length 3. Therefore, the desired result follows from Proposition 1.8. (2) Since the data are symmetric, we may assume that a = 1/d (then b 6= 1/d, as we are assuming that f is not homogeneous in the standard grading of R). Then xd−1 occurs as a pure power in Fx . Also, Lemma 2.4 gives (db − 1)yFy = zFz . Denote z := (0, (db − 1)y, −z)t the corresponding linear syzygy. I1 (φ) contains y, z, where φ denotes a minimal graded presentation matrix of JF . On the other hand, Fx contains a nonzero pure power in x, while its remaining terms belong to the ideal hy, zi. Because of any of the Koszul syzygies involving Fx this forces I1 (φ) to be hx, y, zi-primary. But, since JF is an almost complete intersection, by Proposition 1.6, this implies that JF is of linear type. To prove the second part we argue in the following way. If F is free then we have that z = (0, (db− 1)y, −z)t and (A, B, C)t basis for the syzygies module of JF , for some syzygy (A, B, C): as deg(F ) ≥ 3, we have that z is the only linear syzygy so it must be a part of the basis. Since (db − 1)yFy = zFz , then Fy = zH, Fz = (db − 1)yH, for some H ∈ S. The 2 × 2 minors of the matrix of the two syzygies will give linear combinations of Fx , Fy , Fz . So Fx ∈ hy, zi. Contradiction. Consider the two Koszul syzygies z12 := (Fy , −Fx , 0)t and z13 := (Fz , 0, −Fx )t . Clearly, z, z12 , z13 form a minimal set of generators of the S-submodule of S 3 that they generate. A direct calculation shows that the vector (Fx , −z, (db−1)y)t is a syzygy of the set {z, z12 , z13 }. This way one has a complex of R-modules ψ2 ψ1 ψ0 0 → S(−(2d − 1)) → S(−d) ⊕ S(−2(d − 1))2 → S(−(d − 1))3 → S, where Im(ψ2 ) = (Fx , βz, αy)t , Im(ψ1 ) = Sz + Sz12 + Sz13 and Im(Fx , Fy , Fz ). To see that it is a resolution of its cokernel JF , we apply the well-known acyclicity criterion as formulated in [10, Theorem 20.9]. The ranks of the maps clearly add up right. Thus, it suffices to check the heights of the appropriate Fitting ideals. Since Fx contains a nonzero pure power in x, while its remaining terms belong to the ideal hy, zi, then the height of I1 (ψ2 ) is 3. As to ψ1 , it has the 2-minor Fx2 which has a non-vanishing pure power term in x, while it has another 2-minor belonging to the ideal hy, zi. The two cannot have a proper common factor, hence I2 (ψ1 ) has height at least 2.  It may be of some convenience to state the theorem in terms of free divisors and the partial reducibility attribute mentioned earlier: 16 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU Corollary 2.7. Let f ∈ R := K[x, y] stand for a weighted homogeneous polynomial of degree d ≥ 3, with positive rational weights a, b and let F ∈ R[z] denote its homogenization. Then F is a free divisor if and only if either f is (standard) homogenous or else f is divisible by x or by y. 2.2.3. Coneing. From the previous section we have seen that the homogenization of a weighted homogeneous polynomial in two variables leads to divisors of linear type, but most of the time not free (e.g., if f is irreducible). So freeness is not preserved under homogenization in this low dimension. Actually, by and large, homogenization is perhaps not the right operation to look at. An alternative operation, enjoying good properties at least for divisors which are hyperplane arrangements, is coneing. Let f ∈ R := K[x1 , . . . , xn ] be a polynomial, which is not homogeneous. Let F ∈ R[t] be the homogenization of f with respect to a new variable t. Then the cone over f is the homogeneous polynomial cone(f ) := tF ∈ R[t]. As a consequence to Lemma 2.4, we have the following result. Proposition 2.8. Let f ∈ R be a weighted homogeneous polynomial of degree d and with rational weights a1 , . . . , an . Denote by G := cone(f ) ∈ R[t], the cone over f . Let F = Gt . If the ideal IF = hFx1 , . . . , Fxn i is a perfect ideal of codimension 2, then the gradient ideal JG of G is perfect. Proof. Let F be the homogenization of f with respect to the variable t. Then G = tF . The partial derivatives of G are Gx1 = tFx1 , . . . , Gxn = tFxn , Gt = F + Ft . Because dF = x1 Fx1 + · · · + xn Fxn + tFt , and from the linear syzygy obtained in Lemma 2.4, one gets that Gt = (da1 + a1 − 1)x1 Fx1 + · · · + (dan + an − 1)xn Fxn . IF is a perfect ideal of codimension 2, so let  h1,1 · · ·  ..  . h1,n−1    hn,1 · · · hn,n−1 h1,n−1 (da1 + a1 − 1)x1 .. . (dan + an − 1)xn be the n × (n − 1) matrix whose (signed, ordered) (n − 1)-minors are {Fx1 , . . . , Fxn }. Then the partial derivatives of G are the (signed) n-minors of the (n + 1) × n matrix      h1,1 · · · .. . hn,1 · · · 0 ··· hn,n−1 0 t       Question 2.9. If f ∈ R is a weighted homogeneous polynomial such that V (f ) is a free non-smooth reduced divisor, is it true that the ideal IF occurring in Proposition 2.8 is perfect of codimension 2? If f is in two variables, the answer is yes, as we can see immediately at the beginning of the proof of the next result. Corollary 2.10. Let f ∈ R := K[x, y] be a weighted homogeneous polynomial of degree d ≥ 3, with rational weights a, b. Suppose V (f ) ⊂ A2 is a reduced non-smooth divisor. Denoting G = HOMOLOGY OF HOMOGENEOUS DIVISORS 17 cone(f ) ∈ S := R[z], then JG is a codimension 2 perfect ideal of linear type with graded minimal free resolution 0 → S(−(d + 1)) ⊕ S(−(2d − 1)) → S(−d)3 → JG → 0. Proof. Let F = Gz be the homogenization of f . From Proposition 2.8, it is enough to prove that codim(hFx , Fy i) = 2 (so IF is a complete intersection), which is equivalent to show that Fx and Fy do not have a common factor. If Fx and Fy have a common factor that is not a pure power of z, then by dehomogenization, fx and fy will have a non-constant common factor, contradicting codim(hfx , fy i) = 2. If Fx and Fy have a common factor that is a pure power of z, say z u , u ≥ 1, then by dehomogenizing, deg(fx ) ≤ d − 1 − u and deg(fy ) ≤ d − 1 − u, contradicting the fact that deg(f ) = d, and hence at least one of its partial derivatives must have degree equal to d − 1. We have that Gx = zFx , Gy = zFy , Gz = F + zFz . Using the Euler relation dF = xFx + yFy + zFz , and the syzygy (da− 1)xFx + (db− 1)yFy = zFz from Lemma 2.4, we obtain Gz = (d(a + 1) − 1)xFx + (d(b + 1) − 1)yFy . Multiplying this by z, and since d(a + 1) − 1 6= 0 and d(b + 1) − 1 6= 0 (otherwise a < 0 or b < 0), we obtain the syzygy (d(a + 1) − 1)x, (d(b + 1) − 1)y, −z), of Gx , Gy , Gz . The entries in this syzygy form a regular sequence of length 3, and therefore the conclusion of the theorem is shown.  2.3. New and old examples. 2.3.1. Adding free homogeneous divisors to irreducible homogeneous divisors. A natural question is whether given any irreducible homogeneous polynomial g ∈ R := K[x1 , . . . , xn ] (n ≥ 3) there exists a suitable reduced homogeneous free divisor h ∈ R such that f := gh is a free divisor. Next question would ask what is the minimal number of irreducible components such an h should have. Of course, in the best of the cases one would hope to accomplish this with h itself irreducible. The following propositions give a sense of how this addition problem works. We assume that n ≥ 3 throughout this part. r n−1 Proposition 2.11. Let g = xr11 xr22 · · · xn−1 − xdn ∈ R, with r1 + · · · + rn−1 = d and ri 6= 0 for i = 2, . . . , n − 1, and let h := xi1 · · · xin−2 , where {i1 , . . . , in−2 } ⊂ {1, . . . , n − 1}. Then (i) g is a nonfree divisor. (ii) f := gh is a free divisor of linear type. Proof. (i) To prove that g is not a free divisor, we use the following general obvious C LAIM . Let I ⊂ R be a codimension 2 ideal generated by at least three independent forms of the same degree ≥ 2. If some Koszul relation among these forms is a minimal syzygy generator then I is not perfect. To apply in our case, note that by the shape of g, the partial derivative gxn is a pure power of xn while none of the others involves xn . Then xn is a nonzerodivisor modulo the latter, hence at least one Koszul relation involving xn is a minimal syzygy generator. (ii) Without loss of generality we assume that {i1 , . . . , in−2 } = {1, . . . , n − 2}. One then has r n−2 f = xr11 +1 xr22 +1 · · · xn−2 +1 rn−1 xn−1 − x1 x2 · · · xn−2 xdn , 18 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU from which we see that +1 rn−1 xn−1 rn−2 +1 rn−1 xn−2 xn−1 r n−2 fx1 = (r1 + 1)xr11 xr22 +1 · · · xn−2 − x2 · · · xn−2 xdn fx2 = (r2 + 1)xr11 +1 xr22 xr33 +1 · · · − x1 x3 · · · xn−2 xdn .. . rn−3 +1 rn−2 rn−1 r1 +1 r2 +1 fxn−2 = (rn−2 + 1)x1 x2 · · · xn−3 xn−2 xn−1 − x1 x2 · · · xn−3 xdn r n−3 fxn−1 = rn−1 x1r1 +1 xr22 +1 · · · xn−3 +1 rn−2 +1 rn−1 −1 xn−2 xn−1 fxn = d x1 x2 · · · xn−2 xd−1 n From the last two partial derivatives, which are monomials, we get a reduced Koszul relation of degree d − 1. Suppose we have found n − 2 additional minimal syzygies which are linear. Then we argue as in the proof of Lemma 1.1 ((ii) ⇒ (iii)) by dualizing this partial matrix into R so that the (n − 1)-minors of the transpose divided by their gcd gives the partial derivatives. But since these minors have degree d− 1+ n − 2 = d+ n − 3 = deg(f )− 1, we conclude that the syzygies obtained so far already generate all syzygies, hence the gradient ideal is a (codimension 2) perfect ideal. Now, for any i ∈ {1, . . . , n − 2}, the following is a linear syzygy  1 t ri + 1 xn−1 , − xn , 0, . . . , 0, xi , 0, . . . , 0, − |{z} rn−1 d ith slot as one verifies straightforwardly. Because of the echelon positioning of the ith coordinate, these n − 2 syzygies are independent (hence, minimal) generators. To complete the proof, we argue about the linear type property. Since I is a codimension 2 perfect ideal, the Koszul homology modules of I are Cohen–Macaulay ([3]). Therefore, by [13, Theorem 9.1] it suffices to verify that µ(IP ) ≤ dim RP for every prime ideal P ⊃ I. This condition is equivalent to checking the so-called (F1 ) property of the Fitting ideals of the syzygy matrix of I:   x1  x2   ..  .  φ :=      c1 xn−1 c2 xn−1 · · · c′1 xn−1 c′2 xn−1 · · · xn−2 cn−2 xn−1 c′n−2 xn−1 cxd−1 n m      ,     where the empty slots have null entries, cj , c′j , c are suitable nonzero scalars and m denotes a suitable monomial. The property to be verified is that, for every 1 ≤ t ≤ n − 1, the codimension of the ideal It (φ) is at least n + 1 − t. Fix 1 ≤ t ≤ n − 1. Considering the main diagonal of the (n − 2) × (n − 2) upper left matrix, extended by the entry cxd−1 n , leads us to look at the ideal generated by the t-products of the regular sequence {x1 , . . . , xn−2 , cxd−1 n }, which is well-known to have codimension n − 1 − t + 1 = n − t. Thus, we only need an additional t-minor effectively involving the remaining variable xn−1 . But this is easily obtained using one of the last two rows of φ.  A sort of generalization of Proposition 2.11 is the following: Theorem 2.12. Let g = xdn − xm n−1 h ∈ K[x1 , . . . , xn ], d > m, with h ∈ K[x1 , . . . , xn−2 ] a reduced homogeneous polynomial of degree d − m ≥ 2. HOMOLOGY OF HOMOGENEOUS DIVISORS 19 (i) g is a nonfree divisor. (ii) If h is a free divisor then f := gh is a free divisor ; if, moreover, Jh is an ideal of linear type in K[x1 , . . . , xn−2 ] then Jf is of linear type. Proof. (i) Same argument as in proof of Proposition 2.11 (i) gives a minimal generating Koszul syzygy on the partial derivatives of g. From (the generalized version) Lemma 1.1, obviously g cannot be free. 2 (ii) By assumption, f = xdn h − xm n−1 h . A simple calculation gives 1 1 xn fxn + xn−1 fxn−1 . d m Using the Euler’s formula on f we obtain a linear syzygy f= 2d − m 2d − m )xn−1 , (1 − )xn )t . m d Since h is free there exists a basis of n − 3 syzygies on Jh with degrees adding up to d − m − 1. On the other hand, s0 = (x1 , . . . , xn−2 , (1 − (7) fxi = H hxi , H := (xdn − 2xm n−1 h), i = 1, . . . , n − 2, as one easily checks. Therefore, these syzygies extend to syzygies on Jf by adding two more entries equal to zero. Let s1 , . . . , sn−3 denote these syzygies. 2 d−1 Finally, as in the previous argument, since fxn−1 = −mxm−1 n−1 h , fxn = d xn h admit the common factor h, there is a syzygy of degree d − 1: m−1 t sn−2 = (0, . . . , 0, dxd−1 n , mxn−1 h) . So far, we have the following partial matrix of syzygies of Jf :  (8)   φh   φ :=     0 ···  0 ··· 0 0 x1 .. . xn−2 0 .. . 0 −2 (d−m) m xn−1 d xd−1 n − (d−m) d xn mxm−1 n−1 h      ,     where φh denotes the syzygy matrix of Jh . We claim that φ = φf . For it we use the same argument as before by embedding φ into φf and taking the transpose φtf . By the shape of the syzygies, φt has rank n − 1, hence its (n − 1)-minors divided by their gcd give the elements of Jf . But the degrees of s0 , s1 , . . . , sn−3 , sn−2 add up to 1 + (d − m − 1) + (d − 1) = 2d − m − 1 which is the degree of the generators of Jf Therefore, the gcd is 1, thus implying the minors already generate Jf . To prove the assertion about the linear type property, we now inspect the syzygy matrix φf of Jf , which we now know is given by (8). As explained earlier it suffices to show that for every 1 ≤ t ≤ n − 1, the codimension of the ideal It (φf ) is at least n − t + 1. But, this condition is also necessary, hence applying it to φh we get the inequalities (9) codim(It (φh )) ≥ n − 3 − t + 2 = n − t − 1, as ideals in the ring K[x1 , . . . , xn−2 ]. i = 1, . . . , n − 3, 20 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU Consider the following (n − 1) × (n − 2) submatrix of φf  x1  ..  φh .  ψ1 =  xn−2   0 ··· 0 cxn−1     .   Note that the upper (n − 2)-minor of ψ1 is just h (up to a nonzero scalar multiple) since the corresponding submatrix is the Saito matrix of h. Since, on the other hand, c 6= 0, one has In−2 (ψ1 ) = hxn−1 Jh , hi. Now any prime ideal containing In−2 (ψ1 ) must either contain hxn−1 , hi or else hJh , hi = Jh . Since Jh ⊂ k[x1 , . . . , xn−2 ], xn−1 is a nonzerodivisor on Jh , and since h is assumed to be reduced, Jh has codimension ≥ 2 (actually = 2). Therefore, In−2 (ψ1 ) has codimension 2. We can extend this result to any 1 ≤ t ≤ n − 2 as follows: (10) codim(It (ψ1 )) ≥ n − t in K[x1 , . . . , xn−2 , xn−1 ]. To see this, let p be a minimal prime over It (ψ1 ). We have xn−1 It−1 (φh ) ⊂ It (ψ1 ) ⊂ p. If xn−1 ∈ / p, then It−1 (φh ) ⊂ p, and therefore codim(p) ≥ (n − 2)+ 1− (t − 1) = n − t. If xn−1 ∈ p, since It (φh ) ⊂ It (ψ1 ), then hxn−1 , It (φh )i ⊂ p. But It (φh ) is an ideal in K[x1 , . . . , xn−2 ], of codimension ≥ n − t − 1. So codim(p) ≥ n − t in this case as well. This proves the claim. Now, for 1 ≤ t ≤ n − 1, consider the subideal of It (φf ) generated by the t-minors involving the lower right 2 × 2 submatrix of φf : ! d xd−1 −2 (d−m) n m xn−1 − (d−m) d xn mxm−1 n−1 h Note that its determinant is the factor H in (7). Thus, for t = n − 1, we are recovering the subideal as in (7). In general, this subideal is precisely H It−2 (φh ). One has for 1 ≤ t ≤ n − 2: It (ψ1 ) + H It−2 (φh ) ⊂ It (φf ). Let p be prime containing It (φf ). If H ∈ p then It (ψ1 ) + hHi ⊂ p; but H is a nonzerodivisor modulo It (ψ1 ) since it has a term which is a pure power in xn . Therefore, the codimension of p is ≥ n − t + 1, where we have used the estimate in (10). If, on the other hand, H ∈ / p, then It−2 (φh ) ⊂ p, hence the codimension of p is ≥ n − 3 − (t − 2) + 2 = n − t + 1 using (9). For t = n − 1 the result is clear.  Remark 2.13. It is not apparent what would be a common natural generalization of the above examples. Having g = xdn + g1 (x1 , . . . , xn−1 ) with g1 being a reduced free divisor of degree d, while taking h to be the product of a subset of the irreducible factors of g1 , will not work in general. For example, let n = 5 and g = x55 − g1 (x1 , . . . , x4 ), with g1 = x1 x2 (x1 + x2 )(x1 x4 + x2 x3 ). Then g1 is a free divisor of linear type (cf. Proposition 2.15), but adding to g a product of 3 of the irreducible factors of g1 will not result in a free divisor. Note that the second of the above constructions can start with irreducible divisors g, h, with h free. Of course, iterating the above procedure by adding more variables gives other (reducible) free divisors of quite arbitrary degrees. The simplest iterative example would initialize with h = x1 and g = x23 − x2 x1 . HOMOLOGY OF HOMOGENEOUS DIVISORS 21 2.3.2. Recap of Koszul free divisors. The notion of a Koszul free divisor was introduced in [4]. Its full properties and relationship to other notions have been carried in [5]. In [24] a different approach to this notion was introduced, retaining the original terminology. The first approach was given in terms of differential operators (ideal of “differential symbols”), whereas the version in [24] is more elementary while dealing directly with the symmetric algebra (“symmetric symbols”). Although the two notions were given in different contexts – one analytic, the other polynomial – a more thorough comparison would be welcome. In this work we will refer to the Koszul freeness according to the second approach, hoping no confusion is expected as our setup is always polynomial and not local analytic. According to the latter it follows that, in the (global) Eulerian situation, if the symmetric algebra of the gradient ideal is a Cohen–Macaulay ring then saying that the divisor is Koszul free is tantamount to freeness plus the Euler equation being a regular element modulo the defining equations of the symmetric algebra. This is why, in the Eulerian setup, it is fairly easy from the computational side to verify if a free divisor is Koszul free in the present sense (see [24, Proposition 3.11] for further details). Let us review the latter approach in brief. Let L be a free R-module of finite rank and let {e1 , . . . , ep } be a basis thereof. Then SR (L) = R[T1 , . . . , Tp ], a polynomial ring on variables T1 , . . . , Tp . Any element g ∈ L is of the form g = a1 e1 + · · · + ap ep , for some ai ∈ R. So one obtains g(1) := a1 T1 + · · · + ap Tp ∈ SR (L). More generally, any submodule Z ⊂ L induces, in this way, an ideal Z(1) generated by linear forms inside SR (L). Call Z(1) the polynomial idealization of the embedding Z ⊂ L. ∂ ∂ ∂ + β ∂y + γ ∂z is in In our setup, Z = DF and L = Der(R), with R = K[x, y, z]. If θ = α ∂x DF , then θ(F ) = PF F, for some PF ∈ R. Then we can write 1 1 1 ∂ ∂ ∂ 1 + (β − yPF ) + (γ − zPF ) + PF θE , θ = (α − xPF ) d d d | {z } ∂x | {z } ∂y | {z } ∂z d A B C where d = deg(F ) and θE denotes the Euler relation. Observe that (A, B, C) is a syzygy on (Fx , Fy , Fz ). With this DF (1) = hxT1 + yT2 + zT3 i + h{AT1 + BT2 + CT3 |AFx + BFy + CFz = 0}i is the polynomial idealization of the embedding DF ⊂ Der(R). Note that SR (JF /(F )) = SR (Der(R))/DF (1), thus redirecting the properties of the polynomial idealization to those of the symmetric algebra of the R-module JF /(F ) (an analogous result takes place for arbitrary divisors, replacing JF by the entire gradient ideal of F ). According to the definition in [24], in the present context of plane divisors, Y = V (F ) is a Koszul free divisor if Y is a free divisor and the polynomial idealization DF (1) ⊂ SR (Der(R)) has codimension 3. As stated in [24, Proposition 4.1], a free divisor on P2 is automatically Koszul free. Quite generally, if V (F ) is free and JF of linear type then V (F ) is Koszul free (cf. [24, Corollary 3.12] or [24, Proposition 4.1 and Remark 4.2] – but the precedence for this result is [5, Proposition 3.2]). The converse is not true, though finding such examples in the homogeneous case are not easily guessed. Let us change gears by revisiting a couple of known examples ([5, Example 1.11 and Example 6.2]) in the non-homogenous case that may help to clarify the theory. For convenience we state the relevant properties in the form of a proposition. Proposition 2.14. Let f = 256z 3 − 128x2 z 2 + 16x4 z + 144xy 2 z − 4x3 y 2 − 27y 4 ∈ R = C[x, y, z]. Then: 22 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU (i) f is a weighted homogenous Koszul free divisor with Euler equality 12f = 2xfx + 3yfy + 4zfz . (ii) The gradient ideal I ⊂ R of f is an ideal of linear type. (iii) Let F ∈ K[x, y, z, t] denote the homogenization of f relative to a new variable t. Then (a) V (F ) is a not a free divisor of P3 . (b) JF is of linear type. Proof. (i) By direct inspection, Jf is the ideal generated by the 2-minors of the following matrix   −3y x2 − 12z  x2 − 4z  3xy (11) 1/2xy 9/4y 2 − 4xz (The matrix itself was obtained with Macaulay ([14])). By [24, Proposition 4.1], V (f ) is Koszul free. By direct verification, it is clear that f is weighted homogeneous with weights 2, 3, 4 for x, y, z, respectively. This proves the form of the Euler relation. (ii) It is straightforward to see that the entries of the above matrix generate an hx, y, zi-primary ideal. Therefore, we conclude from Proposition 1.6. (iii) (a) To show that V (F ) is not a free divisor one could of course do a simple calculation with [14], however we choose to give a conceptual argument that may be used elsewhere. By Lemma 2.4, JF admits the linear syzygy (x, −3/2y, −4z, 6t)t . On the other hand, the leftmost syzygy of Jf in (14) gives by homogenization a syzygy of JF of degree 2 which is visibly not a multiple of the linear one. Clearly, JF cannot be generated the 2-minors of these two syzygies (either because it is 4-generated or by degree reason since deg(F ) = 5). Therefore, it admits at least one additional minimal syzygy independent of the first two. Showing that any of the additional ones has standard degree at least 2 will do it since the sum of the degrees of any 3 minimal syzygies would exceed the degree of the partial derivatives of F , which is 4. Equivalently, we show that JF has no additional minimal linear syzygies. To prove the latter claim, suppose that ℓx Fx + ℓy Fy + ℓz Fz + ℓt Ft = 0, with the ℓ’s linear forms in K[x, y, z, t]. Mapping t 7→ 1 gives the relation (12) ℓex fx + ℓey fy + ℓez fz = −ℓet Fet , where ˜ indicates the resulting polynomial in K[x, y, z]. On the other hand, dehomogenizing the Euler relation 5F = xFx + yFy + zFz + tFt yields (13) 5f = xfx + yfy + zfz + Fet . Using the weighted homogeneous Euler relation 12f = 2xfx + 3yfy + 4zfz and (13) furnishes Fet = (−5/6)xfx + (5/4)yfy + (10/3)zfz . Comparing with (12) leads to the relation (ℓex − (5/6)ℓet x)fx + (ℓey + (5/4)ℓet y)fy + (ℓez + (10/3)ℓet z)fz = 0. Since f is weighted homogeneous, so are its partial derivatives (of weighted degrees 10, 9, 8, respectively). Therefore the coefficients of the last relation must be weighted homogeneous as well. But since a polynomial of degree 1 can only be weighted homogeneous for distinct weights of the variables (as is the case here) if it is a k-multiple of a variable, a close scrutiny of the above coefficients shows that they are not weighted homogeneous unless they vanish. In this case, one gets the following equalities    ℓex = (5/6)ℓet x ℓey = −(5/4)ℓet y   ℓe = −(10/3)ℓe z z t HOMOLOGY OF HOMOGENEOUS DIVISORS 23 Since these are equalities of polynomials with standard degrees, we must have ℓet = α, for some α ∈ k. It follows that ℓet = αt, hence 6 (ℓx , ℓy , ℓz , ℓt )t = α (x, −3/2y, −4z, 6t)t , 5 showing that the assumed linear syzygy is a multiple of the linear syzygy already obtained. (b) To show that JF is an ideal of linear type, one uses that it is an ideal of deviation 2. For deviation 2 Cohen–Macaulay ideals in a Cohen–Macaulay ring, it is known that their Koszul homology modules are Cohen–Macaulay ([3]). Therefore, by [13, Theorem 9.1] it suffices to show that JF is locally at every prime ideal P generated by at most dim RP elements. This is obvious if P is the maximal homogeneous ideal of K[x, y, z, t]. If dim RP = 3, the linear syzygy of JF shows that (JF )P is generated by at most 3 elements. It remains to prove that JF is locally a complete intersection at its minimal primes. Now, the singular points of V (F ) in P2 are either those of V (f ) in A2 (t = 1) or else lie on the plane t = 0. A computation with [14] yields that the radical of Jf is generated by the polynomials x3 + 9/2y 2 − 4xz, y(x2 + 12z), xy 2 − 8/3x2 z + 32/3z 2 . Therefore, any minimal prime of Jf contains either y or x2 + 12z. From this one gets that the minimal primes are P := hx2 − 4z, yi and Q := hx2 + 12z, y 2 − 32/9xzi. Now, the entry x2 − 12z of the matrix (14) does not belong to P , hence locally at P the first partial derivative belongs to the ideal generated by the other two partial derivatives. Similarly, the entry −3y does not belong to Q, hence locally at Q the ideal Jf is again a complete intersection. It remains to check the minimal primes of JF that contain t. Another computation with [14] gives that the radical of JF is generated by the homogenized generators of Jf and the additional polynomial y 3 − 32/9xyz. It follows from this that t does not belong to any minimal prime of JF (i.e., V (F ) has no singularities at infinity). This finishes the proof.  Proposition 2.15. Let f = xy(x + y)(x + yz) ∈ R = C[x, y, z] and let Jf ⊂ R denote the ideal generated by its partial derivatives. Then: (i) f is a reduced free Eulerian divisor, but not quasihomogeneous in the sense of all weights positive – namely, one has f = 1/4xfx + 1/4yfy . (ii) Jf is not an ideal of linear type. (iii) The symmetric algebra SR (Jf ) is a complete intersection on which the Euler equation e is a zero-divisor – in particular, f is not Koszul free. (iv) Letting F ∈ R[t] denote the homogenization of f relative to a variable t, one has: (a) F is a free divisor of P3 , but not Koszul free. (b) The symmetric algebra of JF is a reduced Cohen–Macaulay ring, and JF is not syzygetic. (c) F is homaloidal. Proof. (i) The Euler-like expression of f is a direct calculation with the partial derivatives. To see that f is a free divisor we compute with [14], finding that the syzygy matrix of Jf is   xy x2 + 4xy   y2 −3xy (14) −4x − 4yz −8x + 4xz − 4yz (ii) As one easily checks, the ideal generated by the entries of the matrix is contained in hx, yi. Therefore, Jf is not of linear type. 24 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU (iii) The assertion about SR (Jf ) being a complete intersection is clear. By the same token as in (ii), hx, yiR[T, U, V ] is a minimal prime of the ideal hJ1 i of definition of SR (Jf ) over the polynomial ring R[T, U, V ]. Since the Euler relation read in degree one is e := 1/4(xT + yU ) ∈ hx, yiR[T, U, V ], it is a zerodivisor on SR (Jf ). (iv) Nearly everything in this item needs computer intervention, such as with [14]. A highlight is the structural matrix of JF :   0 x 0   0 y xy + y 2 ,    x 4z −3yz −y −4t −2yz − xt − 2yt where the linear syzygies are easily guessed without computer calculation, due to the particular shape of f and its “nearly” weighted homogeneous structure. For the first linear syzygy, note z and t have symmetric roles. In particular, one has ∂F/∂z = xy 2 (x + y) and ∂F/∂t = x2 y(x + y). The second syzygy is like the one obtained in Lemma 2.4, pretending that the Euler relation is a weighted homogenous relation. In item (b), reducedness and minimal primes are not easily seen without resorting to the computer. Therefore, nor is the lack of Koszul freeness. An additional feature is that, in analogy to the case of Jf , saturating the defining ideal of the symmetric algebra of JF by the (homogeneous) idealized Euler relation yields the defining ideal of the Rees algebra of JF . The latter again acquires an additional generator of bidegree (1, 2). Together with the two linear syzygies, it produces enough relations to conclude by [9, Theorem 2.18] that the weak Jacobian dual matrix has rank 3, and hence the rational map defined by the partial derivatives of JF is a Cremona map of P3 . This gives (c).  Remark 2.16. In part (iii) of the above one can be a lot more prolixious. Namely, writing SR (Jf )/(f ) ≃ SR (Der(R))/Df (1) ≃ R[T, U, V ]/D SR (Jf ) ≃ R[T, U, V ]/hJ1 i ։ RR (Jf ) ≃ R[T, U, V ]/J , one has hJ1 i = J ∩ D, D = hJ1 , ei and J = J1 : e = hJ1 , qi, for a suitable q ∈ / hJ1 i of degree 2 in T, U, V . In particular, Jf is not even syzygetic. Finally, RR (Jf ) is Cohen–Macaulay. The details of part (iv) are pretty much similar, except for the reducedness of the symmetric algebra – a matter of wondering. Clearly, f is here a fairly degenerated example, sharing a proper factor with one of its derivatives – something that cannot happen if f is irreducible. At the other end, homaloidal (homogeneous) polynomials are also quite rare, so one wonders if there is any bridge to freeness under suitable conditions. In the light of the above example, it seems natural to ask: Question 2.17. Let f ∈ R = k[x1 , . . . , xn ] be a reduced Eulerian divisor and let F ∈ R[t] denote its homogenization. If f is free (respectively, Koszul free), when is F free (respectively, Koszul free)? If one does not assume the Euler condition then there is a huge class of counter-examples. Namely, take a homogeneous irreducible F ∈ K[x1 , . . . , xn+1 ](n ≥ 2) whose associated projective hypersurface is smooth and let f ∈ K[x1 , . . . , xn ] denote one of its dehomogenizations. This is because the partial derivatives of F generate a complete intersection of codimension n + 1 ≥ 3. On the other hand, if the hypersurface defined by f is smooth but its projective closure has singular HOMOLOGY OF HOMOGENEOUS DIVISORS 25 points then the issue remains (see Proposition 2.2 where dehomogenization f at y = 1 is smooth but the projective closure has a singular point elsewhere – here we have an affirmative answer to the above question for such f ). R EFERENCES [1] M. Alberich-Carramiñana, Geometry of the Plane Cremona Maps, Lecture Notes in Mathematics, 1769, SpringerVerlag Berlin-Heidelberg, 2002. [2] J.F. Andrade and A. Simis, On ideals of minors fixing a submatrix, J. Algebra 102 (1986), 246–259. [3] L. Avramov and J. Herzog, The Koszul algebra of a codimension 2 embedding, Math. Z. 175 (1980), 249–280. [4] F.J. Calderón-Moreno, Logarithmic Differential Operators and Logarithmic De Rham Complexes Relative to a Free Divisor, Ann. Sci. E.N.S., 32 (1999), 577–595. [5] F.J. Calderon-Moreno and L. Narvaez-Macarro, The module Dfs for locally quasi-homogeneous free divisors, Compositio Math. 134 (2002), 59–74. [6] D. Cox and H. Schenck, Local complete intersection in P2 and Koszul syzygies, Proc. Amer. Math. Soc. 131 (2003), 2007–2014. [7] G. Denham, H. Schenck, M. Schulze, M. Wakefield, U. Walther, Local cohomology of logarithmic forms, arXiv: 1103.2459, to appear in Ann. Inst. Fourier (2011). [8] I. Dolgachev, Polar Cremona transformations, Mich. Math. J. 48 (2000), 191–202. [9] A. Doria, H. Hassanzadeh and A. Simis, A characteristic free criterion of birationality, Advances in Math. 230 (2012), 390–413. [10] D. Eisenbud, Commutative Algebra with a View Toward Algebraic Geometry, Springer-Verlag, New York 1995. [11] S. H. Hassanzadeh and A. Simis, Plane Cremona maps: saturation and regularity of the base ideal, arXiv:1109.2815v4[math.AC] 26 Mar 2012. [12] M. Hochster, Rings of invariantes of tori, Cohen–Macaulay rings generated by monomials, and polytopes, Ann. Math. 96 (1972), 318–337. [13] J. Herzog, A. Simis and W. V. Vasconcelos, Koszul homology and blowing-up rings, in Commutative Algebra, Proceedings: Trento 1981 (S. Greco and G. Valla, Eds.), Lecture Notes in Pure and Applied Mathematics, Vol. 84, Marcel Dekker, New York, 1983, pp. 79–169. [14] D. Bayer and M. Stillman, Macaulay: a computer algebra system for algebraic geometry, Macaulay version 3.0 1994 (Macaulay for Windows by Bernd Johannes Wuebben, 1996). [15] A. Micali and N. Roby, Algèbres symétriques et syzygies, J. Algebra 17 (1971), 460–469. [16] A. N. Nejad, The Aluffi algebra of an ideal, PhD Thesis, Universidade Federal de Pernambuco, Brazil, 2010. [17] A. N. Nejad and A. Simis, The Aluffi Algebra, Journal of Singularities 3 (2011), 20–47. [18] P. Orlik and H. Terao, Arrangements of Hyperplanes, Springer-Verlag, Berlin-Heidelberg-New York 1992. [19] I. Pan and F. Russo, Cremona transformations and special double structures, Manuscripta Math. 117 (2005), 491– 510. [20] H. Reiffen, Das Lemma von Poincaré für holomorphe Differentialformen auf komplexen Räumen, Math. Z. 101 (1967), 269–284. [21] K. Saito, Theory of logarithmic differential forms and logarithmic vector fields, J. Fac. Sci. Univ. Tokyo Sect. IA Math. 27 (1980), 265–291. [22] H. Schenck and S. Tohaneanu, Freeness of conic-line arrangements in P2 , Coment. Math. Helvetici 84 (2009), 235–258. [23] M. Schulze, Freeness and multirestriction of hyperplane arrangements, arXiv:1003.0917, to appear in Compos. Math. (2010). [24] A. Simis, Differential idealizers and algebraic free divisors, in Commutative Algebra: Geometric, Homological, Combinatorial and Computational Aspects, Eds: A. Corso, P. Gimenez, M. V. Pinto and S. Zarzuela, pp. 211–226, Lecture Notes in Pure and Applied Mathematics, Vol. 244, Chapman & Hall/CRC 2005. [25] A. Simis, The depth of the Jacobian ring of a homogeneous polynomial in three variables, Proc. Amer. Math. Soc. 134 (2005), 1591-1598. [26] A. Simis and W. Vasconcelos, The syzygies of the conormal module, Amer. J. Math. 103 (1981), 203–224. [27] A. Simis and W. Vasconcelos, On the Dimension and Integrality of Symmetric Algebras, Math. Z. 177 (1981), 341–358. [28] H. Terao, Arrangements of hyperplanes and their freeness I, J. Fac. Science Univ. Tokyo 27 (1980), 293-312. [29] H. Terao, Generalized exponents of a free arrangement of hyperplanes and Shepard-Todd- Brieskorn formula, Invent. Math. 63 (1981), 159–179. [30] S. Tohaneanu, On freeness of divisors on P2 , arXiv: 1203.2046, to appear in Comm. Alg. (2012). 26 ARON SIMIS AND ŞTEFAN O. TOHǍNEANU [31] W. Vasconcelos, Computational Methods in Commutative Algebra and Algebraic Geometry, Springer-Verlag, Berlin 1998. [32] C.T.C. Wall, Geometry of quartic curves, Math. Proc. Camb. Phil. Soc., 117 (1995) 415–423. [33] M. Yoshinaga, On the freeness of 3-arrangements, Bull. London Math. Soc. 37 (2005), 126–134. U NIVERSIDADE F EDERAL DE P ERNAMBUCO , D EPARTAMENTO DE M ATEMTICA , AV. P ROF. L UIZ F REIRE , S / N C IDADE U NIVERSITRIA , CEP 50740-560, R ECIFE - P ERNAMBUCO - B RASIL , E-mail address: [email protected] D EPARTMENT OF M ATHEMATICS , T HE U NIVERSITY C ANADA , E-mail address: [email protected] OF W ESTERN O NTARIO , L ONDON , O NTARIO N6A 5B7,
0math.AC
ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS FOR STRONG POSITIVE SEMIDEFINITE OPERATORS arXiv:1608.07647v1 [math.OC] 27 Aug 2016 YU HIN (GARY) AU AND LEVENT TUNÇEL Abstract. We consider operators acting on convex subsets of the unit hypercube. These operators are used in constructing convex relaxations of combinatorial optimization problems presented as a 0,1 integer programming problem or a 0,1 polynomial optimization problem. Our focus is mostly on operators that, when expressed as a lift-and-project operator, involve the use of semidefiniteness constraints in the lifted space, including operators due to Lasserre and variants of the Sherali–Adams and Bienstock–Zuckerberg operators. We study the performance of these semidefinite-optimization-based lift-and-project operators on some elementary polytopes — hypercubes that are chipped (at least one vertex of the hypercube removed by intersection with a closed halfspace) or cropped (all 2n vertices of the hypercube removed by intersection with 2n closed halfspaces) to varying degrees of severity ρ. We prove bounds on ρ where these operators would perform badly on the aforementioned examples. We also show that the integrality gap of the chipped hypercube is invariant under the application of several lift-and-project operators of varying strengths. 1. Introduction A foundational approach to tackling combinatorial optimization problems is to start with a 0,1 integer programming formulation and construct convex relaxations of the feasible region which leads to a tractable (whether in practice or theory, of course hopefully in both) optimization problem with essentially the same linear objective function but a convex feasible region. Let P ⊆ [0, 1]n denote the feasible region of the linear programming relaxation of an initial 0,1 integer programming problem. In our convex relaxation approach, we are hoping to construct a tractable representation of the convex hull of integer points in P , i.e., the integer hull of P PI := conv (P ∩ {0, 1}n ) . However, it is impossible to efficiently find a tractable description of PI for a general P (unless P = N P). So, in many cases we may have to be content with tractable convex relaxations that are not exact (strict supersets of the integer hull of P ). Lift-and-project methods provide an organized way of generating a sequence of convex relaxations of P which converge to the integer hull PI of P in at most n rounds. Minimum number of rounds required to obtain the integer hull by a lift-and-project operator Γ is called the Γ-rank Date: February 27, 2018. Key words and phrases. combinatorial optimization, lift-and-project methods, integrality gap, design and analysis of algorithms with discrete structures, integer programming, semidefinite programming, convex relaxations. Some of the material in this manuscript appeared in a preliminary form in Au’s PhD Thesis [Au14]. Yu Hin (Gary) Au: Research of this author was supported in part by a Tutte Scholarship, a Sinclair Scholarship, an NSERC scholarship, research grants from University of Waterloo and Discovery Grants from NSERC. Department of Mathematics, Milwaukee School of Engineering, Milwaukee, Wisconsin, U.S.A. E-mail: [email protected]. Levent Tunçel: Research of this author was supported in part by research grants from University of Waterloo, Discovery Grants from NSERC and U.S. Office of Naval Research under award numbers: N00014-12-1-0049 and N00014-15-1-2171. Department of Combinatorics and Optimization, Faculty of Mathematics, University of Waterloo, Waterloo, Ontario, N2L 3G1 Canada. E-mail: [email protected]. 1 2 YU HIN (GARY) AU AND LEVENT TUNÇEL of P . Computational success of lift-and-project methods on some combinatorial optimization problems and various applications is relatively well-documented (starting with the theoretical foundations in Balas’ work in the 1970’s [Bal74]; appeared as [Bal98]), and the majority of these computational successes come from lift-and-project methods which generate polyhedral relaxations. While many lift-and-project methods utilize in addition positive semidefiniteness constraints which in theory help generate tighter relaxations of PI , the underlying convex optimization problems require significantly more computational resources and are prone to run into more serious numerical stability issues. Therefore, before committing to the usage of a certain lift-and-project method, it would be wise to understand the conditions under which the usage of additional computational resources would be well justified. Indeed, this argument applies to any collection of lift-and-project operators that trade off quality of approximation with computational resources (time, memory, etc.) required. That is, to utilize the strongest operators, one needs a better understanding of the class of problems on which these strongest operators’ computational demands will be worthwhile in the returns they provide. In the next section, we introduce a number of known lift-and-project operators and some of their basic properties, with the focus being on the following operators (every one of these utilizes positive semidefiniteness constraints): • SA+ (see [Au14, AT16]), a positive semidefinite variant of the Sherali–Adams operator SA defined in [SA90]; • Las, due to Lasserre [Las01]; • BZ′+ (see [Au14, AT16]), a strengthened version of the Bienstock–Zuckerberg operator BZ+ [BZ04]. Then, in Section 3, we look into some elementary polytopes which represent some basic situations in 0,1 integer programs. We consider two families of polytopes: unit hypercubes that are chipped or cropped to various degrees of severity. First, given an integer n ≥ 1 and a real number ρ where 0 ≤ ρ ≤ n, the chipped hypercube is defined to be ) ( n X n xi ≤ n − ρ . Pn,ρ := x ∈ [0, 1] : i=1 Similarly, we define the cropped hypercube     X X n Qn,ρ := x ∈ [0, 1] : (1 − xi ) + xi ≥ ρ, ∀S ⊆ [n] ,   i∈S i6∈S where [n] denotes the set {1, . . . , n}. These two families of polytopes had been shown to be bad instances for many lift-and-project methods and cutting-plane procedures (see, among others, [CCH89, CL01, CD01, GT01, Lau03, Che07] and more recently [KLM15]). Moreover, these elementary sets are interesting in many other contexts as well. For instance, note that each constraint defining Qn,ρ removes a specific extreme point of the unit hypercube from the feasible region. In many 0,1 integer programming problems and in 0,1 mixed integer programming problems, such exclusion constraints are relatively commonly used. Herein, we show that these sets are also bad instances for the strongest known operators, extending the previously known results in this vein. In particular, we show the following: • The SA+ -rank of Pn,ρ is n for all ρ ∈ (0, 1), and is at most n − ⌈ρ⌉ + 1 for all ρ ∈ (0, n). ˜ (a simple polyhedral operator defined in [GT01] that is In contrast, we show that LS similar to the LS0 operator due to Lovász and Schrijver [LS91]) requires n iterations to return the integer hull of Pn,ρ for all non-integer ρ ∈ (0, n − 1). ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 3 • The integrality gap of SAk+ (Pn,ρ ) in the direction of the all-ones vector is 1+ (n − k)(1 − ρ) (n − 1)(n − k + kρ) for all n ≥ 2, k ∈ {0, 1, . . . , n}, and ρ ∈ (0, 1). Moreover, we show that this integrality ˜ gap is exactly the same, if we replaceSA+ by an operator as weak as LS. i 2 n −1 . This strengthens earlier work by • The Las-rank of Pn,ρ is n for all ρ ∈ 0, 2nn+1 −n2 −1 Cheung [Che07], who showed the existence of such a positive ρ but did not give concrete bounds.   n • The Las-rank of Qn,ρ is n for all ρ ∈ 0, 2n+2n+1 , and at most n − 1 for all ρ > 2n+1 . −n−3 −2 √ ′ • There exist n, ρ where the BZ+ -rank of Pn,ρ is Ω( n), providing what we believe to be the first example where BZ′+ (and as a consequence, the weaker BZ+ ) requires more than a constant number of iterations to return the integer hull of a set. The tools we use in our analysis, which involve zeta and moment matrices, build on earlier work by others (such as [Lau03] and [Che07]), and could be useful in analyzing lift-and-project relaxations of other sets. Finally, we conclude the manuscript by noting some interesting behaviour of the integrality gaps of some lift-and-project relaxations. We remark that preliminary and weaker versions of our results on the Lasserre relaxations of Pn,ρ and Qn,ρ were published in the first author’s PhD thesis [Au14]. During the writing of this manuscript, we discovered that Kurpisz, Leppänen and Mastrolilli [KLM15] had obtained similar and stronger results. In fact, in their work, they characterized general conditions for when the (n − 1)th Lasserre relaxation is not the integer hull. Using very similar ideas to theirs, we have subsequently sharpened our results to those appearing in this manuscript. 2. Preliminaries In this section, we establish some notation and describe several lift-and-project operators utilizing positive semidefiniteness constraints. 2.1. The operators LS+ and SA+ . First, let F denote {0, 1}n , and define A := 2F , the power set of F. As shown in [Zuc03], many existing lift-and-project operators can be seen as lifting a given relaxation P to a set of matrices whose rows and columns are indexed by sets in A. For more motivation and details on this framework, the reader may refer to [AT16]. We first define the operator SA+ , which can be interpreted as a strengthened variant of the Sherali–Adams operator [SA90]. Given P ⊆ [0, 1]n , define the cone    λ n+1 K(P ) := ∈R : λ ≥ 0, x ∈ P , λx where we shall denote the extra coordinate by 0. Next, we introduce a family of sets in A that are used extensively by the operators we will introduce in this paper. Given a set of indices S ⊆ [n] and t ∈ {0, 1}, we define S|t := {x ∈ F : xi = t, ∀i ∈ S} . Note that ∅|0 = ∅|1 = F. Also, to reduce cluttering, we write i|t instead of {i} |t . Next, given any integer ℓ ∈ {0, 1, . . . , n}, we define Aℓ := {S|1 ∩ T |0 : S, T ⊆ [n], S ∩ T = ∅, |S| + |T | ≤ ℓ} and A+ ℓ := {S|1 : S ⊆ [n], |S| ≤ ℓ}. For instance, A1 = {F, 1|1 , 2|1 , . . . , n|1 , 1|0 , 2|0 , . . . , n|0 } , 4 YU HIN (GARY) AU AND LEVENT TUNÇEL while ′ A+ 1 = {F, 1|1 , 2|1 , . . . , n|1 } . Given any vector y ∈ RA for some A′ ⊆ A which contains F and i|1 for all i ∈ [n], we let x̂(y) := (yF , y1|1 , . . . , yn|1 )⊤ . Sometimes we may also alternatively index the entries of x̂(y) as (y0 , y1 , . . . , yn )⊤ , when we verify these vectors’ membership in K(P ). Finally, let Sn+ denote the set of n-by-n real, symmetric matrices that are positive semidefinite, and let ei denote the ith unit vector (of appropriate size, which will be clear from the context). Then, given any positive integer k, we define the operator SAk+ as follows: c k (P ) be the set of matrices Y ∈ SAk which satisfy all of the following conditions: (1) Let SA + + (SA+ 1) Y [F, F] = 1. (SA+ 2) For every α ∈ Ak : (i) x̂(Y eα ) ∈ K(P ); (ii) Y eα ≥ 0. (SA+ 3) For every S|1 ∩ T |0 ∈ Ak−1 , Y eS|1 ∩T |0 ∩j|1 + Y eS|1 ∩T |0 ∩j|0 = Y eS|1 ∩T |0 , ∀j ∈ [n] \ (S ∪ T ). (SA+ 4) For all α, β ∈ Ak such that α ∩ β = ∅, Y [α, β] = 0. (SA+ 5) For all α1 , α2 , β1 , β2 ∈ Ak such that α1 ∩ β1 = α2 ∩ β2 , Y [α1 , β1 ] = Y [α2 , β2 ]. (2) Define    k k n c (P ), x̂(Y eF ) = 1 SA+ (P ) := x ∈ R : ∃Y ∈ SA . + x The SAk+ operator extends the lifted space of the original level-k Sherali–Adams operator SAk (which are matrices of dimension (n+1)×Θ(nk )) to a set of Θ(nk )-by-Θ(nk ) symmetric matrices, and imposes an additional positive semidefiniteness constraint. Also, LS+ , the operator defined in [LS91] that utilizes positive semidefiniteness, is equivalent to SA1+ . In general, SAk+ dominates LSk+ (i.e., k iterative applications of LS+ — see [AT16] for a proof). 2.2. The Lasserre operator. We now turn our attention to the Las operator due to Lasserre [Las01]. While Las can be applied to semialgebraic sets, we restrict our discussion to its applications to polytopes contained in [0, 1]n . Gouveia, Parrilo and Thomas provided in [GPT10] an alternative description of the Las operator, where PI is described as the variety of an ideal intersected with the solutions to a system of polynomial inequalities. Our presentation of the operator is closer to that in [Lau03] than to Lasserre’s original description. Given P := {x ∈ [0, 1]n : Ax ≤ b}, and an integer k ∈ [n], A+ k d (P ) denote the set of matrices Y ∈ S k+1 that satisfy all of the following (1) Let Las + conditions: (Las 1) Y [F, F] = 1; + (Las 2) For every i ∈ [m], define the matrix Y i ∈ SAk where n X A[i, j]Y [(S ∪ {j})|1 , (S ′ ∪ {j})|1 ], Y i [S|1 , S ′ |1 ] := bi Y [S|1 , S ′ |1 ] − j=1 and impose Y i  0. (Las 3) For every α1 , α2 , β1 , β2 ∈ A+ k such that α1 ∩ β1 = α2 ∩ β2 , Y [α1 , β1 ] = Y [α2 , β2 ]. (2) Define    k k n d (P ) : x̂(Y eF ) = 1 Las (P ) := x ∈ R : ∃Y ∈ Las . x ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 5 For all operators Γ considered in this paper, and for every polytope P ⊆ [0, 1]n , we define Γ0 (P ) := P . We note that, unlike the previously mentioned operators, Las requires an explicit description of P in terms of valid inequalities. While it is not apparent in the above definition of the Las operator (as it only uses the variables in the form S|1 , instead of the broader family of S|1 ∩ T |0 as in operators based on SA), we show that Las does commute with all automorphisms of the unit hypercube. Proposition 1. Let L : Rn → Rn be an affine transformation such that {L(x) : x ∈ [0, 1]n } = [0, 1]n . Then, Lask (L(P )) = L(Lask (P )) for all polytopes P ⊆ [0, 1] and for every positive integer k. Proof. Since the automorphism group of the unit hypercube is generated by linear transformations swapping two coordinates and affine transformations flipping a coordinate, it suffices to prove that Las commutes with each of these transformations. First, we show that Lask commutes with the mappings which swap two coordinates. Without loss of generality, we may assume the coordinates are 1 and 2. Let L1 denote the linear transformation, where   x2 if i = 1; x1 if i = 2; [L1 (x)]i :=  xi otherwise. + We also define the map L : A+ k+1 → Ak+1 where   ((S \ {1}) ∪ {2})|1 if 1 ∈ S, 2 6∈ S; ((S \ {2}) ∪ {1})|1 if 2 ∈ S, 1 6∈ S; L(S|1 ) :=  S|1 otherwise, d k (P ). We show that L1 (x) ∈ Now suppose x ∈ Lask (P ), with certificate matrix Y ∈ Las + Lask (L1 (P )). Define Y ′ ∈ SAk+1 such that Y ′ [S|1 , T |1 ] := Y [L(S)|1 , L(T )|1 ], for all S, T ∈ Ak+1 . Then we see that Y ′ is Y with some columns and rows Pn permuted, and thus is positive semidefinite n+1 too. Next, for each a ∈ R such that a0 + i=1 ai xi ≥ 0 is an inequality in the system describing P , define a′ ∈ Rn+1 where   a2 if i = 1; ′ a1 if i = 2; ai :=  ai otherwise. 6 YU HIN (GARY) AU AND LEVENT TUNÇEL Then the collection of the derived inequalities a′0 + j th inequality describing L(P ), then Y ′j [S|1 , T |1 ] = a′0 Y ′ [S|1 , T |1 ] + n X i=1 Pn ′ i=1 ai xi ≥ 0 describe L(P ). If this is the a′i Y ′ [(S ∪ {i})|1 , (T ∪ {i})|1 ] = a0 Y [L(S)|1 , L(T )|1 ] + a2 Y [L(S ∪ {1})|1 , L(T ∪ {1})|1 ] + a1 Y [L(S ∪ {2})|1 , L(T ∪ {2})|1 ] n X Y [L(S ∪ {i})|1 , L(T ∪ {i}))|1 ] + i=3 = a0 Y [L(S)|1 , L(T )|1 ] + a2 Y [L(S) ∪ {2} |1 , L(T ) ∪ {2} |1 ] + a1 Y [L(S) ∪ {1} |1 , L(T ) ∪ {1} |1 ] n X Y [L(S ∪ {i})|1 , L(T ∪ {i}))|1 ] + i=3 j = Y [L(S)|1 , L(T )|1 ]. Thus, Y ′j is also Y j with rows and columns permuted, and thus is positive semidefinite. Hence, we obtain that x̂(Y ′ eF ) = L1 (x) is in Las(L1 (P )). Next, consider the affine transformations flipping a coordinate (without loss of generality, the first coordinate). So, we define L2 : Rn → Rn where [L2 (x)]i :=  1 − x1 if i = 1; xi otherwise. + Also, for every integer ℓ ≥ 1, define U (ℓ) ∈ RAℓ ×Aℓ such that U (ℓ) [S|1 , T |1 ∩ W |0 ] :=  (−1)|S\T | if T ⊆ S ⊆ T ∪ W ; 0 otherwise. d k (P ). Define Ȳ ∈ SAk+1 where Ȳ := Now let x ∈ Lask (P ), with certificate matrix Y ∈ Las (U (k+1) )⊤ Y U (k+1) . This time, we let L : A+ k+1 → Ak+1 denote the map where L(S|1 ) :=  ((S \ {1})|1 ∩ 1|0 if 1 ∈ S; S|1 otherwise, + and let Y ′ ∈ SAk+1 such that Y ′ [S|1 , T |1 ] := Ȳ [L(S)|1 , L(T )|1 ], for all S, T ∈ Ak+1 . Then we see that Y ′ is a symmetric minor of Ȳ = (U (k+1) )⊤ YPU (k+1) . Since Y  0, it follows that Y ′  0 as well. Next, for each a ∈ Rn+1 such that a0 + ni=1 ai xi ≥ 0 is an inequality in the system describing P , define a′ ∈ Rn+1 where   a0 + a1 if i = 0; ′ −a1 if i = 1; ai :=  ai otherwise. ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS Then the collection of the derived inequalities a′0 + j th inequality describing L(P ), then Y ′j [S|1 , T |1 ] = a′0 Y ′ [S|1 , T |1 ] + n X i=1 Pn ′ i=1 ai xi 7 ≥ 0 describe L(P ). If this is the a′i Y ′ [(S ∪ {i})|1 , (T ∪ {i})|1 ] = (a0 + a1 )Ȳ [L(S)|1 , L(T )|1 ] − a1 Ȳ [L(S ∪ {1})|1 , L(T ∪ {1})|1 ] n X Ȳ [L(S ∪ {i})|1 , L(T ∪ {i})|1 ] + i=2 = a0 Ȳ [L(S)|1 , L(T )|1 ] + a1 Ȳ [L(S) ∪ {1} |1 , L(T ) ∪ {1} |1 ] n X + Ȳ [L(S) ∪ {i} |1 , L(T ) ∪ {i} |1 ] i=2 (k) ⊤ = ((U ) Y j U (k) )[L(S)|1 , L(T )|1 ]. Thus, Y ′j is a symmetric minor of (U (k) )⊤ Y j U (k) , and thus is positive semidefinite. Therefore, x̂(Y ′ eF ) = L2 (x) is in Las(L2 (P )).  2.3. The Bienstock–Zuckerberg operator. In [BZ04], Bienstock and Zuckerberg devised a positive semidefinite lift-and-project operator (which we denote BZ+ herein) that is quite different from the previously (pre-2004) proposed operators. In particular, in its lifted space, it utilizes variables in A that are not necessarily in the form S|1 ∩ T |0 , in addition to a number of other ideas. One such idea is refinement. While BZ+ is defined for any polytope contained in [0, 1]n , we will restrict our discussion to lower-comprehensive polytopes for simplicity’s sake. Let polytope P := {x ∈ [0, 1]n : Ax ≤ b}, where A ∈ Rm×n is nonnegative and b ∈ Rm is positive (this implies that P is lower-comprehensive; conversely, every n-dimensional lowercomprehensive polytope in [0, 1]n admits such a representation). Given a vector v, let supp(v) denote the support of v. Next, a subset O of [n] is called a k-small obstruction of P if there exists an inequality a⊤ x ≤ bi in the system Ax ≤ b where • P O ⊆ supp(a); • j∈O aj > bi ; and • |O| ≤ k + 1 or |O| ≥ |supp(a)| − (k + 1). P Observe that, given such an obstruction O, the inequality i∈O xi ≤ |O| − 1 holds for every integral vector x ∈ P . Thus, if we let Ok denote the collection of all k-small obstructions of the system Ax ≤ b, then the set ) ( X Ok (P ) := x ∈ P : xi ≤ |O| − 1, ∀O ∈ Ok i∈O is a relaxation of PI that is potentially tighter than P . The operator BZ+ then defines other collections of indices called walls and tiers, and uses these sets to construct the lifted space of P . In some rare cases though, when the system Ax ≤ b does not have a single k-small obstruction, we have the following result that relates the performance of SA+ and BZ′+ (a strengthened version of BZ+ defined in [AT16]): 8 YU HIN (GARY) AU AND LEVENT TUNÇEL Proposition 2. If P = {x ∈ [0, 1]n : Ax ≤ b} where Ax ≤ b does not have a single k-small obstruction, then ′k SA2k + (P ) ⊆ BZ+ (P ). Proof. If P does not have a single obstruction, then Ok (P ) = P . Also, the collection of walls generated by BZ′k + consists of just the singleton sets. Thus, every tier (which is a union of up to k walls) has size at most k. Then it is vacuously true that every tier of size greater than k is P -useless (this concept of P -useless is defined in [AT16]), and thus by Proposition 4 in [AT16], ′k 2k ′k we obtain that SA′k + (P ) ⊆ BZ+ (P ). Since SA+ (P ) ⊆ SA+ (P ) in general, our claim follows.  The operator SA′+ mentioned the preceding proof is a strengthened version of SA+ (with additional constraints that are very similar to those differentiating BZ′+ from BZ+ ). To minimize notation and distraction, we have elected to only state elements of these operators that are crucial for the subsequent results we present. In Figure 1 we provide a comparison of relative strengths of all aforementioned lift-and-project operators, in addition to BCC, a simple operator defined ˜ a geometric operator studied in [GT01] in by Balas, Ceria, and Cornuéjols in [BCC93]; and LS, their analysis of the Lovász–Schrijver operators. Each arrow in the figure denotes “is dominated by”, meaning that when applied to the same relaxation P , the operator at the head of an arrow would return a relaxation that is at least as tight as that obtained by applying the operator at the tail of the arrow. While the focus in this paper will be on the performance of SA+ , Las and BZ′+ , some of our results also have implications on these other operators. The reader may refer to [AT16] for the detailed definitions and some more intricate properties of these operators. Las BCC LS+ SA+ ˜ LS SA SA′+ BZ+ BZ′+ PSD Operators Polyhedral Operators Tractable w/ weak separation oracle for P Tractable w/ facet description of P Figure 1. A strength chart of some lift-and-project operators. There are also many other operators whose relative performance can be studied in this wider context of operators. For example, recently Bodur, Dash and Günlük [BDG16] proposed a polyhedral lift-and-project operator called Ñ and showed that LS → Ñ → SA2 ˜ where LS is a polyhedral operator devised in [LS91] that dominates LS. Considering Figure 1, note that every lower bound that we prove on rank as well as integrality gaps for Las and BZ′+ imply the same results for all other operators in Figure 1. Similarly, every ˜ applies to all other operators in Figure 1, upper bound on rank and integrality gaps for LS except BCC. ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 9 3. Some bad instances for SA+ , Las and BZ′+ In this section, we consider several polytopes that have been shown to be bad instances for many known lift-and-project operators (and cutting plane schemes in general). 3.1. The chipped hypercube Pn,ρ . Recall the chipped hypercube ) ( n X xi ≤ n − ρ . Pn,ρ := x ∈ [0, 1]n : i=1 Cook and Dash [CD01] showed that the LS+ -rank of Pn,1/2 is n, while Laurent [Lau03] proved that the SA-rank of Pn,1/2 is also n. Cheung [Che07] extended these results and showed that both the LS+ - and SA-rank of Pn,ρ are n for all ρ ∈ (0, 1). Here, we use similar techniques to establish the SA+ -rank for Pn,ρ . Note that, from here on, we will sometimes use v[i] to denote the i-entry of a vector v (instead of vi ). Proposition 3. For every n ≥ 2, the SA+ -rank of Pn,ρ is n for all ρ ∈ (0, 1).   ρ n−1 Proof. We prove our claim by showing that x̄ := 1 − nρ+1−ρ (Pn,ρ ) \ (Pn,ρ )I , where ē ∈ SA+ ē denotes the all-ones vector. First,   n X ρ nρ x̄i = n 1 − > n − 1, = n− nρ + 1 − ρ nρ + 1 − ρ i=1 n−1 (Pn,ρ ). Define Y ∈ RAn−1 ×An−1 and so x̄ 6∈ (Pn,ρ )I . We next show that this vector is in SA+ such that  ρ|S|   1 − nρ+1−ρ if α ∩ β = S|1 for some S ⊆ [n]; ρ Y [α, β] := if α ∩ β = S|1 ∩ j|0 for some S ⊆ [n] and j ∈ [n] \ S; nρ+1−ρ   0 otherwise. n−1 c+ (Pn,ρ ). First, (SA+ 1) holds as Y [F, F] = 1 (since F ∩ F = ∅|1 ). We claim that Y ∈ SA kρ ρ or 1 − nρ+1−ρ for It is not hard to see that Y ≥ 0, as every entry in Y is either 0, nρ+1−ρ some integer k ∈ {0, . . . , n}. Next, we check that x̂(Y eβ ) ∈ K (Pn,ρ ) for all β ∈ An−1 . Given ρ (ē − ei ) β = S|1 ∩ T |0 , x̂(Y eβ ) is the zero vector whenever |T | ≥ 2, and is the vector nρ+1−ρ whenever T = {i} for some i ∈ [n]. Finally, suppose β = S|1 for some S ⊆ [n] where |S| = k. Then ( kρ 1 − nρ+1−ρ if i = 0 or i ∈ S; x̂(Y eβ )[i] = (k+1)ρ 1 − nρ+1−ρ if i ∈ [n] \ S. Now n X x̂(Y eβ )[i] = i=1 = ≤ =     kρ (k + 1)ρ k 1− + (n − k) 1 − nρ + 1 − ρ nρ + 1 − ρ     n−k kρ n 1− −ρ nρ + 1 − ρ nρ + 1 − ρ   kρ (n − ρ) 1 − nρ + 1 − ρ (n − ρ)x̂(Y eβ )[0]. 10 YU HIN (GARY) AU AND LEVENT TUNÇEL Thus, x̂(Y eβ ) ∈ K(P ) in this case as well. Next, it is not hard to see that the entries of Y satisfy (SA+ 3), (SA+ 4) and (SA+ 5). Finally, to see that Y  0, let Y ′ be the symmetric minor ′ of Y indexed by rows and columns from A− n−1 := {S|0 : S ⊆ [n], |S| ≤ n − 1}. Then Y  0 as − it is diagonally dominant. Next, define L ∈ RAn−1 ×An−1 where  (−1)|S| if S ∪ T = U ; L[S|1 ∩ T |0 , U |0 ] := 0 otherwise. Then it can be checked that Y = LY ′ L⊤ . Hence, we conclude that Y  0 as well. This completes our proof.  We next show that (0, 1) is the only range of ρ’s for which the SA+ -rank of Pn,ρ is n. To do that, it is helpful to introduce the notion of moment matrices. Given an integer k ≥ 0 + + + and vector y ∈ RAℓ where ℓ ≥ min {n, 2k}, we define the matrix Mk (y) ∈ RAk ×Ak where Mk (y)[α, β] := y[α ∩ β] for all α, β ∈ A+ k . Then we have the following: Proposition 4. For every n ≥ 2 and non-integer ρ ∈ (0, n), the SA+ -rank of Pn,ρ is at most n − ⌈ρ⌉ + 1. Proof. Let P := Pn,ρ . We use the notion of ℓ-establishment (defined in [AT16]) to prove this claim. First, let ℓ := n − ⌈ρ⌉. From the conditions imposed by SA+ , it is easy to check that c ℓ+1 (P ) is (ℓ + 1)-established (and thus ℓ-established). Also, the condition every matrix Y ∈ SA + (SA+ 5) guarantees that the symmetric minor of Y with rows and columns indexed by sets in A+ ℓ is a moment matrix Mℓ (y) for some vector y. Now notice that for every set S ⊆ [n] where |S| =  ℓ + 1, the incidence vector of S is not in P (as ℓ + 1 > n − ρ). Hence, the condition x̂ Y eS|1 ∈ K(P ) imposed by (SA+ 2) implies that Y [F, S|1 ] = 0. Thus, we obtain that Y [S|1 , S|1 ] = 0 for all S ⊆ [n] of size ℓ + 1, and so the diagonal entries of the symmetric minor Y ′ of Y indexed by sets in A+ ℓ+1 \ Aℓ are all zero. For ′ Y to be positive semidefinite, Y must have all zero entries. Thus, we obtain that y[S|1 ] = 0 for all sets S where |S| ≥ ℓ + 1. P Next, if we define Zi := S⊆[n],|S|=i y[S|1 ] for every i ≥ 0, we obtain that Zi = 0 for all i > ℓ. Then it follows from Corollary 12 in [AT16] that Z1 ≤ ℓ. Since n n X X Y [i|1 , F], y[i|1 ] = Z1 = we conclude that Pn i=1 xi i=1 ≤ ℓ is valid for i=1 SAℓ+1 + (P ), and our claim follows.  Thus, we know that the SA+ -rank of Pn,ρ is exactly n when ρ ∈ (0, 1), and the rank is 1 if ρ ∈ (n − 1, n). When ρ ∈ (n − 2, n − 1), it follows from Proposition 4 that the SA+ -rank is at most 2. Since it is not hard to show that SA1+ (Pn,ρ ) 6= Pn,n−1 , we know in this case that the SA+ -rank is exactly 2. Next, we show that for a weaker operator, the rank of Pn,ρ is always n if it is not integral and strictly contains the unit simplex. Given integer k ∈ [n] and P ⊆ [0, 1]n , consider the following operator originally defined in [GT01]: \ ˜ k (P ) := LS conv {x ∈ P : xi ∈ {0, 1} , ∀i ∈ S} . S⊆[n],|S|=k k ˜ (P ) if and only if for every set of indices S of size k, x can be expressed That is, x is in LS ˜ produces as a convex combination of points in P whose entries in S are all integral. While LS tighter relaxations than BCC, it in turn is dominated by SA and several operators devised by ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 11 Lovász and Schrijver in [LS91] (see, for instance, [GT01] for a discussion on this matter). Then we have the following: ˜ Proposition 5. For every integer n ≥ 2 and for every non-integer ρ ∈ (0, n − 1), the LS-rank of Pn,ρ is n. Proof. n,ρ andoℓ := n − ⌈ρ⌉ (so PI = Pn,ℓ ). We prove our claim by showing that n Let P := Pn−1 ⊤ ˜ max ē x : x ∈ LS (P ) > ℓ. n o ℓ First, let S = [n − 1], and define ǫ := min ⌈ρ⌉ − ρ, n−1 . Also, given T ⊆ S, let χT denote the incidence vector of T in {0, 1}n−1 . Now consider the point      X X n − ℓ χ T  x̄ :=  + n−1 ǫ ℓ (n − ǫ(n − 1)) T ⊆S,|T |=ℓ T ⊆S,|T |=ℓ−1 ℓ − ǫ(n − 1) n−1 ℓ−1 (n − ǫ(n − 1))    χT  . 1 First,observe that x̄ is a linear combination of the points entries in S are integral. Also,   whose  χT χT ∈ P for all T of size ℓ (by the choice of ǫ), and ∈ P for all T of size ℓ − 1 as well. ǫ 1 Furthermore, since ǫ(n − 1) ≤ ℓ, the weights on these points are nonnegative, and do sum up to 1. Thus, x̄ is indeed a convex combination of these points. By the symmetry of P and the ˜ we can express x̄ as a similar convex combination of points in P for all other definition of LS, ˜ n−1 (P ). sets S of size n − 1. Thus, this shows that x̄ ∈ LS ℓ(1−ǫ)+ǫ ē, and thus ē⊤ x̄ > ℓ and x̄ 6∈ PI . On the other hand, it is easy to check that x̄ = n(1−ǫ)+ǫ ˜ Hence, we deduce that P has LS-rank n.  Thus, we see that when ρ is close to n − 1, the positive semidefiniteness constraint imposed by SA+ is in fact helpful in generating the desired facet of the integer hull that can be elusive to a weaker polyhedral operator until the nth iteration. We next give a lower bound on the SA+ -rank of Pn,ρ for some cases where ρ > 1, which will be useful when we later establish a BZ′+ -rank lower bound for some of these polytopes. We first need the following result. Suppose P ⊆ [0, 1]n . Given x ∈ P , let S(x) := {i ∈ [n] : 0 < xi < 1} . Also, given x ∈ [0, 1]n and two disjoint sets of indices I, J ⊆ [n], we define the vector xIJ ∈ [0, 1]n where  if i ∈ I;  1 I 0 if i ∈ J; xJ [i] :=  x[i] otherwise. In other words, xIJ is the vector obtained from x by setting all entries indexed by elements in I to 1, and all entries indexed by elements in J to 0. Then we have the following useful property that is inherited by a wide class of lift-and-project operators. Lemma 6 (Theorem 15 in [AT16]). Let P ⊆ [0, 1]n and x ∈ P . If xIJ ∈ P for all I, J ⊆ S(x) such that |I| + |J| ≤ k, then x ∈ SAk+ (P ). Using Lemma 6, we have the following for the SA+ -rank of Pn,ρ : Proposition 7. For every n ≥ 2, if ρ ∈ (0, n) is not an integer and k < SA+ -rank of Pn,ρ is at least k + 1. n(⌈ρ⌉−ρ) , ⌈ρ⌉ then the 12 YU HIN (GARY) AU AND LEVENT TUNÇEL Proof. First, observe that k< n(⌈ρ⌉ − ρ) ⇐⇒ (n − k) ⌈ρ⌉  n − ⌈ρ⌉ n  + k < n − ρ. Thus, there exists ℓ ∈ R such that (n−k)ℓ+k < n−ρ and ℓ > n−⌈ρ⌉ n . Consider the point x̄ := ℓē. n−⌈ρ⌉ Since ℓ > n , x̄ 6∈ (Pn,ρ )I . However, for every pair of disjoint sets of indices I, J ⊆ [n] where |I| + |J| ≤ k, we have n X x̄IJ [i] ≤ (n − k)ℓ + k < n − ρ, i=1 x̄IJ by the choice of ℓ. Thus, ∈ Pn,ρ P for all such choices of I, J. (Note that the first inequality above follows from the fact that ni=1 x̄IJ [i] is maximized by choosing I, J where |I| = k and J = ∅.) Thus, it follows from Lemma 6 that x̄ ∈ SAk+ (Pn,ρ ). This proves that SAk+ (Pn,ρ ) 6= (Pn,ρ )I , and hence the SA+ -rank of Pn,ρ is at least k + 1.  Using Proposition 7, we obtain a lower-bound result on the BZ′+ -rank of Pn,ρ , establishing what we believe to be the first example in which BZ′+ (and, as a result, BZ+ ) requires more than a constant number of iterations to return the integer hull of a set. √ √ Theorem 8. Suppose an integer n ≥ 5 is not square. Then there exists ρ ∈ (⌊ n⌋ , ⌈ n⌉) k j √a perfect n+1 . such that the BZ′+ -rank of Pn,ρ is at least 2 Proof. Let P := Pn,ρ . First, choose ǫ ∈ (0, 1) small enough such that √ n−1< n (1 − ǫ) √ , ⌈ n⌉ j√ k √ n−1 . Notice that for all n ≥ 5, k + 1 < ρ < n − (k + 1), and let ρ := ⌊ n⌋ + ǫ. Next, let k := 2 and so BZ′k we obtain that SA2k + does not generate any k-small obstructions for P . Thus, + (P ) ⊆ √ ′k 2k BZ+ (P ) by Proposition 2. Also, from jProposition 7, since 2k ≤ n − 1, SA+ (P ) 6= PI . Thus, k the BZ′+ -rank of P is at least k + 1 = √ n+1 2 .  We note that the BZ+ -rank of Pn,ρ is 1 for P every ρ ∈ (0, 1). This is because the set [n] is a k-small obstruction for every k ≥ 1, and so ni=1 xi ≤ n − 1 is valid for Ok (Pn,ρ ), and the refinement step in BZ+ already suffices in generating the integer hull of Pn,ρ . More generally, when k +1 ≥ ρ, every subset of set of [n] of size n−k does qualify as a k-small obstruction, and it can be shown that BZk+ (Pn,ρ ) = (Pn,ρ )I . On the other hand, since BZ+ (and the refined version BZ′+ ) dominates SA+ , Proposition 4 implies that the BZ+ -rank of Pn,ρ is at most n − ⌈ρ⌉ + 1. This implies that, in contrast with other operators (including SA+ and, as we will see, Las), the BZ+ -rank of Pn,ρ is low both when ρ is close to 0 or n. We next turn to the Las-rank of Pn,ρ . Interestingly, Cheung showed the following in [Che07]: Theorem 9. (i) For every even integer n ≥ 4, the Las-rank of Pn,ρ is at most n − 1 for all ρ ≥ n1 ;  (ii) For every integer n ≥ 2, there exists ρ ∈ 0, n1 such that the Las-rank of Pn,ρ is n. Thus, while the rank of Pn,ρ is invariant under the choice of ρ ∈ (0, 1) with respect to all other lift-and-project operators we have considered so far, it is not the case for Las. Next, we strengthen part (ii) of Cheung’s result above, and give a range of ρ where Pn,ρ has Las-rank n for every n ≥ 2. ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS Theorem 10. Suppose n ≥ 2, and 0<ρ≤ Then Pn,ρ has Las-rank n. 13 n2 − 1 . 2nn+1 − n2 − 1 Before we prove Theorem 10, we need some notation and lemmas. Define the matrix Z ∈ where  1 if S ⊆ T ; Z[S|1 , T |1 ] := 0 otherwise. + + RAn ×An Z is the zeta matrix of [n]. Note that Z is invertible, and it is well known that its inverse is the + + Möbius matrix M ∈ RAn ×An where  (−1)|T \S| if S ⊆ T ; M [S|1 , T |1 ] := 0 otherwise. Throughout this paper, we will assume that the rows and columns in Z and M are ordered such that the last row/column corresponds to the set [n]|1 . Note that, with such an ordering, the last column of Z is the all-ones vector. The following relation between zeta matrices and moment matrices is due to Laurent [Lau03]: + + Lemma 11 (Lemma 2 in [Lau03]). Suppose y ∈ RAn . Define u ∈ RAn where X u[S|1 ] := (−1)|T \S| y[T |1 ]. T ⊇S Then Mn (y) = Z Diag(u)Z ⊤ . Note that we used Diag(u) to denote the diagonal matrix U where U [S|1 , S|1 ] := u[S|1 ] for all S ⊆ [n]. Next, the following lemma will be useful for proving Theorem 10, as well as analyzing the cropped hypercube Qn,ρ later on. Note that it uses very similar ideas to that in [KLM15], where they characterized general conditions for when Mn−1 (w) is positive semidefinite, although the proof here is simpler as we are specifically focused on the applications to the sets Pn,ρ and Qn,ρ . + Lemma 12. Let θ ∈ (0, 1) be a fixed number. Define y ∈ RAn such that y[S|1 ] := θ |S| for all S ⊆ [n]. Then (i) Mi (y)  0 for all i ∈ [n]. (ii) Given any ρ > 0, (n − ρ)Mn (y)[S|1 , T |1 ] − n X i=1 Mn (y)[(S ∪ {j})|1 , (T ∪ {j})|1 ] = Mn (w)[S|1 , T |1 ] where w|S|1 ] := ((n − |S|)(1 − θ) − ρ) θ |S| for all S ⊆ [n]. Moreover, Mn (w) = Z Diag(u)Z ⊤ , where u[S|1 ] := (n − |S| − ρ)θ |S| (1 − θ)n−|S| for all S ⊆ [n]. (iii) If ρ ∈ (0, 1) and ρ≤ (1) then Mn−1 (w) ≻ 0. (n + 1)θ(1 − θ)n , 2 − [(n − 1)θ + 2] (1 − θ)n 14 YU HIN (GARY) AU AND LEVENT TUNÇEL Proof. To prove part (i), it suffices to show that Mn (y)  0, as Mi (y) is a symmetric minor of Mn (y) for all i < n. By Lemma 11, Since Mn (y) = Z Diag(v)Z ⊤ , where v[S|1 ] = X T ⊇S |T \S| (−1) y[T |1 ] = n−|S|  X i=0  n − |S| (−1)i θ |S|+i = θ |S|(1 − θ)n−|S|, i which is positive for all S ⊆ [n]. Thus, it follows that Mn (y)  0. For part (ii), we see that (n − ρ)Mn (y)[S|1 , T |1 ] − n X i=1 Mn (y)[(S ∪ {j})|1 , (T ∪ {j})|1 ]   = (n − ρ)θ |S∪T | − |S ∪ T |θ |S∪T | + (n − |S ∪ T |)θ |S∪T |+1 = ((n − |S ∪ T |)(1 − θ) − ρ) θ |S∪T | = Mn (w)[S|1 , T |1 ]. P Also, it is not hard to check that T ⊇S (−1)|T \S| w[S|1 ] = u[S|1 ] for all S ⊆ [n], and so the last part of the claim follows from Lemma 11. Finally, for (iii), let Z̄ and M̄ , respectively, denote the symmetric minor of Z and M with n−1 denote the vector the row and column corresponding to [n]|1 removed. We also let u′ ∈ A+ obtained from u by removing the entry corresponding to [n]|1 . Then by Lemma 11, Mn (w) = Z Diag(u)Z ⊤    ⊤  Z̄ ē Diag(u′ ) 0 Z̄ 0 = n ⊤ 0 1 0 −θ ρ ē 1   ′ ⊤ n ⊤ n Z̄ Diag(u )Z̄ − θ ρēē −θ ρē . = n ⊤ −θ ρē −θ n ρ Since Mn−1 (w) is the symmetric minor of Mn (w) with the last row and column removed, we obtain that Mn−1 (w) = Z̄ Diag(u′ )Z̄ ⊤ −θ n ρēē⊤ . Notice that u[S|1 ] = (n−|S|−ρ)θ |S| (1−θ)n−|S| > 0 for all S ⊂ [n], and that M̄ is nonsingular (M̄ is the inverse of Z̄). Hence, [Diag(u′ )]−1/2 M̄ is nonsingular and [Diag(u′ )]−1/2 M̄ · M̄ ⊤ [Diag(u′ )]−1/2 is an automorphism of the underlying cone of positive semidefinite matrices. Therefore, Mn−1 (w) ≻ 0 if and only if  −1/2  −1/2 Y := Diag(u′ ) M̄ Mn−1 (w)M̄ ⊤ Diag(u′ ) is positive definite. Now observe that Y = I − ρθ n ξξ ⊤ , where ξ := [Diag(u′ )]−1/2 M̄ ē. Hence, (2) Mn−1 (w) ≻ 0 ⇐⇒ ρθ n ξ ⊤ ξ < 1. ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 15 Next, using the fact that (M̄ ē)[S|1 ] = (−1)n−|S|−1 for all S ⊂ [n], we analyze ρθ n ξ ⊤ ξ which is equal to:     X X 1 1   = ρθ n  ρθ n  u[S|1 (n − |S| − ρ)θ |S|(1 − θ)n−|S| S⊂[n] S⊂[n]   ! n−1 X ρθ n n 1−θ i 1 = (1 − θ)n n−i−ρ i θ i=0  !  n−1 X n+1 1−θ i 2 ρθ n < (1 − θ)n (n + 1)(1 − ρ) θ i i=0 !      n+1 1−θ n 1 − θ n+1 1 2ρθ n − (n + 1) − = (1 − ρ)(n + 1)(1 − θ)n θ θ θ   ρ 2 [1 − (nθ + 1)(1 − θ)n ] = . 1−ρ (n + 1)θ(1 − θ)n Thus, if ρ ≤ (n+1)θ(1−θ)n 2−[(n−1)θ+2](1−θ)n , then Mn−1 (w) is positive definite.  We are now ready to prove Theorem 10. Proof of Theorem 10. It is obvious that (Pn,ρ )I = Pn,1 for all ρ ∈ (0, 1). Now suppose we are n2 −1 given integer n ≥ 2 and 0 < ρ ≤ 2nn+1 −n2 −1 . We prove our claim by showing that there exists n−1 n−1 θ > n where θē ∈ Las (Pn,ρ ). + A n where y[S|1 ] := θ |S| for all S ⊆ [n], then Lemma 12 implies Y := Mn (y)  0. Define y ∈ R It also implies that Y 1 = Mn−1 (w) where w|S|1 ] = ((n − |S|)(1 − θ) − ρ)θ k . To prove our claim, it suffices to show that there exists θ > n−1 n such that Mn−1 (w)  0. Since our upper bound on ρ is continuous in θ in a neighbourhood of θ = n−1 n , and the cone of positive definite matrices is the interior of the cone of positive semidefinite matrices, by (2), it suffices to show n−1 that Mn−1 (w) ≻ 0 when θ = n−1 n . Then by letting θ = n in (1) and simplifying, we obtain 2 n −1 guarantees Mn−1 (w) ≻ 0, and the claim follows.  that ρ ≤ 2nn+1 −n2 −1 dn−1 (Pn,ρ ) for some θ > n−1 (where Let p(n) denote the largest ρ > 0 where Mn−1 (y) ∈ Las n y is defined in the proof of Theorem 10). Figure 2 shows the value of logn (p(n)) for some small values of n, as well as the lower bound on p(n) given by Theorem 10. 3.2. The cropped hypercube Qn,ρ . Next, we turn our attention to the cropped hypercube     X X n Qn,ρ := x ∈ [0, 1] : (1 − xi ) + xi ≥ ρ, ∀S ⊆ [n] .   i∈S i6∈S Observe that, for every S ⊆ [n], its incidence vector violates the inequality corresponding to S in the description of Qn,ρ . Thus, we see that (Qn,ρ )I = ∅. Independently, Cook and Dash [CD01] and Goemans and the second author [GT01] showed that Qn,1/2 has LS+ -rank n. Subsequently, the authors showed in [AT16] that the SA+ -rank of Qn,1/2 is also n. In fact, the results therein readily imply that SAk+ (Qn,ρ ) = Qn,ρ−k/2 for all ρ ∈ (0, 1/2] and k ∈ [n]. Thus, it follows that Qn,ρ has SA+ -rank n for all ρ ∈ (0, 1/2]. 16 YU HIN (GARY) AU AND LEVENT TUNÇEL logn (p(n)) 2 4 6 0 −2 8 10 12 n −4 −6 −8 −10 −12 logn (p(n)) Lower bound by Thm. 10 Figure 2. Computational results and lower bounds for p(n). As for the Las-rank of Qn,1/2 , it is shown to be 1 for n = 2 in [Lau03], and 2 for n = 4 in [Che07]. While Las depends on the algebraic description of the initial relaxation, the following observation significantly simplifies the analysis of the Las-rank of Qn,ρ . Proposition 13. Suppose n, k are fixed positive integers and ρ ∈ (0, 1). Define the vector + w ∈ RAn where w[S|1 ] := (n − |S| − 2ρ)2−|S|−1 , ∀S ⊆ [n]. Then Lask (Qn,ρ ) 6= ∅ if and only if Mk (w)  0. d k (Qn,ρ ). Notice that every automorphism for Proof. Suppose Lask (Qn,ρ ) 6= ∅, and let Y ∈ Las the unit hypercube is also an automorphism for Qn,ρ . If we take these 2n n! automorphisms and apply them onto Y as outlined in the proof of Proposition 1, we obtain 2n n! matrices in d k (Qn,ρ ). Let Ȳ be the average of these matrices. Then by the symmetry of Qn,ρ , we know Las that Ȳ = Mk (y), where y[S|1 ] = 2−|S| , ∀S ⊆ [n]. d k (Qn,ρ ), Ȳ ∈ Las dk (Qn,ρ ), and thus satisfies (Las 2) for all of the 2n By the convexity of Las equalities defining Qn,ρ . In fact, due to the entries of P Ȳ , the matrix Ȳ j is the same for all 2n inequalities describing Qn,ρ . Thus, using the inequality ni=1 xi ≤ n − ρ and applying Lemma 12 with θ = 12 , we obtain that Ȳ j [S|1 , T |1 ] = (n − |S ∪ T | − 2ρ)2−|S∪T |−1 = Mk (w)[S|1 , T |1 ] for all S, T ⊆ [n], |S|, |T | ≤ k. Hence, we deduce that Lask (Qn,ρ ) 6= ∅ ⇒ Mk (w)  0. The converse can be proven by tracing the above argument backwards. First, it follows from Lemma 12 that Ȳ  0. Then, again, the matrix Ȳ j is exactly Mk (w) for all 2n inequalities d k (Qn,ρ ). Thus, we obtain that describing Qn,ρ . Since Mk (w)  0 by assumption, Ȳ ∈ Las 1 2 ē ∈ Lask (Qn,ρ ), and so Lask (Qn,ρ ) 6= ∅.  Thus, computing the Las-rank of Qn,ρ reduces to finding the largest k where the matrix Mk (w) defined in the statement of Proposition 13 is positive semidefinite (which would then imply that the Las-rank of Qn,ρ is k + 1). Using that, we are able to show the following: ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 17 Theorem 14. For every n ≥ 2, let q(n) be the largest ρ where Qn,ρ has Las-rank n. Then n+1 n ≤ q(n) ≤ n+1 . n+2 2 −n−3 2 −2 Proof. We first prove the lower bound. If we let θ = 12 in (1), we obtain that ρ ≤ 2n+2n+1 −n−3 implies Mn−1 (w)  0 where w[S|1 ] = (n − |S| − 2ρ)2−|S|−1 , ∀S ⊆ [n]. Thus, the claim follows from Proposition 13. n , then Qn,ρ has Las-rank at most n − 1. As for the upper bound, we show that if ρ > 2n+1 −2 + + Define x ∈ RAn where x[S|1 ] := (−2)|S| for all S ⊆ [n]. Also, let x′ denote the vector in RAn−1 obtained from x by removing the entry corresponding to [n]|1 . By Proposition 13, if we let w[S|1 ] = (n − |S| − 2ρ)2−|S|−1 for all S ⊆ [n] and show that x′⊤ Mn−1 (w)x′ < 0 whenever n ρ > 2n+1 , then Mn−1 (w) 6 0, and our claim follows. −2 Recall that Mn (w) = Z Diag(u)Z ⊤ where u[S|1 ] = (n − |S| − ρ)2−n for all S ⊆ [n]. Also, note that (Z ⊤ x)[S|1 ] = (−1)|S| for all S ⊆ [n]. Thus, x⊤ Mn (w)x = x⊤ Z Diag(u)Z ⊤ x 2 X  = (Z ⊤ x)[S|1 ] u[S|1 ] = S⊆[n] n  X i=0 = = On the other hand, x⊤ Mn (w)x = = x′⊤ (−2)n n i  (−1)i 2 (n − i − ρ)2−n  n2n − n2n−1 − ρ2n 2−n n − ρ. 2   ′   Mn−1 (w) −2−n ρē x (−2)n −2−n ρē⊤ −2−n ρ x′⊤ Mn−1 (w) + (−1)n+1 ρē⊤ −2−n ρx′⊤ ē +  (−1)n+1 ρ  x′ (−2)n  = x′⊤ Mn−1 (w)x′ + (−1)n+1 ρē⊤ x′ + (−1)n+1 ρx′⊤ ē + (−1)n+1 (−2)n ρ = x′⊤ Mn−1 (w)x′ + (2n − 2) ρ. (It is helpful to observe that ē⊤ x′ = (−1)n − (−2)n .) Hence, we combine the above and obtain that n x′⊤ Mn−1 (w)x′ = − (2n − 1)ρ, 2 n . This finishes the proof.  which is negative whenever ρ > 2n+1 −2 Therefore, akin to what Cheung showed for Pn,ρ , there does not exist a fixed ρ where Qn,ρ has Las-rank n for all n. Also, as with Pn,ρ , the Las-rank of Qn,ρ varies under the choice of ρ. For instance, Figure 3 illustrates the Las-rank for Qn,ℓ/1000 for ℓ ∈ [500] and several values of n. The pattern is similar for all other values of n we were able to test — the Las-rank is around n2 when ρ = 21 , and slowly rises to n as ρ approaches 0. Recently, related to the Figure 3, Kurpisz, √ Leppänen and Mastrolilli [KLM16] proved that the Lasserre rank of Qn,1/2 is between Ω( n) and n − Ω(n1/3 ). Also, recall that we let q(n) be the largest ρ where Qn,ρ has Las-rank n. It follows from 2n+1 is roughly bounded between 21 and 1. Note that since Las imposes Theorem 14 that nq(n) 18 YU HIN (GARY) AU AND LEVENT TUNÇEL Las-rank of Qn,ℓ/1000 12 10 8 n = 12 6 n=9 4 n=6 n=3 2 0 100 200 300 400 ℓ 500 Figure 3. The Las-rank of Qn,ρ for varying values of ρ := ℓ/1000, for n ∈ {3, 6, 9, 12}. as many positive semidefiniteness constraints as there are defining inequalities for the given relaxation (which there are exponentially many for Qn,ρ ), the relaxation Lask (Qn,ρ ) is not obviously tractable, even when k is a constant. Now, computing q(n) requires verifying whether d n−1 (Qn,ρ ), a set Lasn−1 (Qn,ρ ) is empty, which by definition of Las is the projection of Las of matrices of order Ω(2n ) × Ω(2n ) with Ω(2n ) positive semidefiniteness constraints. Instead of solving the feasibility problem of such a large number of variables and constraints, Proposition 13 uses the symmetries of Qn,ρ (as well as the fact that Las preserves symmetries and commutes with all automorphisms of the unit hypercube, as shown in Proposition 1) to reduce this task to checking the positive semidefiniteness of Mn−1 (w), a (2n − 1) × (2n − 1) matrix with known entries. Furthermore, notice that if Mn−1 (w) had an eigenvector x with negative eigenvalue, we could assume that x[S|1 ] = x[T |1 ] whenever |S| = |T |, due to the symmetries of the entries in Mn−1 (w). Hence, if we define the n-by-n matrix W whose rows and columns are indexed by {0, 1, . . . , n − 1} such that X W [i, j] := Mn−1 (w)[S|1 , T |1 ] S,T ⊆[n],|S|=i,|T |=j =    n−1 X n−1 n−1 −i−j−1 2 n i j k=0 i j k k n−1 k !    X n n −i−j n − ρ2 i j k=0 i j k k n k ! , then it follows that Mn−1 (w)  0 if and only if W  0. This reduction allows us to verify if Qn,ρ has Las-rank n by simply checking if the n-by-n matrix W is positive semidefinite. Using 2n+1 the reduction above, we computed nq(n) to within two decimal places for n ∈ {2, 3, . . . , 16}, as illustrated in Figure 4. As for the BZ′+ -rank of Qn,ρ , it was shown in [BZ04] that Qn,1/2 has BZ-rank 2, where BZ is a polyhedral operator dominated by BZ+ and BZ′+ . Thus, it follows that the BZ′+ -rank of ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 19 2n+1 nq(n) 1.4 1.2 Upper bound by Thm. 14 1 2n+1 nq(n) 0.8 0.6 Lower bound by Thm. 14 0.4 0.2 0 2 4 6 8 10 12 14 16 n  Figure 4. Computational results and possible ranges for q(n) := min ρ : Lasn−1 (Qn,ρ ) 6= ∅ . Qn,1/2 is at most 2. However, we remark that, as with the Lasserre operator, the Bienstock– Zuckerberg operators also require an explicitly given system of inequalities for the input set. In particular, the run-time of these operators depends on the size of the system (which, again, is exponential in n in the case of Qn,ρ ). Thus, BZk (Qn,ρ ) is not obviously tractable, even for k = O(1). On the other hand, operators such as SA+ , SA and BCC are able to produce tightened relaxations that are tractable as long as we have an efficient separation oracle of the input set (which does exist for the cropped hypercube — note that x ∈ Qn,ρ if and only if x ∈ [0, 1]n and P n n 1 i=1 |xi − 2 | ≤ 2 − ρ). 4. Integrality gaps of lift-and-project relaxations We conclude this paper by noting some interesting tendencies of the integrality gaps of some lift-and-project relaxations. First, given a compact, convex set P ⊆ [0, 1]n where PI 6= ∅ and vector c ∈ Rn , the integrality gap of P with respect to c is defined to be  max c⊤ x : x ∈ P γc (P ) := . max {c⊤ x : x ∈ PI } The integrality gap gives a measure of how “tight” the relaxation P is in the objective function direction of c. Here, we show that the integrality gap of Pn,ρ with respect to the all-ones is invariant under k iterations of several different operators. . Theorem 15. Foro every integer n ≥ 2, for every ρ ∈ (0, 1) and for every operator Γ ∈ n ˜ LS, LS+ , SA, SA+ , we have   (n − k)(1 − ρ) , γē Γk (Pn,ρ ) = 1 + (n − 1)(n − k + kρ) for every k ∈ {0, 1, 2, . . . , n}. Proof. We prove our claim by showing that n o n o ˜ k (Pn,ρ ) ≥ n − k + (k − 1)ρ ≥ max θ : θē ∈ SAk (Pn,ρ ) . (3) max θ : θē ∈ LS + n − k + kρ 20 YU HIN (GARY) AU AND LEVENT TUNÇEL Then the result follows from the dominance relationships between the operators. First, the claim is obvious when k = 0 or when k = n, and thus from here on we assume that k ∈ [n − 1]. Let P := Pn,ρ . We first prove the first inequality in (3). ˜ k (P ), we know that there exist coefficients aT and vectors vT ∈ [0, 1]n−k for Given θē ∈ LS each T ⊆ [k] where   X χT θē = aT . vT T ⊆[k] k ˜ (Here, χT is the incidence vector of T in {0, 1} .) Note that  the  operator LS requires that the χT aT ’s be nonnegative and sum up to 1. Also, note that is in P for all vT ∈ [0, 1]n−k vT whenever |T | < k. For T = [k], the constraint ē⊤ x ≤ n − ρ implies that ē⊤ vT ≤ n − k − ρ. Due to the symmetry of P , given one convex combination of θē, we could obtain many other convex combinations by applying any permutation on [n] that fixes [k]. If we take the average of all these combinations, we would obtain a “symmetric” one where aT = a′T and vT = vT′ whenever |T | = |T ′ |, and that vT ’s are all multiples of the all-ones vector. Thus, we may further assume that there are nonnegative real numbers ai , vi , i ∈ {0, 1, . . . , k} where i  k X ē , ai k (4) θē = vi ē i=0 such that the ai ’s sum to 1, 0 ≤ vi ≤ 1 for all i < k, and 0 ≤ vk ≤ n−k−ρ n−k . Thus, (4) is equivalent to saying that the point (θ, θ) ∈ R2 is a convex combination of the points in the sets n o  i n−k−ρ ( k , vi ) : i ∈ {0, 1, . . . , k − 1} , 0 ≤ vi ≤ 1 and (1, vi ) : 0 ≤ vi ≤ n−k . It is easy to see that the convex hull of these points in R2 form the polytope illustrated in Figure 5. x2 1 k−1 k ,1   x2 = x1 n−k+(k−1)ρ n−k+(k−1)ρ n−k+kρ , n−k+kρ    1, n−k−ρ n−k 0 1 x1 n o ˜ k (Pn,ρ ) to two dimensions. Figure 5. Reduction of finding max θ : θē ∈ LS Then it is easy to see that the largest θ where (θ, θ) is contained in the convex hull is obtained by the convex combination !    k−1  n−k+(k−1)ρ 1 kρ n−k n−k+kρ k . = n−k+(k−1)ρ n−k−ρ + 1 n − k + kρ n − k + kρ n−k n−k+kρ This establishes the upper bound on θ. ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS Next, we turn to show the second inequality in (3) by proving that n−k+(k−1)ρ n−k+kρ ē 21 ∈ SAk+ (P ) |S|ρ for every k. First, define y ∈ A+ n where y[S|1 ] := 1 − n−k+kρ for every S ⊆ [n]. We first show that Mn (y)  0. By Lemma 11, we know that Mn (y) = Z Diag(u)Z ⊤ where u is the vector with entries   n−|S|  X X n − |S| (|S| + j)ρ |T \S| j u[S|1 ] = (−1) y[S|1 ] = (−1) 1 − j n − k + kρ j=0 T ⊇S  if |S| ≤ n − 2;  0 ρ if |S| = n − 1; =  n−k+kρnρ 1 − n−k+kρ if S = [n]. nρ ≥ 0 ⇐⇒ (n − k)(ρ − 1) ≤ 0, which does hold as n ≥ k and ρ < 1. Hence, Note that 1 − n−k+kρ since u ≥ 0, we deduce that Mn (y)  0, and in particular Mk (y)  0. + Next, define L ∈ RAk ×Ak where  (−1)|S| if S ∪ T = U ; L[S|1 ∩ T |0 , U |1 ] := 0 otherwise, k c + (P ). First, Mk (y)  0 implies that Y  0. and let Y := LMk (y)L⊤ . We claim that Y ∈ SA Also, (SA+ 1) holds as Y [F, F] = 1, and it is not hard to see that Y ≥ 0, as every entry ρ iρ in Y is either 0, n−k+kρ or 1 − n−k+kρ for some integer i ∈ {0, . . . , n}. Next, we check that x̂(Y eβ ) ∈ K(P ) for all β ∈ Ak . Given β = S|1 ∩ T |0 , x̂(Y eβ ) is the zero vector whenever ρ (ē − ei ) whenever T = {i} for some i ∈ [n]. In both cases, |T | ≥ 2, and is the vector nρ+1−ρ Pn i=1 Y [i|1 , β] ≤ (n − ρ)Y [F, β] easily holds. Finally, suppose β = S|1 for some S ⊆ [n] where |S| ≤ k. Observe that ( n−k+(k−|S|)ρ if α = F or α = i|1 where i ∈ S; n−k+kρ Y [α, S|1 ] = n−k−(k−|S|−1)ρ otherwise. n−k+kρ Now     n − k + (k − |S|)ρ n − k + (k − |S| − 1)ρ Y [i|1 , S|1 ] = |S| + (n − |S|) n − k + kρ n − k + kρ i=1   n − k + (k − |S|)ρ ≤ (n − ρ) n − k + kρ = (n − ρ)Y [F, S|1 ]. n X Thus, x̂(Y eβ ) ∈ K(P ) in this case as well. Finally, it is not hard to see that the entries of Y satisfy (SA+ 3), (SA+ 4) and (SA+ 5). This completes our proof.  Figure 6 illustrates the integrality gaps of SAk+ (Pn,ρ ) for various values of k and ρ in the case n = 10 (the behaviour is similar for other values of n). In general, when ρ is close to 1, the gap decreases at an almost-linear rate towards 1. On the other hand, when ρ is small, the 1 as k increases to n − 1, and then integrality gap of SAk+ (Pn,ρ ) stays relatively close to 1 + n−1 th abruptly drops to 1 at the n iteration, where we obtain the integer hull. Again, it follows from Theorem 15 that these gaps would be identical if we replaced SA+ by any operator Γ where ˜ SA+ dominates Γ and Γ dominates LS. 22 YU HIN (GARY) AU AND LEVENT TUNÇEL   γē SAk+ (P10,ρ ) 1.12 ρ = 0.01 1.1 ρ = 0.1 1.08 1.06 ρ = 0.5 1.04 1.02 ρ = 0.9 1 0 1 2 3 4 5 6 7 8 9 10 k Figure 6. Integrality gaps of SAk+ (P10,ρ ) for various k and ρ. We also note that Theorem 15 implies Proposition 3. Moreover, n the techniques oused for k ˜ proving the first inequality in (3) can be extended to compute max θ : θē ∈ LS (Pn,ρ ) for any non-integer ρ ∈ (0, n), which would imply Proposition 5. While the integrality gap for Qn,ρ is undefined (as its integer hull is empty for all ρ > 0), we see a similar distinction between its SA+ and Las relaxations. Note that since all lift-and-project operators we have studied preserve containment, starting with a tighter initial relaxation might offer a lift-and-project operator a head start and yield stronger relaxations in fewer iterations. However, in the case of Qn,ρ , different lift-and-project operators utilize this head start in different ways. As mentioned earlier, we know that SAk+ (Qn,ρ ) = Qn,ρ−k/2 for all ρ ∈ (0, 1/2] and for all k = [n]. Thus, given ρ, ρ′ where 0 < ρ < ρ′ ≤ 12 ,  SAk+ (Qn,ρ ) = Qn,(ρ+k/2) ⊃ Qn,(ρ′ +k/2) = SAk+ Qn,ρ′ , for all k ∈ [n − 1]. However, they still converge to the integer hull in the same number of steps. On the other hand, as shown in Theorem 13 and Figure 3, starting with a larger ρ can help Las arrive at the integer hull in fewer iterations, similar to what we saw with Pn,ρ . Thus, at least in the case of Pn,ρ and Qn,ρ where ρ ∈ (0, 1), all aforementioned operators that are no stronger than SA+ perform pretty much equally poorly, while deploying Las does achieve some tangible improvements in rank (at least when ρ is not extremely small). Granted, since the number of inequalities imposed by most lift-and-project methods are superpolynomial in n √ after Ω(log(n)) rounds, an operator managing to return the integer hull in, say, Ω( n) iterations is already exerting exponential effort. In that case, claiming that this operator performs better than another that requires (say) Ω(n) rounds is somewhat a moot point in practice, at the time of this writing. Of course, there do exist examples where a stronger lift-and-project operator manages to return a tractable relaxation and outperforms exponential effort by a weaker operator: We showed in Propositions 4 and 5 that when ρ = n − O(1), SA+ would return the integer hull in ELEMENTARY POLYTOPES WITH HIGH LIFT-AND-PROJECT RANKS 23 ˜ requires Ω(n) rounds. Another such instance is the following: Given O(1) iterations, while LS a graph G = (V, E), consider its fractional stable set polytope, which is defined as  FRAC(G) = x ∈ [0, 1]V : xi + xj ≤ 1, ∀ {i, j} ∈ E . When G is the complete graph on n vertices, it is well known that for hierarchies of polyhedral lift-and-project relaxations (including SA), the integrality gap (with respect to ē) starts at n2 , then gradually decreases, and reaches 1 after Ω(n) iterations. On the other hand, it takes semidefinite operators such as LS+ , SA+ and Las exactly one iteration to reach the stable set polytope of Kn , and thus the corresponding integrality gaps for these operators would dive from n 2 to 1 in just one iteration. This raises the natural question of whether, in general, there is some efficient way where we could diagnose a given problem and determine the “best” lift-and-project method for the job. One step in that direction is through studying how various methods perform on different problem classes. Such studies would hopefully provide us better guidance on when it is worthwhile to apply an operator that is more powerful but has a higher per-iteration computational cost. To take this point further, perhaps one could build a shape-shifting operator that adapts to the given problem in some way. Bienstock and Zuckerberg [BZ04] devised the first operators that generate different variables for different relaxations (or even different algebraic descriptions of the same relaxation). They showed that this flexibility can be very useful in attacking relaxations of some set covering problems. Thus, perhaps tight relaxations for other hard problems can be found similarly by building a lift-and-project operator with suitable adaptations. References [AT16] [Au14] [Bal74] [Bal98] [BCC93] [BDG16] [BZ04] [CCH89] [CD01] [Che07] [CL01] [GPT10] [GT01] [KLM15] [KLM16] Yu Hin Au and Levent Tunçel. A comprehensive analysis of polyhedral lift-and-project methods. SIAM Journal on Discrete Mathematics, 30(1):411–451, 2016. Yu Hin Au. A Comprehensive Analysis of Lift-and-Project Methods for Combinatorial Optimization. PhD thesis, University of Waterloo, 2014. Egon Balas. Disjunctive programming: properties of the convex hull of feasible points. Management Sciences Research Report, (348), 1974. Egon Balas. Disjunctive programming: properties of the convex hull of feasible points. Discrete Appl. Math., 89(1-3):3–44, 1998. Egon Balas, Sebastián Ceria, and Gérard Cornuéjols. A lift-and-project cutting plane algorithm for mixed 0-1 programs. Math. Programming, 58(3, Ser. A):295–324, 1993. Merve Bodur, Sanjeeb Dash, and Oktay Günlük. A new lift-and-project operator. 2016. Daniel Bienstock and Mark Zuckerberg. Subset algebra lift operators for 0-1 integer programming. SIAM Journal on Optimization, 15(1):63–95, 2004. Vašek Chvátal, William Cook, and Mark Hartmann. On cutting-plane proofs in combinatorial optimization. Linear algebra and its applications, 114:455–499, 1989. William Cook and Sanjeeb Dash. On the matrix-cut rank of polyhedra. Mathematics of Operations Research, 26(1):19–30, 2001. Kevin K. H. Cheung. Computation of the Lasserre ranks of some polytopes. Mathematics of Operations Research, 32(1):88–94, 2007. Gérard Cornuéjols and Yanjun Li. On the rank of mixed 0, 1 polyhedra. In International Conference on Integer Programming and Combinatorial Optimization, pages 71–77. Springer, 2001. João Gouveia, Pablo A. Parrilo, and Rekha R. Thomas. Theta bodies for polynomial ideals. SIAM Journal on Optimization, 20(4):2097–2118, 2010. Michel X. Goemans and Levent Tunçel. When does the positive semidefiniteness constraint help in lifting procedures? Mathematics of Operations Research, 26(4):796–815, 2001. Adam Kurpisz, Samuli Leppänen, and Monaldo Mastrolilli. On the hardest problem formulations for the 0/1 Lasserre hierarchy. arXiv preprint arXiv:1510.01891, 2015. Adam Kurpisz, Samuli Leppänen, and Monaldo Mastrolilli. Tight sum-of-squares lower bounds for binary polynomial optimization problems. arXiv preprint arXiv:1605.03019, 2016. 24 [Las01] [Lau03] [LS91] [SA90] [Zuc03] YU HIN (GARY) AU AND LEVENT TUNÇEL Jean B. Lasserre. An explicit exact SDP relaxation for nonlinear 0-1 programs. In Integer programming and combinatorial optimization (Utrecht, 2001), volume 2081 of Lecture Notes in Comput. Sci., pages 293–303. Springer, Berlin, 2001. Monique Laurent. A comparison of the Sherali–Adams, Lovász-Schrijver, and Lasserre relaxations for 0-1 programming. Mathematics of Operations Research, 28(3):470–496, 2003. László Lovász and Alexander Schrijver. Cones of matrices and set-functions and 0-1 optimization. SIAM Journal on Optimization, 1(2):166–190, 1991. Hanif D. Sherali and Warren P. Adams. A hierarchy of relaxations between the continuous and convex hull representations for zero-one programming problems. SIAM Journal on Discrete Mathematics, 3(3):411–430, 1990. Mark Zuckerberg. A Set Theoretic Approach to Lifting Procedures for 0,1 Integer Programming. PhD thesis, Columbia University, 2003.
8cs.DS
Mutable WadlerFest DOT Marianna Rapoport and Ondřej Lhoták arXiv:1611.07610v1 [cs.PL] 23 Nov 2016 {mrapoport, olhotak}@uwaterloo.ca University of Waterloo Abstract. The Dependent Object Types (DOT) calculus aims to model the essence of Scala, with a focus on abstract type members, pathdependent types, and subtyping. Other Scala features could be defined by translation to DOT. Mutation is a fundamental feature of Scala currently missing in DOT. Mutation in DOT is needed not only to model effectful computation and mutation in Scala programs, but even to precisely specify how Scala initializes immutable variables and fields (vals). We present an extension to DOT that adds typed mutable reference cells. We have proven the extension sound with a mechanized proof in Coq. We present the key features of our extended calculus and its soundness proof, and discuss the challenges that we encountered in our search for a sound design and the alternative solutions that we considered. Keywords: DOT calculus, mutation, path-dependent types, Scala 1 Introduction Abstract type members, parametric polymorphism, and mix-in composition are only a few features of Scala’s complex type system. The presence of pathdependent types has made it particularly hard to understand the interaction between the numerous language components and to come up with a precise formalization for Scala. The lack of a theoretical foundation for the language has in turn led to unsound design choices (Odersky, 2016; Amin, 2016b; Amin and Tate, 2016). To model the interaction between Scala’s core features soundly, researchers have worked for over ten years to devise formal calculi (Odersky et al., 2003; Cremet et al., 2006; Moors et al., 2008; Amin et al., 2012, 2014; Rompf and Amin, 2015, 2016a; Amin et al., 2016; Rompf and Amin, 2016b; Amin, 2016a). We refer to the specific calculus of Amin et al. (2016) as WadlerFest DOT because several different calculi have used the name DOT. WadlerFest DOT models the key components of the Scala type system, such as type members, path-dependent types, and subtyping. The eventual intent is to formalize other constituents of the full language, such as classes and inheritance, by a translation to the core features of DOT. However, WadlerFest DOT is still lacking some fundamental Scala features, one of which is mutation. Without mutation, it is difficult to model (mutable) variables and fields, or to reason about side effects in general. 2 M. Rapoport, O. Lhoták Interestingly, mutation is even necessary to model a sound class initialization order for immutable fields, which are mutated once when they are initialized. At the moment, Scala’s complex initialization order can lead to programs with unintuitive behaviour of fields (Petrashko, 2016); in particular, current versions of the Scala compiler permit programs in which immutable fields are read before they have been initialized. In order for the Scala community to discuss alternative designs of the initialization order, it needs a means to specify candidate designs precisely and evaluate them formally. A sound formalization of initialization order, in turn, requires reasoning about overwriting of class members that first hold a null value from the time that they are allocated to the time that they are initialized, which is not directly possible in WadlerFest DOT. This paper presents the Mutable DOT calculus, which is an extension to WadlerFest DOT with typed mutable references. To that end, we augment the calculus with a mutable heap and the possibility to create, update, and dereference mutable memory cells, or locations. A Scala mutable variable (var) can then be modelled by an immutable variable (already included in WadlerFest DOT), containing a mutable memory cell. For example, a Scala object object O { val x = 1 var y = 2 } can be represented in mutable-DOT pseudocode as follows:1 new {this: {x: Int} ∧ {y: Ref Int}} // structural type of object {x = 1} ∧ {y = ref 2 Int} // definitions in object body An unusual characteristic of our heap implementation is that it maps locations to variables instead of values. This design choice is induced by WadlerFest DOT’s type system, which disallows subtyping between recursive types. We show how, as a result, storing values on the heap would significantly limit the expressiveness of our calculus, and explain the correctness of storing variables on the heap. It is not surprising that adding mutable references to a DOT calculus is possible. Indeed, in an update to their technical report, Rompf and Amin (2016a) report that they added them to a different DOT calculus with a big-step semantics. WadlerFest DOT is well suited as a basis for future extension, both to specify existing higher-level Scala features by translation to a core calculus, and to formally explore new proposed extensions to Scala. It comes with a soundness proof formalized and verified in Coq. WadlerFest DOT is simpler than the other full DOT calculi, and its semantics is small-step, so the soundness proof is based on the familiar approach of progress and preservation (Wright and Felleisen, 1994). 1 The Scala type system is nominal while WadlerFest DOT is (mostly) structural. Therefore, the Scala example assigns the object a name, while WadlerFest DOT does not. Mutable WadlerFest DOT 3 The contributions of this paper are: – We define an operational semantics and type system for Mutable DOT, an extension of the small-step WadlerFest DOT calculus with mutable references. – We provide a mechanized type safety proof in Coq, in the form of an extension of the original WadlerFest DOT proof, which is suitable to be used for extensions of WadlerFest DOT that require mutation.2 – We discuss the challenges that we encountered in adding mutation to WadlerFest DOT, and the design choices that we made to overcome them. We conjecture that this reported experience will be helpful for adding mutation to other DOT calculi, including the OOPSLA DOT, which is to appear (Rompf and Amin, 2016b). The rest of the paper is organized as follows. Section 2 is a brief introduction to the original WadlerFest DOT calculus. Section 3 presents the mutable DOT calculus Mutable DOT, and Section 4 outlines its type-safety proof. We discuss Mutable DOT’s design in Section 5 and present an example of using mutable references in Mutable DOT in Section 6. Related work is discussed in Section 7. 2 The WadlerFest DOT Calculus We introduce the features of the WadlerFest DOT calculus through an example. Suppose we want to keep track of fish that live in aquariums. In Scala, we could write: object AquariumModule { trait Aquarium { type Fish val fish : List [ Fish ] } def addFish(a: Aquarium, f: a. Fish) = new Aquarium { type Fish = a.Fish fish = a. fish + f } val piranhas = new Aquarium { type Fish = Piranha fish = List .empty[Piranha] } val goldfish = new Aquarium { type Fish = Goldfish 2 The mechanized proof can be found in our fork of the WadlerFest DOT proof repository (see https://github.com/amaurremi/dot-calculus). 4 M. Rapoport, O. Lhoták fish = List .empty[Goldfish ] } } This program lets us add a fish gf to the goldfish aquarium: val gf : Goldfish = ... addFish(goldFish , gf) but it will result in a type error when trying to add gf to the piranha aquarium: addFish(piranhas , gf) // type error : expected: piranhas . Fish , actual : goldFish . Fish The reason the goldfish is protected from the piranhas is that the type Fish is path dependent, i.e. specific to the run-time Aquarium object that the fish belongs to. This allows the addFish method to guarantee at compile time that an aquarium a accepts only fish of type a.Fish. The syntax, reduction semantics, and type system of the WadlerFest DOT calculus can be seen in Figures 1, 2, 3, and 4. The shaded parts are our mutationrelated changes and can be ignored for now. As a first attempt to define Aquarium in WadlerFest DOT, we can make it an intersection of two types: { Aquarium = {Fish: ⊥..⊤} ∧ { fish : List } } The first type, {Fish : ⊥..⊤}, declares a type member Fish with lower bound ⊥ (Nothing) and upper bound ⊤ (Any). The second type, {fish : List}, is a field declaration of type List that represents the list of fish in the aquarium. The type List is assumed to be defined in a library and contains a type member A for list elements. A problem with the current Aquarium implementation is that it does not say that the type of elements in the fish list should be Fish. More specifically, the list elements should have the Fish type of the Aquarium runtime object to which the list belongs. To let the Aquarium type refer to its own runtime object a, we make Aquarium a recursive type: { Aquarium = µ(a: {Fish: ⊥..⊤} ∧ { fish : List ∧ {A: a. Fish .. a. Fish}}} Here, to express that the type Fish should belong to the object a, we use the type selection a.Fish. The type a.Fish is then used as a refinement of List’s element type A. In this way, the list can contain only the fish that are allowed in the aquarium a. We can now define addFish as a function that takes an aquarium a and a fish f of type a.Fish, and creates a new aquarium a2: { addFish = λ(a: aq.Aquarium).λ(f: a. Fish ). ν(a2: aq.Aquarium ∧{ Fish: a. Fish .. a. Fish }) { Fish = a.Fish fish = ... }} Mutable WadlerFest DOT 5 The construct ν(x : T )d creates a new object of type T with a self-variable x and definitions d. In this case, the definitions are used to initialize the Fish type and fish list of the new aquarium. The Fish type is assigned a.Fish. The new fish list needs to append the fish f to the old a.fish list. To be able to add an element to a list, we need access to an append method, which we will get from List. Suppose that the List type is defined in a collections library. It can be defined as a recursive type µ(list : . . . ) that declares an element type A and an append function. append takes a parameter a of the element type list.A and returns a List of elements that are subtypes of a.A: let collections = ν(col : { List : µ( list : ({A: ⊥..⊤} ∧ {append: ∀(a: list .A)(col . List ∧ {A: ⊥ .. a.A}))}) ... in ... With an append method on Lists, we can fully implement the addFish method. The field a2.fish should be defined as a.fish.append(f). However, since WadlerFest DOT uses administrative normal form (ANF), before performing any operations on terms, we have to bind the terms to variables: in fish = let oldFish = a. fish let append = oldFish.append in append f For better readability, we introduce the following abbreviations (similar ones are used in the WadlerFest DOT paper): {A} ≡ {A : ⊥..⊤} {A : T } ≡ {A : T..T } {A <: T } ≡ {A : ⊥..T } {D1 ; D2 } ≡ {D1 } ∧ {D2 } t u ≡ let x = t in let y = u in x y t.L ≡ let x = t in x.L ν(x)d : T ≡ ν(x : T )d where D1 , D2 are declarations or definitions of either fields or types, and L is a label of a type or field. With those abbreviations, the full aquarium program example looks as follows: let collections = ν(col) { ... }: { List : µ( list : (A; append: ∀(a: list .A)(col . List ; A <: a.A))} in ν(aq) { Aquarium = µ(a: {Fish; fish : { collections . List ; A: a. Fish }}); addFish = λ(a: aq.Aquarium).λ(f: a. Fish ). ν(a2) { Fish = a.Fish fish = a. fish .append f }: {aq.Aquarium; Fish: a. Fish} }: {Aquarium: µ(a: {Fish ; fish : { collections . List ; A: a. Fish }}); 6 M. Rapoport, O. Lhoták addFish: ∀(a: aq.Aquarium)∀(f: a. Fish) {aq.Aquarium; Fish: a. Fish}} 3 Mutation in WadlerFest DOT In this section, we present Mutable DOT, our extension of the WadlerFest DOT calculus with mutable references. The changes in the syntax are inspired by Pierce’s extension of the simply-typed lambda calculus with references (Pierce, 2002, Chapter 13). Throughout this paper, we highlight the changes necessary to convert WadlerFest DOT into Mutable DOT in grey. 3.1 Abstract syntax To support mutation, we augment the WadlerFest DOT syntax with references that point to mutable memory cells, or locations, as shown in Figure 1. Locations are a new kind of value that is added to the syntax, and are denoted as l. The syntax comes with three new terms to support the following reference operations: – ref x T creates a new reference of type T in the store and initializes it with the variable x. Section 5.3 explains why reference expressions need to contain a declared type T , unlike the references in Pierce’s book. – !x reads the contents of a reference x. – x := y updates the contents of a reference x with the variable y. The operations that create, read, and update references operate on variables, not arbitrary terms, in order to preserve ANF. Newly-created references become locations, or memory addresses, denoted as l. Locations are stored in the store, denoted as σ, which serves as a heap. The store is a map from locations to variables. This differs from the common definition of a store, which maps locations to values. We discuss the motivation for this design choice in Section 5.1. In order to preserve the commonly expected intuitive behaviour of a store, we must be sure that while a variable is in the store, it does not go out of scope or change its value. We show this in Section 5.2. Updating a store σ that contains a mapping l 7→ x with a new mapping l 7→ y overwrites x with y: ′ (σ[l → x])(l ) = ( x if l = l′ ′ σ(l ) otherwise. Locations are typed with the reference type Ref T . The underlying type T indicates that the location stores variables of type T . Mutable WadlerFest DOT Ref T σ ::= Store 7 reference type v ::= Value empty store ν(x : T )d object σ[l 7→ x] extended or updated store λ(x : T ).t lambda ∅ l x, y, z Variable a, b, c Term member A, B, C Type member S, T, U ::= Type ⊤ top type ⊥ bottom type {a : T } field declaration {A : S..T } x.A type projection S∧T intersection µ(x : T ) s, t, u ::= recursive type ∀(x : S)T dependent function Term x variable v value x.a selection xy application let x = t in u let binding ref x T !x type declaration location x := y d ::= reference dereferencing assignment Definition {a = t} field definition {A = T } type definition d ∧ d′ aggregate definition Fig. 1: Abstract syntax of Mutable DOT 8 M. Rapoport, O. Lhoták To write concise Mutable DOT programs, we extend the abbreviations from Section 2 with the following rules: ref t T ≡ let x = t in ref x T t := u ≡ let x = t in let y = u in x := y !t ≡ let x = t in !x t; u ≡ let x = t in u 3.2 Reduction rules Since the meaning of an Mutable DOT term depends on the store contents, we represent a program state as a tuple σ | t, denoting a term t that can point to memory contents in the store σ. The new reduction semantics is shown in Figure 2: – A newly created reference ref x T reduces to a fresh location with an updated store that maps l to x (Ref). – Dereferencing a variable using !x is possible if x is bound to a location l by a let expression. If so, !x reduces to σ(l), the variable stored at location l (Deref). – Similarly, if x is bound to l by a let, then the assignment operation x := y updates the store at location l with the variable y (Store). Programs written in the Mutable DOT calculus generally do not contain explicit location values in the original program text. Locations are included as values in the Mutable DOT syntax only because terms such as ref x T will evaluate to fresh locations during reduction. The remaining rules are the WadlerFest DOT evaluation rules, with the only change that they pass along a store. 3.3 Type rules The Mutable DOT typing rules, depicted in Figure 3, depend on a store typing Σ in addition to a type environment Γ . A store typing maps locations to the types of the variables that they store. The store typing spares us the need to re-typecheck locations and allows to typecheck cyclic references (Pierce, 2002). As an example, the following Mutable DOT program cannot be easily typechecked without an explicit store typing (using only the runtime store and the type environment):   let id = λ(x : ⊤).x in let r = ref id (⊤ → ⊤) in  p= let id′ = λ(x : ⊤).(!r) x in r := id′ Mutable WadlerFest DOT e ::= [] | let x = [] in t | let x = v in e Evaluation context σ | t 7−→ σ ′ | t′ σ | e[t] 7−→ σ ′ | e[t′ ] v = λ(z : T ).t σ | let x = v in e[x y] 7−→ σ | let x = v in e[[y/z ] t] v = ν(x : T ) . . . {a = t} . . . σ | let x = v in e[x.a] 7−→ σ | let x = v in e[t] σ | let x = y in t 7−→ σ | [y/x] t (Term) (Apply) (Project) (Let-Var) σ | let x = let y = s in t in u 7−→ σ | let y = s in let x = t in u (Let-Let) l∈ / dom(σ) σ | ref x T 7−→ σ[l 7→ x] | l (Ref) σ | let x = l in e[x := y] 7−→ σ[l 7→ y] | let x = l in e[y] (Store) σ(l) = y σ | let x = l in e[!x] 7−→ σ | let x = l in e[y] (Deref) Fig. 2: Reduction rules for Mutable DOT 9 10 M. Rapoport, O. Lhoták Γ, Σ ⊢ x : µ(x : T ) Γ, Σ ⊢ x : T Γ ::= ∅ | (Γ, x : T ) (Rec-E) Type environment Σ Γ, Σ ⊢ x : T ::= ∅ | (Σ, l 7→ T ) Γ, Σ ⊢ x : U Γ, Σ ⊢ x : T ∧ U (&-I) Store typing Γ, Σ ⊢ t : T Γ (x) = T (Var) Γ, Σ ⊢ x : T Γ, Σ ⊢ T <: U Γ, Σ ⊢ t : U (Sub) Σ(l) = T Γ, Σ ⊢ l : Ref T (Loc) Γ, Σ ⊢ t : T Γ, Σ ⊢ {a = t} : {a : T } (Γ, x : T ), Σ ⊢ t : U x∈ / fv(T ) Γ, Σ ⊢ λ(x : T ).t : ∀(x : T )U (All-I) Γ, Σ ⊢ x : ∀(z : S)T (Fld-I) Γ, Σ ⊢ y : S Γ, Σ ⊢ x y : [y/z ] T (All-E) (Γ, x : T ), Σ ⊢ d : T Γ, Σ ⊢ ν(x : T )d : µ(x : T ) Γ, Σ ⊢ {A = T } : {A : T..T } (Typ-I) Γ, Σ ⊢ d1 : T2 Γ, Σ ⊢ d1 : T1 dom(d1 ), dom(d2 ) disjoint Γ, Σ ⊢ d1 ∧ d2 : T1 ∧ T2 (AndDef-I) ({}-I) Γ, Σ ⊢ x : T Γ, Σ ⊢ ref x T : Ref T Γ, Σ ⊢ x : {a : T } (Ref-I) ({}-E) Γ, Σ ⊢ x.a : T Γ, Σ ⊢ t : T x∈ / fv(U ) (Γ, x : T ), Σ ⊢ u : U Γ, Σ ⊢ x : Ref T Γ, Σ ⊢ !x : T (Ref-E) Γ, Σ ⊢ let x = t in u : U (Let) Γ, Σ ⊢ x : T Γ, Σ ⊢ x : µ(x : T ) (Rec-I) Γ, Σ ⊢ x : Ref T Γ, Σ ⊢ y : T := Γ, Σ ⊢ x y: T Fig. 3: Type rules for Mutable DOT (Asgn) Mutable WadlerFest DOT 11 Starting with an empty store, after two reduction steps we get ∅ | p 7−→∗ {l → id′ } | p′ , where let id = λ(x : ⊤).x in  l in let r =  p′ =  let id′ = λ(x : ⊤).(!r) x in   id′ We would see by looking into the store that to typecheck the location l, we needed to typecheck id′ . id′ depends on r, which in turn refers to the location l, creating a cyclic dependency. We therefore augment our typing rules with a store typing, allowing us to typecheck each location once and for all, at the time of a reference creation. In the example, we would know that l is mapped to (⊤ → ⊤) from the let-binding of r and remember this typing in Σ. To express that a term t has type T under the type environment Γ and store typing Σ, we write Γ, Σ ⊢ t : T . The typing rules for Mutable DOT are shown in Figure 3. The WadlerFest DOT rules are intact except that all typing derivations carry a store typing. The new rules related to mutable references are as follows: – We typecheck locations by looking them up in the store typing. If, according to Σ, a location l stores a variable of type T , then l has type Ref T (Loc). – A newly created reference ref x T can be initialized with the variable x if x has type T . In particular, if x’s precise type U is a subtype of T , then x has type T by Sub, so we can still create a ref x T (Ref-I). – Conversely, dereferencing a variable of a reference type Ref T yields the type T (Ref-E). – Finally, if x is a reference of type Ref T , we are allowed to store a variable y into it if y has type T . To avoid the need to add a Unit type to the type system, we define an assignment x := y to reduce to y, so the type of the assignment is T (Asgn). 3.4 Subtyping rules The subtyping rules of Mutable DOT include an added store typing, and a subtyping rule for references. The rules are shown in Figure 4. Subtyping between reference types is invariant: usually, Ref T <: Ref U if and only if T = U . Invariance is required because reference types need to be (i) covariant for reading, or dereferencing, and (ii) contravariant for writing, or assignment. However, in WadlerFest DOT, co- and contra-variance between types does not imply type equality: the calculus contains examples of types that are not equal, yet are equivalent with respect to subtyping. For example, for any types 12 M. Rapoport, O. Lhoták (Top) Γ, Σ ⊢ T <: ⊤ Γ, Σ ⊢ x : {A : S..T } Γ, Σ ⊢ x.A <: T (Sel-<:) (Bot) Γ, Σ ⊢ ⊥ <: T Γ, Σ ⊢ S <: T Γ, Σ ⊢ S <: U Γ, Σ ⊢ S <: T ∧ U Γ, Σ ⊢ S <: T (<:-And) (Refl) Γ, Σ ⊢ T <: T Γ, Σ ⊢ T <: U Γ, Σ ⊢ S <: U (Trans) Γ, Σ ⊢ T ∧ U <: T (And1 -<:) Γ, Σ ⊢ T <: U Γ, Σ ⊢ {a : T } <: {a : U } (Fld-<:-Fld) Γ, Σ ⊢ S2 <: S1 Γ, Σ ⊢ T1 <: T2 Γ, Σ ⊢ {A : S1 ..T1 } <: {A : S2 ..T2 } (Typ-<:-Typ) Γ, Σ ⊢ T ∧ U <: U (And2 -<:) Γ, Σ ⊢ S <: T Γ, Σ ⊢ S <: U Γ, Σ ⊢ S <: T ∧ U (<:-And) Γ, Σ ⊢ x : {A : S..T } Γ, Σ ⊢ S <: x.A (<:-Sel) Γ, Σ ⊢ S2 <: S1 (Γ, x : S2 ), Σ ⊢ T1 <: T2 Γ, Σ ⊢ ∀(x : S1 )T1 <: ∀(x : S2 )T2 (All-<:-All) Γ, Σ ⊢ T <: U Γ, Σ ⊢ U <: T Γ, Σ ⊢ Ref T <: Ref U ( Ref-Sub ) Fig. 4: Subtyping rules for Mutable DOT Mutable WadlerFest DOT 13 T and U , T ∧ U <: U ∧ T <: T ∧ U . Yet, T ∧ U 6= U ∧ T . Therefore, subtyping between reference types requires both covariance and contravariance: Γ, Σ ⊢ T <: U Γ, Σ ⊢ U <: T Γ, Σ ⊢ Ref T <: Ref U 4 (Ref-Sub) Type Safety In this section, we outline the soundness proof of Mutable DOT as an extension of the WadlerFest DOT soundness proof (Amin et al., 2016). To formulate the progress theorem, Amin et al. introduce the notion of an answer : n ::= x | v | let x = v in n. The type safety of Mutable DOT is expressed as an extension to the WadlerFest DOT progress and preservation theorems. The theorems include a store σ and a store typing Σ, where Σ, unlike Γ , can be non-empty. Theorem 1 (Progress). If ∅, Σ ⊢ t : T , then either t is an answer, or for any store σ such that ∅, Σ ⊢ σ , there is a term t′ and a store σ ′ such that σ | t 7−→ σ ′ | t′ . Theorem 2 (Preservation). If – ∅, Σ ⊢ t : T – ∅, Σ ⊢ σ – σ | t 7−→ σ ′ | t′ , then for some Σ ′ ⊇ Σ , – ∅, Σ ′ ⊢ t′ : T – ∅, Σ ′ ⊢ σ ′ . Below we describe how to extend the WadlerFest DOT proof to prove Mutable DOT soundness. Our paper comes with a mechanized Coq proof, which is also an extension of the WadlerFest DOT proof. The Coq proof can be found in our fork of the WadlerFest DOT proof repository: https://github.com/amaurremi/dot-calculus 4.1 Main ideas of the WadlerFest DOT soundness proof We start by introducing the key ideas of the WadlerFest DOT proof. We will later show how to adapt them to prove Mutable DOT type safety. 14 M. Rapoport, O. Lhoták Bad bounds One of the challenges of proving DOT sound is the problem of “bad bounds” (Amin et al., 2012). For every pair of arbitrary types T and U , there exists an environment Γ such that Γ ⊢ T <: U . Specifically, when type checking the function λ(y : {A : T..U }).t, the body t of the function is type checked in a type environment Γ in which Γ (y) = {A : T..U }. Then Γ ⊢ T <: y.A and Γ ⊢ y.A <: U , so Γ ⊢ T <: U (using (<:-Sel), (Sel-<:), and (Trans)). In particular, if T and U are chosen as ⊤ and ⊥, respectively, then we get Γ ⊢ ⊤ <: ⊥. Since every type is a subtype of ⊤ and a supertype of ⊥, this means that all types become equivalent with respect to subtyping in this environment. Thus, if arbitrary type environments were possible, the type system would collapse, all types would be subtypes of each other, and types would give us no information about terms. To avoid bad bounds, Amin et al. observe that such a type environment cannot occur for an evaluation context during a concrete execution of the program. Specifically, if t′ is a subterm of some term t, then the type checking rules for ∅ ⊢ t : T require the subterm t′ to be type checked in some specific environment Γ (i.e. Γ ⊢ t′ : T ′ ). If there is some variable y such that Γ ⊢ y : {A : T..U }, then y must be bound somewhere in t outside of t′ . If t′ is in an evaluation context of t (i.e. t = e[t′ ]), then the syntactic definition of an evaluation context ensures that y can only be bound to a value by a binding of the form let y = v in u. Since v is a value, it binds A with some specific type S, so its type is {A : S..S} by (Typ-I). Precise typing In order to reason about “good” bounds, the paper introduces the precise typing relation, denoted as ⊢! . A precise typing derivation is allowed to use only a subset of WadlerFest DOT’s type rules, so as to eliminate the rules that can lead to non-equal lower and upper type bounds. The typing derivation of a value is said to be precise if its root is either ({}-I) (typing an object) or (All-E) (typing an abstraction).3 Since the only other rule that could complete a value’s typing derivation is subsumption (Sub), precise typing computes a value’s most specific type. Stack-based reduction rules To make more explicit the evaluation order of subterms in evaluation contexts, Amin et al. define an equivalent reduction semantics without evaluation contexts that uses a variable environment as syntactic sugar for a series of let bindings whose expressions have already been evaluated to values. In the WadlerFest DOT paper, the variable environment is called a store. We call it a stack, and reserve the term store for the mutable heap. The stack-based reduction relation (including our Mutable DOT extensions) is shown in Figure 5. As soon as a let-bound variable x evaluates to a value v, the binding x 7→ v is moved onto the stack γ using the Rule (Let-Value). Although the stack and store appear similar, they have important differences. A stack needs to support only the lookup and append operations, since we never 3 We omit the definition of precise typing for variables because our proof modifications hardly affect it. Please refer to Amin et al.’s paper for the full definition. Mutable WadlerFest DOT γ ::= ∅ | (γ, x 7→ v) Stack σ ::= ∅ | σ[l 7→ x] Store γ(x) = ν(x : T ) . . . {a = t} . . . σ | γ | x.a 7−→ σ | γ | t γ(x) = λ(z : T ).t σ | γ | x y 7−→ σ | γ | [y/z ] t σ | γ | let x = y in t 7−→ σ | γ | [y/x] t σ | γ | let x = v in t 7−→ σ | (γ, x 7→ v) | t σ | γ | t 7−→ σ ′ | γ ′ | t′ σ | γ | let x = t in u 7−→ σ ′ | γ ′ | let x = t′ in u (Project) (Apply) (Let-Var) (Let-Value) (Ctx) l∈ / dom(σ) σ | γ | ref x T 7−→ σ[l 7→ x] | γ | l (Ref) γ(x) = l σ | γ | x := y 7−→ σ[l 7→ x] | γ | y (Store) γ(x) = l σ(l) = y σ | γ |!x 7−→ σ | γ | y (Deref) Fig. 5: Reduction rules for Mutable DOT in which the evaluation context is replaced with a stack for let bindings. The underlying DOT reduction rules are taken from the Coq proof that accompanies the paper of Amin et al. (2016). 15 16 M. Rapoport, O. Lhoták perform updates on the stack. A stack also needs to have a notion of order since values can refer to variables defined earlier in the stack. A store on the other hand needs to support appending and overwriting locations with different variables. The store does not need to be ordered because variables cannot refer to locations. For those reasons, in the Coq formalization of the soundness proof, the stack is represented as a list, and the store as a map data structure. The stack is an optional element of the calculus, while the store is necessary. A stack is just syntactic sugar for let-bindings: t and γ | t′ can be alternative, but equivalent ways of writing the same term. However, there is no way to write a term σ | t as just a t. Consequently, we can write σ | t and σ | γ | t′ as equivalent programs. Stack correspondence The precise type of a value v cannot have bad bounds because to every type member A that v defines, it assigns a concrete type T , so the upper and lower bounds in the precise type of v must both be T : Γ ⊢! v : {A : T..T }. A type environment Γ is said to correspond to a stack γ (written Γ ∼ γ) if it assigns to every variable x the precise type of the corresponding value γ(x). In such a type environment, variables cannot have type members with bad bounds. Possible types To prove the Canonical Forms Lemmas, the WadlerFest DOT paper introduces the set of possible types Ts(Γ, x, v). Informally, this set is defined to contain the types that one would expect x to have if it is bound to v, in the absence of bad bounds in Γ . The paper then proves that if Γ ∼ γ, then all of the types T such that Γ ⊢ x : T are actually included in Ts(Γ, x, γ)(x). 4.2 Adjusting Definitions to Mutable DOT To extend the WadlerFest DOT proof to an Mutable DOT proof, we need to adjust the definitions from above. Precise typing needs to be defined for location values. Definition 1 (Precise Value Typing). Γ, Σ ⊢! v : T if Γ, Σ ⊢ v : T and the typing derivation of t ends in ({}-I), (All-E), or (LOC) . Since the typing relation depends on a store typing, the stack correspondence relation needs to include Σ. Definition 2 (Stack Correspondence). A stack γ = xi 7→ vi corresponds to a type environment Γ = xi : Ti and store typing Σ , written Γ, Σ ∼ γ, if for each i, Γ, Σ ⊢! vi : T . The set of possible types needs to include a store typing and two additional cases for references. First, if a value is a reference to variables of type T , then the reference type Ref T should be in the set of possible types: if Σ(l) = T , then T ∈ Ts(Γ, Σ, x, l). Second, we need to account for reference subtyping. If the Mutable WadlerFest DOT 17 set of possible types includes a reference type Ref T , and U is both a sub- and supertype of T , then Ref U is also in the set of possible types. The updated definition of possible types is as follows. Definition 3 (Possible Types). The possible types Ts(Γ, Σ , x, v) of a variable x bound in an environment Γ and corresponding to a value v is the smallest set S such that 1. If v = ν(x : T )d then T ∈ S. 2. If v = ν(x : T )d and {a = t} ∈ d and Γ, Σ ⊢ t : T ′ then {a : T ′ } ∈ S. 3. If v = ν(x : T )d and {A = T ′ } ∈ d and Γ, Σ ⊢ S <: T ′ , Γ, Σ ⊢ T ′ <: U then {A : S..U } ∈ S. 4. If v = λ(x : S).t and (Γ, x : S), Σ ⊢ t : T and Γ, Σ ⊢ S ′ <: S and (Γ, x : S ′ ), Σ ⊢ T <: T ′ then ∀(x : S ′ )T ′ ∈ S. 5. If v = l and Σ(l) = T then Ref T ∈ S. 6. 7. 8. 9. 4.3 If Ref T ∈ S, Γ, Σ ⊢ T <: U , and Γ, Σ ⊢ U <: T , then Ref U ∈ S. If S1 ∈ S and S2 ∈ S then S1 ∧ S2 ∈ S. If S ∈ S and Γ, Σ ⊢! y : {A : S..S} then y.A ∈ S. If T ∈ S then µ(x : T ) ∈ S. Stores and well-typedness It is standard in proofs of progress and preservation to require that an environment be well-formed with respect to a typing: ∀x.Γ ⊢ γ(x) : Γ (x). For stacks and stack typings, this condition follows from the definition of Γ ∼ γ. We need to also define well-formedness for stores and store typings: Definition 4 (Well-Typed Store). A store σ = {li 7→ xi } is well-typed with respect to an environment Γ and store typing Σ = li 7→ Ti , written Γ, Σ ⊢ σ, if for each i, Γ, Σ ⊢ xi : Ti . The stronger corresponding stacks condition is not required for stores. For stacks, it is needed to ensure absence of bad bounds, because a type can depend on a stack variable (e.g. x.A depends on x). No similar strengthening of welltyped stores is needed because types cannot depend on store locations. 4.4 Proof In this section, we present the central lemmas required to prove the Mutable DOT soundness theorems. The Canonical Forms Lemma requires a well-typed store, and a statement that values corresponding to reference types must be locations. Lemma 1 (Canonical Forms). If Γ, Σ ∼ γ and Γ, Σ ⊢ σ , then 18 M. Rapoport, O. Lhoták 1. If Γ, Σ ⊢ x : ∀(x : T )U then γ(x) = λ(x : T ′ ).t for some T ′ and t such that Γ, Σ ⊢ T <: T ′ and (Γ, x : T ), Σ ⊢ t : U . 2. If Γ, Σ ⊢ x : {a : T } then γ(x) = ν(x : S)d for some S, d, t such that Γ, Σ ⊢ d : S, {a = t} ∈ d, Γ, Σ ⊢ t : T . 3. If Γ, Σ ⊢ x : Ref T then γ(x) = l and σ(l) = y for some l, y such that Γ, Σ ⊢ l : Ref T and Γ, Σ ⊢ y : T . The Substitution Lemma requires substitution inside of the store typing, since the types in Σ can refer to the substituted variable. Lemma 2 (Substitution). If (Γ, x : S), Σ ⊢ t : T and Γ, [y/x] Σ ⊢ y : [y/x] S then Γ, [y/x] Σ ⊢ [y/x] t : [y/x] T . The following proposition is the main soundness result of the Mutable DOT proof. It is also an extension of the original proposition of the WadlerFest DOT soundness proof. Proposition 1. Let – Γ, Σ ⊢ t : T , – Γ, Σ ∼ γ, and – Γ, Σ ⊢ σ . Then either – t is an answer, or – there exist a stack γ ′ , store σ ′ and a term t′ such that σ | γ | t 7−→ σ ′ | γ ′ | t′ and for any such γ ′ , σ ′ , t′ there exist environments Γ ′ and Σ ′ such that • (Γ, Γ ′ ), (Σ, Σ ′ ) ⊢ t′ : T , • (Γ, Γ ′ ), (Σ, Σ ′ ) ∼ γ, and • (Γ, Γ ′ ), (Σ, Σ ′ ) ⊢ σ . Progress and preservation (Theorems 1 and 2) follow directly from Proposition 1, if we assume Γ to be empty. 5 Discussion In this section, we explain the design choices of Mutable DOT in more detail and discuss possible alternative implementations. Mutable WadlerFest DOT 5.1 19 Motivation for a store of variables One unusual aspect of the design of Mutable DOT is that the store contains variables rather than values. We experimented with alternative designs that contained values, and observed the following undesirable interactions with the existing design of WadlerFest DOT. A key desirable property is that the store should be well-typed with respect to a store typing: ∀l. Γ, Σ ⊢ σ(l) : Σ(l). Many of the WadlerFest DOT type assignment rules apply only to variables, and not to values. For example, the type {a : ⊤} is not inhabited by any value, but a variable can have this type. This is because an object value has a recursive type, and the (Rec-E) rule that opens a recursive type µ(x : {a : ⊤}) into {a : ⊤} applies only to variables, not to values. In particular, in the term let x = ν(y : {a : ⊤}){a = t} in ref x {a : ⊤} x has type {a : ⊤} but ν(y : {a : ⊤}){a = t} does not, even though the let binding suggests that the variable and the value should be equal. If memory cells were to contain values, a cell of type {a : ⊤} would not make sense, because no values have that type. However, since WadlerFest DOT prohibits subtyping between recursive types, this would severely restrict the polymorphism of memory cells. In particular, it would be impossible to define a memory cell containing objects with a field a of type ⊤ and possibly additional fields. Extending the subtyping rules to apply to values as well as variables would disrupt the delicate WadlerFest DOT soundness proofs. The above example let term demonstrates another problem: type preservation. The type system should admit the term ref x {a : ⊤} because x has type {a : ⊤}. This term should reduce to a fresh location l of type Ref {a : ⊤}. But a store that maps l to ν(y : {a : ⊤}){a = t} would not be well typed, because the value does not have type {a : ⊤}. 5.2 Correctness of a store of variables Putting variables instead of values in the store raises a concern: when we write a variable into the store, we expect that when we read it back, it will still be in scope, and it will still be bound to the same value. For example, in the following program fragment, the variable x gets saved in the store inside the function f . let f = λ(x : ⊤).ref x T in let y = v in let r = f y in !r Will x go out of scope by the time we read it from the store? The reduction sequence for this program is shown in Figure 6. Notice that before the body ref x T of the function is reduced, the parameter x is first substituted with the argument y, which does not go out of scope. 20 M. Rapoport, O. Lhoták ∅ ∅ | f 7→ λ(x : ⊤).ref x T , y 7→ v |f→ 7 λ(x : ⊤).ref x T , y → 7 v | let r = f y in !r 7 → − | let r = [y/x] ref x T in !r 7−→ ∅ | f 7→ λ(x : ⊤).ref x T , y 7→ v | let r = ref y T in !r 7−→ | let r = l in !r 7−→ l 7→ y | f 7→ λ(x : ⊤).ref x T , y 7→ v l→ 7 y l→ 7 y | f 7→ λ(x : ⊤).ref x T , y 7→ v, r 7→ l | !r |f→ 7 λ(x : ⊤).ref x T , y → 7 v, r 7→ l | y 7−→ Fig. 6: Reduction sequence for example program More generally, from the stack-based reduction semantics in Figure 5, it is immediately obvious that when a variable x is saved in the store using ref x T or y := x, the only variables that are in scope are those on the stack. There are no function parameters in scope that could go out of scope when the function finishes. Moreover, once a variable is on the stack, it never goes out of scope, and the value that it is bound to never changes. This is because the only reduction rule that modifies the stack is (Let-Value), and it only adds a new variable binding, but does not affect any existing bindings. 5.3 Creating references The Mutable DOT reference creation term ref x T requires both a type T and an initial variable x. The variable is needed so that a reference cell is always initialized, to avoid the need to add a null value to DOT. If desired, it is possible to model uninitialized memory cells in Mutable DOT by explicitly creating a sentinel null value. Some other calculi with mutable references (e.g. Types and Programming Languages (Pierce, 2002)) do not require the type T to be given explicitly, but just adopt the precise type of x as the type for the new cell. Such a design does not fit well with subtyping in DOT. In particular, it would prevent the creation of a cell with some general type T initialized with a variable x of a more specific subtype of T . More seriously, such a design (together with subtyping) would break type preservation. Suppose that Γ, Σ ⊢ y : S and Γ, Σ ⊢ S <: T . Then we could arrive at the following reduction sequence: ∅ | f 7→ λ(x : T ).ref x, y 7→ v | fy 7−→ ∅ | f 7→ λ(x : T ).ref x, y 7→ v | [y/x] ref x 7−→ ∅ | f 7→ λ(x : T ).ref x, y 7→ v | ref y The term at the beginning of the reduction sequence has type Ref T , while the term at the end, ref y, has type Ref S. Preservation would require Ref S to be Mutable WadlerFest DOT 21 a subtype of Ref T , but this is not the case in general since the only condition that this example imposes on S and T is that Γ, Σ ⊢ S <: T . 6 Example Recall the aquarium example from Section 2. Suppose we wanted to make the aquarium mutable: instead of returning a new Aquarium, the addFish method should update the aquarium’s list of fish by appending the new fish object to it. A possible implementation in Mutable DOT looks as follows: let collections = ν(col) { ... }: { List : µ( list : (A; append: ∀(a: list .A){col. List ; A <: a.A})} in ν(aq) { Aquarium = µ(a: {Fish; fish : Ref { collections . List ; A: a. Fish }}); addFish = λ(a: aq.Aquarium).λ(f: a. Fish ). let old = !(a.fish) in a.fish := old.append f; f }: {Aquarium: µ(a: {Fish ; fish : Ref { collections . List ; A: a. Fish }}); addFish: ∀(a: aq.Aquarium)∀(f: a. Fish) a.Fish } The fish member of the new Aquarium version is now a reference to a list of fish, and the addFish changes the list to include the new fish and returns it. 7 Related Work The semantics of mutable references presented in this paper is similar to Pierce’s extension of the simply-typed lambda calculus with typed mutable references (Pierce, 2002, Chapter 13). However, the resemblance is mostly syntactic: the language presented in the book does not include subtyping or other object-oriented features. An extensive study of object-oriented calculi, including ones that support mutation, can be found in “A Theory of Objects” (Abadi and Cardelli, 1996). The book surveys imperative calculi with a range of advanced object-oriented features, including subtyping and inheritance, self types, and typed mutable objects (using protected storage cells). Mackay et al. (2012) developed a version of Featherweight Java (Igarashi et al., 2001) with mutable and immutable objects and formalized it in Coq. However, neither of the analyzed type systems involved path-dependent types. The νObj calculus (Odersky et al., 2003) introduced types as members of objects, and thus path-dependent types. However, type members had only upper bounds, but not lower bounds, as they do in Scala. On the other hand, 22 M. Rapoport, O. Lhoták the νObj calculus was richer than DOT, including features such as first-class classes, which are not present even in the full Scala language. Featherweight Scala (Cremet et al., 2006) was a simpler calculus intended to correspond more closely to Scala, and with decidable type-checking. However, its type system has not been proven sound. A related calculus, Scalina (Moors et al., 2008), intended to explore the design of higher-kinded types in Scala, was also not proven sound. Amin et al. (2012) first used the name DOT for a calculus intended to be simple, and to capture only essential features, namely path-dependent types, type refinement, intersection, and union. This paper discussed the difficulties with proving such a calculus sound. The most notable challenge were counterexamples to type preservation in a small-step semantics. In general, a term can reduce to another term with a narrower type. In this DOT calculus, this narrowing could disrupt existing subtyping relationships between type members in that type. Amin et al. (2014) examined simpler calculi with subsets of the features of DOT to determine which features cause type preservation to fail. They identified the problem of bad bounds, noted that they cannot occur in runtime objects that are actually instantiated, and conjectured that distinguishing types realizable at runtime could lead to a successful soundness proof for a DOT calculus with all of its features. Rompf and Amin (2015) confirmed this conjecture by providing the first soundness proof of a big-step semantics for a DOT calculus with type refinement and a type lattice with union and intersection. The use of a big-step semantics makes it possible to get around the problem of small steps temporarily violating type preservation, at the cost of a more complex soundness proof. An update to the technical report Rompf and Amin (2016a) reports that the authors were also able to add mutable references to this big-step version of the calculus. WadlerFest DOT (Amin et al., 2016) defines a very specific evaluation order for the subexpressions of a DOT calculus that satisfies type preservation at each reduction step, and expressed it in a small-step semantics. The semantics uses administrative normal form (ANF) to make the necessary evaluation order explicit and clear, and to distinguish realizable types of objects instantiated at run time from arbitrary types. In particular, in the context in which a term is reduced, every ANF variable maps to a value, an actual run-time object, rather than an arbitrary term; thus, the ANF variables play the role of labels of runtime values in the semantics and its proof. The paper is accompanied by a Coq formalization of the full type soundness proof in the familiar style of progress and preservation Wright and Felleisen (1994), and is thus well suited as a basis for extensions to the calculus. It is this WadlerFest DOT calculus that we have extended with mutable references, to serve as a basis for further extensions that involve mutation. One limitation of the WadlerFest DOT calculus is the lack of subtyping between recursive types. The calculus of Rompf and Amin (2016b), which is to appear, will remove this limitation, while maintaining a small step semantics. We hope that the experience that we have reported here on the WadlerFest DOT calculus will also be helpful for adding mutation to this new DOT calculus. Mutable WadlerFest DOT 8 23 Conclusion WadlerFest DOT formalizes the essence of Scala, but it lacks mutation, which is an important feature of object-oriented languages. In this paper, we show how WadlerFest DOT can be extended to handle mutation in a type-safe way. As shown in the paper, adding a mutable store to the semantics of WadlerFest DOT is not straightforward. The lack of subtyping between recursive types leads to situations where variables and values, even though they are bound together, have incompatible types. As a result, if WadlerFest DOT were extended with a conventional store containing values, it would be impossible for a cell of a given type T to store values of different subtypes of T , thus significantly restricting the kinds of mutable code that could be expressed. The key idea of this paper is to enable support for mutation in WadlerFest DOT by using a store that contains variables instead of values. We have shown that by using a store of variables, it is possible to extend WadlerFest DOT with mutable references in a type-safe way. This leads to a formalization of a language with path-dependent types and mutation, and also brings WadlerFest DOT one step closer to encoding the full Scala language. Acknowledgement: This research was supported by the Natural Sciences and Engineering Research Council of Canada. Bibliography Abadi, M., Cardelli, L.: A Theory of Objects. Monographs in Computer Science, Springer (1996) Amin, N.: Dependent Object Types. Ph.D. thesis (2016a) Amin, N.: Soundness issue with path-dependent type on null path. https://issues.scala-lang.org/browse/SI-9633 (2016b) Amin, N., Grütter, S., Odersky, M., Rompf, T., Stucki, S.: The Essence of Dependent Object Types. Springer International Publishing, Cham (2016) Amin, N., Moors, A., Odersky, M.: Dependent Object Types. In: International Workshop on Foundations of Object-Oriented Languages (FOOL 2012) (2012) Amin, N., Rompf, T., Odersky, M.: Foundations of path-dependent types. In: Proceedings of the 2014 ACM International Conference on Object Oriented Programming Systems Languages & Applications, OOPSLA 2014, part of SPLASH 2014, Portland, OR, USA, October 20-24, 2014. pp. 233–249 (2014) Amin, N., Tate, R.: Java and scala’s type systems are unsound: The existential crisis of null pointers. In: to appear in OOPSLA 2016 (2016) Cremet, V., Garillot, F., Lenglet, S., Odersky, M.: A core calculus for Scala type checking. In: Mathematical Foundations of Computer Science, 31st International Symposium, Slovakia (2006) Igarashi, A., Pierce, B.C., Wadler, P.: Featherweight Java: a minimal core calculus for Java and GJ. ACM Trans. Program. Lang. Syst. 23(3), 396–450 (2001) Mackay, J., Mehnert, H., Potanin, A., Groves, L., Cameron, N.R.: Encoding Featherweight Java with assignment and immutability using the Coq proof assistant. In: Proceedings of the 14th Workshop on Formal Techniques for Java-like Programs (2012) Moors, A., Piessens, F., Odersky, M.: Safe type-level abstraction in scala. In: International Workshop on Foundations of Object-Oriented Languages (FOOL 2008) (2008) Odersky, M.: Scaling DOT to Scala — Soundness. http://www.scala-lang.org/blog/2016/02/17/scaling-dot-soundness.html (2016) Odersky, M., Cremet, V., Röckl, C., Zenger, M.: A nominal theory of objects with dependent types. In: Proc. ECOOP’03. Springer LNCS (2003) Petrashko, D.: Making sense of initialization order in scala. https://d-d.me/talks/scalar2016/#/ (2016) Pierce, B.C.: Types and Programming Languages. The MIT Press, 1st edn. (2002) Rompf, T., Amin, N.: From F to DOT: type soundness proofs with definitional interpreters. CoRR abs/1510.05216v1 (2015), http://arxiv.org/abs/1510.05216v1 Mutable WadlerFest DOT 25 Rompf, T., Amin, N.: From F to DOT: type soundness proofs with definitional interpreters. CoRR abs/1510.05216v2 (2016a), http://arxiv.org/abs/1510.05216v2 Rompf, T., Amin, N.: Type soundness for dependent object types (DOT). In: to appear in OOPSLA 2016 (2016b) Wright, A.K., Felleisen, M.: A syntactic approach to type soundness. Inf. Comput. 115(1), 38–94 (1994)
6cs.PL
arXiv:1609.07450v3 [cs.DM] 21 Feb 2018 Finding long simple paths in a weighted digraph using pseudo-topological orderings Miguel Raggi ∗ [email protected] Escuela Nacional de Estudios Superiores Universidad Nacional Autónoma de México Abstract Given a weighted digraph, finding the longest path without repeated vertices is well known to be NP-hard. Furthermore, even giving a reasonable (in a certain sense) approximation algorithm is known to be NP-hard. In this paper we describe an efficient heuristic algorithm for finding long simple paths, using an hybrid approach of heuristic depth-first search and pseudo-topological orders, which are a generalization of topological orders to non acyclic graphs, via a process we call “opening edges”. Keywords: long paths, graphs, graph algorithms, weighted directed graphs, long simple paths, heuristic algorithms. 1 Introduction We focus on the following problem: Given a weighted digraph D = (V, E) with weight w : E → R+ , find a simple path with high weight. The weight of a path is the sum of the individual weights of the edges belonging to the path. A path is said to be simple if it contains no repeated vertices. Possible applications of this problem include motion planning, timing analysis in a VLSI circuit and DNA sequencing. The problem of finding long paths in graphs is well known to be NP-hard, as it is trivially a generalization of HAMILTON PATH. Furthermore, it was proved by Björklund, Husfeldt and Khanna in [BHK04] that the longest path cannot be aproximated in polynomial time within n1−ε for any ε > 0 unless P = N P . ∗ Research supported in part by PAPIIT IA106316, UNAM. Orcid ID: 0000-0001-9100-1655. 1 While LONGEST SIMPLE PATH has been studied extensively in theory for simple graphs (for example in [Scu03], [ZL07], [PD12]), not many efficient heuristic algorithms exist even for simple undirected graphs, much less for weighted directed graphs. A nice survey from 1999 can be found at [Sch99]. A more recent comparison of 4 distinct genetic algorithms for approximating a long simple path can be found in [PAR10]. An implementation of the proposed algorithm won the Oracle MDC coding competition in 2015. In the problem proposed by Oracle in the challenge “Longest overlapping movie names”, one needed to find the largest concatenation of overlapping strings following certain rules, which could be easily transformed to a problem of finding the longest simple path in a directed weighted graph. The graph had around 13,300 vertices. Our contribution lies in a novel method of improving existing paths, and an efficient implementation of said method. The proposed algorithm consists of two parts: finding good candidate paths using heuristic DFS and then improving upon those candidates by attempting to either replace some vertices in the path by longer subpaths–or simply insert some subpaths when possible–by using pseudo-topological orders. The full C++ source code can be downloaded from http://github.com/mraggi/LongestSimplePath. In Section 2 we give some basic definitions. We describe the proposed algorithm in Section 3. Finally, we give some implementation details and show the result of some experimental data in Section 4. It should be noted that for this particular problem it is generally easy to quickly construct somewhat long paths, but only up to a point. After this point even minor improvements get progressively harder. 2 Preliminaries Definition 2.1. A directed acylic graph (or DAG) D is a directed graph with no (directed) cycles. In a directed acyclic graph, one can define a partial order ≺ of the vertices, in which we say v ≺ u iff there is a directed path from v to u. Definition 2.2. A topological ordering for a directed acyclic graph D is a total order of the vertices of D that is consistent with the partial order described above. In other words, it is an ordering of the vertices such that there are no edges of D which go from a “high” vertex to a “low” vertex. Definition 2.3. Given a digraph D, a strongly connected component C is a maximal set of vertices with the following property: for each pair of vertices x, y ∈ C, there exists a (directed) path from x to y and one from y to x. A weakly connected component is a connected component of the associated simple graph. 2 1 2 3 3 2 6 1 5 5 6 4 4 Figure 1: Two different topological orders of the same digraph Definition 2.4. Given a digraph D, the skeleton S of D is the graph constructed as follows: The vertices of S are the strongly connected components of D. Given x, y ∈ V (S), there is an edge x → y iff there exists a ∈ x and b ∈ y such that a → b is an edge of D. It can be observed that S is always a directed acyclic graph. Definition 2.5. Denote by v the connected component of D which contains v. Given a vertex v, we define the out-rank of v as the length of the longest path of S that starts at v. Similarly, we define the in-rank of v as the length of the longest path of S which ends at v. 2.1 Longest simple path on DAGs In case that the digraph is a acyclic, a well-known algorithm that uses dynamic programming can find the optimal path in O(n) time. We describe Dijkstra’s algorithm adapted to finding the longest simple path in a DAG. As this algorithm is an essential building block of the algorithm described in Section 3.2, we add a short description here for convenience. For a longer discussion see, for example, [SW11]. 1. Associate to each vertex v a real number x[v], which will end up representing the weight of the longest simple path that ends at v. 2. Find a topological ordering of the vertices of D. 3. In said topological order, iteratively set x[v] to the max of x[p] + w(p → v) where p → v is an edge, or 0 otherwise. 4. Once we have x[v] for every vertex v, reconstruct the path by backtracking, starting from the vertex v with the highest x[v]. In more detail, 3 Algorithm 1 Longest simple path in a DAG Input: A DAG D with weight function w : E(D) → R. Output: A longest simple path P in D. function LSP DAG(D) x is an array of size |V (D)|, initialized with zeroes. Find a topological order T for V (D) for v ∈ T do x[v] := max{xp + w(p → v) : p → v} v := argmax(x) P := path with only v T 0 := reverse(T ) while x[v] 6= 0 do u := an in-neighbor of v for which x[u] + w(u → v) = x[v] Add u to the front of P v := u return P This algorithm is simple to implement and efficient. Its running time is O(E + V ), where E is the number of edges of D. 3 The Algorithm In what follows we shall assume we have preprocessed the graph and found the weakly connected components, the strongly connected components, and have fast access to both the outgoing edges and incoming edges for each vertex. As we may perform the following algorithm on each weakly connected component, without loss of generality assume D is weakly connected. Our proposed algorithm has two main parts: In the first part we find long paths using heuristic depth first search, choosing in a smart way which vertices to explore first, and in the second part we discuss a strategy to improve the paths obtained in the first part. Since the idea based on DFS is somewhat standard or straightforward, the main contribution of this paper lies in the ideas presented in the second part. 3.1 Depth-first search We describe a variation on depth-first search (DFS). The standard way of implementing a depth-first search is to either use a stack (commonly refered to as the frontier or fringe) of vertices to store unexplored avenues, or to use recursive calls (effectively using the callstack in lieu of the stack). If the graph is not acyclic, DFS may get stuck on a cycle. The standard way of dealing with this problem, when one simply wishes to see every vertex (and not every simple path, 4 as in our case), is to store previously explored vertices in a data structure that allows us to quickly check if a vertex has been explored before or not. However, for the problem of finding the longest simple path, it’s not enough to simply ignore previously explored vertices, as we may need to explore the same vertex many times, as we may arrive at the same vertex from many different paths, and these need to be considered separately. Thus, for this problem, it is not possible to backtrack to reconstruct the path, as in many other problems. This could be solved simply by modifying DFS slightly: make the frontier data structure containing paths instead of only vertices. However, storing paths uses a large amount of memory and all the extra allocations might slow down the search considerably. We propose a faster approach that results from only modifying a single path inplace. This is very likely not an original idea, but an extensive search in the literature did not reveal any article that considers depth-first search in this manner. Probably because for most problems the recursive or stack implementations are quite efficient, as they only need to deal with stacks of vertices and not stacks of paths. In this approach, instead of maintaining a stack of unexplored avenues, assume for each vertex the outgoing edges are sorted in a predictable manner. Later we will sort the outgoing edges in a way that explores the vertices with high probability of producing long paths first, but for now just assume any order that we know. Since this approach modifies the path in place, always make a copy of the best path found so far before any operation that might destroy the path. Furthermore, assume we have a function NextUnexploredEdge(P, {u, v}) that takes as input a path P and an edge {u, v}, in which the last vertex of P is u, and returns the next edge {u, w} in the order mentioned above for which w ∈ / P . This can be found using binary search, or even adding extra information to the edge, so that each edge remembers its index in the adjacency list of the first vertex. If there is no such edge, the function should return null. If no parameter {u, v} is provided, it should return the first edge {u, w} for which w ∈ / P. We will construct a single path P and modify it repeatedly by adding vertices to the back of P . 5 Algorithm 2 Next Path in a DFS manner Input: A weighted digraph D and a path P , which will be modified in place Output: Either done or not done function NextPath(P ) last := last vertex of P t := NextUnexploredEdge(P ) while t = null and |P | > 1 do last := last vertex of P Remove last from P newLast := last vertex of P t := NextUnexploredEdge(P, {newLast, last}) if t = null then return done Add t to the back of P return not done By repeatedly applying this procedure we can explore every path that starts at a given vertex in an efficient manner, but there are still too many possible paths to explore, so we must call off the search after a specified amount of time, or perhaps after a specified amount of time has passed without any improvements on the best so far. Finally, we can do both forward and backward search with a minor modification to this procedure. So once a path cannot be extended forward any more, we can check if it can be extended backward. We found experimentally that erasing the the first few edges of the path before starting the backward search often produces better results. 3.1.1 Choosing the next vertex We give the details for efficiently searching forward, as searching backward is analogous. So we are left with the following two questions: At which vertex do we start our search at? And then, while performing DFS, which vertices do we explore first? That is, how do we find a “good” order of the outgoing edges, so that good paths have a higher chance of being found quickly? The first question is easily answered: start at vertices with high out-rank. To answer the second question, we use a variety of information we collect on each vertex before starting the search: 1. The out-rank and in-rank. 2. The (weighted) out-degree and (weighted) in-degree. 3. A score described below. Once we find the score of each vertex, order the out-neighbors by rank first and score second, with some exceptions we will mention below. The score should not depend on any path, only on local information about the vertex, and should be fast to calculate. 6 Formally, let k be a constant (small) positive integer. For each vertex v, let Ak (v) be the sum of weights of all paths of length k starting at v. For example, A1 (v) is the weighted out-degree. Given a choice of parameters a1 , a2 , ..., ak ∈ R+ , construct the (out) score for vertex v as scoreout (v) = k X ai Ai (v) i=1 Intuitively, the score of each vertex tries to heuristically capture the number (and quality) of paths starting at that vertex. High score means more paths start at a vertex. When performing forward search, perhaps counter-intuitively, giving high priority to vertices with low score (as long as it is not 0) consistently finds better paths than giving high priority to vertices with high score. The reason for this is that exploring vertices with low score first means saving the good vertices–those with high scores–for later use, once more restrictions are in place. Low scoring vertices are usually quickly discarded if there is no out, and so by leaving vertices with high degree for later, when the path is longer and so there are more restrictions about which vertices can be used, makes sense. An exception is if a vertex has degree 0. In this case, we give the vertex a low priority, as no further paths are possible. Another exception is to give higher priority to vertices with very low indegree (for example, indegree 1), since if they are not explored in a path when first finding their parents, they will never be used again later in the path. In addition, we also use the in-degree information in an analogous way. 3.2 Pseudo-topological order The idea behind the second part of the algorithm is to try to improve paths by either inserting some short paths in-between or replacing some vertices by some short paths in an efficient way that covers both. We begin by introducing some definitions. Definition 3.1. Given a digraph D, a weak pseudo-topological ordering ≺ of the vertices of D is a total order of the vertices in which whenever x ≺ y and there is an edge y → x, then x and y are in the same strongly connected component. In other words, a weak pseudo-topological order is a total order that is consistent with the partial order given by the skeleton. Definition 3.2. Given a digraph D, a strong pseudo-topological ordering ≺ of the vertices of D is a total order of the vertices in which whenever x ≺ y and there is an edge y → x, every vertex in the interval [x, y] is in the same strongly connected component. In other words, a strongly pseudo-topological order is a weakly connected component in which the strongly connected components are not intermixed. 7 3 7 1 4 2 6 8 5 Figure 2: A (strong) pseudo-topological ordering From here on, whenever we mention a pseudo-topological ordering, we mean a strong pseudo-topological ordering. An easy way to get a random pseudo-topological ordering is to get a random topological ordering of the skeleton of the graph, and then “explode” the strongly connected components, choosing a random permutation of vertices in each component. We can think of a pseudo-topological ordering as a topological ordering of the digraph in which we erase all edges that go from a “high” vertex to a “low” vertex, thus considering an acyclic subdigraph of the original. We call this graph the subjacent DAG of the pseudotopological order. Thus, we may apply Algorithm 1 to this acyclic digraph and find its longest simple path. As can be expected, the results obtained in this fashion are very poor compared to even non heuristic recursive slow depth-first search. However, if we combine the two approaches we get better paths. 3.2.1 Combining the two approaches Definition 3.3. Given a path P and a pseudo-topological ordering T , the imposition of P on T is a pseudo-topological ordering TP which every vertex not in P stays in the same position as in T . The vertices in P are permuted to match the order given by P . For example, say we start with path P = 3 → 1 → 5 → 8. Consider any pseudotopological ordering, say, T = (1, 8, 7, 4, 3, 6, 5, 2). Then imposing the order defined by P into T gives rise to T 0 = (3, 1, 7, 4, 5, 6, 8, 2). Lemma 3.4. TP as constructed above is also a (strong) pseudo-topological order. Proof. As T is a strong pseudo-topological order, consider S1 , S2 , ... , Sc the strongly connected components in the order they appear in T . Denote by s(v) index of the strongly connected component of v. It suffices to prove that the vertices only move inside their own strongly connected components when going from T to TP . 8 S1 S2 S3 S4 S5 Figure 3: No backward edges can jump between strongly connected components. Let (p1 , p2 , ..., pk ) be the vertices of path P . Note that there is no i < j for which s(pi ) > s(pj ) since this would mean there exists a path from a vertex in Ss(pi ) to a vertex in Ss(pj ) , but if s(pi ) > s(pj ), no such path is possible in a pseudo-topological order, since this violates the order in the skeleton. This means that when imposing the order of P into T to get TP , no vertex can jump out of their strongly connected component, and thus TP is also a strong pseudo-topological order. The previous lemma ensures that we may run algorithm 1 with order TP , and get a path that is at least as good (and hopefully better) as path P , since all edges of P remain in the subjacent DAG of TP . If after applying this technique we do find an improved path P 0 , we can repeat the process with P 0 , by again taking a random pseudo-topological ordering, imposing the order of P 0 on this new ordering, and so on, until there is no more improvement. The idea then is to construct long paths quickly with DFS and then use these paths as starting points for imposing on random pseudo-topological orders. This approach does indeed end up producing moderately better paths than only doing DFS, even when starting from scratch with the trivial path and a random pseudo-topological order, albeit taking longer. However, we can do better. 3.2.2 Opening the edges Again, we are in the setting where we have a path P which we wish to improve. Now, instead of just imposing path P on multiple random pseudo-topological orders to find one that gets an improvement, construct orders as follows: Pick an edge pi → pi+1 of path P and construct a random pseudo-topological order that is consistent with P and furthermore, for which pi and pi+1 are as far apart as possible. Figure 4: The process of opening an edge. This is achieved by putting all vertices not in P in all strongly connected components between pi and pj in between pi and pj . In the figure above, the “large” vertices are vertices in P and the “small” vertices are all other vertices not in P in the same connected component as 9 pi and pi+1 . If pi and pi+1 are not in the same connected component, then, place every vertex in either connected component, and also every vertex that belongs in a connected component between the component of pi and the component of pi+1 between the two vertices, in such a way that the order is still a strong pseudo-topological order. We may repeat this process for each edge in P . The process of opening an edge is relatively expensive, since we must run Algorithm 1 each time. We now make an attempt at explaining why opening edges works as well as it does. Consider: 1. If there exist a vertex v that can be inserted into P , opening the corresponding edge finds this improvement. 2. If there exists a vertex v that can replace a vertex p in P and make the path longer (by means of edge weights), this process will find it when opening the edge to either side of p. 3. Any (small) path of size k that can be inserted into P , perhaps even replacing a few vertices of P , has probability at least 1/k! of being found if the corresponding vertices in the small path happen to be in the correct order. In the next section we try to heuristically maximize the probability that inserting or replacing paths will be found. 3.2.3 Opening the edges eXtreme In the previous section, when opening up each edge, we put all the remaining vertices in the same connected component in a random order (consistent with pseudo-topological orders). We now consider the question of which order to give to those unused vertices. We discuss three different approaches: one heuristic that is quick and practical, one powerful and somewhat slow, and one purely theoretical using sequence covering arrays but which provides some theoretical guarantees. Let B be the inbetween vertices (i.e. vertices between pi and pi+1 when opening this edge). Since every other vertex will remain in their place, we face the problem of giving B an ordering with a good chance of delivering an improvement. We only consider orders of B that leaves the total order a strongly pseudo-topological order. That is, we only permute the vertices of B within their own strongly connected components of the full graph. Consider the induced subdigraph on B: Recall that running Algorithm 1 with a pseudo-topological order is equivalent to finding the longest path on the digraph that results by erasing all the edges that go backward. 10 Therefore, we must consider only orders of B that are themselves pseudo-topological orders of the induced subgraph on B. We describe three approaches to choosing an order of B. 3.2.4 The powerful approach The “powerful” approach is to recursively repeat the process on the induced subgraph on B. That is, repeat for B the whole process of finding the strongly connected components, performing DFS as described in a previous section, finding suitable pseudo-topological orders, opening their respective edges, and recursively doing the same for the induced subgraphs in order to find good pseudo-topological orders and so on. The problem with this approach is that with any standard cache-friendly graph data structure we would need to reconstruct the induced digraph (i.e. rename the vertices of B but keep track of their original names), and the whole process is slow. Of course, we would only need to do this process once per connected component and then we can use the results for each edge of the path. The advantage of this approach is that we are precisely recursively finding good pseudotopological orders of B, which means it’s likely many long paths can be inserted in our original P . 3.2.5 The heuristic approach Instead of attempting to repeat the whole algorithm on the induced subgraph, we try to mimic heuristically its results. Consider the following operation on the inbetween vertices: pick a vertex u at random, and exchange its position with some out-neighbor v of u which appeared before u in the pseudo-topological order. If no such neighbor exists, simply find pick another u. Repeat this operation (which is quite inexpensive) as many times as the time limit allows. The following theorem ensures that this process will likely end in a (weak) pseudo-topological order. Theorem 3.5. With probability approaching 1 as the number of times approaches infinity, the order constructed above is a weak pseudo-topological order of the induced subgraph B. Proof: For any digraph, given a total order of the vertices, call a pair of vertices (a, b) bad if a appears before b in the order, there is a path from b to a but not one from a to b. In other words, if the strongly connected component which contains b is (strictly) less than the strongly connected component which contains a in the partial order of the skeleton of D. Thus, we only need to prove that the number of bad pairs never increases after an operation, and that with some positive probability, it decreases. Suppose we do an operation, and u is the chosen vertex, which is exchanged with v (so u was after v in the order, but there is an edge from u to v). Then only pairs of vertices of the form (a, u) and (v, a) could have changed status (and only when a is between u and v in the order). 11 Let U, V, A be the strongly connected components containing u, v, a respectively. If A is before U , then indeed the pair (a, u) is now bad after the exchange, but since we are assuming there is an edge from u to v, if A is before U , then it is before V , and so the pair (v, a) used to be bad, but is now good. When (v, a) becomes bad, the process is analogous, and (a, u) becomes good. The above process then gives a random approximate algorithm to calculate weak pseudotopological orders without calculating the strongly connected components. 3.2.6 The theoretical approach Denote E(P ) the edge set of a path P . For a positive integer k, we wish to find P that is maximal in the sense that if Q is another path for which |E(Q) \ E(P )| ≤ k, then the total weight of Q is less than or equal to the total weight of P . Given the edge opening process, this problem can be reduced to the following: we wish for a minimal set of permutations of Sn for which every k-subset of n appears in every possible order. The idea is to try an edge opening for every edge in the path with the order of B given by each element of the set of permutations. This problem has been worked on by Colbourn et al. on [CCHZ13] and [MC14], where they named any such set of permutations a sequence covering array. They give a mostly impractical algorithm for finding covering arrays, that works in practice up to n ≈ 100. However, an easy probabilistic argument yields that taking Θ(log(n)) permutations randomly gives a non-zero chance of ending up with a covering array. This suggests that merely taking many random permutations would yield (probabilistically) the desired result. Unsurprisingly, this approach is not nearly as efficient as the other two. For k = 2, however, a covering array is easy to find: take any permutation and its reverse. So by opening every edge and taking any permutation of the inbetween vertices and its reverse, we ensure the found path is optimal in this very limited sense: There exists no other path with higher total weight all whose edges, except one, are a subset of the edges of P plus one more. 4 4.1 Some details about the implementation Preprocessing the graph The data structure we use for storing the graph is a simple pair of adjacency lists: one for the out-neighbors and one for the in-neighbors, so we can access either efficiently. The vertices are numbered from 0 to n − 1 and we store an array of size n, each element of which is an array storing both the neighbors of the corresponding vertex and the corresponding edge-weights. Next, we find connected components. While it is true that finding the weakly connected components, strongly connected components and skeleton might require some non-trivial 12 processing, this pales in comparison to the NP-hard problem of finding the longest path. An efficient implementation (for example, using C++ boost graph library) can find the weakly and strongly connected components on graphs with millions of edges in a fraction of a second. Then, we find the out-heuristic and the in-heuristic scores for each vertex, as described in Section 3.1, and sort the neighbors of each vertex according to the heuristic. In our experiments, the whole preprocessing step took about 0.2 seconds on the Oracle graph, which has ∼13,300 vertices. This time includes reading the file of strings, figuring out which concatenations are possible and constructing the graph. Experiments with randomly generated graphs of comparable size take less than 0.1 seconds if the graph is already in memory. If one has a training set of a class of graphs, one could use some rudimentary machine learning to try to find the optimal parameters so that on average good paths are found. In fact, for the contest, we did just that, which provided a slight boost. The code includes a trainer for this purpose, but experimental results on the benefits of this are sketchy at best and do not (usually) warrant the long time it takes to train. 4.2 Pseudo-Topological orders Once we have a pseudo-topological order T , we construct its inverse for fast access, so in addition of being able to answer the query “which vertex is in position i of T ?” we can also answer the query “at which position is vertex v in T ?” efficiently. Therefore, any operation we do on T must be mirrored to the inverse. In addition, since we are constantly changing T and having to rerun Algorithm 1, it is worth it to store xv for each v, and just reprocess from the first vertex whose order was modified and onwards. Fortunately, when performing the edge opening process, much of the order has been preserved, so we can use this information and recalculate from the first modification onwards, speeding up the calculation considerably. Finally, opening the edges is just a matter of rearranging the vertices to satisfy the condition, which is straightforward. We found experimentally that the process finds good paths faster if the edges of the path are opened in a random order and not sequentially. This makes intuitive sense. If a path cannot be improved by a certain edge opening, it’s unlikely (but possible) an edge that is near will yield an improvement. Our implementation of the “powerful” approach described in Section 3.2.4 was by constructing a completely new graph and running the algorithm on the subgraph recursively, and so it was prohibitely slow, although it did tend to find longer subpath insertions with fewer edge openings. Perhaps this can be improved. The implementation of the heuristic approach of Section 3.2.5 was considerably more efficient over the random approach described in Section 3.2.6. 13 5 Experimental data We compare this algorithm to one other found in the literature, by Portugal et. al. [PAR10], as the authors have kindly provided us with the code. There is a scarcity of heuristic algorithms for this problem, and the code for some, such as [Sch99] appears to have been lost, so a direct comparison turns out to be impractical. Unfortunately, an extensive literature search did not provide any other accessible source code for this problem, making the code in the link of the introduction the only open source and readily available implementation we are aware of that heuristically finds long simple paths. In [PAR10], the authors compare four approaches based on genetic algorithms. The biggest graph they used as an example consists of 134 vertices. The result was that their fastest algorithm was able to find the optimal solution more than half of the time in around 22 seconds. For comparison, our program only took 0.001 seconds for the same graph and found the longest path on 100% of the test runs. Please bear in mind that the comparison might be somewhat unfair, since their implementation was in Matlab instead of C++. Our algorithm took less than a millisecond for all the graphs in [PAR10] and found the longest simple path 100% of the test runs. 5.1 Tests in large random graphs where we know the longest path size Given n and m, consider the following graph generation process for a graph with n vertices and m edges. Consider any random permutation of the vertices v1 , v2 , ..., vn and add all edges vi → vi+1 . Then pick n − m + 1 other edges uniformly at random. All edge weights were set to 1, so we know for certain the longest simple path has size n − 1. For example, in our experiments, for n = 10, 000 and m = 100, 000, the whole process (including reading the file containing the graph) took on average 1.28 seconds to find the longest simple path. 6 Acknowledgements We would like to thank the organizers of the Oracle MDC coding challenge for providing a very interesting problem to work on (and for the prize of a drone and camera, of course). Furthermore, we would like to thank the other participants, specially Miguel Ángel Sánchez Pérez and David Felipe Castillo Velázquez for the fierce competition. Also, we are grateful to Marisol Flores and Edgardo Roldán for their helpful comments on the paper, as well as David Portugal for providing the source code from their work. This research was partially supported by PAPIIT IA106316. 14 References [BHK04] Andreas Björklund, Thore Husfeldt, and Sanjeev Khanna, Approximating longest directed paths and cycles, Automata, Languages and Programming, Springer, 2004, pp. 222–233. [CCHZ13] Yeow Meng Chee, Charles J Colbourn, Daniel Horsley, and Junling Zhou, Sequence covering arrays, SIAM Journal on Discrete Mathematics 27 (2013), no. 4, 1844–1861. [MC14] Patrick C Murray and Charles J Colbourn, Sequence covering arrays and linear extensions, Combinatorial Algorithms, Springer, 2014, pp. 274–285. [PAR10] David Portugal, Carlos Henggeler Antunes, and Rui Rocha, A study of genetic algorithms for approximating the longest path in generic graphs, Systems Man and Cybernetics (SMC), 2010 IEEE International Conference on, IEEE, 2010, pp. 2539–2544. [PD12] Quang Dung Pham and Yves Deville, Integration of ai and or techniques in contraint programming for combinatorial optimzation problems: 9th international conference, cpaior 2012, nantes, france, may 28 – june1, 2012. proceedings, ch. Solving the Longest Simple Path Problem with Constraint-Based Techniques, pp. 292–306, Springer Berlin Heidelberg, Berlin, Heidelberg, 2012. [Sch99] John Kenneth Scholvin, Approximating the longest path problem with heuristics: a survey, Ph.D. thesis, University of Illinois at Chicago, 1999. [Scu03] Maria Grazia Scutella, An approximation algorithm for computing longest paths, European Journal of Operational Research 148 (2003), no. 3, 584–590. [SW11] R. Sedgewick and K. Wayne, Algorithms, Pearson Education, 2011. [ZL07] Zhao Zhang and Hao Li, Algorithms for long paths in graphs, Theoretical Computer Science 377 (2007), no. 1, 25–34. 15
8cs.DS
1 On Variant Strategies To Solve The Magnitude Least Squares Optimization Problem In Parallel Transmission Pulse Design And Under Strict SAR And Power Constraints arXiv:1309.1567v3 [physics.ins-det] 5 Nov 2013 A. Hoyos-Idrobo, P. Weiss, A. Massire, A. Amadon, N. Boulant Abstract—Parallel transmission is a very promising candidate technology to mitigate the inevitable radiofrequency (RF) field inhomogeneity in magnetic resonance imaging (MRI) at ultra-high field (UHF). For the first few years, pulse design utilizing this technique was expressed as a least squares problem with crude power regularizations aimed at controlling the specific absorption rate (SAR), hence the patient safety. This approach being suboptimal for many applications sensitive mostly to the magnitude of the spin excitation, and not its phase, the magnitude least squares (MLS) problem then was first formulated in 2007. Despite its importance and the availability of other powerful numerical optimization methods, the MLS problem yet has been faced almost exclusively by the pulse designer with the so-called variable exchange method. In this paper, we investigate various two-stage strategies consisting of different initializations and nonlinear programming approaches, and incorporate directly the strict SAR and hardware constraints. Several schemes such as sequential quadratic programming (SQP), interior point (I-P) methods, semidefinite programming (SDP) and magnitude squared least squares (MSLS) relaxations are studied both in the small and large tip angle regimes with RF and static field maps obtained in-vivo on a human brain at 7 Tesla. Convergence and robustness of the different approaches are analyzed, and recommendations to tackle this specific problem are finally given. Small tip angle and inversion pulses are returned in a few seconds and in under a minute respectively while respecting the constraints, allowing the use of the proposed approach in routine. Index Terms—RF parallel transmission, Magnetic resonance imaging, Mathematical programming, optimization. I. Introduction One of the main purposes of Ultra High Field (UHF) magnetic resonance imaging (MRI) is to improve spatial resolution, thanks to an increased signal to noise ratio (SNR). The applicability of most MRI sequences however A. Hoyos-Idrobo, A. Massire, A. Amadon and N. Boulant are with CEA, I2BM, NeuroSpin, UNIRS, Gif sur Yvette, France [email protected] P. Weiss is with ITAV- USR3505, Université de Toulouse, CNRS, France [email protected] The research leading to these results has received funding from the European Research Council under the European Union’s Seventh Framework Program (FP7/2013-2018) / ERC Grant Agreement n. 309674. is challenged due to enhanced non-uniformities in the transmit-sensitivity and off-resonance profiles [1]. If not addressed, these can yield zones of important SNR losses across the images, detrimental to diagnosis. Over the last few years, a lot of research has been devoted to solve the above-mentioned problems, leading to an assortment of new powerful tools including shaped pulses [2], [3], radiofrequency (RF) shimming [4] and transmit SENSE parallel transmission (pTX) [5], [6], [7]. While RF shimming may be useful for very specific applications [8], due to its versatility pTX so far has proved to be almost indispensable to tackle the RF and static field inhomogeneity problem at UHF for specific absorption rate (SAR) demanding sequences [9], [10]. Due to the large number of degrees of freedom pTX provides, there can be many different SAR patterns for a given RF pulse performance. The goal of the RF pulse designer in general then is to find the pattern that satisfies the SAR guidelines [11] with the best pulse performance. Most often, SAR constraints in RF pulse design have either been addressed indirectly through the use of Tikhonov power regularization factors [12], [13], [14], [15], [16] or by focusing on a more tractable, hence significantly smaller, subset of constraints [17], [18]. While the first set of approaches requires the tuning of some parameters, the second one generally does not encompass the complexity of the full SAR spatial distribution. It was not until recently that the crucial development of the virtual observation points (VOPs) [19], [20] made the problem considerably more tractable and facilitated the treatment of all the SAR constraints in RF pulse design utilizing pTX. In [21], the authors could thereby study more thoroughly the trade-offs between the different constraints and the pulse performance in 2D applications. Furthermore, the harder but more beneficial magnitude least squares (MLS) formulation [22], [23] of the pulse design problem was to some extent tackled in the latter work either by identifying a suitable target phase and solving the corresponding least squares problem, or by looping over different least squares problems, the so-called variable exchange method [24]. In most cases otherwise, the MLS problem was not addressed. While this can be justified perhaps for spiral k-space trajectories where the rank of the matrix in the linear system is significant, this 2 can lower pulse performance substantially for more sparse trajectories such as spokes [23] and kT -points [25]. The MLS problem in RF pulse design is equivalent to the phase retrieval problem where a complex signal is sought based on the knowledge of magnitude measurements. It occurs in other branches of physics such as Xray crystallography imaging [26], diffraction imaging [27] and microscopy [28]. The variable exchange method used in the MRI community is identical with the GerchbergSaxton algorithm published in 1972 [29]. Yet, despite the importance of this problem in RF pulse design and its known limitations [30], its use has been ubiquitous in the pulse designers’ community [21], [22], [23], [25]. In this work, we investigate other strategies to solve the MLS problem in 3D, both in the small and the large flip angle (FA) regimes, based on RF field maps measured in-vivo on a human brain at 7 Tesla. The strategies consist of two stages: an initialization and a nonlinear programming approach [31]. Moreover we incorporate all 10-g and global SAR constraints using VOPs, as well as peak and average power constraints. Due to the nonconvexity of the problem, there is no proof that we find the global minimum. However, by exploring different techniques such as sequential quadratic programming, interior point methods, semidefinite programming and magnitude squared least squares relaxations, experience can be built and greater confidence can be gained to finally make useful recommendations. We first present the general context, by defining the mathematical problem and some computational tricks we used to make the problem more tractable. For the sake of clarity and completeness, we then briefly describe the theory behind each technique investigated. Their corresponding performance, execution time and robustness are then presented and discussed. II. Theory The physical examples we shall work with are nonselective kT -points pulses [25] with 30◦ and 180◦ target flip angles. The k-space trajectories in both cases were not optimized and consisted respectively of 5 and 7 kT -points symmetrically located around the centre. The number of kT -points and the number of channels are respectively called NkT and Nc (here equal to 8) throughout. The flip angle (MLS) homogenization problem in the small tip angle approximation (STA) [32], [33] is written as: min k|Ax| − x∈Cp θk22 , (1) where θ denotes the target FA (in rads), A ∈ CN ×p the spins’ dynamics matrix only in the brain region (number of voxels N = 12 000, number of columns p = Nc × NkT ), and x the concatenated RF waveforms of the Nc different channels. The elements of A are given by am,(j−1)Nc +n = isB1,n (rm ) exp(ihrm , kj i) exp (iγ∆B0 (rm ) (T − (j − 1/2)Ts )) . For computational reasons that will appear shortly, and contrary to general practice [7], [13], [14], [15], the elements for each row are ordered first by channel and then by time. Above, ∆B0 corresponds to the static field offset (in Tesla), γ is the gyromagnetic ratio, B1,n (rm ) is the B1 (in µT ) RF field at location rm for maximum voltage (here 180 Volts) corresponding to the nth channel and T is the total pulse duration. The k-space trajectory k(t) is equal to the time-reversed integration of the gradient waveforms to be played during excitation. The index j thus labels the kT -points. Each sub-square pulse is 0.2 ms long for the 30◦ target and 0.5 ms long for the 180◦ target (duration Ts above). The scalar s in the expression as a result is the FA (in rads/µT ) achieved for such a sub-pulse with peak RF amplitude of 1 µT . The time symmetry of the sub-pulses in the low FA regime also implies the 1/2 correction in the ∆B0 evolution in the same expression. To address the SAR constraints, and for the sake of convenience, we use the Q matrices commonly used for SAR calculations [17]. For a single kT -point, these are Q(r) =  σ Ts ExH Ex + EyH Ey + EzH Ez (r), 2ρ T R (2) where σ and ρ are the conductivity and density respectively, T R is the repetition time and Ex , Ey , Ez are the components of the complex electric field row vector at position r along the respective directions for the maximum voltage available on each channel, e.g. Ex (r) = [Ex,1 (r), Ex,2 (r), . . . , Ex,Nc (r)]. The superscript H throughout denotes Hermitian conjugation. Here, we take T R such that the overall duty cycle for the 30◦ and 180◦ pulses are 10 % and 0.25 % respectively. For a single kT -point the SAR at location r for a pulse shape x that way is SAR(r) = xH Q(r)x. Equation (2) then is simply averaged over 10-g of contiguous tissue to obtain the corresponding Q10g (r) matrices. Strictly speaking, thus the number of 10-g SAR constraints is equal to the number of voxels in the head model. In the human head model we describe later on, it is roughly equal to 37 000. To make the problem more tractable, we have used the compression model described in [19]. This model returns a set of VOPs with corresponding QV OP s matrices which guarantees that ∃i ∈ V OP s so that SAR10g,i ≤ max(SAR10g (r)) ≤ SAR10g,i + G SARglobal , r∈Ω (3) where Ω denotes the ensemble of all voxels. Respecting the constraints over the VOPs with a certain pre-defined tolerance hence guarantees to satisfy the constraints in every voxel. The number of VOPs, here denoted as NV OP s throughout for the sake of generality, depends on G , the model and the experimental set-up. In this study, we have taken G = 1, which returned a set of 490 VOPs. A matrix QG was also used to deal with the constraint on global SAR. In addition we incorporate peak power and average power constraints for each channel (again taking into account the duty cycles). Finally the optimization problem for the 30◦ target FA can be summarized as the 3 following: min f (x) := k|Ax| − θk22 x ∈ Cp , ci (x) ≤ 10 W/kg, i ∈ {1, . . . , NV OP s }, cG (x) ≤ 3.2 W/kg, cpw,k (x) ≤ 10 W, k ∈ {1, . . . , Nc }, cA,j (x) = |xj |2 ≤ 1, j ∈ {1, . . . , Nc × NkT }. (4) The functions ci , cG , cA,j and cpw,k are quadratic functions. They denote the 10-g SAR constraints over the VOPs (calculated with QV OP s ), the global SAR constraint (calculated with QG ), the amplitude and the average power for the k th channel (here taken as 10 W) constraints respectively. The values for the SAR constraints above correspond to the guidelines issued by the International Electrotechnical Commission (IEC) [11]. For the inversion pulse, the FA in the objective function in (1) is no longer expressed as a linear relationship but is obtained via the nonlinear function bl (for Bloch): min f (x) := k|bl(x)| − θk22 x ∈ Cp , ci (x) ≤ 3 W/kg, i ∈ {1, . . . , NV OP s }, cG (x) ≤ 1 W/kg, cpw,k (x) ≤ 2 W, k ∈ {1, . . . , Nc }, cA,j (x) ≤ 1, j ∈ {1, . . . , Nc × NkT }. (5) Note that the SAR and average power thresholds here are different than in problem (4). This is because inversion pulses are often used in combination with many additional low FA pulses and that both participate in yielding an effective SAR pattern and an average power. An important example is the MPRAGE sequence, where the duty cycle of that pulse indeed is on the order of 0.25 % (T R ' 2s). This is why the SAR thresholds above have been set, arbitrarily, about 3 times less than the ones recommended by the IEC, keeping in mind that this pulse would likely be used in combination with other small FA pulses. Both problems (4) and (5) are nonconvex optimization problems with nonlinear constraints. All techniques we have explored to solve them make use of the values of the objective function, the constraints and their respective gradients. We detail briefly how these values were calculated later on. All CPU times provided in this paper are for a workstation equipped with an Intel Xeon E5-2620 processor, 16 GB of RAM and using either the Matlab R2013a (The Mathworks, Natick, MA, USA) or the Knitro (Ziena optimization LLC, Evanston, IL, USA) software depending on the algorithms. The Bloch integrations needed for problem (5) were performed with CUDA on a Graphics Processing Unit (GPU) NVIDIA (Santa Clara, CA, USA) Tesla C1060 card. III. Methods reported in [35]. Such a representation was a necessary step to be able to run finite element electromagnetic simulations in HFSS (Ansys, Canonsburg, PA, USA) with our 8-channel pTX coil tuned and matched at 297 MHz to correspond to the proton Larmor frequency at 7 Tesla. Electric fields computed by HFSS were projected onto a 5 × 5 × 5 mm3 Cartesian grid and used to build up the Q matrices of (2). The head model (illustrated in Fig. 1(a)) contains 20 anatomical structure entities with corresponding electric properties, which added up to around 37 000 voxels. The RF and static field maps were acquired at 7 Tesla on a healthy adult volunteer, for which approval was obtained from our institutional review board. The same dataset was used in some of our earlier work [25]. For both RF transmission and reception, a home-made transceiver-array head coil was used (Fig. 1(b)), which consists of eight stripline dipoles distributed every 42.5◦ on a cylindrical surface of 27.6cm diameter, leaving a small open space in front of the subject’s eyes. Relative B1 maps were first acquired using 8 small tip angle FLASH sequences [36], with a small T1 nonlinearity correction. Two reference actual FA acquisitions [37] were then acquired to convert the previous data into absolute maps, with additional echoes in the first repetition time to monitor the ∆B0 evolution. Matrix size was 48 × 48 × 32 with isotropic resolution of 5 mm. These data allowed the encoding of the A matrix in (1). Due to the relative smoothness of the B1 and ∆B0 maps, significant differences in homogeneity when dealing with higher resolution maps are not expected. Finally, although the direct link between the resolution and the number of VOPs is not known to the authors, a higher resolution can lead to increased accuracy of the SAR results but at the possible expense of computational speed. (a) (b) Figure 1. Head model (a) and 8-channel pTX coil (b). Only subcutaneous tissues are shown for illustration in a). Both models of the coil and the head were imported into HFSS to perform finite element electromagnetic simulations. Electric fields were returned for each voxel of the head for a given input power on each transmit element. The electric fields were then used to build the Q matrices in (2) and the VOPs [19], [20] . A. Head model, B1 and ∆B0 maps. The numerical head model we used for the SAR calculations is the one described in [34] whose surface-based representation was obtained from the voxel-based model B. Algorithms The nonconvex problems defined by (4) and (5) are solved using a two stage optimization strategy, where in 4 the first stage an initial vector x is determined and used as an input to the second stage, a nonlinear programming algorithm. The techniques we investigated for the former stage are random initialization, the GerchbergSaxton algorithm [29] and Semidefinite Relaxation (SDR) [30]. For the nonlinear programming stage, we studied the algorithms proposed by the optimization toolbox of Matlab, i.e. the active-set (A-S), Sequential Quadratic Programming (SQP), interior-point (I-P) algorithm, as well as some variants proposed by the Knitro software allowing a user-supplied Hessian of the Lagrangian. 1) Initialization phase Random initialization To increase our chances to find the global minimum, 500 random vectors (uniform distribution) were generated and scaled to satisfy initially all constraints. These inputs were then fed to each different nonlinear programming algorithm. In the large FA case however, and when the Hessian of the Lagrangian was user-supplied, only 50 random vectors were tried due to the long execution time. method also requires an initial phase distribution in the vector u, which we took to be the one of the circularly polarized mode obtained by aligning the phases of the RF field maps at the center of the brain. Finally, the G-S algorithm the way we have presented it so far generates only one candidate x. To generate different candidates, we solved instead the following problem min kAx − diag(θ)uk22 + λkxk22 , u ∈ CN , |ui | = 1, x ∈ Cp , (8) where λ is a regularization parameter which was varied logarithmically from 1 to 300 and 10 000 for the small and large FA targets respectively (500 steps). The range in the latter case indeed was increased as it appeared it generated more variability in the returned input vectors. The G-S algorithm in this case is implemented in the same way this time by using x = Ãλ diag(θ)u where Ãλ = (AH A + λId)−1 AH [23]. Cross-correlations between the corresponding results were calculated to assess their similarities. Semidefinite Relaxation Gerchberg-Saxton Also called variable exchange method [24], this algorithm is inspired from the alternating projection strategy [38] where the problem (1) is reformulated in a way that does not involve the absolute value function by explicitly splitting amplitude and phase contributions, diag(θ) and u, with u satisfying the unity modulus constraint |ui | = 1 for i ∈ {1, . . . , N }. The problem is thus written as min kAx − diag(θ)uk22 u ∈ CN , |ui | = 1, x ∈ Cp , (6) where the optimization procedure is iterated over both variables u ∈ CN and x ∈ Cp . For fixed u, x can be found by solving the unconstrained linear least squares problem: x = A† diag(θ)u, (7) where A† is the Moore-Penrose pseudo-inverse of A. Despite the crude approximation thereby made for the large FA, where the relation between the pulse shape and the FA is nonlinear, it is an easily implementable and quick technique able to return a nonrandom and reasonable guess. The Gerchberg-Saxton (G-S) algorithm projects the current diag(θ)uh on the image of A using the orthogonal projector AA† and correspondingly updates its phase for the new iterate (which is just equivalent to adjust the new phase to the one of Axh ). This procedure is repeated until some convergence criteria are satisfied, e.g. when the cost function varies less than by 1 % from one iteration to the next. Nevertheless, and as the problem is nonconvex in u, this alternating projection method is known to stall in local minima when there are no constraints [30]. This The problem (8) can be expressed as a quadratic programming problem (QP) with variable u by inserting x = Ãλ diag(θ)u in the same equation and setting the positive definite Hermitian matrix M = diag(θ)(Id−AÃλ ) diag(θ) [30], QP (M ) := min uH M u u ∈ CN , |ui | = 1, i ∈ {1, . . . , N }. (9) This problem is equivalent to a Semidefinite Program (SDP) in U = uuH ∈ HN : SDP (M ) := min T r(U M ) U ∈ HN , diag(U ) = 1, U  0, Rank(U ) = 1. (10) The Semidefinite Relaxation (SDR) is obtained by dropping the nonconvex rank constraint and is known to have theoretical guarantees about the global minimum when there are no additional constraints. When the solution has rank one, the relaxation is tight and the vector u is an optimal solution to the problem defined by (9) [30]. If the solution has rank larger than one, a normalized leading eigenvector of U is used as a candidate solution. In practice, the semidefinite programing solvers are rarely designed to handle complex matrices. Therefore the complex programs are often reformulated using the linear transformation T that maps Hermitian complex matrices HN in to real semi-definite positive matrices in S2N [39],   Re(M ) −Im(M ) T (M ) = . (11) Im(M ) Re(M ) We used the code available at (http://www.cmap. polytechnique.fr/scattering/code/phaserecovery.zip), 5 which is a block-coordinate descent method, to solve this new problem. Because solving this problem using this approach took several hours given the size of the matrices, we tried only three different values of λ to generate different initial guesses (1, 100, and 300 for the small FA and 1, 100 and 10 000 for the large FA). These candidates likewise were then fed as initial starting points to the nonlinear programming algorithms we investigated. differences being: the strict feasibility with respect to bounds, this is beneficial when the objective function or the nonlinear constraints functions are undefined or are complex outside the region constrained by the bounds; feasibility routines are reformulated; SQP algorithm is more robust to non-double results, hence it tries to ensure numerical convergence; the linear algebra routines are refactored in order to be more efficient in memory usage and speed. 2) Nonlinear programming Some of the most successful large scale algorithms for generally constrained nonlinear optimization fall into one of two categories [40]: active-set sequential quadratic programming methods and interior-point or barrier methods. Active-set methods can quickly generate a good working set of active constraints, i.e. the ones that satisfy the constraint equalities in Problems (4) and (5), and then perform a minimization on the smaller dimensional subspace generated by this set of linearized and active constraints which are iteratively updated. The constraints that are estimated to be nonactive at the solution point are simply disregarded. Interior-point methods on the other hand always attempt enforcing all the constraints by using barrier penalty functions which progressively vanish as the number of iterations increases. The efficiency and the scaling of these schemes with respect to the size of the problem heavily depend on the particular problem of interest [41]. We now briefly detail these methods. Active-set methods They consist of a (Quasi-)Newton procedure where at each step the problem is approximated by a QP with the constraints linearized [41]. Let QP (xh , Hh ) denote the following problem: min 12 dH Hh d + ∇f (xh )H d d ∈ Cp , ci (xh ) + ∇ci (xh )H d ≤ 10 W/Kg, i ∈ {1, . . . , NV OP s }, cG (xh ) + ∇cG (xh )H d ≤ 3.2 W/Kg, cpw,k (xh ) + ∇cpw,k (xh )H d ≤ 10 W, k ∈ {1, . . . , Nc }, cA,j (xh ) + ∇cA,j (xh )H d ≤ 1, j ∈ {1, . . . , Nc × NkT }, (12) h where d = x − x is the unknown step vector to take at the hth iteration and Hh is the Hessian of the Lagrangian updated in the Matlab implementation via the Broyden-Fletcher-Goldfarb-Shanno (BFGS) method [41]. The basic principle of the A-S algorithm is to solve problem (12) and estimate the active constraints via a calculation of the Lagrange multipliers. At each iteration the constraints believed to be nonactive at the solution point are simply disregarded (but can be reincorporated at a later iteration). For those that are active, the linear constraints above allow to find a subspace tangent to these in which a search direction is determined. The SQP implementation of Matlab is similar to A-S [42], the main Interior-Point Methods The I-P approach consists of approximating the problem by a sequence of equality constrained problems that are easier to solve than the original inequality-constrained problem [40]. It reads: P (13) min f (x) − µk l∈J log(sl ) ci (x) + si = 10 W/Kg, i ∈ {1, . . . , NV OP s }, cG (x) + sG = 3.2 W/Kg, cpw,k (x) + spw,k = 10 W, k ∈ {1, . . . , Nc }, cA,j (x) + sA,k d = 1, j ∈ {1, . . . , Nc × NkT }, sl ≥ 0, l ∈ J , where J is the set of constraints, s is a vector of slack variables and µk > 0 is the sequence of the barrier parameter with limk→+∞ µk = 0. There are two main classes of I-P methods [40]. The first class can be viewed as direct extensions of I-P methods for linear and quadratic programming. They use line searches to enforce convergence, computing the descent steps by solving a system of equations corresponding to the Karush-Kuhn-Tucker [40] conditions; they are also called I-P with direct step. The methods in the second class use a quadratic model to define the step and incorporate a trust-region constraint to provide stability; they are also called I-P with conjugate gradient (CG) step [40]. Matlab exploits both classes in its implementation. In both I-P and A-S methods, the number of iterations, i.e. the number of times problem (12) or problem (13) was solved, was set equal to 60 which was enough in this particular problem to reach convergence towards a local minimum. C. Implementation 1) Calculation of the objective function, the SAR constraints and their respective gradients. Given a candidate solution x the objective function in the small tip angle regime is calculated easily by using (4), where most of the computation consists of multiplying the matrix A with the vector x and taking an l2 -norm. Because most optimization algorithms do not deal directly with complexvariables, we first split x into two parts:   the vector  Re(x) Re(x) . The gradient ∇f could be obtained by Im(x) Im(x) f (x + ej ) − f (x) ∂f (x) ' , blind finite difference with ∂xj  where ej is an elementary vector (1 at one position and zero elsewhere) but this would imply calculating the same 6 kind of matrix-vector product for each degree of freedom, i.e. 2 × Nc × NkT times (here 80 for the small FA pulse). By denoting aj the j th column of the matrix A, instead by linearity one has A(x+ej ) = Ax+aj , for the first half of the gradient√vector and Ax + iaj−p , for the second half, where i = −1. The product Ax thereby is performed only once. This saves many unnecessary calculations. At the end of the procedure, the normalized root mean square s N P 1 error (NRMSE) (θi − θ)2 /θ is provided. In the N i=1 large tip angle regime, the objective function is calculated by using (5), where most of the computation consists of carrying a full Bloch simulation over all voxels and taking an l2 -norm. Its gradient in this case is evaluated via finite differences. The evaluation of the objective function, thus a crucial step to make this approach feasible in routine, was performed by using CUDA and a GPU card. For one kT -point, the SAR for one VOP for a pulse shape x is equal to cV OP (x) = xH QV OP x. For NkT kT -points back to back, the result conveniently becomes cV OP (x) = xH (IdNkT ⊗QV OP )x thanks to the ordering of the elements in the A matrix, where IdNkT is the Identity matrix of size NkT and ⊗ is the Kronecker product. If NkT is not small, the matrix sandwiched between the x vectors is sparse and can be declared as such to speed up the computations. Most importantly, the gradient of the SAR hence has the following analytical expression:     Re((IdNkT ⊗ QV OP )x) Re(x) ∇cV OP =2 . Im(x) Im((IdNkT ⊗ QV OP )x) Although the VOPs considerably reduce the size of the problem, doing a loop over all of them to calculate the SAR would be suboptimal, especially for less compressed models. If Ic is the matrix whose columns are the NT time point waveforms of the different channels, for 100 % of duty cycle the SAR at one spatial location can be calculated using the following formula [43]: SAR = Nc X Nc X H I Qm,n Ic,m c,n , (14) m=1 n=1 = 1T   Q 1 H I Ic NT c  1, (15) where 1T = [1, . . . , 1] ∈ RNc , the operator on the right hand side denotes the Hadamard product and the bar denotes a time average. For one voxel, this formula already saves looping over the different time points. To calculate the SAR value over all the VOPs, we simply compute:      1 ... 0      SAR = 1T Qcat IcH Ic , . . . , IcH Ic   ... . . . ...  , | {z } 0 ... 1 NV OP s times (16) where Qcat = [Q1 , . . . , QNV OP s ]. The matrix on the far right contains NV OP s × Nc rows and should be declared as sparse (1.6 % of the elements are nonzeros in our case). Each column of that matrix contains 8 consecutive ones which isolate a Q matrix. This way, all SAR values are computed in one shot with optimized algebra routines and with no for loops, often time-consuming in Matlab implementations. All matrices besides IcH Ic are built once and for all throughout. Finally, because analytical formulas likewise exist for the gradients of the peak and average power constraints, they can be calculated very efficiently as well. 2) MSLS problem and the Hessian of the Lagrangian. Since the objective function defined by (1) is not everywhere differentiable, gradient-based methods are not well defined and can cause problems. For that reason we attempted to solve the original MLS problem by using a variant that is different but closely related, i.e. the Magnitude Squared Least Squares (MSLS) problem [24], still under the same constraints as in the MLS problems (4) and (5): min f (x) := k|g(x)|2 − θ2 k22 , x∈Cp (17) where g(x) = Ax and g(x) = bl(x) for the small and large tip angle regimes respectively. In the small FA regime the gradient and the Hessian of the Lagrangian are determined analytically [24] and supplied at moderate cost to the Knitro solver (Matlab does not accept a user-supplied Hessian for the A-S and I-P methods). Like for SDP, in order to work with real variables, the linear transformation defined by (11) is applied to A, M = T (A) and setting Mj = [colj (M ), colp+j (M )], the gradient and the Hessian of the objective function are [24] ∇f (x) = 4 N X (xH Mi MiH x − θ2 )Mi MiH x i=1 and ∇2 f (x) =4 N X 2Mi MiH xxH Mi MiH i=1 + (xH Mi MiH − θ2 )Mi MiH respectively. For the large tipangle regime the Hessian  Re(x) 2 of the function, ∇ f , was obtained by blind Im(x) finite differences. Second derivatives for the SAR and power constraints were trivially added to this contribution to return the Hessian of the Lagrangian. Based on this reformulation we investigated likewise the A-S and I-P methods. Knitro on the other hand provides the user with the choice of using either the direct or CG approach for the latter, so that both were tried. Despite the use of a GPU to calculate the objective function and the finite differences in the large tip angle regime, calculating explicitly the Hessian significantly increased the numerical burden compared to the much faster, but approximate, BFGS update method. However the goal in using the MSLS problem reformulation was to investigate potential gains in the returned RF pulse performance (NRMSE) by exploiting full knowledge of the Hessian matrix of the Lagrangian. Because of the longer duration of this 7 implementation (around 20 minutes per run), only 50 random and 50 G-S initializations were performed in the large FA case (as opposed to 500 for the small FA). Semidefinite relaxation, as presented above, was also used to supply three different initial guesses to the Knitro solver. Knowledge of the Hessian allowed faster convergence in terms of number of iterations, which was therefore set to 30. 3) Summary of the different approaches. We summarize the different schemes investigated in this paper for the reader’s convenience. Initializations were performed using: random draws, the G-S algorithm and SDR. The problem of interest is the MLS problem defined in (4) and (5). Both A-S and I-P methods were attempted using a Hessian of the Lagrangian updated by the BFGS method for Matlab and a user-supplied one for Knitro (determined analytically for the small FA problem and via finite differences for the large FA one). The MSLS variant was used in the latter case. IV. Results The cross-correlation among the different input vectors varied between 0.5 and 1 for the random draws, while the one among the vectors generated by the G-S algorithm varied between 0.65 and 1, which indicates a significant variability in the input states. Fig.2 provides the box plots showing the variability of the final NRMSEs with the random initialization procedure combined with the different algorithms. In the small FA regime one can observe a smaller variability within the 1.5 interquartile range for the A-S methods compared to the I-P ones, except for the I-P direct approach in the MSLS formulation. The result however is opposite for the high FA problem with a higher robustness achieved for the I-P method in the original MLS formulation. (a) Low flip angle regime (b) High flip angle regime Figure 2. Box plots obtained for the small (a) and the large tip angle regimes (b). The small horizontal lines correspond to the lowest and highest data within 1.5 interquartile range below the first and above the third quartiles respectively. The crosses are the outliers. The plots were generated with 500 random samples for all approaches except for the MSLS variant in the large FA regime (50 random samples). Table I summarizes the best NRMSEs obtained for the small and large FAs and for each algorithm, along with their execution times (not including the initialization routine which, besides the SDR method, takes negligible time). The constraints before and after each algorithm are also reported in the second table, the initializations being the ones leading to their best respective results. The SDR initialization method returned matrices whose ranks were always far larger than 1 so that no statements about global optimality (without constraints) could be made. The differences between the A-S and SQP implementations of Matlab were minor. The SQP program was slightly slower but guaranteed at the end the strict respect of all the constraints. The A-S technique could on the other hand return a result where the constraints could be, very slightly, violated. Execution time naturally varied significantly depending on the evaluation method of the Hessian (analytical, BFGS or finite differences), the evaluation of the objective function and its gradient (STA, Bloch simulation, finite differences), the algorithm and its starting point. Solving the MSLS problem with Knitro in the large FA regime for instance takes nearly 20 minutes due to the evaluation of the Hessian via finite differences, even when using a GPU card. Solving the MLS problem using the A-S approach and the BFGS update method on the other hand takes 6 and 47 seconds for the small and large FAs respectively. The best NRMSEs found therefore are 5.65 and 8.72 % for the 30◦ and 180◦ target FAs respectively. With a tolerance of 0.3 % for the NRMSE, when starting from a random initial guess the probabilities to converge to these results were for the different algorithms respectively 84, 84, 0, 86, 88, and 69 % (same order as in table I) for the small FA target, indicating a high robustness of the algorithms with a cold start input, except for the I-P implementation of Matlab. The numbers are even more encouraging when the initializations are performed via the G-S algorithm, indicating a very high robustness for these algorithms, especially in the A-S and SQP implementations, when a warm start is provided. These numbers are 100, 100, 0, 90, 91, and 60 %. The A-S and SQP methods thus are seen to be very robust with a cross-correlation between the final output solutions varying between 0.98 and 1. As far as the large FA target is concerned, the results indicate, perhaps not surprisingly, a higher sensitivity with respect to the initial starting point when setting a tolerance of 2 % on the NRMSE, this time the I-P method being the most robust (see Fig. 2(b)). With that tolerance, the probabilities were 70, 75, 84, 36, 66 and 28 % for the random initializations; and 62, 61, 83, 68, 86 and 30 % for the G-S initialization. The I-P (MLS) approach as a result seems more robust for the large flip angle case but yields slightly worse NRMSE on average than the A-S and SQP methods (see Fig. 2(b)), and can take almost twice longer to execute (see Fig. 3(b)). Moreover, for the G-S initializations it is worth pointing that as soon as the Tikhonov parameter exceeded the value of 1000, all MLS methods converged towards their respective minimum with 100 % probability. The A-S or SQP method combined with a G-S initialization and a strong power regularization hence still appears the method of choice in the large FA regime. Despite the differences between 8 Table I Best NRMSE in % and execution time in seconds (in parenthesis) obtained for each initialization/algorithm combination for the small FA (SFA) and large FA (LFA) regimes. hhhh h hhAlgorithm hhhh MLS (Matlab) LFA SFA Initialization Random G-S SDR Random G-S SDR A-S 5.67 (6) 5.70 (6) 5.65 (8) 8.94 (49) 8.90 (47) 9.42 (49) SQP 5.67 (7) 5.71 (8) 5.65 (9) 9.00 (78) 8.91 (77) 9.49 (48) I-P direct & CG 6.70 (9) 7.24 (8) 12.67 (11) 10.22 (44) 10.20 (38) 10.34 (44) the original MLS problem and the MSLS reformulation, the numerical experiments performed indicate (but do not prove) that the exact knowledge of the Hessian is not required and that much faster, but approximate, methods such as the BFGS-update method return equally good results. To illustrate convergence speed, we calculated the NRMSE versus CPU time for each algorithm and by selecting the initial starting point which both verifies the constraints and leads to the best NRMSE achieved in all runs. (a) Low flip angle regime MSLS (Knitro) (b) High flip angle regime Figure 3. NRMSE versus CPU time for the different algorithms in the small (a) and large (b) FA regimes. The plots for the MSLS variant in the large FA regime are not included due to the timeconsuming calculation of the Hessian of the Lagrangian, resulting in a much longer execution time (∼ 20 min). In the small FA regime the plots corresponding to the SQP and A-S algorithms are almost indistinguishable. Here, for all algorithms, the initial starting point was chosen based on two criteria: feasibility with respect to all constraints and best NRMSE obtained among all numerical trials performed in this study. This best NRMSE was obtained with a random input vector, thus yielding initially a high cost function. While it seemed not critical for the A-S methods to start with a feasible point to achieve a very good result, the theory behind I-P methods assumes such a starting point. Results are indicated in Figure 3 both for the small and large FA problems. The corresponding FA maps over the 3 dimensional brain are calculated via a Bloch simulation and are provided in Figure 4, also with the relative saturation of the different constraints indicated in bar graphs (i.e. how far the returned values are from their respective limits). In our case, it seemed that average power and peak amplitude were the most critical constraints for the small FA design, whereas the most critical constraint in the large FA regime was by far the amplitude. A-S 5.68 (40) 5.68 (47) 5.77 (40) 8.83 (1 369) 8.72 (1 351) 9.57 (1 357) I-P direct 5.68 (35) 5.73 (33) 6.42 (37) 8.76 (1 124) 8.74 (1 119) 9.03 (1 116) I-P CG 5.73 (34) 5.69 (33) 10.72 (36) 9.07 (1 126) 8.83 (1 111) 12.54 (1 117) V. Discussion A practical evaluation of optimization algorithms is complicated by details of implementation, heuristics and algorithmic options. In this paper, it is worth stressing that the numerical experiments we have carried out made use of different algorithms provided by different solvers (Matlab, Knitro) with their default options. Furthermore we found that variants of the I-P methods (CG and direct) could behave very differently for the MSLS problem. In those same methods, the evolution of the barrier parameter µ with respect to the number of iterations likewise can have a great impact on the final result [21]. Therefore it is not excluded that slightly different implementations of the same class of algorithms could lead to better results. Our goal here however was to provide a readily implementable solution. Surprisingly, it was also found that the BFGS approximation of the Hessian of the Lagrangian led to equally good results as the ones returned when the Hessian was fully calculated, however for the MSLS variant. This is a useful result which allows to significantly speed up the implementation at no performance expense. Among all algorithms and initializations we have tested, our recommendation depends on the tolerance one may have on the satisfaction of the constraints. Both A-S and SQP implementations are robust with respect to the initialization in the small FA regime, as long as the input is plausible (generated for instance quickly by the G-S algorithm). In the large FA regime, the best performance was obtained with the A-S method but this time a smaller robustness with respect to the input state was observed. Initializations performed with the G-S method and a high regularization parameter returned the best result in a reliable manner. Whereas A-S is a bit faster than SQP, the constraints may be slightly violated at the end (by a few % at the most). Although this can be acceptable for instance for the SAR or average power constraints, this solution would not be accepted by the MRI scanner if the peak power limit was exceeded. This however can be checked a posteriori and corrected by truncating or renormalizing the waveforms, provided the performance is not too much affected. The SQP algorithm on the other hand should return a solution leading to a strict nonviolation of the constraints. For the 3D kT -points tests we have studied, the gain in computation time for the A-S method versus SQP seemed certainly worth the 9 (a) Low flip angle regime (b) High flip angle regime Figure 4. Flip-angle maps obtained for the small (a) and the large tip angle regimes (b). The bar graphs on the left side of the maps indicate in a percentile way how far from their limits the constraints are ("A" is for amplitude, "M" for the maximum average power among the different channels, "L" for local SAR and "G" for global SAR). The numbers in the left of the FA maps correspond to the NRMSE. LFA SFA Table II Peak power (A) (without units), maximum average power (P) (W), maximum 10-g SAR (L) (W/kg) and global SAR (G) (W/kg) corresponding to Table I before and after each algorithm. The initializations here correspond to the ones leading to the lowest NRMSE for each algorithm. A-S (MLS) SQP (MLS) I-P Direct & CG (MLS) A-S (MSLS) I-P Direct (MSLS) I-P CG (MSLS) A-S (MLS) SQP (MLS) I-P Direct & CG (MLS) A-S (MSLS) I-P Direct (MSLS) I-P CG (MSLS) A 0.81 0.81 0.57 0.37 0.50 0.84 0.72 0.83 0.81 0.50 0.65 0.82 After initialization P L G 10.17 5.15 0.85 10.29 5.19 0.85 5.51 2.60 0.49 2.81 0.95 0.22 4.34 1.71 0.38 11.82 5.78 0.93 0.06 0.10 0.03 0.07 0.12 0.03 0.07 0.11 0.03 0.03 0.05 0.01 0.05 0.08 0.02 0.07 0.12 0.03 possible post-correction on the waveforms, which would take negligible time. Despite the good results obtained in [21], our results also seem to indicate that it is more efficient to tackle the MLS problem under constraints directly rather than looping over constrained least-squares problems where the phase of the target FA is updated at each iteration [21]. For the small FA pulse, the best performance we could find was 5.65 %, which is comparable to our previous results [25], [9] except this time no tuning of parameters was required to enforce all constraints. For the inversion pulse, the best performance obtained was 8.72 % using the A-S algorithm, the MSLS variant, and a 3.5 ms kT -points pulse, but in almost 20 minutes. A slightly higher NRMSE of 8.90 % on the other hand could be obtained in 47 seconds still using the A-S technique on the MLS problem. This is worse than the 6 % inhomogeneity we had obtained using an optimal control approach, a pulse duration of 5.9 ms and in around 3 minutes [9]. Considering however the much smaller number of degrees of freedom we used here (112 versus 94 000), the substantially shorter pulse duration and the fact that the SAR constraints this time were directly incorporated, this result is quite remarkable A 0.94 0.94 0.66 0.94 0.93 0.93 1.00 1.00 0.93 1.00 1.00 1.00 After algorithm P L 10.00 6.95 10.00 6.97 7.44 2.46 10.00 7.67 10.00 6.65 10.00 7.05 0.19 0.42 0.19 0.42 0.13 0.26 0.19 0.38 0.18 0.38 0.18 0.35 G 1.55 1.55 0.47 1.73 1.60 1.66 0.10 0.10 0.06 0.10 0.10 0.09 and is likely due to the use of second order methods compared to gradient descent approaches [9]. Furthermore, note that 8.90 % inhomogeneity is significantly better than what is typically measured at 3 Tesla using a birdcage coil ( ∼ 12 %) [44]. This performance and efficiency to design such pulses thus allows to mitigate the RF inhomogeneity problem at UHF in standard T1 -weighted imaging sequences such as the MPRAGE in very reasonable time and thus in routine. VI. Conclusion In this paper we have investigated several initializations and nonlinear programming methods to solve the MLS problem in RF pulse design utilizing parallel transmission at UHF, under strict SAR and hardware constraints, both in the small (linear) and large (nonlinear) FA regimes. Our final recommendation in both cases is the use of an A-S (or SQP) method combined with a G-S initialization with strong power regularization to yield the lowest NRMSE in the most efficient way. Moreover, the combination of these techniques leads to an execution time that is sufficiently small for the approach to be implemented in routine, although the use of parallel computing devices (GPUs in 10 our case) seems at this point a necessity for the design of large FA pulses. [18] References [1] V. de Moortele, C. Akgun, G. Adriany, S. Moeller, J. Ritter, C. M. Collins, M. B. Smith, J. T. Vaughan, K. Uğurbil et al., “B1 destructive interferences and spatial phase patterns at 7T with a head transceiver array coil,” Magn Reson Med, vol. 54, no. 6, pp. 1503–1518, 2005. [2] J. Moore, M. Jankiewicz, A. W. Anderson, and J. C. Gore, “Evaluation of non-selective refocusing pulses for 7T MRI,” J Magn Reson, vol. 214, pp. 212–220, 2012. [3] N. Boulant, J.-F. Mangin, and A. Amadon, “Counteracting radio frequency inhomogeneity in the human brain at 7 Tesla using strongly modulating pulses,” Magn Reson Med, vol. 61, no. 5, pp. 1165–1172, 2009. [4] G. Adriany, V. de Moortele, F. Wiesinger, S. Moeller, J. P. Strupp, P. Andersen, C. Snyder, X. Zhang, W. Chen, K. P. Pruessmann et al., “Transmit and receive transmission line arrays for 7 Tesla parallel imaging,” Magn Reson Med, vol. 53, no. 2, pp. 434–445, 2005. [5] U. Katscher, P. Börnert, C. Leussler, and J. S. van den Brink, “Transmit sense,” Magn Reson Med, vol. 49, no. 1, pp. 144–150, 2003. [6] Y. Zhu, “Parallel excitation with an array of transmit coils,” Magn Reson Med, vol. 51, no. 4, pp. 775–784, 2004. [7] W. Grissom, C.-y. Yip, Z. Zhang, V. A. Stenger, J. A. Fessler, and D. C. Noll, “Spatial domain method for the design of RF pulses in multicoil parallel excitation,” Magn Reson Med, vol. 56, no. 3, pp. 620–629, 2006. [8] J. Ellermann, U. Goerke, P. Morgan, K. Ugurbil, J. Tian, S. Schmitter, T. Vaughan, and P.-F. Van De Moortele, “Simultaneous bilateral hip joint imaging at 7 Tesla using fast transmit B1 shimming methods and multichannel transmission– a feasibility study,” NMR Biomed, vol. 25, no. 10, pp. 1202– 1208, 2012. [9] M. Cloos, N. Boulant, M. Luong, G. Ferrand, E. Giacomini, M.F. Hang, C. J. Wiggins, D. Le Bihan, and A. Amadon, “Paralleltransmission-enabled magnetization-prepared rapid gradientecho T1-weighted imaging of the human brain at 7T,” Neuroimage, vol. 62, no. 3, pp. 2140–2150, 2012. [10] A. Massire, M. A. Cloos, A. Vignaud, D. Le Bihan, A. Amadon, and N. Boulant, “Design of non-selective refocusing pulses with phase-free rotation axis by gradient ascent pulse engineering algorithm in parallel transmission at 7T,” J Magn Reson, vol. 230, pp. 76–83, 2013. [11] IEC, International standard, medical electrical equipment -part 2: particular requirements for the safety of Magnetic Resonance equipment for medical diagnosis, 3rd ed., 2011. [12] A. Zelinski, V. Goyal, L. Angelone, G. Bonmassar, L. Wald, and E. Adalsteinsson, “Designing RF pulses with optimal specific absorption rate (SAR) characteristics and exploring excitation fidelity, SAR and pulse duration tradeoffs,” in Proc. of the 15th Annual Meeting of ISMRM, 2007, p. 1699. [13] A. Sbrizzi, H. Hoogduin, J. J. Lagendijk, P. Luijten, G. L. Sleijpen, and C. A. van den Berg, “Time efficient design of multi dimensional RF pulses: application of a multi shift CGLS algorithm,” Magn Reson Med, vol. 66, no. 3, pp. 879–885, 2011. [14] C. M. Deniz, L. Alon, R. Brown, D. K. Sodickson, and Y. Zhu, “Specific absorption rate benefits of including measured electric field interactions in parallel excitation pulse design,” Magn Reson Med, vol. 67, no. 1, pp. 164–174, 2012. [15] M. A. Cloos, M. Luong, G. Ferrand, A. Amadon, D. Le Bihan, and N. Boulant, “Local SAR reduction in parallel excitation based on channel-dependent Tikhonov parameters,” J Magn Reson Imaging, vol. 32, no. 5, pp. 1209–1216, 2010. [16] A. Sbrizzi, H. Hoogduin, J. J. Lagendijk, P. Luijten, G. L. Sleijpen, and C. A. van den Berg, “Fast design of local Ngram-specific absorption rate–optimized radiofrequency pulses for parallel transmit systems,” Magn Reson Med, vol. 67, no. 3, pp. 824–834, 2012. [17] I. Graesslin, F. Schweser, B. Annighoefer, S. Biederer, U. Katscher, K. Nehrke, H. Stahl, H. Dingemans, G. Mens, and P. Bornert, “A minimum SAR RF pulse design approach for parallel Tx with local hot spot suppression and exact fidelity [19] [20] [21] [22] [23] [24] [25] [26] [27] [28] [29] [30] [31] [32] [33] [34] [35] [36] constraint,” in Proc. of the 16th Annual Meeting ISMRM, Toronto, Canada, 2008, p. 621. D. O. Brunner and K. P. Pruessmann, “Optimal design of multiple-channel RF pulses under strict power and SAR constraints,” Magn Reson Med, vol. 63, no. 5, pp. 1280–1291, 2010. G. Eichfelder and M. Gebhardt, “Local specific absorption rate control for parallel transmission by virtual observation points,” Magn Reson Med, vol. 66, no. 5, pp. 1468–1476, 2011. J. Lee, M. Gebhardt, L. L. Wald, and E. Adalsteinsson, “Local SAR in parallel transmission pulse design,” Magn Reson Med, vol. 67, no. 6, pp. 1566–1578, 2012. B. Guérin, M. Gebhardt, S. Cauley, E. Adalsteinsson, and L. L. Wald, “Local specific absorption rate (SAR), global SAR, transmitter power, and excitation accuracy trade-offs in low flipangle parallel transmit pulse design,” Magn Reson Med, 2013. A. Kerr, Y. Zhu, and J. Pauly, “Phase constraint relaxation in parallel excitation pulse design,” in Proc. of the 15th Annual Meeting of ISMRM, 2007, p. 1694. K. Setsompop, L. Wald, V. Alagappan, B. Gagoski, and E. Adalsteinsson, “Magnitude least squares optimization for parallel radio frequency excitation design demonstrated at 7 Tesla with eight channels,” Magn Reson Med, vol. 59, no. 4, pp. 908–915, 2008. P. W. Kassakian, “Convex approximation and optimization with applications in magnitude filter design and radiation pattern synthesis,” Ph.D. dissertation, University of California, Berkeley, 2006. M. Cloos, N. Boulant, M. Luong, G. Ferrand, E. Giacomini, D. Le Bihan, and A. Amadon, “kT-points: Short threedimensional tailored RF pulses for flip-angle homogenization over an extended volume,” Magn Reson Med, vol. 67, no. 1, pp. 72–80, 2012. R. W. Harrison, “Phase problem in crystallography,” JOSA A, vol. 10, no. 5, pp. 1046–1055, 1993. O. Bunk, A. Diaz, F. Pfeiffer, C. David, B. Schmitt, D. K. Satapathy, and J. Veen, “Diffractive imaging for periodic samples: retrieving one-dimensional concentration profiles across microfluidic channels,” Acta Crystallographica Section A: Foundations of Crystallography, vol. 63, no. 4, pp. 306–314, 2007. J. Miao, T. Ishikawa, Q. Shen, and T. Earnest, “Extending x-ray crystallography to allow the imaging of noncrystalline materials, cells, and single protein complexes,” Annu Rev Phys Chem, vol. 59, pp. 387–410, 2008. R. Gerchberg and W. Saxton, “A practical algorithm for the determination of phase from image and diffraction plane pictures,” Optik, vol. 35, p. 237, 1972. I. Waldspurger, A. d’Aspremont, and S. Mallat, “Phase recovery, maxcut and complex semidefinite programming,” arXiv preprint arXiv:1206.0102, 2012. T.-H. Chang, Z.-Q. Luo, C. Akgun, T. Vaughan, K. Ugurbil, and P.-F. Van de Moortele, “Transmit b1 shimming at high field with sar constraints: A two stage optimization method independent of the initial set of rf phases and amplitudes,” in Proc. of the 16th Annual Meeting ISMRM, Toronto, Canada, 2008, p. 1088. J. Pauly, D. Nishimura, and A. Macovski, “A k-space analysis of small-tip-angle excitation,” J Magn Reson, vol. 81, no. 1, pp. 43–56, 1989. N. Boulant and D. I. Hoult, “High tip angle approximation based on a modified Bloch–Riccati equation,” Magn Reson Med, vol. 67, no. 2, pp. 339–343, 2012. A. Massire, M. A. Cloos, M. Luong, A. Amadon, A. Vignaud, C. J. Wiggins, and N. Boulant, “Thermal simulations in the human head for high field MRI using parallel transmission,” J Magn Reson Imaging, vol. 35, no. 6, pp. 1312–1321, 2012. N. Makris, L. Angelone, S. Tulloch, S. Sorg, J. Kaiser, D. Kennedy, and G. Bonmassar, “MRI-based anatomical model of the human head for specific absorption rate mapping,” Medi Biol Eng Comput, vol. 46, no. 12, pp. 1239–1251, 2008. P. Van de Moortele, C. Snyder, L. DelaBarre, G. Adriany, J. Vaughan, and K. Ugurbil, “Calibration tools for RF shim at very high field with multiple element RF coils: from ultra fast local relative phase to absolute magnitude B1+ mapping,” in Proc. of the 15th Annual Meeting of ISMRM, Berlin, Germany, 2007, p. 1676. 11 [37] V. L. Yarnykh, “Actual flip-angle imaging in the pulsed steady state: A method for rapid three-dimensional mapping of the transmitted radiofrequency field,” Magn Reson Med, vol. 57, no. 1, pp. 192–200, 2007. [38] H. H. Bauschke and P. L. Combettes, Convex analysis and monotone operator theory in Hilbert spaces. Springer, 2011. [39] M. X. Goemans and D. Williamson, “Approximation algorithms for MAX-3-CUT and other problems via complex semidefinite programming,” in Proc. of the thirty-third annual ACM symposium on Theory of computing. ACM, 2001, pp. 443–452. [40] J. Nocedal and S. Wright, Numerical Optimization, 2nd ed. New York: Springer, 2006. [41] L. Hei, J. Nocedal, and R. A. Waltz, “A numerical study of active-set and interior-point methods for bound constrained optimization,” in Modeling, Simulation and Optimization of Complex Processes. Springer, 2008, pp. 273–292. [42] S. Han, “A globally convergent method for nonlinear programming,” JOTA, vol. 22, no. 3, pp. 297–309, 1977. [43] I. Graesslin, H. Homann, S. Biederer, P. Börnert, K. Nehrke, P. Vernickel, G. Mens, P. Harvey, and U. Katscher, “A specific absorption rate prediction concept for parallel transmission MR,” Magn Reson Med, vol. 68, no. 5, pp. 1664–1674, 2012. [44] N. Boulant, D. L. Bihan, and A. Amadon, “Strongly modulating pulses for counteracting RF inhomogeneity at high fields,” Magn Reson Med, vol. 60, no. 3, pp. 701–708, 2008.
5cs.CE
ENTROPY OF BERNOULLI CONVOLUTIONS AND UNIFORM EXPONENTIAL GROWTH FOR LINEAR GROUPS arXiv:1510.04043v2 [math.CA] 1 Jun 2016 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Abstract. The exponential growth rate of non polynomially growing subgroups of GLd is conjectured to admit a uniform lower bound. This is known for non-amenable subgroups, while for amenable subgroups it is known to imply the Lehmer conjecture from number theory. In this note, we show that it is equivalent to the Lehmer conjecture. This is done by establishing a lower bound for the entropy of the random walk on the semigroup generated by the maps x 7→ λ · x ± 1, where λ is an algebraic number. We give a bound in terms of the Mahler measure of λ. We also derive a bound on the dimension of Bernoulli convolutions. 1. Introduction A Bernoulli convolution P with nparameter λ is the distribution µλ of the infinite random series n>0 ±λ , where the ± are independent fair coin tosses, and λ is a real number between 0 and 1. Such measures appear in a large number of situations in harmonic analysis and dynamical systems. A key question regarding them, arguably the most puzzling, is asking for which values of λ is this distribution absolutely continuous with respect to Lebesgue measure. If λ < 1/2, then µλ is singular, being supported on a Cantor set. Surprisingly, there is a family of λ’s greater than 1/2 with singular µλ (the inverses of the Pisot numbers in (1, 2), see [17]). It is a well-known question of Erdős to determine whether or not µλ is absolutely continuous whenever λ is real and close enough to 1, see [17, 38]. If µλ is absolutely continuous, then its dimension dim µλ coincides with the dimension of Lebesgue measure, namely 1. In [25], M. Hochman made a breakthrough in this direction, by establishing that dim µλ = 1 unless λ ∈ ( 21 , 1) is almost algebraic in the sense that there is a sequence of degree n polynomials pn with coefficients in {−1, 0, 1} such that pn (λ) tends to 0 super-exponentially fast. It is easily seen that the set of almost algebraic numbers has packing dimension zero, and this was further exploited by Shmerkin [42] to obtain that µλ is absolutely continuous for all λ ∈ ( 21 , 1), except perhaps for a subset of λ’s of Hausdorff dimension zero. (We recall that a set of 0 packing dimension is also of 0 Hausdorff dimension.) In the first part of this paper we will study the opposite situation when λ is assumed to be an algebraic number. In this case the study of Bernoulli convolutions is closely related to another famous conjecture: the Lehmer conjecture about algebraic numbers. This asserts that the Mahler measure EB acknowledges support from ERC Grant no. 617129 ‘GeTeMo’; PV acknowledges support from the Simons Foundation. 1 2 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ of an irreducible polynomial in Z[X] ought to be bounded away from 1 uniformly, unless it is equal Q to 1. Recall that if πλ := ar r1 (X − λi ) = ar X r + . . . + a1 X + a0 ∈ Z[X] is the minimal polynomial of an algebraic number λ ∈ Q, then the Mahler measure Mλ of πλ is defined by Y Mλ := |ar | |λi |. (1.1) |λi |>1 We can now state our first result: Theorem 1. If the Lehmer conjecture holds, then there is ε > 0 such that for every real algebraic number λ with 1 − ε < λ < 1, the dimension of the Bernoulli convolution µλ is 1. Moreover, our methods give unconditional results, too. We provide an easily testable sufficient (but unfortunately, not necessary) condition that implies dim µλ = 1, which yields plentiful new examples of Bernoulli convolutions with full dimension. See Theorem 5 below, and the discussion that follows it. In a follow-up paper [8], we prove the following result among others. Theorem 2. We have {λ ∈ (1/2, 1) : dim µλ < 1} ⊆ {λ ∈ Q ∩ (1/2, 1) : dim µλ < 1}, where Q is the set of algebraic numbers and {·} denotes the closure of the set with respect to the natural topology of real numbers. Using this result, we can drop the condition of algebraicity from Theorem 1. If Lehmer’s conjecture holds, then there is ε > 0 such that dim µλ = 1 for all 1 − ε < λ < 1. In addition, Theorem 2 provides additional motivation for studying the case of algebraic parameters. Indeed, if one was able to prove that the inverses of Pisot numbers are the only algebraic parameters such that dim µλ < 1, then we would have dim µλ = 1 for all transcendental parameters, since the set of Pisot numbers is closed (see [41]). Unfortunately, we are not able to prove this, but we believe that our methods introduced in this paper may yield an approach. In the second part of this paper, we discuss a connection between Bernoulli convolutions and a classical topic in geometric group theory, namely the growth of finitely generated groups. Given a group Γ generated by a finite subset S, we denote by ρS the rate of exponential growth of its n-th powers, namely: 1 log |S n |, n→+∞ n where S n is the set of products of n elements chosen from S. Examples of Grigorchuk and de la Harpe [22] show that ρS can take arbitrarily small positive values even for linear groups. However in [9, Conjecture 1.1], the first author made the following conjecture: ρS := lim Conjecture 3 (Growth Conjecture). Given d ∈ N, there is ε = ε(d) > 0 such that for every finite subset S in GLd (C), either ρS = 0, or ρS > ε. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 3 A positive answer to this conjecture was obtained earlier in [10, 13] in the special case when S generates a non-virtually solvable subgroup of GLd (C). Indeed this is a simple consequence of the uniform version of the Tits alternative proved therein (see also [7, 18] for earlier related works). A key ingredient in this work was the proof [12] of an analogue of Lehmer’s conjecture in the setting of semisimple algebraic groups. The case when the subgroup generated by S is virtually solvable is surprisingly harder, since it was observed in [11] that the above conjecture, already in the case of solvable subgroups of GL2 , implies the Lehmer conjecture. We can now show the converse: Theorem 4. The Growth conjecture is equivalent to the Lehmer conjecture. The key behind the proofs of Theorems 1 and 4 is the study of the entropy of Bernoulli convolutions with algebraic parameter via Theorem 5 below, which directly relates the Mahler measure to the entropy. The ping-pong method used in most proofs of exponential word growth is not powerful enough in our situation. Indeed no free semigroup may in general be generated by words of small length (see [11, Thm 1.7]). Fortunately here entropy comes to our rescue. While it is clear how entropy relates to an exponential growth rate (Jensen’s inequality, see (1.5)), the relation between entropy and the dimension of a Bernoulli convolution is provided by Hochman’s theorem alluded above, which tells us that if λ ∈ Q ∩ (1/2, 1), then  h  λ dim µλ = min ,1 , (1.2) | log λ| where hλ is the entropy of the random walk on the semigroup generated by the affine transformations x 7→ λ · x ± 1. More precisely, it is defined as follows: (n) H(µλ ) , (1.3) hλ := lim n→+∞ n where H(θ) denotes the Shannon entropy of the discrete probability measure Pn−1 (n) (n) ±λi , where ± θ and µλ is the law of the random variable µλ = i=0 are independent fair coin tosses. If X1 , . . . , Xn are independent random similarities, which take the values x 7→ λ · x + 1 or x 7→ λ · x − 1 with (n) equal probability, then µλ is also the law of Xn · · · X1 (0). This explains our terminology of calling hλ the entropy of the random walk. We explain in Paragraph 3.4 how (1.2) follows from [25]. It is convenient for us to use the following convention for the base of logarithms. We write log for the base 2 logarithm, so that log 2 = 1. We can now state our main theorem. Theorem 5. There is a positive constant c > 0, such that the following holds. Let λ be an algebraic number. Then c min{1, log Mλ } 6 hλ 6 min{1, log Mλ }. We stress that λ here can take any complex value in Q, not only real values. Our estimates show that one can take c = 0.44 in the above result. This is probably not optimal. 4 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Remark 6. In fact, the result holds in greater generality. Let ξ0 , ξ1 , . . . be a sequence of finitely supported i.i.d. random variables with common law ν0 . (n) Suppose that ξn ∈ Q almost surely. Write µλ,ν0 for the law of the random Pn−1 variable i=0 ξi λi and write hλ,ν0 for the quantity that we obtain when we (n) (n) replace µλ by µλ,ν0 in (1.3). Then there is a constant c(ν0 ) depending only on ν0 such that c(ν0 ) min{1, log Mλ } ≤ hλ,ν0 ≤ min{H(ν0 ), log Mλ }. Moreover, for each ε > 0, there is a measure ν0 such that c(ν0 ) > 1 − ε. This means, in particular, that for every algebraic λ ∈ (1/2, 1) such that λ−1 is neither a Pisot nor a Salem number, there is a measure ν0 supported on the integers, such that dim µλ,ν0 = 1. (Without the requirement that ν0 is supported on the integers, this has been known before.) Our main motivation for considering this more general case is an application in the paper [45] for the absolute continuity of certain biased Bernoulli convolutions. The upper bound in Theorem 5 is often a strict inequality. Indeed we prove: Proposition 7. Let λ be an algebraic number such that Mλ < 2 and assume that λ has no Galois conjugates on the unit circle. Then hλ < log Mλ . In this paper, we do not explore the possibility of extending this result to the more general setting considered in Remark 6. We note that this proposition was proved by Garsia [21] in the case where λ is the inverse of a Pisot number in (1, 2). The upper bound in Theorem 5 follows from a simple counting argument. In fact if we denote by ρλ the rate of exponential growth (in base 2) of the (n) size of the support of µλ , namely (n) log | Supp(µλ )| , n→+∞ n then an obvious upper bound on hλ is ρλ := lim hλ 6 ρλ 6 log 2 = 1, (1.4) (1.5) as follows say from Jensen’s inequality, see (2.9). It is easy to see that ρλ = 1 unless λ is a root of a polynomial with coefficients in {−1, 0, 1}. For a topological study of the set of roots of such polynomials, see [3]. If λ is algebraic, then one has the following easy upper bound (see Lemma 16) ρλ 6 log Mλ , (1.6) from which it also follows that Mλ > 2 unless λ is a root of a polynomial with {−1, 0, 1} coefficients, a fact known since [36, 37]. For the strict inequality in Proposition 7, one needs a slightly more precise (ℓ) upper bound on the size of the support of µλ , which is obtained by first (ℓ) showing that the law of the image of µλ under the geometric embedding Q(λ) → Rn+2m (where n is the number of real embeddings, 2m the number BERNOULLI CONVOLUTIONS AND GROUP GROWTH 5 of complex embeddings, and λ has modulus less than 1) is singular with respect to Lebesgue measure. It is an adaptation of Garsia’s proof [21] of this proposition in the special case when λ−1 is Pisot. Theorem 1 is a direct corollary of Theorem 5 and Hochman’s identity (1.2). We note that Theorem 5 also has unconditional consequences, since Lehmer’s conjecture has been verified for several classes of algebraic numbers, see e.g. [2, 6]. Note that already Hochman’s identity readily implies that dim µλ = 1, provided λ ∈ Q ∩ ( 12 , 1) and the semigroup generated by x 7→ λ · x ± 1 is free, e.g. when λ is not a unit or has a conjugate outside the annulus 1/2 ≤ |z| ≤ 2. Theorem 5 provides another condition implying dim µλ = 1, which can be easily tested, namely: Corollary 8. If λ is a real algebraic number such that min(Mλ , 2)−0.44 6 λ 6 1, then dim µλ = 1. Here we used are numerical estimate c0 ≥ 0.44 on the constant in Theorem 5. The derivation of Theorem 4 from Theorem 5 is based on some group theoretic arguments, which enable one to give a lower bound on the growth rate of an arbitrary virtually solvable subgroup of GLd (C) in terms of the growth rate of the semigroup generated by the two affine transformations of the complex line x 7→ λx + 1 and x 7→ λx − 1, which is precisely ρλ . See Theorem 21 in Section 4. The proof of the lower bound in Theorem 5 is the main contribution of this paper. Our argument is a multi-scale analysis that exploits the selfsimilarity (see (2.2) below) of the measure µλ , together with an inequality for the entropy of the sum of independent random variables (see Proposition 10), which can be seen as an entropy analogue of the Plünnecke-Ruzsa inequality from additive combinatorics and is discussed in [29, 33, 43]. This allows to lower bound the entropy by a sum of entropy contributions at each scale, each of which is uniformly bounded below. Finally, we mention some related works from the literature. In [24] Hare and Sidorov computed explicit lower bounds for the entropy hλ in the special case, when λ is a Pisot number. In particular they showed, that hλ > 0.81 · log λ−1 for all Pisot numbers, which is a better constant than what our methods yield. Moreover, Sidorov pointed out to us that their result holds in greater generality for all algebraic numbers. On the other hand, Theorem 5 provides an estimate for hλ in terms of the Mahler measure with a constant independent of the number of Galois conjugates inside the unit disk. This uniformity is the main difficulty and the main point in our work. See also [1] for upper and lower bounds on hλ , in the case when λ is the Golden Ratio. Paul Mercat studied the quantity ρλ in his thesis [35]. He showed that ρλ = log Mλ , whenever λ ∈ (1/2, 1) is a Salem number. This is also true for Pisot numbers [32]. Mercat also showed that when λ has no conjugates on the unit circle, then the semigroup generated by x → λx ± 1 is automatic, in particular 2ρl is an algebraic number in this case, and he gave an algorithm to compute its minimal polynomial. 6 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ The following result of Peters [39] was brought to our attention by Andreas Thom. For each integer N and algebraic number λ, denote by Sλ,N the set of matrices   λ n , 0 1 where n ranges through the integers −N, . . . , N . It is proved in [39] that lim ρSλ,N = log Mλ . N →∞ The main interest in our results is that we are able to give a good lower bound even for ρSλ,1 . The paper is organized as follows. In Section 2 we outline the proof of the lower bound in Theorem 5, recall the basic properties of entropy and prove some entropy inequalities we need. Section 3 completes the proof of the lower bound in Theorem 5 and also deals with the upper bound estimates. In Paragraph 3.4 we explain how (1.2) follows from [25] and deduce Theorem 1. In Section 4 we discuss the applications to the growth of solvable linear groups and prove Theorem 4. Finally the last section is devoted to some open problems. Acknowledgements. It is a pleasure to thank Francesco Amoroso, Jean Bourgain, Mike Hochman, Paul Mercat, Nikita Sidorov and Andreas Thom for interesting discussions. 2. Entropy bounds for the random walk In this section, we set notations, review some basic properties of entropy, give an outline of the proof of Theorem 5 and discuss a number of preliminaries. 2.1. Bernoulli convolutions in matrices. Let A ∈ Md (R) be a matrix with real entries and spectral radius strictly less than 1. We fix an atomic probability measure ν0 supported on a finite subset of the rationals. Let {ξn }n>0 be a sequencePof bounded i.i.d. random variables with common law ν0 . The power series n>0 An converges absolutely, and hence the random variable X XA := ξn An (2.1) n>0 is well-defined and almost surely finite. We denote its law by µA . Its support is some bounded region of Md (R), and it satisfies the self-similarity relation (ℓ) (ℓ) µA = µA ∗ Aℓ µA , (2.2) where µA is the law of the random variable X (ℓ) XA := ξn An , 06n6ℓ−1 Aℓ µ ℓ and A is the push-forward of the measure µA by the linear map x 7→ A x. (ℓ) If A = λ ∈ M1 (R) then this is consistent with the notation µλ and µλ used in the Introduction. (For brevity we omit the subscript ν0 in our notation.) BERNOULLI CONVOLUTIONS AND GROUP GROWTH 7 (ℓ) (ℓ) For any given vector x ∈ Rd , we let XA,x := XA · x and XA,x := XA · x (ℓ) and denote the associated measures on Rd by µA,x and µA,x . Similarly to µA , this measure also satisfies a self-similarity relation (ℓ) µA,x = µA,x ∗ Aℓ µA,x . (2.3) 2.2. Outline of the proof of Theorem 5. In this paper H(X) denotes the entropy of the random variable X taking values in Rd . More precisely, if X takes only countably many values {xi }i , then H(X) will denote the Shannon entropy, i.e. X H(X) = − pi log pi , i where pi is the probability that X = xi . If on the other hand the distribution of X is absolutely continuous with respect to Lebesgue measure, then H(X) will denote the differential entropy, that is Z H(X) = − f (x) log f (x)dx, where f (x) is the density of X, which is well defined provided f log f is in L1 (Rd ). Although we will use the same letter for the Shannon and the differential entropy, it should not cause confusion: we will only consider the entropy of random variables whose law is either atomic, and we will then use the Shannon entropy, or absolutely continuous with respect to Lebesgue, in which case the differential entropy will be used. We fix an algebraic number λ ∈ Q and assume that A ∈ Md (R) is such a matrix whose eigenvalues coincide with the Galois conjugates λi of λ of modulus < 1. Note that the spectral radius of such an A is strictly less than 1. Of course it is always possible to find such a matrix, because the non-real Galois conjugates, i.e. the roots of the minimal polynomial πλ , come in pairs of complex conjugates. We make the following simple observation: if λ satisfies an equation of P P the form 0ℓ−1 εn λn = 0ℓ−1 ε′n λn for two sets of rationals {εn }06n6ℓ−1 and {ε′n }06n6ℓ−1 , then every Galois conjugate of λ will satisfy the same equation, and hence (looking at a basis of eigenvectors of A) we also have for all x ∈ Rd ℓ−1 X n εn A x = n=0 ℓ−1 X ε′n An x. n=0 From this we can deduce that: (ℓ) (ℓ) (ℓ) H(Xλ ) = H(XA ) > H(XA,x ). (2.4) (ℓ) Our goal (towards Theorem 5) is to obtain a lower bound on H(XA,x ). We shall shortly describe a method to do this, but first introduce some more notation. For a matrix B ∈ GLd (R) and a bounded random variable X on Rd , H(X; B) will denote the quantity H(X; B) := H(X + GB ) − H(GB ), where GB is a centered gaussian random variable with co-variance matrix B t B that is independent of X. (Here t B denotes the transpose of B.) If 8 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ B1 , B2 ∈ Md (R) are two matrices, then H(X; B1 |B2 ) will denote H(X; B1 |B2 ) := H(X; B1 ) − H(X; B2 ). These quantities have the following intuitive meaning. Denote by ∆ the unit ball in Rd . Then H(X; B) measures the amount of information needed to describe the law of X up to an error inside B(∆). One may define similar quantities using other mollifiers than the standard gaussian (say, the indicator function of ∆ or some other bump like function), which would capture the same intuitive meaning. These quantities differ from H(X; B) by an additive constant depending on the dimension. However, our arguments cannot tolerate any losses, so the choice of the smoothing is important for technical reasons. We use the following partial order on Md (R). We write B1  B2 if B2 t B2 −B1 t B1 is a non-negative semi-definite matrix, or equivalently k t B1 xk2 ≤ k t B2 xk2 for all x ∈ Rd . The quantities defined above enjoy the following properties, which will be crucial for us. Lemma 9. Let B1 , B2 ∈ GLd (R) be such that B1  B2 . Assume that X, Y are two bounded independent random variables taking values in Rd . Then (i) (ii) (iii) (iv) H(X; B1 ) > 0, H(X; B1 ) + H(Y ; B1 ) > H(X + Y ; B1 ), H(X; B1 ) > H(X; B2 ), H(X + Y ; B1 |B2 ) > H(X; B1 |B2 ). This lemma will be proved in Section 2.4. For now we pursue our outline of the proof of Theorem 5. Recall that we started with a matrix A ∈ Md (R) whose eigenvalues coincide with the Galois conjugates of λ of modulus strictly less than 1. Assume now that its operator norm (for the canonical Euclidean structure on Rd ) is less or equal to 1. This ensures that Ai+1  Ai for each i ∈ N. (ℓ) The first step in the proof will be to approximate H(XA,x ) by H(XA,x ; Aℓ |Id), where Id denotes the identity matrix. Intuitively this is expected to hold, (ℓ) since XA,x differs from XA,x only at a scale proportional to Aℓ (∆). In fact, (ℓ) we will show that even H(XA,x ) > H(XA,x ; Aℓ |Id) holds. Then we write H(XA,x ; Aℓ |Id) = ℓ X i=1 H(XA,x ; Ai |Ai−1 ). Using Lemma 9 (iv) and the self-similarity property (2.3), we will bound from below each term on the right hand side by H(XA,x ; A|Id). Taking the limit ℓ → ∞ we then obtain (ℓ) H(XA ) > H(XA,x ; A|Id). (2.5) ℓ To estimate the right hand side of (2.5), we use inequality (iv) from Lemma 9 and keep only one convolution factor in XA,x . This yields the hλ,ν0 = lim BERNOULLI CONVOLUTIONS AND GROUP GROWTH 9 following inequality, which is valid for all vectors x ∈ Rd , and all real matrices A with norm at most 1 and eigenvalues equal to the conjugates of λ of modulus less than 1, hλ,ν0 > H(ξ0 · x; A|Id). (2.6) By a suitable choice of the vector x and the matrix A we reduce this to entropies on R: hλ,ν0 > Φ(Mλ ) := sup{H(tMλ ξ0 + G) − H(tξ0 + G)}, (2.7) t>0 where G is a standard gaussian random variable independent of ξ0 . Then a calculus exercise allows to get the lower bound c(ν0 ) min{1, log Mλ } for the right hand side above, thus concluding our outline of the proof of Theorem 5. In the remainder of this section, we recall some basic facts about Shannon and differential entropies in Paragraph 2.3, then prove Lemma 9 in Paragraph 2.4. The proof of Theorem 5 is given in the next section following the above outline. 2.3. Basic properties of Entropy. Recall that we denote by H(X) the Shannon entropy of X if X is a discrete random variable in Rd and the differential entropy if X is absolutely continuous with respect to the Lebesgue measure on Rd . We refer the reader to [15] for a thorough introduction to information theory and entropy. The purpose of this paragraph is to recall a few properties. The Shannon entropy is always non-negative. The differential entropy on the other hand can take negative values. For example, if A ∈ GLd (R), and X is a random variable with finite differential entropy H(X), then it follows from the change of variables formula that H(AX) = H(X) + log | det A|, (2.8) which can take negative values when A varies. On the other hand, if X takes countably many values, the Shannon entropy of AX is the same as that of X. Note that both entropies are invariant under translation by a constant in Rd . The density of a centered gaussian random variable GA with co-variance matrix A t A on Rd is gA (x) := 1 (2π)d/2 | det A| · e−||A −1 x||2 /2 , and its differential entropy is d2 log 2eπ + log | det A|. It maximizes the differential entropy of a random variable in Rd with the same co-variance. For a proof see [15, Example 12.2.8]. We define F (x) := −x log(x) for x > 0 and recall that F is concave, and it is sub-additive, i.e. F (x + y) 6 F (x) + F (y), and it also satisfies the identity F (xy) = xF (y) + yF (x). From the concavity of F and Jensen’s inequality, we see that for any atomic random variable X taking at most N possible different values, H(X) 6 log N. (2.9) 10 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Let now X and Y be two independent random variables in Rd . If both are atomic, it follows immediately from the sub-additivity of F (x) and the identity F (xy) = xF (y)+yF (x) that H(X+Y ) 6 H(X)+H(Y ) for Shannon entropy. This is no longer true for differential entropy (since the formula is not invariant under a linear change of variable). However if X is atomic and bounded, while Y is assumed absolutely continuous, then H(X + Y ) 6 H(X) + H(Y ), (2.10) where H(X) is Shannon’s entropy and the other two are differential entropies. To see this, note that P if f (y) is the density of Y , then the density of X + Y is E(f (y − X)) = i pi f (y − xi ), hence: Z X  H(X + Y ) = F pi f (y − xi ) dy 6 Z X i = = Z X X i i i F (pi f (y − xi ))dy F (pi )f (y − xi )dy + F (pi ) + Z Z X i pi F (f (y − xi ))dy F (f (y))dy = H(X) + H(Y ) and (2.10) follows. In the other direction, we always have the lower bound H(X + Y ) > max{H(X), H(Y )} (2.11) if all three entropies are of the same type (i.e. either Shannon or differential), as follows easily from the concavity of F . The relative entropy (or Kullback-Leibler divergence) of two absolutely continuous probability distributions p and q on Rd is defined as Z p(x) dx D(p||q) := p(x) log q(x) This quantity is always non-negative (information inequality) as follows immediately from Jensen’s inequality and the concavity of x 7→ log x, since Z Z q(x) q(x)  −D(p||q) = p(x) log dx 6 log dx = 0. p(x) p(x) p(x) Moreover D(p||q) = 0 if and only if p and q coincide almost everywhere. A direct consequence of this inequality is the fact that the entropy of the joint law of two random variables (X, Y ) is at most the sum of the entropy of each marginal, namely: H(X, Y ) 6 H(X) + H(Y ) Indeed the difference H(X) + H(Y ) − H(X, Y ) (also called the mutual information) can be expressed as the relative entropy D(p(X,Y ) (x, y)||pX (x)pY (y)), where p(X,Y ) (x, y) is the joint density of (X, Y ) and pX (x) and pY (y) the marginals, i.e. the densities of X and Y respectively. Equality holds if and only if X and Y are independent. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 11 A similar inequality is as follows. Suppose X, Y, Z are three Rd -valued absolutely continuous random variables such that the triple (X, Y, Z) as well as the individual marginals X, Y and Z have finite differential entropy. Then H(X, Y, Z) + H(Z) 6 H(X, Z) + H(Y, Z) (2.12) Indeed, the difference H(X, Z) + H(Y, Z) − H(X, Y, Z) − H(Z) is exactly the relative entropy D(p||q) of the two (Rd )3 -valued probability distributions p(x, y, z) := p(X,Y,Z)(x, y, z) and q(x, y, z) := p(X,Z) (x, z)p(Y,Z) (y, z)/pZ (z). 2.4. Inequalities for entropies of sums of random variables. The purpose of this section is to prove Lemma 9. We first recall the following result from [33, Theorem I.]. Theorem 10 (submodularity inequality). Assume that X, Y, Z are three independent Rd -valued random variables such that the distributions of Y , X + Y , Y + Z and X + Y + Z are absolutely continuous with respect to Lebesgue measure and have finite differential entropy. Then H(X + Y + Z) + H(Y ) 6 H(X + Y ) + H(Y + Z). (2.13) This result goes back in some form at least to a paper by Kaimanovich and Vershik [31, Proposition 1.3], which related the positivity of the entropy of a random walk on a group to the existence of bounded harmonic functions. The version in that paper assumes that the laws of X, Y and Z are identical. The inequality was rediscovered by Madiman [33, Theorem I.] in the greater generality stated above. Then it was recast in the context of entropy analogues of sumset estimates from additive combinatorics by Tao [43] and Kontoyannis and Madiman [29]. And indeed Theorem 10 can be seen as an entropy analogue of the Plünnecke–Ruzsa inequality in additive combinatorics (see [44, Corollary 6.29]). We provide the short proof for the reader’s convenience. We first give it under the additional assumption that X and Z are absolutely continuous and have finite differential entropy. Proof of Theorem 10 assuming that X, Z have finite differential entropy. We apply (2.12) to the random variables X ′ = X, Y ′ = X + Y, Z ′ = X + Y + Z to get H(X, X+Y, X+Y +Z)+H(X+Y +Z) 6 H(X, X+Y +Z)+H(X+Y, X+Y +Z) However H(X, X + Y, X + Y + Z) = H(X, Y, Z) because the linear transformation used here has determinant 1 (see (2.8)), while H(X, X + Y + Z) = H(X, Y + Z) = H(X) + H(Y + Z) by independence of X, Y, Z. Similarly H(X + Y, X + Y + Z) = H(X + Y ) + H(Z), and H(X, Y, Z) = H(X) + H(Y ) + H(Z). The result follows.  For the general case we need to approximate X and Z by absolutely continuous random variables. We will replace them by X + εGId and Z + εG′Id , where GId and G′Id are two independent (of everything) gaussian random variables with covariance matrices Id. We will need the following two simple Lemmata. 12 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Lemma 11. Let X be an absolutely continuous bounded random variable in Rd with finite differential entropy. Let GId be a standard gaussian random variable in Rd that is independent of X. Then H(X) = limε→0 H(X + εGId ) Proof. We have H(X) ≤ H(X + εGId ) by (2.11) for all ε. Denote by f the density of X and by gε the density of εGId . We observe that f ∗ gε converges to f almost everywhere and we set out to construct a majorant function. We fix a sufficiently large real number R such that f (x) = 0 for all kxk > R − 10. We observe that for all x with kxk > R and 2 0 < ε < 1 we have f ∗ gε (x) < e−(kxk−R) . We write m for the maximum of the function F (x) = −x log(x) and define M (x) = m for kxk ≤ R + 10 and 2 M (x) = (kxk − R)2 e−(kxk−R) for kxk > R + 10. We observe that F (f ∗ gε (x)) ≤ M (x) for all x, hence by Fatou’s Lemma we have Z H(X) ≥ lim sup F (f ∗ gε (x))dx = lim sup H(X + εGId ). ε→0 ε→0 This completes the proof.  If X is a random variable and A is an event with positive probability, then we denote by X|A a random variable that satisfies P(X|A ∈ B) = P(B ∩ A)/P(A) for any event B. Lemma 12. Let X be an absolutely continuous random variable in Rd with finite differential entropy. Let {An } be an increasing sequence of events such that lim P(An ) = 1. n→∞ Then H(X) = limn→∞ H(X|An ). Proof. Let M be a monotone increasing function on R>0 such that M (x) = |x log(x)| if x ≤ 1/10 or x ≥ 10 and M (x) ≥ |x log(x)| for all x. We write f for the density of X and P(An )−1 fn for the density of X|An . We note that fn converges to f almost everywhere and that |fn log(fn )| ≤ M (f ). Since M (x) ≤ Cx + |x log x| for some constant C and both f and |f log(f )| are in L1 , we see that M (f ) ∈ L1 . Thus by the dominated convergence theorem, we have Z H(X) = lim − fn (x) log fn (x)dx = lim H(X|An ). n→∞ n→∞  Proof of Theorem 10 in the general case. First we assume that X, Y and Z are all bounded. Let GId and G′Id be two independent (from each other and X, Y, Z) standard gaussian random variables of dimension matching that of X. We apply the already proved case of the theorem for the random variables X + εGId , Y and Z + εG′Id and obtain H(X + Y + Z + εGId + εG′Id ) + H(Y ) 6 H(X + Y + εGId ) + H(Y + Z + εG′Id ). In light of Lemma 11, letting ε → 0 we can conclude the theorem for X, Y, Z. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 13 If any of X, Y or Z is unbounded, then we define An to be the event kXk + kY k + kZk < n. Using the theorem for the bounded variables X|An , Y |An and Z|An we get H([X + Y + Z]|An ) + H(Y |An ) 6 H([X + Y ]|An ) + H([Y + Z]|An ). We take the limit n → ∞ and conclude the theorem from Lemma 12.  Recall the definition of H(X; B) and H(X; B1 |B2 ) from the two paragraphs before Lemma 9. We finish this section by proving the properties of these entropies claimed in this lemma. Proof of Lemma 9. Item (i) follows easily from the concavity of F (x) = −x log(x), indeed Z Z H(X +GB1 ) = F (E(gB1 (x−X)))dx > E(F (gB1 (x−X)))dx = H(GB1 ). Item (ii) is a consequence of (2.13) applied to the three independent variables X ′ = X, Y ′ = GB1 and Z ′ = Y . Since B1  B2 , there exists M ∈ Md (R) such that B2 t B2 = B1 t B1 + M t M . In particular if GB1 and GM are two independent centered gaussian distributions on Rd with co-variance matrix B1 t B1 and M t M respectively, then GB1 + GM is a centered gaussian variable with co-variance B2 t B2 . Now item (iii) follows from (2.13) by setting Y = GB1 and Z = GM , while item (iv) also follows from (2.13) applied to the independent variables X ′ , Y ′ , Z ′ defined by X ′ := Y , Y ′ := X + GB1 , Z ′ := GM .  3. Proof of Theorem 5 and Proposition 7 In this section we establish Theorem 5 and Proposition 7. In Paragraph 3.1 we give the details of the above outline and give a lower bound for hλ in terms of Mλ only, via the function Φ defined above in (2.7). In Paragraph 3.2 we study the function Φ and deduce the desired lower bound in Theorem 5. Finally, we prove the upper bounds of Theorem 5 and Proposition 7 in Paragraph 3.3. 3.1. Lower bounds on the entropy. We keep the notations introduced in the previous section. In particular ξ0 is a random variable with law ν0 , and G is an independent standard gaussian real random variable. Also Mλ is the Mahler measure of the algebraic number λ. We recall that for a > 0 Φν0 (a) = sup{H(ξ0 ta + G) − H(ξ0 t + G)}. t>0 The following proposition is the main goal of this paragraph. It establishes the lower bounds (2.5)–(2.7) from our outline. Proposition 13. Let λ be an algebraic number and A ∈ Md (R) a matrix such that kAk ≤ 1 and the eigenvalues of A coincide with the Galois conjugates of λ of modulus < 1. Then for every x ∈ Rd hλ,ν0 >H(XA,x ; A|Id) > H(ξ0 · x; A|Id), hλ,ν0 >Φν0 (Mλ ). We recall that XA,x := XA · x for x ∈ Rd and XA was defined in (2.1). 14 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Proof. Note that the spectral radius of A is less than 1 and thus the random variable XA is well defined and bounded. Recall that we denote by µA,x and (ℓ) (ℓ) µA,x the laws of the random variables XA,x and XA,x respectively. In what follows it will be convenient for us to write H(µ; B) for H(X; B), where X is a random variable with law µ. In a similar fashion we also use the notation H(µ; B1 |B2 ). First we observe that (ℓ) Indeed H(µA,x ; Aℓ |Id) 6 H(µA,x ). H(µA,x ; Aℓ |Id) = H(µA,x ; Aℓ ) − H(µA,x ; Id) (ℓ) = H(µA,x ∗ Aℓ µA,x ; Aℓ ) − H(µA,x ; Id) (ℓ) 6 H(µA,x ; Aℓ ) + H(Aℓ µA,x ; Aℓ ) − H(µA,x ; Id) (ℓ) 6 H(µA,x ; Aℓ ) (ℓ) 6 H(µA,x ), where we used the self-similarity relation (2.3) on the second line, the subadditivity property (ii) in Lemma 9 on the third line. In the fourth line, we used the fact that the gaussian GA has the same law as AGId together with the change of variable formula for the entropy (2.8). Finally the last line follows from the sub-additivity property (2.10). On the other hand, by definition H(µA,x ; Aℓ |Id) = ℓ X i=1 H(µA,x ; Ai |Ai−1 ). We claim that each term in this sum is bounded below by H(µA,x ; A|Id). This claim follows easily from the self-similarity relation (2.3) and estimate (iv) of Lemma 9. Indeed, our assumption that ||A|| 6 1 implies that ||Ai y|| 6 ||Ai−1 y|| for every y ∈ Rd and i > 1, and thus ensures that Ai  Ai−1 . This makes the use of Lemma 9 (iv) legitimate and shows that (i−1) H(µA,x ; Ai |Ai−1 ) = H(µA,x ∗ Ai−1 µA,x ; Ai |Ai−1 ) > H(Ai−1 µA,x ; Ai |Ai−1 ) = H(µA,x ; A|Id). Now to conclude the proof of the first inequality, observe that 1 1 (ℓ) (ℓ) hλ,ν0 = lim H(µλ ) > lim H(µA,x ) ℓ→∞ ℓ ℓ→∞ ℓ 1 > lim H(µA,x ; Aℓ |Id) > H(µA,x ; A|Id). ℓ→∞ ℓ To deduce the second bound, we use again Lemma 9 (iv): (1) H(µA,x ; A|Id) > H(µA,x ; A|Id) = H(ξ0 · x; A|Id). We turn to the proof of the third bound. To this end, we optimize the parameters x ∈ Rd and A ∈ Md (R). Note that A is allowed to vary among all matrices in Md (R) with prescribed spectrum: {λ1 , . . . , λd }, the Galois conjugates of λ that lie inside the open unit disc, and such that ||A|| 6 1. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 15 Exploiting the rotational symmetry of the normalized gaussian law, we observe that for any two orthogonal matrices u, v ∈ Od (R), H(ξ0 · x; A|Id) = H(ξ0 · ux; uAv|Id). By the Cartan decomposition, every matrix A ∈ Md (R) can be written as A = uDv for a diagonal matrix D = diag(α1 , . . . , αd ) with α1 > . . . > αd > 0 and u, v ∈ Od (R). The αi ’s are called the singular values of A. A well-known theorem of Horn ([26] and [27, Pb. 2, p 222]) describes the set of values that can arise as singular values of a matrix with prescribed spectrum. It follows from this result that one can find a real matrix A ∈ Md (R) whose eigenvalues are as above λ1 , . . . , λd and whose singular values are α1 = . . . = αd−1 = 1 and αd = |λ1 · · · λd | = 1/Mλ . Note that α1 = ||A|| = 1, so this matrix A satisfies our requirements. In our case we can also find A by the following simple alternative arguP d n ment: given v ∈ R , consider the quadratic form qv (x) := n>0 hA0 x, vi2 , where h·i is the canonical Euclidean scalar product on Rd , and A0 is any diagonalizable matrix with the prescribed eigenvalues. This form is welldefined, because the spectral radius of A0 is less than 1. Pick v ∈ Rd so that the vectors t An0 v span Rd as n varies among the integers (this is always possible since A0 is invertible and has distinct eigenvalues). Then qv is positive definite and there exists B ∈ GLd (R) such that qv (x) = kBxk2 . Now by construction: qv (x) = hx, vi2 + qv (A0 x) = hx, vi2 + kBA0 xk2 , from which it follows that kBA0 B −1 xk2 = kxk2 − hx, t B −1 vi2 , which means that at least d − 1 singular values of BA0 B −1 are equal to 1. The last one is unambiguously determined by the determinant, hence equal to 1/Mλ . We write D = diag(1, . . . , 1, Mλ−1 ). By the above discussion, there are two orthogonal matrices u, v ∈ O(d) such that A = uDv and hence D = u−1 Av −1 . We deduce hλ,ν0 > H(ξ0 · x; D|Id) for all x ∈ Rd . We now pick x of the form x = ted , for some t ∈ R and where ed = (0, . . . , 0, 1) is the last element of the canonical basis of Rd . Then H(ξ0 x; D|Id) =H(ξ0 ted + DGId ) − H(DGId ) − (H(ξ0 ted + GId ) − H(GId )) =H(ξ0 tMλ ed + GId ) − H(ξ0 ted + GId ) =H(ξ0 tMλ + G) − H(ξ0 t + G) where in the last line G is a normalized one-dimensional gaussian random variable. We used the change of variable formula (2.8) to prove the second equality and the identity F (xy) = xF (y) + yF (x) satisfied by the function F (x) = −x log(x) to integrate out the first d variables. This completes the proof of the proposition.  3.2. Proof of the lower bound in Theorem 5. In this paragraph, we complete the proof of the lower bound in Theorem 5 and to this aim, we study the function Φν0 (a) = sup{H(ξ0 ta + G) − H(ξ0 t + G)} t>0 16 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ and prove the following estimates: Lemma 14. The function Φν0 is monotone increasing and we have Φν0 (a) Φν (a2 ) ≥ 0 2 log a log a for any a > 1. This has the following immediate corollary. Corollary 15. We have for all a > 1, where Φν0 (a) ≥ c min{log a, 1} c = √ min {Φν0 (a)/ log(a)}. (3.1) 2≤a≤2 The constant c can be numerically estimated by calculating Φν0 (a) for a running through a sufficiently dense arithmetic progression and using the monotonicity of Φν0 to estimate it in the intervals between the point of the progression. Our numerical calculations show c ≥ 0.44 for the case ν0 = (δ−1 + δ1 )/2 that is relevant for Bernoulli convolutions. According to these calculations the function Φν0 (a)/ log(a) appears to be monotone decreasing, hence the minimum is probably attained for a = 2. We note that for each ε > 0, it is possible to choose the measure ν0 in such a way that the constant (3.1) is at least 1 − ε. Indeed, a simple calculation shows that Φν (a) = log a, for each a > 1 if ν is a Gaussian measure. Hence, one can take for ν0 a measure supported on the rationals that suitably approximates a Gaussian measure and find that c is as close to 1 as desired. Observe that Corollary 15 combined with Proposition 13 completes the proof of the lower bound in Theorem 5. Proof of Lemma 14. Using the change of variable formula (2.8) we get H(ξ0 ta + G) − H(ξ0 t + G) =H(ξ0 t + a−1 G) − H(a−1 G) − [H(ξ0 t + G) − H(G)] =H(ξ0 t; a−1 |1). This is an increasing function of a for each fixed t by part (iii) of Lemma 9. This shows that Φν0 (a) is an increasing function of a. We turn to the second claim. Fix a and ε > 0 and let t be such that Φν0 (a2 ) ≤ H(ξ0 ta2 + G) − H(ξ0 t + G) + ε. Then by the definition of Φν0 (a), we have Φν0 (a2 ) ≤ H(ξ0 ta2 +G)−H(ξ0 ta+G)+H(ξ0 ta+G)−H(ξ0 t+G)+ε ≤ 2Φν0 (a)+ε. We take ε → 0 to conclude Φν0 (a2 ) ≤ 2Φν0 (a), which is precisely the second claim.  Proof of Corollary 15. If a ≥ 2, then Φν0 (a) ≥ Φν0 (2) ≥ c = c min{log a, 1} by the monotonicity of Φν0 and the definition of c. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 17 √ n If a < 2, then we take n ≥ 0 to be an integer such that 2 ≤ a2 < 2. Then by the second claim of Lemma 14 applied repeatedly and the definition of c we have n Φν0 (a2 ) Φν0 (a) ≥ ≥ c. n log a log a2 This shows Φν0 (a) ≥ c log a proving the claim.  3.3. Proof of the upper bounds. The goal of this paragraph is to prove the upper bound hλ ≤ ρλ ≤ min{1, log Mλ } in Theorem 5. We will also show Proposition 7, which says that the inequality hλ ≤ min{1, log Mλ } is strict if Mλ < 2 and λ has no Galois conjugate on the unit circle. For simplicity, we assume as we may that ν0 is supported on Z. We first recall a simple counting lemma. Lemma 16. Let λ be an algebraic unit and denote by k the number of Galois (ℓ) conjugates of λ on the unit circle. Then | Supp(µλ )| ≤ Cℓk Mλℓ , where C is a constant depending only on λ and ν0 . In particular ρλ ≤ min{1, log Mλ }. Recall that ρλ is defined in (1.4). This lemma is standard, but we give the proof for the reader’s convenience. Proof. We denote by σ1 , . . . σn : Q(λ) → R the real Galois embeddings with |σi (λ)| ≥ 1 and by τ1 , . . . , τm : Q(λ) → C the complex Galois embeddings with |τi (λ)| ≥ 1 such that we take exactly one from each pair of complex conjugate embeddings. Furthermore, we denote by ρ1 , . . . , ρo : Q(λ) → C the real or complex Galois embeddings with |ρi (λ)| < 1. (Here we take both from a pair of complex conjugate embeddings.) We define the map S : Q(λ) → Rn+2m by S(x) = (σ1 (x), . . . , σn (x), Re(τ1 (x)), Im(τ1 (x)), . . . , Re(τm (x)), Im(τm (x))). We consider the set (ℓ) A = Supp(µλ ) = ℓ−1 nX i=0 o ai λi : ai ∈ Supp ν0 ; for all i . We note that elements of A are algebraic integers, hence for any two different x, y ∈ A we have Y |σi (x − y)||τj (x − y)|2 |ρk (x − y)| ≥ 1. i,j,k For any 1 ≤ k ≤ o, we have |ρk (x− y)| ≤ |ρk (x)|+ |ρk (y)| ≤ 2L/(1− |ρk (λ)|), where L = maxx∈Supp ν0 |x|. Hence there is a number c depending on λ and L such that Y |σi (x − y)||τj (x − y)|2 ≥ c. i,j Thus kS(x − y)k > c1 for some other number c1 depending on λ and L. 18 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Consider the set Ω = {(x1 , . . . , xn+2m ) ∈ Rn+2m : |xi | ≤ L |σi (λ)|ℓ − 1 + c1 for 1 ≤ i ≤ n, while for 1 ≤ j ≤ m, |σi (λ)| − 1 |τj (λ)|ℓ − 1 + c1 if |τj (λ)| > 1, |τj (λ)| − 1 |xn+2j−1 |, |xn+2j | ≤ Lℓ + c1 if |τj (λ)| = 1}. |xn+2j−1 |, |xn+2j | ≤ L It is easily seen that the balls of radii c1 /2 around the points S(x) for x ∈ A are disjoint and contained in Ω. On the other hand, there is a number C depending only on λ and L such that the volume of Ω is less than Cℓk Mλℓ , hence the claim follows.  Proof of the upper bound in Theorem 5. Using (2.9) we see that hλ 6 ρλ , so  the bound follows from Lemma 16. It remains to prove Proposition 7, which we recall now: Proposition 17. Let λ be an algebraic number such that Mλ < 2 and assume that λ has no conjugates on the unit circle. Then hλ < log Mλ . From now on we restrict ourselves to the special case ν0 = (δ−1 + δ1 )/2 that is relevant to Bernoulli convolutions. The proof is based on ideas from Garsia’s proof that hλ < − log λ if λ−1 is Pisot [21]. We use the following notation (note that it differs from that of the proof of Lemma 16). We denote by σ1 , . . . σn : Q(λ) → R the real Galois embeddings with |σi (λ)| < 1 and by τ1 , . . . , τm : Q(λ) → C the complex Galois embeddings with |τi (λ)| < 1 such that we take exactly one from each pair of complex conjugate embeddings. Furthermore, we denote by ρ1 , . . . , ρo : Q(λ) → C the real or complex Galois embeddings with |ρi (λ)| > 1. (Here we take both from a pair of complex conjugate embeddings.) We define the map S : Q(λ) → Rn+2m by S(x) = (σ1 (x), . . . , σn (x), Re(τ1 (x)), Im(τ1 (x)), . . . , Re(τm (x)), Im(τm (x))). We introduce the random vectors Yλ = ∞ X i=0 i ξi S(λ ) = S(Xλ ), (ℓ) Yλ = ℓ−1 X (ℓ) ξi S(λi ) = S(Xλ ). i=0 The strategy of the proof of the proposition is the following. We begin by proving that the law of Yλ is singular (Lemma 18). Then we approximate (ℓ) the law of Yλ by Yλ and conclude that most of the probability mass is concentrated on an ε proportion of the atoms. This yields a slight improvement over the proof of the upper bound in Theorem 5, which is just enough to conclude that hλ < Mλ . Lemma 18. Suppose that λ is an algebraic unit that has no Galois conjugates on the unit circle. Then the law of Yλ is singular. The proof is a straightforward generalization of the fact that µλ is singular if λ−1 is Pisot. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 19 Proof. We put for each t ∈ N ζt =(σ1 (λ−t ), . . . , σn (λ−t ), 2 Re(τ1 (λ−t )), −2 Im(τ1 (λ−t )), . . . , 2 Re(τm (λ−t )), −2 Im(τm (λ−t ))). We show below that there is a number c > 0 depending only on λ such that |E[exp(2πihζt , Yλ i)]| ≥ c. Then the Riemann-Lebesgue Lemma implies that the law of Yλ is singular. We observe that ∞ Y E[exp(2πihζt , ξj S(λj )i)] E[exp(2πihζt , Yλ i)] = = j=0 ∞ Y cos(2πhζt , S(λj )i). j=0 We can write hζt , S(λj )i = n X σa (λ−t )σa (λj ) +2 m X a=1 b=1 = n X (Re(τb (λ−t )) Re(τb (λj )) − Im(τb (λ−t )) Im(τb (λj ))) j−t σa (λ )+2 a=1 m X Re(τb (λj−t )). b=1 We set uj = n X σa (λj ) + 2 vj = o X ρa (λj ). a=1 m X Re(τb (λj )), b=1 a=1 Since λ is a unit and uj + vj equals to the sum of all Galois conjugates of λj , it follows that uj + vj is an integer for all j ∈ Z. Hence we can write |E[exp(2πihζt , Yλ i)]| ≥ = ∞ Y j=−∞ −1 Y j=−∞ | cos(2πuj )| | cos(2πvj )| ∞ Y j=0 | cos(2πuj )| =: c. We now show that the quantity of the right hand side, which we have denoted by c is strictly positive. We note that there is a positive number α < 1 depending only on λ such that |uj | ≤ (n + 2m)αj and |vj | ≤ oα−j for all j ∈ Z. We choose an integer N large enough so that (n + 2m)αj < 1/4 and oαj < 1/4 for j > N . There is an absolute constant C > 0 such that cos(x) ≥ exp(−C|x|) for |x| < 1/4, hence we can write ∞ N −N −1   Y   X X αj . | cos(2πuj )| exp − C(n + 2m) α−j c ≥ exp − Co j=−∞ j=−N j=N +1 20 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ We note that uj is an algebraic integer for all j ∈ Z so it cannot be equal to one half plus an integer. This finishes the proof that c > 0, hence the lemma follows.  Proof of Proposition 17. Denote by Qℓ the box in Rn+2m with side lengths |σ1 (λ)|ℓ , . . . , |σn (λ)|ℓ , |τ1 (λ)|ℓ , |τ1 (λ)|ℓ , |τ2 (λ)|ℓ , |τ2 (λ)|ℓ . . . , |τm (λ)|ℓ , |τm (λ)|ℓ centered around the origin. We begin by an observation about the separation of points in the support (ℓ) (ℓ) of Yλ . Let x, y ∈ Supp Xλ be two different points. We can apply an argument similar to that in the proof of Lemma 16 for the points S(λ−(ℓ−1) x), S(λ−(ℓ−1) y) and λ−1 in place of λ to show that there is a number c > 0 depending only on λ such that S(λ−(ℓ−1) x) − S(λ−(ℓ−1) y) ∈ / cQ0 . This in turn yields S(x) − S(y) ∈ / cQℓ−1 . (ℓ) Next, we estimate the difference between Yλ and Yλ . We can write |σi (Xλ − (ℓ) Xλ )| = ∞ X j=ℓ σi (λj ) ≤ C|σi (λ)|ℓ , where C is a constant depending only on λ. A similar inequality holds for (ℓ) the embeddings τi . We can conclude hence that Yλ − Yλ ∈ CQℓ . We fix a small number ε > 0. Since the law of Yλ is singular, we can find two closed sets A, B ⊂ Rn+2m such that their union covers Supp Yλ , µ(A) < ε and P(Yλ ∈ B) < ε. Here and everywhere below, µ denotes the Lebesgue measure. If ℓ is sufficiently large, we have µ(A + cQℓ ) < 2ε and P(Yλ ∈ B + CQℓ ) < (ℓ) 2ε, where c and C are the same as above. Hence P(Yλ ∈ B) < 2ε in (ℓ) particular. We estimate the cardinality of A′ := Supp(Yλ ) ∩ A. If x, y ∈ A′ are distinct, then x + (c/2)Qℓ and y + (c/2)Qℓ are disjoint. Hence |A′ | < µ(A′ + (c/2)Qℓ ) < C1 εMλℓ , µ((c/2)Qℓ ) where C1 is a constant depending only on λ. By Lemma 16 (here k = 0), we (ℓ) can estimate from above the cardinality of B ′ = Supp(Yλ ) ∩ B by C2 Mλℓ . BERNOULLI CONVOLUTIONS AND GROUP GROWTH 21 (ℓ) We put our estimates together to bound H(Yλ ). We write X (ℓ) (ℓ) (ℓ) H(Yλ ) = −P(Yλ = x) log(P(Yλ = x)) x∈A′ + X x∈B ′ (ℓ) −P(Yλ (ℓ) = x) log(P(Yλ = x)) (ℓ)  P(Y (ℓ) ∈ A′ )  P(Yλ ∈ A′ ) λ log |A′ | |A′ |  P(Y (ℓ) ∈ B ′ )  P(Y (ℓ) ∈ B ′ )  ′ λ λ + |B | · − log |B ′ | |B ′ | ≤|A′ | ·  − (ℓ) ≤ − P(Yλ (ℓ) + P(Yλ (ℓ) ∈ A′ ) log(P(Yλ (ℓ) ∈ A′ )) − P(Yλ (ℓ) ∈ A′ ) log |A′ | + P(Yλ (ℓ) ∈ B ′ ) log(P(Yλ ∈ B ′ ) log |B ′ | ∈ B ′ )) ≤1 + log(C1 εMλℓ ) + 2ε log(C2 Mλℓ ). If we set ε sufficiently small depending only on C1 and C2 , hence ulti(ℓ) mately depending only on λ, then we obtain H(Yλ ) < log(Mλℓ ). We can conclude now that (ℓ) H(Yλ ) < log(Mλ ) hλ ≤ ℓ proving the claim.  3.4. Although (1.2) is not stated in this form in [25] it is essentially contained in that paper. For the reader’s convenience, we show how to reduce it to the main result of [25] that we now recall. All of the ideas in this paragraph are taken from [25]. For an integer n denote by Dn the partition of R into intervals of length 2−n such that 0 is an endpoint of two intervals in the partition and by H(ν, Dn ) the Shannon entropy of ν with respect to the partition Dn . For integers m < n, denote by H(ν, Dn |Dm ) = H(ν, Dn ) − H(ν, Dm ) the conditional entropies. This is the notation in [25], which differs from ours, and we only use it in this paragraph. Theorem 19 (Special case of [25, Theorem 1.3]). Let λ ∈ (1/2, 1) and suppose that dim µλ < 1. Then 1 (n) (3.2) H(µλ , Dqn′ |Dn′ ) = 0 lim n→∞ n′ for any q > 0, where n′ = ⌊n · log λ−1 ⌋. We first consider the case when dim µλ < 1. We recall from [20, Lemma 1.52] that for each algebraic number λ, there are cλ and dλ such that any two (n) distinct points in the support of µλ are of distance at least cλ n−dλ Mλ−n . Hence, taking q sufficiently large, we can write 1 1 (n) (n) lim H(µλ , Dqn′ ) = lim H(µλ ) = hλ . n→∞ n n→∞ n We combine this with (3.2) and deduce hλ 1 (n) H(µλ , Dn′ ) = . lim n→∞ n′ log λ−1 22 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ (n) ′ Since µλ approximates µλ at scale 2−n , 1 1 (n) lim H(µλ , Dn′ ) = lim ′ H(µλ , Dn′ ) n→∞ n′ n→∞ n The quantity on the left hand side of this equation is known to equal dim µλ , see [19]. It is left to consider the case dim µλ = 1, and we need to prove that hλ ≥ log λ−1 . The observation that hλ < log λ−1 implies µλ is singular goes back to Garsia [21]. Here we need a slightly stronger statement that we obtain by writing 1 1 (n) 1 = dim µλ = lim ′ H(µλ , Dn′ ) = lim ′ H(µλ , Dn′ ) n→∞ n n→∞ n hλ 1 (n) . ≤ lim ′ H(µλ ) = n→∞ n log λ−1 This completes the proof of (1.2). We can now prove Theorem 1. Proof of Theorem 1. If Lehmer’s conjecture holds, then there is a number ε > 0 such that log Mλ > ε for all algebraic numbers λ ∈ (1/2, 1). Then hλ ≥ 0.44ε by Theorem 5. If λ is sufficiently close to 1 so that log λ−1 < 0.44ε, then hλ > log λ−1 and dim µλ = 1 by (1.2).  4. Uniform exponential growth for linear groups This section is devoted to the proof of Theorem 4 and the consequences of Theorem 5 for group growth. Recall that given a group G generated by a finite subset S, we denote by ρS the rate of exponential growth: 1 log |S n |. n Since |S n+m | 6 |S n ||S m | for every n, µ ∈ N the above limit exists, by the classical subadditive lemma. We also note that ρS = ρS∪{1} , because S (S ∪ {1})n = ni=0 S i , and hence |(S ∪ {1})n | 6 (n + 1)|S n |. So without loss of generality, we will assume that 1 ∈ S. Before going into any details we record here the following initial observation, whose proof we leave to the reader. Let gλ,1 and gλ,−1 be the affine transformations of the complex line x 7→ λx + 1 and x 7→ λx − 1. Set Sλ := {gλ,1 , gλ,−1 }. Then we have: ρS := lim n→+∞ ρSλ = ρλ , where ρλ is defined in (1.4). In particular Theorem 5 combined with (1.5) implies that ρSλ > 0.44 min{1, log Mλ }. Remark 20. It is worth remarking here that the standard argument for proving exponential word growth in finitely generated groups is to exhibit two elements that generate a free semi-group. Every non virtually nilpotent solvable group contains a free semigroup (see e.g. [11] and references therein). However there is no uniform bound on the word length of these free generators: indeed in [11] a construction is given of a sequence of algebraic numbers λn such that Sλn generates a non-virtually nilpotent subgroup of affine transformations, and yet no pair of elements in (Sλn )n generate a BERNOULLI CONVOLUTIONS AND GROUP GROWTH 23 free semigroup. Therefore there is no hope of obtaining a good lower estimate for ρS using ping-pong techniques only, as was done in [10, 13] in the non-virtually solvable case. According to a celebrated lemma of Jordan [30], there is a function J = J(d) ∈ N such that every finite subgroup of GLd (C) contains a normal abelian subgroup of index at most J(d). The following is the main theorem of this section: Theorem 21. Let S be a finite subset of GLd (C) generating a virtually solvable subgroup, then either ρS = 0 and hSi is virtually nilpotent, or there is λ ∈ C× , not a root of unity, such that ρS > 1 log Mλ . 27d!J(d) Recall that Mλ is the Mahler measure of the minimal polynomial of λ in Z[X] if λ is algebraic over Q. We adopt the convention that Mλ = 2 if λ is transcendental. Remark 22. The classical geometric proofs of Jordan’s lemma by Bieber2 bach and Frobenius give a bound on J(d) of the form dO(d/ log d) , while recent work of Michael Collins [14] based on the classification of finite simple groups shows that J(d) 6 (d + 1)! if d > 71. We will show additionally, that if KS denotes the field generated by the matrix entries of each element s ∈ S, then λ can be chosen to be algebraic over KS of degree at most d!. In particular: Corollary 23. Assuming the Lehmer conjecture, there is c > 0 such that the following holds. If the finite subset S ⊂ GLd (C) generates a virtually solvable subgroup, then either ρS = 0 and hSi is virtually nilpotent, or c ρS > . d!J(d) Using Dobrowolski’s bound for the Mahler measure of an algebraic number of bounded degree (see [16]) we obtain in a similar way the following consequence, which was pointed out to us by Andreas Thom. Corollary 24. There is an absolute constant c > 0 such that if the finite subset S ⊂ GLd (Q) generates a virtually solvable subgroup, then either ρS = 0 and hSi is virtually nilpotent, or c ρS > 2d . d The proof of Theorem 21 goes by first reducing to subgroups of Uppd (C), the subgroup of GLd (C) made of upper triangular matrices, and then by finding a suitable quotient to Aff(C), the group of affine transformations of the complex line (similarities). Note that we have an isomorphism: Aff(C) ≃ {ga,b :=  a b 0 1  ; a ∈ C∗ , b ∈ C} 6 GL2 (C) 24 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ The matrix ga,b identifies with the affine transformation x 7→ ax + b. If g = ga,b , we set a(g) = a and b(g) = b. We make the following simple observation, whose proof we leave to the reader: Fact: If λ ∈ C \ {0, 1} and t1 6= t2 , u1 6= u2 , then the pair (gλ,t1 , gλ,t2 ) is conjugate to the pair (gλ,u1 , gλ,u2 ) by an element in Aff(C). Lemma 25. Let S be a finite subset of Aff(C) containing the identity. If hSi is not virtually nilpotent, then there is g, γ ∈ S 3 such that the pair (g, γ) is conjugate in Aff(C) to the pair (gλ,1 , gλ,−1 ) for some λ ∈ C∗ , which is not a root of unity. Proof. First observe that the multiplicative subgroup of C∗ generated by the a(s), s ∈ S, is infinite, for otherwise the subgroup hSi would be virtually abelian. In particular, there is s0 ∈ S such that λ0 := a(s0 ) is not a root of unity. Up to conjugating S in Aff(C), we may assume without loss of generality that b(s0 ) = 0. So s0 = gλ0 ,0 . Now note that there must exist some s ∈ S such that b(s) 6= 0, for otherwise hSi would be abelian. Now not both λ0 a(s) and λ20 a(s) are roots of unity. Let γ be either s0 s or s20 s, so that a(γ) is not a root of unity. Accordingly, let g be either ss0 , or ss20 . Then λ := a(γ) = a(g) is not a root of unity, while b(γ) 6= b(g). From the above fact, we deduce that (g, γ) is conjugate in Aff(C) to the pair (gλ,1 , gλ,−1 ) as desired.  If S ⊂ GLd (C), recall that KS denotes the subfield of C generated by the matrix entries of each s ∈ S. Corollary 26. Let S be a finite subset of Aff(C) containing the identity. Assume that hSi is not virtually nilpotent, then there is λ ∈ KS \ {0}, which is not a root of unity, such that 1 ρS > log Mλ . 9 Proof. Indeed S 3n contains all products of at most n affine transformations of the form gλ,1 or gλ,−1 . The images of 0 under these maps form the support (n) of the measure µλ , so ρS > 31 ρλ . The desired inequality then follows from Theorem 5. If Mλ > 2, set λ = 2.  Lemma 27. Let Γ be a solvable closed algebraic subgroup of GLn (C), and Γ◦ the connected component of the identity. The following are equivalent: (1) [Γ, Γ] is unipotent, (2) Γ is a subgroup of a connected solvable algebraic subgroup of GLn (C). Moreover if this holds, then there is a finite abelian subgroup F such that Γ = F Γ◦ , and a diagonalizable subgroup H 6 Γ containing F such that H = F H ◦ , and Γ◦ = H ◦ Γu where Γu is the unipotent radical of Γ◦ . Proof. Note that (2) implies (1), because Γ can be conjugated inside Uppd (C), as follows from the Lie-Kolchin theorem. We now pass to the converse. Note that if H and F exist as in the statement of the lemma, then Γ can be triangularized and hence (2) holds. BERNOULLI CONVOLUTIONS AND GROUP GROWTH 25 Indeed, looking at a composition series for Γu in Cn , we see that H preserves it and can be diagonalized in a basis adapted to this decomposition. We will prove the existence of H as above by induction on dim Γ. First recall that it is a well-known observation attributed to Platonov [40] (see also [46, 10.10], [5, 5.11]) that every complex algebraic group has a finite subgroup intersecting each connected component. So there is a finite subgroup F with Γ = F Γ◦ . If (1) holds, then F must be abelian, because [F, F ] is finite and unipotent, hence trivial. Being finite, F must consist of semisimple elements, and since it is abelian, it is a diagonalizable subgroup. To find H, we argue as in the standard proof of the existence of a maximal torus mapping onto the quotient of a connected solvable algebraic group with its unipotent radical ([28, 19.3]). Let ZΓ (F ) be the centralizer of F in Γ and ZΓ (F )◦ its connected component of the identity. Since [F, Γ] ⊂ Γu , the diagonalizable subgroup F acts trivially by conjugation on Γ/Γu , and [28, Corollary 18.4] tells us that the map φ : Γ → Γ/Γu sends ZΓ (F )◦ onto Γ◦ /Γu . Since F 6 ZΓ (F ) and F Γ◦ = Γ, we conclude that ZΓ (F ) maps onto Γ/Γu . In particular ZΓ (F ) = F ZΓ (F )◦ , since every unipotent subgroup is connected. So we may replace Γ by ZΓ (F ) and argue by induction if dim ZΓ (F ) < dim Γ. The subgroup H thus found for ZΓ (F ) will work for Γ as well. Otherwise Γ◦ 6 ZΓ (F ), and given a maximal torus in H ◦ 6 Γ◦ , we may set H := F H ◦ , which is the desired diagonalizable subgroup. This ends the proof.  Remark 28. Denote by K the field of definition of the algebraic group Γ that appear in the previous lemma. It is not a priori clear that the subgroup F in the conclusion of the lemma can be chosen inside Γ(K). However, we show now that this is indeed the case if Γ 6 Uppd , and moreover H can be chosen defined and split over K. To see this, note that since maximal K-tori in Uppd are K-split, so are the maximal K-tori T in Γ◦ . Since they are all conjugate by an element of Γ◦u (K), we have Γ(K) = NΓ (T )(K)Γ◦u (K). But NΓ (T ) = ZΓ (T ) (apply [28, 19.4.b] with G = Uppd ), so replacing Γ with ZΓ (T ), we may assume that maximal K-tori in Γ◦ are K-split and are inside the center of Γ. This implies in particular that there is only one such T . Then Γ/T is virtually unipotent, and the exact sequence 1 → Γu (K) → Γ(K)/T (K) → Γ(K)/Γ◦ (K) → 1 splits, because Γ◦ (K)/T (K) is divisible, torsion free and nilpotent. For a proof of the last assertion, see the discussion above 10.10 in [46]. So there is a subgroup F ⊂ Γ(K) such that F ∩ Γu (K) = 1 (forcing F to be abelian) and Γ(K) = F T (K)Γu (K). Clearly F is made of semisimple elements (if f ∈ F some power of f lies in T ). Also every semisimple element in Uppd (K) is diagonalizable. It follows that F T (K) is an abelian subgroup made of diagonalizable elements, hence it can be simultaneously diagonalized, and this yield the desired subgroup H. Lemma 29. Let Γ be a subgroup of Uppd (C). If Γ is not virtually nilpotent, then there is a homomorphism ρ : Γ → Aff(C), whose image is not virtually nilpotent. 26 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Proof. We prove the result for subgroups of a connected solvable algebraic group G (this is equivalent to our assumption by the Lie-Kolchin theorem). We will work by induction on dim G. Without loss of generality, we may assume that Γ is Zariski-closed, and let Γ◦ be its connected component of the identity. Under the assumption that Γ is Zariski-connected, a proof of this lemma can be found in [7, Lemma 10.7]. We need some adjustments to handle the general case. To prove Lemma 29, we have to find a character χ : Γ → C∗ , and a nontrivial cocycle β : Γ → C, that is a map such that β(gh) = β(g) + χ(g)β(h), and β(ker χ) 6= 0. Then the map Γ → Aff(C) sending g to the matrix   χ(g) β(g) 0 1 gives the desired homomorphism. By Lemma 27 above, there is a diagonalizable subgroup H of Γ such that Γ = HΓu , and Γu = Γ ∩ U , where U is the unipotent radical of G. The subgroup H lies in a maximal torus of G, say T , so that G = T · U . Let Z be the center of U . It is a normal algebraic subgroup of G of positive dimension. If Γ◦ acts trivially on Z by conjugation, then we may pass to G/Z and apply induction, since then the image of Γ in G/Z will not be virtually nilpotent. So assume that its action is not trivial. Note that the Γ-action on Z factors through G/U ≃ T . Since T is a torus, its action on the additive group Z splits into weight spaces. There is a weight χ : T → C∗ such that χ(Γ◦ ) 6= 1. Let Zχ 6 Z be a one-dimensional subspace in the eigenspace of χ, so that tzt−1 = χ(t)z when t ∈ T . Note that Zχ is a normal subgroup of G. We can assume that H ◦ acts trivially on U/Zχ , for otherwise the image of Γ in G/Zχ would not be virtually nilpotent and we could use induction. This means that [H ◦ , U ] 6 Zχ . On the other hand H ◦ does not commute with Γu , for otherwise Γ◦ would be nilpotent. Pick h0 ∈ H ◦ such that [h0 , Γu ] 6= 1. Since Γ = HΓu , and H commutes with h0 , we see that [h0 , Γ] 6 Zχ . Then we set β(γ) = [h0 , γ], after identifying Zχ with the additive group of C. It is easy to check that this is a non trivial cocycle as claimed. This ends the proof of the lemma.  Remark 30. If G is a K-split connected solvable K-subgroup of GLd (C), where K is some subfield of C and Γ 6 G is a closed algebraic K-subgroup, which is not virtually nilpotent, then replacing everywhere maximal torus by K-split maximal torus, the proof above combined with Remark 28 shows that the homomorphism ρ : Γ → Aff(C) we have constructed is defined over K. We conclude: Corollary 31. Let S be a finite subset of Uppd (C) containing the identity. Assume that hSi is not virtually nilpotent, then there is λ ∈ KS \ {0}, which is not a root of unity, such that ρS > 1 log Mλ . 9 BERNOULLI CONVOLUTIONS AND GROUP GROWTH 27 Proof. This follows from the combination of Lemma 29, Corollary 26 and Remark 30.  To handle virtually solvable subgroups not necessarily contained in Uppd (C), we need the following lemma. Lemma 32. Let G be a group, and H a subgroup with G = SH for some finite generating subset S of G containing 1, but not assumed symmetric. Let ρ : H → Aff(C) be a homomorphism with non virtually nilpotent image. Then the subgroup generated by S 3 ∩ H has a non virtually nilpotent image under ρ. Proof. Let χ be the character H → C∗ induced by the natural homomorphism Aff(C) → C∗ . First we claim that χ(hS 3 ∩ Hi) is infinite. Indeed H is generated by the elements of the form s1 s2 s−1 3 belonging to H, with each si in S. At least one of them must map to an element of infinite order under −1 χ, say χ(s1 s2 s−1 3 ) has infinite order. Let s4 ∈ S be such that s3 ∈ s4 H. Then s3 s4 ∈ H. So we see that either χ(s3 s4 ) has infinite order, or else s1 s2 s4 = s1 s2 s−1 3 s3 s4 has infinite order. This proves the claim. So pick γ ∈ S 3 ∩ H with χ(γ) of infinite order. Now observe that every virtually nilpotent subgroup of Aff(C) containing ρ(γ) must be abelian. Indeed if it contains an element not commuting with ρ(γ), then the commutator will be a non-trivial translation t, but the subgroup generated by ρ(γ)n and tn is nilpotent for no n ∈ N (the centralizers of these two elements have trivial intersection, so there is no center). So if ρ(hS 3 ∩ Hi) were virtually nilpotent, it would be abelian. However −1 ρ(H) is not abelian, and it is generated by the ρ(s1 s2 s−1 3 ) with s1 s2 s3 belonging to H and s1 , s2 , s3 ∈ S. The centralizer of ρ(γ) in Af f (C) is abelian. Pick such elements with [ρ(s1 s2 s−1 3 ), ρ(γ)] 6= 1. As above let s4 ∈ S with s3 s4 ∈ H. We see that either ρ(s3 s4 ) does not commute with ρ(γ), or else ρ(s1 s2 s4 ) does not commute with ρ(γ). In both cases ρ(hS 3 ∩ Hi) is not abelian, hence not virtually nilpotent. The lemma is proved.  We can now conclude the Proof of Theorem 21. Let G be the Zariski closure of the subgroup Γ generated by S. Let T be a maximal torus of G◦ . For every g ∈ G, gT g −1 is a maximal torus, hence is conjugate to T by an element of G◦ . This shows that G = NG (T )G◦ . Diagonalizing T , we see that the centralizer ZG (T ) of T in G has index at most d! in NG (T ). By the result of Platonov mentioned at the beginning of the proof of Lemma 27, there is a finite subgroup F such that ZG (T ) = F ZG (T )◦ , and Jordan’s theorem implies that there is an abelian subgroup A in F with index at most J(d). Now note that the commutator subgroup of the subgroup AG◦ is unipotent. So Lemma 27 shows that AG◦ can be conjugated inside Uppd (C) by an element of GLd (C). The Zariski-closure H of Γ ∩ AG◦ is defined over KS and can be triangularized by some element of GLd (C). It follows that there b S of KS with degree at most d! such that H can be is a field extension K b S ). triangularized by an element of GLd (K 28 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ Since H ∩ Γ is not virtually nilpotent, by Lemma 29 and the remark bS , following it, there is a homomorphism ρ : H → Aff(C), defined over K with non virtually nilpotent image. Since H has index at most d!J(d) in Γ, setting S0 = S d!J(d) , we see that S0 H = Γ, so that we may apply Lemma 32 and conclude that hS03 ∩ Hi has non virtually nilpotent image under ρ. b × not a root Hence Corollary 26 shows that ρS03 ∩H > 91 Mλ for some λ ∈ K S 1 ρS03 .  of unity. The result follows immediately since ρS > 3d!J(d) 5. Further directions and open problems We already mentioned in the introduction that given ε > 0 there exist a finitely generated group Γ = hSi such that 0 < ρS < ε. These examples of groups with slow exponential growth were constructed by Grigorchuk and de la Harpe in [22] out of a presentation for the Grigorchuk group of intermediate growth. They are virtually a product of finitely many free groups. Taking a suitable quotient such groups can be made solvable, in fact even metabelian-by-(finite 2-group), as was shown in [4]. However the solvability class in these examples is not bounded. We record here the following: Problem 1. Given r ∈ N, is there cr > 0 such that if S is a finite generating subset of a solvable group with solvability class bounded by r, then either ρS = 0 and hSi is virtually nilpotent, or ρS > cr ? In view of Lemma 16 (or [11, §7]) a positive answer to this question implies the Lehmer conjecture. It would be nice to investigate, as we did in this paper for linear groups, whether the converse holds as well. To that end we state the following version of the previous problem. Problem 2. Given r ∈ N, is there cr > 0 such that if S is a finite generating subset of a solvable group with solvability class bounded by r, then either × ρS = 0 and hSi is virtually nilpotent, or there is a number λ ∈ Q not a root of unity such that ρS > cr log Mλ ? The problem obviously reduces to the case when the group is just not virtually nilpotent in the sense that every proper quotient of the group is virtually nilpotent. Such groups are known to be virtually metabelian [11, 23]. Those that are metabelian (i.e. r = 2) embed in Aff(K) for some field K, hence for those the answer to the above problem is positive and the proof is easy. However to handle to case when r > 2, one needs new ideas to overcome the finite index issue. Another interesting question is whether there are some numbers λ such that hλ = log Mλ . In particular, the case of Salem numbers would be very interesting, because in that case hλ = log Mλ = log λ−1 is equivalent to dim µλ = 1 by (1.2). Problem 3. Is it true that hλ = log λ−1 for all Salem numbers λ ∈ (1/2, 1)? Observe that Salem numbers have conjugates on the unit circle, hence Proposition 7 does not apply. However, we learnt from Paul Mercat [34] that there are examples outside the scope of Proposition 7, such that hλ < BERNOULLI CONVOLUTIONS AND GROUP GROWTH 29 log Mλ . Such examples are the roots of the polynomial x6 + x5 + x4 − x3 + x2 + x + 1, which are three pairs of complex conjugates that are inside, on and outside the unit circle, respectively, and Mλ < 2. Mercat showed that ρλ < log Mλ by computing the first 8 steps of the random walk and finding (8) that | Supp(µλ )| < Mλ8 . References [1] J. C. Alexander and D. Zagier. The entropy of a certain infinitely convolved Bernoulli measure. J. London Math. Soc. (2) 44 (1):121–134, 1991. ↑5 [2] F. Amoroso and S. David. Le problème de Lehmer en dimension supérieure. J. Reine Angew. Math. 513:145–179, 1999. ↑5 [3] C. Bandt. On the Mandelbrot set for pairs of linear maps. Nonlinearity 15 (4):1127– 1147, 2002. ↑4 [4] L. Bartholdi and Y. de Cornulier. Infinite groups with large balls of torsion elements and small entropy. Arch. Math. (Basel) 87 (2):104–112, 2006. ↑28 [5] A. Borel and J.-P. Serre. Théorèmes de finitude en cohomologie galoisienne. Comment. Math. Helv. 39:111–164, 1964. ↑25 [6] P. Borwein, E. Dobrowolski, and M. J. Mossinghoff. Lehmer’s problem for polynomials with odd coefficients. Ann. of Math. (2) 166 (2):347–366, 2007. ↑5 [7] E. Breuillard and T. Gelander. Uniform independence in linear groups. Invent. Math. 173 (2):225–263, 2008. ↑3, 26 [8] E. Breuillard and P. P. Varjú. On the dimension of Bernoulli convolutions, 2016. Work in progress. ↑2 [9] E. Breuillard. Diophantine geometry and uniform growth of finite and infinite groups. Proceedings of the International Congress of Mathematicians, 2014 ICM (Seoul). ↑2 [10] . A strong tits alternative. arXiv:0804.1395. ↑3, 23 [11] . On uniform exponential growth for solvable groups. Pure Appl. Math. Q. 3 (4, Special Issue: In honor of Grigory Margulis. Part 1):949–967, 2007. ↑3, 22, 28 [12] . A height gap theorem for finite subsets of GLd (Q) and nonamenable subgroups. Ann. of Math. (2) 174 (2):1057–1110, 2011. ↑3 [13] . Heights on SL2 and free subgroups. In Geometry, rigidity, and group actions, pages 455–493. 2011. ↑3, 23 [14] M. J. Collins. On Jordan’s theorem for complex linear groups. J. Group Theory 10 (4):411–423, 2007. ↑23 [15] T. M. Cover and J. A. Thomas. Elements of information theory. Wiley-Interscience [John Wiley & Sons], Hoboken, NJ, Second, 2006. ↑9 [16] E. Dobrowolski. On a question of Lehmer and the number of irreducible factors of a polynomial. Acta Arith. 34 (4):391–401, 1979. ↑23 [17] P. Erdős. On a family of symmetric Bernoulli convolutions. Amer. J. Math. 61:974– 976, 1939. ↑1 [18] A. Eskin, S. Mozes, and H. Oh. On uniform exponential growth for linear groups. Invent. Math. 160 (1):1–30, 2005. ↑3 [19] D.-J. Feng and H. Hu. Dimension theory of iterated function systems. Comm. Pure Appl. Math. 62 (11):1435–1500, 2009. ↑22 [20] A. M. Garsia. Arithmetic properties of Bernoulli convolutions. Trans. Amer. Math. Soc. 102:409–432, 1962. ↑21 [21] . Entropy and singularity of infinite convolutions. Pacific J. Math. 13:1159– 1169, 1963. ↑4, 5, 18, 22 [22] R. Grigorchuk and P. de la Harpe. Limit behaviour of exponential growth rates for finitely generated groups. In Essays on geometry and related topics, Vol. 1, 2, pages 351–370. 2001. ↑2, 28 [23] J. R. J. Groves. Soluble groups with every proper quotient polycyclic. Illinois J. Math. 22 (1):90–95, 1978. ↑28 [24] K. G. Hare and N. Sidorov. A lower bound for Garsia’s entropy for certain Bernoulli convolutions. LMS J. Comput. Math. 13:130–143, 2010. ↑5 30 EMMANUEL BREUILLARD AND PÉTER P. VARJÚ [25] M. Hochman. On self-similar sets with overlaps and inverse theorems for entropy. Ann. of Math. (2) 180 (2):773–822, 2014. ↑1, 3, 6, 21 [26] A. Horn. On the eigenvalues of a matrix with prescribed singular values. Proc. Amer. Math. Soc. 5:4–7, 1954. ↑15 [27] R. A. Horn and C. R. Johnson. Topics in matrix analysis. Cambridge University Press, Cambridge, 1994. Corrected reprint of the 1991 original. ↑15 [28] J. E. Humphreys. Linear algebraic groups. Springer-Verlag, New York-Heidelberg, 1975. Graduate Texts in Mathematics, No. 21. ↑25 [29] K. I. and M. M. Sumset and inverse sumset inequalities for differential entropy and mutual information. preprint arXiv:1206.0489, 2012. ↑5, 11 [30] C. Jordan. Mémoire sur les équations différentielles linéaires à intégrale algébrique. J. Reine Angew. Math. 84:89–215, 1878. ↑23 [31] V. A. Kaı̆manovich and A. M. Vershik. Random walks on discrete groups: boundary and entropy. Ann. Probab. 11 (3):457–490, 1983. ↑11 [32] S. P. Lalley. β-expansions with deleted digits for Pisot numbers β. Trans. Amer. Math. Soc. 349 (11):4355–4365, 1997. ↑5 [33] M. Madiman. On the entropy of sums. In Information Theory Workshop, 2008. ITW 08. IEEE:303–307, 2008. ↑5, 11 [34] P. Mercat. Private communication. ↑28 [35] . Semi-groupes fortement automatiques. Bull. Soc. Math. France 141 (3):423– 479, 2013. ↑5 [36] M. Mignotte. Sur les multiples des polynômes irréductibles. Bull. Soc. Math. Belg. 27 (3):225–229, 1975. ↑4 [37] M. Pathiaux. Sur les multiples de polynômes irréductibles associés à certains nombres algébriques. In Séminaire Delange-Pisot-Poitou, 14e année (1972/73), Théorie des nombres, Fasc. 1, Exp. No. 13, pages 9. 1973. ↑4 [38] Y. Peres, W. Schlag, and B. Solomyak. Sixty years of Bernoulli convolutions. In Fractal geometry and stochastics, II (Greifswald/Koserow, 1998), pages 39–65. 2000. ↑1 [39] J. Peters. Entropy on discrete abelian groups. Adv. in Math. 33 (1):1–13, 1979. ↑6 [40] V. P. Platonov. The theory of algebraic linear groups and periodic groups. Izv. Akad. Nauk SSSR Ser. Mat. 30:573–620, 1966. ↑25 [41] R. Salem. A remarkable class of algebraic integers. Proof of a conjecture of Vijayaraghavan. Duke Math. J. 11:103–108, 1944. ↑2 [42] P. Shmerkin. On the exceptional set for absolute continuity of Bernoulli convolutions. Geom. Funct. Anal. 24 (3):946–958, 2014. ↑1 [43] T. Tao. Sumset and inverse sumset theory for Shannon entropy. Combin. Probab. Comput. 19 (4):603–639, 2010. ↑5, 11 [44] T. Tao and V. Vu. Additive combinatorics. Cambridge Studies in Advanced Mathematics, vol. 105. Cambridge University Press, Cambridge, 2006. ↑11 [45] P. P. Varjú. Absolute continuity of Bernoulli convolutions for algebraic parameters, 2016. arXiv:1602.00261v1. ↑4 [46] B. A. F. Wehrfritz. Infinite linear groups. An account of the group-theoretic properties of infinite groups of matrices. Springer-Verlag, New York-Heidelberg, 1973. Ergebnisse der Matematik und ihrer Grenzgebiete, Band 76. ↑25 Mathematische Institut, Einsteinstrasse, 62, Universität Münster, GERMANY E-mail address: [email protected] Centre for Mathematical Sciences, Wilberforce Road, Cambridge CB3 0WA, UK E-mail address: [email protected]
4math.GR
Inverse Reinforcement Learning with Conditional Choice Probabilities Mohit Sharma1 , Kris M. Kitani1 , and Joachim Groeger2 arXiv:1709.07597v1 [cs.AI] 22 Sep 2017 1 Robotics Institute, Carnegie Mellon University 1 {mohits1, kkitani}@cs.cmu.edu 2 [email protected] Abstract We make an important connection to existing results in econometrics to describe an alternative formulation of inverse reinforcement learning (IRL). In particular, we describe an algorithm using Conditional Choice Probabilities (CCP), which are maximum likelihood estimates of the policy estimated from expert demonstrations, to solve the IRL problem. Using the language of structural econometrics, we re-frame the optimal decision problem and introduce an alternative representation of value functions due to (Hotz and Miller 1993). In addition to presenting the theoretical connections that bridge the IRL literature between Economics and Robotics, the use of CCPs also has the practical benefit of reducing the computational cost of solving the IRL problem. Specifically, under the CCP representation, we show how one can avoid repeated calls to the dynamic programming subroutine typically used in IRL. We show via extensive experimentation on standard IRL benchmarks that CCP-IRL is able to outperform MaxEnt-IRL, with as much as a 5x speedup and without compromising on the quality of the recovered reward function. Introduction The problem of extracting the reward function of a task given observed optimal behavior has been studied in parallel in both robotics and economics. In robotics this literature is collected under the heading "Inverse Reinforcement Learning" (IRL), (Ng and Russell 2000) (Abbeel and Ng 2004). The aim here is to learn a reward function that best explains demonstrations of expert behavior so that a robotic system can reproduce expert like behavior. Alternatively, in economics it is referred to as "structural econometrics" (Miller 1984) (Pakes 1986) (Rust 1987) and is used to help economists better understand human decision making. Although both fields developed in parallel, they are similar in that both seek to uncover a latent reward function of an underlying Markov Decision Process (MDP). One of the main challenges in IRL is the large computational complexity of current state of the art algorithms (Ziebart et al. 2008) (Ratliff, Bagnell, and Zinkevich 2006). To infer the reward function of the underlying MDP, we need to repeatedly solve this MDP at every step of a reward parameter optimization scheme. The MDP solution, which is characterized by a value function, requires a computationally expensive Dynamic Programming (DP) procedure. Unfortunately, solving this DP step repeatedly makes IRL algorithms computationally prohibitive. Thus, recent works have looked at scaling IRL algorithms to large environment spaces (Finn, Levine, and Abbeel 2016) (Levine and Koltun 2012). This problem of large computational complexity has also been studied in economics (Hotz and Miller 1993) (Su and Judd 2012) (Aguirregabiria and Mira 2002). Among the many works, Conditional Choice Probability (CCP) estimators (Hotz and Miller 1993) are particularly interesting because of their computational efficiency. CCP estimators use CCP values to estimate the reward function of the MDP. The CCP values specify the optimal action for a state and are estimated from expert demonstrations. These estimators are computationally efficient since they avoid the repeated computation of the DP step by using an alternative representation of the MDP’s value function. In this paper we leverage results from (Rust 1987), (Hotz and Miller 1993) and (Magnac and Thesmar 2002) to formulate an estimation routine for the reward function with CCPs, that avoids repeated calls to the solver of the full dynamic decision problem. The key insight from (Hotz and Miller 1993) is that differences in current reward and future values between actions can be calculated from CCPs. This allows us to express future value functions in terms of difference value functions and therefore CCPs. Since CCPs are directly observed in the data, we can use this function representation to estimate the value function of the MDP at each step of the optimization process without solving the expensive dynamic programming (DP) formulation. This results in an algorithm whose overall computational time is comparable to a single MDP computation of a traditional gradient-based IRL method. In this work we introduce CCP-IRL by incorporating CCPs into IRL. We test the CCP-IRL algorithm on multiple different IRL benchmarks and compare the results to the state of the art IRL algorithm, MaxEnt-IRL (Ziebart et al. 2008). We show that with CCP-IRL we can achieve up to 5× speedup without affecting the quality of the inferred reward function. We also show that this speedup holds across large state spaces and increases for complex problems, such as, problems where value iteration takes much longer to converge. Preliminaries In this section, we first introduce the MDP formulation as used in the econometrics literature under the name "Dynamic Discrete Choice Model". Following this, we show how the optimality equation is formulated under these assumptions, and how the resulting optimization problems can be related to traditional IRL algorithms. independence, we can write the original decision problem as:  V (xt , t ) = max r(xt , a) + at a∈A   + β · Ext+1 |xt ,a V (xt+1 ) . Dynamic Discrete Choice Model The ex-ante value function also follows a Bellman-like equation: h  V (xt ) = Et max r(xt , a) + at a∈A (5)  i  + β · Ext+1 |a,xt V (xt+1 ) A dynamic discrete choice (DDC) model (i.e., a discrete Markov decision process with action shocks) is defined as a tuple (X , A, T, r, E, F ). We assume a discrete state space, although this is not strictly necessary. X is a countable set of states with a cardinality of |X |. A is a finite set of actions with cardinality |A|. T is the transition function where T (x0 |x, a) is the probability of reaching state x0 given current state x and action a. The reward function r is a mapping r : A × X → R. Different from MDPs typically used in RL, each action also has a "payoff-shock" associated with it, that enters payoffs additively. Intuitively, the shock variable accounts for the possibility that an agent takes a non-optimal behavior due to some unobserved factor of the environment or agent. The vector of shocks is denoted  = [1 · · · |A| ] and  ∈ R|A| . Total rewards for action a ∈ A in state x ∈ X are therefore given by: r(a, x) + a . (1) . A shock value a ∈ R is often assumed to be distributed according to a Gumbel or Type 1 Extreme Value (TIEV) distribution, F (a ) = e−e −a (2) We will see that the use of a TIEV distribution is numerically convenient for the following derivations. However, alternative algorithms can be derived for other functional forms. Each shock a is independently and identically drawn from F (a ). This ensures that state transitions are conditionally independent. All serial dependence between t and t+1 is transmitted through xt+1 . (Rust 1988) proves the existence of optimal stationary policies in this setting. Bellman Optimality Equation Derivation Consider a system currently in state (xt , t ), where t is a vector of shock values. The decision problem is to select the action that maximizes the payoff:  V (xt , t ) = max r(xt , a) + at a∈A (3) + β · Ext+1 ,t+1 |xt ,a [V (xt+1 , t+1 )] where V is the value function, β is the discount factor and at ∈ t is the shock value when selecting action a at time t. Given the conditional independence assumption of the shock variable described previously, we can separate the integration of xt+1 and . Define the ex-ante value function (i.e., V prior to the revelation of the values of ) as: V (xt ) , Et [V (xt , t )] , (4) that is, the expectation of the value function with respect to the shock distribution. Using this notation and conditional Assuming TIEV distribution for the shock values, one obtains the following expression for the ex-ante value functions as shown by (Rust 1987): # " X   V (xt ) = ln exp r(xt , a) + β · Ext+1 |a,xt V (xt+1 ) a∈A + γ, (6) where γ is Euler’s constant. The expectation of the maximum is equal to the average of expected value functions, conditional on choosing action a with  integrated using the TIEV density. Weights in the average are given by the CCPs of choosing action a. Notice that the above is exactly the recursive representation of the Maximum Causal Entropy IOC algorithm as derived in Theorem 6.8 in (Ziebart 2010a). In our setting, the soft-max recursion is a consequence of Bellman’s optimality principle in a setting with a separable stochastic payoff shock with a TIEV distribution, while in (Ziebart 2010a) the authors derive the recursion from an information-theoretic perspective that enforces a maximum causal entropy distribution over trajectories. Conditional Choice Probability Inverse Reinforcement Learning We will now show how it is possible to efficiently recover the optimal value function, and consequently the underlying reward function, using the DDC model. The key insight is that the optimal value function can be directly estimated from observed state-actions pairs (Conditional Choice probabilities), observed over a large set of expert demonstrations. When this assumption holds the optimal value function can be represented as a linear function of the CCPs and efficiently computed for different parameter values without solving the DP problem iteratively. Conditional Choice Probabilities Since an outside observer does not have access to the shock (), the underlying deterministic policy of the expert σ(a|x, ) is not directly measurable. However, if we average decisions across trajectories conditioned on the same state variables we are able to identify the integrated policy. We denote this integrated policy by σ(a|x) ∈ [0, 1], the conditional choice probability (CCP) of an action being chosen conditioned on state x: σ(a|xt ) , E [1{a is optimal in state xt }] , (7) where 1{} is the indicator function. The event in the indicator function is equivalent to the event:  r(xt , a) + at + βExt+1 |a,xt V (xt+1 ) ≥ (8) r(xt , a0 ) + a0 t + βExt+1 |a0 ,xt V (xt+1 ), ∀a0 6= a Expanding the expectation under the TIEV assumption on the shock variable allows CCPs to be solved in closed-form:  exp r(xt , a) + βExt+1 |xt ,a V (xt+1 )  σ(a|xt ) = P 0 a0 ∈A exp r(xt , a ) + βExt+1 |xt ,a0 V (xt+1 ) (9) this inverse mapping and assuming TIEV distribution for , we get ˜(a|xt ) = γ − log σ(a|xt ). From (12) we can see that, excluding the unknown reward function, all other terms can be estimated from CCPs. We can now stack the ex-ante value function over all states, X   V= S(a) × R(a) + ˜(a) + βT(a)V (13) a where:   V (x1 )   .. V=  . V (x|X |   r(x1 , a)   .. R(a) =   . r(x|X | , a) Notice that (9) is identical to the definition of the policy of the MaxEnt formulation in (Ziebart 2010a), which is derived from an entropic prior on trajectories. The CCP is derived by integrating out the TIEV shock variable. Hotz-Miller’s CCP Method  Our aim in Inverse Reinforcement Learning is to find the parameterized reward function r(θ) for the given MDP/R. We now show how we can leverage the non-parameteric estimates of choice conditional probabilities to efficiently estimate the parameters (θ) of the reward function. First, we look at the alternative representation of the exante value function which can be derived from the CCP representation. Using this alternative representation, we will see how we can avoid solving the original MDP using the expensive dynamic programming formulation for every update of θ. Returning to the definition of ex-ante value function (4) we know that, h  V (xt ) = Et max r(xt , a) + at a∈A  i  + β · Ext+1 |a,xt V (xt+1 ) .  T(a) =  T (x1 |x1 , a), . . . , T (x|X | , x1 , a) .. . T (x1 |x|X | , a), . . . , T (x|X | , x|X | , a)   σ(a|x1 )   .. S(a) =   . σ(a|x|X | )   ˜(a|x1 )   .. ˜(a) =   . ˜(a|x|X | ) Notice that (13) is linear in ex-ante value function (V). Thus we can write a closed form solution for it. First, rearranging the terms we get, V− X  X  S(a) ∗ βT(a)V = S(a) ∗ [R(a) + ˜(a)] a a (14) Defining λ as a 1 × |X | vector of ones. We can now write the closed form solution for V as, #−1 " V= I− X (S(a)λ) ∗ [βT(a)] a Now, defining the expected shock given that action a is optimal as ˜(a|xt ) = E (at |a is optimal in state xt ), we can rewrite (11) as, h X V (xt ) = σ(a|xt ) r(xt , a) + ˜(a|xt ) +β X i T (xt+1 |xt , a)V (xt+1 )   (10) (Hotz and Miller 1993) show that if we can get consistent CCP estimates from the data, the above equation (10) can be estimated as, hX  V (xt ) = Et σ(a|xt ) r(xt , a) + at a∈A (11)  i  + β · Ext+1 |a,xt V (xt+1 ) a∈A  (12) xt+1 ∈X It was shown further that ˜(a|xt ) depends on CCPs and distribution of  only. They prove that the mapping between CCPs and choice specific value function is invertible. Using " × # X (15) S(a) ∗ [R(a) + ˜(a)] a The above is the value function representation used by (Pesendorfer and Schmidt-dengler 2008) and discussed in (Arcidiacono and Ellickson 2011). We now discuss the CCP-IRL algorithm and how it avoids repeatedly solving the original MDP problem. The pseudocode for CCP-IRL is given in Algorithm 1, where µD is expert’s feature expectations and f are features at every state. Notice that the only quantity dependent on θ in (15) is R(a, θ). Thus, to estimate V using (15) we calculate R(a, θ) Algorithm 1 CCP-IRL algorithm 1: procedure CCP-IRL(µD , f, S, A, T, γ) 2: θ(0) ← init_weights P −1 3: M ← [I − a (S(a)λ) ∗ [βT (a)]] 4: ˜ ← γ − log S(a) 5: for i ← 1, n do 6: R(i) ← θT f P   7: V (i) ← M × a S(a) × R(i) + ˜ (i) (i) (i) 8: πθ (a|x) ← eV (xa )−V (x) 9: E[µ(i) ] ← FORWARD PASS() 10: θ(i) ← θ(i−1) − α × (µD − E[µ(i) ]) 11: end for 12: end procedure for every θ value i.e., at every step of the iteration (Line 6). P −1 But the inverse matrix [I − a (S(a)λ) ∗ [βT(a)]] is independent of θ and hence can be pre-computed once for all iterations (Line 3). This inverse matrix computes the state visitation frequency for each state, weighted by the appropriate discount factor and hence encompasses a large part of calculations involved in MaxEnt (Ziebart 2010a). Given this inverse matrix computing V at any θ requires simple matrix operations (Line 7), which allows us to avoid solving the MDP using dynamic programming at every step of the iteration. Lines 8-10 calculate the gradient for the reward parameters and are explained in (Kitani et al. 2012). We also note how to calculate the initial CCP estimates (S). In their simplest form, the initial CCP estimates can be computed directly from N expert trajectories each with i Ti time periods: D = {(ait , xit )Tt=0 : i = 1, . . . , N } in tabular form. An initial maximum likelihood estimate can be computed by maintaining a table over state-action pair occurrences. Complexity Analysis The main computation in CCP-IRL is to estimate the inverse matrix in (15). In contrast the main computation in MaxEnt-IRL is solving the MDP using dynamic programming. However, note that unlike MaxEnt-IRL where we need to repeatedly solve the MDP using dynamic programming we only need to estimate the inverse matrix once. Once the matrix inverse has been found estimating the MDP in CCPIRL involves simple matrix computations and hence involve no significant computation overhead. Thus, assuming a total of N iterations for the entire MaxEnt-IRL convergence and T iterations for each backwards recursion, MaxEnt-IRL takes a total of O(N × T × |A| × |S|) (Ziebart 2010a). For CCP-IRL assuming the matrix inversion can be performed with state of the art matrix inversion method, we get a corresponding runtime of O(|S|2.4 + T × |A| × |S|). This complexity can be further reduced to O(T × |A| × |S|) for linear reward formulations. We also look at how for large state spaces, we can avoid using matrix inversion and rather estimate the inverse matrix (15) using successive approximations. Defin- Algorithm 2 Forward Pass 1: procedure F ORWARD PASS 2: D(0) (x) ← P (xi = xinitial ) 3: for i ← 1, n do 4: D(i−1) (xgoal ) ← 0 5: D(i) (x) ← D(i) (x) + πθ (a|x0 )D(i−1) (x0 ) 6: end for P 7: D(x) ← i D(i) (x) 8: return D(x) 9: end procedure P −1 ing A ≡ (I − β a (S(a)λ) ∗ [T(a)]) we can write it as −1 A = (I − βF ) where F is used as a shorthand for notational convenience. Premultiplying both sides with (I − βF ) we get (I−βF )×A = I which finally gives us A = I+βF A. We can now use this last equation to estimate the invese matrix A by successive approximations. From a computational perspective this can be much more efficient compared to estimating the inverse directly. Next, we will empirically show the above computational gains in CCP-IRL as well as discuss the expert data requirements for CCP-IRL. Experiments In this section we empirically validate, (1) the computational efficiency of CCP-IRL and (2) the underlying assumptions of consistent CCP estimates i.e., we show the data requirement for CCP-IRL. To this end we evaluate the performance of CCP-IRL on three standard IRL tasks. Since CCP-IRL is most closely related with traditional MaxEnt-IRL (Ziebart et al. 2008), we use it as a baseline method to compare our results on the benchmark tasks. Previously, both linear (Ziebart et al. 2008) (Ziebart 2010b) and non-linear (Wulfmeier, Ondruska, and Posner 2015) formulations of MaxEnt-IRL have been used to estimate the reward functions. Hence, we discuss results for both linear and non-linear parameterization of CCP-IRL. For the former, we focus on problems of navigation in a traditional Gridworld setting with stochastic dynamics, while for the latter we choose the Objectworld task as described in (Levine and Koltun 2013). For comparative analysis, we use both qualitative and quantitative results. For qualitative analysis, we directly compare the visualizations of the inferred reward functions for both CCP-IRL and MaxEnt-IRL. For quantitative comparison, we use negative log likelihood (NLL) (Kitani et al. 2012) and expected value difference (EVD) (Levine, Popovic, and Koltun 2011) as the evaluation criterion. NLL is a probabilistic comparison metric and evaluates the likelihood of a path under the predicted policy. For a policy (π), NLL is defined as, Y   N LL(π) = Eπ(a|s) − log π(at |st ) (16) t As another metric of success, similar to related works Gridworld: Evaluating Linear Rewards We use the Gridworld experiments to show the computational efficiency of CCP-IRL assuming linear parameterization. We use the Gridworld problem because the reward function is approximately linear. We test with two increasingly difficult settings in Gridworld i.e., Fixed Target and Macro Cells (described below) to show how CCP-IRL provides computational advantage across both tasks. Also, for the more complex Macro-cell task, we show how CCP-IRL requires consistent CCP estimates, which in turn depend on the amount of expert demonstrations available. Fixed Target Gridworld For our initial experiment we focus on the standard RL task of navigation in a N × N grid world. We show that CCP-IRL provides a significant computation advantage when compared to MaxEnt-IRL. Additionally, we also show that similar to MaxEnt-IRL, CCP-IRL is able to extract the underlying reward function across large state spaces. In this setting, the agent is required to move to a specific target location given some obstacles. The initial start location is randomly distributed through the grid. The agent gets a large positive reward at the target location. For states with obstacles, the agent gets a large negative reward. At all other states, the agent gets 0 reward. The agent can only move in four directions (North, South, East, West) i.e., no diagonal movement is allowed. To make the environment more challenging, we assume stochastic wind, which forces the agent to move to a random neighboring location with a certain probability, p = 0.3. For our feature representation, we use distance to the target location along with the state of each grid cell i.e., whether the grid cell contains an obstacle or not. First, we compare the EVD performance of our proposed CCP-IRL algorithm against the MaxEnt IRL baseline in Figure 1 (Right). As seen in the above plot, both algorithms converge to the expert behavior with similar amount of data. Hence our proposed CCP-IRL algorithm is correctly able to infer the underlying reward distribution. We now observe the computational gain provided by CCPIRL. The first three rows in Table 1 compare the amount of time between CCP-IRL and MaxEnt-IRL for increasing state spaces. Notice that CCP-IRL is atleast 2× faster compared to MaxEnt-IRL, for both small and large state spaces. This is expected given that we do not use backwards recursion to solve the MDP problem at every iteration. Next, we look at the convergence rate for both algorithms. This is important since CCP-IRL provides much larger computational advantage with increasing number of iterations. MaxEnt-20 MaxEnt-80 CCP-20 CCP-80 2.0 1.5 Expected Value Difference Negative Log Likelihood (Levine and Koltun 2013) (Wulfmeier, Ondruska, and Posner 2015), we use expected value difference (EVD). EVD measures the difference between the optimal and learned policy by comparing the value function obtained with each policy under the true reward distribution. Further, to verify the computational improvement using CCP-IRL, we observe the time taken by each algorithm as well as the number of iterations it takes for each algorithm to converge. We show that our algorithm is able to achieve similar qualitative and quantitative performance with much less computational time. 1.0 0.5 0 50 100 Iteration 150 200 70 MaxEnt CCP 60 50 40 30 20 10 0 0 50 100 Trajectories 150 200 Figure 1: Left: Log likelihood results for MaxEnt and CCP on fixed target with gridsize of 16 with 20 and 80 trajectories respectively. Right: Expected Value Difference results on fixed target with grid size 16. N 32 64 128 32 32 64 Cell Size 8 4 8 MaxEnt (sec) 584.31 1812.94 15062.24 635.63 584.30 3224.97 CCP (sec) 270.52 552.18 3119.20 266.18 283.81 1024.42 Speedup 2× 3× 5× 3× 2× 3× Table 1: Computation time (averaged over multiple runs) comparison between MaxEnt and CCP for gridworld settings. Each experiment was run for 50 iterations. Figure 1 (Left) shows the NLL values for both algorithms against increasing number of iterations. Notice that both algorithms converge to similar result with same number of iterations for different amount of input trajectories. This shows that both algorithms have a similar rate of convergence. We also compare the computation time for each algorithm against the discount factor (β) of the underlying MDP. By varying β we are able to vary the complexity of the original MDP since a large β value gives more weight to future actions and thus each solution of the value iteration DP takes longer. Figure 4 shows the computation time for both algorithms against different β values. As expected, we see an almost exponential rise in the computation time for MaxEntIRL while CCP-IRL shows a negligible time increase which indicates that CCP-IRL provides much larger gains for more complex MDP problems. Macro Cells We use the more complex macro-cell Gridworld environment (Abbeel and Ng 2004) to demonstrate how CCP-IRL’s performance depends on expert trajectories. As discussed above, CCP-IRL requires consistent CCP estimates for reward function estimation. Since CCP estimates are calculated from expert trajectories we observe how CCP-IRL’s performance depends on the amount of expert trajectories. In this setting, the N × N grid is divided into nonoverlapping square regions (macro-cells). Each region contains multiple grid cells and each cell in a region shares the same reward. Similar to (Abbeel and Ng 2004), for every region we select a positive reward r ∈ (0, 1) with probability of 0.1 and r = 0 with probability 0.9. This reward distribution leads to positive rewards in few macro cells which results in interesting policies to be learned and hence requires 1.6 1.4 1.2 1.0 0.8 0.6 0.4 0.2 0 20 40 60 80 100 Trajectories 120 140 160 12 1000 MaxEnt CCP 10 900 8 6 4 2 0 0 20 40 60 80 100 Trajectories 120 140 160 Figure 2: Results for gridworld of size 16 with macro-cells of size 2. Left: Minimum NLL results with varying number of trajectories. Right: Expected Value Difference results. For few trajectories CCP-IRL shows much larger variance as compared to MaxEnt-IRL. Time (in seconds) MaxEnt CCP 1.8 Expected Value Difference Negative Log Likelihood 2.0 800 MaxEnt CCP 700 600 500 400 300 200 0.5 0.6 0.7 0.8 Discount Factor 0.9 Figure 4: Computation time (in seconds and averaged over multiple runs) comparison between MaxEnt and CCP for Gridworld with gridsize of 32. Each experiment was run for 50 iterations. True Reward MaxEnt CCP Figure 3: Reward distribution for macro cells with gridsize 8 and macro cell size 2 using 10 trajectories. Dark - high reward, Light - low reward. more precise CCP estimates to match expert behavior. Since all the cells in the same region share the same reward, our feature representation is a one-hot encoding of the region that cell belongs to e.g., in a grid world of size N = 64 and macro cell of size 8 we have 64 regions and thus each state vector is of size 64. As before, we assume a stochastic wind with probability 0.3 and the agent can move only in four directions. We analyze the performance of both algorithms given different amounts of expert trajectories. Figure 2 compares the NLL and EVD results against increasing number of expert trajectories. As seen above, both algorithms show poor performance given very few trajectories (< 20 trajectories). However, with moderate number of trajectories MaxEnt-IRL approaches expert behavior while CCP-IRL is still comparatively worse. Finally, with sufficiently large number of trajectories (> 60) both algorithms converge to expert behavior. CCP-IRL’s poor performance with few expert demonstrations reflect its dependence on sufficient amount of input data. Since CCP estimates are calculated from input data CCP-IRL needs a sufficient (relatively larger than MaxEntIRL) amount of trajectories to get consistent CCP estimates. We also qualitatively compare the rewards inferred by both algorithms given few trajectories in Figure 3. Notice that the darker regions in the true reward are similarly darker for both algorithms. Thus, both algorithms are able to infer the general reward distribution. However, MaxEnt-IRL is able to match the true reward distribution at a much finer level (since less discrepancy compared to the true reward) and hence the underlying policy more closely as compared to Experiment Setting MaxEnt CCP Speedup Grid size: 16, C = 2 Grid size: 32, C = 2 1622.63 296.43 5× 9115.50 1580.22 6× Grid size: 16, C = 8 2535.38 545.95 5× Grid size: 32, C = 8 19445.66 4799.02 4× Table 2: Computation time (in seconds and averaged over multiple runs) comparison between MaxEnt and CCP for Objectworld. Each experiment was run for the same number of iterations with similar settings. CCP-IRL. Thus, given few input trajectories MaxEnt-IRL performs better than our proposed CCP-IRL algorithm. We verify the computation advantage for CCP-IRL across large state spaces (|S| ∈ {103 , 104 }) in Table 1. As seen before, CCP-IRL is atleast 2× faster than MaxEnt-IRL. Also, its computational efficiency increasing for larger state spaces. Objectworld: Evaluating Non-Linear Rewards We now look at CCP-IRL’s performance when the true reward function is a non-linear parameterization of the feature vector. For this, we use the Objectworld (Levine, Popovic, and Koltun 2011) environment since the reward function is a non-linear function of state features (Levine, Popovic, and Koltun 2011). Similar to related work (Wulfmeier, Ondruska, and Posner 2015), we use a Deep Neural Network (DNN) as the non-linear function approximator. As before, we verify both (1) the computational advantage provided by CCP-IRL (DeepCCP-IRL) and (2) the data requirement for CCP-IRL in the above scenario. The Objectworld environment consists of a grid of N × N states. At each state the agent can take 5 actions, including movement in 4 directions and staying in place. Spread through the grid are random objects, each with an inner and MaxEnt CCP 1.6 1.4 Expected Value Difference Negative Log Likelihood 1.8 1.2 1.0 0.8 0.6 0.4 0 20 40 60 80 Trajectories 100 10 MaxEnt CCP 8 6 4 2 True Reward 0 0 20 40 60 Trajectories 80 Figure 5: Results on ObjectWorld with gridsize of 16 and 2 colors. Left: NLL results on test trajectories. Right: Expected Value Difference results. 30000 MaxEnt CCP 12 10 8 6 4 2 0 0 20 40 60 80 100 Trajectories 120 140 MaxEnt CCP 25000 Time (in seconds) Expected Value Difference 14 160 20000 15000 10000 5000 0 0 1000 2000 3000 Iterations 4000 MaxEnt CCP 100 5000 Figure 6: Left: Results for transfer experiment using MaxEnt and CCP formulation on Objectworld with gridsize of 16 and 2 colors. Right: Time variance between MaxEnt-IRL and CCP-IRL with increasing number of iterations. As expected CCP-IRL shows little computation increase with larger number of iterations. outer color. Each of these colors is chosen from a set of C colors. The reward for each cell(state) is positive if the cell is within distance 3 of color 1 and distance 2 of color 2, negative if only within distance 3 of color 1 and zero in all other cases. For our feature vector we use a continuous set of values x ∈ R2C , where xi and xi+1 is the shortest distance from the state to the i’th inner and outer color respectively. Since the reward is only dependent on two colors, features for other colors act as distractors. We use DeepMaxEnt-IRL (Wulfmeier, Ondruska, and Posner 2015) as the baseline, using similar deep neural network architecture for both algorithms. Precisely, we use a 2-layer feed-forward network with rectified linear units. We use the Adam (Kingma and Ba 2014) optimizer with the initial learning rate set to 10−3 . We quantitatively analyze the performance of our proposed DeepCCP-IRL algorithm. Figure 5 compares the NLL and EVD results for both algorithms. Notice that as observed before, with few expert trajectories both algorithms perform poorly. However, DeepMaxEnt-IRL matches expert performance with moderate number of trajectories (≈ 20), while DeepCCP-IRL requires relatively large number of trajectories (≈ 40). This is expected since CCP-IRL requires larger number of expert trajectories to get consistent CCP estimates. Also, we qualitatively look at the inferred reward to verify how well the DNN is able to approximate the non-linear reward. Figure 7 plots the inferred rewards against the true Figure 7: Reward distribution for Objectworld with gridsize 8 using 30 trajectories and 5 colors. Dark - low reward, Light - high reward. We also plot the inner and outer color of each object. Pink - color 1 Orange - color 2, other colors are distractors. Figure best viewed in electronic version. reward function. Notice that both algorithms capture the nonlinearities in the underlying reward function and consequently match the expert behavior. Thus, a deep neural network suffices as a non-linear function approximator for CCP-IRL. We now analyze the computation gain in the non-linear case. Table 2 shows the computation time for different sized state spaces and different sized feature vectors. Notice that DeepCCP-IRL is almost 5× as fast as DeepMaxEnt-IRL across small and large state spaces. Thus we see that CCPIRL provides a much larger computation advantage for the non-linear case, which we believe is because the objectworld MDP problem is more complex than the above grid world experiments. This results in both algorithms requiring larger number of iterations until convergence which leads to a large computational increase for DeepMaxEnt-IRL as compared to DeepCCP-IRL. This computational increase with larger number of iterations is also shown in Figure 6 (Right). Notice that as the number of iterations increase, our proposed DeepCCP-IRL algorithms shows minor computational increase as compared to DeepMaxEnt-IRL. Thus, for significantly complex MDP problems which require large number of iterations our proposed CCP-IRL algorithm should require much less computation time compared to MaxEnt-IRL. Conclusion We have described an alternative framework for inverse reinforcement learning (IRL) problems that avoids value function iteration or backward induction. In IRL problems, the aim is to estimate the reward function from observed trajectories of a Markov decision process (MDP). We first analyze the decision problem and introduce an alternative representation of value functions due to (Hotz and Miller 1993). These representations allow us to express value functions in terms of empirically estimable objects from action-state data and the unknown parameters of the reward function. We then show that it is possible to estimate reward functions with few parametric restrictions. References Abbeel, P., and Ng, A. Y. 2004. Apprenticeship learning via inverse reinforcement learning. In Proceedings of the twenty-first international conference on Machine learning, 1. ACM. Aguirregabiria, V., and Mira, P. 2002. Swapping the nested fixed point algorithm: A class of estimators for discrete markov decision models. Econometrica 70(4):1519–1543. Arcidiacono, P., and Ellickson, P. B. 2011. Practical methods for estimation of dynamic discrete choice models. Annu. Rev. Econ. 3(1):363–394. Finn, C.; Levine, S.; and Abbeel, P. 2016. Guided cost learning: Deep inverse optimal control via policy optimization. In International Conference on Machine Learning, 49–58. Hotz, V. J., and Miller, R. A. 1993. Conditional choice probabilities and the estimation of dynamic models. Review of Economic Studies 60:497–529. Kingma, D., and Ba, J. 2014. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980. Kitani, K. M.; Ziebart, B. D.; Bagnell, J. A.; and Hebert, M. 2012. Activity forecasting. In European Conference on Computer Vision, 201–214. Springer. Levine, S., and Koltun, V. 2012. Continuous inverse optimal control with locally optimal examples. arXiv preprint arXiv:1206.4617. Levine, S., and Koltun, V. 2013. Guided Policy Search. Proceedings of the 30th International Conference on Machine Learning 28:1–9. Levine, S.; Popovic, Z.; and Koltun, V. 2011. Nonlinear inverse reinforcement learning with gaussian processes. In Advances in Neural Information Processing Systems, 19–27. Magnac, T., and Thesmar, D. 2002. Identifying dynamic discrete decision processes. Econometrica 70:801–816. Miller, R. A. 1984. Job matching and occupational choice. Journal of Political Economy 92(6):1086–1120. Ng, A., and Russell, S. 2000. Algorithms for inverse reinforcement learning. Proceedings of the Seventeenth International Conference on Machine Learning 0:663–670. Pakes, A. 1986. Patents as options: Some estimates of the value of holding european patent stocks. Econometrica 54(4):755–84. Pesendorfer, M., and Schmidt-dengler, P. 2008. Asymptotic Least Squares Estimators for Dynamic Games. Review of Economic Studies 901–928. Ratliff, N. D.; Bagnell, J. A.; and Zinkevich, M. A. 2006. Maximum margin planning. Proceedings of the 23rd International Conference on Machine Learning (ICML) 729–736. Rust, J. 1987. Optimal replacement of gmc bus engines: An empirical model of harold zurcher. Econometrica 55:999– 1033. Rust, J. 1988. Maximum likelihood estimation of discrete control processes. SIAM Journal on Control and Optimization 26(5):1006–1024. Su, C.-L., and Judd, K. L. 2012. Constrained optimization approaches to estimation of structural models. Econometrica 80(5):2213–2230. Wulfmeier, M.; Ondruska, P.; and Posner, I. 2015. Maximum entropy deep inverse reinforcement learning. arXiv preprint arXiv:1507.04888. Ziebart, B. D.; Maas, A. L.; Bagnell, J. A.; and Dey, A. K. 2008. Maximum entropy inverse reinforcement learning. In AAAI, volume 8, 1433–1438. Chicago, IL, USA. Ziebart, B. D. 2010a. Modeling purposeful adaptive behavior with the principle of maximum causal entropy. Ph.D. Dissertation, Carnegie Mellon University. Ziebart, B. D. 2010b. Modeling purposeful adaptive behavior with the principle of maximum causal entropy. Carnegie Mellon University.
2cs.AI
arXiv:1610.06427v1 [math.ST] 20 Oct 2016 On weighted optimality of experimental designs Samuel Rosa Faculty of Mathematics, Physics and Informatics, Comenius University, Bratislava, Slovakia January 18, 2018 Abstract When the experimental objective is expressed by a set of estimable functions, and any eigenvalue-based optimality criterion is selected, we prove the equivalence of the recently introduced weighted optimality and the ’standard’ optimality criteria for estimating this set of functions of interest. Also, given a weighted eigenvalue-based criterion, we construct a system of estimable functions, so that the optimality for estimating this system of functions is equivalent to the weighted optimality. This allows one to use the large body of existing theoretical and computational results for the standard optimality criteria for estimating a system of interest to derive theorems and numerical algorithms for the weighted optimality of experimental designs. Moreover, we extend the theory of weighted optimality so that it captures the experimental objective consisting of any system of estimable functions, which was not the case in the literature on weighted optimality so far. For any set of estimable functions, we propose a corresponding weight matrix of a simple form, and with a straightforward interpretation. Given a set of estimable functions with their corresponding weights, we show that it is useful to distinguish between the primary weights selected by the experimenters and the secondary weights implied by the weight matrix. 1 Introduction In a given experiment, certain parameters or functions of parameters may be of greater interest than others. Then, the experimental design should reflect this. In the optimal design theory, such objectives can be expressed using the weighted optimality criteria, developed by Morgan 1 and Wang [2010] and Morgan and Wang [2011]. These authors consider models with treatment effects in which various weights are placed on the particular treatments. They build a diagonal weight matrix, and propose a weighted information matrix that captures the given weights. However, Stallings and Morgan [2015] found the approach of Morgan and Wang too restrictive, and therefore extended the theory of the weighted optimality. They propose a weighted information matrix for any, generally non-diagonal, positive definite weight matrix. Such an approach allows one to capture situations, in which the experimental objective is to estimate a given set of estimable functions (possibly with assigned various weights). Although the weighted optimality criteria provide a meaningful approach of expressing the interest in a given set of linear estimable functions, such an objective can also be expressed directly, using the theory of optimality for estimating the given functions of interest (e.g., see Pukelsheim [2006]). Let us denote the system of functions of interest as QT τ , where Q is a given coefficient matrix and τ is the vector of the effects of interest. Then, the theory of optimality for QT τ makes use of the information matrix for QT τ , as opposed to the information matrix for the vector τ . The optimality for a system of interest is a well developed theory with a wide range of known results. Many of these results deal generally with the optimality criteria - notably the equivalence theorems (see Chapter 7 by Pukelsheim [2006]); and many more provide optimal designs for particular models, systems of estimable functions and optimality criteria. In blocking experiments, e.g., see Majumdar and Notz [1983] for comparing test treatment with a control, and Majumdar [1986] for comparing two sets of treatments; see Rosa and Harman [2016] for optimal designs in general models with treatment effects and nuisance effects. There is also a multitude of results on algorithms for constructing optimal (or efficient) designs for a system of functions of interest: e.g., rounding of optimal approximate designs (Chapter 12 by Pukelsheim [2006]), multiplicative algorithms (Yu [2010]), and mixed integer second order cone programming (Sagnol and Harman [2015]). In this paper, we build upon the theory presented by Stallings and Morgan [2015]. In Section 2, we compare the weighted optimality and the ’standard’ optimality for estimating a system of interest. We show that given a system of functions of interest QT τ , the corresponding weighted optimality and the optimality for QT τ are equivalent for any eigenvalue-based criterion. Furthermore, we note that the weights assigned to the functions QT τ can be expressed by appropriately rescaling these functions. Note that most of the well-known criteria are eigenvalue-based; e.g., the D-, A- and E-optimality all depend only on the positive eigenvalues of the information matrix. We also consider the situation, where a weight matrix W is selected, instead of a system of functions of interest. In such a case, we provide a method 2 for constructing a system of functions of interest QT τ for the given weight matrix, so that for any eigenvalue-based criterion the optimality for QT τ is equivalent to the weighted optimality given by W . When one considers a weighted optimality criterion, the provided equivalence with the optimality for a system of interest allows one to employ the tools of the extensive theory of the ’standard’ optimality for a system of interest, e.g., the equivalence theorems and the algorithms for computing optimal exact designs. Moreover, we extend the theory of the weighted optimality. The weight matrices corresponding to a system QT τ are defined by Stallings and Morgan [2015] only for systems that satisfy that rank(Q) is at least equal to the dimension of the set of all estimable functions. This, for instance, does not cover the case of c-optimality (see Pukelsheim [2006], Chapter 2). We propose to relax the definition of the weight matrix so that a weight matrix can be constructed for any system of estimable functions. Moreover, we define a weight matrix corresponding to a system QT τ , which is of a slightly simpler form than that by Stallings and Morgan [2015], although these two forms are equivalent with respect to the implied weighting of estimable functions. Finally, we note that it is advisable to differentiate between primary weights specified by the experimenters and secondary weights given by the weight matrix that corresponds to the system of interest QT τ . 1.1 Notation We define 1n and 0n as the column vectors of length n of all ones and zeroes, respectively. The symbol In denotes the identity matrix, and we define Jn := 1n 1Tn and 0m×n := 0m 0Tn . By diag(x1 , . . . , xn ) we denote the n × n diagonal matrix with x1 , . . . , xn on diagonal. The symbols Sn+ and Sn++ denote the sets of n × n non-negative definite matrices and positive n definite matrices, respectively. Given A ∈ S+ , we denote its ordered eigenvalues by λ1 (A) ≥ . . . ≥ λn (A). By C(A) and N (A) we denote the column space and the null space of the matrix A, respectively. Given a matrix A, the Moore-Penrose pseudoinverse of A is denoted by A+ , and A− is any generalized inverse of A. By A+1/2 we denote the matrix (A+ )1/2 . 1.2 The model Consider the model studied by Stallings and Morgan [2015]: y = X(ξ)τ + Lβ + ε, (1) where y = (y1 , . . . , yn )T is the response, τ = (τ1 , . . . , τv )T is the vector of the parameters of interest, β = (β1 , . . . , βm )T is the vector of nuisance parameters, and ε is the n × 1 vector of 3 uncorrelated errors with E(ε) = 0n and Var(ε) = σ 2 In . The (exact) design ξ determines the matrix X(ξ) that relates τ to y, and L is the matrix relating β to y, which is independent of the choice of the design ξ. Since the results in this paper do not depend on the variance of the errors, for simplicity we assume σ 2 = 1. The information matrix for τ is C(ξ) = X T (ξ)(I − PL )X(ξ), where PL = L(LT L)− LT is the matrix of the orthogonal projection on C(L). A function q T τ is estimable under a design ξ if and only if q ∈ C(C(ξ)). As in Stallings and Morgan [2015], we require for all competing designs to be able to estimate the same set of linear functions of the parameters q T τ . We define E as the estimation space, which is the set of all vectors q corresponding to these estimable functions q T τ . That is, all competing designs have the same C(C(ξ)), namely C(C(ξ)) = E. Often, the estimation space E is the entire Rv or the set of all vectors orthogonal to 1v , denoted by 1⊥ v . We denote the v × v matrix of the orthogonal projection on E by Pτ . A common example of model (1) is a model, where τ is the vector of treatment effects, and β are some nuisance effects. In this case, the estimation space is E = 1⊥ v , which represents the set of all treatment contrasts. We consider a system of s estimable functions QT τ , where Q is a v × s matrix of rank r, satisfying C(Q) ⊆ E; we denote the columns of Q as q1 , . . . , qs , and the elements of Q as Qij . We say that a design ξ is feasible for QT τ if QT τ is estimable under ξ. We say that the system QT τ is unscaled (or normalized) if kqi k = 1 for all i; otherwise, QT τ is said to be scaled. Furthermore, if r = s, then we say that the system QT τ is of full rank; otherwise, QT τ is said to be rank-deficient. Note that for a system QT τ to attain the full rank, it is necessary that s ≤ dim(E). If the interest in each of the functions in QT τ is not the same, we represent the various interest by weights b1 , . . . , bs of the functions q1T τ, . . . , qsT τ . We denote the matrix of weights of the functions of interest as B = diag(b1 , . . . , bs ). 1.3 Weighted optimality For now, let us consider the weighted optimality criteria, as defined by Stallings and Morgan [2015]. That is, we say that the weight matrix is any v × v positive definite matrix W . For a given W and any estimable function q T τ , the weight assigned to q T τ is (q T W −1 q)−1 and the T τ ). T τ ) = (q T W −1 q)−1 Var(qd corresponding weighted variance is VarW (qd Then, the weighted information matrix of a feasible design ξ (given a weight matrix W ) is defined as CW (ξ) = W −1/2 C(ξ)W −1/2 . Given an optimality criterion Φ, a design is Φoptimal with respect to W (or, in short, ΦW -optimal) if it maximizes ΦW (C(ξ)) := Φ(CW (ξ)). 4 Note that Stallings and Morgan [2015] consider optimality criteria that are to be minimized. The correspondence between the weighted variance and the weighted information matrix is represented by Lemma 1 by Stallings and Morgan [2015], which states that the weighted variance of a given estimable function q T τ is a convex combination of the inverses of the eigenvalues of CW (ξ). Two weight matrices W1 and W2 are said to be estimation equivalent if q T W1−1 q = cq T W2−1 q for all q ∈ E and for some constant c. Lemma 3 by Stallings and Morgan [2015] shows that W1 and W2 are estimation equivalent if and only if Pτ W1−1 Pτ = cPτ W2−1 Pτ for some constant c. When the objective of the experiment is to estimate a set of s normalized functions QT τ , where s is equal to the dimension of E and r = s, Stallings and Morgan [2015] propose a corresponding weight matrix WQ = I − Pτ + QQT , where Pτ is the orthogonal projector on E. The inverse of such a matrix is WQ−1 = I − Pτ + (QQT )+ , and WQ places weight 1 on each of the functions of interest qiT τ , i.e., (qiT WQ−1 qi )−1 = 1 for i = 1, . . . , s. In particular, it holds that QT WQ−1 Q = Is . If the interest in the functions q1T τ, . . . , qsT τ is represented by the weights b1 , . . . , bs , one can employ the weighted version of Q given by Q̃ := QB 1/2 . That 1/2 is, the interest bi in qiT τ is expressed by rescaling the function of interest using q̃i = bi qi , 1/2 so that kq̃i k = bi . Then, the corresponding weight matrix WQ̃ places weight bj on qjT τ , j = 1, . . . , s. When the normalized system of contrasts QT τ satisfies r = dim(E) and s > r (i.e., when we have ’too many’ functions of interest), the authors employ the same form of the corresponding weight matrix WQ as in the case r = s = dim(E). However, in general, such a matrix does not place equal weights on each of the functions qiT τ . That is not a desirable property, because these functions of interest should be assigned uniform weights. However, Stallings and Morgan [2015] show that the desired weights can be captured by the weighted A-optimality criterion, even with such a weight matrix. 2 Optimality for a system of interest Stallings and Morgan [2015] observed that the standard optimality criteria defined on the information matrices C(ξ) place equal emphasis on all normalized estimable functions, which is an evident limitation of such approach. Consequently, the weighted optimality criteria present a way of eliminating such limitations, because they allow for various emphases on the estimable functions. 5 However, this limitation of the standard optimality criteria arises primarily not because of the criteria considered, but rather it is due to the narrow definition of the information matrix C(ξ), which captures the information about exactly the vector τ . When the interest is in a set of s estimable functions QT τ , where r = s, this limitation can be completely circumvented by considering the well-established information matrix of a feasible design ξ for the system of interest QT τ (as opposed to the information matrix C(ξ) for the vector τ ): NQ (ξ) = (QT C − (ξ)Q)−1 , see Pukelsheim [2006]. Such an information matrix is proportional to the inverse of the variance matrix for the least-squares estimator of QT τ . Given a standard optimality criterion, a design is said to be Φ-optimal for the system of interest QT τ (or ΦQ -optimal) if it maximizes Φ(NQ (ξ)). In the second case in which Stallings and Morgan [2015] defined the matrix WQ , i.e., when s > r = dim(E), the information matrix for QT τ of the form (QT C − (ξ)Q)−1 is not well defined, as the inverse matrix does not exist. Instead of the inverse, one can consider the pseudo-inverse, resulting in the information matrix NQ (ξ) = (QT C − (ξ)Q)+ (2) for s > r (e.g., see Pukelsheim [2006]). Note that the form (2) encompasses both the cases s = r and s > r. Also note that the information matrix NQ (ξ) is well defined even for r < dim(E). We show that not only can the experimental objective of estimating a set of estimable functions QT τ be represented both by the corresponding weighted optimality as well as by the information matrix for QT τ ; these approaches are in fact equivalent for any criterion based only on the (non-negative) eigenvalues of the information matrix, as is proved in the following theorem. Note that the weighted optimality of Stallings and Morgan [2015] is built primarily for the eigenvalue-based optimality criteria, e.g., see Lemma 1 therein. Theorem 1. Let QT τ be a system of estimable functions that satisfies r = dim(E), and let ξ be a feasible design for QT τ . Then, the information matrix NQ (ξ) = (QT C − (ξ)Q)+ for QT τ and −1/2 the weighted information matrix CWQ (ξ) = WQ −1/2 C(ξ)WQ have the same non-zero eigenvalues, including multiplicities. , where WQ = I − Pτ + (QQT ), Proof. Let us denote C := C(ξ). In this proof, we will employ the facts that the non-zero eigenvalues of AB are identical to the eigenvalues of BA if BA is defined, and that the non-zero eigenvalues of AAT are identical to the eigenvalues of AT A, see 6.54 by Seber [2008]. 6 The eigenvalues of CWQ (ξ) are identical to the eigenvalues of WQ−1 C, which can be expressed as (I − Pτ + (QQT )+ )C = (QQT )+ C, where the equality follows from C(C) ⊆ E. Therefore, the non-zero eigenvalues of CWQ (ξ) are inverse to the eigenvalues of ((QQT )+ C)+ . Theorem 2 of Greville [1966] implies that for two symmetric matrices A and B of the same size, the formula (AB)+ = B + A+ holds if and only if A+ ABB T and AT ABB + are symmetric. Because r = dim(E) and C(Q) ⊆ C(C) = E, it follows that C(Q) = C(C) = E. Moreover, C((QQT )+ ) = C(QQT ) = C(Q) = C(C) = C(C + ), which yields that there exist matrices Z and V , such that C = QQT Z and (QQT )+ = C + V . Since both (QQT )+ and C + are symmetric, it follows that (QQT )+ = V T C + . By setting A = (QQT )+ and B = C in Theorem 2 of Greville [1966], we obtain A+ ABB T = QQT (QQT )+ CC T = QQT (QQT )+ QQT ZC T = CC T and AT ABB + = (QQT )+ (QQT )+ CC + = (QQT )+ V T C + CC + = (QQT )+ (QQT )+ , which are both evidently symmetric. Therefore, the non-zero eigenvalues of CWQ (ξ) are inverse to the eigenvalues of C + QQT , which has the same non-zero eigenvalues as QT C + Q. Thus, the matrix CWQ (ξ) has the same non-zero eigenvalues as (QT C + Q)+ = NQ (ξ). The construction of and the relationship between the weighted optimality and the optimality for QT τ is depicted in Figure 1. The condition r = dim(E) in Theorem 1 is necessary for the weight matrix WQ (as defined by Stallings and Morgan [2015]) to exist. Unlike the weighted information matrix CQ , the information matrix for QT τ allows one to consider also the case in which r < dim(E). In Sections 3 and 4, we will propose a weight matrix that captures also r < dim(E). The coefficient matrix Q in Theorem 1 can be either scaled or unscaled. Therefore, even when considering a system of contrasts QT τ with non-uniform weights bi > 0, i = 1, . . . , s, by Theorem 1, such an objective can be captured by the information matrix for some system of estimable functions. Namely, such a weighting can be accomplished by employing the matrix NQ̃ for the weighted system of estimable functions Q̃T τ = B 1/2 QT τ . In other words, the weight placed on a given estimable function qiT τ can be expressed by appropriately rescaling 1/2 the function to bi qiT τ . An additional evidence, besides the results mentioned in Introduction, that the theory of optimality for QT τ is well developed is, e.g., the fact that Theorem 2 by Stallings and Morgan [2015] is a corollary of Corollary 8.8 by Pukelsheim [2006] in light of Theorem 1. Moreover, the optimality for QT τ eliminates the need for the intermediary step of constructing the weight 7 QT τ ; weights bi , i = 1, . . . , s rescaling (0) 1/2 Q̃T τ , q̃i = bi qi optimality for Q̃T τ (A1) (B1) weighted optimality WQ̃ = I − Pτ + Q̃Q̃T (B2) CWQ̃ (ξ) = −1/2 −1/2 WQ̃ C(ξ)WQ̃ NQ̃ (ξ) = (Q̃T C − (ξ)Q̃)+ (A2) Φ(NQ̃ (ξ)) (B3) equality Φ(CWQ̃ (ξ)) Figure 1: Constructing optimality criteria. The system of estimable functions QT τ with weights bi is rescaled in step (0). Suppose that ξ is a feasible design. The weighted optimality of Stallings and Morgan [2015] is obtained by constructing the weight matrix WQ̃ (B1), then the weighted information matrix CWQ̃ (B2), and finally, applying the optimality criterion to the weighted information matrix (B3). Alternatively, the optimality for the given weighted system is obtained by constructing the information matrix for Q̃T τ (A1) and applying the optimality criterion to this information matrix (A2). Theorem 1 shows the equivalence of these two approaches, i.e., that Φ(NQ (ξ)) is equal to Φ(CW̃ (ξ)) for any eigenvalue-based criterion Φ. matrix WQ from a given system of estimable functions; instead, the matrix NQ (ξ) allows one to consider the system of interest QT τ directly, see Figure 1. We have obtained that when the experimental objective is to estimate a system of estimable functions QT τ with given weights, then such an objective can be equivalently expressed directly by the information matrix for QT τ , instead of constructing the weight matrix and then considering the weighted optimality. However, one may specify the weight matrix (as in Morgan and Wang [2010]), instead of considering a set of weighted estimable functions. This brings up an inverse problem: can a system of estimable functions that corresponds to the pre-specified weight matrix be constructed? We provide a positive answer to this question. First, let us define the v × v matrix R := (Pτ W −1 Pτ )+1/2 . Such a matrix satisfies C(R) = E, 8 1 RRT = R2 = (Pτ W −1 Pτ )+ , and RT τ = Rτ is the sought system of estimable functions. v Theorem 2. Let W ∈ S++ be a weight matrix, let R = (Pτ W −1 Pτ )+1/2 . Then, given a design ξ that is feasible for Rτ , the weighted information matrix CW (ξ) has the same eigenvalues (including multiplicities) as the information matrix NR (ξ) for Rτ . Proof. In this proof, we employ the same techniques as in the proof of Theorem 1. Let us denote C := C(ξ) and W2 := Pτ W −1 Pτ . The eigenvalues of CW (ξ) are identical to the eigenvalues of W −1 C = W −1 Pτ CPτ , which are in turn identical to the eigenvalues of Pτ W −1 Pτ C = W2 C. The non-zero eigenvalues of W2 C are inverse to the non-zero eigenvalues of (W2 C)+ . Note that C(W2+ ) = C(W2 ) = E = C(C) = C(C + ). Therefore, there exist some matrices Z and H, such that W2 = C + Z and C = W2+ H. Transposing the former equation yields W2 = Z T C + . Let us employ Theorem 2 by Greville [1966] for A = W2 and B = C. Then, AT ABB + = W2 W2 CC + = W2 Z T C + CC + = W2 Z T C + = W22 and A+ ABB T = W2+ W2 CC = W2+ W2 W2+ HC = W2+ HC = C 2 , which are both symmetric. Thus, (W2 C)+ = C + W2+ = C + RR. The eigenvalues of C + RR are identical to the eigenvalues of RC + R, which are in turn inverse to the eigenvalues of (RC + R)+ = NR (ξ). This shows that the non-zero eigenvalues of CW (ξ) and NR (ξ) are identical. Moreover, both NR (ξ) and CW (ξ) are v × v matrices, thus they even have the same multiplicity of the zero eigenvalue. By Theorem 2, weighted optimality with respect to any eigenvalue-based criterion can be transformed to optimality for Rτ ; and thus, already developed algorithms for optimality for estimating a system of estimable functions can be employed. Figure 2 illustrates the construction of the weighted optimality criterion for a given W and of the optimality criterion for the corresponding system Rτ . 3 Extending the definition of the weight matrix When dim(E) < v, one needs not weight all the functions with coefficients in Rv ; e.g., in a model with treatment effects and nuisance effects, there is no point in weighting functions other than the treatment contrasts. Moreover, the experimenters may wish to assign non-zero weights only to some subset of the estimable functions. Then, we propose to express the set 9 W ∈ Sv++ weighted optimality (A1) (B1) optimality for RT τ CW (ξ) = W −1/2 C(ξ)W −1/2 R = (Pτ W −1 Pτ )+1/2 (B2) NR (ξ) = (RC − (ξ)R)+ (B3) (A2) Φ(CW (ξ)) equality Φ(NR (ξ)) Figure 2: Constructing optimality criteria for a given weight matrix. Suppose that ξ is a feasible design. The weighted optimality is obtained by constructing the weighted information matrix CW (ξ) (A1) and then applying the optimality criterion to the weighted information matrix (A2). Alternatively, the optimality for a system of estimable functions is obtained by constructing the sought system Rτ (B1), constructing the information matrix for Rτ (B2) and then applying the optimality criterion to this information matrix (B3). Theorem 2 shows the equivalence of these two approaches, i.e., that Φ(CW (ξ)) is equal to Φ(NR (ξ)) for any eigenvalue-based criterion Φ. of all coefficient vectors of functions that are to be weighted using C(W ). In particular, we require only for the functions q T τ with q ∈ C(W ) to be weighted. Therefore, we propose that the weight matrices need not be non-singular; in fact, since C(W ) represents the set of functions that are to be weighted, ranks of the proposed weight matrices are equal to the dimensions of the sets of the considered coefficient vectors q. For example, in a model with treatment and nuisance effects, it always holds that C(W ) ⊆ 1⊥ v and thus the proposed weight matrix satisfies rank(W ) ≤ v − 1 in such a model. Clearly, for singular W , the assigned weights cannot be given by (q T W −1 q)−1 . A natural relaxation of this formula is (q T W − q)−1 . Then, given a weight matrix W and a coefficient vector q ∈ C(W ), we define the weight of q T τ as (q T W − q)−1 ; if q 6∈ C(W ), the weight of q T τ is zero. v Definition 1. (i) The matrix W is a weight matrix if W ∈ S+ and C(W ) ⊆ E. (ii) Let W be a weight matrix and let q ∈ C(W ). Then, the weighted variance of q T τ is T τ ) = (q T W − q)−1 Var(qd T τ ). VarW (qd Note that the condition q ∈ C(W ) ensures that the weight of q T τ does not depend on 10 1 the choice of the generalized inverse W − . Moreover, if q ∈ C(W ), then q = W h for some h ∈ Rv ; thus q T W − q = hT W h, which is equal to zero if and only if h ∈ N (W ), i.e., when q = W h = 0v . It follows that W places zero weight on an estimable function that satisfies q ∈ C(W ) if and only if q = 0v . Following Definition 1, we must appropriately define the weighted information matrix, as the definition CW (ξ) = W −1/2 C(ξ)W −1/2 is not feasible for singular W . Given a weight maT trix W , we denote its spectral decomposition by W = SW ΛW SW , where ΛW = diag(λ1 (W ), . . . , λv (W )) and SW is a v × v orthogonal matrix. We denote the rank of W by d. Then, if d < v, we may also write W = F DF T , where D = diag(λ1 (W ), . . . , λd (W )) is a d × d matrix of the positive eigenvalues of W , and the v × d matrix F contains the first d columns of SW . Then, W can T , where KW = F D1/2 is a v × d matrix of rank d. be expressed as W = KW KW Definition 2. (i) Let W be a weight matrix and let ξ be a design that satisfies C(W ) ⊆ C(C(ξ)). Then, the weighted information matrix of ξ is T CW (ξ) = (KW C − (ξ)KW )−1 , where KW is defined in the previous paragraph. (ii) Let Φ be an optimality criterion. Then, a design is Φ-optimal with respect to W , or ΦW -optimal in short, if it maximizes Φ(CW (ξ)). The condition C(W ) ⊆ C(C(ξ)) ensures that the functions with coefficient vectors q ∈ C(W ) that are to be weighted are actually estimable under ξ, i.e., q ∈ C(C(ξ)). The v × d T matrix KW in Definition 2 satisfies KW KW = W , which indicates that it is a quasi-square root of W , with the number of columns adjusted to correspond to its rank; compare to CW (ξ) = W −1/2 C(ξ)W −1/2 given by Stallings and Morgan [2015]. Note that both the matrices KW and C(ξ) are of rank d, and C(KW ) ⊆ C(C(ξ)); thus, the weighted information matrix CW (ξ) is well-defined, and is of full rank. We remark that the weighted information matrix CW (ξ) coincides with the information T matrix NK (ξ) for estimating KW τ . Therefore, Definition 2 in fact consists of finding a set of estimable functions of full rank corresponding to W and then calculating the information matrix for the obtained set. Similarly to Stallings and Morgan [2015], we show that the proposed weighted information matrix is relevant with respect to the weighted variances. Proposition 1. Let W be a weight matrix of rank d, let q ∈ C(W ) and let ξ be a design that T τ under ξ is a convex combination of is feasible for q T τ . Then, the weighted variance of qd −1 λ−1 1 (CW (ξ)), . . . , λd (CW (ξ)). 11 T Proof. Since W = KW KW , we have C(W ) = C(KW ) and thus q ∈ C(W ) = C(KW ) yields q = KW h for some h ∈ Rd . Therefore, T τ ) = q T C − (ξ)q = hT C −1 (ξ)h = hT U Λ−1 U T h = Var(qd W d X gi2 λ−1 i (CW (ξ)), i=1 where U ΛU T is the spectral decomposition of CW (ξ), and g := U T h. Then, T T T T T − T h U U h = h h. The weight of q τ is q W q = h T T − KW (KW KW ) K T T − KW (KW KW ) KW h 2 i gi P = T = h h, because is a symmetric idempotent matrix of full rank, i.e., Id . It follows that T τ ) = (hT h)−1 VarW (qd r X gi2 λ−1 i (CW (ξ)) = i=1 r X gi2 −1 λ (CW (ξ)). gT g i i=1 Analogously to Stallings and Morgan [2015], we say that two weight matrices W1 and W2 that satisfy C(W1 ) = C(W2 ) =: S are estimation equivalent if there exists c > 0 such that q T W1− q = cq T W2− q for all q ∈ S. Proposition 2. Let W1 and W2 be weight matrices satisfying C(W1 ) = C(W2 ) =: S. Then, W1 and W2 are estimation equivalent if and only if PS W1− PS = cPS W2− PS for some constant c > 0, where PS is the orthogonal projector on S. Proof. The proof is analogous to the proof of Lemma 3 by Stallings and Morgan [2015]. Let W1 and W2 be estimation equivalent. Let us denote qi as i-th column of PS . Then, qi ∈ S and thus qiT W1− qi = cqiT W2− qi , which shows that the diagonal elements of PS Wk− PS satisfy the desired equation. Now, let qj be the j-th column of PS , j 6= i, and let q := qi + qj ∈ S. Then, q T W1− q = cq T W2− q, which yields qiT W1− qi + qjT W1− qj + 2qiT W1− qj = cqiT W2− qi + cqjT W2− qj + 2cqiT W2− qj , and thus qiT W1− qj = cqiT W2− qj , which shows the desired result also for non-diagonal elements. Conversely, let the weight matrices satisfy PS W1− PS = PS W2− PS and let q ∈ S. Then, PS q = q and thus q T W1− q = q T PS W1− PS q = cq T PS W2− PS q = cq T W2− q. Note that because C(PS ) = C(W1 ) = C(W2 ), the expressions PS W1− PS and PS W2− PS do not depend on the choice of W1− and W2− , respectively. Furthermore, if rank(Wi ) = dim(E), i = 1, 2, then we have S = E and thus PS W1− PS = cPS W2− PS becomes Pτ W1− Pτ = cPτ W2− Pτ , cf. Lemma 3 by Stallings and Morgan [2015]. 12 4 Weights for any set of estimable functions 4.1 System of a lesser dimension Consider the case of r < dim(E), i.e., the case in which the coefficient vectors q1 , . . . , qs do not span the entire estimation space. The simplest example of such a system of contrasts is a single estimable function QT τ = q1T τ , which represents c-optimality (where c = q1 ). As already noted, the experimental settings satisfying r < dim(E) are not covered by Stallings and Morgan [2015]. In general, the matrix WQ = I − Pτ + QQT is not of full rank in such a case; and thus WQ−1 , which is needed for the actual weighting, does not exist. The approach of weighting any estimable function q T τ by (q T W −1 q)−1 may not be necessary if r < dim(E), as shown in the following example, which aims to demonstrate this in a simple setting. Example 1. Consider a simple case of model (1), in which τ is the vector of treatment effects and β represents only the constant term, resulting in: yi = µ + τξ(i) + εi , i = 1, . . . , n, (3) where µ is the overall mean, and ξ(i) ∈ {1, . . . , v} is the treatment chosen for the i-th trial. T The estimation space is E = 1⊥ v , which represents the set of all treatment contrasts q τ . Suppose that v = 4 and that we aim to compare only τ2 and τ1 ; thus, we have QT τ = √ q1T τ = (τ2 − τ1 )/ 2. Clearly, such a system of contrasts does not place any weight on τ3 or τ4 . Therefore, any matrix of treatment weights corresponding to QT τ should not place any weight on any q T τ , such that q3 6= 0 or q4 6= 0. √ Now, consider a less extreme case. Suppose that Q = (q1 , q2 ), where q2T = (1, 1, 1, −3)/ 12, √ and let q3T = (1, 1, −2, 0)/ 6. Then, the coefficient vector q3 cannot be constructed from Q, i.e., q3 is not a linear combination of q1 and q2 ; in fact, q3 is orthogonal to both of them. Then, √ q3T τ need not inherit any of the weight assigned to q1T τ and q2T τ ; e.g., unlike (τ3 − τ4 )/ 2, which can clearly be constructed as a linear combination of q1T τ and q2T τ . k For any system QT τ , we propose to weight only the estimable functions that can be constructed from the functions of primary interest. Formally, one weights only q T τ , such that q can be expressed as a linear combination of functions of primary interest, i.e., only if q ∈ C(Q). We note that the condition q ∈ C(Q) covers the original condition q ∈ E, because C(Q) ⊆ E since the original functions in QT τ need to be estimable too. In fact, the condition q ∈ C(Q) reduces to q ∈ E when r = dim(E), because C(Q) = E then. That is a rather meaningful condition, as there is no point in assigning weights to non-estimable functions. 13 4.2 Corresponding weight matrix The definition of the weight matrix presented in Section 3 allows us to provide the following weight matrix corresponding to any system of interest QT τ : For an arbitrary system of estimable functions QT τ (i.e., for any number of functions s ≥ 1 of any achievable rank r ≤ min{s, dim(E)}), we define the unscaled weight matrix WQ = QQT . If the particular functions of interest are assigned weights b1 , . . . , bs , then we simply consider the scaled system of functions of interest Q̃T τ = B 1/2 QT τ , resulting in WQ̃ = QBQT . Definition 3. Let QT τ be a system of estimable functions with weights b1 , . . . , bs . Then, the corresponding unscaled weight matrix is WQ = QQT and the scaled weight matrix is WQ̃ = QBQT , where Q̃ = QB 1/2 . When r = dim(E), the term I − Pτ ensures the non-singularity of the weight matrix I − Pτ + QQT . However, the relaxation of the non-singularity condition of the weight matrices in this paper eliminates the need for the ’regularizing term’ I − Pτ . Therefore, we obtain the simple form WQ = QQT . In particular, when E = Rv and r = v, then Pτ = I and thus the matrices I − Pτ + QQT and QQT coincide. On the other hand, when E = 1⊥ v and r = v − 1, the matrices do not coincide, because the weight matrix of Stallings and Morgan [2015] is non-singular, whereas the weight matrix defined here is of rank v − 1, as the set of estimable functions has only v − 1 ’degrees of freedom’. The following proposition shows that the weight matrix proposed here is equivalent to the weight matrix considered by Stallings and Morgan [2015], with respect to the implied weights of the estimable functions, when the latter is defined (i.e., when r = dim(E)). Therefore, we obtain a weight matrix W = QQT , which is equivalent to the weight matrix W = I−Pτ +QQT , but is of a simpler form. Proposition 3. Let QT τ be a system of functions of interest, such that r = dim(E). Then, the weight matrices W1 = QQT and W2 = (I − Pτ ) + QQT are estimation equivalent. That is, q T W1− q = q T W2−1 q for any q ∈ E. Proof. Recall that W2−1 = (I −Pτ )+(QQT )+ . Since r = dim(E), the matrix PS in Proposition 2 becomes Pτ and thus Pτ W2− Pτ = Pτ (QQT )+ Pτ = Pτ W1− Pτ , where the first equality follows from W2− = W2−1 ; and the expression Pτ (QQT )− Pτ does not depend on the choice of (QQT )− , yielding the last equality. Then, the estimation equivalence follows from Proposition 2. 14 Similarly as in Theorem 1, the weighting given by WQ = QQT is equivalent to directly considering the information matrix NQ , for any eigenvalue-based criterion. Theorem 3. Let QT τ be a system of estimable functions and let ξ be a feasible design for QT τ . Then, the information matrix NQ (ξ) for QT τ and the weighted information matrix T CWQ (ξ) = (KW C − (ξ)KWQ )−1 have the same non-zero eigenvalues, including multiplicities. Q Proof. The non-zero eigenvalues of the information matrix NQ (ξ) = (QT C − (ξ)Q)+ are inverse to the eigenvalues of the matrix QT C − (ξ)Q. The matrix QT C − (ξ)Q can be expressed as QT C − (ξ)Q = (C +1/2 Q)T (C +1/2 Q), which shows that it has the same non-zero eigenvalues T as the matrix (C +1/2 Q)(C +1/2 Q)T = C +1/2 QQT C +1/2 . Because QQT = WQ = KWQ KW , Q T T we have C +1/2 QQT C +1/2 = C +1/2 KWQ KW C +1/2 ; and C +1/2 KWQ KW C +1/2 has the same Q Q T non-zero eigenvalues as KW C + KWQ . Observing that the non-zero eigenvalues of the matrix Q T KW C + KWQ are inverse to the non-zero eigenvalues of CWQ (ξ) completes the proof. Q Let W be a weight matrix. Then, a system of estimable functions that corresponds to W can be constructed employing the matrix W 1/2 , similarly to Theorem 2. Theorem 4. Let W be a weight matrix. Then, the matrix W corresponds to the system of estimable functions W 1/2 τ . Moreover, given a design ξ that is feasible for W 1/2 τ , the weighted information matrix CW (ξ) has the same eigenvalues (including multiplicities) as the information matrix NW 1/2 (ξ) for W 1/2 τ . Proof. The system W 1/2 τ is estimable, because C(W 1/2 ) = C(W ) ⊆ E. Because W 1/2 satisfies W 1/2 (W 1/2 )T = W , the weight matrix W corresponds to the system W 1/2 τ . Then, Theorem 3 yields the identity of the non-zero eigenvalues. Moreover, both CW (ξ) and NW 1/2 (ξ) are v × v matrices, which yields the same multiplicity of the zero eigenvalue. A proper weight matrix WQ should place equal weight on each of the normalized functions qiT τ . In the following proposition, we show that this is satisfied for the proposed WQ as long as the coefficient vectors q1 , . . . , qs are linearly independent, i.e., as long as rank(Q) = s. Proposition 4. Let QT τ be a full-rank system of normalized estimable functions. Then, QT WQ− Q = Is . If b1 , . . . , bs are the weights assigned to q1T τ, . . . , qsT τ , respectively, then QT WQ̃− Q = B −1 , where Q̃ = QB 1/2 . Proof. We have QT WQ− Q = QT (QQT )− Q = Is , because QT (QQT )− Q is a symmetric idempotent matrix of full rank, i.e., Is . The second statement follows from the analogous observation that Q̃T (Q̃Q̃T )− Q̃ = Is , which yields B 1/2 QT WQ̃− QB 1/2 = Is . 15 Clearly, when the functions in the system QT τ are not normalized, the weight of qi is kqi k2 , because it can be expressed as qi = kqi kq¯i , where q¯i is unscaled. When the functions q1 , . . . , qs are not linearly independent, the matrix WQ does not place equal weights on all of them (and neither does the matrix I − Pτ + QQT , as noted in Section 1.3). We will elaborate on this in Section 6. The condition that a proper weight matrix must weight all the unscaled functions of interest equally (given B = Is ) does not uniquely define a weight matrix, as we have seen for W1 = QQT and W2 = I − Pτ + QQT . However, such matrices need not even be estimation equivalent. An extreme case is the matrix W = Iv − Jv /v, which satisfies W + = W and T T q T W − q = 1 for any q ∈ E as long as E = 1⊥ v . Clearly, q (Iv − Jv /v)q = q q = 1, for any normalized q. Obviously, such a weight matrix does not provide any information about the considered set of estimable functions. Even when we restrict ourselves to the non-singular matrices, as in Stallings and Morgan [2015], the condition qiT W −1 qi = 1 for all i = 1, . . . , s, does not uniquely specify a weight matrix, as is shown in the following example. Example 2. Consider the model (3) with v = 3 and suppose that the objective is to compare the test treatments 2 and 3 with the control (the first treatment). That is, s = 2, q1 = √ √ (−1, 1, 0)T / 2 and q2 = (−1, 0, 1)T / 2. Let     2 2 2 3/2 −1/2 −1/2     −1   W1 =  0   with W1 = 2 4 2 −1/2 1/2 2 2 4 −1/2 0 1/2 and   2 2 2    −1   1/3  with W2 = 2 4 1 . 2 1 4 2/3 √ Then, QT W1−1 Q = QT W2−1 Q = I2 . Consider q = (0, −1, 1)T / 2. Then, (q T W1−1 q)−1 = 1/2  5/2 −1   W2 =  −1 2/3 −1 1/3 −1  and (q T W2−1 q)−1 = 1/3, which shows that W1 and W2 are not estimation equivalent. We have found two positive definite weight matrices that assign the required weights to the given functions, yet they assign different weights to other estimable functions. k Therefore, it is crucial that the proposed weight matrix, WQ = QQT , has a meaningful interpretation with respect to the system QT τ , other than assigning equal weights to each of the functions in QT τ . Theorems 1 and 3 state that the eigenvalue-based weighted optimality criteria with the weight matrices I − Pτ + QQT and QQT are equivalent to the optimality 16 with respect to the well-established information matrix for QT τ . This shows that the weight matrix proposed by Stallings and Morgan [2015] as well as the weight matrix proposed here are indeed relevant when the objective is to estimate QT τ . Lemma 1 by Stallings and Morgan [2015] and Proposition 1 here show the relevance of the weight matrices with respect to the weighted variances. Furthermore, in Section 4.3, we provide a straightforward interpretation of the elements of WQ = QQT , which indicates the relevance of the proposed matrix. 4.3 Elements of the weight matrix Let us denote the rows of Q by q∗1 , . . . , q∗v ; note that q∗i are row vectors. Then, the elements of WQ and WQ̃ satisfy T WQ (i, j) = q∗i q∗j = s X T WQ̃ (i, j) = q̃∗i q̃∗j = Qik Qjk , k=1 s X bk Qik Qjk i, j = 1, . . . , v, k=1 where q̃∗1 , . . . , q̃∗v are the rows of Q̃ = QB 1/2 . Such a form has a straightforward interpretation. The i-th diagonal element of WQ indeed represents the weight of the i-th parameter of interest: it is the sum of squares of all the coefficients for the i-th parameter across all functions of interest q1T τ, . . . , qsT τ . The element on the position (i, j), i 6= j, represents the amount of interest in the comparison of the i-th and j-th effects, as it is the sum of all products of the coefficients for the i-th and the j-th parameters across all functions of interest. High negative values of WQ (i, j) suggest a significant interest in the actual comparison, e.g., τi − τj ; high positive values suggest a significant interest in their combined effect, e.g., τi + τj . For the scaled version WQ̃ , the coefficients in each function qiT τ are multiplied by the 1/2 square of the corresponding weight bi first, and only then the sums of squares or products are calculated - thus assigning the i-th function the relative weight bi , i = 1, . . . , s. In the following example, we demonstrate the previous observations. Example 3. Consider model (3) with the experimental objective as in Example 2. Then, the matrix WQ is  WQ = QQT = 2 1 −1 2 −1 −1 1 0  −1  0 . 1 Disregarding the common factor 1/2, the weight of the first treatment is 2, because it is present in QT τ two times, whereas the other two treatments have analogously weight 1. Since the second and the third treatment cannot be found in the same contrast, the weight assigned to their comparison is zero; similarly, the negative ’weight’ −1 represents amount of interest in comparing the effects of the first and of the second (third) treatments. 17 √ Now, suppose that the contrast (τ2 − τ1 )/ 2 still has the weight b1 = 1, but the second √ treatment comparison (τ2 − τ1 )/ 2 is given an increased weight b2 = 2. Then, each element √ of the second contrast is multiplied by 2, resulting in   3 −1 −2  1 WQ̃ = Q̃Q̃T =  −1 1 0 , 2 −2 0 2 which places more weight on the first and the second treatment, and on their comparison, as it should, because b2 = 2 represents greater interest in comparing the first and the third k treatment. 5 E- and A-optimality Now that we have introduced the concept of the weight matrix corresponding to a system of estimable functions, we can provide the interpretation of the selected weighted optimality criteria for the general weight matrix, not necessarily implied by a system of estimable functions QT τ . In particular, we provide interpretations of the weighted criteria of E-optimality and A-optimality in terms of the weighted variances of the estimable functions, similar (except Proposition 6) to those by Stallings and Morgan [2015]. The value of the weighted E-optimality criterion, or EW -optimality criterion in short, is ΦEW (ξ) = λmin (CW (ξ)). Proposition 5. Let ξ ∈ Ξ and let W be a weight matrix. Then, the inverse of the value of EW -optimality is equal to the largest weighted variance over all q T τ , such that q ∈ C(W ). Proof. We have T λmin (CW (ξ)) = (λmax (KW C − (ξ)KW ))−1 =  max x∈Rd T C − (ξ)KW x −1 xT K W . xT x The largest weighted variance over all q T τ , such that q ∈ C(W ), is T q T C − (ξ)q z T K T C − (ξ)KW z z T KW C − (ξ)KW z = max T WT − = max , T − zT z q∈C(W ) q W q z∈Rd z KW W KW z z∈Rd max where the first equality follows from the fact that C(W ) = C(KW ), and thus for any q ∈ C(W ) T T T − there exists z ∈ Rd , such that q = KW z. Since W = KW KW , we have KW (KW KW ) KW = Id , as in the proof of Proposition 1, which yields the second equality. 18 From Proposition 5 it follows that any EW -optimal design minimizes the largest weighted variance over all q T τ , such that q ∈ C(W ). The value of the weighted A-optimality criterion, or AW -optimality criterion in short, is −1 T ΦAW (ξ) = d(tr(CW (ξ)))−1 = d(tr(KW C − (ξ)KW ))−1 , see Chapter 6 by Pukelsheim [2006]. Proposition 6. Let ξ ∈ Ξ and let W be a weight matrix. Then, the inverse of the value of AW -optimality is equal to the average variance of any system of d estimable functions QT τ that satisfy WQ = W . T Proof. We have (ΦAW (ξ))−1 = tr(KW C − (ξ)KW )/d. Let QT τ be a system of d estimable functions, such that QQT = W . Then, the average weighted variance for q1T τ, . . . , qdT τ is d 1 X T − −1 T − T (q W qi ) Var(qd i τ ) = tr(DQ C (ξ)Q)/d, d i=1 i where D = diag((q1T W − q1 )−1 , . . . , (qdT W − qd )−1 ). Moreover, QT W − Q = QT (QQT )− Q = Id , as in the proof of Proposition 1. Thus, D = Id and the average weighted variance is equal to tr(QT C − (ξ)Q)/d. T From QQT = KW KW follows that C(Q) = C(QQT ) = C(KW ); therefore, there exists T T a d × d matrix Z, such that Q = KZ. Then, KW KW = QQT = KW ZZ T KW . By pre- T T T and KW , respectively, by KW = KW ZZ T KW and post-multiplying the equation KW KW T T T T KW . Because KW is of full column rank, the KW ZZ T KW KW = KW KW KW we obtain KW T matrix KW KW is non-singular, which yields ZZ T = Id . Therefore, the average weighted variance is equal to T T T tr(Z T KW C − (ξ)KW Z)/d = tr(KW C − (ξ)KW ZZ T )/d = tr(KW C − (ξ)KW )/d = (ΦAW (ξ))−1 . In particular, from Proposition 6 it follows that the AW -optimal design minimizes the T average variance for KW τ. In the following proposition, we also provide the interpretation of AW -optimality analogous to that by Stallings and Morgan [2015]. We say that two estimable functions q1T τ and q2T τ are orthogonal with respect to the weight matrix W , or W -orthogonal in short, if q1T W − q2 = 0. Proposition 7. Let ξ ∈ Ξ and let W be a weight matrix. Then, the inverse of the value of AW -optimality is equal to the average variance for any system of d mutually W -orthogonal estimable functions QT τ , such that C(Q) ⊆ C(W ). 19 Proof. As in Proposition 6, the average weighted variance for W -orthogonal estimable functions q1T τ, . . . , qdT τ is tr(DQT C − (ξ)Q)/d, with Q and D defined as in the proof of Proposition 6. The W -orthogonality of the considered functions yields that QT W − Q = D−1 , which is equivalent to D1/2 QT W − QD1/2 = Id . From C(QD1/2 ) = C(Q) ⊆ C(W ) = C(KW ) follows that there exists a d × d matrix Z, such that QD1/2 = KZ. D 1/2 T − Q W QD 1/2 = Z T T KW W − KW Z T = Z Z, because T KW W − KW Therefore, Id = = Id as in the proof of Proposition 1. That is, Z is an orthogonal matrix. Then, the average variance can be expressed as T C − (ξ)KW Z)/d tr(DQT C − (ξ)Q)/d = tr(D1/2 QT C − (ξ)QD1/2 )/d = tr(Z T KW T = tr(KW C − (ξ)KW ZZ T )/d = (ΦA (ξ))−1 . Clearly, the maximum number of functions that can be mutually W -orthogonal is d, as Q W − Q = Is cannot be achieved by a v × s matrix Q with s > d. Moreover, the condition T C(Q) ⊆ C(W ) ensures that the estimable functions can be weighted by W . Therefore, Propo- sition 6 shows that any AW -optimal design minimizes the average variance for any system of W -orthogonal estimable functions of maximal size that can be weighted by W . 6 6.1 Primary and secondary weights Inconsistency There is a seeming inconsistency in the weighted optimality: seemingly consistent systems of weights produce inconsistent weight matrices. When we use a set of functions QT τ to construct the treatment weights, these weights imply a weight for any function q T τ in C(Q), representing the amount of interest in this function. However, in general, we cannot consistently use any subset of functions in C(Q) with their implied weights, other than QT τ , as an equivalent way of describing the experimental objective, because then the weight matrix would change, and the implied weights for the original functions QT τ would be different. The example below demonstrates this. Example 4. Consider the setting of comparing two test treatments with a control, as in √ Example 2, with weights b1 = b2 = 1. Let q3T τ = (τ3 − τ2 )/ 2. Then, q3 = Qh, where h = (−1, 1)T , and q3T τ has weight inverse to hT QT WQ− Qh = hT h = 2. Thus, we have the amount of interest in q3T τ represented by the weight b3 = 1/2. 20 Now, consider q1T τ and q3T τ , together denoted as Q̄T τ , with the corresponding weights b1 = 1 and b3 = 1/2, and let us denote W2 = Q̄B Q̄T . Then, q2 = Q̄h2 , where h2 = (1, 1)T , which yields the weight of q2 inverse to hT QT W2− Qh = hT B −1 h = 3. Therefore, the weight implied for q2 is 1/3, which is inconsistent with the original weight b2 = 1. It follows that the system of contrasts q1T τ and q2T τ with weights b1 and b2 implies a weight b3 for q3T τ ; but that is not the same as building a weight matrix from q1T τ and q3T τ with the consistent weights b1 and b3 . In other words, although the original system of contrasts implies a weight 1/2 for the contrast q3T τ , we cannot actually use this weight to equivalently define the same system of k weights. Therefore, given a system of estimable functions QT τ , we propose to distinguish between the primary weights b1 , . . . , bs of the original functions of interest, and the secondary (or implied ) weights w(q) = (q T WQ̃− q)−1 given by the weight matrix WQ̃ for any function q T τ that satisfies q ∈ C(Q). These two systems of weights are not equivalent: the primary weights are pre-specified for a finite number of functions of interest, and they represent the primary interest assigned to these functions; the secondary weights represent the amount of interest in any q ∈ C(Q) implied by the functions of interest and their primary weights. In Example 4, the original weights b1 = b2 = 1 are the primary weights for q1T τ and q2T τ , respectively. By contrast, the weight w(q3 ) = 1/3 of q3T τ is not a primary weight, but one that is implied by the two functions of interest. 6.2 Rank-deficient systems For a rank-deficient system of functions of interest, we may wish to assign the same weight to each of the functions of interest, similarly as in Proposition 4 for the full rank systems. However, in general, this does not happen with the proposed weight matrix QQT , nor with the matrix I − Pτ + QQT proposed by Stallings and Morgan [2015] (as noted in Section 1.3). Consider the extreme case, where Q = (q1 , q2 ), where q1 = q2 , with b1 = b2 = 1, i.e., we have two functions of interest, which are identical. Then, it is easy to see that QQT = 2q1 q1T and qiT (QQT )− qi = 1/2 for i = 1, 2, which yields the secondary weights of q1T τ and q2T τ to be w(q1 ) = w(q2 ) = 2. Without differentiating between the primary and the implied weights, such a result might seem nonsensical - because the function q1T τ is assigned the weight b1 = 1, and yet the corresponding weighting by WQ would at the same time provide double the weight for q1T τ . However, since the function q1T τ is present twice in the system of functions of interest, it is 21 natural that its implied weight w(q2 ) is 2, unlike its primary weight b1 = 1. Let us return to Example 4. Example 5. Consider the setting as in Example 4, and let Q = (q1 , q2 , q3 ) with b1 = b2 = 1 and b3 = 1/2. That is, we have added the contrast q3T τ to the original system of two contrasts, with its weight given by the first two contrasts, see Example 4. Then,    3/2 1 −1 −1 0  √  1     √ Q̃ = 1 0 −1/ 2 , and G =  1 2 √ 2 0 1 1/ 2 0 0  0  0  0 is a generalized inverse of Q̃Q̃T . Then, it is easy to calculate that w(q3 ) = (q3T Gq3 )−1 = 1, and w(q1 ) = w(q2 ) = 4/3. Since we have added a third contrast, which is confounded with the first two contrasts, the third contrast provides some secondary weight for the other two, and vice versa. Then, it is to be expected that the implied weight of each of q1T τ, q2T τ, q3T τ is greater than its primary weight, not even preserving the relative weights. k We have demonstrated that in the rank-deficient case a statement analogous to Proposition 4 does not hold. In fact, employing the notion of the secondary weights, in general such a statement should not hold: i.e., given B = Is , all of the secondary weights implied by WQ should not always be equal to 1. Because of the confounding in the rank-deficient systems, the functions of interest provide each other some of their weight, resulting in secondary weights different from the primary ones. Intuitively, the secondary weights should be at least equal to the primary ones, because of the ’sharing’ of the weights. This is demonstrated in the following proposition. Proposition 8. Let QT τ be a system of estimable functions with weights b1 , . . . , bs , and let WQ̃ be the corresponding weight matrix. Then, the secondary weight of any of the functions qiT τ with respect to WQ̃ is at least bi , i.e., w(qi ) ≥ bi , i = 1, . . . , s. Moreover, if qi can be expressed as a linear combination of the other columns of Q, then w(qi ) > bi . Proof. First, consider the unscaled version WQ = QQT . The weight of qiT τ is inverse to qiT (QQT )− qi = eTi QT (QQT )− Qei , where ei is the i-th column of Is . The matrix PQ := QT (QQT )− Q is idempotent, therefore ρ(PQ ) = 1, where ρ is the spectral norm of a matrix. Then, eTi PQ ei = eTi PQ PQ ei = kPQ ei k22 ≤ ρ2 (PQ )kei k22 = 1. Therefore, w(qi ) ≥ 1. Now, consider WQ̃ = Q̃Q̃T . Then, q̃iT (Q̃Q̃T )− q̃i ≤ 1, the same as for 1/2 WQ . From q̃i = bi qi follows that bi w−1 (qi ) ≤ 1, which implies w(qi ) ≥ bi . 22 Note that equality is attained in kPQ ei k22 ≤ ρ2 (PQ )kei k22 if and only if ei ∈ arg maxx kPQ xk2 /kxk2 , i.e., if and only if ei is an eigenvector corresponding to λ1 (PQ ) = 1. The last condition is equivalent to ei ∈ C(QT ), because PQ is the projector on C(QT ). Suppose that q can be expressed as a linear combination of the other columns of Q, P qi = j6=i αj qj . Moreover, suppose that w(qi ) = bi , i.e., kPQ ei k22 = ρ2 (PQ )kei k22 , which is equivalent to ei ∈ C(QT ). Then there exists a z ∈ Rv , such that QT z = ei , i.e., qiT z = 1 and P qjT z = 0 for j 6= i. But then qiT z = j6=i αj qjT z = 0, which contradicts qiT z = 1. 7 Discussion If the objective of the experiment is to estimate a system of estimable functions QT τ , possibly with weights b1 , . . . , bs , and an eigenvalue-based optimality criterion is considered, then the theory of the weighted optimality criteria is equivalent to the theory of optimality for QT τ (using NQ (ξ)), as shown in Theorems 1 and 3. However, the latter approach may be more appropriate, as it does not require the construction of the weight matrix and it is a well-developed and thoroughly justified theory tailored for estimating a system of estimable functions. When some non-uniform weights bi are considered, the weighting can be simply 1/2 done by rescaling Q to QB 1/2 , i.e., by multiplying each coefficient vector qi by bi . When the weighted optimality is chosen, we have extended its scope, so that it includes the systems of estimable functions with rank less than dim(E), as well as singular weight matrices. Consequently, the weight matrix WQ = QQT can be used instead of that by Stallings and Morgan [2015]. Such a weight matrix is of a simpler form, and has a straightforward interpretation of its elements (see Section 4.3). We noted that it is necessary to differentiate between the primary and the secondary (implied) weights, as they are not equivalent. In fact, given a set of functions of interest QT τ , the calculation of the implied weights for other estimable functions allows for an alternative use of the weight matrices. Instead of being an alternative to the ’standard’ optimality for QT τ , the corresponding weight matrix WQ can be viewed as an addition to the optimality theory for QT τ . It provides a tool for analysis of the functions of interest and other estimable functions: the corresponding weight matrix WQ allows one to calculate the secondary weights, which measure the implied amount of interest in any estimable function q T τ satisfying q ∈ C(Q), given the original system of (weighted) estimable functions QT τ . Such an analysis was performed in Section 4.2 by Stallings and Morgan [2015]. 23 References T. N. E. Greville. Note on the generalized inverse of a matrix product. SIAM Review, 8(4): 518–521, 1966. D. Majumdar. Optimal designs for comparisons between two sets of treatments. Journal of Statistical Planning and Inference, 14:359–372, 1986. D. Majumdar and W. I. Notz. Optimal incomplete block designs for comparing treatments with a control. The Annals of Statistics, 11:258–266, 1983. J. P. Morgan and X. Wang. Weighted optimality in designed experimentation. Journal of the American Statistical Association, 105(492):1566–1580, 2010. J. P. Morgan and X. Wang. E-optimality in treatment versus control experiments. Journal of Statistical Theory and Practice, 5(1):99–107, 2011. F. Pukelsheim. Optimal design of experiments. SIAM, Philadelphia, 2006. S. Rosa and R. Harman. Optimal approximate designs for estimating treatment contrasts resistant to nuisance effects. Statistical Papers, 2016. doi: 10.1007/s00362-016-0809-0. G. Sagnol and R. Harman. Computing exact D-optimal designs by mixed integer second-order cone programming. The Annals of Statistics, 43(5), 2015. G. A. Seber. A Matrix Handbook for Statisticians. John Wiley & Sons, New Jersey, 2008. J. W. Stallings and J. P. Morgan. General weighted optimality of designed experiments. Biometrika, 102(4):925–935, 2015. Y. Yu. Monotonic convergence of a general algorithm for computing optimal designs. The Annals of Statistics, 38(3):1593–1606, 2010. 24
10math.ST
Full-Pose Tracking Control for Aerial Robotic Systems with Laterally-Bounded Input Force arXiv:1605.06645v2 [math.OC] 17 May 2017 Antonio Franchi1 , Ruggero Carli2 , Davide Bicego1 , and Markus Ryll1 Abstract—In this paper, we define a general class of abstract aerial robotic systems named Laterally Bounded Force (LBF) vehicles, in which most of the control authority is expressed along a principal thrust direction, while in the lateral directions a (smaller and possibly null) force may be exploited to achieve fullpose tracking. This class approximates well platforms endowed with non-coplanar/non-collinear rotors that can use the tilted propellers to slightly change the orientation of the total thrust w.r.t. the body frame. For this broad class of systems, we introduce a new geometric control strategy in SE(3) to achieve, whenever made possible by the force constraints, the independent tracking of position-plus-orientation trajectories. The exponential tracking of a feasible full-pose reference trajectory is proven using a Lyapunov technique in SE(3). The method can deal seamlessly with both under- and fully-actuated LBF platforms. The controller guarantees the tracking of at least the positional part in the case that an unfeasible full-pose reference trajectory is provided. The paper provides several experimental tests clearly showing the practicability of the approach and the sharp improvement with respect to state of-the-art approaches. I. I NTRODUCTION In the last years we have seen exciting new developments and astonishing applications in the field of unmanned aerial vehicles (UAVs). Advancements in control, perception and actuation allow UAVs to perform very agile maneuvers [1], [2]. UAVs perform complex missions solely or in swarms and heterogenous groups [3], [4]. Originally performed missions have been contactless as, e.g., environmental monitoring and search and rescue [5]. Nowadays UAVs are as well utilized as aerial robots to perform direct physical interaction – UAVs grasp, transport and manipulate our environment as shown by several research projects on aerial manipulation [6]–[8]. Standard multi-rotors (quadrotors, hexarotors, octorotors, etc.) have coplanar propellers generating forces that are all aligned to one direction in body frame, which makes them under-actuated systems. As a consequence, these platforms can produce a total force only along that direction. In order to follow a generic position trajectory the total force direction in world frame is changed by rotating the whole vehicle. Maneuvers in which rotation and translation are completely independent are precluded to these platforms. Presence of such an underactuation does not only limit the set of maneuvers that the aerial vehicle can carry out, but even deteriorates its potentiality to interact with the environment by rapidly 1 LAAS-CNRS, Université de Toulouse, CNRS, Toulouse, France, [email protected],[email protected],[email protected] 2 Department of Information Engineering, University of Padova, Padova, Italy, [email protected] This work has been funded by the European Union’s Horizon 2020 research and innovation programme under grant agreement No 644271 AEROARMS. exerting forces in an arbitrarily-chosen direction of the space while keeping a pre-specified orientation. This could be a serious problem in the case that, e.g., the platform has to move through a hostile and cluttered ambient or resist a wind gust while keeping a desired attitude. New actuation strategies that can overcome the aforementioned issues and then allow a complete tracking in position and attitude have been explored. The major solution has been to mount rotors in a tilted way such that the thrust of each propeller is not collinear anymore. With this solution, the direction of the total force can be changed by selecting the intensity of the force produced by each propeller. If the number of propellers is at least six, and tilting directions do not generate a singular configuration, then direction and intensity of both the instantaneous total moment and the instantaneous total force acting on the whole system can be made controllable at will (inside the input envelope). This solution has been applied in several real implementation and is becoming more and more popular in the aerial vehicles and robotics community. For example, results achieved in [9] show an improvement in resisting an opposing wrench, while the work done in [10]–[12] shows that such solution allows to decouple the tracking of a desired position and orientation. These new kind of platforms (sometimes referred to as fullyactuated) call for new methods to control them efficiently and to reliably cope with the added complexity of the platforms and of the larger set of tasks in which they can be employed, when compared to standard collinear multi-rotors. To fill this gap, in this paper we propose a novel method for controlling fully actuated multi-rotor platforms while taking into account the most limiting input bounds they have to cope with, i.e., lateral input force. The proposed controller ensures, in nominal conditions, the tracking of a full-6D pose (position plus orientation) reference trajectory. If the reference orientation and the force needed to track the position trajectory do not comply with the platform constraints, the proposed strategy gives priority to the tracking of the positional part of the trajectory1 while also tracking the closest feasible orientation to the reference one. The proposed method is based on a rigorous analysis in which a formal convergence proof is provided. Furthermore, an extensive experimental validation is carried out to test the viability of the theory and learn instructive lessons from practice. Theory and practice clearly demonstrate that the proposed 1 This choice is supported by, e.g., the fact that in typical applications a wrong position tracking is more likely to lead to an obstacle crash than a non perfect orientation tracking. method outperforms state-of-the-art methods, in terms of both performances and stability. In order to attain generality, the proposed method is designed to work with a large variety of different platforms which include not only the fully-actuated but also the underactuated (collinear propeller) case. In this way we both maximize the breadth of the impact of the proposed methodology to new full-actuated platforms and we also maintain backcompatibility with the standard platforms. This last feature makes the proposed method also ideal to control vectoredthrust vehicles that can transit from an under-actuated to a fully-actuated configuration while flying – as. e.g., the one presented in [13]. In fact, by using the proposed controller there is no need of switching between two different controllers for each configuration. Additionally, we envision that the method proposed in this paper will find large application in the new emerging topic of aerial robotic physical interaction with fully-actuated platforms. A striking example of this application has been shown in [14], where an admittance control framework has been built around the controller developed in this paper, and real experiments in contact with the environment are shown. A preliminary version of the method presented in this paper has been proposed in [13]. With respect to [13] we provide here a strongly improved content: 1) a controller that works on a more general model (in [13] only the specific case of hexarotor with a particular orientation pattern is considered), 2) the theoretical proof of the convergence of the controller (in [13] no proof is given), 3) the analytic solution of the optimization problem in a relevant case (not given in [13]), and 4) a set of experiments with a real multi-rotor vehicle that validate the practicability of the method in real scenarios and the improvements with respect to the state of-the-art (in [13] only a limited set of simulations are presented). The remaining part of the paper is structured as follows. Section I-A presents motivations and the state of the art. Section II presents the generic model. The full-pose geometric control and prove of the asymptotically exponential tracking are presented in Sec. III. In Sec. IV we present the full computation of the generic controller in a meaningful case, while results of several experiments are shown in Sec. V. Finally we conclude the paper and give an outline of further possible extensions in Sec. VI. A. Motivations and State of the Art In order to use at best the available energy, common multirotor platforms are designed with all coplanar rotors. Therefore the direction of the input force applied to the platform center of mass (the total thrust) is also collinear with the spinning axes of the rotors. Being the direction of the total thrust constant in body frame, those platforms are underactuated. For these platforms several controllers have been proposed in the literature like, e.g., controller based on the dynamic feedback linearization [15], cascaded/backstepping controllers [16], [17], and geometric controllers on SE(3) [18], [19] (see [20] for a review of these and other possible strategies). In the recent years new concepts have been developed where the use of non-coplanar propellers [9], [10], [21] allows the orientation of the total thrust to deviate from its principal direction, if needed. These platforms present several manifest benefits which have been already discussed in Sec. I. However, in order to minimize the waste of energy caused by the appearance of internal forces, the maximum component of the total thrust along the lateral direction is typically kept (by design) much lower than the maximum allowed component along the vertical one. We call these kind of platforms aerial vehicles with laterally-bounded force (LBF). An LBF platform possesses a principal direction of thrust along which most of the thrust can be exerted. A certain amount of thrust (typically smaller) can be exerted along any non-principal (lateral) directions. This model includes the standard underactuated multi-rotor vehicle where thrust is possible only along the principal direction, and the isotropically fullyactuated platforms where a large amount of total thrust in the lateral directions is applicable [11], [12]. If the LBF platform is underactuated then it is not able to track a generic full-pose trajectory, i.e., with independent position and orientation in SE(3). The rotation about any axis that is orthogonal to the principal fixed total thrust direction must follow the evolution over time of the position trajectory, according to the well-known differential flatness property [15], [22]. The rotation about the axis that is parallel to the total thrust is instead independent from the position trajectory, therefore an underactuated multi-rotor aerial platform can only track a 4D-pose trajectory (i.e., position plus one angle). On he contrary, if the LBF platform is fully-actuated then some force can be exerted in the lateral direction thus allowing the tracking of a generic full-pose (6D) trajectory. However due to the bounded thrust along the lateral directions, it is not possible to track any full-pose trajectory. The larger the bounds the higher the ability of the platform to track any trajectory, the lower the bounds the more the platform resembles an underactuated multi-rotor and thus it becomes almost unable to track a full-pose trajectory but only a 4D-pose one. The easiest approach to control fully-actuated platforms is the inverse dynamics approach. First, a control wrench is computed in order to track the desired trajectory by cancelling the nonlinear dynamical effects and zero the position and orientation errors. Then the thrust inputs for each propeller are computed from the control wrench by simply inverting the control allocation matrix. This method has been first proposed in [10] and then used also in [11]2 and in [12]. The limitation of this control approach is to neglect input saturation, which may easily lead to an unstable behavior if, e.g., the full-pose trajectory to be followed is not input-feasible. Another control approach is presented in [21], which is however specific to that octorotor platform, it does not consider input bounds either, and is based on a particular Euler angle representation. In this paper we present a geometric controller that is 2 In [11] pseudo inversion is used in place of inversion in order to allocate the eighth control inputs of the octo-rotor to attain the six-dimensional wrench. q(t0) = (pr (t0), R(t0)) Uxy u1 zB g xB zW OW p yW FW xW Uxy TABLE I M AIN S YMBOLS USED IN THE PAPER U1 u2 Uxy OB yB FB pr (t) q(t f ) = (pr (t f ), R(t f )) Rr (t) R Fig. 1. A drawing illustrating the main the quantities of an LBF Aerial Vehicle, the main frames involved, the laterally bounded input sets and the full-pose 6D reference trajectory. instead very general and applicable to any LBF vehicle, thus also taking into account the bounds on the lateral control force. The method is not prone to local orientation representation singularities since it is natively designed in SE(3). Furthermore, being not based on pure model inversion like feedback linearization, it is structurally more robust to model uncertainties. Remark 1. It is worth to mention that another way to obtain orientation/position decoupling, could be to use less than six propellers plus additional servomotors to tilt the propellers while flying, as done, e.g., in [23]. This technology is typically referred to as vectoring thrust. For example, in [24] and [23] controllers that deal with vectoring thrust aerial vehicles are presented. One main disadvantage of vectoring thrust platforms is the added complexity and weight due to the additional vectoring motor and mechanism. Another disadvantage is the much slower ability to change the force direction which is due to the small maximum torque of lightweight servomotors and to the inertia of the motor-propeller group. The latter drawback, in particular, is an insurmountable obstacle for physical interaction application. Therefore we do not consider these platforms in the scope of this paper and we keep the extension of the proposed controller to vectored thrust platforms as a possible future development. II. L ATERALLY-B OUNDED F ORCE A ERIAL V EHICLES With reference to Fig. 1, we denote with FW = OW , {xW , yW , zW } and FB = OB , {xB , yB , zB } the fixed inertial frame, and body frame attached to the aerial platform, respectively. The origin of FB , i.e., OB , is chosen coincident with the center of mass (CoM) of the platform and its position in FW 3 is denoted with pW OB ∈ R , shortly indicated with just p in the following. For the reader’s convenience, Table I summarizes all the main symbols used in the paper. The aerial platform is modeled as a rigid body whose mass is denoted with m > 0. The positive definite matrix J ∈ R3×3 denotes the vehicle inertia matrix with respect to OB expressed in FB . The orientation of FB with respect to FW is represented by the rotation matrix RW B ∈ SE(3), shortly denoted with R in the following. The configuration of the aerial vehicle is defined by the position p and the Definition Symbol World Inertial Frame Attached Body Frame Position of the OB , the CoM, in FW Rotation matrix from FW to FB Angular velocity of FB w.r.t FW expr. in FB Mass of the vehicle Vehicle’s Inertia matrix w.r.t to OB expressed in FB Control force applied to the CoM expressed in FB Control moment applied to the CoM expressed in FB Feasible set of the control force u1 Feasible set of the projection of u1 on the xy plane in FB FW FB p R ω m J u1 u2 U1 Uxy Reference position for OB in FW Reference rotation matrix from FW to FB pr (t) Rr (t) Reference control force to be applied to OB Set of orientations in SO(3) that allow the application of fr (t) Subset of R(fr ) that minimizes a certain cost w.r.t. Rr Desired rotation matrix in R(fr , Rr ) fr (t) R(fr ) R(fr , Rr ) Rd attitude R, which are gathered in the vehicle configuration q = (p, R) ∈ SE(3). The angular velocity of FB with respect to FW , expressed in FB , is indicated with ω BB,F ∈ R3 , and briefly denoted as ω in the following. Thus, the vehicle orientation kinematics is described by: ω ]× , Ṙ = R[ω (1) where [?]× : R3 → so(3) is the map that associates a vector ? ∈ R3 to its corresponding skew symmetric matrix. Let us denote the control inputs of the vehicle with u1 = [u1 u2 u3 ]T ∈ R3 and u2 = [u4 u5 u6 ]T ∈ R3 , representing the total force and total moment applied to the CoM of the vehicle expressed in FB , respectively. The total force input u1 is subject to the following constraints [u1 u2 ]T ∈ Uxy ⊂ R2 , u3 ≥ 0, (2) (3) where the laterally bounding set Uxy is a set that contains the origin. We define U1 = {u1 ∈ R3 | [u1 u2 ]T ∈ Uxy , u3 ≥ 0}. Note that Uxy can be constant or even be changing depending of u3 , as shown in Figures 1 and 2–(left). Using the Newton-Euler approach we can express the dynamics of the aerial platform as mp̈ = −mge3 + Ru1 ω = −ω ω × Jω ω + u2 Jω̇ (4) (5) with g being the gravitational acceleration and ei , i = 1, 2, 3, representing the i-th vector of the canonical basis of R3 . Remark 2 (Underactuated aerial vehicle). When Uxy = {0} (6) the total force is always oriented as Re3 and model (4)– (5) becomes the underactuated quadrotor model considered in [15], [17], [19], see Fig. 2–(top). III. F ULL -P OSE G EOMETRIC C ONTROL ON SE(3) Quadrotor Let be given a full-pose trajectory qr (t) = (pr (t), Rr (t)) : [t0 ,t f ] → SE(3), where pr (t) ∈ R3 is the reference position trajectory and Rr (t) ∈ SO(3) is the reference attitude trajectory. The nominal input required to track qr (t) is easily obtained inverting (4)-(5) Hexarotor ur1 = RTr (mge3 + mp̈r ) ω r + Jω̇ ω r, ur2 = ω r × Jω where p̈r = RTr Ṙr . d2 p, dt 2 r (9) (10) ω r ]× = and ω r is defined using (1), i.e., [ω Definition 1. A reference trajectory qr (t) is feasible if ur1 (t) ∈ U1 ∀t ∈ [t0 ,t f ]. Octorotor Full-pose 6D tracking is possible only if the given reference trajectory qr (t) is feasible. However we shall design a controller that works even if qr (t) is not feasible, in the sense that the tracking of pr (t) is still guaranteed and no singularity appears. Consider the following position and velocity errors Force Vector e p = p − pr ev = ṗ − ṗr , (11) (12) fr = mp̈r + mge3 − K p e p − Kv ev , (13) Aerial Vehicle Fig. 2. Set of allowable total total thrust U1 for 3 basic different cases of LBF platforms. Top: a standard quadrotor. Middle: approximation of a hexarotor with tilted propellers. Bottom: approximation of an octorotor with smaller lateral propellers. In the last two cases the sets are an approximation of the real cases, which can be used to simplify the computations. However the proposed control can deal with the real more complex sets as well. Remark 3 (Conic LBF). When Uxy = {[u1 u2 ]T ∈ R2 | u21 + u22 ≤ (tan α)2 u23 }, (7) model (4)–(5) approximates the case of hexarotors with tilted propellers [9], [10], [13], for which the set of allowable U1 forces has the conic shape depicted in Fig. 2-(middle). The quantity α is a parameter that represents the tilting angle of the propellers (hexarotor). Remark 4 (Cylindric LBF). When 2 }, Uxy = {[u1 u2 ]T ∈ R2 | u21 + u22 ≤ rxy and the following vector where K p and Kv are positive definite gain matrices. The vector fr represents the reference total control force that ideally one would like to apply to the aerial vehicle CoM if the system would be completely fully actuated, i.e., if U1 = R3 . The set of orientations that allow to apply fr to the CoM of the LBF aerial vehicle is defined as R(fr ) = {R ∈ SO(3) | RT fr ∈ U1 }. (14) For an underactuated coplanar multi-rotor system, i.e., if (6) holds, the set R(fr ) is formed by any R such that Re3 and fr are parallel, i.e., Re3 × fr = 0. For a generic LBF aerial vehicle the set R(fr ) may contain also matrixes for which Re3 × fr 6= 0. Therefore we have the following. Proposition 1. For any fr it holds R(fr ) 6= 0. / (8) model (4)–(5) approximates the case of an octorotor (or, more in general, an n-rotor) with four main propellers and four (or n − 4) secondary less powerful propellers tilted 90 degrees w.r.t. the main ones, like the one presented in [21], for which the set of allowable U1 forces can be approximated by the cylindric shape depicted in Fig. 2-(bottom). Note that a more accurate (e.g., parallelepipedal) set can be used if needed, for which the proposed controller is still valid. The constant parameter rxy represents the maximum lateral thrust allowed by the smaller horizontal propellers. It is worth to stress again that our model is general enough to encompass a much broader set of possible platform than the set given by just considering the previous examples. Proof. If fr 6= 0 then, by definition of R(fr ) and U1 ,   fr 6= 0/ R(fr ) ⊃ R ∈ SO(3) | Re3 = kfr k If fr = 0 then R(fr ) = SO(3). As one can see from the LBF model the rotational dynamics (5) is (completely) fully actuated and decoupled from the translational dynamics (4). One of the main ideas behind the proposed controller is to exploit a cascaded structure by choosing, at each time t, a desired orientation Rd ∈ SO(3) that belongs to R(fr ) and also minimizes a given cost function w.r.t. Rr . Then one can use the fully actuated rotational dynamics to track Rd and, in turns, track the reference position pr . If the full-pose reference trajectory qr is feasible then Rd will exponentially converge to Rr and then also the reference orientation will be tracked. Otherwise, only the best feasible orientation will be tracked. Therefore the controller implicitly prioritizes the position trajectory against the orientation one, as wanted. In the following, we shall formally define this controller concept and theoretically prove its convergence properties. Define R(fr , Rr ) ⊂ R(fr ) as the set of rotation matrices that solve the minimization min J(Rr , R0 ), (15) R0 ∈R(fr ) where J : SO(3) × SO(3) → R≥0 is a suitably chosen cost function that represents the degree of similarity between Rr and R0 one is interested in. The elements in R(fr , Rr ) represent orientations of the LBF that allow to apply fr and minimize the function J w.r.t. Rr . Consider that, at each time t a desired orientation Rd ∈ R(fr , Rr ) is chosen. Furthermore, whenever Rr ∈ R(fr , Rr ) then Rd must bet chosen equal to Rr . Then define, as in [19], the rotation and angular velocity errors 1 eR = (RTd R − RT Rd )∨ , 2 eω = ω − RRTd ω d (16) (17) where •∨ : so(3) → R3 is the inverse map of [?]× , and ω d is the angular velocity associated to Rd . Consider then the following control law  u1 = satUxy (fTr Re1 )e1 + (fTr Re2 )e2 + (fTr Re3 )e3 (18) ω − KR eR − Kω eω + u2 = ω × Jω ω ]× RT Rd ω d − RT Rd ω̇ ωd − J [ω (19)  where satUxy (x) is a vector in Uxy with the same direction of x, that minimizes the distance from x. KR = kR I and Kω = kω I are the gain matrices with kR > 0 and kω > 0. A nice property is that (18)–(19) reduces to the control in [19] in the case that (6) holds (underactuated vehicles). However a major difference is in the computation of Rd , which in [19] is computed from the position trajectory using the differential flatness property while in the proposed controller is computed ensuring feasibility of the input and minimizing the cost function w.r.t. the reference orientation Rr . In order to prove the convergence properties of the proposed controller let us consider the following error function between two rotation matrixes R1 and R2 to be  1 d(R1 , R2 ) = tr I − RT2 R1 . 2 (20) Theorem 1. Assume that Rd (t) ∈ R(fr (t)) for any t and that ω d (t) are well defined for any t. Consider the ω d (t) and ω̇ control u1 and u2 defined at (18) and (19). Assume that the initial condition satisfies d (R(0), Rd (0)) < 2, (21) and keω (0)k2 < 2 kR ( 1 − d (R(0), Rd (0)) ) λmin (J) (22) Then, the zero equilibrium of the tracking errors eR , eω , e p and ev is exponentially stable. The region of attraction is characterized by (21) and (22). Proof. The proof is divided into two parts. We first show that, if the R(0) and eΩ (0) satisfy, respectively, (21) and (22), then R(t) converges exponentially to Rd (t), in the sense that the function d (R(t), Rd (t)) goes exponentially to zero. Secondly, we characterize the error dynamics on the translational dynamics and, based on the fact that R(t) converges exponentially to Rd (t), we show that also e p and ev goes exponentially to zero. The time derivative of eω defined in (17) is  ω + J [ω ω ]× RT Rd ω d − RT Rd ω̇ ωd . Jėω = Jω̇ (23) Plugging (5) into (23) and substituting u2 from (19), we get Jėω = −kR eR − kω eω . In [19], it is shown, by exhibiting a suitable Lyapunov function, that, under conditions in (21) and in (22), the zero equilibrium of the attitude tracking error eR , eω is exponentially stable and that there exist two positive constants α, β such that d (R(t), Rd (t)) < αe−βt d (R(0), Rd (0)) . (24) We determine now the error dynamics of the translational dynamics. Substituting u1 from (18) in (4) we obtain mp̈ = −mge3 + fr + Ru1 − fr = mp̈r − K p e p − Kv ev + γ , where γ = Ru1 − fr . It easily follows that mėv = −K p e p − Kv ev + γ . (25) Consider (24) and observe that, since Rd ∈ R(fr ) for any t, we have that there exist two positive constants C, ρ such that kγγ (t)k ≤ Ce−ρt kγγ (0)k. Let x = [ev e p ]T then, (25) can be written in vector form as ẋ = Ax + Bγγ where  A= −Kv I −K p 0 (26)   , B= I 0  . Since Kv , K p are both positive definite matrices, we have that A is a Hurwitz matrix. Observe that (26) is the cascade of a linear stable system and an exponential stable signal. Then we can apply Lemma 3 (reported in Appendix) obtaining the result stated in the Theorem. A block diagram that shows the main subsystems of the proposed control architecture is provided in Fig. 3. Theorem 1 ensures, under mild conditions, the exponential stability of e p , ev , eR , and eω . Notice that this results holds R Reference Force (13) (18) u1 pr , ṗr , p̈r LBFA Force fr Projection Dyn. p, ṗ fr Model R, ω u R d Des. Ori. (15) Attitude (19) 2 Rr (1)-(5) Optimization ωd , ω̇d Controller ω R p, ṗ fr Fig. 3. Block diagram of the proposed geometric controller with the references to the corresponding equations in the text. regardless of the feasibility of qr . If qr is also feasible then exponential tracking of qr by q is also guaranteed. In order to formally state this fact let us define the following errors 1 eRr = (RTr Rd − RTd Rr )∨ , 2 eωr = ω d − Rd RTr ω r . (27) (28) In next result we characterize the convergence of the above errors to zero provided that the reference trajectory qr (t) is feasible and satisfies the additional property that ur1 is sufficiently inside U1 , meaning that there exists a time instant t¯ and a positive number ε such that the distance of ur1 from the boundary of U1 is greater than ε > 0 for all t > t¯, i,e, dist (ur1 (t), ∂ U1 ) > ε, ∀t > t¯. (29) Theorem 2. Assume qr (t) is a feasible trajectory and that it satisfies the additional property in (29). Assume that Rd (t) ∈ ω d (t) are well defined R(fr (t)) for any t and that ω d (t) and ω̇ for any t. Consider the control u1 and u2 defined at (18) and (19). Assume that the initial condition satisfies (21) and (22). Then the zero equilibrium of the tracking errors eR , eω , e p and ev is exponentially stable and there exists a time instant t¯ ≥ t0 such that eRr (t) = eωr (t) = 0 for all t > t¯. The region of attraction is characterized by (21) and (22). Proof. From Theorem 1 we can write that fr = mp̈r + mge3 + ξ (30) kξξ (t)k ≤ Le−λt kξξ (0)k (31) where for some positive constants L and λ . This implies that the vector fr − (mp̈r + mge3 ) and, in turn, also the vector RTr fr − RTr (mp̈r + mge3 ), tend exponentially to zero. Hence, since qr (t) is feasible and satisfies (29), it follows, from continuity arguments, that there exists t 0 such that RTr fr ∈ U1 for all t ≥ t 0 . Therefore Rd (t) = Rr (t) for all t > t 0 . Remark 5. The proposed controller (in particular the attitude ωd. controller (19)) relies on the availability of ω d , and ω̇ These quantities depend in turn on Rd which is the output of an optimization algorithm executed at each control step. ω d to be well defined and available the In order for ω d and ω̇ optimization must ensure a sufficient smoothness of Rd . This could be enforced by adding, e.g., a regularization term in the cost function J. If in the real case at hand this is not possible (or not implementable), then at each time instant in which Rd is not smooth the attitude controller will undergo a new transient phase. In practice, see Sec. V, we have experimentally ascertain that the presence of a few isolated non-smooth instants does not constitute at all a real problem for the stability of the implementation and that regularization is actually not needed for practical stabilization. IV. C OMPUTATION OF Rd FOR AN I MPORTANT C ASE The proposed control method is kept on purpose general regarding two main features: the choice of Uxy in (2) and the choice of J in (15). The former allows the method to be used for a large set of aerial vehicles with different actuation capabilities. The latter allows the engineer to customize the definition of similarity between two orientations in order to comply with the particular task at hand. In this section we illustrate how these two general features are particularized to a specific meaningful case. In particular, we consider the case of Uxy defined in (8) and the following choice of cost function J J(Rr , R0 ) = 1 − bT3r b03 , (32) R0 where Rr = [b1r b2r b3r ] and = [b01 b02 b03 ]. The cost function J in (32) is minimized whenever b3r = b03 and maximized whenever b3r = −b03 . Remark 6. For example in the case that the aerial vehicle embeds a down-facing camera, the cost (32) can be used to emphasize the fact that: 1) while following the position trajectory it is important to orient the sagittal axis of the camera as prescribed by b3r , but 2) the particular rotation about the sagittal axis has no relevance for the specific camera-observation task. In the following we show how it is possible to efficiently compute an Rd that belongs to R(fr , Rr ) and is also equal to Rr if Rr ∈ R(fr , Rr ). These are in fact the requirements needed for Rd in order for Theorems 1 and 2 to be valid. Let us start by instantiating R(fr ) for this particular case. From simple geometrical considerations on the cylindrical shape of the set U1 it is easy to see that the following definition of R(fr ) holds q n o 2 , R(fr ) = R0 ∈ SO(3) | fTr b03 ≥ kfr k2 − rxy (33) which states that the vector fr must lie within the cylinder of radius rxy generated about the axis b03 (see Fig. 4). Using (32) and (33) we can rewrite (15) in terms of the only vector variable b03 , instead of the whole matrix R0 , as min √ fTr b03 ≥ 2 , kfr k2 −rxy kb03 k2 =1 −bT3r b03 , (34) 2 , fT and bT are the givens of the problem. where rxy r 3r q 2 then b0 = b In the case that fTr b3r ≥ kfr k2 − rxy 3r is the 3 0 solution to (34). Otherwise, let us write b3 as the sum of two components b03 = b03k + b03⊥ , where b03k is parallel to the plane Algorithm 1: Bisection used to solve problem (35) 1 2 3 4 5 6 Fig. 4. Geometrical interpretation of the feasibility constraint in (33). spanned by b3r and fr , while b03⊥ is perpendicular to it, i.e., is parallel to b3r × fr . It is easy to see that the cost function in (34), i.e., bT3r b03 , is not affected by b03⊥ , in fact bT3r b03 = bT3r b03⊥ +bT3r b03k = bT3r b03k . | {z } =0 The vector b03k can be written using the Rodrigues’s rotation formula as b03k (θ ) = b3r cos θ + (k × b3r ) sin θ + k(k · b3r )(1 − cos θ ), ×fr where k = kbb3r ×f and θ is the rotation angle that univocally 3r r k 0 defines b3k . Noting that the constraint kb03 k2 = 1 is automatically verified by b03k (θ ) for any θ , then we can further simplify (34) in terms of the only scalar variable θ as min √ fTr b03k (θ )≥ 2 kfr k2 −rxy −bT3r b03k (θ ). (35) The minimization prolem (35) can be efficiently solved numerically using the bisection method shown in Algorithm 1. In order to finally compute Rd from b3d we suggest to employ the following formula, as done in [19]: # " Rd = (b3d × b1r ) × b3d {z } | b1d b ×b | 3d {z 1r} b3d . (36) b2d T qFinally, we note that if Rr ∈ R(fr , Rr ) then fr b3r ≥ 2 2 kfr k − rxy which, as we previously said, implies that b3d = b3r . Then, from (36) it results Rd = Rr , thus allowing to fulfill also the second requirement on the computation of Rd , besides the minimization (15). It is worth to notice that the described algorithm takes a negligible time to be run on a standard computer, thus allowing a real time numerical control implementation at frequencies that are way below 1 ms for each control loop, if needed by the application. In case of different sets Uxy and different cost functions J either similar efficient approaches can be used or the method presented here can be used as a conservative approximation. V. E XPERIMENTS In this section we present and discuss the results of different experiments performed with an LBF aerial vehicle. The experimental setup used to conduct the experiments is introduced in 7 8 9 Data: n (number of iterations ∝ solution accuracy) Data: b3r , fr , and rxy (givens of the problem) ×fr k ← kbb3r ×f 3r rk θmax ← arcsin(kkk) θ ← θmax /2 for i = 1 to n do q if fTr b03k (θ ) ≥ 2 kfr k2 − rxy then 1 θmax 2 2i θ ←θ− else θ ← θ + 12 θ2max i return θ Sec. V-1 while in Sec. V-2 we present and discuss thoroughly the different experiments. 1) Experimental Setup: The LBF platform used to perform the experiments is the Tilt-Hex robot, an in-house developed fully actuated vehicle (see Fig. 7). The Tilt-Hex is an example of platform that can be controlled by the full-pose geometric controller presented in Sec. III. We carefully chose the TiltHex to perform the experiments as the platform is able to emulate different values of rxy ∈ [0, rxymax ] (see (8)), which means that we can emulate seamlessly underactuated and fully actuated platforms. Notice that even if the Tilt-Hex is an hexarotor that implements the concept depicted in Fig. 2(middle), we can emulate for validation purposes the cylindric force constraint of Fig. 2-(bottom) by choosing rxy small enough and avoiding trajectories that require extreme values of u3 , see Fig. 5. All components of the Tilt-Hex are off-the-shelf available or 3D printable. The diameter of the Tilt-Hex (distance between two propeller hubs) is 0.8 m. The total mass, including a 2200 mA h battery, is m = 1.8 kg. The propellers are tilted first about the axis that connects the rotor with the center of the hexarotor shape (α = ±35◦ ), then about the axis that is perpendicular to the previous rotation axis and e3 (β = 25◦ ). These angles ensure a balanced selection between large lateral forces and inefficient losses as a result of internal forces. The 30.5 cm propeller blades are powered by MK3638 brushless motors provided by MikroKopter. The maximum lift force of a single motor-propeller combination is 12 N. The electronic speed controller (ESC) driving the motor is a BL-Ctrl-2.0 from MikroKopter. The controller, running on the ESC, is an in-house development [25] that controls the propeller rotational speed in closed loop at a variable frequency (e.g., when the propeller rotation speed is 70 Hz the control frequency is 3.29 kHz). An inertial measurement unit (IMU) provides accelerometer and gyroscope measurements (500 Hz) and a marker-based motion capture system provides position and orientation measurements (100 Hz) of the platform. The motion capture and IMU measurements are fused via a UKF state estimator to obtain the full state at 500 Hz. A PnP-algorithm and an onboard camera could easily be utilized to replace the motion capture system, as done for matrices. In plots where data are very noisy a filtered version (darker color) is presented together with the original data (lighter color in background), as, e.g. in the last row of Fig. 6. The interested reader is referred to the multimedia attachment of this paper to fully enjoy the videos all the experiments. Furthermore, all the experimental data (with suitable scripts to plot them) are provided for download at the the following link http://homepages.laas.fr/afranchi/files/2017/dataset1.zip. A. Experimental Batch 1 Fig. 5. Left: The blue volume encloses the set of feasible forces, obeying the constraints of minimal and maximum rotor spinning velocity for the Tilt-Hex. The red plane visualizes the cut of the sectional view of the plot on the right. Right: lower part of the cut of the left figure. The red cylinder visualizes the volume of the imposed cylindric force constraint. Notice that the cylinder is fully inside the volume of feasible forces. The black dot in the center visualizes the force needed to hover horizontally and therefore represents the nominal working point. a similar system in [26], by some of the authors. However it is preferable to validate the proposed controller using the motion capture and the IMU because in this way we minimize the influence of the particular perception system used on the controller performances and the evaluation results more fair. Finally, the controller has been implemented in MatlabSimulink and runs at 500 Hz on a stationary base PC connected to the Tilt-Hex through a serial cable. As the computational effort of the controller is very low (considerably below 1 ms per control loop) it could be ported easily to an on-board system. Based on our experience with a similar porting, we expect the performances of an onboard implementation to be much better than the Matlab-Simulink implementation, thanks to the possibility of reaching a faster control frequency (larger than 1 kHz) and almost real-time capabilities (latency below 1 ms). Therefore the experiments proposed in Section V-2 represent a worst case scenario from this point of view, in the sense that an onboard implementation can only perform better than what we tested. 2) Experimental Validations: Three different experimental validations have been conducted. The task of of all the experiments is to follow at best a given reference pose trajectory qr (t) = (pr (t), Rr (t)), i.e., position and orientation in function of time t. In the first experimental validation, called Experimental Batch 1 the value of rxy in (8) and of Rr is kept constant. The Experimental Batch 1 is composed by three experiments: Exp. 1.1, Exp. 1.2 and Exp. 1.3, which are detailed in the following. Instead in the second validation, denoted with Exp. 2, Rr varies over time. Finally in the third validation, referred to as Exp. 3 is rxy that varies over time. For the reader’s convenience the rotation matrices used internally by the controller have been converted to roll-pitchyaw angles, with the convention R• → φ• , θ• , ψ• in all plots. However, the internal computations are all done with rotation In the Experimental Batch 1 the translational part of the reference trajectory, i.e., pr (t) = [prx (t) pry (t) prz (t)]T , is such that pry (t) = 0 m and prz (t) = 1 m remain constant over the whole trajectory, while prx (t) oscillates sinusoidally between −1.2 m and 1.2 m with constant amplitude and time-varying frequency. The time-varying frequency is chosen such that the envelope of p̈rx (t) is first quasi-linearly increasing from 0 m/s2 up to 5.9 m/s2 and then quasi-linearly decreasing down to 0 m/s2 – see Fig. 6: first (top) and last (bottom) plot. The trajectory includes also a start-from-rest maneuver and a stopto-rest maneuver at the beginning and the end, respectively. The reference orientation is constant and horizontal during the whole trajectory, i.e., Rr (t) = I3×3 The batch is composed by three experiments described in the following. In Exp. 1.1 a value of rxy = 3 N has been selected, which fits well inside the actual maximum lateral force of the Tilt-Hex given its mass of m = 1.8 kg. This means that in the parts of 3N 2 the trajectory in which | p̈rx | > 1.8 kg = 1.66 m/s we expect the controller to let the platform deviate from Rr in order to track the high lateral acceleration. On the other side we expect a good independent tracking of position and orientation when p̈rx ≤ 1.66 m/s2 . In fact, Exp.1.1 is meant to illustrate the canonical behavior of proposed controller when controlling a fully-actuated LBF platform. In Exp. 1.2 we present the result of the controlled system in the extreme situation of rxy = 0 N which resembles an underactuated aerial vehicle. Therefore we expect the controller to let the platform deviate almost always from Rr . This experiment is meant to show that the proposed controller can handle the (classic) underactuated case, thus not requiring the user to switch between different controllers. In Exp. 1.3 we perform the same trajectory with the stateof-the-art controller presented in [10], a controller that does not take into account the input saturations. This experiment is meant to show how the proposed controller outperforms the state of the art controllers in terms of robustness and stability. 1) Experiment 1.1: Fig. 6 visualizes the main results of Exp 1.1. There are three clearly distinct temporal phases in the experiment separated by the vertical dashed lines in the second plot and defined by t ∈ T1 = [0 s, 25.8 s], t ∈ T2 = [25.8 s, 74 s], and t ∈ T3 = [74 s, 95 s], respectively. In the first and third phases the full-pose reference trajectory is always feasible. In fact, the norm of the acceleration of the reference position trajectory | p̈rx | is always below 1.66 m/s2 (see the sixth plot- dashed grey lines). This value represents the maximum lateral acceleration that the controller can impose . [m] 1 0 −1 −2 prx pry prz py px pz . 20 . Fig. 7. The Tilt-Hex performing Exp. 1.1 at different time instances: Left t = 15.4 s; middle t = 37.7 s; right t = 47.9 s. Although the reference orientation is constant and horizontal the Tilt-Hex adapts it orientation to allow for following the reference position. [deg] 10 0 −10 −20 θr θd θ . . [m] 0.05 0 −0.05 −0.1 (px − prx ) (py − pry ) (pz − prz ) . 10 . [deg] 5 0 −5 −10 . (φ − φd ) (θ − θd ) (ψ − ψd ) −15 3 . [m\s] 1.5 0 −1.5 −3 −4.5 ṗrx ṗry ṗrz ṗy ṗx ṗz . [m\s2 ] . 6 3 0 −3 −6 −9 p̈rx p̈ry p̈x p̈y . 4 . [N] 2 0 −2 −4 u1 u2 rxy . . [Hz] 80 60 40 0 w1 w2 10 20 w3 30 w4 40 [s] w5 50 w6 60 70 80 90 . Fig. 6. Exp. 1.1: Desired position: sinusoidal motion along the xW axis with constant amplitude and triangular (first increasing then decreasing) frequency. Desired orientation: constantly horizontal. Lateral force bound: constant rxy = 3 N. to the platform when the orientation is kept horizontal and the bound rxy = 3 N and mass of m = 1.8 kg are considered. In the second phase, instead, the full-pose reference trajectory is not always feasible and in the middle of the second phase, in the neighborhood of t = 49 s, the trajectory is mostly unfeasible, since the lateral acceleration required has peaks of 5.9 m/s2 (3.5 times the maximum lateral acceleration attainable while keeping a horizontal orientation). Accordingly to what expected, in the ‘feasible’ phases (T1 and T3 ) both the orientation and position tracking errors w.r.t. the reference full-pose trajectory, are relatively low. In particular we have that the pose error is in average zero, and kp(t) − pr (t)k < 0.02 m and |θ (t) − θr (t)| < 1.7◦ . In the ‘unfeasible’ phase (T2 ), the position tracking error is still good (kp(t) − pr (t)k < 0.06 m) while the desired orientation Rd (t) sensibly deviates from the reference one Rr (t) with a peak overshoting 20◦ for |θd (t) − θr (t)| (see second plot). In fact, tilting is the only way by which the platform can track the desired position, given the lateral force bounds. It is interesting to note that not only the reference position is well tracked along the whole experiment, but also the translational velocity and acceleration are, as shown in the fifth plot and sixth plot, respectively. Looking at the seventh plot one can appreciate how the controller keeps always the lateral force within the requested bounds and at the same time touches and stays on the bounds several times for several seconds. This is a clear index that the controller exploits at best the platform capabilities. Notice also how in the phases in which the lateral force touches the bounds, the controller exploits the tilting of the platform (compare the second plot) in order to compensate for the partial loss of the lateral control authority and attain the force required to produce the needed acceleration. Finally, for the sake of completeness, we present also the actual six rotor spinning frequencies w1 , . . . , w6 in the eighth and final plot. Figure 7 shows the Tilt-Hex performing Exp. 1.1 in three different time instants. Furthermore, we encourage the reader to watch the multimedia atachment showing this and the other experiments. 2) Experiment 1.2: To test the behavior of the controller with an underactuated aerial system, in Exp. 1.2 we ask the system to track the same trajectory of Exp 1.1 but setting a zero maximum lateral force, i.e., rxy = 0 N. In this way the TiltHex should emulate the behavior of an underactuated platform as, e.g., a collinear multi-rotor. Figure 8 shows the main plots, where we omit the plots that are similar to the ones in Fig. 6 in order to focus on the salient differences. Contrarily to Exp. 1.1, in Exp. 1.2 the first and third ‘feasible’ phases do not exists. The whole experiment is a long unfeasible phase due to the constraint rxy = 0 N, which makes impossible, at any time, to track the constantly horizontal reference orientation defined while following the sinusoidal reference position trajectory. The orientation tracking of Exp. 1.2 is presented in the first plot of Fig. 8, where also the one Exp. 1.1 is shown again for ease of comparison. In the period of time T1 defined in Sec. V-A1, the pitch tracking error in Exp. 1.2, |θ (t) − θr (t)|, 30 15 0 −15 −30 −45 . 1 [m] [deg] . Ex. 1.2: θd Ex. 1.1: θd Ex. 1.2: θ Ex. 1.1: θ −2 0 . . . [deg] [m] 0 −0.1 prx pry 5 prz 10 py px 15 pz 20 25 30 35 . 20 0.05 −0.05 0 −1 (px − prx ) (py − pry ) (pz − prz ) 10 0 −10 −20 φr φd φ θr θd θ . . . . 0.3 0 −1 u1 u2 rxy 0.15 [m] [N] 1 . . 0 −0.15 80 (py − pry ) (px − prx ) (pz − prz ) . . 20 40 0 w1 w2 10 20 w3 30 w4 40 [s] 50 w5 [deg] [Hz] −0.3 60 w6 60 70 80 90 . 10 0 −10 −20 Fig. 8. Exp. 1.2: Same desired trajectory as in Exp.1.1 but with rxy = 0. (φ − φd ) (θ − θd ) (ψ − ψd ) . . [Hz] 80 reaches 11◦ , i.e., 6.5 times the peak of Exp. 1.1 in the same period. In the period of time T2 defined in Sec. V-A1, the pitch tracking error in Exp. 1.2, |θ (t) − θr (t)| reaches 31◦ i.e., about 1.5 times the peak of Exp. 1.1 in the same period. Regarding the translation (second plot of of Fig. 8), the peak of the position tracking error is about 3 times larger (in the period T1 ) and 1.4 times larger (in the period T2 ), when compared to the error peak of Exp. 1.1 in the same periods. This is due to the fact that full actuation helps in minimizing the position tracking too (not only the orientation tracking). In the third plot of Fig. 8 we can see that that the inputs u1 and u2 remain zero as expected during the full trajectory tracking, as required. Finally, for completeness, we present also the actual six rotor spinning frequencies w1 , . . . , w6 in the fourth and last plot of Fig. 8. 3) Experiment 1.3: In order to compare with the stateof-the-art methods such as [10], in Exp. 1.3 we tested the controller with a saturated rotor spinning velocity with the minimum and maximum values in Exp. 1.1 (43 Hz ≤ wi ≤ 83 Hz, i ∈ [1 . . . 6]). The results are depicted in Fig. 9. The platform tracks well the reference trajectory till the output reaches its limit (t=34 s) (see Fig. 9 - third plot, dashed line). Spinning velocities outside the limitation are asked by the controller and are therefore saturated. This means that u1 and u2 in (18)–(19) cannot be generated anymore and the trajectory tracking performance decreases rapidly, until the system becomes completely unstable diverging from the reference position (||p − pr || > 0.5 m) and reference velocity (||ṗ− ṗr || > 1.2 m/s) such that we had to abort the experiment. This experiment clearly shows how our controller outperforms a state-of-the-art controller in terms of performances and, most important of all, stability and safety. 60 40 0 w1 w2 5 w3 10 w4 15 [s] w5 20 w6 25 30 35 . Fig. 9. Exp. 1.3: Same desired trajectory as in Exp.1.1 but with saturated rotor spinning velocity w (saturation indicated by dashed grey lines in plot five). The experiment is automatically stopped after about 39 s because the system becomes unstable. B. Experiment 2 To present the full capabilities of the full pose controller on LBF vehicles, in Exp. 2 we set pr (t) as in Exp. 1.1, but we additionally ask the platform to follow a Rd (t) generated applying to I3×3 a sinusoidal rotation about the yW axis (with an amplitude of 10◦ ). This rotational motion is particularly chosen such that the orientation of the Tilt-Hex is in opposition of phase with respect to the orientation that an underactuated vehicle would need in order to track pr (t) (i.e., the top part of the platform facing outwards at the two ends of the position trajectory, while for, e.g. a quadrotor the top would face always toward the center of the position trajectory). Also in this case the reference-to-actual position error and the desired-to-actual orientation error remain bounded and small (see the third and fourth plot of Fig. 10). The maximum lateral thrust is reached sooner than Exp. 1.1 (at t = 10 s), due to the special inclination required to the Tilt-Hex. This results in an earlier adaptation of the desired orientation trajectory Rd . As expected, at the time of highest accelerations (45 s ≤ t ≤ 55 s) the desired pitch angle θd is almost inverted with respect to the reference angle θr . C. Experiment 3 The conclusive Exp. 3 has been designed to stress the fact that the presented controller can seamlessly work with under . . 1 2 [m] [m] 1 0 −1 prx pry prz py px pz −2 20 . . 10 0 −10 −20 pry prx −2 0 20 10 prz py px 20 pz 30 40 50 . 10 [deg] [deg] . 0 −1 θr θd θ 0 −10 θr −20 θd θ . . . . 0.05 0 [m] [m] 0.05 −0.05 −0.1 −0.15 0.1 (px − prx ) (py − pry ) (pz − prz ) 0 −0.05 −0.1 (px − prx ) (py − pry ) (pz − prz ) . . . −5 −10 10 5 0 [deg] [deg] 5 . (φ − φd ) (θ − θd ) (ψ − ψd ) 0 −5 −10 φ − φd θ − θd ψ − ψd . . . 2 5 0 2.5 [N] [N] . −2 −4 −6 0 u1 u2 rxy 10 20 30 0 −2.5 −5 40 [s] 50 60 70 80 90 u1 u2 rxy . . . Fig. 10. Exp. 2: Desired position: as in Exp. 1.1. Desired orientation: sinusoidal rotation about the yW axis in opposition of phase w.r.t. a hypothetical quadrotor following the desired position. Lateral force bound: constant rxy = 3 N. and fully-actuated platforms and moreover with platforms that can actively change between these two configurations during flight, as the one presented in [13]. The plots of the experiment are reported in Fig. 11. The reference trajectory in position for the second experiment consists out of two regular sinusoidal motions along the xW and yW axes with an amplitude of 1.3 m and 0.5 m, respectively, and constant frequencies. The first seconds of the translational trajectory are a polynomial trajectory to connect the initial state of the Tilt-Hex (hovering at an arbitrary position) with the sinusoidal reference trajectory. The reference orientation is constant Rr (t) = I3×3 . The lateral force bound rxy is changed over time, in particular, it is rxy (t) = 0 N for t ∈ [0 s, 18 s], rxy (t) = 10 N for t ∈ [38 s, 56 s], and it is linearly increasing from 0 N to 10 N for t ∈ [18 s, 38 s] The selection of the time-varying rxy (t) forces to system to be underactuated until t = 18 s. As it should be, the position tracking is always good (first and third plots). However the system cannot track at the same time the reference position the reference orientation. Until t = 34 s the system is partially fully actuated (w.r.t. the trajectory to be followed). The orientation tracking gradually improves. At t = 34 s, rxy is large enough to track the reference orientation at any time (see second plot). The behavior of rxy is visualized in the fifth plot, together [Hz] 80 60 40 20 0 w1 w2 10 w3 20 w4 [s] w5 30 w6 40 50 . Fig. 11. Exp. 3: Desired position: composition of two sinusoidal motions along xB and yB , with constant amplitudes and frequencies. Desired orientation: constant and horizontal. Lateral force bound: rxy linearly increasing from 0 N to 10 N. with the actual lateral forces implemented by the controller, which are always kept within the bounds. The fact that the lateral force bound changes over time does not deterioriate the behavior of the controller, which is instead able to cope with the time-varying constraint exploiting the platform capability always at its best. Finally it is worth to mention that the ranges of the propeller spinning frequencies utilized by the controller (w1 . . . w6 ) naturally increases with the increase of rxy (t) at the benefit of completely tracking the full pose reference trajectory (see the sixth plot). VI. C ONCLUSIONS In this paper we introduced the new class of LaterallyBounded Force (LBF) aerial vehicles. This class is general enough to encompass a large variety of recently conceived aerial vehicles having the possibility to actuate the thrust in a direction other than the principal one. Common underactuated platforms are included in this class as a degenerate (but fully admissible) case. For this class of vehicles we proposed a geometric controller in SE(3) that is able to let it track any feasible full-pose (6D) trajectory. The controller adapts seamlessly to the case the trajectory is (or becomes) not feasible or that the platform is (or becomes) underactuated. Being defined in SE(3) the controller is not prone to the singularities of local chart orientation representations. The practicability of the theory has been shown in real experiments. Furthermore this controller has been already used as inner loop controller for other projects involving also aerial physical interaction, as, e.g., in [14]. In future we plan to study adaptive and robust techniques to deal with parameter uncertainties and malfunction of some of the actuators. ẋ1 (t) = Ax1 (t) + Bx2 (t) ẋ2 (t) = f (x2 (t)) (37) where A ∈ Rn1 ×n1 , B ∈ Rn1 ×n2 and f : Rn2 → Rn2 is a continuous function. We assume that 1) A is a Hurwitz matrix; 2) there exists a compact set X ⊆ Rn2 with 0 ∈ X , and suitable constants C > 0, ρ > 0, such that kx2 (t)k ≤ Ce−ρ t kx2 (0)k, (38) for any x2 (0) ∈ X . Then, the zero equilibrium (x1 , x2 ) = (0, 0) of the cascade system (37) is exponentially stable. The basin of attraction is R × X . Proof. From the first equation in (37), we have that 0 eA(t−τ) Bx2 (τ) dτ. Since A is Hurwitz and since signal x2 satisfies (38), it follows that there exist suitable positive constants C1 , C2 , ρ1 , ρ2 such that kx1 (t)k ≤ C1 e−ρ1 t kx1 (0)k + Z t eA(t−τ) Bx2 (τ) dτ 0 −ρ2 t ≤ C1 e−ρ1 t kx1 (0)k +C2 e  ≤ 2C32 e−2ρ3 t kx1 (0)k2 + kx2 (0)k2 +C2 e−2ρt kx2 (0)k2   ≤ 2C32 e−2ρ3 t +C2 e−2ρt kx1 (0)k2 + kx2 (0)k2 T Let q x(t) = [x1 (t) x2 (t)] and let ρ4 = min {ρ3 , ρ} and C4 = 2C32 +C2 . Then kx(t)k2 ≤ C42 e−2ρ4 t kx(0)k2 , and, equivalently, kx(t)k ≤ C4 e−ρ4 t kx(0)k. R EFERENCES Lemma 3. Consider the cascade system Z t kx1 (t)k2 + kx2 (t)k2 This shows that systems in (37) is exponentially stable. VII. A PPENDIX x1 (t) = eAt x1 (0) + Now, combining the previous inequality with (38), we can write kx2 (0)k Defining C3 = max {C1 ,C2 }, ρ3 = min {ρ1 , ρ2 }, yields kx1 (t)k ≤ C3 e−ρ3 t (kx1 (0)k + kx2 (0)k) and, in turn,  kx1 (t)k2 ≤ C32 e−2ρ3 t kx1 (0)k2 + 2kx1 (0)kkx2 (0)k + kx2 (0)k2 . Since 2kx1 (0)kkx2 (0)k ≤ kx1 (0)k2 + kx2 (0)k2 we have,  kx1 (t)k2 ≤ 2C32 e−2ρ3 t kx1 (0)k2 + kx2 (0)k2 . [1] D. Mellinger, N. Michael, and V. Kumar, “Trajectory generation and control for precise aggressive maneuvers with quadrotors,” in 12th Int. Symp. on Experimental Robotics, Delhi, India, Dec. 2010. [2] D. Falanga, E. Mueggler, M. Faessler, and D. Scaramuzza, “Aggressive quadrotor flight through narrow gaps with onboard sensing and computing using active vision,” in 2017 IEEE Int. Conf. on Robotics and Automation, Singapore, 2016. [3] A. Kushleyev, D. Mellinger, C. Powers, and V. Kumar, “Towards a swarm of agile micro quadrotors,” Autonomous Robots, vol. 35, no. 4, pp. 287–300, 2013. [4] SHERPA, “EU Integrated Project IP 600958,” www.sherpa-project.eu. [5] T. Tomić, K. Schmid, P. Lutz, A. Dömel, M. Kassecker, E. Mair, I. L. Grixa, F. Ruess, M. Suppa, and D. Burschka, “Toward a fully autonomous uav: Research platform for indoor and outdoor urban search and rescue,” Robotics & Automation Magazine, IEEE, vol. 19, no. 3, pp. 46–56, 2012. [6] ARCAS, “EU Collab. Project ICT-287617,” www.arcas-project.eu, 2011-2015. [7] AeRoArms, “EU Collab. Project ICT-644271,” www.aeroarms-project. eu, 2015-2019. [8] AEROworks, “EU Collab. Project ICT-644128,” www.aeroworks2020. eu. [9] R. Voyles and G. Jiang, “Hexrotor UAV platform enabling dextrous interaction with structures – preliminary work,” in 2012 IEEE Int. Symp. on Safety, Security and Rescue Robotics, College Station, TX, Nov. 2012, pp. 1–7. [10] S. Rajappa, M. Ryll, H. H. Bülthoff, and A. Franchi, “Modeling, control and design optimization for a fully-actuated hexarotor aerial vehicle with tilted propellers,” in 2015 IEEE Int. Conf. on Robotics and Automation, Seattle, WA, May 2015, pp. 4006–4013. [11] D. Brescianini and R. D’Andrea, “Design, modeling and control of an omni-directional aerial vehicle,” in 2016 IEEE Int. Conf. on Robotics and Automation, Stockholm, Sweden, May 2016, pp. 3261–3266. [12] S. Park, J. J. Her, J. Kim, and D. Lee, “Design, modeling and control of omni-directional aerial robot,” in 2016 IEEE/RSJ Int. Conf. on Intelligent Robots and Systems, Daejeon, South Korea, 2016, pp. 1570–1575. [13] M. Ryll, D. Bicego, and A. Franchi, “Modeling and control of FAST-Hex: a fully-actuated by synchronized-tilting hexarotor,” in 2016 IEEE/RSJ Int. Conf. on Intelligent Robots and Systems, Daejeon, South Korea, Oct. 2016, pp. 1689–1694. [14] M. Ryll, G. Muscio, F. Pierri, E. Cataldi, G. Antonelli, F. Caccavale, and A. Franchi, “6D physical interaction with a fully actuated aerial robot,” in 2017 IEEE Int. Conf. on Robotics and Automation, Singapore, May 2017. [15] V. Mistler, A. Benallegue, and N. K. M’Sirdi, “Exact linearization and noninteracting control of a 4 rotors helicopter via dynamic feedback,” in 10th IEEE Int. Symp. on Robots and Human Interactive Communications, Bordeaux, Paris, France, Sep. 2001, pp. 586–593. [16] T. Hamel, R. Mahony, R. Lozano, and J. Ostrowski, “Dynamic modelling and configuration stabilization for an X4-Flyer,” in 15th IFAC World Congress, Barcelona, Spain, 2002, pp. 217–222. [17] S. Bouabdallah and R. Siegwart, “Backstepping and sliding-mode techniques applied to an indoor micro quadrotor,” in 2005 IEEE Int. Conf. on Robotics and Automation, May 2005, pp. 2247–2252. [18] R. Mahony, S.-H. Cha, and T. Hamel, “A coupled estimation and control analysis for attitude stabilisation of mini aerial vehicles,” in 2006 Australasian Conf. on Robotics & Automation, Auckland, New Zealand, Nov. 2006, pp. 3003–3012. [19] T. Lee, M. Leoky, and N. H. McClamroch, “Geometric tracking control of a quadrotor UAV on SE(3),” in 49th IEEE Conf. on Decision and Control, Atlanta, GA, Dec. 2010, pp. 5420–5425. [20] M.-D. Hua, T. Hamel, P. Morin, and C. Samson, “Introduction to feedback control of underactuated VTOL vehicles: A review of basic control design ideas and principles,” IEEE Control Systems Magazine, vol. 33, no. 1, pp. 61–75, 2013. [21] H. Romero, S. Salazar, A. Sanchez, and R. Lozano, “A new UAV configuration having eight rotors: dynamical model and real-time control,” in 46th IEEE Conf. on Decision and Control, New Orleans, LA, Dec. 2007, pp. 6418–6423. [22] D. Mellinger and V. Kumar, “Minimum snap trajectory generation and control for quadrotors,” in 2011 IEEE Int. Conf. on Robotics and Automation, Shanghai, China, May. 2011, pp. 2520–2525. [23] M. Ryll, H. H. Bülthoff, and P. Robuffo Giordano, “A novel overactuated quadrotor unmanned aerial vehicle: modeling, control, and experimental validation,” IEEE Trans. on Control Systems Technology, vol. 23, no. 2, pp. 540–556, 2015. [24] M.-D. Hua, T. Hamel, P. Morin, and C. Samson, “Control of VTOL vehicles with thrust-tilting augmentation,” Automatica, vol. 52, pp. 1–7, 2015. [25] A. Franchi and A. Mallet, “Adaptive closed-loop speed control of BLDC motors with applications to multi-rotor aerial vehicles,” in 2017 IEEE Int. Conf. on Robotics and Automation, Singapore, May 2017. [26] J.-L. Sanchez-Lopez, V. Arellano-Quintana, M. Tognon, P. Campoy, and A. Franchi, “Visual marker based multi-sensor fusion state estimation,” in 20th IFAC World Congress, Toulouse, France, Jul. 2017.
3cs.SY
arXiv:1511.03870v2 [math.GR] 2 Jun 2016 A Practical Cryptanalysis of the Algebraic Eraser Adi Ben-Zvi∗ Simon R. Blackburn† Boaz Tsaban∗ June 3, 2016 Abstract We present a novel cryptanalysis of the Algebraic Eraser primitive. This key agreement scheme, based on techniques from permutation groups, matrix groups and braid groups, is proposed as an underlying technology for ISO/IEC 29167-20, which is intended for authentication of RFID tags. SecureRF, the company owning the trademark Algebraic Eraser, markets it as suitable in general for lightweight environments such as RFID tags and other IoT applications. Our attack is practical on standard hardware: for parameter sizes corresponding to claimed 128-bit security, our implementation recovers the shared key using less than 8 CPU hours, and less than 64MB of memory. 1 Introduction The Algebraic Eraser™ is a key agreement scheme using techniques from non-commutative group theory. It was announced by Anshel, Anshel, Goldfeld and Lemieaux in 2004; the corresponding paper [1] appeared in 2006. ∗ Department of Mathematics, Bar-Ilan University, Ramat Gan 5290002, Israel Department of Mathematics, Royal Holloway University of London, Egham, Surrey TW20 0EX, United Kingdom © IACR 2016. This article is the final version submitted by the author(s) to the IACR and to Springer-Verlag on 1 June 2016. The version published by Springer-Verlag is available at [DOI to follow]. † 1 The Algebraic Eraser is defined in a very general fashion: various algebraic structures (monoids, groups and actions) need to be specified in order to be suitable for implementation. Anshel et al. provide most of this extra information, and name this concrete realisation of the Algebraic Eraser the Colored Burau Key Agreement Protocol (CBKAP). This concrete representation involves a novel blend of finite matrix groups and permutation groups with infinite braid groups. A company, SecureRF, owns the trademark to the Algebraic Eraser, and is marketing this primitive as suitable for low resource environments such as RFID tags and Internet of Things (IoT) applications. The primitive is proposed as an underlying technology for ISO/IEC 2916720, and work on this standard is taking place in ISO/IEC JTC 1/SC 31/WG 7. The company has also presented the primitive to the Internet Research Task Force’s Crypto Forum Research Group (IRTF CFRG), with a view towards standardisation. IoT is a growth area, where current widely-accepted public key techniques struggle to operate due to tight efficiency constraints. It is likely that solutions which are efficient enough for these applications will become widely deployed, and the nature of these applications make system changes after deployment difficult. Thus, it is vital to scrutinise the security of primitives such as the Algebraic Eraser early in the standardisation process, to ensure only secure primitives underpin standardised protocols. In a presentation to the NIST Workshop in Lightweight Cryptography in 2015, SecureRF claims a security level of 2128 for their preferred parameter sizes, and compares the speed of their system favourably with an implementation of a key agreement protocol based on the NIST recommended [14] elliptic curve K-283. The company reports [3] a speed-up by a factor of 45– 150, compared to elliptic curve key agreement at 128-bit security levels. It claims that the computational requirements of the Algebraic Eraser scales linearly with the security parameter, in contrast to the quadratic scaling of elliptic-curve-based key agreement. Related work The criteria for choosing some global parameters of the scheme (namely certain subgroups C and D of matrices over a finite field, and certain subgroups A and B of a certain infinite semidirect product of groups) are not given in [1], and have not been made available by SecureRF. In the absence of this information, it is reasonable to proceed initially with a cryptanalysis on the basis that these parameters are chosen in a generic fashion. All previous cryptanalyses have taken this approach. 2 Myasnikov and Ushakov [13] provide a heuristic length-based attack on the CBKAP that works for the parameter sizes originally suggested [1]. However, Gunnells [10] reports that this attack quickly becomes unsuccessful as parameter sizes grow; the parameter sizes proposed by SecureRF make this attack impractical.1 Kalka, Teicher and Tsaban [11] provide an efficient cryptanalysis of the CBKAP for arbitrary parameter sizes. The attack uses the public key material of Alice and the messages exchanged between Alice and Bob to derive an equivalent to the secret random information generated by Bob, which then compromises the shared key, and so renders the scheme insecure. In particular, the techniques of [11] will succeed when the global parameters are chosen generically. SecureRF uses proprietary distributions for global parameters, so the cryptanalysis of [11] attack does not imply that the CBKAP as implemented is insecure.2 Indeed, Goldfeld and Gunnells [9] show that by choosing the subgroup C carefully one step of the attack of [11] does not recover the information required to proceed, and so this attack does not succeed when parameters are generated in this manner. Our contribution There are no previously known attacks on the CBKAP for the proposed parameter sizes, provided the parameters are chosen to resist the attack of [11]. The present paper describes a new attack on the CBKAP that does not assume any structure on the subgroup C. Thus, a careful choice of the subgroup C will have no effect on the applicability of our attack, and so the proposed security measure offered by Goldfeld and Gunnells [9] to the attack of [11] is bypassed. The earlier cryptanalyses of CBKAP ([13],[11]) attempt to recover parts of Alice’s or Bob’s secret information. The attack presented here recovers the shared key directly from Alice’s public key and the messages exchanged between Alice and Bob. SecureRF have kindly provided us with sets of challenge parameters of the full recommended size, and our implementation is successful in recovering the shared key in all cases. Our (non-optimised) implementation recovers the 1 There is an analogy with the development of RSA here: the size of primes (200 digits) proposed in the original article [15] was made obsolete by improvements in integer factorisation algorithms [4]. 2 The analogy with RSA continues: factorisation of a randomly chosen integer n is much easier than when n is a product of two primes of equal size, which is why the latter is used in RSA. 3 common key in under 8 hours of computation, and thus the security of the system is much less than the 2128 level claimed for these parameter sizes. The attack scales well with size, so increasing parameter sizes will not provide a solution to the security problem for the CBKAP. Conclusion and recommendation Because our attack efficiently recovers the shared key of the CBKAP for recommended parameter sizes, using parameters provided by SecureRF, we believe the results presented here cast serious doubt on the suitability of the Algebraic Eraser for the applications proposed. We recommend that the primitive in its current form should not be used in practice, and that full details of any revised version of the primitive should be made available for public scrutiny in order to ensure a rigorous security analysis. Recent developments Since the first version of this paper was posted, there have been two recent developments. Firstly, authors from SecureRF have posted [2] a response to our attack, concentrating in the main on the implications for the related ISO standard and providing some preliminary thoughts on how they might redesign the primitive. Until the details are finalised, it is too soon to draw any conclusions on the security of any redesigned scheme, though there have already been some discussions on Cryptography Stack Exchange [8]. Secondly, Blackburn and Robshaw [6] have posted a paper that cryptanalyses the ISO standard itself, rather then the more general underlying Algebraic Eraser primitive. Structure of the paper The remainder of the paper is organised as follows. Sections 2 and 3 establish notation, and describe the CBKAP. We describe a slightly more general protocol than the CBKAP, as our attack naturally generalises to a larger setting. We describe our attack in Section 4. In Section 5 we describe the results of our implementations and provide a short conclusion. 2 Notation This section establishes notation for the remainder of the paper. We closely follow the notation from [11], which is in turn mainly derived from the notation in [1], though we do introduce some new terms. 4 Let F be a finite field of small order (e.g., |F| = 256) and let n be a positive integer (e.g., n = 16). Let Sn be the symmetric group on the set {1, 2, . . . , n}, and let GLn (F) be the group of invertible n × n matrices with entries in F. Let M be a subgroup of GLn (F(t1 , . . . , tn )), where the elements ti are algebraically independent commuting indeterminates. Indeed, we assume that the group M is contained in the subgroup of GLn (F(t1 , . . . , tn )) of matrices whose determinant can be written as at for some non-zero element a ∈ F and some, possibly empty, word t in the elements ti and their inverses. Let M be the subgroup of GLn (F(t1 , . . . , tn )) generated by permuting the indeterminates of elements of M in all possible ways. Fix non-zero elements τ1 , . . . , τn ∈ F. Define the homomorphism ϕ : M → GLn (F) to be the evaluation map, computed by replacing each indeterminate ti by the corresponding element τi . Our assumption on the group M means that ϕ is well defined. The group Sn acts on M by permuting the indeterminates ti . Let M ⋊ Sn be the semidirect product of M and Sn induced by this action. More concretely, if we write g a for the action of an element g ∈ Sn on an element a ∈ M , then the elements of M ⋊ Sn are pairs (a, g) with a ∈ M and g ∈ Sn , and group multiplication is given by (a, g)(b, h) = (a g b, gh) for all (a, g), (b, h) ∈ M ⋊ Sn . Let C and D be subgroups of GLn (F) that commute elementwise: cd = dc for all c ∈ C and d ∈ D. The CBKAP specifies that C is a subgroup consisting of all invertible matrices of the form ℓ0 + ℓ1 κ + · · ·+ ℓr κr where κ is a fixed matrix, ℓi ∈ F and r ≥ 0. So C is the group of units in the F-algebra generated by κ. Moreover, the CBKAP specifies that D = C. But we do not assume anything about the forms of C and D in this paper, other than the fact that they commute. Let Ω = GLn (F) × Sn and let Sbn = M ⋊ Sn . We have two actions on Ω. Firstly, there is the right action of the group Sbn on Ω via a map ∗ : Ω × Sbn → Ω, as defined in [1, 11]. So (s, g) ∗ (b, h) = (sϕ(g b), gh) 5 for all (s, g) ∈ Ω and all (b, h) ∈ Sbn . Secondly, there is a left action of the group GLn (F) on Ω via the map • : GLn (F) × Ω → Ω given by matrix multiplication: x • (s, g) = (xs, g) for all x ∈ GLn (F) and all (s, g) ∈ Ω. Note that for all x ∈ GLn (F), all ω ∈ Ω and all b g ∈ Sbn we have that (x • ω) ∗ b g = x • (ω ∗ b g ). Also note that the left action is F-linear, in the sense that if x ∈ GLn (F) can be written in the form r X x= ℓ i ci i=1 for some ci ∈ GLn (F) and ℓi ∈ F, then for all (s, g) ∈ Ω we have x • (s, g) = r X ℓi (ci • (s, g)). i=1 To interpret the right hand side of the equality above: the subset of Ω whose second component is a fixed element of Sn is naturally an F-vector space, where addition and scalar multiplication takes place in the first component only. Finally, let A and B be subgroups of Sbn that ∗-commute: for all (a, g) ∈ A, (b, h) ∈ B and ω ∈ Ω, (ω ∗ (a, g)) ∗ (b, h) = (ω ∗ (b, h)) ∗ (a, g). 3 3.1 The CBKAP protocol Overview The CBKAP is unusual in that the parties executing it, Alice and Bob, use different parts of the public key in their computations: neither party 6 needs to know all of the public key. The security model assumes that one party’s public key material is known to the adversary: say Alice’s public key material is known, but Bob’s ‘public’ key (which is better thought of as part of his private key material) is not revealed. The adversary, Eve, receives just Alice’s public information, and the messages sent over the insecure channel. Security means that Eve cannot feasibly compute any significant information about K. The attack in [11] works in this model. The same is true for the attack we describe below. In a typical proposed application, the protocol might be used to enable a low-power device, such as an RFID tag, to communicate with a central server. Data on an RFID tag is inherently insecure, as is system-wide data. So the above security model is realistic (and conservative) for these application settings. 3.2 The protocol Public parameters (for Alice) include the parameters n, F, M, τ1 , . . . , τn , C and A. The groups M, C and A are specified by their generating sets. For efficiency reasons, the generators of the group A are written as words in a certain standard generating set for the group Sbn . We discuss this further in Section 5, but see the TTP algorithm in [1] for full information. It is assumed that Eve knows the parameters n, F, M, τ1 , . . . , τn , C and A. Bob needs to know the groups B and D, rather than the groups A and C. Eve does not need to know the subgroups B and D for our attack to work. We write e for the identity element of Sn . We write In for the identity matrix in GLn (F), and write 1 = (In , e) ∈ Ω. Alice chooses elements c ∈ C and b g = (a, g) ∈ A. She computes the product c•1∗b g = (cϕ(a), g) ∈ Ω and sends it to Bob over an insecure channel. Bob, who knows the groups B and D, chooses elements d ∈ D and b h = (b, h) ∈ B. He computes the product d•1∗b h = (dϕ(b), h) ∈ Ω and sends it to Alice over the insecure channel. 7 Note that cd = dc because c ∈ C and d ∈ D, and the groups C and D commute elmentwise. Thus, d • (c • 1 ∗ gb) ∗ b h = (dc) • (1 ∗ b g) ∗ b h = (cd) • (1 ∗ b g) ∗ b h = (cd) • (1 ∗ b h) ∗ b g (as b g ∈ A, b h ∈ B, and A and B ∗-commute) = c • (d • 1 ∗ b h) ∗ b g. The common key K is defined by K = d • (c • 1 ∗ b g) ∗ b h = c • (d • 1 ∗ b h) ∗ b g. Alice can compute the key K using the right hand expression in the equation above; Bob can compute K by computing the middle expression. 4 The proposed attack Eve, the adversary, sees all public information, and also sees the elements (p, g) := c • 1 ∗ b g ∈ Ω and (q, h) := d • 1 ∗ b h ∈ Ω that are transmitted between Alice and Bob. Eve’s goal is to compute the shared key. Rather than attempting to compute Alice’s private key material c and b g , or Bob’s private key material d and b g , our attack will recover the shared key directly. An overview of our attack is as follows. We first argue that the group C can be replaced by a ‘linearised’ version of C: this makes it easier to test membership in C. We then show that Eve does not need to compute Alice’s or Bob’s secret information in order to derive the shared key: more limited information suffices. (This information is specified in equations (1) and (2) below.) Finally, we show how Eve can compute this information. For a group H of n × n matrices over a field F, we write Alg(H) for the Falgebra generated by H [5]. So Alg(H) is the set of all F-linear combinations of matrices in H. We write Alg∗ (H) for the set of all invertible matrices in Alg(H). The groups C proposed in the CBKAP satisfy C = Alg∗ (C). More generally, we may assume that this is always the case. To see this, first note Alg∗ (C) and D commute elementwise since every element of Alg∗ (C) is a linear combination of elements in C. Thus, C may be replaced by Alg∗ (C) 8 to obtain a valid new instance of the protocol. Moreover, since C ⊆ Alg∗ (C) the new instance of the protocol is more general than the original protocol: Alice can choose her matrix c from the larger group Alg∗ (C). So if we successfully recover the common key in every new instance of the protocol, we can successfully recover the common key in the original instance. Thus, from now on, we assume that C = Alg∗ (C). Let κ1 , κ2 , . . . , κr ∈ C be a basis for Alg(C). Such a basis is not difficult to compute, using standard techniques. Our assumption means that any invertible linear combination of the matrices κi lies in C. Let P E A be the pure subgroup of A, defined by P = { (α, g) ∈ A : g = e }. Then ϕ(P ) is a subgroup of GLn (F). Consider the subgroup Alg∗ (ϕ(P )) of GLn (F). Concretely, an element α′ ∈ Alg∗ (ϕ(P )) is an invertible matrix of the form k X ′ ℓi ϕ(αi ) α = i=1 where k ≥ 0, ℓi ∈ F and (αi , e) ∈ P . Suppose that Eve finds elements c̃ ∈ C, α′ ∈ Alg∗ (ϕ(P )) and (ã, g) ∈ Sbn such that (p, g) = c̃ • (α′ , e) ∗ (ã, g). (1) Moreover, suppose that Eve can find an elements (αi , e) ∈ P and ℓi ∈ F such that k X ℓi ϕ(αi ) = α′ . (2) i=1 Then Eve can compute the common key, as follows. Firstly, she computes the matrix k X ′ ℓi ϕ(h αi ). β = i=1 This computation is possible for Eve, since h is part of the message (q, h) = (dϕ(b), h) ∈ Ω transmitted from Bob to Alice. Now, (αi , e) ∈ P ≤ A, and so (αi , e) ∗-commutes with all elements in B. Thus, (qϕ(h αi ), h) = d • 1 ∗ (b, h) ∗ (αi , e) = d • 1 ∗ (αi , e) ∗ (b, h). 9 Eve then computes c̃ • (qβ ′ , h) ∗ (ã, g). We claim that this is equal to the common key K. To see this, first note that (qβ , h) = k X ℓi (qϕ(h αi ), h) = i=1 k X ℓi (d • 1 ∗ (αi , e) ∗ (b, h)) = i=1 k X ℓi (dϕ(αi )ϕ(b), h) ′ i=1 = (d k X ℓi ϕ(αi )ϕ(b), h) i=1 ′ = (dα ϕ(b), h) = d • (α′ , e) ∗ (b, h). Hence c̃ • (qβ ′, h) ∗ (ã, g) = c̃ • d • (α′ , e) ∗ (b, h) ∗ (ã, g) = d • c̃ • (α′ , e) ∗ (b, h) ∗ (ã, g) (since c̃ ∈ C and d centralises C) = d • c̃ • (α′ , e) ∗ (ã, g) ∗ (b, h) (as (ã, g) ∈ A and (b, h) ∈ B ∗-commute) = d • (p, g) ∗ b h = d • (c • 1 ∗ b g) ∗ b h = K. So it suffices to show that Eve can find elements αi , ℓi , ã, c̃ and α′ so that Equations (1) and (2) are satisfied. Precomputation stage: Find the αi . Eve computes a collection of elements (αi , e) such that the matrices ϕ(αi ) form a basis of Alg(ϕ(P )). Once this is done, any α ∈ Alg∗ (ϕ(P )) can easily be written in the form (2). Eve does not need to know the messages (p, g) and (q, h) in this stage, so this stage can be carried out as a precomputation. Eve proceeds as follows. 10 Eve generates, as in [11], short products (a′ , g ′ ) of generators of A such that the order r of the permutation g ′ is small (n or less), and computes α1 = (a′ , g ′)r = (a′′ , e). She repeats this procedure to generate α2 , α3 . . .. (Eve may also take products of some of the previously generated elements (α1 , e), (α2 , e), . . . , (αi−1 , e) to define (αi , e).) Eve stops when the dimension of the F-linear span of the matrices ϕ(αi ) stops growing, and fixes a linearly independent subset of these matrices. At the end of this process (relabelling after throwing linearly dependent elements ϕ(αi ) away), Eve has α1 , α2 , . . . αr such that ϕ(α1 ), ϕ(α2 ), . . . , ϕ(αr ) are a basis for a subspace V of Alg(ϕ(P )). Indeed, we expect (with high probability) that V = Alg(ϕ(P )). We assume that this is true from now on. Stage 1: Find ã. Find a product of generators in A whose second component is equal to g, using the method in [11]. Let (ã, g) be this product. Define γ ∈ GLn (F) by (γ, e) = (p, g) ∗ (ã, g)−1. Stage 2: Find c̃. Recall that Eve knows κ1 , κ2 , κ3 , . . . , κr ∈ C that form a basis of Alg(C). She finds (see below) field elements x1 , x2 , . . . , xr ∈ F such that γ −1 (x1 κ1 + x2 κ2 + · · · + xr κr ) ∈ V, and x1 κ1 + x2 κ2 + · · · + xr κr is invertible. (3) (4) Set c̃ = x1 κ1 + x2 κ2 + · · · + xr κr . Since c̃ is an invertible element of Alg(C), we see that c̃ ∈ C. To find a solution to Equations (3) and (4), Eve randomly generates solutions xi that satisfy (3), which is easy, as the conditions are linear. She stops when (4) is also satisfied. We claim that the proportion of solutions to (3) that satisfy (4) is bounded below by 1 − n/|F|, which is a non-trivial proportion for the parameters that are proposed. The claim follows by applying the Invertibility Lemma [16, Lemma 9], which states that the proportion of invertible matrices in any F-subspace of matrices over F is at least 1 − (n/|F|), provided that the subspace contains at least one invertible matrix. We note that the elements of the form x1 κ1 + x2 κ2 + · · · + xr κr that satisfy (3) are a subspace of matrices. So it remains to show that there exists an invertible element of this form. But let x1 , x2 , . . . , xr ∈ F be such that 11 x1 κ1 + x2 κ2 + · · · + xr κr = c. The elements xi exist since c ∈ C ⊆ Alg(C). Clearly c̃ = c is invertible. Moreover (3) holds, because we may show that γ −1 c ∈ ϕ(P ) ⊆ V as follows. Firstly, (γ, e) = (p, g) ∗ (ã, g)−1 = (cϕ(a), g) ∗ ( g (ã−1 ), g −1) = (cϕ(a)ϕ(ã−1 ), e), −1 so γ = cϕ(a)ϕ(ã−1 ) and therefore γ −1 c = ϕ(ã)ϕ(a)−1 . And secondly, we see that ϕ(ã)ϕ(a)−1 = ϕ(ãa−1 ) ∈ ϕ(P ), since (ã, g)(a, g)−1 = (ã, g)( g a−1 , g −1) = (ãa−1 , e) −1 and (ã, g), (a, g) ∈ A. Stage 3: The remaining parameters. Eve sets α′ = c̃−1 γ. Since (α′ )−1 ∈ V , we see that α′ (being a power of (α′ )−1 ) also lies in V . So Eve can easily calculate coefficients ℓi such that k X ℓi ϕ(αi ) = α′ . i=1 Hence, Equation (2) holds. We may also verify that Equation (1) holds: c̃ • (α′ , e) ∗ (ã, g) = c̃ • (c̃−1 γ, e) ∗ (ã, g) = (γ, e) ∗ (ã, g) = ((p, g) ∗ (ã, g)−1) ∗ (ã, g) = (p, g). 5 Experiments and conclusion We have implemented our attack in Magma [7], running on one 2GHz core of a multi-core server. We used 5 sets of actual challenge parameters kindly provided by SecureRF. These parameters all used the values |F| = 256 and n = 16. The subgroup A is specified by a generating set; each generator for A is given as a word of length approximately 650 (notice the large parameter setting!) in the generating set X = { (xi (t), si ) : 1 ≤ i ≤ n − 1 } for M ⋉ Sn defined in [1]. In all 5 cases, our attack terminated successfully, producing the exact shared key. Our attack used less than 64MB of memory, and terminated in less than 8 hours. We would like to emphasise that our code is far from being optimised; we estimate an improvement in CPU time by a significant factor in an optimised version of the attack. 12 Let Bn be a braid group on n strands, and let σ1 , σ2 , . . . , σn−1 be the Artin generators for Bn . (See, for example, [12] for an introduction to braid groups.) There is a homomorphism ψ : Bn → M ⋉ Sn such that ψ(σi ) = (xi , si ) for 1 ≤ i ≤ n − 1, which gives rise to the coloured Burau representation. Thus we could (and did) use standard routines for computing with braids in Bn , rather than dealing with words in X directly. The most computationally intensive part of the attack is the computing of ϕ(a) where (a, g) ∈ M ⋉ Sn is given as a word in the generators of A. The long length of the generators in A as words in X is the cause of difficulty here; we were computing with words of length approximately 20,000 in Stage 1 of our attack. To decide when the precomputation stage should terminate, we use the criterion that the F-dimension of the algebra generated by the matrices ϕ(αi ) should not grow when 4 generators (αi , e) in a row are considered. Not surprisingly, this attack is highly parallelisable. We did not exploit this fact since for the actual parameters a single CPU core sufficed. It remains open how to immunise the Algebraic Eraser against the presented cryptanalysis. The only hope seems to be to make the problem of expressing a permutation as a short product of given permutations difficult, by working with very carefully chosen distributions. However, for the intended applications, the computational constraints necessitate small values of n. In this case, Schreier–Sims methods solve this problem efficiently, no matter how the permutations are used. See the discussion around [11, Table 4]. Acknowledgement The authors would like to thank Arkadius Kalka for providing code from the earlier attack [11] on the Algebraic Eraser, and for explaining how to use this code. The authors would also like to thank Martin Albrecht for various excellent editorial suggestions. References [1] I. Anshel, M. Anshel, D. Goldfeld and S. Lemieux, ‘Key agreement, the Algebraic Eraser™ and lightweight cryptography’, Contemporary Math- 13 ematics 418 (2006), 1–34. [2] I. Anshel, D. Atkins, D. Goldfeld and P. Gunnells, ‘Defeating the BenZvi, Blackburn, and Tsaban attack on the Algebraic Eraser’, IACR eprint 2016/044. [3] D. Atkins and P. Gunnells, ‘Algebraic Eraser™: A lightweight, efficient asymmetric key agreement protocol for use in nopower, low-power, and IoT devices’, presentation at the NIST Lightweight Cryptography Workshop, 20 July, 2015. http://www.nist.gov/itl/csd/ct/lwc_workshop2015.cfm [4] F. Bahr, M. Boehm, J. Franke, T. Kleinjung, ‘rsa200’. http://www.crypto-world.com/announcements/rsa200.txt. [5] A. Ben-Zvi, A. Kalka and B. Tsaban, ‘Cryptanalysis via algebraic spans’, IACR eprint 2014/041. [6] S.R. Blackburn and M.J.B. Robshaw, ‘On the security of the Algebraic Eraser tag authentication protocol’, ACNS 2016, to appear. IACR eprint 2016/091. [7] W. Bosma, J. Cannon and C. Playoust, ‘The Magma algebra system. I. The user language’, Journal of Symbolic Computation 24 (1997), 235– 265. [8] Cryptography Stack Exchange, ‘Status of Algebraic Eraser Key Exchange?’, http://crypto.stackexchange.com/questions/30644/status-of-algebraic-eraser-key retrieved on February 5, 2016. [9] D. Goldfeld and P. Gunnells, ‘Defeating the Kalka–Teicher–Tsaban linear algebra attack on the Algebraic Eraser’, Arxiv eprint 1202.0598, February 2012. [10] P. Gunnells, ‘On the cryptanalysis of the generalized simultaneous conjugacy search problem and the security of the Algebraic Eraser’, arXiv eprint 1105.1141, May 2011. [11] A. Kalka, M. Teicher and B. Tsaban, ‘Short expressions of permutations as products and cryptanalysis of the Algebraic Eraser’, Advances in Applied Mathematics 49 (2012), 57–76. 14 [12] C. Kassel and V. Turaev, Braid Groups, Graduate Texts in Mathematics 247, Springer, New York, 2008. [13] A. Myasnikov and A. Ushakov, ‘ Cryptanalysis of the Anshel-AnshelGoldfeld-Lemieux Key Agreement Protocol’, Groups Complexity Cryptology 1 (2009), 63–75. [14] National Institute of Stadards and Technology, ‘Digital Signature Standard (DSS)’, Federal Information Processing Standards Publication FIPS PUB 186-4, July 2013. http://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.186-4.pdf. [15] R. Rivest, A. Shamir and L. Adleman, ‘A method for obtaining digital signatures and public-key cryptosystems’, Communications of the ACM 21 (1978), 120–126. [16] B. Tsaban, ‘Polynomial-time solutions of computational problems in noncommutative algebraic cryptography’, Journal of Cryptology 28 (2015), 601–622. 15
4math.GR
arXiv:1802.10139v1 [math.AC] 27 Feb 2018 STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN Abstract. Using recent work by Erman-Sam-Snowden, we show that finitely generated ideals in the ring of bounded-degree formal power series in infinitely many variables have finitely generated Gröbner bases relative to the graded reverse lexicographic order. We then combine this result with the first author’s work on topological Noetherianity of polynomial functors to give an algorithmic proof of the following statement: ideals in polynomial rings generated by a fixed number of homogeneous polynomials of fixed degrees only have a finite number of possible generic initial ideals, independently of the number of variables that they involve and independently of the characteristic of the ground field. Our algorithm outputs not only a finite list of possible generic initial ideals, but also finite descriptions of the corresponding strata in the space of coefficients. 1. Introduction Grevlex series and Gröbner bases. Let A be a ring and let RA be the A-algebra of formal power series over A of bounded degree in the infinitely many variables x1 , x2 , . . .. In other words, each element of RA is a formal infinite sum X cα x α α∈NZ≥0 ,|α|≤d where d is some nonnegative integer and cα ∈ A for each sequence α = (α1 , α2 , . . .) of nonnegative integers whose sum |α| is (finite and) at most d. Addition and multiplication are as usual. We equip the polynomial ring RA with the graded reverse lexicographic order grevlex, in which xα > xβ if either |α| > |β| or |α| = |β| and the last non-zero entry of α − β is negative. So, for instance, the monomials of degree 3 are ordered as follows: x31 > x21 x2 > x1 x22 > x32 > x21 x3 > x1 x2 x3 > x22 x3 > x1 x23 > x2 x23 > x33 > x21 x4 > . . . To remind the reader that this is the only monomial order considered in this paper, we call the elements of RA grevlex series over A. If f is a nonzero element of R, then lm( f ) denotes the largest monomial that has a nonzero coefficient in f , lc( f ) denotes that coefficient, and lt( f ) = lc( f )lm( f ) is the leading term. The ring RA carries a unique topology in which a basis of open neighborhoods of f ∈ RA is given by all sets {g ∈ RA | lm( f − g) < xα } as α varies. Let L be a field. A Gröbner basis of an ideal I ⊆ RL is a subset B ⊆ I such that for each h ∈ L there exists an f ∈ B with lm( f )|lm(h). We do not require that B be finite. As in the classical setting, a Gröbner basis B of I generates I as an ideal (Lemma 7). Our first main result is the following. JD is partially supported by a Vici grant from the Netherlands Organisation for Scientific Research (NWO). Research of AL is supported in part by DMS-1719968 award from NSF. 1 2 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN Theorem 1. For every field L, every finitely generated homogeneous ideal in the ring RL has a finite Gröbner basis with respect to grevlex. The analogous statement certainly does not hold for all monomial orders: in [Sne98a, Appendix A.2] it is shown that the ideal generated by a generic quadric and a generic cubic has a non-finitely generated initial ideal relative to the lexicographic order. Theorem 1 implies a positive answer to [Sne98b, Question 7.1]; in that paper P a positive answer is given in the case where the ideal is generated by series |α|=di ci,α xα , i = 1, . . . , k whose coefficients (ci,α )i∈[k],|α|=di are algebraically independent over the prime field of L. The natural question arises whether a Gröbner basis as in the theorem can be computed in finite time. A straightforward variant SeriesBuchberger of Buchberger’s algorithm shows that this would, indeed, be the case—if only we could work effectively with infinite series. Next we focus S on the following setting where we can indeed work with such series. Let S∞ = n Sn be the union of all symmetric groups, and let S>n be the subgroup of all permutations fixing 1, . . . , n elementwise. Suppose that we are given an action of S>n0 on A by means of ring automorphisms, and let S>n0 act on the variables x1 , x2 , . . . via πxi = xπ(i) . This action extends to an action of S>n0 by (continuous) ring automorphisms on RA via   X  X −1 α π  cα x  = π(cα )xα◦π . α α We call an f ∈ RA eventually invariant if there exists an n ≥ n0 such that π( f ) = f for all π ∈ S>n . To specify an eventually invariant grevlex series we need only a finite number of coefficients: if f is invariant under S>n and has degree d, then S>n has only finitely many orbits on monomials in x1 , x2 , . . . of degree at most d—the grevlexlargest element in each orbit is of the form xα where α(n + 1) ≥ α(n + 2) ≥ . . .. Then f is uniquely determined by its coefficients on these grevlex-largest representatives P P xα1 , . . . , xαs . We call fˆ := si=1 cαi xαi the n-representation of f = α cα xα . Often we will suppress n from this notation. Theorem 2. Suppose that A = L is a field. There exist a finite algorithm that on input a finite list fˆ1 , . . . , fˆk of representations of eventually invariant grevlex series f1 , . . . , fk outputs a finite list ĝ1 , . . . , ĝl representing an eventually invariant Gröbner basis g1 , . . . , gl of h f1 , . . . , fk iRL . Stillman’s conjecture. The condition of eventual invariance seems rather restrictive, but it is tailored to a proof of the following theorem. Theorem 3. There exists a finite algorithm that on input k ∈ Z and d1 , . . . , dk ∈ Z≥0 outputs a finite sequence S1 , . . . , St , each Si a finite set of monomials in the x j , such that the following holds: For every infinite field K, all n ∈ N, and all homogeneous polynomials f1 , . . . , fk ∈ K[x1 , . . . , xn ] of degrees d1 , . . . , dk , respectively, the generic grevlex initial ideal of h f1 , . . . , fk iK[x1 ,...,xn ] equals hSi iK[x1 ,...,xn ] for some i. In short: ideals in polynomial rings generated by homogeneous polynomials of degrees d1 , . . . , dk have only finitely many possible generic initial ideals, independently of the number of variables. Via [Eis95, Corollary 19.11], which is based on [BS87], this implies that the projective dimension of an ideal generated by homogeneous forms of fixed degrees but in an arbitrary number of variables and in STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS 3 arbitrary characteristic is uniformly bounded. This is Stillman’s conjecture from the title; see [PS09]. This is the fourth proof of Stillman’s conjecture, after the first proof by AnanyanHochster [AH16] and two recent proofs by Erman-Sam-Snowden [ESS18]. Our proof is the same in spirit as the second proof in the latter paper in that it uses Draisma’s theorem on topological Noetherianity of polynomial functors [Dra17]. However, unlike the second proof in [ESS18] (but like the first proof there, and like Ananyan-Hochster’s proof), our theorem yields S1 , . . . , St that are valid in all characteristics. Also, our theorem is constructive in the sense that we give an algorithm for computing the possible initial ideals and the corresponding strata given by equations and disequations for field characteristics and coefficients of the input series. All these are represented finitely. In [ESS18] the authors raise the question whether a version over Z of Draisma’s theorem holds, as this would also make their second proof characteristic-independent. We do not settle this question. Instead, the algorithm of Theorem 3 simulates a generic ideal computation in all characteristics, branching along constructible subsets of Spec Z whenever necessary. We argue that, if there were an infinite branch in this computation, then this branch would also be infinite over some field; and that this would contradict Draisma’s theorem over that field. In [ESS17] (see also [DES17, Theorem 1.9]), using Stillman’s conjecture and Draisma’s theorem, the same authors establish a generalization of Stillman’s conjecture to ideal invariants that are upper semicontinuous in flat families and preserved under adding a variable to the polynomial ring. Organization. This paper is organized as follows. In Section 2 we prove Theorem 1 using work from [ESS18]. In Section 3 we use this existence result to prove that a version of Buchberger’s algorithm for eventually invariant series terminates; this yields Theorem 2. In Section 4 we review topological Noetherianity of a specific polynomial functor, which follows from [Dra17]. Finally, in Section 5 we derive Theorem 3 from Theorem 2 and Draisma’s theorem. 2. The existence of finite Gröbner bases We will use two results from [ESS18], the first of which is the following. Theorem 4 (Theorem 1.2 from [ESS18]). If L is perfect, then RL contains (uncountably many) homogeneous elements (g j ) j∈J such that the unique L-algebra homomorphism L[(x j ) j∈J ] → RL sending x j to g j is an L-algebra isomorphism. (n) For each n ∈ Z≥0 we write RL := L[x1 , . . . , xn ]. There is a natural L-algebra homomorphism RL → R(n) , f 7→ f (n) that retains only the terms involving only the L variables x1 , . . . , xn . We may think of a degree-at-most-d element of RL as a sequence (n) ( f (0) , f (1) , . . .) in which each f (n) is a polynomial in RL of degree at most d such that f (n) is the image of f (n+1) under discarding all terms divisible by xn+1 . Conversely, (n) RL is an L-subalgebra of RL . Observe that, for any f ∈ RL and n ∈ Z≥0 , the image (lm( f ))(n) is either zero or equal to lm( f (n) ) in the grevlex order on L[x1 , . . . , xn ]. Theorem 5 (Theorem 5.4 from [ESS18]). A sequence g1 , . . . , gl ∈ RL of homogeneous (n) (n) (n) elements is a regular sequence in RL if and only if g1 , . . . , gl is a regular sequence in RL for all n ≫ 0. 4 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN The following lemma is straightforward from [ESS18, Section 5], but we include its proof using the two results above. Lemma 6. Let f1 , . . . , fk ∈ RL . Then the natural map between first syzygies (n+1) SyzR(n+1) ( f1 L (n+1) , . . . , fk (n) (n) ) → SyzR(n) ( f1 , . . . , fk ) L is surjective for all n ≫ 0. Proof. This surjectivity is not affected by enlarging the field, so we may assume that L is perfect. By Theorem 4, there exist homogeneous g1 , . . . , gl ∈ RL such that f1 , . . . , fk ∈ L[g1 , . . . , gl ] and such that g1 , . . . , gl are part of a system of variables for the polynomial ring RL . In particular, they are a regular sequence in RL , and hence by Theorem 5 the polynomials g(n) , . . . , g(n) are a regular sequence in R(n) 1 L l (n) (n) for n ≫ 0. We draw two conclusions from this. First, for n ≫ 0, g1 , . . . , gl algebraically independent over L, A (n) := (n) L[g1 , . . . , (n) gl ], (n) (n) f1 , . . . , fk are are elements of the polynomial ring and SyzA(n+1) ( f1(n+1) , . . . , fk(n+1) ) → SyzA(n) ( f1(n) , . . . , fk(n) ) is a bijection. Second, still for n ≫ 0, R(n) is a free module over A(n) . Therefore, (n) (n) (n) (n) SyzA(n) ( f1 , . . . , fk ) ⊆ (A(n) )k generates SyzR(n) ( f1 , . . . , fk ) ⊆ (R(n) )k as an R(n) module. Combining these two statements we find the surjectivity claimed in the lemma.  Proof of Theorem 1. Let f1 , . . . , fk ∈ RL be nonzero, homogeneous, and let n ∈ Z≥0 . Set I := h f1 , . . . , fk i ⊆ RL . Consider a monomial u ∈ lm(I) ∩ R(n+1) divisible by xn+1 . There exist homogeneous a1 , . . . , ak ∈ R(n) with deg(ai ) = deg(u) − deg( fi ) and homogeneous b1 , . . . , bk ∈ R(n+1) with deg(bi ) = deg(u) − deg( fi ) − 1 such that u = lm((a1 + b1 xn+1 ) f1(n+1) + · · · + (ak + bk xn+1 ) fk(n+1) ). (n) (n) Now (a1 , . . . , ak ) ∈ SyzR(n) ( f1 , . . . , fk )—otherwise, the right-hand side would equal P (n) lm( i ai fi ), which is not divisible by xn+1 . By Lemma 6, if n ≫ 0, the syzygy (n+1) (n+1) (a1 , . . . , ak ) can be lifted to a syzygy (c1 , . . . , ck ) ∈ SyzR(n+1) ( f1 , . . . , fk ). Write L ci = ai + xn+1 b′i for each i. Then (n+1) u = lm((b1 − b′1 )xn+1 f1 + · · · + (bk − b′k )xn+1 f (n+1) ), but then we see that u/xn+1 ∈ lm(I). Hence for n ≫ 0, lm(I) does not contain minimal generators divisible by xn+1 . It follows that for such an n, lm(I) is generated by any finite generating list m1 , . . . , mt of lm(I(n) ). Now h1 , . . . , ht ∈ I such that lm(hi ) = mi form a Gröbner basis of I.  Buchberger’s algorithm for grevlex series To turn Theorem 1 into an algorithm, we derive a version of Buchberger’s algorithm. Lemma 7 (Division with remainder). Let f1 , . . . , fk ∈ RL be monic and h ∈ RL . Then there exist q1 , . P . . , qk ∈ RL such that lm(qi fi ) ≤ lm(h) for all i and such that no term of the remainder h − i qi fi is divisible by any lm( fi ). STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS 5 In particular, if f1 , . . . , fk is a Gröbner basis of the ideal that they generate, then the remainder must be zero. Proof. Initialize r := h and qi := 0 for all i. While some term of r is divisible by some lm( fi ), pick the grevlex-largest such term cxα in r, subtract c(xα /lm( fi )) fi from r and add cxα /lm( fi ) to qi . This does not change terms in qi larger than the term just added, and hence in the product topology on RkL the vector q converges a solution vector q as desired.  function SeriesBuchberger( f1 , . . . , fk ) assume f1 , . . . , fk ∈ RL homogeneous grevlex series. m := 1; B := ∅ (the basis); Q := { f1 , . . . , fk } (the queue); while Q , ∅ do while Q contains an f with f (m) , 0 do Q := Q \ { f }; f := f /lc( f ); B := B ∪ { f }; for h ∈ B \ { f } do γ := lcm(lm(h), lm( f )); s := (γ/lm(h))h − (γ/lm( f )) f ; compute a remainder r of s after division by B; if r , 0 then Q := Q ∪ {r}; end if; end for; end while; m := m + 1; end while; return B; end function Proposition 8. Assuming an implementation for addition, multiplication, and division with remainder of grevlex series, SeriesBuchberger on page 5 terminates after a finite number of steps and outputs a Gröbner basis of the ideal generated by the series in the input. Proof. Fix any natural number n. The loops with m ranging from 1 to n really (n) (n) compute a Gröbner basis for I := h f1 , . . . , fk i while dragging the tails of the series along. In particular, these n loops terminate. If an element is added to the (n) queue Q in the (n + 1)st run of the loop, then this implies that lm(I) ∩ RL does not generate lm(I). By Theorem 1, this cannot happen infinitely often, so the algorithm terminates. That the output is, indeed, a Gröbner basis, follows from the ordinary Buchberger criterion.  3. Buchberger’s algorithm for eventually invariant series Recall that S>n0 acts on L, on variables, and on RL . Given representations fˆ1 , . . . , fˆk of eventually invariant f1 , . . . , fk ∈ RL , we want to compute the representation of an eventually invariant Gröbner basis of I := h f1 , . . . , fk i. 6 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN The first ingredient in our variant of Buchberger’s algorithm is an analogue of Lemma 7. Lemma 9 (Division with remainder on representations.). Let f1 , . . . , fk ∈ RL be monic and h ∈ RL . Assume that h, f1 , . . . , fk , lm( f1 ), . . . , lm( fk ) are invariant under S>n . Then q1 , . . . , qk and r from Lemma 7 can be chosen S>n -invariant, and the representations q̂1 , . . . , q̂k , r̂ can be effectively computed from ĥ, fˆ1 , . . . , fˆr . Proof. Set r := h. While some term of r is divisible by some lm( fi ), pick the grevlexlargest such term cxα in r, let xα1 , xα2 , . . . be the (countably infinite) orbit of xα under S>n and each i let ci be the coefficient of xαi in r. Since r is S>n -invariant, so is P for αi a := i ci x . Moreover, as lm( fi ) is S>n -invariant, a is divisible by lm( fi ). Replace r by r − (a/lm( fi )) fi and qi by qi + (a/lm( fi )); each of these are S>n -invariant. This does not effect the terms of r larger than xα and gets rid of this particular term. In this process, r and the qi remain S>n -invariant and converge to series as in Lemma 7. For effectiveness, we need to be able to compute the representation of r − (a/lm( fi )) fi from r̂, â = cxα , and fˆi . The representation depends linearly on the series, so it suffices to have a procedure for computing the representation of a product. The function Product does just that—it uses that no monomial of degree e that is grevlex-maximal in its S>n -orbit contains any of the variables xn+e+1 , xn+e+2 , . . ..  function Product(n, fˆ, ĥ) input: n-representations fˆ, ĥ of S>n -invariant series f, h. output: n-representation fbh of f h. e := deg f + deg h; compute the truncations f (n+e) , h(n+e) from fˆ, ĥ; u := f (n+e) h(n+e) ; remove all terms in u not grevlex-maximal in their S>n -orbit; return u; end function function Remainder(n, ĥ, { fˆ1 , . . . , fˆk }) input: n-representations ĥ, fˆ1 , . . . , fˆk of S>n -invariant series, with fˆi monic and lm( fˆi ) S>n -invariant; output: the n-representation of a remainder of h after division by f1 , . . . , fk . assume lm( fˆ1 ), . . . , lm( fˆk ) are S>n -invariant. r̂ := ĥ; while r̂ contains a term cxα divisible by some lm( f̂i ) do r̂ := r̂−Product(cxα/lm( fˆi ), x fˆi ); end while; return r̂; end function The next ingredient is S-series: if f, g are monic S>n -invariant series whose leading monomials are also S>n -invariant, and xγ = lcm(lm( f ), lm(g)), then we set S( f, g) := (xγ /lm( f )) f − (xγ /lm(g))g. We note that S( f, g) is also S>n -invariant, and STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS 7 the n-representation of S( f, g) can be computed from the n-representations fˆ, ĝ, as follows. function S(n, fˆ, ĝ) input: n-representations fˆ, ĝ of monic S>n -invariant series with lm( fˆ), lm( ĝ) S>n -invariant. output: n-representation of S( f, g). xγ := lcm(lm( fˆ), lm( ĝ)); ŝ := (xγ /lm( fˆ)) fˆ − (xγ /lm( ĝ)) ĝ; return ŝ; end function P From the n-representation fˆ = si=1 cαi xαi of an S>n -invariant grevlex series one can compute the m-representation f˜ with m > n as follows. For each i = 1, . . . , s, the group S>m has only finitely many orbits on S>n xαi . Let xβi1 , . . . , xβisi be the grevlexmaximal representatives of these orbits, and let πi1 , . . . , πisi ∈ S>m be such that πi j xαi = xβi j . Then define si s X X f˜ := πi j (cαi )xβi j . i=1 j=1 We call f˜ the m-expansion of fˆ. So we may freely increase n when desirable; we will use this to ensure that the leading monomial of f is S>n -invariant. function SymmetricBuchberger(n, fˆ1, . . . , fˆk ) input: n-representations fˆ1 , . . . , fˆk S>n -invariant series. output: the m-representation of a Gröbner basis of h f1 , . . . , fk i for some m ≥ n. m := n; B̂ := ∅ (the basis); Q := { fˆ1 , . . . , fˆk } (the queue); while Q , ∅ do while Q contains an fˆ with fˆ(m) , 0 do Q := Q \ { fˆ}; fˆ := fˆ/lc( fˆ); B̂ := B̂ ∪ { fˆ}; for ĥ ∈ B̂ \ { fˆ} do r̂ :=Remainder(m,S(m, ĥ, fˆ), B̂); end for; if r̂ , 0 then Q := Q ∪ {r̂}; end if; end while; Replace B̂ and Q̂ by their (m + 1)-expansions; m := m + 1; end while; return B̂; end function 8 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN Proof of Theorem 2. The algorithm SymmetricBuchberger above called with arguments (n, fˆ1 , . . . , fˆk ) performs the same operations as the algorithm SeriesBuchberger on page 5 on input ( f1 , . . . , fk ), except that it works with finite data structures capturing the series fi . Hence Proposition 8 implies both the termination and the fact that the output of SymmetricBuchberger is the representation of a Gröbner basis of h f1 , . . . , fk i.  Remark 10. Should one consider implementing SymmetricBuchberger, it may be practical to allow series to have m-representations with varying values of m, as opposed to the uniform m for every iteration of the outer loop above. In order to perform binary operations, i.e., additions and multiplications, representations would then need to be expanded to a matching value of m. Furthermore, to ensure termination, the order of S-pairs needs to ensure that each leading monomial is eventually encountered. In SymmetricBuchberger, this is done by increasing m only after all the leading monomials in x1 , . . . , xm have been collected. 4. A polynomial functor Let K be an infinite field. Let GLn (K) act on the space Kn with basis x1 , . . . , xn by left multiplication, and for each d ∈ Z≥0 on the d-th symmetric power Sd Kn in the natural manner. Fix d1 , . . . , dk ∈ Z≥0 and set P(n) (K) := Sd1 Kn ⊕ · · · ⊕ Sdk Kn , the space of forms of degrees d1 , . . . , dk in n variables. Now define P(K) := lim←n P(n) (K), where the maps come from the projection Kn+1 → Kn forgetting the last coordinate. The space P(K) is the subspace of (RK )k consisting of all tuples where the i-th element is homogeneous of degree di for each i ∈ [k]. Dually, let V := limn→ (P(n) (K))∗ . Then V is a countable-dimensional space, P(K) is canonically isomorphic to V ∗ , and hence K[P] := SV, the symmetric algebra on V, serves as a coordinate ring of P(K) in that the set of K-algebra homomorphisms K[P] → K is canonically identified with P(K). We equip P(K) with the Zariski topology in which closed subsets are characterized by polynomial S equations from K[P]. Both P(K) and V are naturally a module for GL∞ (K) := n GLn (K), and so is K[P]. The following is an instance of a general result on polynomial functors from [Dra17]. Theorem 11. Let K be an infinite field, and fix integers d1 , . . . , dN . Then any chain P(K) ⊇ X1 ⊇ · · · of GL∞ (K)-stable Zariski-closed subsets stabilizes eventually. Equivalently, any sequence a1 , a2 , a3 , . . . in K[P] has the property that for t ≫ 0 we have v u t* t−1 + [ GL∞ (K)ai . at ∈ i=1 Remark 12. Two comments are in order. First, the implication ⇒ between the two statements in the theorem follows from the Nullstellensatz, since the first sentence also holds for any algebraic closure of K. Second, each ai is an element of K[P(ni ) ] for some finite ni . If n ≥ maxi∈[t] ni , then the property of at above is equivalent to v u t* t−1 + [ GLn (K)ai , at ∈ i=1 STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS 9 where we have replaced ∞ by n. 5. Finitely many generic initial ideals We now prepare for the proof of Theorem 3. For i = 1, . . . , k let fi be the homogeneous degree-di series X ci,α xα fi = |α|=di whose coefficients live in the polynomial ring A = Z[ci,α | i ∈ [k], α ∈ ZN ≥0 , |α| = di ] in which the ci,α are variables. We note that if K is a field, then K⊗A is the coordinate ring K[P] of the space P(K) introduced in Section 4. On A acts S∞ via ring automorphisms determined by πci,α = ci,α◦π−1 , and each fi is S∞ -invariant. In the 0-representation fˆi of fi , we have X fˆi = ci,α xα , |α|=di ,α(1)≥α(2)≥... a polynomial with as many terms as there are partitions of di . Write A(n) for the subring of A generated by those ci,α such that ∀m > n : α(m) = 0. P Let g be an n × n-matrix of variables. Replacing, in fi , each xh with h ≤ n by j gh j x j and each xh with h > n by xh yields a series g fi in the xh whose coefficients are polynomials that are linear in the ci,α and homogeneous of degree di in the gh j . We use the formal notation g−1 ci,α for the coefficient of xα in g fi . This notation is chosen so that if we specialize g to be the matrix of a permutation π ∈ Sn , then g−1 ci,α specializes to π−1 ci,α in the Sn -action above. For a polynomial r = r(c) ∈ A (in the ci,α with varying i and α) write g−1 r ∈ Z[gh j | h, j ∈ [n]] ⊗Z A for the polynomial obtained by replacing each ci,α with g−1 ci,α . Regarding g−1 r as a polynomial in the entries gh j whose coefficients are in A, we write En (r) ⊆ A for the set of all nonzero coefficients. It is easy to see that if r ∈ A(n) , then also En (r) ⊆ A(n) . The following easy lemma explains the significance of this construction. Lemma 13. If K is an infinite field, then the K-span of the orbit of 1 ⊗ r ∈ K ⊗Z A under GLn (K) equals the K-span of 1 ⊗ En (r(c)).  Proof of Theorem 3. In the recursive variant Stillman of SymmetricBuchberger on page 10, we write Fp , where p is either zero or a prime, for the prime field of characteristic p. We prove that Stillman terminates on input (0, ∅, { fˆ1 , . . . , fˆd }, Spec(Z), ∅, ∅) and that it prints out the sets Si as in the theorem. First we clarify the role of the variables. The symbols m, B̂, Q̂ carry the same meaning as in SymmetricBuchberger. The current run considers only primes in the set Y ⊆ Spec(Z). Furthermore, it deals with the specializations of the truncations (m) (m) f1 , . . . , fk with coefficients in s* + [ (m) (m) −1 Em (r) . Ā := A [N ]/ r∈Z 10 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN procedure Stillman(n, B̂, Q̂, Y, Z, N) m := n; Q := Q \ {0}; while Y , ∅ and Q̂ , ∅ do while Y , ∅ and Q̂ contains an fˆ with fˆ(m) , 0 do Q̂ := Q̂ \ { fˆ}; b := lc( fˆ) ∈ A[N−1 ]; a :=numerator(b) ∈q A;   S Y1 := (p) ∈ Y : a ∈ h r∈Z Em (r)iFp ⊗A(m) [N−1 ] ; Stillman(m, B̂, Q̂ ∪ { fˆ − lt( fˆ)}, Y1 , Z, N); Y := Yn \ Y1 ; o S Y2 := (p) ∈ Y : 1 < h r∈Z∪{a} Em (r)iFp ⊗A(m) [N−1 ] ; Stillman(m, B̂, Q̂ ∪ { fˆ − lt( fˆ)}, Y2 , Z ∪ {a}, N); fˆ := fˆ/b; N := N ∪ {a}; B̂ := B̂ ∪ { fˆ}; for ĥ ∈ B̂ \ { fˆ} do r̂ :=Remainder(m,S(m, ĥ, fˆ), B); if r̂ , 0 then Q̂ := Q̂ ∪ {r̂}; end if; end for; end while; Replace B and Q̂ by their (m + 1)-expansions; m := m + 1; end while; if Y , ∅ then print lm(B̂); end if; end procedure (I) (II) We discuss the computations of Y1 , Y2 . For Y1 , one starts running the ordinary Buchberger algorithm on the ideal in the S localization A(m) [N−1 ][t] generated by r∈Z Em (r) and ta − 1 (Rabinowitsch’ trick), where t is an auxiliary variable. Whenever an integer leading coefficient is divisible by a nonzero prime (p) in Y, the algorithm branches into a branch where multiples of p are zero and a branch where p is invertible. Assuming that Y is constructible to begin with, each leaf of this finite tree yields a constructible set of primes leading to that leaf, and Y1 is the union of the primes corresponding to leaves where the aforementioned ideal contains 1. A similar algorithm is used to compute Y2 . Since we start with Y = Spec Z, it follows that in any of the further calls of Stillman the set Y is constructible. In other words, Y is either a finite set of nonzero primes in Spec(Z) or a cofinite set in Spec(Z) containing (0). STILLMAN’S CONJECTURE VIA GENERIC INITIAL IDEALS 11 Furthermore, in each run of Stillman, for each (p) ∈ Y, the algebra Fp ⊗ Ā(m) has 0 , 1. This is true at the initial call, it remains true in call (I) since m, Z, N do not change, and it remains true in call (II) since we explicitly test for this condition. Furthermore, it remains true later in the loop, since there we have already removed from Y the primes in Y1 , which are those where inverting a would cause the algebra to collapse. Let T be the rooted tree whose vertices are the runs of Stillman and whose edges are labelled (I) or (II) according to which call in the algorithm leads from one run to the other. We claim that every path in T away from the root is finite. Indeed, consider an infinite path γ in T. The argument Y remains nonempty and weakly decreases along γ and since it is locally closed in Spec(Z), exists a prime (p0 ) ∈ Spec Z that is in the intersection of all the arguments Y along γ. If infinitely many edges in γ are labelled (II), then Z records a1 , a2 , a3 , . . . with ai ∈ A(mi ) and m1 ≤ m2 ≤ . . . and q ai < Eni (a1 ) ∪ · · · ∪ Eni (ai−1 ) Fp0 ⊗A(mi ) for all i = 1, 2, 3, . . . By Lemma 13 and Remark 12 this contradicts the Noetherianity of K[P] over any infinite field K of characteristic p0 (Theorem 11). Hence only finitely many edges in γ are labelled (II). We analyse the computation along γ beyond the last edge e labelled (II). Let m∞ ∈ N ∪ {∞} be the supremum of the values of m along γ, let Z0 be the (fixed) value of Z along γ from e onwards, and let N∞ the union of all N’s seen along γ. Define s* à := Fp0 ⊗ −1 A[N∞ ]/ [ + Em (r) . m≤m∞ ,r∈Z By construction, 1 , 0 in Ã, hence there exists an epimorphism from à to some field L of characteristic p0 . Then the call of SeriesBuchberger with input the images of the fi in RL performs the same operations as the algorithm Stillman along γ. Since the former algorithm terminates by Proposition 8, so does the latter. We conclude that T is finite. Let K be an infinite field, n a natural number, and let f1′ , . . . , fk′ be homogeneous polynomials in K[x1 , . . . , xn ] of degrees d1 , . . . , dk , respectively. We claim that, at the leaf of some path γ in T away from the root, generators for the generic initial ideal of h f1′ , . . . , fk′ i are printed. To see this, let g ∈ GLn be an n × n-matrix of variables, set L := K((gh j )h, j ), and consider the ideal J in L[x1 , . . . , xn ]Pgenerated by the polynomials g f1′ , . . . , g fk′ obtained by replacing xh in each fi′ by h gh j x j . Then the generic initial ideal of h f1′ , . . . , fk′ i ⊆ K[x1 , . . . , xn ] equals the initial ideal of J, and the latter is computed by Buchberger (or SymmetricBuchberger) on input (n and) g f1′ , . . . , g fk′ . To find γ, proceed as follows: whenever a ∈ A is defined as the numerator of a leading coefficient of fˆ, check if under the specialization fi 7→ g fi′ the element a specializes in K to zero or to a nonzero element. If a specializes to zero, then follow call (I) or call (II) according as (char K) ∈ Y1 or not. If a does not specialize to zero, then follow neither of these calls and continue with the loop. Along this γ, Stillman performs the same operations as SeriesBuchberger, and hence terminates with the generic initial ideal of h f1′ , . . . , fk′ i.  12 JAN DRAISMA AND MICHAŁ LASOŃ AND ANTON LEYKIN Remark 14. Apart from printing lm(B̂) at each leaf of T we may also print Y, Z, N, which together describe a locally closed stratum of P(K), for any infinite K with (char K) ∈ Y, consisting of k-tuples with generic initial ideal generated by lm(B̂). Acknowledgements. The authors thank Institut Mittag-Leffler for the hospitality during their stay in the early 2018. The first author thanks Diane Maclagan, who introduced Stillman’s conjecture to him many years ago and suggested that it might be related to Noetherianity up to symmetry. The third author thanks MSRI for the Fall of 2017 stay, during which “The Fellowship of the Ring” and Craig Huneke rekindled his interest in Stillman’s conjecture. Last but the most, the thanks go to Gennady Lyubeznik and Mike Stillman. When they both were 40 years young, Gennady suggested a problem that involved a certain constructible stratification and Mike helped solving it via parametric Gröbner bases. The intuition gained 20 years ago was instrumental in the present work. References [AH16] [BS87] [DES17] [Dra17] [Eis95] [ESS17] [ESS18] [PS09] [Sne98a] [Sne98b] Tigran Ananyan and Melvin Hochster. Small subalgebras of polynomial rings and Stillman’s conjecture. 2016. Preprint, arXiv:1610.09268. David Bayer and Michael Stillman. A theorem on refining division orders by the reverse lexicographic order. Duke Math. J., 55:321–328, 1987. Harm Derksen, Rob Eggermont, and Andrew Snowden. Topological noetherianity for cubic polynomials. Algebra Number Theory, 11(9):2197–2212, 2017. Jan Draisma. Topological Noetherianity of polynomial functors. 2017. Preprint, arXiv:1705.01419. David Eisenbud. Commutative Algebra. With a View toward Algebraic Geometry, volume 150 of Graduate Texts in Mathematics. Springer-Verlag, Berlin, 1995. Daniel Erman, Steven Sam, and Andrew Snowden. Generalizations of Stillman’s conjecture via twisted commutative algebra. 2017. Preprint, http://www-personal.umich.edu/˜asnowden/papers/genstillman-071517.pdf. Daniel Erman, Steven V. Sam, and Andrew Snowden. Big polynomial rings and Stillman’s conjecture. 2018. Preprint, arXiv:1801.09852. Irena Peeva and Mike Stillman. Open problems on syzygies and Hilbert functions. J. Commut. Algebra, 1(1):159–195, 2009. Jan Snellman. Gröbner bases and normal forms in a subring of the power series ring on countably many variables. J. Symb. Comput., 25(3):315–328, 1998. Jan Snellman. Reverse lexicographic initial ideals of generic ideals are finitely generated. In Gröbner bases and applications. Based on a course for young researchers, January 1998, and the conference “33 years of Gröbner bases”, Linz, Austria, February 2–4, 1998, pages 504–518. Cambridge: Cambridge University Press, 1998. (Jan Draisma) Mathematical Institute, University of Bern, Sidlerstrasse 5, 3012 Bern, Switzerland; and Eindhoven University of Technology, The Netherlands E-mail address: [email protected] (Michał Lasoń) Mathematical Institute, University of Bern, Sidlerstrasse 5, 3012 Bern, Switzerland; Institute of Mathematics of the Polish Academy of Sciences, ul.Śniadeckich 8, 00-656 Warszawa, Poland E-mail address: [email protected] (Anton Leykin) School of Mathematics, Georgia Institute of Technology, Atlanta, GA 303320160, USA E-mail address: [email protected]
0math.AC
arXiv:1601.07227v1 [math.NA] 26 Jan 2016 A network that learns Strassen multiplication Veit Elser Cornell University Abstract We study neural networks whose only non-linear components are multipliers, to test a new training rule in a context where the precise representation of data is paramount. These networks are challenged to discover the rules of matrix multiplication, given many examples. By limiting the number of multipliers, the network is forced to discover the Strassen multiplication rules. This is the mathematical equivalent of finding low rank decompositions of the n × n matrix multiplication tensor, Mn . We train these networks with the conservative learning rule, which makes minimal changes to the weights so as to give the correct output for each input at the time the input-output pair is received. Conservative learning needs a few thousand examples to find the rank 7 decomposition of M2 , and 105 for the rank 23 decomposition of M3 (the lowest known). High precision is critical, especially for M3 , to discriminate between true decompositions and “border approximations”. 1 Introduction The current surge of activity in machine learning with neural networks, far from being a fad, is a response to hard empirical evidence. The powers of discrimination, generalization, and abstraction exhibited by these networks matches and often outperforms humans. At the same time, from a theoretical perspective, we know that the core representation of knowledge by these networks is only approximate. The representation of images as compositions of non-negative features, for example, works well only until the images become unnatural. While synthetic data avoids this shortcoming, the allure of the network is diminished when the learned knowledge is not new or surprising. Questions related to the Strassen algorithm [S] for matrix multiplication provide an opportunity for testing neural networks in the interesting setting where the 1 representation of knowledge is both exact and poorly understood by humans (an open mathematical problem). In this short contribution we define Strassen multiplication (SM) in engineering terms, construct a neural network that has the capacity to implement SM, introduce a simple protocol for training the network called conservative learning, and finish with the mandatory presentation of spectacular results. 2 What is Strassen multiplication? In 1969 Volker Strassen published a paper [S] that showed, among other things, that a pair of 2 × 2 matrices could be multiplied with just seven scalar multiplications, one less than the eight required in the standard algorithm. Strassen’s trick becomes practical on very large matrices where it can be applied recursively on blocks, and finding the fewest number of scalar multiplications for general n×n matrices turns out to be a deep mathematical problem. A glance at the network that implements Strassen multiplication (SM) in Figure 1 quickly establishes two things that make this application of machine learning unique: • The architecture of the network and the operations performed by its components are a perfect match to the mathematical problem, as opposed to being just a well motivated, robust platform for general machine learning applications. • The design of the network is deliberately naive and lives up to the standard that the machine should have the capacity to learn something that we don’t already know. Our network, in fact, does not even know how numbers are arranged to form a matrix! Figure 1 is an engineer’s representation of SM. The elements of the 2 × 2 matrices A and B are read in from two registers of numbers a(i) and b(i), i = 1, . . . , 4 on the left and right. Those from A are ‘pooled’ into the left inputs of the seven multipliers in the middle layer of the network, those from B into the right inputs. Pooling is the most general linear-homogeneous operation. Denoting the inputs to the multipliers a∗ (j) and b∗ (j), j = 1, . . . , 7, the pooling equations are ∗ a (j) = 4 X ∗ Wa (j, i)a(i) b (j) = 4 X i=1 i=1 2 Wb (j, i)b(i). (1) Figure 1: A network for multiplying 2×2 matrices that uses only seven multipliers. Multiplication by a constant (“weight”) occurs at each of the lines connecting input and output registers (for the matrices A, B and C) to the multipliers in the middle layer of the network. The 7 × 4 sets of real numbers Wa and Wb are called weights, though they are not required to be non-negative. Multiplication by a weight is not counted as one of the multiplies in SM. Unlike the multiplications performed by the seven multipliers, weight multiplication is a linear operation in the inputs to the network. The challenge of SM is to find a set of weights that work for all conceivable matrices we wish to multiply. We will see that this set is not unique, and there exist transformations from one set to another that works just as well. In the most practical set found by Strassen [S], all the nonzero weights are just ±1, so the weight-multiplications are really just additions and subtractions. The output end of the network works in the same way as the input end: the outputs of the seven multipliers are pooled into the four output registers of the C 3 matrix, c(i), i = 1, . . . , 4, again in the most general way with a set of weights: c(i) = 7 X Wc (i, j) a∗ (j)b∗ (j). (2) j=1 Strassen’s discovery can now be expressed in purely engineering terms. That is, there exists a fixed set of weights Wa , Wb and Wc such that the four numbers in the product of any pair of matrices can be computed with the 7-multiplier network of Figure 1 (i.e. the 8-multiplier network implicit in the standard algorithm is suboptimal). 3 Mathematical digression: tensor rank Combining (1) and (2) we obtain a curious statement about matrix multiplication, now for n × n matrices: 2 c(i) = 2 n n X X Mn (i, k, l) a(k)b(l) (3) k=1 l=1 Mn (i, k, l) = r X Wc (i, j) Wa (j, k) Wb (j, l). (4) j=1 The universal three-index set of numbers Mn is a tensor of order three, the (n × n)matrix multiplication tensor. We see that Mn can be written as a sum of r products of three 1-tensors, the atoms of all tensors. The minimum r in the decomposition into products of 1-tensors is called the rank of the tensor. Unlike the problem of determining the rank of a matrix (a 2-tensor), determining the ranks of higher order tensors such as Mn is computationally difficult [H]. While we know rank (M2 ) = 7 [W], already for the next case we currently only have bounds [B, JDL]: 19 ≤ rank (M3 ) ≤ 23. A general transformation of the weights that gives another correct network (decomposition of Mn ) can be inferred from the fact that the transformed matrices à = U AV −1 B̃ = V BW −1 C̃ = U CW −1 , (5) for arbitrary invertible (U, V, W ), satisfy the matrix product property whenever A, B and C do (ÃB̃ = C̃). But feeding à and B̃ into the network, and seeing the correct output C̃, is equivalent to feeding in A and B and seeing C in the output 4 after the three sets of weights have been appropriately transformed by the linear relations (5). When we test our network for “matrix multiplication fidelity” we would like to do better than spot check its accuracy on sample instances. To assess how well it will perform on any instance of matrix multiplication we compute ǫ, where 2  r X X 1 Mn (i, k, l) − Wc (i, j) Wa (j, k) Wb (j, l) (6) ǫ2 = 2 3 (n ) ikl j=1 is the mean-square error in how our weights are decomposing the true Mn . 4 Conservative learning The truly amazing thing about the network in Figure 1 is not that, given the special Strassen weights, it manages to produce the product C = AB with only seven multiplies. What is really remarkable is the fact that the network can learn a correct set of weights just by being shown enough examples of correctly multiplied matrices. A huge industry has grown up around the problem of training networks. Most methods start with completely random weights and adjust these to minimize the discrepancy between the correct output and the actual output of the network. There are many schemes for minimization, though most are local and based on gradients of some measure of discrepancy (“loss”) with respect to the weights. We will use a somewhat different approach for the Strassen network called conservative learning. Conservative learning is not the oxymoron it would seem, but a combination of two very reasonable principles: • When presented with a training item for which the network gives the wrong output, change the weights so that at least this item produces the correct output. • Make the smallest possible change to the weights when learning each new item. By making the smallest possible change, when obsessing over the most recent item, we stand a better chance of not corrupting the accumulated knowledge derived from 5 all previous items. To add mathematical support to this statement we analyze a very simple network. Consider a network that implements a linear transformation from a set of inputs x ∈ Rm to a set of outputs y ∈ Rn . We use matrix notation in what follows. The transformation to be learned corresponds to a matrix of weights W ⋆ , and training samples are pairs (x, y) where y = W ⋆ x. Suppose W is the current matrix and (x, W ⋆ x) a new training item. As our network is linear, we choose to train only with normalized inputs, xT x = 1. We wish to find the smallest change ∆ such that (W + ∆)x = W ⋆ x. (7) Taking the Frobenius norm k∆k = Tr ∆T ∆ to define the smallness of the change, some simple linear algebra gives us the conservative learning rule: W → W ′ = W + (W ⋆ x − W x)xT . (8) The current weights are incremented by a rank 1 matrix comprising the input vector x as one factor and the output discrepancy W ⋆ x − W x as the other. The new weights W ′ are now correct on the item (x, W ⋆ x). To better understand how we are doing relative to the corpus of all possible items, we make note of the following relationship between old and new weights: W ′ − W ⋆ = (W − W ⋆ )(1 − xxT ) (9) Px⊥ (W (10) = ⋆ − W ). The operator Px⊥ projects rows to the orthogonal complement of x. From (10) we infer the norm inequality kW ′ − W ⋆ k ≤ kW − W ⋆ k, (11) where we get equality only in the rare case that x is orthogonal to all the rows of W − W ⋆ . This inequality proves that conservatism is sound: by minimally accommodating each new item there is monotone improvement in our approximation of the transformation (W ⋆ ) itself. Conservative learning has the nice feature that there are no parameters that have to be tuned, such as the step size in gradient descent. This continues to be true when the principle is applied to general networks. However, multiple layers and nonlinear components make the problem of finding the exact weight modifications intractable. Fortunately, there is a systematic procedure for keeping track 6 of the order of smallness of the changes in the general network so that an approximate learning rule can be written down. The update procedure for the weights in the multilayer setting has similarities with the back-propagation rules in gradientbased learning, but there are also some new modes of propagation. Not surprisingly, proving convergence is also out of reach. Our experiments with the Strassen network show spectacular convergence, even without imposing a small parameter to keep changes in check. A derivation of the conservative learning rules for the Strassen network are given in the appendix. This network has all the features that need to be addressed in general networks and therefore serves as a good vehicle for explaining the method. 5 Conservative learning with the Strassen network There are two sources of randomness when training a network: the distribution of the initial weights and the distribution of the training items. We did not explore this dimension in our experiments with the Strassen network. The weights were initialized with independent uniform samples from a symmetric interval about the origin. Clearly the scale of this interval is not arbitrary, since the tensor Mn being decomposed has a definite scale. A scale for the weights is also implied by the error objective (6). Conservative learning proved not to be very sensitive to the scale of the initial weights, with only extreme limits (small and large scales) showing performance degradation. For simplicity we therefore chose to always initialize with samples drawn from [−1, 1]. Adding an interesting bias to the distribution of training matrices is also something we did not try. Our input matrices were simply constructed from uniform samples of [−1, 1] in each element of A and B. After rescaling to conform with our normalization convention Tr AT A = Tr B T B = 1, these together with C = AB were handed to the network for training. It astonished us how quickly the network discovers Strassen’s trick for 2 × 2 matrices, when the weights are updated by the conservative learning rules. Figure 2 shows the decomposition error ǫ converging linearly, after an initial training set of only a few thousand. The five runs shown have slightly different convergence rates, a variability that can only be attributed to the initial weights and the early training items (before the onset of linear convergence). We did not compare with other learning rules, all of which, unlike conservative learning, come with parameters 7 Figure 2: Root-mean-square error ǫ in the rank 7 decomposition of the 2 × 2 matrix multiplication tensor by the network in Figure 1. Shown are results for five runs of the network, each starting with random weights and trained on streams of random instances of correctly multiplied matrices. and batch protocols that we were not prepared to manage with competence. When we remove one multiplier from the middle layer of the network in Figure 1, that is, attempt to find a rank 6 decomposition of M2 , the error ǫ fluctuates indefinitely. This of course is what we expect, since there is a proof that M2 has rank 7 [W]. For 3×3 matrices the network exhibits a new kind of behavior. Since it is known that rank (M3 ) ≤ 23 [JDL], convergent behavior is possible in principle when we have 23 multipliers. We find that this indeed happens in about 64% of all runs, an example of which is the lower plot in Figure 3. In the remaining runs ǫ decays much more slowly; an example of this behavior is the higher plot in Figure 3. The phenomenon of there being two qualitatively different asymptotic states of the network, when decomposing M3 , is consistent with the border rank property. This property, peculiar to tensors of order three and higher, refers to the topological closure properties of the space of tensor decompositions. When this space is not closed, the abstract closure defines tensor decompositions on the “border” of the space that have lower rank. In more concrete terms, it gives rise to approximate decompositions of lower rank, where the approximation as measured by ǫ gets 8 Figure 3: Root-mean-square error ǫ, in rank 23 decompositions of the 3 × 3 matrix multiplication tensor, on two runs. The absence of convincing linear convergence in one of the runs is accompanied (Figure 4) by a slow growth in the maximum weight magnitude. better when the weights are allowed to diverge without limit. We see evidence of “border” behavior when we compare the evolution of the maximum weight magnitude, max (|Wa |, |Wb |, |Wc |), for the two runs in Figure 3. These are plotted in Figure 4. In contrast to the linearly convergent run, where the maximum weight saturates, the run with slow convergence has a corresponding slow growth in the maximum weight. An interpretation of our results, consistent with what is known about tensor decompositions of M3 , is that the weights in the slowly converging runs are rank 23 border approximations to true rank 24 or higher decompositions. Running the network with 22 multipliers we only observe the slow convergence/growing weight behavior. While this does not prove the true rank is 23, it is consistent with M3 having rank 22 border approximations [Sch]. That slow convergence was never observed in our experiments with M2 is in agreement with the known fact [JML] that this tensor does not have lower rank border approximations. Conservative learning with the Strassen network for 3 × 3 matrices is summarized in Figure 5. This gives the distribution of the final decomposition error ǫ for 103 runs, each limited to 108 training items and terminated when the error dropped 9 Figure 4: The maximum weight magnitudes, max (|Wa |, |Wb |, |Wc |), for the two training runs shown in Figure 3. below 10−14 . Runs with linear convergence, such as the one in Figure 3, typically required far fewer than 108 training items. The large peak at the low end of the distribution in Figure 5, about 64% of all runs, therefore gives the probability that the network finds a true rank 23 decomposition. As explained above, we believe the network is slowly converging to border approximations in the other runs. 6 Appendix The starting point for deriving the conservative learning rules for the Strassen network (Fig. 1) is the Lagrangian function L= 1 1 1 Tr (∆Ta ∆a ) + Tr (∆Tb ∆b ) + Tr (∆Tc ∆c ) 2 2 2 + αT (a∗ − (Wa + ∆a )a) + β T (b∗ − (Wb + ∆b )b) + γ T (c − (Wc + ∆c )a∗ ◦ b∗ ) . (12) To streamline the derivation we use matrix notation. The new training item is the triplet of vectors (a, b, c) corresponding to the unrolled matrices (A, B, C = AB). We should think of (a, b) as inputs to the network and c as the output. Prior to this 10 Figure 5: Distribution of the final decomposition error of M3 in 103 runs, each with 108 training items. Runs were terminated when ǫ dropped below 10−14 . item the network has weight matrices Wa and Wb that map the inputs to the pairs of inputs of the multipliers in the middle layer, (a∗ , b∗ ). The outputs of the multipliers is the vector c∗ = a∗ ◦ b∗ , where ◦ denotes componentwise multiplication. If the network weights are correct even for the new item, then mapping c∗ with the weight matrix Wc should match the output vector c. In general, the three weight matrices have to be changed by (∆a , ∆b , ∆c ) for this to be true, and the first three terms of L are the Frobenius norm objective on these changes to keep them small. The last three terms are constraints imposed via three vectors of Lagrange multipliers, (α, β, γ). These insure that with the changed weights the inputs/outputs of the network match the inputs/outputs of the multipliers in the middle layer. Given the current weights (Wa , Wb , Wc ) and the new training item (a, b, c), our task is then to find a stationary point of Lagrangian L for the variables (∆a , ∆b , ∆c ), (a∗ , b∗ ), and (α, β, γ). In the derivation below we assume that the inputs are normalized as aT a = bT b = 1. Stationarity with respect to ∆a and ∆b imply ∆ a = α aT ∆ b = β bT . (13) Comparing with the update rule for the linear network in section 4 prompts us to interpret α and β as discrepancies associated with the multiplier inputs. Multiplying 11 (13) on the right respectively by a and b we also have ∆a a = α ∆b b = β. (14) These equations and ones to follow are consistent with the Lagrange multipliers vanishing proportionately with the changes in the weights. Before we impose stationarity with respect to the other variables, we define a set of approximate vectors associated with implementing the network using the current (unchanged) weights. This mode of evaluating the nodes (vectors) in the network is called a forward pass. ã∗ = Wa a b̃∗ = Wb b. c̃ = Wc ã∗ ◦ b̃∗ . (15) (16) Imposing stationarity with respect to (α, β) and comparing the resulting equations with (15) and (14), we obtain a∗ = (Wa + ∆a )a a∗ − ã∗ = ∆a a = α b∗ = (Wb + ∆b )b, (17) b∗ − b̃∗ = ∆b b = β. (18) This shows that the discrepancies represented by α and β are the differences between their true values (after the conservative-learning update) and their forwardpass values. Learning in some sense starts at the output layer, where the c̃ of the forward pass is compared with the output c of the training item. To obtain the conservative learning rule for this we start by imposing stationarity of L with respect to ∆c : ∆c = γ (a∗ ◦ b∗ )T . (19) We now make the first of a series of approximations. Extending to the output layer the property of the middle layer, that the pairs (∆a , α) and (∆b , β) have the same order of smallness, we expect (∆c , γ) also to vanish proportionately. A good approximation of (19) is then to replace a∗ and b∗ by their forward pass values (the error being higher order), ∆c ≈ γ (ã∗ ◦ b̃∗ )T = γ c̃∗T , (20) where we have expressed the result in terms the forward pass value of the multiplier outputs, c̃∗ . Now imposing stationarity of L with respect to γ, c = (Wc + ∆c ) a∗ ◦ b∗ , 12 (21) and comparing with (16) we obtain   c − c̃ ≈ ∆c c̃∗ + Wc (a∗ − ã∗ ) ◦ b̃∗ + ã∗ ◦ (b∗ − b̃∗ ) ≈ γ c̃∗T c̃∗ + Wc (α ◦ b̃∗ + ã∗ ◦ β). (22) (23) where we have neglected second order terms and used (13) and (20). By imposing stationarity with respect to the two remaining sets of variables we will obtain equations that relate (α, β) to γ, enabling us to cast the equation for the output discrepancy (23) just in terms of the unknown γ: (a∗ , b∗ ) α = b∗ ◦ (WcT + ∆Tc )γ α = b∗ ◦ (WcT γ) β = a∗ ◦ (WcT + ∆Tc )γ, (24) β = a∗ ◦ (WcT γ). (25) In (25) we again discarded second order terms. Substituting α and β from (25) into (23) we arrive at the equation that begins the process of updating the weights: c − c̃ ≈ (c̃∗T c̃∗ ) γ + Wc (ã∗ ◦ ã∗ + b̃∗ ◦ b̃∗ ) WcT γ. (26) Equation (26) relates the discrepancy, between the true (training) c and the c̃ of the forward pass, to the Lagrange multipliers γ. Were we to neglect the offdiagonal terms in this linear matrix equation and determine γ by γ← 1 (c − c̃), c̃∗T c̃∗ (27) then the process of learning item (a, b, c) would be completely analogous to the usual “back-propagation” scheme. After forward-propagating the inputs (a, b) with Wa , Wb and Wc to determine the discrepancy c − c̃, the γ given by (27) is back-propagated (25) by WcT to get α and β. The three Lagrange multipliers then determine the weight changes by (13) and (20). Lacking an argument for discarding the off-diagonal terms in (26), we need to look for methods to solve this more complex linear equation. The off-diagonal terms correspond to one-level of back-propagation followed by forward-propagation. An iterative solution of the linear equation would thus involve multiple backward-forward propagations between just the final two layers of the network. This is not as intimidating as it might seem for two reasons. First, when using the conjugate gradient (CG) method, the number of backward-forward iterations is bounded by the number of components of the vector γ. Second, given a reasonable initial solution-estimate, CG usually requires only few iterations in practice. 13 Since our derivation of the conservative learning rules has been based on the premise that the discrepancies (a∗ − ã∗ , b∗ − b̃∗ , c − c̃) are small, we are keeping with this premise when we take as our initial CG solution-estimate γ = 0. As a better motivated alternative to (27) we apply the fewest (non-trivial) number of CG iterations — a single one — to this solution-estimate. At this single-iteration level of CG the approximate solution has a simple interpretation. Let G = (c̃∗T c̃∗ ) + Wc (ã∗ ◦ ã∗ + b̃∗ ◦ b̃∗ ) WcT (28) be the symmetric positive definite matrix in our linear equation δ = c − c̃ = Gγ. (29) The single-iteration CG solution has the form γ1 = λδ, where λ is a scalar multiplier and determined by projecting the equation on δ: δT (δ − G(λδ)) = 0. (30) The conservative learning alternative to (27) is therefore γ ← γ1 = (c − c̃)T (c − c̃) (c − c̃). (c − c̃)T G(c − c̃) (31) Not surprisingly this reduces to (27) when the off-diagonal terms in G are dropped. We conclude this appendix with a short summary of the conservative learning rules for updating the network weights when given a new training item (a, b, c). 1. Forward propagate (a, b) using (15) and (16) to get (ã∗ , b̃∗ , c̃∗ = ã∗ ◦ b̃∗ ) and c̃. 2. From the output discrepancy c − c̃ compute γ using (31). Computing the scalar multiple of c− c̃ in this expression requires a single backward-forward propagation by the matrix G in (28). 3. The update ∆c of Wc is the rank 1 matrix (20) constructed from γ and c̃∗ . 4. Backward propagate γ by (25) to obtain α and β. 5. The updates (∆a , ∆b ) of (Wa , Wb ) are given by the rank 1 matrices (13) constructed from (α, β) and (a, b). 14 7 Acknowledgements I thank Cris Moore for instigating this study, Jonathan Yedidia for suggesting the conservative learning method, and Alex Alemi for keeping things competitive. The Simons Foundation and ADI Lyric Labs provided financial support. References [S] V. Strassen, Gaussian elimination is not optimal, Numer. Math. 13, 354-356 (1969). [H] J. Håstad, Tensor rank is NP-complete, J. Algorithms 11, 644-654 (1990). [B] M. Bläser, On the complexity of the multiplication of matrices of small formats, J. Complexity 19, 43-60 (2003). [JDL] J.D. Laderman, A noncommutative algorithm for multiplying 3×3 matrices using 23 multiplications, Bull. Amer. Math. Soc. 82, 126-128 (1976). [W] S. Winograd, On the multiplication of 2 × 2 matrices, Linear Algebra Appl. 4, 381-388 (1971). [Sch] A. Schönhage, Partial and total matrix multiplication, SIAM J. Comput. 10, 434-455 (1981). [JML] J.M. Landsberg, The border rank of the multiplication of 2 × 2 matrices is seven, J. Amer. Math. Soc. 19, 447-459 (2006). 15
9cs.NE
1 arXiv:1609.07719v1 [math.NA] 25 Sep 2016 2 A survey on stochastic multi-scale modeling in biomechanics: computational challenges Marco Favino∗ Rolf Krause∗ Igor V. Pivkin∗ September 27, 2016 Abstract During the last decade, multi-scale models in mechanics, bio-mechanics and life sciences have gained increasing attention. Using multi-scale approaches, effects on different time and length scales, such as, e.g., cellular and organ scale, can be coupled and their interaction can be studied. Clearly, this requires the development of new mathematical models and numerical methods for multi-scale problems, in order to provide reliable and efficient tools for the investigation of multi-scale effects. Here, we give an overview on existing numerical approaches for multi-scale simulations in bio-mechanics with particular emphasis on stochastic effects. 1 Introduction Computational Science, i.e. the study, development, and use of algorithms, methods and simulations tools, has become indispensable for research and experimentation in science, engineering, medicine, and technology, cf. [BL05]. Physical experiments can very often be replaced by a “virtual experiment”, i.e. a simulation. Classical simulation approaches like finite elements are routinely used in research and industry by now, and computational methods like Molecular Dynamics (MD) allow for a detailed investigation of effects on small scales, for example for the design of new materials and drugs. In fact, looking from a single-scale and single-physics point of view, current simulation methods are quite elaborated. The existing methods for solving ordinary differential equations (ODEs) or partial differential equations (PDEs) have reached a high level of maturity: accuracy control, adaptivity, efficiency and robustness can be guaranteed for a large range of problem classes, which can be modeled by, e.g., initial or boundary value problems involving ODEs or PDEs. Many of the underlying mathematical models, however, have been developed from a deterministic point of view with the idea of reducing the complexity of ∗ Institute of Computational Science, Università della Svizzera italiana, Lugano, Switzerland 3 A survey on stochastic multi-scale modeling 4 a physical or biological phenomena. Thus, the classical “deterministic singlephysics, single-scale” approach has several limitations. Firstly, most deterministic methods aim at the computation of a single solution or a single trajectory, which is usually assumed or even known to be uniquely determined by the initial data and the chosen parameters. For most biological and bio-mechanical applications, however, relevant parameters or other data such as, e.g., the computational domain, are not exactly known. As a consequence, the value of the information which can be obtained from a single trajectory computed for one given set of data is restricted. Secondly, information on the sensitivity of the problem with respect to perturbations in the data can not be obtained directly from such a simulation. Thirdly, many processes on small length- and timescales in biology and bio-mechanics might be modeled best using stochastic approaches. The interaction of these stochastic effects in the micro scale (cell level or below) with deterministic processes on the macro-scale (organ level or above) is also not easily possible within the framework of classical deterministic simulations. These limitations have simply been caused by the fact that computational models had (and have) to be designed in order to make the results of a simulation run accessible in reasonable time. With the ever growing computational capabilities of modern super-computers, however, the restrictions in terms of computational time become less important, thus opening new perspectives for the modeling and simulation of complex and coupled systems. As of 2014, we have super-computers available which deliver up to 34 petaFLOPs [SDS+ 14] and exaFLOP machines are expected in the near future. Thus, in principle there is sufficient computational power available in order to carry out even very demanding simulations involving different length and time scales and different models. In parallel to the growth of computational capabilities, within the last three decades various new numerical approaches have been developed. In particular uncertainty quantification, sensitivity analysis, multi-scale effects, coupled and complex systems, and the influences of random processes have been driving factors. They have been employed to different biomedical applications, such as remodeling and growth of tissues (e.g., wound healing, bone healing, tumor growth), modeling of cardiovascular system, muscular activation, and electrophysiology. Thus, we are currently facing the transition from a more deterministic single-physics approach towards a broader class of mathematical models and numerical methods, which are capable of dealing with complex systems involving multiple scales and stochastic effects. These new methods give rise to a wide range of new possibilities in terms of simulation and prediction of biological and bio-mechanical systems. In this paper, we aim towards an overview on existing multi-scale approaches and their numerical treatment with particular emphasis on stochastic effects. We will focus especially on bio-mechanical applications. We will also include methods which have been developed in computational mechanics, as we believe that the underlying concepts and ideas are also relevant for computational biomechanics. A survey on stochastic multi-scale modeling 5 Finally, we would like to emphasize that -naturally- the references given in this paper are far from complete. If the given references appear to be selected randomly, we kindly ask the reader to interpret this in the broader context of the stochastic approaches considered here. 2 2.1 Multi-scale Approaches High Resolution Approaches The possibly most straightforward approach to treating different length-scales in bio-mechanics might be the usage of high resolution models based on single-scale models. Here, prominent example is the simulation of trabecular bone using the so called micro-finite element method: a high resolution finite element mesh is used which allows for resolving the structure of the trabeculae. Naturally, this approach finds it limits where the material does not behave as a continuum any more, as this is a necessary prerequisite for the application of continuum based material models and the finite element method. The resulting large scale systems are then solved using established and well scaling fast iterative methods as multigrid methods on massively parallel machines [AvLM+ 08]. In the case of non-linear material models, the situation is more complex, but it can be handled efficiently even for the arising large scale systems, cf., e.g., [CWM10]. These high resolution models, which have been originally designed for simulating the mechanical behaviour of the bone, have also been extended in order to investigate, e.g., bone-cell response to mechanical stimuli [LCGP06]. In [GWvLM09] it is argued that, in order to model and simulate this interaction more accurately, hierchical models should be developed and employed. An approach to stochastic modeling can be found in [TMBM94]. Here, stoachastic effects are added to a continuum based model. 2.2 Concurrent Multi-Scale Models The development of coupled multi-scale models has been starting about 20-25 years ago in different fields. We refer to the survey [GZC14], where an overview by scientific communities can be found. There, Astrophysics, Biology, Energy, Engineering, Environmental and Material Sciences are identified as major fields for multi-scale simulations. Additional surveys on multi-scale models can be found in [CM03, PL04, BCC+ 04, ELVE04]. An important choice in multi-scale modelling is whether to decompose the problem hierarchically or to use a concurrent approach, in which the different scales are treated simultaneously. Clearly, this also makes a difference from the numerical point of view. In the first case the different scales can be treated separately and in a sequential manner. The transfer of information between the different scales is often realised by exchanging parameters, usually from fine to coarse: computations on the micro-scale are used to determine certain parameters on the macro-scale. A survey on stochastic multi-scale modeling 6 We refer to [BLL02, AG05] and to Section 3 for more details on this approach. In the second case, i.e. the concurrent case, the different models and scales interact and influence each other directly during the computation. In computational mechanics, the most prominent multi-scale methods are designed for the coupling of MD on the micro-scale and finite elements on the macro-scale. We refer to Figure 1 for an example from fracture mechanics illustrating this concept. Here, a MD solution around the crack tip is combined with a finite element simulation “far away”from the crack. In these applications, the solution methods are based on a spatial decomposition of the computational domain, which can be non-overlapping, partially overlapping, or fully overlapping. Examples are the coupling of length scales method, which uses a non-overlapping decomposition with a lower-dimensional interface for coupling [BABK99], the Bridging Domain method by Belytschko and Xiao, which uses a transition domain for the information transfer between the scales, and the bridging scale method by Liu et al. [WL03], which is designed for the fully overlapping case but then reduces the size of the atomistic region by using absorbing boundary conditions outside the “region of interest”. Recently, these methods have been extended to include also the randomness of the material structures using homogenization approaches, see [YCT+ 08, LQG+ 10] and the references cited therein. In this context, also the Arleqiun method has to be mentioned, which provides a general approach to multi-scale coupling in particular in mechanics, see [Dhi98]. In addition to multi-scale approaches where MD and finite elements are coupled, Figure 1: Coupling between Molecular Dynamics and Finite Elements (Mode-I fracture). also other coupled models exist. An example can be found in [MKSB11], where finite elements are coupled with discrete automata for modeling tumors. We finally note that sometimes also multi-dimensional models are referred to as multi-scale models. Here, 1d (often ODEs) and 3d models (often PDEs) are coupled, see [GSS+ 14, PdLF+ 09, KJ10]. The fully overlapping case is described in more detail in Section 3.3. Scale Transfer A particular challenge in the framework of coupled multi-scale simulations is the transfer of discrete fields –in mechanics usually displacements A survey on stochastic multi-scale modeling 7 and stresses– between the different scales. By design, the models on the different scales will have different characteristics. It is well known that a simple and straightforward coupling of MD and finite elements leads to spurious oscillations and/or to the so called “ghost forces” at the coupling interface, which can spoil the accuracy of the simulation. Moreover, in MD the displacement of the atoms are pointwise given quantities, whereas in a continuum based model such as finite elements the computed displacements live in a suitable function space (usually the Sobolev space H 1 ). From neither a physical nor a mathematical point of view it is possible to identify finite element displacements with MD displacements directly. Instead, a suitable transfer operator has to be derived which allows for a stable and seamless transfer of discrete fields between the different models. See [FKKL11] and the references therein for details on this aspect. A similar -but less severe- problem shows up with respect to the discretization in time. Here, the different time scales of MD and continuum based approaches have to be taken into account. One possibility is to use time integrators as the SHAKE-RATTLE integrator [HLW00], which is a standard symplectic integrator for constrained Hamiltonian systems. 2.3 Coarse Graining A fundamental problem for numerical simulations on the molecular scale is the fact that the currently feasible time- and length scales are still too small for many practical applications. Although standard simulations tools in MD show excellent scaling behaviour also on larger parallel machines, the computation times needed for simulations in classical MD are still very high: an example might be the simulation of a complex virus in a time range of about a milli-second. In order to address this problem, so called coarse grained (CG) methods have been introduced, which aim at using coarser scales in space and time without sacrificing too much the microscopic information, see, e.g., [Vot09, NLSK04]. Although there is a huge variety of CG models available in the literature, they share the common idea of partitioning the system into single interaction centres, the so called “beads”. For this in-space-reduced system, the CG potentials are derived, which provide the effective force field for the interaction of the CG particles or beads. Often, these CG potentials are given in a parametrised form and they aim at preserving structural properties observed in atomistic simulations. Examples are approximations based on the potential of mean force [SSR+ 01, MBF+ 00] or the inverse Monte Carlo technique [MFP+ 04] and Inverse Boltzmann. CG potentials might also be designed to preserve thermodynamic properties [SSR+ 01, MdVM04, MRY+ 07, MKP+ 08]. Multi-scale Coarse-Graining (MSCG) [IV05] is a different class of CG potentials that uses information from high-resolution simulations or models for building the CG potential. This is usually done by means of a force matching method [IPBV04, EA94]. For the analysis of MSCG in the framework of statistical mechanics, see [NaGSAK+ 08a, NaGSAK+ 08b]. From a numerical point of view, the computational effort for CG simulations can be reduced by choos- A survey on stochastic multi-scale modeling 8 ing a new multi-resolution basis [DA12b, DA12a]. With respect to stochastic approaches, combinations of CG approaches with Monte-Carlo methods have been derived and analyzed, see [KMV03]. In terms of biological and biomechanical applications, CG models have been used for simulating the behaviour of platelet aggregation as a stochastic process [PRK06]. Also on the cellular level, in [VG12] an approach is presented which incorporates cell death and proliferation as stochastic processes. A multiscale description for wound healing using different models on cellular, cell colony, and tissue scale is described in [VG13]. 2.4 Dissipative Particle Dynamics Dissipative particle dynamics (DPD) is a relatively new, potentially very effective particle-based approach, which was applied in simulations of physical and biological systems from atomistic to macroscopic size. The DPD model consists of particles (“beads”) which correspond to coarse-grained entities, representing clusters of atoms or molecules [HK92, PCK10]. The size of these clusters, which defines the level of coarse-graining in DPD simulations, can vary by many orders of magnitude in different applications. For simple fluids, the DPD particles interact with each other via pairwise forces, e.g., conservative, dissipative, and random [GW97]. All forces in DPD conserve linear and angular momenta. Conservative force in DPD is derived from soft quadratic potential and its magnitude depends on the physical system. Dissipative force takes into account dissipation of energy due to friction forces. Stochastic component of the DPD, the random force, takes into account the degrees of freedom which were eliminated as a result of coarse-graining. Dissipative and random forces form DPD thermostat [EW95]. In simulations of complex systems other forces are usually added, which include bonded interactions, angle potentials, etc. Unlike MD, where the choice of forces is based on a theoretical model of the physical system to be simulated, the DPD model involves forces of a form independent on the physical system. Therefore, parameters in DPD simulations have to be carefully chosen in applications. Two interpretations of the DPD method exist. According to the first one, DPD can be considered as a stochastic CG molecular dynamics [GW97]. Here, each DPD particle corresponds to a cluster of a small number of atoms or molecules, typically in the range between 3 and 10. In this case, the most common process of choosing DPD simulation parameters for fluid systems is based on assuming that the dimensionless compressibility of the DPD fluid is equal to the dimensionless compressibility of the physical fluid [GW97, KPMK05]. The time scale is defined by matching the diffusion constant of the molecule of interest [Gro00, GR01] or vorticity [KPMK05]. The level of coarse-graining in this interpretation of the DPD is limited however [Tro03, PK06]. For systems containing water it is usually less than 10 water molecules per single DPD particle. Nevertheless, due to the soft potentials employed in DPD, the time scales are typically quite large comparing to MD, resulting in speed-up factors of more than 104 [GW97]. A survey on stochastic multi-scale modeling 9 The second interpretation of the DPD method is based on the fact that DPD forces conserve linear and angular momenta. As a result, DPD provides correct description of the hydrodynamic interactions in simulations even with relatively small number of particles [Esp95]. Here, each DPD particle can correspond to a cluster of a very large number of atoms or molecules. The DPD simulation parameters are chosen so that relevant dimensionless numbers (such as Reynolds number in flow simulations) or specific properties of fluid are preserved. Thermal fluctuations are still present in simulations, and therefore the method is typically used for modeling mesoscale systems. The dual nature of the DPD method, which allows simulations of atomistic as well as mesoscopic systems, can be effectively utilized in multi-scale modeling approaches. In coupling of MD and continuum based methods (e.g., finite element), DPD can be used as an intermediate model, helping to bridge the gap between scales. On the other hand, coupling DPD itself with continuum solver will allow simulations of systems, in which the smallest resolved length and time scales will be controlled by the level of coarse-graining used in DPD. Uncertainties and unresolved small scale effects in the system then can be integrated into the stochastic nature of the DPD method. The difficulty and the effort required for such coupling should be similar to the coupling of MD and finite element method. However, due to the larger time scales in DPD, the hybrid multiscale system based on DPD will allow for larger simulation times as compared to MD based hybrid systems. DPD has been applied to model many complex multiscale systems, including simulations of polymer solutions, brushes and melts [SHM95, MT00, Spe00], binary mixtures [CN96], amphiphilic systems [JBC+ 99, SL02, PP14], and cells [PK08, PLP+ 13]. Also, certain processes on the cellular level were modeled stochastically using multi-scale approaches in order to allow for a realistic yet simple description of complex behavior, for example see [PRK09]. 3 Modeling Based Approaches The multi-scale approaches presented in the previous sections are characterized by explicitly resolving the scales under investigation. A first alternative to this approach is to pass information from the microscale to the macro-scale by homogenisation, i.e. by means of averaging of equations at the micro-scale. In contrast to the concurrent multi-scale models from Section 2.2, here the information transfer is unidirectional, i.e. only from micro to macro-scale. A second alternative is the macroscopical modeling of the micro-scales. Macroscopical modelling considers the medium to consist of as many overlying continua as are the constituents in the system. Then, for each of the constituents the governing laws (usually continuity equations) are derived at the macroscopical level and coupling terms are added, which describe the interaction between the different constituents. In order to obtain a closed mathematical system, further hypotheses have to be introduced on the different components of the A survey on stochastic multi-scale modeling 10 system. In some applications, such as theory of poroelasticity or biphasic materials, these approaches are believed to coincide. Indeed, under certain hypotheses these two methods may lead to the same system of equations [Sch03]. Here, we point out the importance of the microscopical approach, since the mechanical response of a biological material does not only depend on the material parameters but also on the microscopical geometry [FDH06]. As a third alternative, the micro-scale can be coupled to the macro-scale by incorporating it as a “driving force” in the description of a macro-scale process which is modeled on the continuous level (such as diffusion or mechanics). These models are widely used in, e.g., cardiac electrophysiology or cardiac electromechanics. We will refer to them as embedded approaches. 3.1 Homogenisation Homogenisation usually refers to methods that starts from microscopical considerations and then, by means of averaging procedures, equations or problem parameters are upscaled to a coarser level [Glo12, Cha10]. In continuum based methods, homogenisation techniques assume the existence of a Representative Volume Element (RVE), which supplies information about the microscopical composition and structure of the heterogenous continua. Inside the RVE, continuity equations are defined under the hypothesis that the separation surfaces between the constituents are known. The microscopic solutions are obtained by means of volume- and mass-averages [HG89] and a system of equations at the macroscopical level is defined. In this process, also stochastic influences can be incorporated [BP04]. An alternative to analytical homogenisation can be found in numerical homogenisation. Here, using micro-scale simulations of RVEs, the relevant parameters are derived. We refer to [Cot13], where an iterative approach is described, in which the material parameters obtained for a stochastic micro-structure are updated in an iterative manner within a coupled simulation. Stochastic effects on the micro scale are also considered in [YCT+ 08], where a statistical multiscale approach is presented, which aims at quantifying the influence of random material microstructure on material constitutive properties. 3.2 Micro-macro Modeling for Biological Tissues In continuum biomechanics, the modeling of biological tissues strictly depends on their microstructure and composition. This holds particularly true for multiphase tissues such as cartilage [FGLR+ 05], intervertebral discs [MNL11], heart walls [HvCAH91], and periodontal ligament [FGD+ 11, Fav14, FBK14]. Indeed, a standard single-phase description is not satisfactory to reproduce their mechanical behaviour. The study of the effect of microstructure comes from the largely investigated field of material sciences. Here, a typical case study is the influence of pores on the overall response of the solid matrix. A survey on stochastic multi-scale modeling 11 From a mathematical standpoint, the arising model is a non-linear system of differential-algebraic equations. In its simplest form, it is given by a conservation of mass that governs the time evolution and a conservation of momentum that acts as a constraint on the motion. Implicit methods are hence a natural choice for the time integration in order to ensure the conservation properties [Gea84]. Consolidation problems of poroelastic biomaterials are characterized by a very rapid increase of pressure and then a relaxation of the tissues. In order to reproduce this very quick transient, a very short time step is needed and hence a large sequence of non-linear implicit problems has to be solved. The short time-step also imposes a very strict condition on the mesh size [FGK13] and hence suitable efficient solution method, such as non-linear multigrid or multigrid Newton’s methods, have to be developed for the arising saddle-point problem. The picture of poroelasticity becomes even more complicated when remodeling phenomena are included [GGF+ 12]. In this case, the non-linear system is coupled with a tensorial ODE, whose coefficients depend on stress state of the material. Hence, suitable solvers as the return mapping algorithm [SH98] have to be adapted in this context. In [FGLR+ 05], the statistical orientation of fibers inside cartilage is modeled. The poroelasticity system is then coupled with an evolution equation that governs the mean orientation of the fibres. 3.3 Embedded Multi-scale Models Another biological application where the homogenisation procedure is relevant comes from the modeling of cardiac electrophysiology. In the cardiac tissue, cells maintain a difference of ion concentration between the interior and exterior of the cell by means of active ionic (K+ and Na+ ) pumps. In consequence, a difference between the intra- and extra-cellular potential (known as membrane voltage) exists. Thus the cell membrane acts as an insulator. Since a cellular approach for the simulation of the heart would be unaffordable, mathematical homogenisation is a necessary tool for the simulation of heart [KS98]. This upscaling leads to a two-phase representation of the cardiac tissue where two equations describing the intra- and extra-cellular potential are defined on the same space. This system, known as bidomain equations, can be written in two different formulations: the parabolic-parabolic and the parabolic-elliptic. A simplified version of this system (the monodomain equation) can be derived assuming that the intra- and extra-cellular conductivity tensors are linear dependent. Even though this assumption is usually not valid, monodomain simulations can approximate bidomain simulations well for large-scale models, [PDR+ 06]. The monodomain equation is a diffusion problem with a non-linear reactive term depending on the ionic current. Hence, both mono- and bidomain equations have to be coupled at each point with a Hodgkin and Huxley-like model [HH52]. It is basically a system of ODEs that describes the dependance of the current on the ionic concentrations. To include the stochastic effects and fluctuations in the behaviour of ion A survey on stochastic multi-scale modeling 12 channels, a probabilistic model was developed in [PCV+ 11]. Changes in temporal and spatial variability in cardiac repolarization were related to changes in the probability distribution. A different approach to include variability in the ion channels has been proposed in [DKB12]. Here a continuous model that uses stochastic differential equations has been developed. This approach naturally encloses the interaction between cells and leads to global system of equations that can be efficiently solved. The simulation of the monodomain equation is usually realised by means of semi-implicit methods. Often, the non-linear term is treated in an explicit way and the diffusive term implicitly. This also allows to employ explicit time integration for the ODEs describing ionic concentrations, thus realizing the multiscale coupling. The solution of monodomain equation is characterised by a travelling peak with steep gradient around the so called depolarisation region. It is localised in a relatively small zone while in the rest of the domain the solution is smooth. Capturing this travelling wave renders the simulation of the electrophysiology of the heart challenging due to a required high spatial resolution. In [KPD+ 12], an efficient adaptive strategy for large parallel machines has been developed. However, the refinement is controlled using error indicators, as reliable and efficient error estimators for this kind of problem are not yet available. A first step towards the development of error estimators for this kind of coupled multi-scale problem may be the single-scale continuous formulation of electrophysiology recently presented in [HH14]. There, a variational formulation of cardiac electrophysiology is given which allows for a completely continuous formulation of the underlying multi-scale problem in terms of a minmax-problem. This formulation allows for deriving bounds for the time-steps below which the objective function is strictly convex, as it is highly beneficial from a numerical point of view. 4 Uncertainty Quantification As discussed in the previous sections, many realistic applications are characterised by uncertainty. The source of uncertainty can be in the parameters of the problems (parameter uncertainty) or in the data of the problem (parameter variability). The former refers to variability in material parameters, external loadings, boundary conditions, and geometry, while the latter refers to the variability in the output of a model. A survey which also discusses available simulation tools is [LEE12]. Mathematically speaking, uncertainty quantification (UQ) models are characterised by a stochastic PDE with random coefficients and forcing term, and some known parameters. In the literature, this is sometimes referred to as a stochastic multi-scale problem. We therefore briefly summarise existing frameworks to reduce the dimensionality of these problems and enable a fast and accurate solution of them. A survey on stochastic multi-scale modeling 13 A straightforward approach to this problem consists in the introduction of a sampling of the parameter space and then in the solution for each subproblem of a PDE with deterministic coefficients. This method is affordable as long as the problem does not suffer the curse of dimensionality, i.e. the exponential increase of the samplings with the dimension of the parameter space. An improvement to the parameter sampling is the stochastic collocation method (SCM) [BNT10, XH05]. The unknown parameters are assumed to depend on a finite number of random variables. Hence, a particular grid is introduced in the probability space and again some deterministic PDEs are solved. The particularity of this method consists in the fact that the choice of Gaußpoints in the parameter space allows to solve independent problems in space and ensures exponential convergence. In other applications, the variation is not only in the parameters, but the data of the problem can be random variables defined at each point of the computational domain. In this case, they are described not as random variables but as random fields. Hence, a possible method to approach this problem is to use the Karhunen-Loéve (KL) theorem [Loe78]. The idea is to write a stochastic process as the infinite sum of random variables - which can be interpreted as a stochastic Fourier series. Then, only a certain number of basis variables is employed to approximate the solution. Obviously, if the variability in the data is not large, few functions are sufficient to reproduce the random process and hence a SCM method can be employed for the solution. A similar approach for solving stochastic differential equations or equations depending on random processes is the polynomial chaos (PC) [XK02, HS12]. The random process is expanded over Hermite-polynomials and it is approximated by a finite number of them. This method also shows exponential convergence. The application of both KL and PC requires a finite second moment of the random process while this hypothesis is not necessary for SCM. A different approach for stochastic equations is the Monte Carlo Method (MCM). A sequence of problems is solved for random values of the unknown parameters. The solution is weighted with the probability of the outcome. MCM 1 is a very robust method but it is slow in convergence (O(N − 2 )) where N is the dimension of the sampling. Convergence is independent on the dimension of the considered random variables. The changes on the probability distribution of the random coefficients or pseudo-random sequences may improve the convergence but do not change the order. An improvement of this method is the Quasi-Monte Carlo Method (QMCM). It employs low-discrepancy sequences instead of random, or pseudo-random, ones. In this case, sequences of parameters are not randomly chosen, but they are correlated ensuring an order of convergence of (O(N −1 (log N )k )). A simple yet attractive possibility for creating an even more cost effective sampling procedure is the multilevel Monte Carlo method for elliptic stochastic partial differential equations [HPS13] which allows to solve problems with this structure. Stochastic PDEs are even more challenging when the problem has also a multi-scale structure. The multi-scale nature arises when the material param- A survey on stochastic multi-scale modeling 14 eters have many small inclusions that are randomly distributed or when the covariance function has a sharp peak. In this case, the construction of a reduced basis with PC or KL requires a large number of polynomials. In order to characterise the influence of material properties on the micro-scale, various multi-scale models for uncertainty quantification have been developed, cf. [PS14, CPL13]. Here, the stochastic models on the micro-scale are mainly used for characterising unknown material properties. We finally note that a purely probabilistic model for material fatigue and formation of micro-cracks has been presented in [Sch13]. The model is derived from reliability statistics and takes into account size effects, inhomogeneous strain, and thermal effect. Interestingly, this model acts as a “probabilistic post-processor” on data created by deterministic macro-scale simulations. 5 Multi-scale in High Performance Computing With respect to the realisation of multi-scale approaches in terms of simulation software, the main difficulty is arguably the fact that most of the existing simulation softwares have been written with a single-physics or single-scale application in mind. Thus, exploiting the available computational power in the context of multi-scale simulations turns out to be difficult, as specially tailored algorithms have to be designed and implemented, which are capable of dealing with the massive parallelism of current and upcoming supercomputers. This holds in particularly true if different simulation methods - like MD for the micro-scale and finite elements for the macro-scale - have to be intertwined. As a matter of fact, their efficient simultaneous usage within a common simulation framework is far from trivial, see, e.g., [KK11]. In fact, many multi-scale simulations are usually carried out by combining different codes through more or less elaborated interfaces. We refer to [GBBC+ 13]. Following this approach, data has to be transferred between the different scales (or simulation codes), see Figure 2. This is usually done in a Mul6scale(Coupling(Sovware(Framework( Krause,(Krause((((((((((((((Towards(High(Performance(Mul6scale(Simula6on( 36( Figure 2: Data exchange between different simulation tools. A survey on stochastic multi-scale modeling 15 sequential way, as the progress of the simulation on one scale will depend on the progress of the simulation on a different scale. One possibility to improve the computational speed is to advance the faster scale independently from the slower scale by doing a multi-rate time integration, cf., e.g., [SM10]. With respect to scalability on massively parallel machines, however, the inherently sequential approach used for the realisation of many multi-scale simulations can limit dramatically the scalability. For example, for the coupling of MD and finite elements, in [KK11] two parallel simulation tools have been coupled using a parallel scale transfer. Nevertheless, the originally good scaling of the two simulation tools when used “stand-alone” could not be maintained. This is simply due to the fact that the respective computational demands of the simulations on the employed scales are substantiably different and, combined with the scale transfer, do not allow for a good load balancing. Within the framework of MD and particle-based CG models, the situation is less severe, as both models are relatively similar. Thus, by now efficient softwares for MD simulations (GROMACS, LAMMPS) as well as approaches for their efficient coupling [GV14] exist. However, as explained above, this relatively good behavior can not be transferred to multi-scale simulations including different models as, e.g., MD and finite elements. When different models are intertwined nicely as for example in the case of cardiac electrophysiology, excellent scalability can be achieved on current supercomputer architectures, see, e.g., [KPD+ 12]. This is possible since the smaller scale, i.e. the models for the ion-channels, can be seamlessly integrated into the finite element method used for the diffusive part of the mono- or bidomain equation. The integration is done by simply solving a set of ODEs at each mesh node or at each quadrature point. As this additional work load is completely local and moreover scales nicely with the number of degrees of freedom for the finite element simulation, massively parallel machines can be used efficiently. From the above examples it is clear that the possibility to use massively parallel supercomputers will heavily depend on the type of the multi-scale model and on its characteristics. To put it simply, the better the different scales can be intertwined, the more likely good scalability will be. Making the computational power of large machines available for truly heterogeneous multi-scale simulations thus remains a significant challenge. Coupling existing codes is possible, but can lead to a drastic loss in scalability. The ongoing trend in supercomputing towards heterogeneous hardware (CPU, accelerators, GPUs, shared memory, distributed memory,. . . ) and the corresponding diversification in terms of programming tools (OpenCL, CUDA, OpenMP, MPI,. . . ) will make it moreover necessary to provide highly specific implementations. A possible remedy here could be to use asynchronous solution methods as stochastic solution methods, as those might allow for obtaining good scalability even for the strongly heterogeneous demands of multi-scale simulations. A survey on stochastic multi-scale modeling 6 16 Conclusions Clearly, multi-scale models allow for the treatment of complex phenomena involving different scales, such as, e.g., remodeling and growth of tissues (wound or bone healing, tumor growth, in-stent restenosis), muscular activation, or cardiac electrophysiology. Numerous new numerical approaches have been developed to simulate multiscale problems. However, if compared to the by now well elaborated simulation methods for “classical”problems, such as computational mechanics and fluid mechanics, in the numerical simulation of (stochastic) multi-scale problems still many questions have to be answered. Particularly interesting aspects in the analysis of multi-scale methods are • • • • • • to move away from “single-trajectory view”; scale transfer; properties and stability of the coupled system; incorporation of stochastic effects; consistent definition of a coupled multi-scale problem; uncertainty quantification and sensitivity to perturbations, also for coupled multi-scale models; • parameter estimation for coupled multi-scale models. New approaches in numerical analysis are desirable to • • • • • • • • choose discretisation or discrete model; define and estimate discretisation error and error in physical modeling; control convergence, error, and accuracy; get a posteriori error estimation and adaptivity; exploit parallelism for strongly heterogeneous models; obtain scalability of solution methods and efficient solution; develop fast and reliable coupled solution methods; generalize and unify approaches to scale transfer. Moreover, the interaction of data with computational models is an issue. Here, data driven simulation, in which a simulation run is forced to optimally match the available data (measured or acquired in real time), might be an interesting option. On the computational side, the combination of different simulation tools gives rise to severe technical difficulties such as the simple exchange of data between different simulation codes, the control of iterative processes, and the introduction of appropriate stopping criteria. In terms of high performance computing, coupled methods will have to be developed which will show good scaling behavior even on the upcoming exascale machines. Such methods are currently not available, at least not to the knowledge of the authors. Summing up, it therefore can be argued that the huge potential of multiscale simulations can be exploited best, if appropriate new concepts and ideas A survey on stochastic multi-scale modeling 17 in numerical analysis will be developed, which will have to be accompanied by new improvements both of algorithms and, of course, of simulation softwares. It could be speculated that, in view of the growing core counts, also asynchronous and/or stochastic algorithms might be better suited for the numerical simulation of heterogeneous multi-scale problems on the upcoming large scale machines. Acknowledgement I.V.P. acknowledges support by the Swiss Platform for Advanced Scientific Computing grant and a grant from the Swiss SystemsX.ch initiative within the framework of the ERA-Net ERASysAPP. R.K. acknowledges support by the Swiss Platform for High Performance Computing (PASC) and by the SNF through the project “A Flexible High Performance Approach to Cardiac Electromechanics”. References [AG05] M. Arndt and M. Griebel. Derivation of Higher Order Gradient Continuum Models and Atomistic Models for Crystalline Solids. Multiscale Model. Simul., 4(2):531–562, 2005. [AvLM+ 08] P. Arbenz, G. H. van Lenthe, U. Mennel, R. Müller, and M. Sala. A scalable multi-level preconditioner for matrix-free µ-finite element analysis of human bone structures. Internat. J. Numer. Methods Engrg., 73(7):927–947, 2008. [BABK99] J. Broughton, F. Abraham, N. Bernstein, and E. Kaxiras. Concurrent coupling of length scales: methodology and application. Phys. Rev. B, 60(8):2391–2403, 1999. [BCC+ 04] P. Bochev, M. Christon, S. Collins, R. Lehoucq, J. Shadid, A. Slepoy, and G. Wagner. A Mathematical Framework for Multiscale Science and Engineering: The Variational Multiscale Method and Interscale Transfer Operators. Technical Report SAND2004-2671, Sandia National Laboratories, 2004. [BL05] Marc R. Benioff and Edward D. Lazowska. Computational science: Ensuring america’s comptetitiveness. Technical report, Report of the US President’s Information Technology Advisory Committee, 2005. [BLL02] X. Blanc, C. LeBris, and P. Lions. From molecular models to continuum mechanics. Arch. Rat. Mech. Anal., 164(4):341–381, 2002. A survey on stochastic multi-scale modeling 18 [BNT10] I. Babuka, F. Nobile, and R. Tempone. A stochastic collocation method for elliptic partial differential equations with random input data. SIAM Review, 52(2):317–355, 2010. [BP04] Alain Bourgeat and Andrey Piatnitski. Approximations of effective coefficients in stochastic homogenization. Ann. I. H. Poincare, 40:153–165, 2004. [Cha10] Nicolas Charalambakis. Homogenization techniques and micromechanics. a survey and perspectives. Appl. Mech. Rev., 63, 2010. [CM03] W. A. Curtin and R. E. Miller. Atomistic/continuum coupling in computational materials science. Modelling Simul. Mater. Sci. Engrg., 11(3):R33–R68, 2003. [CN96] P. V. Coveney and K. E. Novik. Computer simulations of domain growth and phase separation in two-dimensional binary immiscible fluids using dissipative particle dynamics. Physical Review E, 54(5):5134–5141, 1996. [Cot13] Rgis Cottereau. A stochastic-deterministic coupling method for multiscale problems. application to numerical homogenization of random materials. Procedia {IUTAM}, 6(0):35 – 43, 2013. {IUTAM} Symposium on Multiscale Problems in Stochastic Mechanics. [CPL13] Aleksandr Chernatynskiy, Simon R. Phillpot, and Richard LeSar. Uncertainty quantification in multiscale simulation of materials: A prospective. Annual Review of Materials Research, 43:157–182, 2013. [CWM10] D. Christen, D. J. Webster, and R. Müller. Multiscale modelling and nonlinear finite element analysis as clinical tools for the assessment of fracture risk. Philos Transact A Math Phys Eng Sci, 368(1920):2653–68, Jun 13 2010. Christen, David Webster, Duncan James Muller, Ralph England Philosophical transactions. Series A, Mathematical, physical, and engineering sciences Philos Transact A Math Phys Eng Sci. 2010 Jun 13;368(1920):2653-68. [DA12a] Avisek Das and Hans. C. Andresen. The multiscale coarsegraining method. ix. A general method for the construction of three-body coarse-grained force fields. J. Chem. Phys., 136:194114, 2012. [DA12b] Avisek Das and Hans. C. Andresen. The multiscale coarsegraining method. viii. Multiresolution hierarchical basis funcions and basis function selection in the construction of coarsegrained force fields. J. Chem. Phys., 136:194113, 2012. A survey on stochastic multi-scale modeling 19 [Dhi98] H. Ben Dhia. Multiscale mechanical problems: the arlequin method. Comptes Rendus de lAcademie des Sciences - Series IIB, 326(12):899–904, 1998. [DKB12] C. Dangerfield, D. Kay, and K. Burrage. Modeling ion channel dynamics through reflected stochastic differential equations. Physical Review E, 85(5), 2012. [EA94] Furio Ercolessi and J. B. Adams. Interatomic potential from first-principles calculations: the Force-Matching method. Europh. Lett., 26:583–588, 1994. [ELVE04] W. E, X. Li, and E. Vanden-Eijden. Some Recent Progress in Multiscale Modelling. In S. Attiner and P. Koumoutsakos, editors, Multiscale Modelling and Simulation, volume 39 of Leture Notes in Computational Science and Engineering, pages 3–22. Springer, 2004. [Esp95] P. Espanol. Hydrodynamics from dissipative particle dynamics. Physical Review E, 52(2):1734–1742, 1995. [EW95] P. Espanol and P. Warren. Statistical-mechanics of dissipative particle dynamics. Europhys. Lett., 30(4):191, 1995. [Fav14] M. Favino. Derivation, Simulation and Validation of Poroelastic Models in Dental Biomechanics. PhD thesis, Universitá della Svizzera italiana, 2014. [FBK14] M. Favino, C. Bourauel, and R. Krause. A non-linear poroelastic model of the periodontal ligament. submitted to International Journal of Computational Methods in Engineering Science and Mechanics, 2014. [FDH06] Andreas Fritsch, Luc Dormieux, and Christian Hellmich. Porous polycrystals built up by uniformly and axisymmetrically oriented needles: homogenization of elastic properties. Comptes Rendus Mcanique, 334(3):151 – 157, 2006. [FGD+ 11] M. Favino, C. Gross, M. Drolshagen, L. Keilig, J. Deschner, C. Bourauel, and R. Krause. Validation of a heterogeneous elastic-biphasic model for the numerical simulation of the PDL. Computer Methods in Biomechanics and Biomedical Engineering, 2011. to appear. [FGK13] M. Favino, A. Grillo, and R. Krause. A Stability Condition for the Numerical Simulation of Poroelastic Systems, chapter 110, pages 919–928. American Society of Civil Engineers, 2013. A survey on stochastic multi-scale modeling 20 [FGLR+ 05] S. Federico, A. Grillo, G. La Rosa, G. Giaquinta, and W. Herzog. A transversely isotropic, transversely homogeneous microstructural-statistical model of articular cartilage. Journal of Biomechanics, 38(10):2008 – 2018, 2005. [FKKL11] Konstantin Fackeldey, Dorian Krause, Rolf Krause, and Christoph Lenzen. Coupling molecular dynamics and continua with weak constraints. SIAM Journal on Multiscale Modeling & Simulation, 9(4):1459–1494, 2011. [GBBC+ 13] D. Groen, J. Borgdorff, C. Bona-Casas, J. Hetherington, R. W. Nash, S. J. Zasada, I. Saverchenko, M. Mamonski, K. Kurowski, M. O. Bernabeu, and A. G. Hoekstra P. V. Coveney. MAPPER: Flexible composition and execution of high performance, high fidelity multiscale biomedical simulations. Interface Focus, 3, 2013. http: //rsfs.royalsocietypublishing.org/content/3/2/20120087.short. [Gea84] C.W. Gear. Differential-algebraic equations. In EdwardJ. Haug, editor, Computer Aided Analysis and Optimization of Mechanical System Dynamics, volume 9 of NATO ASI Series, pages 323–334. Springer Berlin Heidelberg, 1984. [GGF+ 12] A. Grillo, C. Giverso, M. Favino, R. Krause, M. Lampe, and G. Wittum. Mass transport in porous media with variable mass. In J.M.P.Q. Delgado, Antonio Gilson Barbosa Lima, and Marta Vazquez Silva, editors, Numerical Analysis of Heat and Mass Transfer in Porous Media, volume 27 of Advanced Structured Materials, pages 27–61. Springer Berlin Heidelberg, 2012. [Glo12] Antoine Gloria. Numerical homogenization: survey, new results, and perspectives. ESAIM: Proceedings, 37:50–116, September 2012. [GR01] R. D. Groot and K. L. Rabone. Mesoscopic simulation of cell membrane damage, morphology change and rupture by nonionic surfactants. Biophys. J., 81(2):725, 2001. [Gro00] R. D. Groot. Mesoscopic simulation of polymer-surfactant aggregation. Langmuir, 16(19):7493, 2000. [GSS+ 14] S. Grein, M. Stepniewski, S.Reiter, M. Knodel, and G. Queisser. 1d-3d hybrid modelling - from multi-compartment models to full resolution models in space and time. Front. Neuroinform., 8(68), 2014. [GV14] John. M. A. Grime and Gregory A. Voth. Highly scalable and memory efficient ultra-coarse-grained molecular dynamics A survey on stochastic multi-scale modeling 21 simulations. Journal of Chemical Theory and Computation, 10(1):423–431, 2014. [GW97] R. D. Groot and P. B. Warren. Dissipative particle dynamics: Bridging the gap between atomistic and mesoscopic simulation. J. Chem. Phys., 107(11):4423, 1997. [GWvLM09] Friederike A. Gerhard, Duncan J. Webster, G. Harry van Lenthe, and Ralph Mller. In silico biology of bone modelling and remodelling: adaptation. Phil. Trans. R. Soc. A, 2009. [GZC14] D. Groen, S. J. Zasada, and P.V. Coveney. Survey of multiscale and multiphysics applications and communities. Computing in Science & Engineering, 16(2), 2014. [HG89] S. M. Hassanizadeh and W. G. Gray. Derivation of Conditions Describing Transport Across Zones of Reduced Dynamics Within Multiphase Systems. Water Resources Research, 25:529–539, 1989. [HH52] A. L. Hodgkin and A. F. Huxley. A quantitative description of membrane current and its application to conduction and excitation in nerve. The Journal of Physiology, 117(4):500– 544, 1952. [HH14] Daniel E. Hurtado and Duvan Henao. Gradient flows and variational principles for cardiac electrophysiology: Toward efficient and robust numerical simulations of the electrical activity of the heart. Comput. Methods Appl. Mech. Engrg., 273:238–254, 2014. [HK92] P. J. Hoogerbrugge and J. M. V. A. Koelman. Simulating microscopic hydrodynamic phenomena with dissipative particle dynamics. Europhys. Lett., 19(3):155, 1992. [HLW00] E. Haier, C. Lubich, and G. Wanner. Geometric Numerical Integration. Springer, second edition, 2000. [HPS13] Helmut Harbrecht, Michael Peters, and Markus Siebenmorgen. On multilevel quadrature for elliptic stochastic partial differential equations. In Jochen Garcke and Michael Griebel, editors, Sparse Grids and Applications, volume 88 of Lecture Notes in Computational Science and Engineering, pages 161– 179. Springer Berlin Heidelberg, 2013. [HS12] VIET HA HOANG and CHRISTOPH SCHWAB. Regularity and generalized polynomial chaos approximation of parametric and random second-order hyperbolic partial differential equations. Analysis and Applications, 10(03):295–326, 2012. A survey on stochastic multi-scale modeling 22 [HvCAH91] J. M. Huyghe, D. H. van Campen, T. Arts, and R. M. Heethaar. A two-phase finite element model of the diastolic left ventricle. Journal of Biomechanics, 24(7):527 – 538, 1991. [IPBV04] Sergei Izvekov, Michele Parrinello, Christian J. Burnham, and Gregory A. Voth. Effective force field for condensed phase systems: A new method for force-matching. J. Chem. Phys., 120:10896–10913, 2004. [IV05] Sergei Izvekov and Gregory A. Voth. A Multiscale CoarseGraining Method for Biomolecular Systems. J. Phys. Chem. B. Letters, 109:2469–2473, 2005. [JBC+ 99] S. Jury, P. Bladon, M. Cates, S. Krishna, M. Hagen, N. Ruddock, and P. Warren. Simulation of amphiphilic mesophases using dissipative particle dynamics. Phys Chem Chem Phys, 1(9):2051–2056, 1999. [KJ10] Rolf Krause and Steiner Johannes. Cosserat-rods and elastic bodies: On the numerical simulation of a coupled system. In John Middleton and Christopher Jacobs, editors, CMBBE2010 : 9th International Symposium on Computer methods in Biomechanics and Biomedical Engineering, Valencia, Spain, Valencia, Spain, November 2010. Arup, Solihull. [KK11] Dorian Krause and Rolf Krause. Parallel scale-transfer in multiscale MD-FE coupling using remote memory access. In eScience Workshops, pages 66–73, 2011. [KMV03] Markos A. Katsoulakis, Andrew J. Majda, and Dionisios G. Vlachos. Coarse-grained stochastic processes and monte carlo simulations in lattice systems. Journal of Computational Physics, 186:250–278, 2003. [KPD+ 12] Dorian Krause, Mark Potse, Thomas Dickopf, Rolf Krause, Angelo Auricchio, and Frits Prinzen. Hybrid parallelization of a large-scale heart model. In Rainer Keller, David Kramer, and Jan-Philipp Weiss, editors, Facing the Multicore - Challenge II, volume 7174 of Lecture Notes in Computer Science, pages 120–132. Springer Berlin Heidelberg, 2012. Available as ICS Preprint 2011-04. [KPMK05] E. E. Keaveny, I. V. Pivkin, M. Maxey, and G. E. Karniadakis. A comparative study between dissipative particle dynamics and molecular dynamics for simple- and complex-geometry flows. J. Chem. Phys., 123(10):104107, 2005. [KS98] James Keener and James Sneyd. Mathematical Physiology. Springer-Verlag New York, Inc., New York, NY, USA, 1998. A survey on stochastic multi-scale modeling 23 [LCGP06] Damien Lacroix, Arnaud Chateau, Maria-Pau Ginebra, and Josep A. Planell. Micro-finite element models of bone tissueengineering scaffolds. Biomaterials, 27(30):5326 – 5334, 2006. [LEE12] G. Lin, D. W. Engel, and P. W. Esliner. Survey and evaluate uncertainty quantification methodologies. Technical Report PNNL-20914, Pacific Northwest National Laboratory, Richland, Washington, 2012. [Loe78] M. Loeve. Probability theory. Springer, 1978. [LQG+ 10] Wing Kam Liu, Dong Qian, Stefano Gonella, Shaofan Li, Wei Chen, and Shardool Chirputkar. Multiscale methods for mechanical science of complex materials: Bridging from quantum to stochastic multiresolution continuum. Int. J. Numer. Meth. Engng, 83(8-9):10391080, 2010. [MBF+ 00] Hendrik Meyer, Oliver Biermann, Roland Fallera, Dirk Reith, and Florian Mller-Plathe. Coarse graining of nonbonded interparticle potentials using automatic simplex optimization to fit structural properties. J. Chem. Phys., 113:6264–6275, 2000. [MdVM04] Siewert J. Marrink, Alex. H. de Vries, and Alan E. Mark. Coarse grained model for semiquantitative lipid simulations. J. Phys. Chem. B, 108(2):750–760, 2004. [MFP+ 04] Teem Murtola, Emma Falck, Michael Patra, Mikko Kartuunen, and Ilpo Vattulainen. Coarse-grained model for phosholipid/cholesterol bilayer. J. Chem. Phys., 121:9156, 2004. [MKP+ 08] Luca Monticelli, Senthil K. Kandasamy, Xavier Periole, Ronald G. Larson, D. Peter Tielman, and Siewert J. Marrink. The MARTINI Coarse-Grained Force Field: Extension to Protein. J. Chem. T. Comp., 4:819–834, 2008. [MKSB11] CP May, E Kolokotroni, Stamatakos, and P. Büchler. Coupling biomechanics to a cellular level model: an approach to patient-specific image driven multi-scale and multi-physics tumor simulation. Prog Biophys Mol Biol., 2011. [MNL11] Andrea Malandrino, Jrme Noailly, and Damien Lacroix. The effect of sustained compression on oxygen metabolic transport in the intervertebral disc decreases with degenerative changes. PLoS Computational Biology, 7(8), 2011. [MRY+ 07] Siewert J. Marrink, H. Jelger Risselada, Serge Yefimov, D. Peter Toeleman, and Alex H. de Vries. The MARTINI Force Field: Coarse-Grained Model for Biomolecular Simulations. J. Phys. Chem. B., 111:7812–7824, 2007. A survey on stochastic multi-scale modeling [MT00] 24 P. Malfreyt and D. J. Tildesley. Dissipative particle dynamics simulations of grafted polymer chains between two walls. Langmuir, 16(10):4732–4740, 2000. [NaGSAK+ 08a] W. G. Noid, Jhih-Wei Chu adn Gary S. Ayton, Vind Krishna, Sergei Izvekov, Gregory A. Voth, Avisek Das, and Hans C. Andrsen. The multiscale coarse-graining method. i. A rigorous bridge between atomistic and coarse-grained models. J. Chem. Phys., 128:244114, 2008. [NaGSAK+ 08b] W. G. Noid, Jhih-Wei Chu adn Gary S. Ayton, Vind Krishna, Sergei Izvekov, Gregory A. Voth, Avisek Das, and Hans C. Andrsen. The multiscale coarse-graining method. ii. A rigorous bridge between atomistic and coarse-grained models. J. Chem. Phys., 128:244115, 2008. [NLSK04] Steve O. Nielsen, Carlos F. Lopez, Goundla Srinivas, and Michael L. Klein. Coarse Grained models and computer simulation of soft matters. J. Phys. Cond. Matt., 16:481–512, 2004. [PCK10] I. V. Pivkin, B. Caswell, and G. E. Karniadakis. Dissipative particle dynamics. In Reviews in Computational Chemistry, pages 85–110. John Wiley & Sons, Inc., 2010. [PCV+ 11] Esther Pueyo, Alberto Corrias, Laszlo Virag, Norbert Jost, Tamas Szel, Andras Varro, Norbert Szentandrassy, Peter P. Nanasi, Kevin Burrage, and Blanca Rodrguez. A multiscale investigation of repolarization variability and its role in cardiac arrhythmogenesis. Biophysical Journal, 2011. [PdLF+ 09] Tiziano Passerini, Mariarita de Luca, Luca Formaggia, Alfio Quarteroni, and Alessandro Veneziani. A 3d/1d geometrical multiscale model of cerebral vasculature. Journal of Engineering Mathematics, 2009. [PDR+ 06] M. Potse, B. Dube, J. Richer, A. Vinet, and R.M. Gulrajani. A comparison of monodomain and bidomain reaction-diffusion models for action potential propagation in the human heart. Biomedical Engineering, IEEE Transactions on, 53(12):2425– 2435, Dec 2006. [PK06] I. V. Pivkin and G. E. Karniadakis. Coarse-graining limits in open and wall-bounded dissipative particle dynamics systems. J. Chem. Phys., 124(18):184101, 2006. [PK08] I.V. Pivkin and G.E. Karniadakis. Accurate coarse-grained modeling of red blood cells. Physical Review Letters, 101, 2008. A survey on stochastic multi-scale modeling 25 [PL04] H. S. Park and W. K. Liu. An introduction and tutorial on multiple scale analysis in solids. Comp. Meth. Appl. Mech. Engrg., 193(17-20):1733–1772, 2004. [PLP+ 13] Z. L. Peng, X. J. Li, I. V. Pivkin, M. Dao, G. E. Karniadakis, and S. Suresh. Lipid bilayer and cytoskeletal interactions in a red blood cell. P Natl Acad Sci USA, 110(33):13356–13361, 2013. [PP14] Emanuel K. Peter and Igor V. Pivkin. A polarizable coarsegrained water model for dissipative particle dynamics. The Journal of Chemical Physics, 141(16):164506, 2014. [PRK06] I. V. Pivkin, P. D. Richardson, and G. Karniadakis. Blood flow velocity effects and role of activation delay time on growth and form of platelet thrombi. Proceedings of the National Academy of Sciences 103 (46),, 103(46):17164–17169, 2006. [PRK09] I. V. Pivkin, P. D. Richardson, and G. E. Karniadakis. Effect of red blood cells on platelet aggregation. Ieee Eng Med Biol, 28(2):32–37, 2009. [PS14] Manolis Papadrakakis and George Stefanou, editors. Proceedings of the IUTAM Symposium held at Santorini, Greece, September 9-11, 2013., 2014. [Sch03] M. Schanz. On the equivalence of the linear biots theory and the linear theory of porous media. ASCE Engineering Mechanics Conference, 2003. [Sch13] S. Schmitz. A Local and Probabilistic Model for Low-Cycle Fatigue – New Aspects of Structural Analysis. PhD thesis, Universitá della Svizzera italiana, 2013. [SDS+ 14] Erich Strohmaier, Jack Dongarra, Horst Simon, Martin Meuer, and Hans Meuer. Top 500 list, 2014. http://www.top500.org/lists/2014/11/. [SH98] J. C. Simo and T. J. R. Hughes. Compuational Inelasticity. Springer Verlag, 1998. [SHM95] A. G. Schlijper, P. J. Hoogerbrugge, and C. W. Manke. Computer-simulation of dilute polymer-solutions with the dissipative particle dynamics method. Journal of Rheology, 39(3):567–579, 1995. [SL02] Julian C. Shillcock and Reinhard Lipowsky. Equilibrium structure and lateral stress distribution of amphiphilic bilayers from dissipative particle dynamics simulations. The Journal of Chemical Physics, 117(10):5048, 2002. A survey on stochastic multi-scale modeling 26 [SM10] V. Savcenco and R. M. M. Mattheij. Multirate numerical integration for stiff odes. In Progress in Industrial Mathematics at ECMI 2008, pages 327–332, 2010. [Spe00] N. A. Spenley. Scaling laws for polymers in dissipative particle dynamics. Europhys Lett, 49(4):534–540, 2000. [SSR+ 01] John C. Shelley, Mee Y. Shelley, Robert C. Reeder, Sanjoy Bandyopadhyay, and Michael L. Klein. A Coarse Grain Model for Phospholipid Simulations. J. Phys. Chem. B., 105:4464– 4470, 2001. [TMBM94] J S Thomsen, Li Mosekilde, R W Boyce, and E Mosekilde. Stochastic simulation of vertebral trabecular bone remodeling. Bone, 15(6):655–666, November 1994. [Tro03] S. Y. Trofimov. Thermodynamic Consistency in Dissipative Particle Dynamics. PhD thesis, Eindhoven University of Technology, 2003. [VG12] F. J. Vermolen and A. Gefen. A semi-stochastic cell-based formalism to model the dynamics of migration of cells in colonies. Biomech Model Mechanobiol, 11:183–195, 2012. [VG13] F. J. Vermolen and A. Gefen. Multiscale Computer Modeling in Biomechanics and Biomedical Engineering., volume 14 of (Studies in Mechanobiological Engineering, chapter Wound healing: multi-scale modeling, pages 321–345. Springer, 2013. [Vot09] Gregory A. Voth, editor. Coarse-Graining of Condened Phase and Biomolecular Systems. CRC Press, Taylor and Francis Group, Raton Boca, 2009. [WL03] G. J. Wagner and W. K. Liu. Coupling of atomistic and continuum simulations using a bridging scale decomposition. J. Comp. Phys., 190(1):249–274, 2003. [XH05] Dongbin Xiu and Jan S. Hesthaven. High-order collocation methods for differential equations with random inputs. SIAM J. Sci. Comput., 2005. [XK02] D. Xiu and G. Karniadakis. The wiener–askey polynomial chaos for stochastic differential equations. SIAM Journal on Scientific Computing, 24(2):619–644, 2002. [YCT+ 08] X. Yin, W. Chen, A. C. To, C. McVeigh, and W. K. Liu. Statistical volume element method for predicting microstructureconstitutive property relations. Computer Methods in Applied Mechanics and Engineering, 2008.
5cs.CE
Local List Recovery of High-rate Tensor Codes & Applications Brett Hemenway∗ Noga Ron-Zewi† Mary Wootters‡ arXiv:1706.03383v1 [cs.IT] 11 Jun 2017 June 13, 2017 Abstract In this work, we give the first construction of high-rate locally list-recoverable codes. Listrecovery has been an extremely useful building block in coding theory, and our motivation is to use these codes as such a building block. In particular, our construction gives the first capacity-achieving locally list-decodable codes (over constant-sized alphabet); the first capacity achieving globally list-decodable codes with nearly linear time list decoding algorithm (once more, over constant-sized alphabet); and a randomized construction of binary codes on the Gilbert-Varshamov bound that can be uniquely decoded in near-linear-time, with higher rate than was previously known. Our techniques are actually quite simple, and are inspired by an approach of Gopalan, Guruswami, and Raghavendra (Siam Journal on Computing, 2011) for list-decoding tensor codes. We show that tensor powers of (globally) list-recoverable codes are ‘approximately’ locally list-recoverable, and that the ‘approximately’ modifier may be removed by pre-encoding the message with a suitable locally decodable code. Instantiating this with known constructions of high-rate globally list-recoverable codes and high-rate locally decodable codes finishes the construction. 1 Introduction List-recovery refers to the problem of decoding error correcting codes from “soft” information. More precisely, given a code C : Σk → Σn , which maps length-k messages to length-n codewords, an (α, ℓ, L)-list-recovery algorithm for C is provided with a sequence of lists S1 , . . . , Sn ⊂ Σ of size at most ℓ each, and is tasked with efficiently returning all messages x ∈ Σk so that C(x)i ∈ / Si for at most α fraction of the coordinates i; the guarantee is that there are no more than L such messages. The goal is to design codes C which simultaneously admit such algorithms, and which also have other desirable properties, like high rate (that is, the ratio k/n, which captures how much information can be sent using the code) or small alphabet size |Σ|. List-recovery is a generalization of list-decoding, which is the situation when the lists Si have size one: we refer to (α, 1, L)-list-recovery as (α, L)-list-decoding. List recoverable codes were first studied in the context of list-decoding and soft-decoding. The celebrated Guruswami-Sudan list-decoding algorithm [GS99] is in fact a list-recovery algorithm, as are several more recent list-decoding algorithms [GR08b, GW11, Kop15, GX13]. Initially, list ∗ [email protected]. Department of Computer Science, University of Pennsylvania [email protected]. Department of Computer Science, Ben-Gurion University ‡ [email protected]. Departments of Computer Science and Electrical Engineering, Stanford University † 1 recoverable codes were used as stepping stones towards constructions of list decodable and uniquely decodable codes [GI01, GI02, GI03, GI04]. Since then, list recoverable codes have found additional applications in the areas of compressed sensing, combinatorial group testing, and hashing [INR10, NPR12, GNP+ 13, HIOS15]. Locality is another frequent desideratum in coding theory. Loosely, an algorithm is “local” if information about a single coordinate xi of a message x of C can be determined locally from only a few coordinates of a corrupted version of C(x). Locality, and in particular local list-decoding, has been implicit in theoretical computer science for decades: for example, local list-decoding algorithms are at the heart of algorithms in cryptography [GL89], learning theory [KM93], and hardness amplification and derandomization [STV01]. The actual definition of a locally list-recoverable (or locally list-decodable) code requires some subtlety: we want to return a list of answers, and we want the algorithm to be local (having to do with a single message coordinate), but returning a list of possible symbols in Σ for a single message coordinate is pretty useless if that was our input to begin with (at least if the code is systematic in which case the message coordinates are a subset of the codeword coordinates). Instead, we require that a local list-recovery algorithm returns a list A1 , . . . , AL of randomized local algorithms. Each of these algorithms takes an index i ∈ [k] as input, and has oracle access to the lists S1 , . . . , Sn . The algorithm then makes at most Q queries to this oracle (that is, it sees at most Q different lists Si ), and must return a guess for xi , where x is a message whose encoding C(x) agrees with many of the lists. The guarantee is that for all such x—that is, for all x whose encoding C(x) agrees with many of the lists—there exists (with high probability) some Aj so that for all i, Aj (i) = xi with probability at least 2/3. The parameter Q is called the query complexity of the local list-recovery algorithm. One reason to study local list-recoverability is that list-recovery is a very useful building block throughout coding theory. In particular, the problem of constructing high rate locally listrecoverable codes (of rate arbitrarily close to 1, and in particular non-decreasing as a function of ℓ) has been on the radar for a while, because such codes would have implications in local listdecoding, global list-decoding, and classical unique decoding. In this work, we give the first constructions of high-rate locally list-recoverable codes. As promised, these lead to several applications throughout coding theory. Moreover, our construction is actually quite simple. Our approach is inspired by the list-decoding algorithm of [GGR11] for tensor codes, and our main observation is that this algorithm—with a few tweaks—can be made local. 1.1 Results We highlight our main results below—we will elaborate more on these results and their context within related literature next in Section 2. High-rate local list-recovery. Our main technical contribution is the first constructions of highrate locally list-recoverable codes: Theorems 5.5 and 5.6 give the formal statements. Theorem 5.5 can guarantee high-rate list recovery with query complexity n1/t (for constant t, say n0.001 ), constant alphabet size and constant output list size, although without an explicit construction or an efficient list recovery algorithm. Theorem 5.6 on the other hand gives an explicit and efficient version, at the cost of a slightly super-constant output list size (which depends on log∗ n). 2 For those familiar with the area, it may be somewhat surprising that this was not known before: indeed, as discussed below in Section 2, we know of locally list recoverable codes (of low rate), and we also know of high-rate (globally) list-recoverable codes. One might think that our result is lurking implicitly in those earlier works. However, it turns out that it is not so simple: as discussed below, existing techniques for locally or globally list-recoverable codes do not seem to work for this problem. Indeed, some of those prior works [HW15, KMRS16, GKO+ 17] (which involve the current authors) began with the goal of obtaining high-rate locally list-recoverable codes and ended up somewhere else. This raises the question: why might one seek high-rate locally list-recoverable error correcting codes in the first place? The motivation is deeper than a desire to add adjectives in front of “error correcting codes.” As we will see below, via a number of reductions that already exist in the literature, such codes directly lead to improvements for several other fundamental problems in coding theory, including fast or local algorithms for list and unique decoding. Capacity-achieving locally list-decodable codes. The first such reduction is an application of an expander-based technique of Alon, Edmunds, and Luby [AEL95], which allows us to turn the high-rate locally list-recoverable codes into capacity achieving locally list-decodable (or more generally, locally list recoverable) codes. Our main results are stated as Theorems 6.1 and 6.2. As before, Theorem 6.1 gives capacity achieving locally list decodable codes with query complexity n0.001 (say), constant alphabet size and constant output list size, although without an explicit construction or efficient list decoding algorithms. Theorem 6.2 on the other hand gives explicit and efficiently list decodable codes, and a trade-off between query complexity, alphabet size, and output list size. Specifically, these codes obtain query complexity Q = n1/t with an output list size and an alphabet size that grow doubly exponentially with t (and output list size depends additionally on log∗ n). In particular, if we choose t to be constant, we obtain query complexity n1/t , with constant alphabet size and nearly-constant output list size. We may also choose to take t to be very slowly growing, and this yields query complexity no(1) , with output list and alphabet size no(1) as well. Prior to this work, no construction of capacity achieving locally list decodable codes with query-complexity o(n) was known. Near-linear time capacity-achieving list-decodable codes. Given an efficiently list decodable capacity achieving locally list-decodable code (as given by Theorem 6.2 mentioned above), it is straightforward to construct fast algorithms for global list-decoding the same code. Indeed, we just repeat the local decoding algorithm (which can be done in time nO(1/t) ) a few times, for all n coordinates, and take majority vote at each coordinate. Thus, our previous result implies explicit, capacity-achieving, list-decodable codes (or more generally, list recoverable codes) that can be (globally) list-decoded (or list-recovered) in time n1+O(1/t) . This result is reported in Theorem 7.1. As with the previous point, this result actually allows for a trade-off: we obtain either decoding time N 1.001 (say) with constant alphabet size and near-constant output list size, or decoding time n1+o(1) at the cost of increasing the alphabet and output list size to no(1) . Previous capacity achieving list-decoding algorithms required at least quadratic time for recovery. Near-linear time unique decoding up to the Gilbert Varshamov bound. Via a technique of Thommesen [Tho83] and Guruswami and Indyk [GI04], our near-linear time capacity3 achieving list-recoverable codes give a randomized construction of low-rate (up to 0.02) binary codes approaching the Gilbert-Varshamov (GV) bound, which admit near-linear time (n1+o(1) ) algorithms for unique decoding up to half their distance. The formal statement is in Theorem 7.2. Previous constructions which could achieve this either required at least quadratic decoding time, or else did not work for rates larger than 10−4 . Our approach (discussed more below) is modular; given as an ingredient any (globally) high-rate list-recoverable code (with a polynomial time recovery algorithm), it yields high-rate (efficiently) locally list-recoverable code. To achieve the results advertised above, we instantiate this with either a random (non-efficient) linear code or with the (efficient) Algebraic Geometry (AG) subcodes of [GK16b]. Any improvements in these ingredient codes (for example, in the output list size of AG codes, which is near-constant but not quite) would translate immediately into improvements in our constructions. Organization. In Section 2 below, we discuss related work and put our results in context, followed by an overview of our techniques in Section 3. We set up notation and definitions in Section 4. Our main technical contribution is a construction of high-rate locally list-recoverable codes, and this is handled in Section 5. In Section 6, we discuss the implication to capacity-achieving local list decoding. Finally, Section 7 discusses our applications to near-linear-time decoding algorithms: Section 7.1 presents our results for global capacity-achieving list-decoding, and Section 7.2 presents our results for unique decoding up to the Gilbert-Varshamov bound. 2 Related work As mentioned above, list decoding and recovery, local decoding, and local list decoding and recovery, have a long and rich history in theoretical computer science. We mention here the results that are most directly related to ours mentioned above. High-rate local list recovery. Our main technical contribution is the construction of high-rate locally list-recoverable codes. There are two lines of work that are most related to this: the first is on local list recovery, and the second on high-rate (globally) list-recoverable codes. Local list-decoding (which is a special case of local list recovery) first arose outside of coding theory, motivated by applications in complexity theory. For example, the Goldreich-Levin theorem in cryptography and the Kushilevitz-Mansour algorithm in learning theory are a local list-decoding algorithm for Hadamard codes. Later, Sudan, Trevisan and Vadhan [STV01], motivated by applications in pseudorandomness, gave an algorithm for locally list-decoding Reed-Muller codes. Neither Hadamard codes nor the Reed-Muller codes of [STV01] are high-rate. However, similar ideas can be used to locally list-decode lifted codes [GK16a], and multiplicity codes [Kop15], which can be seen as high-rate variants of Reed-Muller codes. These algorithms work up to the so-called Johnson bound. Briefly, the Johnson √ bound says that a code of distance δ is (α, L)-list-decodable, for reasonable L, when α ≤ 1 − 1 − δ. This allows for high rate list decodable codes when δ is small, but there exist codes which are more list-decodable: the list-decoding capacity theorem implies that there are codes of distance δ which are (α, L)-list-decodable for α approaching the distance δ. The “capacity-achieving” list-decodable codes that we have been referring to are those which meet this latter result, which turns out to be optimal. 4 Like many list-decoding algorithms, the algorithms of [STV01, Kop15, GK16a] can be used for list-recovery as well (indeed, this type of approach was recently used in [GKO+ 17] to obtain a local list-recovery algorithm for Reed-Muller codes.) However, as mentioned above they only work up to the Johnson bound for list-decoding, and this holds for list-recovery as well. However, for list-recovery, the difference between the Johnson bound and capacity is pmuch more stark. Quantitatively, for (α, ℓ, L)-list-recovery, the Johnson bound requires α ≤ 1 − ℓ(1 − δ), which is meaningless unless δ is very large; this requires the rate of the code to be small, less than 1/ℓ. In particular, these approaches do not give high-rate codes for list-recovery, and the Johnson bound appears to be a fundamental bottleneck. The second line of work relevant to high-rate local list-recovery is that on high-rate global listrecovery. Here, there are two main approaches. The first is a line of work on capacity achieving listdecodable codes (also discussed more below). In many cases, the capacity achieving list-decoding algorithms for these codes are also high-rate list-recovery algorithms [GR08b, GW11, Kop15, GX13]. These algorithms are very global: they are all based on finding some interpolating polynomial, and finding this polynomial requires querying almost all of the coordinates. Thus, it is not at all obvious how to tweak these sorts of algorithms to achieve locally list-recoverable codes. The other line of work on high-rate global list-recovery is that of [HW15], which studies high-rate list-recoverable expander codes. While that algorithm is not explicitly local, it’s not as clearly global as those previously mentioned (indeed, expander codes are known to have some locality properties [HOW15]). However, that work could only handle list-recovery with no errors—that is, it returns codewords that agree with all of the lists Si , rather than a large fraction of them—and adapting it to handle errors seems like a challenging task. Thus, even with a great deal of work on locally list recoverable codes, and on high-rate globally list-recoverable codes, it was somehow not clear how to follow those lines of work to obtain high-rate locally list-recoverable codes. Our work, which does give high-rate locally list-recoverable codes, follows a different approach, based on the techniques of [GGR11] for list-decoding tensor codes. In fact, given their ideas and a few other ingredients, our solution is actually quite simple! We discuss our approach in more detail in Section 3. Capacity achieving locally list decodable codes. As mentioned above, one reason to seek high-rate codes is because of a transformation of Alon, Edmunds, and Luby [AEL95], recently highlighted in [KMRS16], which can, morally speaking, turn any high-rate code with a given property into a capacity achieving code with the same property.1 This allows us to obtain capacity achieving locally list-decodable (or more generally, locally list recoverable) codes. This trick has been used frequently over the years [GI01, GI02, GI03, GI04, HW15, KMRS16, GKO+ 17], and in particular [GKO+ 17] used it for local list recovery. We borrow this result from them, and this immediately gives our capacity achieving locally list-decodable codes. Once we have these, they straightforwardly extend to near-linear time capacity-achieving (globally) list-decodable (or more generally, locally list recoverable) codes, simply by repeatedly running the local algorithm on each coordinate. 1 We note however that this transformation does not apply to the property of list decoding, but just list recovery, and therefore we cannot use existing constructions of high-rate locally list decodable codes [Kop15, GK16a] as a starting point for this transformation. 5 Capacity-achieving list-decodable codes. We defined list-decodability above as a special case of list-recovery, but it is in fact much older. List-decodability has been studied since the work of Elias and Wozencraft [Eli57, Woz58] in the late 1950s, and the combinatorial limits are well understood. The list-decoding capacity theorem, mentioned earlier, states that there exist codes of rate approaching 1 − Hq (α) which are (α, L)-list-decodable for small list size L, where Hq (α) is the q-ary entropy function (when q is large we have 1 − Hq (α) ≈ 1 − α). Moreover, any code of rate larger than that must have exponentially large list size. The existence direction of the list-decoding capacity theorem follows from a random coding argument, and it wasn’t until the Folded Reed-Solomon Codes of Guruswami and Rudra [GR08b] that we had explicit constructions of codes which achieved list-decoding capacity. Since then, there have been many more constructions [Gur10, GW11, Kop15, DL12, GX12a, GX13, GK16b], aimed at reducing the alphabet size, reducing the list size, and improving the speed of the recovery algorithm. We show the state-of-the-art in Table 1 below, along with our results (Theorem 7.1). Code Reference Construction Alphabet size List size Decoding time Folded RS codes, derivative codes [GR08b, GW11, Kop15] Explicit poly(n) poly(n) nO(1/ε) Folded RS subcodes [DL12] Explicit poly(n) O(1) n2 (Folded) codes [GX12a, GX13] Monte Carlo O(1) O(1) nc AG subcodes [GK16b] Explicit O(1) exp(exp((log∗ n)2 )) nc Tensor codes Theorem 7.1 Explicit O(1) exp(exp(exp(log∗ n))) n1.001 AG sub- Table 1: Constructions of list-decodable codes that enable (α, L) list decoding up to rate ρ = 1 − Hq (α) − ε, for constant ε. We have suppressed the dependence on ε, except where it appears in the exponent on n in the decoding time. Above, c is an unspecified constant. In the analysis of these works, it is required to take c ≥ 3. It may be that these approaches could be adapted (with faster linear-algebraic methods) to use a smaller constant c, but it is not apparent; in particular we cannot see how to take c < 2. Unique decoding up to the Gilbert-Varshamov bound. The Gilbert-Varshamov (GV) bound [Gil52, Var57] is a classical achievability result in coding theory. It states that there exist binary codes of relative distance δ ∈ (0, 1) and rate ρ approaching 1− H2 (δ), where H2 is the binary entropy function. The proof is probabilistic: for example, it is not hard to see that a random linear code will do the trick. However, finding explicit constructions of codes approaching the GV bound remains one of the most famous open problems in coding theory. While we cannot find explicit constructions, we may hope for randomized constructions with efficient algorithms, and indeed this was achieved in the low-rate regime through a few beautiful ideas by Thommesen [Tho83] and follow-up work by Guruswami and Indyk [GI04]. Thommesen gave an efficient randomized construction of concatenated codes approaching the GV bound. Starting with a Reed-Solomon code over large alphabet, the construction is to concatenate each symbol with an independent random linear code. Later, [GI04] showed that these codes could in fact be efficiently decoded up to half their distance, in polynomial time, up to rates about 10−4 . 6 Their idea was to use the list recovery properties of Reed-Solomon codes. The algorithm is then to list decode the small inner codes by brute force, and to run the efficient list-recovery algorithm for Reed-Solomon on the output lists of the inner codes: the combinatorial result of Thommesen ensures that the output list will contain a message that corresponds to the transmitted codeword. In their work, [GI04] used the Guruswami-Sudan list recovery algorithm [GS99]. After decades of work [Ale02, BB10, CH11, BHNW13, CJN+ 15], this algorithm can now be implemented to run in near-linear time, and so we already can achieve near-linear time unique decoding near the GV bound, up to rates about 10−4 . The reason for the bound on the rate is that the GuruswamiSudan algorithm only works up to the aforementioned Johnson bound, which means it cannot tolerate as much error as capacity-achieving list-recoverable codes. It was noted by Rudra [Rud07] that replacing the Reed-Solomon codes with a capacity achieving list recoverable code (such as folded Reed-Solomon codes) can improve this rate limit up to about 0.02. However, those capacity achieiving list recovery algorithms were slower (as in Table 1), and this increases the running time back to at best quadratic. The recent work [GKO+ 17] also applied these techniques to give locally decodable codes approaching the Gilbert-Varshamov bound. These have query complexity nβ , and so in particular can be easily adapted to give a global decoding algorithm with running time O(n1+β ). However, the rate up to which the construction works approaches zero exponentially quickly in 1/β. Using exactly the same approach as these previous works, we may plug in our capacity achieving near-linear-time list-recooverable codes to obtain binary codes approaching the GV bound, which are uniquely decodable up to half their distance in time n1+o(1) , and which work with rate matching Rudra’s, ρ = 0.02. Remark 2.1. It is natural to ask whether our result can, like [GKO+ 17], give locally decodable codes on the GV bound of higher rate. In fact, we do not know how to do this. The main catch is that our locality guarantees are for local decoding rather than local correction. That is, we can only recover the message symbols and not the codeword symbols, and consequently we do not know how to choose the message from the output list that corresponds to the unique closest codeword. It is an interesting open question whether one can use our techniques to extend the results of [GKO+ 17] to higher rates. List-decodability and local properties of tensor codes. As we elaborate on more below in Section 3, our codes are constructed by taking tensor products of existing constructions of globally list-recoverable codes. Our approach is inspired by that of [GGR11], who study the list-decodability of tensor codes, although they do not address locality. It should be noted that the local testing properties of tensor codes have been extensively studied [BS06, Val05, CR05, DSW06, GM12, BV09, BV15, Vid11, Mei09, Vid13]. To the best of our knowledge, ours is the first work to study the local (list) decodability of tensor codes, rather than local testability. 3 Overview of techniques Our main technical contribution is the construction of high-rate locally list-recoverable codes. While these are powerful objects, and result in new sub-linear and near-linear time algorithms for fundamental coding theoretic tasks, our techniques are actually quite simple (at least if we take certain previous works as a black box). We outline our approach below. 7 Our main ingredient is tensor codes, and the analysis given by Gopalan, Guruswami, and Raghevendra in [GGR11]. Given a linear code C : Fk → Fn , consider the tensor code C ⊗ C : Fk×k → Fn×n ; we will define the tensor product formally in Definition 4.8, but for now, we will treat the codewords of C ⊗ C as n × n matrices with the constraints that the rows and columns are all codewords of the original code C. In [GGR11], it is shown that the tensor code C ⊗ C is roughly as list-decodable as C is. That work was primarily focused on combinatorial results, but their techniques are algorithmic, and it is these algorithmic insights that we leverage here. The algorithm is very simple: briefly, we imagine fixing some small combinatorial rectangle S × T ⊆ [n] × [n] of “advice.” Think of this advice as choosing the symbols of the codeword indexed by those positions. By alternately list decoding rows and columns, it can be shown that this advice uniquely determines a codeword c of C ⊗ C. Finally, iterating over all possible pieces of advice yields the final list. Inspired by their approach, our Main Technical Lemma 5.2 says that if C is list-recoverable, then not only C ⊗ C is also list-recoverable, but in fact it is (approximately) locally list-recoverable. To understand the intuition, let us describe the algorithm just for C ⊗ C, although our actual codes will require a higher tensor power C ⊗t . Suppose that C is list-recoverable with output list size L. First, imagine fixing some advice J := (j1 , . . . , jm ) ∈ [L]m for some (small integer) parameter m. eJ which attempts to locally decode some message that This advice will determine an algorithm A corresponds to a close-by codeword c of C ⊗ C, and the list we finally return will be the list of all eJ obtained by iterating over all possible advice. algorithms A eJ , on input (i, i′ ) ∈ [n] × [n].2 Recall, A eJ is Now, we describe the randomized algorithm A allowed to query the input lists at every coordinate, and must produce a guess for the codeword eJ chooses m random rows of [n] × [n]. These each correspond to value indexed by (i, i′ ). First, A e codewords in C, and AJ runs C’s list-recovery algorithm on them to obtain lists L1 , . . . , Lm of size at most L each. Notice that this requires querying mn coordinates, which is roughly the square eJ will use the advice j1 , . . . , jm to choose root of the length of the code (which is n2 ). Then, A codewords from each of these lists, and we remember the i′ ’th symbol of each of these codewords. eJ again runs C’s list-recovery algorithm on the i′ ’th column, to obtain another list L. Finally, A Notice that our advice now has the same form as it does in [GGR11]: we have chosen a few symbols eJ chooses the codeword in L that agrees the most with this advice. The of a codeword of C. Now A ′ eJ ’s guess for the (i, i′ ) symbol of the tensor codeword. i ’th symbol of this codeword is A The above idea gives a code of length n which is locally list-recoverable with query complexity √ on the order of n. This algorithm for C ⊗ C extends straightforwardly to C ⊗t , with query complexity n1/t . The trade-off is that the output list-size also grows with t. Thus, as we continue to take tensor powers, the locality improves, while the output list-size degrades; this allows for the trade-off between locality and output list-size mentioned in the introduction. One issue with this approach is that this algorithm may in fact fail on a constant fraction of coordinates (i, i′ ) (e.g., when a whole column is corrupted). To get around this, we first encode our message with a high-rate locally decodable code, before encoding it with the tensor code. For this, we use the codes of [KMRS16], which have rate that is arbitrarily close to 1, and which are √ locally decodable with exp( log n) queries. This way, instead of directly querying the tensor code (which may give the wrong answer a constant fraction of the time), we instead use the outer locally decodable code to query the tensor code: this still does not use too many queries, but now it is 2 eJ we describe decodes codeword bits instead of messages bits, but since the codes we use are The algorithm A systematic this algorithm can also decode message bits. 8 robust to a few errors. The final question is what to use as an inner code. Because we are after high-rate codes we require C to be high-rate (globally) list recoverable. Moreover, since the tensor operation inflates the output list size by quite a lot, we require C to have small (constant or very slowly growing) output list size. Finally, we need C to be linear to get a handle on the rate of the tensor product. One possible choice is random linear codes, and these give a non-explicit and non-efficient construction with constant output list size. Another possible choice is the Algebraic Geometry subcodes of [GX13, GK16b] which give explicit and efficient construction but with slowly growing output list size. However, we cannot quite use these latter codes as a black box, for two reasons. First, the analysis in [GX13] only establishes list-decodability, rather than list-recoverability. Fortunately, list-recoverability follows from exactly the same argument as list-decodability. Second, these codes are linear over a subfield, but are not themselves linear, while our arguments require linearity over the whole alphabet. Fortunately, we can achieve the appropriate linearity by concatenating the AG subcode with a small list-recoverable linear code, which exists by a probabilistic argument. We handle these modifications to the approach of [GX13, GK16b] in Appendix A. To summarize, our high-rate locally list-recoverable code is given by these ingredients: to encode a message x, we first encode it with the [KMRS16] locally decodable code. Then we encode this with a t-fold tensor product of a random linear code or a modified AG subcode and we are done. We go through the details of the argument sketched above in Section 5; but first, we introduce some notation and formally define the notions that we will require. 4 Definitions and preliminaries For a prime power q we denote by Fq the finite field of q elements. For any finite alphabet Σ and for any pair of strings x, y ∈ Σn , the relative distance between x and y is the fraction of coordinates i ∈ [n] on which x and y differ, and is denoted by dist(x, y) := |{i ∈ [n] : xi 6= yi }| /n. For a positive  integer ℓ we denote by Σℓ the set containing all subsets of Σ of size ℓ, and for any pair of strings n / Si , x ∈ Σn and S ∈ Σℓ we denote by dist(x, S) the fraction of coordinates i ∈ [n] for which xi ∈ that is, dist(x, S) := |{i ∈ [n] : xi ∈ / Si }| /n. Throughout the paper, we use exp(n) to denote 2Θ(n) . Whenever we use log, it is to the base 2. 4.1 Error-correcting codes Let Σ be an alphabet and k, n be positive integers (the message length and the block length, respectively). A code is an injective map C : Σk → Σn . The elements in the domain of C are called messages and the elements in the image of C are called codewords. If F is a finite field and Σ is a vector space over F, we say that C is F-linear if it is a linear transformation over F between the F-vector spaces Σk and Σn . If Σ = F and C is F-linear, we simply say that C is linear. The generating matrix of a linear code C : Fk → Fn is the matrix G ∈ Fn×k such that C(x) = G · x for any x ∈ Fk . We say that a code C : Σk → Σn is systematic if any message is the prefix of its image, that is, for any x ∈ Σk there exists y ∈ Σn−k such that C(x) = (x, y). The rate of a code C : Σk → Σn is the ratio ρ := nk . The relative distance dist(C) of C is the minimum δ > 0 such that for every pair of distinct messages x, y ∈ Σk it holds that dist(C(x), C(y)) ≥ δ. For a code C : Σk → Σn of relative distance δ, a given parameter α < δ/2, and a string w ∈ Σn , the problem of decoding from α fraction of errors is the task of finding the unique message x ∈ Σk 9 (if any) which satisfies dist(C(x), w) ≤ α. The best known general trade-off between rate and distance of codes is the Gilbert-Varshamov bound, attained by random (linear) codes. For x ∈ [0, 1] let Hq (x) = x logq (q − 1) + x logq (1/x) + (1 − x) logq (1/(1 − x)) denote the q-ary entropy function. Theorem 4.1 (Gilbert-Varshamov (GV) bound, [Gil52, Var57]). For any prime power q, 0 ≤ δ < n 1 − 1q , 0 ≤ ρ < 1 − Hq (δ), and sufficiently large n, a random linear code C : Fρn q → Fq of rate ρ has relative distance at least δ with probability at least 1 − exp(−n). 4.2 List decodable and list recoverable codes List decoding is a paradigm that allows one to correct more than δ/2 fraction of errors by returning a small list of messages that correspond to close-by codewords. More formally, for α ∈ [0, 1] and an integer L we say that a code C : Σk → Σn is (α, L)-list decodable if for any w ∈ Σn there are at most L different messages x ∈ Σk which satisfy that dist(C(x), w) ≤ α. For list decoding concatenated codes it is useful to consider the notion of list recovery where one is given as input a small list of candidate symbols for each of the codeword coordinates, and is required to output a list of messages such that the corresponding codewords are consistent with the input lists. More concretely, for α ∈ [0, 1] and integers ℓ, L we say that a code C : Σk → Σn Σn is (α, ℓ, L)-list recoverable if for any S ∈ ℓ there are at most L different messages x ∈ Σk which satisfy that dist(C(x), S) ≤ α. It is well-known that 1 − Hq (α) is the list decoding capacity, that is, any q-ary code of rate above 1 − Hq (α) cannot be list decoded from α fraction of errors with list size polynomial in the block length, and on the other hand, a random q-ary (linear) code of rate below 1 − Hq (α) can be list decoded from α fraction of errors with small list size. Theorem 4.2 ([Gur01], Theorem 5.3). For any prime power q, 0 ≤ α < 1 − 1q , 0 ≤ ρ < 1 − Hq (α) − 1 , logq (L + 1) n and sufficiently large n, a random linear code C : Fρn q → Fq of rate ρ is (α, L)-list decodable with probability at least 1 − exp(−n). The following is a generalization of the above theorem to the setting of list recovery. Theorem 4.3 ([Gur01], Lemma 9.6). For any prime power q, integers 1 ≤ ℓ ≤ q and L > ℓ, 0 ≤ α ≤ 1,   1 q 0≤ρ< · (1 − α) · log(q/ℓ) − H2 (α) − H2 (ℓ/q) · , log q logq (L + 1) n and sufficiently large n, a random linear code C : Fρn q → Fq of rate ρ is (α, ℓ, L)-list recoverable with probability at least 1 − exp(−n). Over large alphabet the above theorem yields the following. 10 Corollary 4.4. There is a constant c so that the following holds. Choose ρ ∈ [0, 1], ε > 0, and a positive integer ℓ. Suppose that q is a prime power which satisfies q ≥ max{(1 − ρ − ε)−c(1−ρ−ε)/ε , (ρ + ε)−c(ρ+ε)/ε , ℓc/ε }. n cℓ/ε )-list Then for sufficiently large n, a random linear code C : Fρn q → Fq of rate ρ is (1 − ρ − ε, ℓ, q recoverable with probability at least 1 − exp(−n). Proof. Follows by observing that in the above setting of parameters,   q 1 · (ρ + ε) · log(q/ℓ) − H2 (1 − ρ − ε) − H2 (ℓ/q) · log q cℓ/ε log ℓ (1 − ρ − ε) log(1/(1 − ρ − ε)) (ρ + ε) log(1/(ρ + ε)) − − − O(ε/c) ≥ ρ+ε− log q log q log q ≥ ρ + ε − O(ε/c), so the corollary holds for sufficiently large constant c. 4.3 Locally decodable codes Intuitively, a code C is said to be locally decodable if, given a codeword C(x) that has been corrupted by some errors, it is possible to decode any coordinate of the corresponding message x by reading only a small part of the corrupted version of C(x). Formally, it is defined as follows. Definition 4.5 (Locally decodable code (LDC)). We say that a code C : Σk → Σn is (Q, α)-locally decodable if there exists a randomized algorithm A that satisfies the following requirements: • Input: A takes as input a coordinate i ∈ [k], and also gets oracle access to a string w ∈ Σn that is α-close to some codeword C(x). • Query complexity: A makes at most Q queries to the oracle w. • Output: A outputs xi with probability at least 23 . Remark 4.6. By definition it holds that α < dist(C)/2. The above success probability of 32 can be amplified using sequential repetition, at the cost of increasing the query complexity. Specifically, amplifying the success probability to 1 − e−t requires increasing the query complexity by a multiplicative factor of O(t). Locally list decodable and list recoverable codes. The following definition generalizes the notion of locally decodable codes to the setting of list decoding / recovery. In this setting the algorithm A is required to find all messages that correspond to nearby codewords in an implicit sense. Definition 4.7 (Locally list recoverable code). We say that a code C : Σk → Σn is (Q, α, ℓ, L)locally list recoverable if there exists a randomized algorithm A that satisfies the following requirements: • Preprocessing: A outputs L randomized algorithms A1 , . . . , AL . 11 • Input: Each Aj takes as input a coordinate i ∈ [k], and also gets oracle access to a string n S ∈ Σℓ . • Query complexity: Each Aj makes at most Q queries to the oracle S. • Output: For every codeword C(x) that is α-close to S, with probability at least 32 over the randomness of A the following event happens: there exists some j ∈ [L] such that for all i ∈ [k], 2 Pr[Aj (i) = xi ] ≥ , 3 where the probability is over the internal randomness of Aj . We say that A has preprocessing time Tpre if A outputs the description of the algorithms A1 , . . . , AL in time at most Tpre , and has running time T if each Aj has running time at most T . Finally, we say that C is (Q, α, L)-locally list decodable if it is (Q, α, 1, L)-locally list recoverable. 4.4 Tensor codes A main ingredient in our constructions is the tensor product operation, defined as follows. Definition 4.8 (Tensor codes). Let C1 : Fk1 → Fn1 , C2 : Fk2 → Fn2 be linear codes, and let G1 ∈ Fn1 ×k1 , G2 ∈ Fn2 ×k2 be the generating matrices of C1 , C2 respectively. Then the tensor code C1 ⊗ C2 : Fk1 ×k2 → Fn1 ×n2 is defined as (C1 ⊗ C2 )(M ) = G1 · M · GT2 . Note that the codewords of C1 ⊗C2 are n1 ×n2 matrices over F whose columns belong to the code C1 and whose rows belong to the code C2 . The following effects of the tensor product operation on the classical parameters of the code are well known (see e.g. [Sud01, DSW06]). Fact 4.9. Suppose that C1 : Fk1 → Fn1 , C2 : Fk2 → Fn2 are linear codes of rates ρ1 , ρ2 and relative distances δ1 , δ2 respectively. Then the tensor code C1 ⊗ C2 has rate ρ1 · ρ2 and relative distance δ1 · δ2 . For a linear code C, let C ⊗1 := C and C ⊗t := C ⊗ C ⊗(t−1) . Then by the above, if C has rate ρ and relative distance δ then C ⊗t has rate ρt and relative distance δt . 5 High-rate locally list recoverable codes We start by showing the existence of high-rate locally list recoverable codes. For this we first show in Section 5.1 below that high-rate tensor codes are approximately locally list recoverable, namely there exists a short list of local algorithms that can recover most of the coordinates of messages that correspond to near-by codewords. We then observe in Section 5.2 that by pre-encoding the message with a locally decodable code, the former codes can be turned into locally list recoverable codes for which the local algorithms can recover all the coordinates of messages that correspond to near-by codewords. Finally, we show in Section 5.3 how to instantiate the codes used in the process in order to obtain high-rate locally list recoverable codes with good performance. 12 5.1 Approximate local list recovery We start by showing that high-rate tensor codes are approximately locally list recoverable as per Definition 5.1 below. As noted above, the main difference between approximately locally list recoverable codes and locally list recoverable codes (Definition 4.7) is that in the former we only require that the local algorithms recover most of the coordinates. A simple averaging argument then shows that in the case of approximate local list recovery each of the local algorithms in the output list can be assumed to be deterministic. Finally, to describe our approximate local list recovery algorithm it will be more convenient to require that the local algorithms recover codeword bits as opposed to message bits3 . Definition 5.1 (Approximately locally list recoverable code). We say that a code C : Σk → Σn is (Q, α, ε, ℓ, L)-approximately locally list recoverable if there exists a randomized algorithm A that satisfies the following requirements: • Preprocessing: A outputs L deterministic algorithms A1 , . . . , AL . • Input: Each Aj takes as input a coordinate i ∈ [n], and also gets oracle access to a string n S ∈ Σℓ . • Query complexity: Each Aj makes at most Q queries to the oracle S. • Output: For every codeword C(x) that is α-close to S, with probability at least 1 − ε over the randomness of A the following event happens: there exists some j ∈ [L] such that Pr [Aj (i) = C(x)i ] ≥ 1 − ε, i∈[n] where the probability is over the choice of uniform random i ∈ [n]. As before, we say that A has preprocessing time Tpre if A outputs the description of the algorithms A1 , . . . , AL in time at most Tpre , and has running time T if each Aj has running time at most T . Our main technical lemma is the following. Lemma 5.2 (Main technical). Suppose that C : Fk → Fn is a linear code of relative distance δ e := C ⊗t : that is (α, ℓ, L)-(globally) list recoverable. Then for any εe > 0, the tensor product code C t t O(t) n k e α e e, εe, ℓ, L)-approximately locally list recoverable for α e = α · εe · δ , F → F is (Q, and e =n· Q e = exp L  logt L , (α · εe)O(t) · δO(t2 ) logt L 2 (α · εe)O(t) · δO(t )  . e has preprocessing time Moreover, the approximate local list recovery algorithm for C   t log L Tepre = log n · exp , 2 (α · εe)O(t) · δO(t ) 3 In our constructions we shall use systematic codes and so recovery of codeword bits will imply also recovery of message bits. 13 and if the (global) list recovery algorithm for C runs in time T then the approximate local list e runs in time recovery algorithm for C Te = T · logt L . (α · εe)O(t) · δO(t2 ) The proof of the above lemma will follow from repeated application of the following technical lemma. Lemma 5.3. Suppose that C : Fk → Fn is a linear code of relative distance δ that is (α, ℓ, L)′ ′ (globally) list recoverable, and C ′ : Fk → Fn is a linear code that is (Q′ , α′ , ε′ , ℓ, L′ )-approximately e := C ⊗ C ′ : Fk×k′ → locally list recoverable. Then for any εe ≥ 100ε′ /δ, the tensor product code C ′ 1 e α e · min {α′ · δ, α · εe}, e, εe, ℓ, L)-approximately locally list recoverable for α e = 10 Fn×n is (Q,   log(L/e ε) e Q=O · Q′ + n, (δ · α′ · εe)2 and e = exp L  log L′ · log(L/e ε) (δ · α′ · εe)2  . Moreover, if the (global) list recovery algorithm for C runs in time T , and the approximate local list ′ recovery algorithm for C ′ has preprocessing time Tpre and runs in time T ′ , then the approximate e has preprocessing time local list recovery algorithm for C     log L′ · log(L/e ε) log(L/e ε) ′ e · (log n + Tpre ) + exp , Tpre = O (δ · α′ · εe)2 (δ · α′ · εe)2 and runs in time Te = O  log(L/e ε) (δ · α′ · εe)2  · T ′ + T. Before we prove the above lemma we show how it implies the Main Technical Lemma 5.2. Proof of Lemma 5.2. The proof proceeds by repeated application of Lemma 5.3 to the code C. For a fixed εe > 0, our goal is to find parameters Q(t) , α(t) , L(t) such that C ⊗t is a (Q(t) , α(t) , εe, ℓ, L(t) )approximately locally list recoverable code. We begin by defining ε(i) := where the factor · · · > ε(1) , and δ 100  δ 100 t−i εe for i = 1, . . . , t , comes from Lemma 5.3. With this definition, we have εe = ε(t) > ε(t−1) > εe = ε(t) =  100 δ t−1 ε(1) . When t = 1, we have C ⊗t = C, which means Q(1) = n, α(1) = α, L(1) = L, and this holds for any ε(1) > 0, and hence for any εe > 0, since C is actually list recoverable (not just approximately). Since C ⊗i = C ⊗ C ⊗(i−1) , by Lemma 5.3, we have the following recursive relationships 14 1 min(α(i−1) δ, αε(i) ) 10 log(L/ε(i) ) := 2 δα(i−1) ε(i) α(i) = m(i) Q(i) = m(i) Q(i−1) + n m (i) L(i) = L(i−1) T(i) = m(i) · T(i−1) + T   m(i) (Tpre )(i) = m(i) · log n + (Tpre )(i−1) + L(i−1) Solving these recursions gives the following bounds on the parameters of interest. The distance parameter, α(t) , satisfies 1 min(α(t−1) δ, αε(t) ) 10 1 ≥ min(α(t−1) δ, αε(1) ) 10  t−1 δ αε(1) ≥ 10   t−1  δ t−1 δ α εe = 10 100  2 t−1 δ = αe ε. 1000 α(t) = Notice that as i increases, the parameters ε(i) are increasing, whereas the parameters α(i) are 1 min(α(i−1) , ε(i) ) < decreasing. Nevertheless, α(i) ε(i) > α(i−1) ε(i−1) . To see this note that α(i) < 10 ε(i) for all i, which means 100 10 α = min(α(i−1) δ, ε(i) ) > α(i−1) , δ (i) δ where the last inequality follows since αi−1 < εi−1 < εi . Multiplying both sides by ε(i) , we conclude that α(i) ε(i+1) > α(i−1) ε(i) , as desired. Now, notice that since ε(i−1) < ε(i) and α(i) ε(i+1) > α(i−1) ε(i) , we have m(i−1) = Thus log(L/ε(i−1) ) log(L/ε(i) ) 2 ≥ 2 = m(i) δα(i−2) ε(i−1) δα(i−1) ε(i) m(2) ≥ m(3) ≥ · · · ≥ m(t) Notice that m(2) log(L/ε(2) ) log( = 2 =  δα(1) ε(2) δα  100 t−2 L/ε(t) ) δ 2  δ t−2 ε (t) 100 15 ≤ log(  100 t−2 L/ε(t) ) δ  2t δ α2 ε2(t) 100 ≤ log(L/ε(t) )  δ 3t 2 2 α ε(t) 100 Where last inequality holds since log(ax) ≤ a log(x) when log(x) ≥ log(a)/(a − 1). The output list size, L(t) , satisfies L(t) = L ≤L Qt−1 i=2 m(i) mt−1 (2)   = exp (log L) · mt−1 (2) logt (L/e ε) 2  3t δ α2t εe2t 100 ≤ exp The query complexity, Q(t) , satisfies  Q(t) = n 1 + t−1 t−1 Y X i=2 j=i ≤ (t − 1)nmt−1 (2) The running time, T(t) , satisfies T(t) = T t−1 Y i=2  m(i) + T 1 + t ≤T log (L/e ε)  2 δ 3t 100 The pre-processing time, (Tpre )(t) , satisfies α2t εe2t ! .  m(j)  logt (L/e ε) 2  3t δ α2t εe2t 100 ≤n ! ! . t−1 t−1 Y X i=2 j=i  m(j)  .    (Tpre )(t) = m(t) · log n + (Tpre )(t−1) + exp m(t) log L(t−1)   t−1 t−1 t t−1 Y X Y X m(j) L(i) m(j)  + = log n · 1 + i=2 j=i j=i i=1 t−1 ≤ mt−1 (2) t log n + tm(2) L(t) ≤ (t log n + tL(t) )mt−1 (2) logt (L/e ε) ≤ t log n + t exp 2  3t δ α2t εe2t 100   logt L ≤ log n · exp (α · εe)O(t) · δO(t2 ) 16 !! logt (L/e ε) 2  3t δ α2t εe2t 100 We proceed to the proof of Lemma 5.3. e that outputs a list of (deterProof of Lemma 5.3. Our goal is to find a randomized algorithm A e e c ∈ C ⊗ C ′ that is consistent with ministic) local algorithms A1 , . . . , ALe such that for any codeword e ei in the most of the input lists, with high probability over the randomness of A, there exists some A output list that computes correctly most of the coordinates of e c. e e We first describe the algorithm  A. The  algorithm A first chooses a uniform random subset log(L/e ε) R ⊆ [n] of rows of size m := O (δ·α′ ·eε)2 . It then runs for each row r ∈ R, independently, the approximate local list recovery algorithm A′ for C ′ , let Ar1 , . . . , ArL′ denote the output algorithms on row r. Finally, for every possible choice of a single local algorithm Arjr per each of the rows e outputs a local algorithm denoted A eJ where J := (jr )r∈R ∈ [L′ ]R . The r ∈ R, the algorithm A eJ is given below, followed by an informal description. formal definition of the algorithm A Algorithm 1 The approximate local list recovery algorithm for C ⊗ C ′ . eJ ((i, i′ ) ∈ [n] × [n′ ]) function A ′  eJ receives oracle access to a matrix of lists S ∈ F n×n ⊲A ℓ ⊲ J = (jr )r∈R ∈ [L′ ]R for r ∈ R do Run Arjr on input i′ and oracle access to the rth row S|{r}×[n′ ] . Let c′r ← Arjr (i′ ). ⊲ c′r is a candidate for the symbol at position (r, i′ ) ∈ [n] × [n′ ]. end for ⊲ At this point, we have candidate symbols for every position in R × {i′ }. Run the (global) list recovery algorithm for C on the i′ th column S|[n]×{i′ } . Let L ⊆ Fn denote the output list. Choose a codeword c ∈ L such that c|R is closest to (c′r )r∈R (breaking ties arbitrarily). Return: ci end function eJ is given as input a codeword coordinate (i, i′ ) ∈ [n] × [n′ ] in the Recall, that the algorithm A ′ tensor product code C ⊗ C , is allowed to query the input lists at every coordinate, and must eJ first produce a guess for the codeword value indexed by (i, i′ ). To this end, the algorithm A r ′ runs on each row r ∈ R the local recovery algorithm Ajr for C that is specified by the choice of J = (jr )r∈R on input i′ and oracle access to the rth row. For each row r ∈ R let c′r be the guess for the symbol at position (r, i′ ) ∈ [n] × [n′ ] produced by Arjr . At this point we have candidate eJ runs the global list recovery algorithm for C on symbols for all positions in R × {i′ }. Now, A ′ the i th column and chooses a codeword c ∈ C from the output list that agrees the most with the eJ ’s guess for the (i, i′ ) candidate symbols (c′r )r∈R on this column. Finally, the ith symbol of c is A symbol of the tensor codeword. Next we prove the correctness of the purposed local list recovery algorithm, followed by an analysis of its performance. e = C ⊗ C ′ such that dist(e Correctness: Let e c be a codeword of C c, S) ≤ α e. Our goal is to show e eJ that with probability at least 1 − εe over the randomness of A, there exists some local algorithm A e in the output list of A that computes correctly at least 1 − εe fraction of the coordinates of e c. 17 eJ above is obtained. Recall that Ar is the local algorithm We first explain how the algorithm A jr that computes the jr th “guess” for the codeword on the rth row. For every row r ∈ R let jr ∈ [L′ ] c on the rth row among all local algorithms Ar1 , . . . , ArL′ be such that Arjr agrees the most with e (breaking ties arbitrarily), and let J = (jr )r∈R . We shall show below that with probability at least e it holds that A eJ computes correctly at least 1 − εe fraction of the 1 − εe over the randomness of A, coordinates of e c. The high level idea of the proof is as follows. First, we observe that since the rows in R are chosen uniformly at random, and by averaging, with high probability for most rows r ∈ R it holds that e c is consistent with most of the input lists on the row. Let us denote by Rgood ⊆ R the subset of these ’good’ rows. By the local list recovery guarantee for C ′ , with high probability on each c on this such good row r ∈ Rgood the algorithm Arjr computes correctly most of the coordinates of e row. Now, by another averaging argument this implies in turn that for most columns i′ ∈ [n′ ] it holds that both e c is consistent with most of the input lists on the columnn and additionally, most of the guesses (c′r )r∈R for this column are correct. As above, let us denote by Colgood ⊆ [n′ ] the subset of these ’good’ columns. Finally, by the list recovery guarantee for C, on any good column i′ ∈ Colgood the i′ th column e c|[n]×{i′ } of e c is present in the output list L, and we further show that with high probability e c|[n]×{i′ } is closest to (c′r )r∈R on R among all codewords in L, in which case eJ outputs the correct (i, i′ ) symbol of e A c. Details follow. We start by showing the existence of a large subset of good rows Rgood ⊆ R. For this observe 1 ·α′ ·δ, by Chernoff bound that since the rows in R are chosen uniformly at random, and since α e ≤ 10 (without replacement, see e.g. Lemma 5.1 in [GGR11]), with probability at least 1 − exp(−(α′ · ′ δ)2 m) ≥ 1− 3εe over the choice of R, it holds that dist(e c|R×[n′ ] , S|R×[n′ ] ) ≤ α8·δ . If this is the case, then  c|{r}×[n′ ] , S|{r}×[n′ ] ≤ α′ . by averaging, for at least 1− 8δ fraction of the rows r ∈ R it holds that dist e Let   Rgood = r ∈ R | dist e c|{r}×[n′ ] , S|{r}×[n′ ] ≤ α′ . Now we observe that for each good row r ∈ Rgood , with high probability over the randomness c on this row. For this of A′ the algorithm Arjr computes correctly most of the coordinates of e 1 1 ′ note that since 1 − ε ≥ 1 − 100 · δ · εe, with probability at least 1 − 100 · δ · εe over the randomness 1 · δ · εe of A′ , independently for each row r, it holds that Arjr computes correctly at least 1 − 100 fraction of the coordinates of e c|{r}×[n′ ] . Consequently, by Chernoff bound with probability at least e it holds that (Ar )r∈R 1 − exp(−(δ · εe)2 · m) ≥ 1 − 3εe over the randomness of A, compute correctly good jr 1 at least 1 − 24 · δ · εe fraction of the coordinates of e c|Rgood ×[n′ ] . Finally, if this is the case then for   at least 1 − 3εe fraction of the columns i′ ∈ [n′ ] it holds that dist e c|Rgood ×{i′ } , (Arjr (i′ ))r∈Rgood ≤ 8δ . Next we show the existence of a large subset of good columns Colgood ⊆ [n′ ]. So far we obtained εe e εe over the randomness that with probability at least 1 − 23 ·   of A, for at least 1 − 3 fraction of e≤ the columns i′ ∈ [n′ ] it holds that dist e c|R×{i′ } , (Arjr (i′ ))r∈R ≤ δ4 . Moreover, note that since α 1 10 · α · εe, for at least 1 − 3εe fraction of the columns i′ ∈ [n′ ] it holds that dist(e c|[n]×{i′ } , S|[n]×{i′ } ) ≤ α. Let    δ ′ ′ r ′ Colgood = i ∈ [n ] | dist(e c|[n]×{i′ } , S|[n]×{i′ } ) ≤ α and dist e c|R×{i′ } , (Ajr (i ))r∈R ≤ . 4 Then by the above, with probability at least 1 − |Colgood | ≥ (1 − 23 · εe)|n′ |. 18 2 3 e it holds that · εe over the randomness of A Now for each column i′ ∈ Colgood it holds that dist(e c|[n]×{i′ } , S|[n]×{i′ } ) ≤ α, and so e c|[n]×{i′ } ′ must be in the output list L of the i th column. Moreover, since the code C has relative distance δ, any codeword ĉ ∈ L other than e c|[n]×{i′ } must differ from e c|[n]×{i′ } by at least δ fraction of the coordinates. Furthermore, since R is chosen uniformly at random, by Chernoff bound, with probability at least 1 − exp(−δ2 m) over the choice of R it holds that dist(ĉ|R , e c|R×{i′ } ) ≥ 3δ/4. By union over all codewords in L this implies in turn that with probability at least 1 − L · exp(−δ2 m) ≥ c|[n]×{i′ } } it holds that dist(ĉ|R , e c|R×{i′ } ) ≥ 1 − 19 · εe2 over the choice of R, for all codewords ĉ ∈ L \ {e 3δ/4. Next observe that if the above holds then for any column i′ ∈ Colgood we have on the one hand that dist e c|R×{i′ } , (c′r )r∈R ≤ 4δ , and on the other hand that  δ  c|R×{i′ } ) − dist e c|R×{i′ } , (c′r )r∈R ≥ dist ĉ|R , (c′r )r∈R ≥ dist(ĉ|R , e 2 for any ĉ ∈ L \ {e c|[n]×{i′ } }. So e c|[n]×{i′ } will be the codeword in L that is closest to (c′r )r∈R on R, and consequently we will have c = e c|[n]×{i′ } and ci = e ci,i′ . So we obtained that for each column 1 ′ 2 e the algorithm A eJ i ∈ Colgood , with probability at least 1 − 9 · εe over the randomness of A, ′ computes the entire column i correctly. By averaging, this implies in turn that with probability at e the algorithm A eJ computes correctly at least 1 − εe fraction least 1 − 3εe over the randomness of A 3 of the coordinates of e c|[n]×Colgood . e the Concluding, we obtained that with probability at least 1 − εe over the randomness of A, eJ computes correctly at least 1 − εe fraction of the coordinates of e e algorithm A c, so the algorithm A satistifes the local list recovery requirement. Next we analyze the performance of the algorithm. Output list size: [L′ ]R which is The resulting output list size equals the number of different strings (jr )r∈R ∈ e = (L ) L ′ m Query complexity: = exp  log(L′ ) · log(L/e ε) ′ 2 (δ · α · εe)  . The query complexity is   ε) e = m · Q′ + n = O log(L/e Q · Q′ + n, (δ · α′ · εe)2 since Q′ queries are needed in order to list recover each of the rows in R, and n additional queries are needed to globally list recover the i′ ’th column. Pre-Processing Time: The pre-processing algorithm generates a random set R, of size m, which takes m log n time to generate and store. The pre-processing algorithm then runs m independent ′ . Finally, the pre-processing copies of A′ (once for each row in R), and this takes time m · Tpre m algorithm generates the set J of size (L′ ) . Thus the total pre-processing time is   ′ m log n + Tpre + exp m log L′ . 19 Running Time: Each local recovery algorithm runs m copies of the local recovery algorithm for C ′ , which takes time m · T ′ . Then it runs the global list recovery algorithm for C once, which takes time T , thus the total running time of each local recovery algorithm is m · T ′ + T. 5.2 Local list recovery Next we show that the approximately locally list recoverable codes of Lemma 5.2 can be turned into locally list recoverable codes by pre-encoding the message with a locally decodable code. Lemma 5.4. Suppose that C : Fρn → Fn is a systematic linear code of rate ρ and relative distance b : Fbk → F(ρn)t is (Q, b α δ that is (α, ℓ, L)-(globally) list recoverable, and C b)-locally decodable. Then  t b ⊗t k n e α e e := C C b : F → F is (Q, e, ℓ, L)-locally list recoverable for α e =α·α b · ρt · δO(t) , C and e=Q b·n· Q e = exp L logt L 2) (α · α b)O(t) · (ρ · δ)O(t logt L , ! . 2 (α · α b)O(t) · (ρ · δ)O(t ) e has preprocessing time Moreover, the local list recovery algorithm for C ! t log L Tepre = exp · log n, 2 (α · α b)O(t) · (ρ · δ)O(t ) and if the (global) list recovery algorithm for C runs in time T and the local decoding algorithm for b runs in time Tb then the local list recovery algorithm for C e runs in time C b·T · Te = Tb + Q logt L 2) (α · α b)O(t) · (ρ · δ)O(t . t t Proof. Setting εe = α bρt in Lemma 5.2, we conclude that the tensor code C := C ⊗t : F(ρn) → Fn εδO(t) . Note furthermore that since is (Q, α, εe, ℓ, L)-approximately locally list recoverable for α = αe C is systematic then so is C. Intuitively, the proof works as follows: to recover the ith message symbol, xi , run the local b to obtain a set of Q b indices in F(ρn)t that, if queried, would allow you decoder of the inner code C to recover xi . Since the code C is systematic, those symbols correspond to symbols in the big code e Use the approximate local list recovery algorithm for C to obtain L guesses for each of these C. b b “guesses” run the local decoding algorithm for Q symbols. Finally, for each of these L sets of Q b to obtain L guesses for xi . Since C is only approximately locally list recoverable, there will be C a subset of symbols on which the approximate local list decoder fails, but by carefully choosing b parameters, these errors can be handled by the local decoding procedure of C. b times the query It is not hard to see that the query complexity of this algorithm will be Q ⊗t ⊗t complexity of C , and the output list size will be the same as that of C . Below, we describe the algorithm and proof of correctness in more detail. Let (A1 , · · · , AL ) ← A(·) be the approximate local list recovery algorithms for C. In Algorithm 2 we describe the local e := C(C). b e1 , . . . , A e for the code C list recovery algorithms A L 20 e := C ⊗t (C). b Algorithm 2 The local list recovery algorithm for C ej (i ∈ [b function A k])  t ej receives oracle access to lists S ∈ F n ⊲A ℓ b on input i to obtain a set of Q b indices that the local Run the local decoding algorithm for C decoder would query. Let R ⊆ [(ρn)t ] be the subset of indices that would be queried. Let R ⊆ [nt ] be the indices in C encoding the indices of R. b because C is systematic. ⊲ R exists and |R| = |R| = Q for r ∈ R do (r) Let cj ← Aj (r) (on oracle access to S) end for (j) b on input {c(r) } Run the local decoder for C j r∈R to obtain a guess xi for the ith symbol of the message (j) Return: xi end function  nt e b e Correctness: Given a string of lists S ∈ Fℓ , suppose e c = C(x) = C(C(x)) is a codeword of C e that is α e-close to S. We need to show that with probability at least 32 over the randomness of A 2 ej (i) = xi ] ≥ . there is a j ∈ [L] such that for all i ∈ [b k], Pr[A 3 t ⊗t Since εe = α bρ the tensor code C = C is (Q, α, εe, ℓ, L)-approximately locally list recoverable, εδO(t) . Thus if e c is α e-close to S, then with probability 1 − εe, over the randomness of A, for α = αe there is a j ∈ [L] such that Pr [Aj (i) = C(x)i ] ≥ 1 − εe. i∈[nt ] This means that with probability 1 − εe over the randomness of A, there is a j such that Aj (·) is b b Since C is systematic, the inner codeword C(x) must be εeρ−t εe-close to the codeword C(C(x)). b b close to the restriction of S to the information symbols. Since C is (Q, α b)-locally decodable, and −t b α b = εeρ , then by the local decoding property of the inner code, C, given any i ∈ [b k], and oracle b will recover xi with probability at least 2 . access to Aj (·), the local decoding algorithm for C 3 Output list size and query complexity: and the output list size is The query complexity is b·n· e=Q b·Q =Q Q e = L = exp L  logt L , (α · α b · ρt )O(t) · δO(t2 ) logt L 2 (α · α b · ρt )O(t) · δO(t ) It can also be verified that the running times are as required. 21  . 5.3 Instantiations In what follows we shall instantiate Lemma 5.4 in two ways. For both, we will use the highb In the first instantiation, which rate LDCs of [KMRS16] (Theorem 5.8 below) as the code C. is more straightforward, we just use a random linear code (via Corollary 4.4) as the code C. e that is not efficiently encodable, nor efficiently list recoverable, but it does This yields a code C achieve small locality together with constant alphabet size and constant output list size. The second instantiation, which does yield efficinetly encodable (in nearly-linear time) and efficiently list recoverable (in sub-linear time) codes, uses a modification of the Algebraic Geometry subcodes studied in [GX13, GK16b] (Theorem A.1) as the code C. These latter codes have constant alphabet size, but slightly super-constant output list size, which means that our efficient construction will as well. In more detail, we obtain the following pair of theorems. Theorem 5.5 (High-rate locally list recoverable codes, non-efficient). There is a constant c so that the following holds. Choose ε > 0 and positive integers ℓ, t. Suppose that s ≥ max{1/εc , c(log ℓ)t/ε}. Then there exists an infinite family of F2 -linear codes {Cn }n such that the following holds. (1−ε)n 1. Cn : F2s → Fn2s has rate 1 − ε and relative distance at least (ε/(16t))t . 2. Cn is (Q, α, ℓ, L)-locally list recoverable for α = (ε/t)O(t) , √ Q = n1/t · 2O( and log n·log log n) 2 · (sℓ)t · (t/ε)O(t ) ,   2 L = exp (sℓ)t · (t/ε)O(t ) . In particular, when ε, ℓ, t, s are constant we get that α = Ω(1), Q = n1/t+o(1) , and L = O(1). Theorem 5.6 (High-rate locally list recoverable codes, efficient). There is a constant c so that the following holds. Choose ε > 0 and a positive integer ℓ. Let {tn }n be a sequence of positive integers, non-decreasing with n, so that t0 is sufficiently large and r ε logq (n) . tn ≤ cℓ For each choice of t choose s = s(t) so that s ≥ max{1/εc , c(log ℓ)t/ε} is even. Then there exists an infinite family of F2 -linear codes {Cn }n such that the following holds. Below, to simplify notation we use t instead of tn and s instead of s(tn ). (1−ε)n 1. Cn : F2s → Fn2s has rate 1 − ε and relative distance at least (Ω(ε/t))2t . 2. Cn is (Q, α, ℓ, L)-locally list recoverable for α = (ε/t)O(t) ,  2  √ t ℓs ∗ 1/t O( log n·log log n) · exp · exp(log n) + t log s , Q=n ·2 ε and  L = exp exp  t2 ℓs · exp(log∗ n) + t log s ε 22  . 3. The local list recovery algorithm for Cn has preprocessing time    2 t ℓs ∗ · exp(log n) + t log s · log n, Tpre = exp exp ε and running time T =n O(1/t) √ O( log n·log log n) ·2  · exp exp  tℓs · exp(log∗ n) + log s ε  . 4. Cn can be encoded in time √ n · 2O( log n·log log n) + t · n1+O(1/t) . In particular, when ε, ℓ, tn = t, s are constant we get that α = Ω(1), Q = n1/t+o(1) , L = exp(exp(exp(log∗ n))), Tpre = log1+o(1) n, T = nO(1/t) , and encoding time is n1+O(1/t) . Remark 5.7 (Super-constant t). Theorem 5.6 is interesting even when tn = t is a sufficiently large constant that does not depend on n. For our applications, we will need to take tn to be slightly super-constant, so we allow for that in the statement of Theorem 5.6. To prove the above theorems we use the following result from [KMRS16, KMRS15] that shows the existence of high-rate LDCs with sub-polynomial query complexity. Theorem 5.8 ([KMRS15], Theorem 1.3). There is a constant c so that the following holds. Choose ρ ∈ [0, 1] and ε > 0. Then there exists an infinite sequence {ni }i such that for any n = ni in the sequence and for any s ≥ 1/εc there exists an F2 -linear code Cn satisfying: n 1. Cn : Fρn 2s → F2s has rate ρ and relative distance at least 1 − ρ − ε. √ 2. Cn is (2O( 3. Cn can be log n·log log n) , 1−ρ−ε )-locally decodable 2 √ encoded in time n · 2O( log n·log log n) . √ in time s · 2O( log n·log log n) . Remark 5.9. We remark about a few differences between the above theorem and Theorem 1.3 in [KMRS15]: 1. Theorem 1.3 in [KMRS15] talks about locally correctable codes (LCCs) instead of locally decodable codes (LDCs). The difference between LCCs and LDCs is that for LCCs the local correction algorithm is required to decode codeword bits as opposed to message bits. However, it can be shown that the result holds for LDCs as well (see discussion at end of Section 1.1 in [KMRS15]). 2. Theorem 1.3 in [KMRS15] only states the existence of some s0 ≤ 1/εc for which the above holds, however it can be verified that the result holds for any s ≥ s0 as well. 3. Encoding time is not stated explicitly in [KMRS15], Lemma 3.2 and [Kop15], Appendix A. We proceed to the proof of Theorem 5.5. 23 Proof of theorem 5.5. Let c′ be a sufficiently large constant for which both Corollary 4.4 and The′ orem 5.8 hold, and suppose that s ≥ max{(4/ε)c , 16c′ (log ℓ)t/ε}. ((1−ε/2)n)1/t 1/t → Fn2s be a linear code of rate (1−ε/2)1/t ≤ 1−ε/(8t) (the inequality holds Let C : F2s ε y , ℓ, 2O(sℓt/ε) )-list since (1 − x) ≤ 1 − xy/4 for x, y ∈ [0, 1], see e.g. Fact 2.1 in [KMRS15]) that is ( 16t recoverable whose existence is guaranteed by Corollary 4.4 for sufficiently large n (depending on ε, ℓ, t, s). Note furthermore that by Theorem 4.1 we may assume that C has relative distance at least ε/(16t). Finally, note that one may assume that the code C is systematic by performing (1−ε/2)n b : F(1−ε)n be an F2 -linear → F2s Gaussian elimination on the generating matrix of C. Let C 2s √  ε ε 1−ε O( log n·log log n) , 4 -locally decodable given by Theorem 5.8 for code of rate 1−ε/2 ≤ 1 − 2 that is 2 infinite values of n (depending on ε). b for any n for which both C and Ĉ exist. Then Cn : F(1−ε)n → Fn2s is an Let Cn := C ⊗t (C) 2s t F2 -linear code of rate 1 − ε and relative distance at least (ε/(16t)) . Moreover, by Lemma 5.4 the code Cn is (Q, α, ℓ, L)-locally list recoverable for α = (ε/t)O(t) ,  t √ √ sℓt 2 2 1/t O( log n·log log n) · (t/ε)O(t ) = n1/t · 2O( log n·log log n) · (sℓ)t · (t/ε)O(t ) , · Q=n ·2 ε and   2 L = exp (sℓ)t · (t/ε)O(t ) . Next we prove Theorem 5.6. Proof of Theorem 5.6. Fix any n ∈ N so that Theorem 5.8 may be instantiated with block length (1 − ε/2)n, and so that n1/tn ≥ q 8c0 ℓtn /ε , (1) where c0 is the constant from the statement of Theorem A.1. By Theorem 5.8 and the assumption on tn , there are infinitely many such n. For the rest of the proof, we will denote tn by t, since n is now fixed. Let c′ be a sufficiently large constant (independent of n) for which both Theorem A.1 and ′ Theorem 5.8 hold, and suppose that s ≥ max{(4/ε)c , 8c′ (log ℓ)t/ε} is even. Then the code Cn is constructed as follows. 1/t ((1−ε/2)n)1/t Let C : F2s → Fn2s be a linear code of rate 1 − ε/(8t) ≥ (1 − ε/2)1/t and relative distance Ω((ε/8t)2 ), that is (Ω((ε/8t)2 ), ℓ, L0 )-list recoverable whose existence is guaranteed by Theorem A.1, where    ℓt ∗ · exp(log (n)) L0 = exp2s exp2s ε     ℓst ∗ = exp exp exp(log (n)) + log(s) . ε Here, we are using (1) to ensure that we may choose the block length n1/t and rate 1 − ε/(8t) in Theorem A.1. Once more, one may further assume that the code C is systematic by performing Gaussian (1−ε/2)n b : F(1−ε)n be an F2 -linear code of rate → F2s elimination on the generating matrix of C. Let C 2s √  ε ε 1−ε log n·log log n) O( , 4 -locally decodable given by Theorem 5.8. 1−ε/2 ≤ 1 − 2 that is 2 24 (1−ε)n b Then Cn : F s → Fn2s is an F2 -linear code of rate 1−ε and relative distance Let Cn := C ⊗t (C). 2 at least (Ω(ε/t))2t . Moreover, by Lemma 5.4 the code Cn is (Q, α, ℓ, L)-locally list recoverable for α = (ε/t)O(t) ,  2  √ t ℓs ∗ 1/t O( log n·log log n) · exp · exp(log n) + t log s , Q =n ·2 ε and  L = exp exp  t2 ℓs · exp(log∗ n) + t log s ε  . b can be locally Next observe that√ since C can be list recovered in time poly(n1/t , L0 ), and C O( log n·log log n) decoded in time 2 , the local list recovery algorithm for Cn has preprocessing time   2  t ℓs ∗ Tpre = exp exp · exp(log n) + t log s · log n, ε and running time T =n O(1/t) √ O( log n·log log n) ·2  · exp exp  tℓs · exp(log∗ n) + log s ε  . Finally, since C can be encoded in time poly(n1/t ) then C ⊗t can be encoded in time t·n·poly(n1/t ), b is and consequently the encoding time of Cn := C ⊗t (C) √ n · 2O( 6 log n·log log n) + t · n1+O(1/t) . Capacity achieving locally list decodable codes Next we show the existence of capacity achieving locally list decodable codes over large (but constant) alphabet. As before we exhibit two instantiations of this result: In the first instantiation we obtain capacity achieving locally list decodable codes that have constant output list size, however these codes cannot be efficiently encoded or list decoded; In the second instantiation we obtain capacity achieving locally list decodable codes that are efficiently encodable (in nearly-linear time) and efficiently list decodable (in sub-linear time), however these codes have slightly super-constant output list size. These latter codes can also achieve no(1) query complexity at the cost of increasing the alphabet and output list sizes to no(1) . Towards our GV bound application, we actually present a stronger version that applies also to list recovery, where list decoding corresponds to the special case in which the input list size ℓ equals 1. Theorem 6.1 (Capacity achieving locally list decodable / recoverable codes, non-efficient). There is a constant c so that the following holds. Choose ρ ∈ [0, 1], ε > 0, a positive integer ℓ, and sufficiently large integer t. Let  s0 := max c(1 − ρ − ε/2) log(1/(1 − ρ − ε/2))/ε, c(ρ + ε/2) log(1/(ρ + ε/2))/ε, c(log ℓ)/ε ,  and suppose that s ≥ max (t/ε)ct , cℓt/ε2 · s0 /ρ. Then there exists an infinite family of F2 -linear codes {Cn }n such that the following holds. 25 n 1. Cn : Fρn 2s → F2s has rate ρ and relative distance at least 1 − ρ − ε. 2. Cn is (Q, 1 − ρ − ε, ℓ, L)-locally list recoverable for √ Q = n1/t · 2O( and log n·log log n) 2 · st+O(1) · 2O(s0 ℓt/ε) · (t/ε)O(t ) ,   2 L = exp st · 2O(s0 ℓt/ε) · (t/ε)O(t ) . In particular, when ρ, ε, ℓ, t, s are constant we get that Q = n1/t+o(1) and L = O(1). Theorem 6.2 (Capacity achieving locally list decodable / recoverable codes, efficient). There is a constant c so that the following holds. Choose ρ ∈ [0, 1], ε > 0, and a positive integer ℓ. Let {tn }n be a sequence of positive integers, non-decreasing with n, so that t0 is sufficiently large, and so that r ε logq (n) . tn ≤ cℓ Let  s0 := max c(1 − ρ − ε/2) log(1/(1 − ρ − ε/2))/ε, c(ρ + ε/2) log(1/(ρ + ε/2))/ε, c(log ℓ)/ε ,  and for each choice of t choose s = s(t) so that s ≥ max (t/ε)ct , cℓt/ε2 · s0 /ρ is even. Then there exists an infinite family of F2 -linear codes {Cn }n such that the following holds. Below, we use t to denote tn and s to denote s(tn ) to simplify notation. n 1. Cn : Fρn 2s → F2s has rate ρ and relative distance at least 1 − ρ − ε. 2. Cn is (Q, 1 − ρ − ε, ℓ, L)-locally list recoverable for   √ Q = n1/t · 2O( log n·log log n) · exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s and    L = exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s . 3. The local list recovery algorithm for Cn has preprocessing time    Tpre = exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s · log n, and running time √ T = nO(1/t) · 2O( log n·log log n)    · exp exp ts · 2O(s0 ℓ/ε) · exp(log∗ n) + log s . 4. Cn can be encoded in time √ n · 2O( log n·log log n) 2 + t · n1+O(1/t) + O(n · 2s ) + sO(1) · n · polylogn. In particular, 26 • When ρ, ε, ℓ, t, s are constant we see that Q = n1/t+o(1) , L = exp(exp(exp(log∗ n))), Tpre = log1+o(1) n, T = nO(1/t) , and encoding time is n1+O(1/t) .   log log(n) O(t) we see • Alternatively, when ρ, ε, ℓ are constant, t = tn = O (loglog 2 log log log(n)) , and s = t that Q, L, Tpre , T are of the form no(1) and encoding time is n1+O(1/t) = n1+o(1) . To prove the above theorems we shall use the following lemma from [GKO+ 17] that gives a distance amplification procedure for local list recovery. Lemma 6.3 ([GKO+ 16], Lemma 5.4). There is a constant c so that the following holds. For any δout , αout , ε > 0 there exists an integer d ≤ (δout · αout · ε)−c such that the following holds. • Let Cout : (Σout )ρout ·nout → (Σout )nout be an F-linear code of rate ρout and relative distance δout that is (Q, αout , ℓout , Lout )-locally list recoverable. • Let Cin : (Σin )ρin ·nin → (Σin )nin be an F-linear code of rate ρin and relative distance δin that is (αin , ℓin , Lin )-(globally) list recoverable. • Additionally, suppose that nin ≥ d, |Σout | = |Σin |ρin ·nin and Lin ≤ ℓout . Then there exists an F-linear code C : (Σninin )(ρin ·ρout )·nout → (Σninin )nout of rate ρin · ρout and relative distance at least δin − ε that is (O(Q · n2in · log nin ), αin − ε, ℓin , Lout )-locally list recoverable. Moreover, • If the local list recovery algorithm for Cout has preprocessing time Tpre,out and running time Tout , and the global list recovery algorithm for Cin has running time Tin , then the local list recovery algorithm for C has preprocessing time Tpre,out and running time O(Tout ) + O(Q · Tin ) + poly(Q, nin , ℓin ). • If the encoding times of Cout , Cin are Tbout , Tbin respectively then the encoding time of C is O(Tbout ) + O(nout · Tbin ) + nout · poly(nin , log nout ). Remark 6.4. The definition of locally list recoverable codes in [GKO+ 17] is stronger than ours since it requires an additional soundness property which guarantees that with high probability, all local algorithms in the output list compute an actual codeword. This requirement is not needed in our setting, and it can be verified that the proof of the above lemma goes through also with our weaker definition. Also, the encoding time was not mentioned explicitly in [GKO+ 17] but it can be deduced from the proof of the lemma. We proceed to the proof of Theorem 6.1. Proof of Theorem 6.1. Let c′ be a sufficiently large constant for which both Corollary 4.4, Theorem  ′ 5.5 and Lemma 6.3 hold, and suppose that s ≥ max (t/ε)c t , 32(c′ )2 ℓt/ε2 · s0 /ρ for  s0 := max 4c′ (1 − ρ − ε/2) log(1/(1 − ρ − ε/2))/ε, 4c′ (ρ + ε/2) log(1/(ρ + ε/2))/ε, 4c′ (log ℓ)/ε .  ′ (ρ+ε/4)·(s/s0 ) s/s Let Cin : F2s0 → F2s0 0 be a linear code of rate ρ + ε/4 that is 1 − ρ − ε/2, ℓ, 24c s0 ℓ/ε -list recoverable whose existence is guaranteed by Corollary 4.4 for sufficiently large t (depending on 27 ρ, ε, ℓ). Note furthermore that by Theorem 4.1 we may assume that Cin has relative distance at least 1 − ρ − ε/2. ρn/(ρ+ε/4) ρ ≤ 1−ε/8 and relative distance Let Cout : F2(ρ+ε/4)s → Fn2(ρ+ε/4)s be an F2 -linear code of rate ρ+ε/4 t at least (ε/(128t)) , given by Theorem 5.5 for infinite values of n (depending on ρ, ε, ℓ, t, s), that is ′ (Qout , (ε/t)O(t) , 24c s0 ℓ/ε , Lout )-locally list recoverable for √ Qout = n1/t · 2O( and log n·log log n) 2) · st · 2O(s0 ℓt/ε) · (t/ε)O(t   2 Lout = exp st · 2O(s0 ℓt/ε) · (t/ε)O(t ) . n Then by Lemma 6.3 for any n for which Cout exists there exists an F2 -linear code Cn : Fρn 2s → F2s of rate ρ and relative distance at least 1 − ρ − ε that is (Q, 1 − ρ − ε, ℓ, L)-locally list recoverable for √ Q = n1/t · 2O( and log n·log log n) 2 · st+O(1) · 2O(s0 ℓt/ε) · (t/ε)O(t ) ,   2 L = exp st · 2O(s0 ℓt/ε) · (t/ε)O(t ) . Next we prove Theorem 6.2. Proof of theorem 6.2. Let c′ be a sufficiently large constant for which both Corollary 4.4, Theorem 5.6 and Lemma 6.3 hold. Fix n ∈ N so that Theorem 5.6 guarantees the existence of a code with block length n and using parameter t = tn . (By Theorem 5.6, there are infinitely many such n). Now  ′t c that n is fixed, we will use t to denote tn . Suppose that s = s(t) ≥ max (t/ε) , 32(c′ )2 ℓt/ε2 · s0 /ρ is even for  s0 := max 4c′ (1 − ρ − ε/2) log(1/(1 − ρ − ε/2))/ε, 4c′ (ρ + ε/2) log(1/(ρ + ε/2))/ε, 4c′ (log ℓ)/ε . The code Cn is constructed as follows.  ′ (ρ+ε/4)·(s/s0 ) s/s Let Cin : F2s0 → F2s0 0 be a linear code of rate ρ + ε/4 that is 1 − ρ − ε/2, ℓ, 24c s0 ℓ/ε -list recoverable whose existence is guaranteed by Corollary 4.4. Note furthermore that by Theorem 4.1 we may assume that Cin has relative distance at least 1 − ρ − ε/2. ρn/(ρ+ε/4) ρ Let Cout : F2(ρ+ε/4)s → Fn2(ρ+ε/4)s be an F2 -linear code of rate ρ+ε/4 ≤ 1 − ε/8 and relative ′ distance at least (Ω(ε/t))2t , given by Theorem 5.6, that is (Qout , (ε/t)O(t) , 24c s0 ℓ/ε , Lout )-locally list recoverable for   √ Qout = n1/t · 2O( log n·log log n) · exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s and    Lout = exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s . n Then by Lemma 6.3 there exists an F2 -linear code Cn : Fρn 2s → F2s of rate ρ and relative distance at least 1 − ρ − ε that is (Q, 1 − ρ − ε, ℓ, L)-locally list recoverable for   √ Q = n1/t · 2O( log n·log log n) · exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s 28 and    L = exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s . The stated running and encoding times follow similarly. 7 Nearly-linear time capacity achieving list decodable codes In this section we show how to construct capacity achieving list decodable codes that can be encoded and list decoded (probabilistically) in nearly-linear time. These codes are presented in Section 7.1 below. We then show (in Section 7.2) how these codes can be used to probabilistically construct codes of rate up to 0.02 that can be uniquely decoded (probabilistically) up to half the Gilbert-Varshamov (GV) bound in nearly-linear time. 7.1 Nearly-linear time capacity achieving list decodable codes Our nearly-linear time capacity achieving list decodable codes follow as a consequence of our efficient capacity achieving locally list decodable code construction (Theorem 6.2). Once more, we show a stronger version that applies also to list recovery. Theorem 7.1 (Nearly-linear time capacity achieving list decodable / recoverable codes). There is a constant c so that the following holds. Choose ρ ∈ [0, 1], ε > 0, and a positive integer ℓ. Let {tn }n be a sequence of positive integers, non-decreasing with n, so that t0 is sufficiently large, and so that r ε logq (n) . tn ≤ cℓ Let  s0 := max c(1 − ρ − ε/2) log(1/(1 − ρ − ε/2))/ε, c(ρ + ε/2) log(1/(ρ + ε/2))/ε, c(log ℓ)/ε ,  and for each choice of t, suppose that s = s(t) is such that s ≥ max (t/ε)ct , cℓt/ε2 · s0 /ρ is even. Then there exists an infinite family of F2 -linear codes {Cn }n such that the following holds. Below, to simplify notation we use t instead of tn and s instead of s(tn ). n 1. Cn : Fρn 2s → F2s has rate ρ and relative distance at least 1 − ρ − ε. 2. Cn is (1 − ρ − ε, ℓ, L)-list recoverable for    L = exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s) . 3. Cn can be list recovered probabilistically (with success probability 2/3)4 in time    √ T = n1+O(1/t) · 2O( log n·log log n) · exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s . 4 More precisely, there exists a randomized algorithm A, running in time T , that outputs a list of L messages, and the guarantee is that with probability at least 2/3 the output list contains all messages that correspond to close-by codewords. Note that the success probability can be amplified to 1 − e−t , at the cost of increasing the output list size by a multiplicative factor of O(t), by repeating the algorithm independently O(t) times and returning the union of all output lists. 29 4. Cn can be encoded in time √ n · 2O( log n·log log n) 2 + t · n1+O(1/t) + O(n · 2s ) + sO(1) · n · polylogn. In particular, • When ρ, ε, ℓ, t, s are constant we get that L = exp(exp(exp(log∗ n))) and list recovery and encoding times are n1+O(1/t) .   log log(n) • Alternatively, when ρ, ε, ℓ are constant, t = tn = O (loglog and s = tO(t) we get log log log(n))2 ) that L = no(1) and list recovery and encoding times are n1+O(1/t) = n1+o(1) . Proof. We use the same codes as in Theorem 6.2 so it only remains to prove the second and third bullets. The global list recovery algorithm A for Cn first runs the local list recovery algorithm A′ for Cn guaranteed by Theorem 6.2 for O(log L′ ) times independently where L′ is the output list size given by Theorem 6.2. Let A′1 , A′2 , . . . , A′O(L′ log L′ ) denote the local algorithms in the output lists. Then for each A′j the algorithm A includes in the output list a message x(j) ∈ Fρn 2s which results by applying A′j on each of the ρn message coordinates O(log(nL′ )) times independently and taking majority vote for each of the coordinates. We claim that with probability at least 2/3 the list output by A includes all messages that correspond to close-by codewords. To see this note first that since any close-by codeword is represented in the output list of A′ with probability at least 2/3, it must hold that the number of close-by codewords is at most 3L′ /2. Consequently, running A′ for O(log L′ ) times guarantees that with probability at least 5/6 all close-by codewords will be represented in the output list. Moreover, repeating the decoding of each message coordinate for O(log(nL′ )) times guarantees that each of these coordinates is decoded correctly with probability at least 1 − 1/(10nL′ ), and so by union bound with probability at least 5/6 all messages are decoded correctly. So we obtained that with probability at least 1−1/6−1/6 = 2/3 the output list of A will include all messages that correspond to close-by codewords. Finally note that the output list size of the algorithm A is    ′ ′ 2 O(s0 ℓ/ε) ∗ O(L log L ) = exp exp t s · 2 · exp(log n) + t log s , and its running time is ′ O(Tpre · log L′ ) + O(L′ log L′ · n log(nL′ ) · T ′ )    √ = n1+O(1/t) · 2O( log n·log log n) · exp exp t2 s · 2O(s0 ℓ/ε) · exp(log∗ n) + t log s , ′ , T ′ denote the preprocessing and running times of the local list recovery algorithm for where Tpre Cn , respectively. 7.2 Nearly-linear time decoding up to half the GV bound Next we show how the nearly-linear time capacity achieving list recoverable codes of Theorem 7.1 can be used to obtain codes of rate up to 0.02 that are uniquely decodable up to half the GilbertVarshamov (GV) bound in nearly-linear time. Let H2−1 : [0, 1] → [0, 21 ] be the inverse of the binary entropy function H2 in the domain [0, 21 ]. 30 Theorem 7.2 (Nearly-linear time decoding up to half GV bound). Choose constants ρ ∈ [0, 0.02] and ε > 0. Then there exists a randomized polynomial time algorithm which for infinitely many n, given an input string 1n , outputs a description of a code Cn that satisfies the following properties with probability at least 1 − exp(−n).5 −1 n 1. Cn : Fρn 2 → F2 is a linear code of rate ρ and relative distance at least δ := H2 (1 − ρ) − ε. 2. Cn can be uniquely decoded probabilistically (with 2/3) from δ/2 fraction   success probability log log log(n) 1+O(1/t) 1+o(1) of errors in time n =n for t = O (log log log log(n))2 . 3. Cn can be encoded in time n1+O(1/t) = n1+o(1) with the same choice of t. To prove the above theorem we rely on the following lemma which says that one can turn a code that approximately satisfies the Singleton bound into one that approximately satisfies the GV bound via random concatenation. The proof is similar to that of Thommesen [Tho83]. In what follows let θ(x) := 1 − H2 (1 − 2x−1 ) for x ∈ [0, 1]. Lemma i is a constant c so that the following holds. Choose ε > 0, ρin ∈ [0, 1], and h 7.3. There θ(ρin )−ε/2 c·ρin . Then the following holds for sufficiently large n. . Suppose that s ≥ ε2 ·(1−ρ ρout ∈ 0, ρin out ) 2 Let Cout : Fρ2sout ·n → Fn2s be an F2 -linear code of rate ρout and relative distance at least 1 − ρout − εc . sn/ρ Let C : F2s·ρout·n → F2 in be a code obtained from Cout by applying a random linear code C (i) : s/ρ Fs2 → F2 in on each coordinate i ∈ [n] of Cout independently (where we identify the field F2s with the vector space Fs2 via the usual F2 -linear transformation). Then C has relative distance at least H2−1 (1 − ρout · ρin ) − ε with probability at least 1 − exp(−n). We shall also use the following lemma that states the effect of concatenation on list recovery properties. Lemma 7.4. Let Cout : Fρqsout ·n → Fnqs be an (αout , ℓout , Lout )-list recoverable code, with a list sn/ρ recovery algorithm running in time Tout . Let C : Fqs·ρout·n → Fq in be the code obtained from Cout s/ρ by applying a code C (i) : Fsq → Fq in on each coordinate i ∈ [n] of Cout . Suppose furthermore that at least 1 − ε fraction of the codes C (i) are (αin , ℓin , Lin )-list recoverable for Lin = ℓout , with a list recovery algorithm running in time Tin . Then C is ((αout − ε) · αin , ℓin , Lout )-list recoverable in time Tout + O(n · Tin ). Before we prove the above pair of lemmas we show how they imply Theorem 7.2. Proof of Theorem 7.2. Let c be a sufficiently large constant for which both Theorem 7.1 and Lemma ρ 7.3 hold. Let ρin := θ −1 (ρ + ε/2) and ρout := ρρin = θ−1 (ρ+ε/2) . Define t = tn = O  log log log(n) (log log log log(n))2  5 The randomized algorithm can output different codes under different random choices, we are only guaranteed that the output code has the required properties with high probability. Also the encoding and decoding algorithms need access to the random choices made during the construction of the code. 31 as in the statement of Theorem 7.2, and let  s = max (ct/ε2 )ct , c3 21/ε t/ε4 · s0 /(ρout (1 − ρout )) for even s0 := max  c2 ε2     1 ε2 1 − ρout − log , 2c 1 − ρout − ε2 /(2c)     2 c2 1 ε2 c ρout + log , 3 . 2 2 ε 2c ρout + ε /(2c) ε Notice that chosing when t = tn is super-constant, as above, and ε, ρ are constant (as in the theorem statement) that we always have s = tO(t) . Choose any n ∈ N so that Theorem 7.1 guarantees that codes of block length n exist (there are infinitely many of these). Then the code Cn is constructed as follows. ρ n/s ρ ·(ρ n/s) be the F2 -linear code of rate ρout and relative distance at least Let Cout : F2sout in → F2sin  2 2 1 − ρout − εc that is 1 − ρout − εc , 21/ε , nO(1/t) -list recoverable in time n1+O(1/t) whose existence is guaranteed by Theorem 7.1. Notice that here t is growing with n, but slowly enough that we may apply Theorem 7.1. Let Cn : Fρ2out ·ρin n → Fn2 be a binary linear code of rate ρin · ρout = ρ obtained from Cout s/ρ by applying a random linear code C (i) : Fs2 → F2 in on each coordinate i ∈ [ρin n/s] of Cout independently. Then by Lemma 7.3 the code Cn has relative distance at least H2−1 (1 − ρ) − ε with probability at least 1 − exp(−n). Moreover, by Theorem 4.2 we also have that each C (i) is (H2−1 (1 − ρin − ε), 21/ε )list decodable with probability at least 1 − exp(−s) = 1 − o(1), so with probability at least 1 − exp(−n) it holds that at least 1−ε2 /c fraction of the C (i) ’s are (H2−1 (1−ρin −ε), 21/ε )-list decodable. Lemma 7.4 then implies that in this case the code Cn is ((1−ρout −2ε2 /c)·H2−1 (1−ρin −ε), nO(1/t) )list decodable (probabilistically) in time n1+O(1/t) + n · 2O(s) = n1+O(1/t) . Now observe that by Theorem 7.1 the code Cout is encodable in time n1+O(1/t) , and so encoding 2 time of Cn is n1+O(1/t) + n · 2O(s ) = n1+O(1/t) . Consequently, whenever the list decoding radius of Cn exceeds half the minimum distance, one can uniquely decode Cn up to half the minimum distance in time n1+O(1/t) by list decoding Cn , computing the codewords that correspond to the messages in the output list, and returning the (unique) closest codeword. So we obtained that the code Cn is uniquely decodable up to half the minimum distance in time 1+O(1/t) n whenever  H −1 (1 − ρ) − ε . 1 − ρout − 2ε2 /c · H2−1 (1 − ρin − ε) ≥ 2 2 Finally, it is shown in [Rud07], Section 4.4 that the inequality above holds for sufficiently small constant ε > 0 by choice of ρ = ρin · ρout ≤ 0.02. It remains to prove Lemmas 7.3 and 7.4. We start with Lemma 7.3. Proof of Lemma 7.3. The proof follows the arguments of [Tho83]. For a string x of length n let the relative weight wt(x) of x denote the fraction of non-zero coordinates of x. It is well known that the relative distance of an F-linear code equals the minimum relative weight wt(c) of a non-zero codeword c ∈ C. 32 sn/ρ Fix a codeword c′ ∈ Cout with wt(c′ ) = γ ≥ 1 − ρout − ε2 /c, and let c ∈ F2 in be a word s/ρ obtained from c′ by applying a random linear code C (i) : Fs2 → F2 in on each coordinate i ∈ [n] of c′ independently. Then for each non-zero coordinate i of c′ it holds that the i-th block of c of s/ρ length s/ρin is distributed uniformly over F2 in , and so γsn/ρin coordinates of c are uniformly distributed (while the rest equal zero). Consequently, we have that   γsn/ρin Pr[wt(c) < δ] ≤ 2−γsn/ρin ≤ 2H2 (δ/γ)γsn/ρin · 2−γsn/ρin . ≤ δsn/ρin Next we apply a union bound over all codewords c′ ∈ Cout . For this fix γ > 0 such that γ ≥ 1 − ρout − ε2 /c and γn ∈ N. Then it holds that the number of codewords in Cout of relative weight γ is at most   2 n 2 · (2s )γn−(1−ρout −ε /c)n ≤ 2n · 2(γ−(1−ρout −ε /c))sn , γn  n where the above bound follows since there are at most γn choices for the location of the non-zero coordinates, and for any such choice fixing the value of the first γn − (1 − ρout − ε2 /c)n nonzero coordinates determines the value of the rest of the non-zero coordinates (since two different codewords cannot differ on less than (1 − ρout − ε2 /c)n coordinates). Consequently, we have that X 2 Pr[dist(C) < δ] ≤ 2n · 2(γ−(1−ρout −ε /c))sn · 2H2 (δ/γ)γsn/ρin · 2−γsn/ρin 1−ρout −ε2 /c≤γ≤1, γn∈N = X 1−ρout −ε2 /c≤γ≤1, γn∈N  exp −γsn/ρin   1 − ρout − ε2 /c 1 − ρin · 1 − γ  ρin − H2 − γs   δ . γ Finally, Lemma 8 in [GR08a] implies that in our setting of parameters, and for choice of δ := H2−1 (1 − ρin · ρout ) − ε, the right hand side of the above inequality is at most exp(−n), which completes the proof of the lemma. The running time follows. Next we prove Lemma 7.4. Proof of Lemma 7.4. For i ∈ [n] and j ∈ [s/ρin ], let Si,j ⊆ Fq be a list of at most ℓin possible symbols for the coordinate C(x)i,j := C(x)(i−1)·(s/ρin )+j , which is the j-th coordinate of C (i) (Cout (x)i ). Suppose that for at most a (αout − ε) · αin fraction of coordinates (i, j), C(x)i,j ∈ / Si,j . Then by Markov’s inequality, for at most a αout − ε fraction of i ∈ [n], the blocks C (i) (Cout (x)i ) have more than αin fraction of the j ∈ [s/ρin ] so that C(x)i,j ∈ / Si,j . Thus, we may list recover each block C (i) (Cout (x)i ) which is list recoverable to obtain a list Si ⊆ Fqs of at most Lin = ℓout possible symbols for Cout (x)i , and the above reasoning shows that Cout (x)i ∈ / Si for at most αout n values of i. Now we may run Cout ’s list recovery algorithm to obtain a final list of size Lout . Acknowledgements. The second author would like to thank Swastik Kopparty for raising the question of obtaining capacity achieving locally list decodable codes which was a direct trigger for this work as well as previous work [KMRS16, GKO+ 17], and Sivakanth Gopi, Swastik Kopparty, Rafael Oliveira and Shubhangi Saraf for many discussions on this topics. The current collaboration began during the Algorithmic Coding Theory Workshop at ICERM, we thank ICERM for their hospitality. 33 References [AEL95] Noga Alon, Jeff Edmonds, and Michael Luby. Linear time erasure codes with nearly optimal recovery. In proceedings of the 36th Annual IEEE Symposium on Foundations of Computer Science (FOCS), pages 512–519. IEEE Computer Society, 1995. [Ale02] Michael Alekhnovich. Linear diophantine equations over polynomials and soft decoding of reed-solomon codes. In Foundations of Computer Science, 2002. Proceedings. The 43rd Annual IEEE Symposium on, pages 439–448. IEEE, 2002. [BB10] Peter Beelen and Kristian Brander. Key equations for list decoding of Reed Solomon codes and how to solve them. Journal of Symbolic Computation, 45(7):773–786, 2010. [BHNW13] Peter Beelen, Tom Hoholdt, Johan S.R. Nielsen, and Yingquan Wu. On rational interpolation-based list-decoding and list-decoding binary goppa codes. Information Theory, IEEE Transactions on, 59(6):3269–3281, 2013. [BS06] Eli Ben-Sasson and Madhu Sudan. Robust locally testable codes and products of codes. Random Struct. Algorithms, 28(4):387–402, 2006. [BV09] Eli Ben-Sasson and Michael Viderman. Tensor products of weakly smooth codes are robust. Theory of Computing, 5(1):239–255, 2009. [BV15] Eli Ben-Sasson and Michael Viderman. Composition of semi-LTCs by two-wise tensor products. Computational Complexity, 24(3):601–643, 2015. [CH11] Henry Cohn and Nadia Heninger. Ideal forms of Coppersmith’s theorem and Guruswami-Sudan list decoding. In ICS, pages 298–308, 2011. [CJN+ 15] Muhammad F.I. Chowdhury, Claude-Pierre Jeannerod, Vincent Neiger, Eric Schost, and Gilles Villard. Faster algorithms for multivariate interpolation with multiplicities and simultaneous polynomial approximations. Information Theory, IEEE Transactions on, 61(5):2370–2387, 2015. [CR05] Don Coppersmith and Atri Rudra. On the robust testability of tensor products of codes. ECCC TR05-104, 2005. [DL12] Zeev Dvir and Shachar Lovett. Subspace Evasive Sets. In STOC ’12, pages 351–358, October 2012. [DSW06] Irit Dinur, Madhu Sudan, and Avi Wigderson. Robust local testability of tensor products of LDPC codes. In proceedings of the 9th International Workshop on Randomization and Computation (RANDOM), pages 304–315. Springer, 2006. [Eli57] Peter Elias. List decoding for noisy channels. Technical Report 335, MIT, September 1957. [GGR11] Parikshit Gopalan, Venkatesan Guruswami, and Prasad Raghavendra. List decoding tensor products and interleaved codes. SIAM Journal on Computing, 40(5):1432–1462, 2011. 34 [GI01] Venkatesan Guruswami and Piotr Indyk. Expander-based constructions of efficiently decodable codes. In Foundations of Computer Science, 2001. Proceedings. 42nd IEEE Symposium on, pages 658–667. IEEE, October 2001. [GI02] Venkatesan Guruswami and Piotr Indyk. Near-optimal linear-time codes for unique decoding and new list-decodable codes over smaller alphabets. In Proceedings of the Thiry-fourth Annual ACM Symposium on Theory of Computing, STOC ’02, pages 812– 821, New York, NY, USA, 2002. ACM. [GI03] Venkatesan Guruswami and Piotr Indyk. Linear time encodable and list decodable codes. In Proceedings of the thirty-fifth annual ACM symposium on Theory of computing, STOC ’03, pages 126–135, New York, NY, USA, 2003. ACM. [GI04] Venkatesan Guruswami and Piotr Indyk. Efficiently decodable codes meeting GilbertVarshamov bound for low rates. In SODA ’04: Proceedings of the fifteenth annual ACM-SIAM symposium on Discrete algorithms, pages 756–757, Philadelphia, PA, USA, 2004. Society for Industrial and Applied Mathematics. [Gil52] Edgar N. Gilbert. A comparision of signalling alphabets. Bell System Technical Journal, 31:504–522, 1952. [GK16a] Alan Guo and Swastik Kopparty. List-decoding algorithms for lifted codes. IEEE Transactions on Information Theory, 62(5):2719 – 2725, 2016. [GK16b] Venkatesan Guruswami and Swastik Kopparty. Explicit subspace designs. Combinatorica, 36(2):161–185, 2016. [GKO+ 16] Sivakanth Gopi, Swastik Kopparty, Rafael Oliveira, Noga Ron-Zewi, and Shubhangi Saraf. Locally testable and locally correctable codes approaching the gilbert-varshamov bound. Electronic Colloquium on Computational Complexity (ECCC), 23:122, 2016. [GKO+ 17] Sivakanth Gopi, Swastik Kopparty, Rafael Oliveira, Noga Ron-Zewi, and Shubhangi Saraf. Locally testable and locally correctable codes approaching the gilbert-varshamov bound. In Proceedings of the Twenty-Eighth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 2073–2091. SIAM, 2017. [GL89] Oded Goldreich and Leonid A Levin. A hard-core predicate for all one-way functions. In Proceedings of the twenty-first annual ACM symposium on Theory of computing, pages 25–32. ACM, 1989. [GM12] Oded Goldreich and Or Meir. The tensor product of two good codes is not necessarily locally testable. Inf. Proces. Lett., 112(8-9):351–355, 2012. [GNP+ 13] Anna C. Gilbert, Hung Q. Ngo, Ely Porat, Atri Rudra, and Martin J. Strauss. ℓ2 /ℓ2 foreach sparse recovery with low risk. In Automata, Languages, and Programming, volume 7965 of Lecture Notes in Computer Science, pages 461–472. Springer Berlin Heidelberg, 2013. 35 [GR08a] Venkatesan Guruswami and Atri Rudra. Concatenated Codes Can Achieve Listdecoding Capacity. In Proceedings of the Nineteenth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA ’08, pages 258–267, Philadelphia, PA, USA, 2008. Society for Industrial and Applied Mathematics. [GR08b] Venkatesan Guruswami and Atri Rudra. Explicit codes achieving list decoding capacity: Error-correction with optimal redundancy. IEEE Transactions on Information Theory, 54(1):135–150, 2008. [GS99] Venkatesan Guruswami and Madhu Sudan. Improved decoding of Reed-Solomon and algebraic-geometry codes. IEEE Transactions on Information Theory, 45(6), 1999. [Gur01] Venkatesan Guruswami. List decoding of error-correcting codes. PhD thesis, MIT, 2001. [Gur10] Venkatesan Guruswami. Cyclotomic function fields, artin–frobenius automorphisms, and list error correction with optimal rate. Algebra & Number Theory, 4(4):433–463, 2010. [Gur11] Venkatesan Guruswami. Linear-algebraic list decoding of folded Reed-Solomon codes. In IEEE Conference on Computational Complexity, pages 77–85, 2011. [GW11] Venkatesan Guruswami and Carol Wang. Optimal rate list decoding via derivative codes. In RANDOM ’11, 2011. [GX12a] Venkatesan Guruswami and Chaoping Xing. Folded codes from function field towers and improved optimal rate list decoding. In Proceedings of the 44th annual ACM symposium on Theory of computing (STOC), pages 339–350. ACM, 2012. [GX12b] Venkatesan Guruswami and Chaoping Xing. List decoding reed-solomon, algebraicgeometric, and gabidulin subcodes up to the singleton bound. Electronic Colloquium on Computational Complexity (ECCC), 2012. [GX13] Venkatesan Guruswami and Chaoping Xing. List decoding reed-solomon, algebraicgeometric, and gabidulin subcodes up to the singleton bound. In Proceedings of the 45th annual ACM symposium on Theory of Computing (STOC), pages 843–852. ACM, 2013. [GX14] Venkatesan Guruswami and Chaoping Xing. Optimal rate list decoding of folded algebraic-geometric codes over constant-sized alphabets. In Proceedings of the TwentyFifth Annual ACM-SIAM Symposium on Discrete Algorithms, pages 1858–1866. SIAM, 2014. [HIOS15] Iftach Haitner, Yuval Ishai, Eran Omri, and Ronen Shaltiel. Parallel hashing via list recoverability. In Rosario Gennaro and Matthew Robshaw, editors, CRYPTO, volume 9216 of Lecture Notes in Computer Science, pages 173–190. Springer, 2015. [HOW15] Brett Hemenway, Rafail Ostrovsky, and Mary Wootters. Local correctability of expander codes. Inf. Comput, 243:178–190, 2015. 36 [HW15] Brett Hemenway and Mary Wootters. Linear-time list recovery of high-rate expander codes. In ICALP ’15, volume 9134, pages 701–712, 2015. [INR10] Piotr Indyk, Hung Q. Ngo, and Atri Rudra. Efficiently decodable non-adaptive group testing. In Proceedings of the Twenty-First Annual ACM-SIAM Symposium on Discrete Algorithms, SODA ’10, pages 1126–1142, Philadelphia, PA, USA, 2010. Society for Industrial and Applied Mathematics. [KM93] Eyal Kushilevitz and Yishay Mansour. Learning decision trees using the fourier spectrum. SIAM Journal on Computing, 22(6):1331–1348, 1993. [KMRS15] Swastik Kopparty, Or Meir, Noga Ron-Zewi, and Shubhangi Saraf. High-rate locallycorrectable and locally-testable codes with sub-polynomial query complexity. Electronic Colloquium on Computational Complexity (ECCC), 2015. [KMRS16] Swastik Kopparty, Or Meir, Noga Ron-Zewi, and Shubhangi Saraf. High rate locallycorrectable and locally-testable codes with sub-polynomial query complexity. In Journal of the ACM, to appear. Preliminary version in proceedings of the 48th Annual Symposium on Theory of Computing (STOC), pages 25–32. ACM Press, 2016. [Kop15] Swastik Kopparty. List-decoding multiplicity codes. Theory OF Computing, 11(5):149– 182, 2015. [Mei09] Or Meir. Combinatorial construction of locally testable codes. SIAM J. Comput., 39(2):491–544, 2009. [NPR12] Hung Q. Ngo, Ely Porat, and Atri Rudra. Efficiently Decodable Compressed Sensing by List-Recoverable Codes and Recursion. In Christoph Dürr and Thomas Wilke, editors, 29th International Symposium on Theoretical Aspects of Computer Science (STACS 2012), volume 14 of Leibniz International Proceedings in Informatics (LIPIcs), pages 230–241, Dagstuhl, Germany, 2012. Schloss Dagstuhl–Leibniz-Zentrum fuer Informatik. [Rud07] Atri Rudra. List Decoding and Property Testing of Error Correcting Codes. PhD thesis, University of Washington, 2007. [Sti09] Henning Stichtenoth. Algebraic function fields and codes, volume 254. Springer Science & Business Media, 2009. [STV01] Madhu Sudan, Luca Trevisan, and Salil Vadhan. Pseudorandom generators without the XOR lemma. Journal of Computer and System Sciences, 62(2):236–266, 2001. [Sud01] Madhu Sudan. Algorithmic introduction to coding theory (lecture notes), 2001. [Tho83] Christian Thommesen. The existence of binary linear concatenated codes with reed solomon outer codes which asymptotically meet the gilbert- varshamov bound. IEEE Trans. Information Theory, 29(6):850–853, 1983. [Val05] Paul Valiant. The tensor product of two codes is not necessarily robustly testable. In proceedings of the 9th International Workshop on Randomization and Computation (RANDOM), pages 472–481. Springer, 2005. 37 [Var57] R. R. Varshamov. Estimate of the number of signals in error correcting codes. Doklady Akadamii Nauk, pages 739–741, 1957. [Vid11] Michael Viderman. A combination of testability and decodability by tensor products. Electronic Colloquium on Computational Complexity (ECCC), 18:87, 2011. [Vid13] Michael Viderman. Strong LTCs with inverse poly-log rate and constant soundness. In proceedings of the 54th IEEE Symposium on Foundations of Computer Science (FOCS), pages 330–339. IEEE Computer Society, 2013. [Woz58] J.M. Wozencraft. List decoding. Quarterly progress report, MIT, 1958. A List-recovery of algebraic geometry codes In this appendix, we outline how the approach of [GX13] needs to be changed in order to obtain linear list-recoverable codes. The main theorem is as follows. Theorem A.1. There are constants c, c0 so that the following holds. Choose ε > 0 and a positive integer ℓ. Suppose that q ≥ ℓc/ε is an even power of a prime. Let N0 = q c0 ℓ/ε . Then for all N ≥ N0 , there is a deterministic polynomial-time construction of an Fq -linear code (1−ε)N 2 2 C : Fq → FN q of rate 1 − ε and relative distance Ω(ε ) which is (Ω(ε ), ℓ, L)-list-recoverable in time poly(N, L), returning a list that is contained in a subspace over Fq of dimension at most q cℓ/ε ε !2log∗ (N) . In particular, when ε, ℓ, q are constant, the ouput list size L is exp(exp(exp(log∗ N ))). We remark that the list size is very slowly growing (although admittedly with extremely large constants). We follow the approach of [GX13, GK16b]. In [GX13], Guruswami and Xing show how to construct high-rate list-decodable codes over a constant alphabet, modulo a construction of explicit subspace designs. In [GK16b], Guruswami and Kopparty gave such constructions and used them to construct high-rate list-decodable codes over constant-sized alphabets with small list-sizes. We would like to use these codes here. However, there are two things which must be modified. First, the guarantees of [GX13, GK16b] are for list-decodability, and we are after list-recoverability. Fortunately, this follows from a standard modification of the techniques that they use. Second, the codes that they obtain are not linear, but rather are linear over a subfield of the alphabet. To correct this, we concatenate these codes with list-recoverable linear codes of a constant length. A random linear code has this property, and since we only require them to be of constant length, we may find such a code, and run list-recovery algorithms on it, in constant time. We begin by addressing the leap from list-decodability to list-recovery, and then discuss the code concatenation step. We refer the reader to [GX13, GK16b] for the details (and, indeed, for several definitions); here we just outline the parts which are important for list-recovery. The basic outline of the construction (and the argument) is as follows: Step 1. Show that AG codes are list-decodable, with large but very structured lists. We will extend this to list-recoverability with structured lists. 38 Step 2. Show that one can efficiently find a subcode of the AG code which will avoid this sort of structure: this reduces the list size. This part of the argument goes through unchanged, and will yield a list-recoverable code over Fqm with small list size. Once we have Fq -linear codes over Fm q that are list-recoverable, we discuss the third step: Step 3. The code produced is Fq -linear (rather than Fqm -linear). This was fine for [GX13, GK16b], but for us we require a code which is linear over the alphabet it is defined over. To get around this we concatenate the codes above with a random linear code of length m over Fq . This will result in an Fq -linear code over Fq that is list-recoverable with small list sizes. We briefly go through the details. First we give a short refresher/introduction to the notation. Then we handle the three steps above, in order. We note that throughout this appendix we will refer to Theorem and Lemma numbers in the extended version [GX12b] rather than the conference version [GX13]. Step 0. Algebraic Geometry Codes and basic notation. Since we do not need to open up the AG code machinery very much in order to extend the results of [GX13] to list-recovery, we do not go into great detail here, and we refer the reader to [GX13] and the references therein for the technical details, and to [Sti09] for a comprehensive treatment of AG codes. However, for the ease of exposition here (for the reader unfamiliar with AG codes), we will introduce some notation and explain the intuitive definitions of these notions. In particular, we will use the running example of a rational function field. We stress that this is not the final function field used; thus the intuition should be taken as intuition only. Let F/Fq be a function field of genus g. One example (which may be helpful to keep in mind) of a genus-0 function field is the rational function field Fq (X)/Fq , which may be thought of as rational functions f (X)/g(X), where f, g ∈ Fq [X] are irreducible polynomials. For the code construction, we will use a function field of larger genus (given by the Garcia-Stichtenoth tower, as in [GX13]), but we will use this example to intuitively define the algebraic objects that we need. Let P∞ , P1 , . . . , Pn be n + 1 distinct Fq -rational places (that is, of degree 1). Formally, these are ideals, but they are in one-to-one correspondence with Fq ∪ {∞}, and let us think of them that way. For each such place P , there is a map (the residue class map with respect to P ) which maps F/Fq to Fq ; we may think of this as function evaluation, and in our example of Fq (X)/Fq , if P is a place associated with a point α ∈ Fq , then indeed this maps f (X)/g(X) to f (α)/g(α). Let L(lP∞ ) be the Riemann-Roch space over Fq . Formally, this is L(lP∞ ) = {h ∈ F \ {0} : νP∞ (h) ≥ −l} ∪ {0} , where νP∞ is the discrete valuation of P∞ . Informally (in our running example), this should be thought of as the set of rational functions f (X)/g(X) so that deg(g(X)) − deg(f (X)) ≥ −l. In particular, the number of poles of f /g is at least the number of roots, minus l. It would be tempting, in this example, to think of these as degree ≤ l polynomials; all but at most l of the powers of X in the numerator are “canceled” in the denominator. Of course, there are many problems with this intuition, but it turns out that this indeed works out in some sense. In particular, it can be shown that the dimension of this space is at least l − g + 1. When g = 0 (as in our running example), it is exactly l + 1, the same as the dimension of the space of degree-≤ l polynomials. 39 More generally (whatever the genus), for any rational place P , we may write a function h ∈ Lm (lP∞ ) as ∞ X hj T j , (2) h= j=0 where T is a local parameter of P , and it turns out that h is uniquely determined by the first l + 1 coefficients h0 , h1 , . . . , hl+1 . Now let Fm be the constant extension Fqm · F , and let Lm (lP∞ ) be the corresponding RiemannRoch space. This has the same dimension over Fqm as L(lP∞ ) does over Fq . Now we consider the algebraic geometry code defined by C(m; l) := {(h(P1 ), . . . , h(Pn )) : h ∈ Lm (lP∞ )} . Following the intuition that h(Pi ) denotes function evaluation, this definition looks syntactically the same as a standard polynomial evaluation code, and should be thought of that way. This is an Fqm -linear code over Fqm , with block length n and dimension at least l − g + 1. Step 1. List-decoding with structured lists to list-recovery with structured lists. With the preliminaries (and some basic, if possibly misleading, intuition for the reader unfamiliar with AG codes) out of the way, we press on with the argument. Fix a parameter k, and consider a general AG code C(m; k+2g−1), with the notation above. (We will fix a particular AG (sub)code later, by choosing a function field and by choosing a subcode). Let S1 , . . . , Sn ⊂ Fqm be lists of size at most ℓ corresponding to each coordinate. We first show that C(m; k + 2g − 1) is (1 − α, ℓ, L)-list-recoverable for some α to be chosen below, where the list size is very large, but the list is structured. In [GX13], the approach (similar to that in [Gur11] or [GW11]) is as follows. 1. We will first find a low-degree interpolating linear polynomial (whose coefficients live in Riemann-Roch spaces) Q(Y1 , . . . , Ys ) = A0 + A1 Y + · · · + As Ys so that Ai ∈ Lm (DP∞ ) and A0 ∈ Lm ((D + k + 2g − 1)P∞ ), for some parameter k to be chosen later, for ℓn − k + (s − 1)g + 1 ⌋, D=⌊ s+1 and subject to ℓn linear constraints over Fqm . Before we list the constraints, notice that the number of degrees of freedom in Q is s(D − g + 1) + D + k + g, because the Fqm -dimension of Lm ((D + k + 2g − 1)P∞ ) is at least D + k + g, and the Fqm dimension of Lm ((DP∞ )) is at least D−g +1. Thus, the choice of D shows that the dimension of this space of interpolating polynomials is greater than ℓn. Thus, we will be able to find such a Q that satisfies the ℓn following ℓn constraints. For each i ∈ [n] and for all y ∈ Si , we have the constraint that A0 (Pi ) + A1 (Pi )y + A2 (Pi )y q + · · · + As (Pi )y q 40 s−1 = 0. 2. With this polynomial Q in hand, we observe that if h ∈ Lm ((k + 2g − 1)P∞ ) whose encoding s−1 has h(Pi ) ∈ Si for at least αn positions i, for αn > D+k+2g−1, then Q(h, hσ , . . . , hσ ) = 0, where hσ denotes the extension of the Frobenius automorphism α 7→ αq on Fqm to Lm (lP∞ ). This proof (Lemma 4.7 in [GX12b]) remains unchanged when we pass to list-recovery from list-decoding. Briefly, this agreement means that Q(h, . . . , hσ s−1 )(Pi ) = A0 (Pi ) + A1 (Pi )h(Pi ) + · · · + As (Pi )h(Pi )q s−1 =0 s−1 for at least αn values of i, and so the function Q(h, hσ , . . . , hσ ) (which lies in Lm ((D + k + 2g − 1)P∞ ); as per the intuition above, we are thinking of these as roughly analogous to degree-(D + k + 2g − 1) polynomials) has at least αn ≥ D + k + 2g − 1 roots, and hence is the zero function. 3. Thus, any element h ∈ Lm ((k + 2g − 1)P∞ ) that agrees with at least αn lists also satisfies s−1 Q(h, . . . , hσ ) = 0. It remains to analyze the space of these solutions, and to show that they are nicely structured. This requires one more step, which goes through without change. More precisely, [GX13] takes a subcode of C(m; k + 2g − 1); this subcode will still have a large list size, but the list will be structured. This resulting code, denoted C(m; k + 2g − 1|Fkqm ), has dimension k. (Recall that C(m; k + 2g − 1) has dimension k + g, so we have reduced the dimension by g.) We refer the reader to [GX13] for the details, as they do not matter for us. At the end of the day, the analysis of [GX13] (Lemma 4.8 in the full version [GX12b]) applies unchanged to show that the set of messages h in this new code that are solutions to this equation lie in a structured space: more precisely, the coefficients (h0 , h1 , . . . , hk+2g−1 ) m(k+2g−1) as in (2) belong to an (s − 1, m)-ultra-periodic subspace of Fq . For us, the precise definition of this does not matter, as we may use the rest of [GX13] as a black box. 4. Before we move on, we summarize parameters. We have so far established that there is a code C(m; k + 2g − 1|Fkqm ) that is list-recoverable with agreement parameter α and inner list sizes ℓ, resulting in a structured list. The requirement on α is: αn > D + k + 2g − 1   ℓn − k + (s − 1)g + 1 + k + 2g − 1, = s+1 and so it suffices to take ℓn − k + (s − 1)g + 1 + k + 2g − 1 s+1 1 (ℓn + s(k − 1) + g(3s + 1)) . = s+1 αn > Again, the dimension of the code is k and the length is n. It is Fqm -linear over Fqm . Step 2. Taking a subcode. For this step, we may follow the argument of [GX13] without change. Briefly, to instantiate the AG code we use a function field from a Garcia-Stichtenoth tower. The parameters of this are as follows: we choose a prime power r, and let q = r 2 . Then we choose an integer e > 0. There is a function field F = Ke so that Ke has at least n = r e−1 (r 2 −r)+1 rational places, and genus ge bounded by r e . This is the function field we will use. We remark 41 that [GX13] has to do a bit of work here to show that one can actually find a description of the structured list efficiently, but it can be done. We plug in parameters to obtain the following Lemma, which is analogous to Theorem 4.14 in [GX12b]. Lemma A.2. Let q be the even power of a prime, and choose ℓ, ε > 0. There is a parameter √ s = O(ℓ/ε) so that the following holds. Let m ≥ s and let R ∈ (0, 1). Suppose that α ≥ R+ε+3/ q. √ Then for infinitely many n (all integers of the form n = q e/2 ( q − 1)), there is a deterministic polynomial-time construction of an Fqm -linear code C of block length n, dimension k = Rn, so that the following holds: for any sets S1 , . . . , Sn ⊆ Fqm with |Si | ≤ ℓ for all i, the set of messages leading to codewords c ∈ C so that ci ∈ Si for at least αn coordinates i is contained in one of q O(mn) possible (s − 1, m)-ultra periodic Fq -affine subspaces of Fmk q . Further, this collection of subspaces can be described in time poly(n, m). Proof. Our condition on α is that it is at least ℓn + s(k − 1) + n(3s + 1)/(r − 1) ℓn + s(k − 1) + ge (3s + 1) ≤ Using ge ≤ n/(r − 1) n(s + 1) n(s + 1) ℓ + s(R − 1/n) + (3s + 1)/(r − 1) . = s+1 √ Choosing s = O(ℓ/ε) and using the fact that r = q gives the conclusion. With this lemma in hand, we may proceed exactly as the proof in [GX13]; indeed, it is exactly the same code, and we exactly the same conclusion on the structure of the candidate messages. The basic idea is to choose a subset of messages carefully via a cascaded subspace design. This ensures that the number of legitimate messages remaining in the list is small, and further that they can be found efficiently. We briefly go through parameters, again referring the reader to the discussion in [GX13, GK16b] for details. We will fix   ℓ (3) s = O(ℓ/ε), and m = O 2 · logq (ℓ/ε) . ε We now trace these choices through the analysis of [GX13, GX14]. Remark A.3. The reader familiar with these sorts of arguments might expect us to set m = ℓ/ε2 , and indeed this would be sufficient if we could allow q to be sufficiently large. However, in this case, setting m this way would result in a requirement that q ≥ ℓ/ε2 . We would like q to be independent of ℓ for the next concatenation step to work (of course, the alphabet size q m must be larger than ℓ), and this requires us to take m slightly larger. This loss comes out in the final list size. Without defining a cascaded subspace design, we will just mention that it is a sequence of T subspace designs (which we will not define either); a cascaded subspace design comes with vectors of parameters (r0 , . . . , rT ), (m0 , . . . , mT ), and (d0 , . . . , dT1 ). For i = 1, . . . , T , the i’th subspace m design in this sequence is a (ri−1 , ri )-strong-subspace design in Fq i−1 , of cardinality mi /mi−1 , and dimension di−1 . Again, for us it does not matter what a strong subspace design is, only that we may find explicit ones: 42 Theorem A.4 (Follows from Theorem 6 in [GK16b]). For all ζ ∈ (0, 1) and for all r, m with r ≤ ζm/4, and for all prime powers q so that 2r/ζ < q ζm/(2r) , there exists an explicit collection of 2 M ≥ q Ω(ζm/r) /(2r) subspaces in Fm q , each of codimension at most ζm, which form a (r, r /ζ)-strong subspace design. Remark A.5. In [GK16b], the theorem is stated for (r, r/ζ)-weak subspace designs; however, as is noted in that work, a (A, B)-weak subspace design is also a (A, AB)-strong subspace design, which yields our version of the theorem. Below, we will use Theorem A.4 in order to instantiate a cascaded subspace design. The reason we want to do this is because of Lemma 5.6 in [GX12b]: Lemma A.6 (Lemma 5.6 in [GX12b]). Let M be a (r0 , r1 , . . . , rT )-cascaded subspace design with T length-vector (m0 , m1 , . . . , mT ). Let A be an (r, m)-ultra periodic affine subspace of Fm q . Then the dimension of the affine space A ∩ U (M) is at most rT , where U (M) denotes the canonical subspace of M. We have not defined a canonical subspace, and we refer the reader to [GX12b] for details; the important thing for us is that we wish to construct a cascaded subspace design M so that rT is small, mT is equal to mk, and so that r0 = s − 1 and m0 = m. This will allow us to choose a subcode of the code from Lemma A.2 by restricting the space of messages to the canonical subspace U (M), and this will be the Fq -linear code (over Fm q ) that we are after. We may use Theorem A.4 to instantiate such a cascaded subspace design as follows (the derivation 2 /ζ . below follows the proof of Lemma 5.7 in [GX12b]). We choose ζi = ε/2i , r0 = s−1, and ri = ri−1 i √ mi−1 . We will continue up to i = T , choosing T We choose m0 = m and we will define mi = mi−1 ·q so that mT = mk. At this point, we must deal with the detail that there may be no such T ; to deal with this we do exactly as in the proof of Lemma 5.7 in [GX12b] and modify our last two choices of mT −1 , mT so that mT ≤ mk but is close (within an additive log2q (km)); for our final subspace, we will pad the mT -dimensional vectors with 0’s in order to form a subspace in Fmk with the same q ∗ T ∗ O(log (mk)) . 2 dimension. Choosing mT ≈ mk puts T = O(log (mk)), and rT = O(s/ε) ≤ (ℓ/ε) With these choices, we instantiate T subspace designs via Theorem A.4, with m ← mi , r ← ri , and ζ ← ζi . We check that the requirements of Theorem A.4 are satisfied, beginning with the requirement that ri ≤ ζi mi /4. Since mi ζi grows much faster than ri as i increases, it suffices to check this for i = 0, when we require r0 ≤ ζ0 m0 , or s − 1 ≤ mε/8. Our choices of m and s in (3) satisfy this. The next requirement is that 2ri /ζi ≤ q ζi mi /(2ri ) for all i. Again, the right hand side grows much faster than the left, and so we establish this for i = 0, requiring that 4(s − 1) ≤ q εm/4(s−1) . ε With our choices of m and s, this requirement is that ℓ ≤ q O(logq (ℓ/ε)) , ε2 which is true. Thus, Theorem A.4 provides us with a cascaded subspace design with the given parameters. As mentioned above, we may then use Lemma A.6 to choose an appropriate subcode of our AG 43 code from Lemma A.2. We have chosen the parameters above so that (r0 , m0 ) = (s − 1, m), precisely the guarantee of Lemma A.2. Thus, the final bound on the dimension of this intersection ∗ is rT ≤ (ℓ/ε)O(log (mk)) , which gives our final list size. Finally, we observeP(as in Observation 5.5 of [GX12b]) that the dimension of the resulting subcode is at least (1 − i ζi )mT = (1 − ε)mk. Thus the final code has dimension at least (1 − ε)mk over Fkm , and hence the final rate is at least √q (1 − ε)R. Observing that q must be at least ε−2 for the 1/ q term in Lemma A.2 to be absorbed into the additive ε factor, we arrive at the following theorem. Theorem A.7. Let q be an even power of a prime, and choose ℓ, ε > 0, so that q ≥ ε−2 . Choose ρ ∈ (0, 1). There is an mmin = O(ℓ logq (ℓ/ε)/ε2 ) so that the following holds for all m ≥ mmin . √ For infinitely many n (all n of the form q e/2 ( q − 1) for any integer e), there is a deterministic n polynomial-time construction of an Fq -linear code C : Fρn q m → Fq m of rate ρ and relative distance 1 − ρ − O(ε) that is (1 − ρ − ε, ℓ, L)-list-recoverable in time poly(n, L), returning a list that is contained in a subspace over Fq of dimension at most  2log∗ (mk) ℓ . ε We note that the distance of the code comes from the fact that it is a subcode of C(m; k+3ge −1), which has distance at least n − (k + 2g − 1) = n − 2g − k + 1. In the above parameter regime, the √ genus ge satisfies ge ≤ n/(r − 1) = n/( q − 1) = O(εn). Thus, the relative distance of the final code is at least (n − 2ge − k + 1)/n ≥ 1 − O(ε) − ρ. Step 3. Concatenating to obtain Fq -linear codes over Fq . Theorem A.7 gives codes over Fqm which are Fq -linear. For our purposes, to prove Theorem A.1, we require codes over Fq which are Fq -linear. Thus, we will concatenate these codes with random Fq -linear codes from Corollary 4.4 and apply Lemma 7.4 about the concatenation of list-recoverable codes. In more detail, we choose parameters as follows. Let ε > 0 and let ε′ = ε/2, and choose any integer ℓ and any block length N . Fix a constant c and parameters m and e which will be determined below. Choose an even prime power q so that n o q ≥ max ℓc/ε , ε−c . Let Cin be a random q-ary linear code of rate ρin = 1 − ε′ of length m/ρin . By Corollary 4.4, there exists an Fq linear code Cin with rate ρin = 1 − ε′ and block length m/ρin which is (αin , ℓin , Lin )′ list-recoverable, for αin = ε′ /2, ℓin = ℓ, and Lin = q 2cℓ/ε . We note that we can choose c large enough to ensure that the hypothesis of Corollary 4.4 hold. Let Cout be the codes from Theorem A.7, instantiated with rate ρin = 1 − ε′ , ε ← ε′ /2 and √ ℓ ← Lin . With these parameters, we will get a code over Fqm of length n = q e/2 ( q − 1) which is (αout , Lin , Lout )-list-recoverable, where   log ∗ (mk) Lout = expq (Lin /ε′ )2  !2log∗ (mk)  2cℓ/ε′ q  = expq  ε′ 44 and where αout = 1 − ρin − ε′ = ε′ /2. Let mmin be as in Theorem A.7, so that ′ mmin = O(Lin logq (Lin /ε′ )/(ε′ )2 ) = O q cℓ/ε cℓ (ε′ )3 ! . We will choose m so that mmin ≤ m ≤ q · mmin . (4) ′ O(q cℓ/ε cℓ/(ε′ )3 ), choosing m slightly larger than mmin — Notice that, given the definition of mmin = as large as q · mmin —amounts to replacing the constant c with c + 1. Thus, the choices of m and c (subject to (4)) will not affect the list-recoverability of Cout , but they will affect the block length of the concatenated code. Formally, Lemma 7.4 implies that the concatenated code has rate ρin · ρout = (1 − ε′ )2 ≥ 1 − ε, and is (αin αout , ℓ, Lout )-list-recoverable. Here, we have αin αout = (ε′ )2 /4 = Ω(ε2 ), which is what is claimed in Theorem A.1. The output list size claimed in Theorem A.1 follows from the choice of m and our guarantee on Lout . We note that the concatenated code will have message length K = mk, and so we write log∗ (mk) = log∗ (K). Finally, we choose m and e. At this point, the choice of these parameters (subject to (4)) will not affect that list-recoverability of the concatenated code, but they do control the block length of the code and the running time of the decoding algorithm. The block length is √ m · q e/2 ( q − 1). ρin In order to prove that we can come up with such codes for all sufficiently large block lengths N , as required in the statement of Theorem A.1, we must show that for all sufficiently large N , we can choose m satisfying (4) and e so that m √ · q e/2 ( q − 1). N= ρin That is, we want to find an integer e so that N · (1 − ε/2) ∈ [mmin , q · mmin ]. √ q e/2 ( q − 1) However, we have chosen this window for m to be large enough so that such an e exists as long as N is sufficiently large (in terms of q, ℓ, ε). More precisely, for some large enough constant C, we require N ≥ q Cℓ/ε , which is our choice of N0 in Theorem A.1. Now we verify the running time of the list-recovery algorithm. The outer code Cout can be list-recovered in time poly(n, Lout ) by Theorem A.7. The inner code can be list-recovered by brute force in time q O(m) = expq O q 2(c+1)ℓ/ε ℓ/ε3 = poly(Lout ). Lemma 7.4 implies that the final running time is poly(N, L), where L = Lout is the final list size and N is the block length of the concatenated code. 45
7cs.IT
Energy Shaping Control of an Inverted Flexible Pendulum Fixed to a Cart Prasanna S. Gandhib , Pablo Borjaa , Romeo Ortegaa a Laboratoire b Suman de Signaux et Systèmes, CentraleSupelec, 91192 Gif-sur-Yvette, France Mashruwala Advanced Microengineering Laboratory, Department of Mechanical Engineering, Indian Institute of Technology. Powai, Mumbai 400076, India. arXiv:1605.02991v1 [cs.SY] 10 May 2016 Abstract Control of compliant mechanical systems is increasingly being researched for several applications including flexible link robots and ultra-precision positioning systems. The control problem in these systems is challenging, especially with gravity coupling and large deformations, because of inherent underactuation and the combination of lumped and distributed parameters of a nonlinear system. In this paper we consider an ultra-flexible inverted pendulum on a cart and propose a new nonlinear energy shaping controller to keep the pendulum at the upward position with the cart stopped at a desired location. The design is based on a model, obtained via the constrained Lagrange formulation, which previously has been validated experimentally. The controller design consists of a partial feedback linearization step followed by a standard PID controller acting on two passive outputs. Boundedness of all signals and (local) asymptotic stability of the desired equilibrium is theoretically established. Simulations and experimental evidence assess the performance of the proposed controller. Keywords: Energy shaping, compliant systems, Lagrangians systems, holonomic constraints, PID controllers. 1. Introduction The problem of stabilization of underactuated mechanical systems, both in the domain of ordinary and partial differential equations, has been widely addressed by several control researchers in recent years. In the domain of flexible mechanisms and robots, flexibility in the links is the main source of underactuation. If the deformations due to flexibility are small it is possible to use an unconstrained Lagrange formulation and invoke the Assumed Modes Method (AMM) [1] to obtain a simple, finite–dimensional model—see [2] for a recent literature review. This modeling procedure, however, is inapplicable for systems with large deformations, for which a constrained Euler–Lagrange (EL) formulation is required. This approach has been adopted in [3] to derive an accurate model for a single ultra–flexible link fixed to a cart. Potential energy change owing to ultra–large deformations in the presence of gravity is considered in [3] using the constant length of the beam as a holonomic constraint. For a survey on recent control techniques for this class of systems see [3, 4, 5]. The objective of this paper is to design an energy shaping controller with guaranteed stability properties for the model of a single ultra–flexible link fixed to a cart reported in [3]. As is well known [6] the application of energy shaping controllers is stymied by the need to solve partial difEmail addresses: [email protected] (Prasanna S. Gandhi), [email protected] (Pablo Borja), [email protected] (Romeo Ortega) ferential equations (PDEs) that identify the mechanical structure (Lagrangian or Hamiltonian) that is assigned to the closed–loop. To propose a truly constructive energy shaping scheme, that does not require the solution of PDEs, it was recently proposed in [7] to relax the constraint of preservation in closed–loop of the EL structure. The design in [7] proceeds in two steps, first, we apply a partial feedback linearization (PFL) [8] that transforms the system into Spong’s normal form—if this system is still EL, two new passive outputs are immediately identified. Second, a classical PID around a suitable combination of these passive outputs completes the design. It is shown in the paper that this technique, developed for standard EL systems in [7], is also applicable to the constrained EL system at hand. This extension is far from obvious, because the (lower order) dynamics that results from the projection of the system on the manifold defined by the constraint is not an EL system. In spite of this fact it is shown that, because of the workless nature of the forces introduced by the constraints, it is still possible to identify the two new passive outputs to which the PID is applied. The remainder of the paper is organized as follows. Section 2 presents the full constrained EL dynamics of the system and its reduced order projection. Section 3 presents the proposed energy shaping control algorithm. Section 4 presents the simulation results, while in Section 5 we show the experimental ones. Section 6 summarizes the work and outlines some future research. Notation: Unless indicated otherwise, all vectors in the paper are column vectors. Given n ∈ N, ei ∈ Rn is the i–th Euclidean basis vector of Rn . For x ∈ Rn , we denote |x|2 := x⊤ x. To simplify the expressions, the arguments of all mappings—that are assumed smooth—will be explicitly written only the first time that the mapping is defined. For a scalar function V : Rn → R, we define ⊤ 2 and ∇2x V := ∂∂xV2 —when clear from the ∇x V := ∂V ∂x context the subindex in ∇ will be omitted. 2. System Dynamics and Problem Formulation In [3] a dynamic model that accurately describes the behaviour of the single ultra–flexible link fixed to a cart depicted in Fig. 1 is reported. The main feature of this model, which distinguishes it from other models, is that to take into account large deformations of the link its length is assumed constant—giving rise to a holonomic constraint. The model is rigorously developed using a constrained EL formalism, combined with a standard application of the AMM, and its validity is experimentally validated. In this section we present this model, first, in its constrained EL form and then in a reduced form—obtained via the elimination of the constrained equations. Figure 1: Single ultra–flexible link with base excitation The different terms entering into (1) are defined as   D1 (xe ) 0 D2 (xe ) D3 0 , D(q) :=  0 D2 (xe ) 0 D4   A1 (θ, xe ) A(q) = A2 (θ, xe ) := ∇Γ(q), R := diag{R1 , 0, R3 }, 0  1 1 δ(xe , θ̇, ż) 2 C1 (xe )ẋe 2 C2 (xe )ẋe C(q, q̇) := −δ(xe , θ̇, ż) 0 − 1 C2 (xe )θ̇  , 2.1. Constrained Euler–Lagrange Model The model reported in [3] admits a constrained EL representation of the form D(q)q̈ + C(q, q̇)q̇ + B(q) + Rq̇ = e3 τ + λA(q) Γ(q) = 0, 1 2 C2 (xe )ẋe with (1) and (4) E, I, D3 , R1 , R3 are defined in Table 1 and the remaining functions are given in Appendix A. with L > 0 the length of the link and φ the mode shape function of the AMM [1] reported in [9], that is, φ(x) = cosh − cos L  i h L ηx  ηx + γ sin − sinh , L L 1 1 C1 (xe )θ̇ + C2 (xe )ż, 2 2   B1 (θ, xe ) B(q) = B2 (θ, xe ) := ∇V (q) 0 0 where V is the potential energy of the system given by Z xe 2 [θφ′′ (x)] 1 V (q) = EI o3 dx − D3 g(L − xe ), n 2 2 0 1 + [θφ′ (x)] 0  ηx  2 δ(xe , θ̇, ż) := where q = col(θ, xe , z) ∈ D × R+ × R are the generalised coordinates, R ≥ 0 is a matrix of damping coefficients. D > 0 is the inertia matrix, C q̇ are the Coriolis and centrifugal forces, B is a conservative force vector due to potential energy, τ is control vector, λA is a vector of virtual forces due to the holonomic constraint, with λ the Lagrange multiplier, and Γ is the (constant length) constraint function given by Z xe q 2 (2) Γ(q) := 1 + [θφ′ (x)] dx − L,  ηx  1 2 C2 (xe )θ̇ Problem formulation: Given the system (1) find a control input τ that places the beam at its vertical position with the cart stopped at the zero position, i.e., that renders the point q∗ := (0, L, 0) a (locally) asymptotically stable equilibrium. (3) where η and γ are given in the table 1. The analysis made in [3] considers only one mode where the deflection α(θ, x) is given by α(x, θ) = φ(x)θ. Remark 1. In [3] the model (1) is obtained applying EL equations to the constrained Lagrangian L(q, q̇, λ) = T (q̇, q) − V (q) + λΓ(q) 2 Replacing (8) in (1) it is possible to eliminate the Lagrange multiplier λ—as done in [3]. Moreover, using (9), we can eliminate the coordinate xe to reduce the order of the system. After some lengthy, but straightforward calculations, this leads to the equations (7) with the definitions where λ is a Lagrange multiplier and T is the kinetic energy of the system given by T (q̇, q) = 1 ⊤ q̇ D(q)q̇. 2 Remark 2. It should be noted that the well known [10] skew–symmetry property Ḋ(q) = C(q, q̇) + C ⊤ (q, q̇), A21 (θ, x̂e (θ)) A22 (θ, x̂e (θ)) A1 (θ, x̂e (θ)) 1 A1 (θ, x̂e (θ)) Cθ (θ) := D3 2 ζ − C1 (x̂e (θ)) A2 (θ, x̂e (θ)) 2 A2 (θ, x̂e (θ)) A1 (θ, x̂e (θ)) Bθ (θ) := B1 (θ, x̂e (θ)) − B2 (θ, x̂e (θ)) A2 (θ, x̂e (θ)) Dz (θ) := D2 (x̂e (θ)) Dθ (θ) := D1 (x̂e (θ)) + D3 (5) is satisfied. Unfortunately, this important property is of no use for controller design in the present context. Remark 3. In [3] the analysis of the open–loop equilibria of (1) is carried out. In particular, it is proven that the open–loop equilibrium set is given by Cz (θ) := −C2 (x̂e (θ)) A1 (θ, x̂e (θ)) , A2 (θ, x̂e (θ)) (10) where E := {(θ, xe , z) ∈ D × R+ × R | A21 (θ, x̂e (θ)) A22 (θ, x̂e (θ)) A1 (θ, x̂e (θ)) − A3 (θ, x̂e (θ)) . A2 (θ, x̂e (θ)) A1 (θ, xe )B2 (θ, xe ) − A2 (θ, xe )B1 (θ, xe ) = 0} . (6) ζ =A5 (θ, x̂e (θ)) + A4 (θ, x̂e (θ)) Furthermore, and not surprisingly, it is shown that the desired equilibrium q∗ ∈ E and is unstable. 2.2. Reduced purely differential model In this subsection we apply the standard constraint differentiation procedure [11] to transform the algebro– differential equations (1) to a purely differential form of reduced order. Remark 4. The first equation in (8) can be re-written as follows A⊤ (q)q̇ = 0. (11) Consequently, differentiating the total energy of (1)—that is given as H(q, q̇) := T (q, q̇) + V (q)—and using the skew– symmetry property (5) yields the usual power balance equation Ḣ = −q̇ ⊤ Rq̇ + q̇3 τ. Proposition 1. The system dynamics (1) is equivalent to Dθ (θ)θ̈ + Dz (θ)z̈ + Cθ (θ)θ̇2 + R1 θ̇ + Bθ (θ) 2 Dz (θ)θ̈ + D4 z̈ + Cz (θ)θ̇ + R3 ż = 0 = τ (7) This means that the virtual forces introduced in the equations due to constrained Lagrange formulation are workless, that is, they are not responsible for addition or removal of energy from the system. This key property is used later to identify the passive outputs used for the design of the energy shaping controller. with the functions Dθ , Cθ , Bθ , Dz and Cz given in (10). Proof 1. Differentiating the constraint equation (2), we get A1 (θ, xe )θ̇ + A2 (θ, xe )ẋe = 0 A1 (θ, xe )θ̈ + A2 (θ, xe )ẍe + A3 (θ, xe )θ̇ ẋe +A4 (θ, xe )ẋ2e + A5 (θ, xe )θ̇2 = 0, Remark 5. The admissible initial conditions for the reduced system (7) are restricted to the set (8) where the functions Ai , i = 3, 4, 5, are given in the Appendix. Now, the constraint (2) satisfies q 2 A2 (θ, xe ) = 1 + [θφ′ (xe )] , {(θ, z) ∈ D × R | Γ(θ, x̂e (θ)) = 0}, where, clearly, the system evolves. which is clearly bounded away from zero. Invoking the Implicit Function Theorem [12] we can guarantee the existence of a function x̂e (θ) such that 3. Energy Shaping Control As explained in the introduction the energy shaping control of [7] proceeds in three steps: a partial feedback linearization, identification of two passive outputs and the addition of a PID loop around a suitable combination of these outputs. These steps are applied to the system (7) in the following subsections. Γ(θ, x̂e (θ)) = 0. Equivalently, it is possible to express xe in terms of θ, that is xe = x̂e (θ). (9) 3 Proof 3. First, notice that 3.1. Partial feedback linearization The lemma below describes a first static state–feedback that performs the PFL of the system (7). V̇θ Lemma 1. Consider the system (7) in closed–loop with the control   Dz Dz Dz τ =R3 ż + Cz − Cθ θ̇2 − R1 θ̇ − Bθ Dθ Dθ Dθ   Dz2 + D4 − u. (12) Dθ = = = = z̈ = Gθ (θ)u = u, ∂V ˙ ∂V θ̇ + x̂e ∂θ ∂ x̂e B1 (θ, xe )θ̇ + B2 (θ, xe )x̂˙ e B1 (θ, x̂e (θ))θ̇ + B2 (θ, x̂e (θ))ẋe   A1 (θ, x̂e (θ)) θ̇ B1 (θ, x̂e (θ)) − B2 (θ, x̂e (θ)) A2 (θ, x̂e (θ)) Bθ (θ)θ̇, (13) Ḋθ = 2Cθ θ̇. where Gθ (θ) := −Dz (θ). Ḋθ = Ḋ1 (x̂e (θ)) + 2D3 A1 (θ, x̂e (θ)) Ȧ1 (θ, x̂e (θ)) A22 (θ, x̂e (θ)) A21 (θ, x̂e (θ)) Ȧ2 (θ, x̂e (θ)) A32 (θ, x̂e (θ))   ∂A1 ˙ A1 (θ, x̂e (θ)) ∂A1 ∂D1 ˙ θ̇ + x̂e + 2D3 2 x̂e = ∂ x̂e A2 (θ, x̂e (θ)) ∂θ ∂ x̂e   2 A (θ, x̂e (θ)) ∂A2 ∂A2 ˙ − 2D3 13 θ̇ + x̂e A2 (θ, x̂e (θ)) ∂θ ∂ x̂e − 2D3 Now, replacing the latter expression in the second equation of (7), we get  Dz  Dz z̈ + Cθ θ̇2 + R1 θ̇ + Bθ + D4 z̈ + Cz θ̇2 + R3 ż = τ. Dθ = C1 (x̂e (θ))ẋe Substituting the control law (12) in the equation above we obtain the second equality of (13). The first equation results, replacing z̈ = u in the first equation of (7).  1 A1 (θ, x̂e (θ)) A5 (θ, x̂e (θ))θ̇ + A3 (θ, x̂e (θ))ẋe + 2D3 2 A2 (θ, x̂e (θ)) 2   A1 (θ, x̂e (θ)) 1 − A3 (θ, x̂e (θ))θ̇ + A4 (θ, x̂e (θ))ẋe A2 (θ, x̂e (θ)) 2   A1 (θ, x̂e (θ)) A1 (θ, x̂e (θ)) = −C1 (x̂e (θ)) + 2D3 2 ζ θ̇ A2 (θ, x̂e (θ)) A2 (θ, x̂e (θ)) 3.2. Identification of the passive outputs In the following lemma the new cyclo–passive1 maps for the system (13) are identified. Lemma 2. Consider the system (13). The signals ya yu (19) Indeed, computing the time derivative of Dθ we get Proof 2. The proof proceeds rewriting the first equation of (7) as follows  1  (14) Dz z̈ + Cθ θ̇2 + R1 θ̇ + Bθ . θ̈ = − Dθ − (18) where we have used (4) for the second identity, (9) for the third one and the first equation in (8) for the fourth one. Now we will prove that Then, the system can be written in Spong’s normal form Dθ (θ)θ̈ + Cθ (θ)θ̇2 + R1 θ̇ + Bθ (θ) = = 2Cθ θ̇, := ż := Gθ (θ)θ̇, where we used the first equation of (8) to eliminate ẋe in the fourth identity. The time derivative of (16) along the system trajectories is define cyclo–passive maps u 7→ ya and u 7→ yu with storage functions 1 2 ż (15) Ha (z) = 2 1 Hu (θ) = Dθ (θ)θ̇2 + Vθ (θ), (16) 2 respectively, where 1 Ḣu = Dθ θ̇θ̈ + Ḋθ θ̇2 + V̇θ 2   1 = Gθ u − Cθ θ̇2 − R1 θ̇ + Ḋθ θ̇ θ̇ 2 = −R1 θ̇2 + Gθ θ̇u ≤ uyu . Vθ (θ) := V (θ, x̂e (θ)). where (14) and (18) were used in the second equality while the third one was obtained invoking (19). On the other hand, the time derivative of (15) along the system trajectories is More precisely, the time derivative of the functions Ha and Hu along the solutions of (13) satisfy the dissipation inequalities Ḣa ≤ uya , Ḣu ≤ uyu . (17) Ḣa = ż z̈ = uya . 1 We recall that the difference between cyclo–passive and passive maps is that in the former one the storage function is not necessarily bounded from below. This completes the proof. 4 respect to the desired equilibrium) function of the state (θ, z, θ̇, ż) of the system (13). Notice that for this reduced system the desired equilibrium is simply the origin. To express W as a function of the state we only need to deal with the integral term. For, we define the function ! Z Z 3.3. PID controller Similarly to [7] the controller design is completed adding a PID around a suitably weighted sum of the two cyclo– passive outputs (ya and yu ) identified in Lemma 2. More precisely, the controller implements the relationship   Z t ˙ ke u = − KP ỹ + KI ỹ(s)ds + KD ỹ , (20) θ VN (θ) := −D3 0 ρA0 0 where ỹ := ka ya + ku yu L φ(x̂e (s))ds − φ(x)dx θ, 0 whose time derivative is given by (21) with ke , ka , ku ∈ R and KP , KI , KD ∈ R+ the PID gains. As explained in [7], and illustrated below, these gains are selected to shape the energy function. To implement the controller (20) without differentiation the term ỹ˙ is replaced by its evaluation along the system dynamics (13). Since the system is relative degree one this brings along some terms depending on u that are moved to the left hand side of (20). Some lengthy, but straightforward, calculations show that (20) is equivalent to   Z t K(θ)u = − KP ỹ + KI ỹ(s)ds − KD ku S(θ, θ̇), V̇N = −D3 φ(x̂e (θ))θ̇ − ρA0 Z ! L φ(x)dx θ̇ 0 = −Dz θ̇ = Gθ θ̇ = yu . Consequently Z t ỹ(s)ds = ka z(t) + ku VN (θ(t)) + c, 0 where c ∈ R is an integration constant. Using the latter and the definitions of Ha , Hu and ỹ we can prove that, up to an additive constant, 0 where we defined the functions i Gθ h Cθ θ̇2 + R1 θ̇ + Bθ S(θ, θ̇) := Ġθ θ̇ − Dθ   G2θ (θ) . K(θ) := ke + KD ka + ku Dθ (θ) W (t, ỹ, θ, θ̇, ż) =    ⊤ 1 θ̇ θ̇ + Vd (θ, z) =: Hd (θ, z, θ̇, ż) Dd (θ) ż 2 ż (23) where we defined  k k D (θ) + ku2 KD G2θ (θ) Dd (θ) := e u θ ka ku KD Gθ (θ) Clearly, a sufficient condition for the controller to be implementable is that the function K is bounded away from zero, that is, |K| ≥ δ > 0. (22)  ka ku KD Gθ (θ) ke ka + ka2 KD (24) 1 2 Vd (θ, z) := ke ku Vθ (θ) + KI [ka z + ku VN (θ)] . 2 To analyse the stability of the system (13) in closed–loop with the PID (20), (21) we propose the function (25) Remark 6. Without the assumption that R1 = 0 a term −ke ku R1 θ̇2 appears in Ẇ . As will be shown below, see also [7] and Remark 7, to make the upward position a minimum of the total energy function Hd it is necessary to flip the potential energy of the pendulum, which is done selecting ke ku < 0, making positive the dissipation term. The deleterious effect of dissipation in energy shaping methods is well known and has been reported in various references [13, 14]. W (t, ỹ, θ, θ̇, ż) :=ke [ka Ha (ż) + ku Hu (θ, θ̇)] Z t 2 KI KD 2 + ỹ , ỹ(s)ds + 2 2 0 and make the reasonable assumption that the friction forces acting on the beam are negligible, hence set R1 = 0. The derivative of W yields Z t KD ˙ ỹỹ ỹ(s)ds + Ẇ = ke (ka Ḣa + ku Ḣu ) + KI ỹ 2 0 Z t KD ˙ ỹ ỹ = ke ỹu + KI ỹ ỹ(s)ds + 2 0 = −KP ỹ 2 , 3.4. Main stability result The proposition below, which essentially gives conditions on the controller gains to ensure Hd is positive definite, is the main result of this section. where we used the dissipation inequalities (17)—that under the assumption R1 = 0 become equalities—to get the second identity and replaced (20) to find the last one. The final step in our stability analysis is to show that the function W can be expressed as a positive definite (with Proposition 2. Consider the system (1) in closed–loop with the controller (12) where the outer–loop control u is given by the PID (20) with ỹ = ka ż + ku Gθ (θ)θ̇. 5 (26) Set the constant gains ke , ka and the PID gains KP , KI and KD to arbitrary positive numbers while ku is negative and, for some small ǫ > 0, satisfies   ke ku ≤ −C ka + − ǫ, (27) KD by ∇2 V d =  ke ku ∇2 Vθ + KI ku ∇2 (ka z + ku VN ) −KI ku ka Dz =  ν(θ, z) −KI ku ka Dz where C is a positive constant verifying C≥ Dθ (θ) . G2θ (θ) −KI ku ka Dz KI ka2   −KI ku ka Dz , KI ka2 where we defined the function (28) ν(θ, z) := ke ku ∇2 Vθ +KI ku2 Dz2 −KI ku ∇Dz (ka z + ku VN ) . (i) The origin of the reduced dynamics (7), which corresponds to the desired equilibrium q∗ = (0, L, 0) of (1), is stable with Lyapunov function Hd given in (23). Evaluating it at the origin yields   ν(0) −KI ku ka Dz (0) 2 ∇ Vd (0) = , −KI ku ka Dz (0) KI ka2 (ii) It is asymptotically stable if the signal ỹ defined in (26) is detectable with respect to (13). (29) where ν(0) = ke ku ∇2 Vθ (0) + KI ku2 Dz2 (0). Proof 4. In Lemma 1 it has been shown that the dynamics of the system (1) in closed–loop with the controller (12) is described by (13). Therefore, given the derivations above, it only remains to prove that the non–increasing function Hd , defined in (23), is positive definite. This will be established proving that, under the conditions of the proposition Dd > 0 and Vd has an isolated minimum at the origin. To prove the first claim notice from (24) that the (2, 2) term of Dd is positive. Hence it only remains to show that its determinant is also positive. Now,  det{Dd } = ke ku Dθ ke ka + ka2 KD + ke ku2 ka KD G2θ    = ke ku Dθ ke ka + ka2 KD + ku ka KD G2θ   ke 2 Dθ ) + ku . (ka + = ke ku ka KD Gθ G2θ KD Now, ∇2 Vθ (0) = EI Z 0 x̂e (0) [φ′′ (x)]2 dx − D3 g Z x̂e (0) [φ′ (x)]2 dx, 0 which can be shown to be negative [3]. Since ke ku < 0 the (1, 1) term of ∇2 Vd (0) is positive. Moreover, det{∇2 Vd (0)} = ke ku ∇2 Vθ (0)KI ka2 , which is also positive, ensuring∇2 Vd (0) > 0. The previous analysis ensures that the origin is an isolated minimum for the function Vd as claimed above. The proof is completed invoking classical Lyapunov theory [12]. Remark 7. Notice that the condition ∇2 Vθ (0) < 0 is consistent with the well known fact that the upward pendulum position is unstable in open–loop. Similarly to the rigid case [7] the maximum of the open–loop potential energy is transformed into a minimum in closed–loop multiplying Vθ by the negative number ke ku —see (25). Since ke ku < 0, the term outside the brackets is negative. Furthermore, if (27) and (28) are satisfied, the term inside the brackets is also negative, yielding det{Dd } > 0. We proceed now to prove that the condition (22), which ensures realisability of the control (20), is satisfied. This is established noticing that   Dθ (θ) ke Dθ (θ) ka + + ku . KD K(θ) = 2 G2θ (θ) Gθ (θ) KD Remark 8. The critical condition (27) is satisfied in a neighborhood of the origin replacing C by RL D3 φ2 (L) + ρA0 0 φ2 (x)dx Dθ (0) i2 = 2 . h RL Gθ (0) D3 φ(L) + ρA0 0 φ(x)dx Hence, invoking (27), we have that (22) holds. To establish the proof of the second claim we compute the gradient of Vd as   ke ku ∇Vθ + KI ku ∇VN (ka z + ku VN ) ∇Vd = KI ka (ka z + ku VN )   ke ku Bθ − KI ku Dz (ka z + ku VN ) = . KI ka (ka z + ku VN ) Remark 9. The term ka z + ku VN (θ) in (25) is a new potential energy corresponding to a virtual spring attached to the cart—thereby enabling to stabilize the cart position. Remark 10. The choice of the free gains of Proposition 2 is given just as an illustration. From the proof it is clear that, depending on the particular problem, other (possibly less conservative) choices are available. Using the fact that Bθ (0) = 0 and VN (0) = 0 we conclude that ∇Vd (0) = col(0, 0). Now, the Hessian of Vd is given 6 The partial feedback linearization was replaced by the standard procedure of obtaining the desired trajectories for z via the integration of the cart acceleration, which is numerically reconstructed. The set of gains used in the experiment are ke = 1, ka = 1, ku = −47.5, KD = 1.9, KP = 3 and KI = 0.9. Simulation results are repeated for this set of gains. Figure 6 presents the comparison of simulation results with experimental counterparts for the set of initial conditions ICs 2. The results demonstrate that the control task is achieved in a similar time although the trajectory in the experiments shows more oscillations with high frequency components of the vibrations of the beam. These oscilations are not captured by the simulation model that, as explained in Section 2, retains only the first deflection mode. However, as shown in the plots, these high frequency vibrations degrade the transient performance but do not induce instability. A video of the experiments can be watched in https://youtu.be/YBcI9WIaQa0. 4. Simulation Results In this section we assess the performance of the proposed controller via Matlab simulations choosing different sets of gains and different initial conditions. We simulated the system (13) in closed–loop with the PID controller (20), (26) with the parameters given in Table 1. We have chosen three different initial conditions, given in Table 2, corresponding to radically different scenarios of the system. Namely, an arbitrary point (ICs1), one of the stable open-loop equilibria (ICs2) and an initial condition with the cart far from the origin and the tip mass located at the unstable open–loop equilibrium (ICs3). For the selection of suitable gains for the controller, we fixed the gain ke = 1 and linearized the closed–loop system. We based our criterion to choose the gains, always satisfying (22) and (27), and observing the eigenvalues of the closed–loop matrix of the linearized system around the desired equilibrium point. Particular attention has been paid to the eigenvalue closest to the imaginary axis, which is directly related to the rate of convergence of the cart position. Three sets of gains were selected and they are given in Table 3. For the Set 1 the real part of the slowest pole was −0.58, −0.75 for the Set 2 and −1.33 for Set 3. Simulation results of the energy shaping control are shown in Figures 3–5, where the variation of the cart position and control input acceleration is observed to be within practical limits, hence the control objective of simultaneous stabilisation of cart position while suppressing the cantilever vibrations is achieved. To evaluate the effect of the gains on the estimate of the domain of attraction of the closed–loop systems provided by the Lyapunov function Hd we show in Figure 2 the level curves of the desired potential energy Vd for each set of gains. As expected, there is a tradeoff between convergence rate and the size of the domain of attraction—as the slowest closed–loop pole of the linearized system moves farther to the left the closed sublevel sets shrink. 6. Conclusions and Future Research The new energy shaping, fully constructive, controller of [7] has been applied for the stabilisation of the upward unstable position of a cart with an ultra–flexible beam. The dynamics of this system is accurately described by an EL system with an algebraic constraint. The reduction of this dynamics to the constrained manifold is not an EL system, therefore the technique of [7] must be modified for its application in our system. It is shown in the paper that, due to the lossless nature of the constraint forces, it is still possible to identify the passive outputs required for the controller design, which is completed adding a classical PID controller around a suitable combination of these outpus. The performance of the proposed controller is assessed via simulations and experiments. The experiments showed that the parameters identified in [3] do not capture the dynamic behaviour required for the controller design. A new identification stage, aimed at correcting this deficiency, is currently under way. Another line of research that we are pursuing pertains to the development of a theory for general constrained EL systems that will extend the work done in [7] for unconstrained EL systems. 5. Experimental Results Experiments were also carried out to assess the performance of the proposed controller. The physical description of the experimental setup is provided in Appendix B. Although the simulations of the previous section demonstrate effectiveness with three sets of gains, it was found that the control becomes unstable for the same gains in the experiments and it was necessary to retune them via a trail-and-error procedure. We believe this problem was due to a discrepancy in the values of the parameters of the model, which were identified in [3] to capture the multiple equilibria and chaotic behaviour observed experimentally. A different parameter identification process is necessary to reproduce the smooth dynamical transients for small beam deviations, which is the behaviour assumed for the controller design. Acknowledgment Pablo Borja would like to thank the mexican Secretary of Public Education (SEP) and the mexican National Council of Science and Technology (CONACyT) for supporting his research. The work of Romeo Ortega was supported in part by the Government of Russian Federation (Grant 074-U01) and the Ministry of Education and Science of Russian Federation (Project 14.Z50.31.0031). 7 Table 1: System parameters Parameter Pendulum cross section area Young’s modulus Gravitational acceleration Moment of inertia Pendulum length Tip mass Cart mass Function of the system natural frequency Dimensionless constant Pendulum density Viscous friction at the pendulum base Viscous friction between the rail and the cart Symbol Ao E g I L M Mc η γ ρ R1 R3 Table 2: Initial conditions ICs 1 ICs 2 ICs 3 θ [m] −0.08 0.134 0 z [m] −0.1 0 −0.15 θ̇ [m/s] 0 0 0 ż [m/s] 0 0 0 Value 8 × 10−6 9 × 1010 9.81 1.066 × 10−13 0.305 2.75 × 10−2 0.1 1.1741 0.9049 8400 9.86 × 10−4 7.69 Units m2 N m2 m seg 2 kg · m2 m kg kg − − kg m3 kg seg kg seg Table 3: Gains sets Set 1 Set 2 Set 3 ke 1 1 1 ka 0.5 1 1 ku −50.77 −61.37 −43.04 KD 1.47 1.28 2.18 KP 1.94 1.92 3.66 Figure 2: Level curves of the desired potential energy Vd (θ, z) for the different sets of gains 8 KI 0.35 0.52 1.35 X vs Time Tip mass position vs Time e 0.306 Set 3 Set 2 Set 1 0.06 0.304 0.04 0.02 α [m] Xe [m] 0.302 0.3 0.298 0.296 0.294 0 5 10 Time [s] 15 0 −0.02 L Set 3 Set 2 Set 1 −0.04 −0.06 −0.08 0 20 5 Cart position vs Time 10 Time [s] 15 20 Cart acceleration vs Time 0.5 0 0 −0.05 u [m/s2] z [m] −0.1 −0.15 −0.2 −0.25 Set 3 Set 2 Set 1 −0.3 −0.35 0 5 10 Time [s] 15 −0.5 −1 Set 3 Set 2 Set 1 −1.5 −2 0 20 5 10 Time [s] 15 20 Figure 3: Simulation results for ICs 1 Xe vs Time Tip mass position vs Time 0.15 0.305 Set 3 Set 2 Set 1 0.1 L Set 3 Set 2 Set 1 0.29 0.285 0 0.05 α [m] 0.295 5 10 Time [s] 15 0 −0.05 −0.1 0 20 5 Cart position vs Time 10 Time [s] 15 20 Cart acceleration vs Time 0.4 2 Set 3 Set 2 Set 1 Set 3 Set 2 Set 1 1.5 u [m/s2] 0.3 z [m] Xe [m] 0.3 0.2 1 0.5 0.1 0 0 0 5 10 Time [s] 15 −0.5 0 20 Figure 4: Simulation results for ICs 2 9 5 10 Time [s] 15 20 X vs Time Tip mass position vs Time e 0.3055 0.04 0.305 0.03 0.02 0.304 α [m] Xe [m] 0.3045 0.3035 L Set 3 Set 2 Set 1 0.303 0.3025 0.302 0 Set 3 Set 2 Set 1 5 10 Time [s] 15 0.01 0 −0.01 −0.02 0 20 5 Cart position vs Time 10 Time [s] 15 20 Cart acceleration vs Time 0.2 0 0.1 0 u [m/s2] z [m] −0.05 −0.1 0 5 10 Time [s] 15 −0.2 −0.3 Set 3 Set 2 Set 1 −0.15 −0.1 Set 3 Set 2 Set 1 −0.4 −0.5 0 20 5 10 Time [s] Figure 5: Simulation results for ICs 3 Figure 6: Comparison of simulation and experimental results for ICs 2 10 15 20 Appendix A. Details of the System Dynamics The functions below are the elements of the matrices A, B, C and D in system (1). A1 (θ, xe ) := Z xe 0 A2 (θ, xe ) := q θ[φ′ (x)]2 q dx, 1 + [θφ′ (x)]2 1 + [θφ′ (xe )]2 , A3 (θ, xe ) := q 2θ[φ′ (xe )]2 , 1 + [θφ′ (xe )]2 xe [φ′ (x)]2 3 dx.  0 1 + [θφ′ (x)]2 2  Z xe θ[φ′′ (x)]2 1 − 2[θφ′ (x)]2 B1 (θ, xe ) := EI dx,  4 0 1 + [θφ′ (x)]2 A5 (θ, xe ) := B2 (θ, xe ) := Figure 7: Inverted flexible pendulum. Z 1 EI[θφ′′ (xe )]2  2 1 + [θφ′ (x2 )]2 3 + D3 g. C1 (xe ) := 2D3 φ(xe )φ′ (xe ), C2 (xe ) := D3 φ′ (xe ). Z L D1 (xe ) := ρA0 [φ(x)]2 dx + D3 [φ(xe )]2 , References 0 [1] L. Meirovitch, Elements of vibration analysis, McGraw-Hill, 1975. [2] S. K. Dwivedy, P. Eberhard, Dynamic analysis of flexible manipulators, a literature review, Mechanism and machine theory 41 (7) (2006) 749–777. [3] O. Patil, P. Gandhi, On the dynamics and multiple equilibria of an inverted flexible pendulum with tip mass on a cart, Journal of Dynamic Systems, Measurement, and Control 136 (4) (2014) 041017. [4] D. E. Torfs, R. Vuerinckx, J. Swevers, J. Schoukens, Comparison of two feedforward design methods aiming at accurate trajectory tracking of the end point of a flexible robot arm, Control Systems Technology, IEEE Transactions on 6 (1) (1998) 2–14. [5] E. Bayo, A finite-element approach to control the end-point motion of a single-link flexible robot, Journal of Robotic systems 4 (1) (1987) 63–75. [6] R. Ortega, A. Donaire, J. Romero, Lecture Notes in Control and Information Sciences, chap. Passivity–based control of mechanical systems, Springer Berlin/Heidelberg, 2016. [7] A. Donaire, R. Mehra, R. Ortega, S. Satpute, J. Romero, F. Kazi, N. Singh, Shaping the energy of mechanical systems without solving partial differential equations, Automatic Control, IEEE Transactions on . [8] M. W. Spong, Underactuated mechanical systems, in: Control problems in robotics and automation, Springer, 135–150, 1998. [9] P. Laura, J. Pombo, E. Susemihl, A note on the vibrations of a clamped-free beam with a mass at the free end, Journal of Sound and Vibration 37 (2) (1974) 161–168. [10] R. Ortega, M. W. Spong, Adaptive motion control of rigid robots: A tutorial, Automatica 25 (6) (1989) 877–888. [11] D. J. Hill, I. M. Mareels, Stability theory for differential/algebraic systems with application to power systems, in: Robust Control of Linear Systems and Nonlinear Control, Springer, 437–445, 1990. [12] H. Khalil, Nonlinear systems, Prentice-Hall, New Jersey, 2000. [13] C. Woolsey, C. K. Reddy, A. M. Bloch, D. E. Chang, N. E. Leonard, J. E. Marsden, Controlled Lagrangian systems with gyroscopic forcing and dissipation, European Journal of Control 10 (5) (2004) 478–496. [14] F. Gómez-Estern, A. J. van der Schaft, Physical damping in IDA-PBC controlled underactuated mechanical systems, European Journal of Control 10 (5) (2004) 451–468. D2 (xe ) := D3 φ(xe ) + ρA0 Z L φ(x)dx 0 D4 := D3 + Mc + ρA0 L. Appendix B. Experimental Implementation Figure 7 shows the picture of the setup used for experimental implementation. A fatigue resistant Cu-Be alloy material is used for fabrication of the beam. Cart is guided by a rail and driven through a toothed belt driven by a motor (Maxon Motor AG: 236670). An encoder reads the position z of the motor and hence the cart. An H-bridge amplifier (Nex Robotics Hercules 36V,15A) is used to drive the motor. Strain gauges (TML Tokyo Sokki Kenkyujo Co.: FLA-5-11) in full bridge configuration along with an amplifier (DataQ Instruments 5B38-02) are used for feedback θ. The derivatives θ̇ and ż are computed numerically using a digital derivative filter. Interfacing of the motor, strain amplifier, and encoder is done with data acquisition system ds 1104 from dSPACE GmbH via PWM, DAC, and encoder interfaces. Careful horizontal levelling of the cart and rail, and meticulous adjustment of the beam and the center of gravity of the tip mass is carried out to make sure that the unstable equilibrium is perfectly vertical and other equilibria are symmetric about the unstable equilibrium position. Several nonlinear terms in the control law (20) are integral function of θ with length constraint giving ẋe as limit of integration and thus are computationally demanding to evaluate in real time. Hence a look up table arrangement is used for evaluation of these terms in real time. Appropriate signal conditioning is used to balance detrimental effects of noise on one side and filter delay on the other. 11
3cs.SY
SMILES2vec An Interpretable General-Purpose Deep Neural Network for Predicting Chemical Properties arXiv:1712.02034v2 [stat.ML] 18 Mar 2018 Garrett B. Goh Nathan Hodas PNNL [email protected] PNNL [email protected] Charles Siegel Abhinav Vishnu PNNL [email protected] PNNL [email protected] ABSTRACT 1 Chemical databases store information in text representations, and the SMILES format is a universal standard used in many cheminformatics software. Encoded in each SMILES string is structural information that can be used to predict complex chemical properties. In this work, we develop SMILES2vec, a deep RNN that automatically learns features from SMILES to predict chemical properties, without the need for additional explicit feature engineering. Using Bayesian optimization methods to tune the network architecture, we show that an optimized SMILES2vec model can serve as a general-purpose neural network for predicting distinct chemical properties including toxicity, activity, solubility and solvation energy, while also outperforming contemporary MLP neural networks that uses engineered features. Furthermore, we demonstrate proof-of-concept of interpretability by developing an explanation mask that localizes on the most important characters used in making a prediction. When tested on the solubility dataset, it identified specific parts of a chemical that is consistent with established first-principles knowledge with an accuracy of 88%. Our work demonstrates that neural networks can learn technically accurate chemical concept and provide state-of-the-art accuracy, making interpretable deep neural networks a useful tool of relevance to the chemical industry. In the chemical industry, designing chemicals with desired characteristics is a bottleneck in the development of new products. Despite decades of research, much of modern day chemical design is still driven by serendipity and chemical intuition, although improvements to rational chemical design has been incrementally improving over time. [23] Currently, there exists two key contributing factors in the current state in physics-based or rule-based computational chemistry methods that accounts for the gap towards true rational chemical design. One factor is driven by technical limitations, such as that in compute capacity, and the other is incomplete or partial understanding of the underlying chemical concepts. The first factor is being addressed with development of GPUaccelerated code for molecular modeling [36] and special-purpose chemistry supercomputers [34], but the second factor requires solutions grounded in further fundamental research, which is often a slower process. CCS CONCEPTS •Computing methodologies → Natural language processing; Neural networks; Transfer learning; •Applied computing → Chemistry; Computational biology; Bioinformatics; •Theory of computation → Bayesian analysis; KEYWORDS Natural Language Processing, Bayesian Optimization, Interpretability, Transfer Learning, Cheminformatics ACM Reference format: Garrett B. Goh, Nathan Hodas, Charles Siegel, and Abhinav Vishnu. 2018. SMILES2vec. In Proceedings of ACM SIGKDD Conference, London, UK, Aug 2018 (KDD 2018), 8 pages. DOI: 10.475/123 4 Permission to make digital or hard copies of part or all of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for third-party components of this work must be honored. For all other uses, contact the owner/author(s). KDD 2018, London, UK © 2018 Copyright held by the owner/author(s). 123-4567-24-567/08/06. . . $15.00 DOI: 10.475/123 4 1.1 INTRODUCTION Limitations of Feature Engineering and Black Box Models For the prediction of chemical properties that cannot be easily computed through physics-based or rule-based methods, modern insilico modeling in chemistry is therefore predicated on correlating engineered features with the activity or property of the chemical, which is formally known as the field of Quantitative StructureActivity or Structure-Property Relationship (QSAR/QSPR) modeling [4]. Feature engineering in chemistry is a sophisticated science that stretches back to the late 1940s [30]. Molecular descriptors, as they are termed by chemists, are basic computable properties or sophisticated descriptions of a chemical’s structure, and these engineered features were developed based on first-principles knowledge. To date, over 5000 molecular descriptors have been developed [38]. In addition, molecular fingerprints have also been designed, which instead of computing a basic property, provides a description of a specific part of the chemical’s structure [33]. Since the 1980s, various machine learning (ML) algorithms have been used to predict the activity or property of chemicals [4] using molecular desciptors and/or fingerprints as input features. More recently, deep learning (DL) models have also been developed [9, 21, 28, 31]. In general, these models either perform at parity or slightly outperform prior state-of-the-art models based on traditional ML algorithms for chemical applications [14]. KDD 2018, Aug 2018, London, UK Compared to computer vision (CV) and natural language processing research (NLP), the use of DL models in chemistry relies heavily on these engineered features. This may be problematic as it limits the neural network’s search space of potentially learnable representations. This is further exacerbated in situations in which engineered features are not appropriate or inadequate due to the lack of well-developed domain knowledge, which originates from the second factor that limits the impact of existing computational chemistry methods. In contrast, the dominant approach in CV/NLP research is to train DL models directly on typically unaltered raw data of large datasets with little or minimal feature engineering research. For example, unaltered images are used as the input in various CNN models [18] and similarly unaltered text is used in LSTM-based models [41]. Therefore, developing DL models that leverage on representation learning is a logical advance for the field of chemistry as well. Lastly, an additional challenge associated with current ML/DL models is the lack of interpretability. Typically operated as opaque black-box models, it is difficult to gain any scientific understanding as to why or how an algorithm predicts a particular chemical property. For typical applications in CV/NLP research, this may not be an issue. However, for the chemical industry, particularly for regulated products, such as requesting FDA approval for new drugs, an explanation of how the chemical works (i.e. interacts with the body is a requirement). Therefore, models that have increased interpretability or explainability is not only of industrial relevance, but it will also enable chemists to formulate new hypothesis to improve on and possibly accelerate the pace fundamental research. Goh G.B. et al. established first principles knowledge on simple chemical properties, such as solubility? Our contributions are as follows: • We perform extensive experiments to determine the optimal neural network architecture for interpreting the SMILES “chemical language”. • We developed an explanation mask to explain why or how the neural network makes a particular prediction. • We show how an optimal SMILES2vec network architecture can be generalized to predict broad range of properties that are of relevance to multiple industries, including pharmaceuticals, biotechnology, materials and consumer goods. • We demonstrate that SMILES2vec models, despite having no feature engineering, achieves better accuracy than contemporary multi-layer perceptron (MLP) models that uses engineered features. The organization for the rest of the paper is as follows. In section 2, we examine the datasets, its broad applicability to chemicalaffliated industries, as well as the Bayesian optimization process used for refining the network architecture, and the training protocols of the neural network. Then, in section 3, we document the experiments used to develop the final SMILES2vec network architecture and constructing of the interpretability masks. Lastly, in section 4, we perform additional experiments to quantify the accuracy of interpretability using the solubility dataset as an example, and evaluate SMILES2vec accuracy of chemical property predictions against contemporary DL models. 2 1.2 Related Work In chemistry, raw unaltered data would typically refer to a representation that describes the structure and orientation of a chemical. In basic chemistry education, students are taught how to draw a 2D diagram of a chemical (i.e. an image), which also serves as the primary medium of communication amongst chemist. Alternatively, the same structural information can be encoded as graphs. Indeed, convolutional neural network (CNN) models that use chemical images [16, 17, 39] and other DL models that use molecular graphs [12, 24] have been recently developed. In addition, a chemical’s structural information can also be encoded in text format, such as SMILES [40], which is also the basis for interoperability between various cheminformatics software packages. In terms of text representations, we acknowledge there has been some prior work in this direction [2, 22]. In terms of interpretable DL models, while we have seen advances in conventional CV/NLP applications [32], at the time of writing, we are not aware of any interpretable DL models in chemistry that learns directly on raw data. 1.3 Contributions Our work improves the existing state of learning directly from chemical text representations, and it is also the first interpretable neural network that works on chemical text. In the process, our work also addresses the following question: Is the SMILES representation sufficient to capture the first order distinction between different chemical properties? Assuming that the above hypothesis is true, would it then be possible to validate what a neural network learns with METHODS Here, we document the methods used in the development of SMILES2vec. First, we provide a brief introduction to SMILES. Then, we provide details on the datasets used, data splitting and preparation. Then, we examine the details of refining the neural network architecture using Bayesian methods, as well as the training protocol and evaluation metrics for the neural network. 2.1 Introduction to SMILES SMILES is a “chemical language” [40] that encodes structural information of a chemical into a compact text representation. There is a regular grammar to SMILES. For example, the alphabets denote atoms, and in some cases also what type of atoms. For example, c and C denote aromatic and aliphatic carbons respectively. Special characters like ‘=’ denote the type of bonds (connections between atoms). Rings are denoted by encapsulating numbers, and side chains by round brackets. Thus, with sufficient training a chemist can read SMILES and infer the structure of the chemical. From this structural information, more complex properties can be predicted. Inspired by language translation RNN work [41], we do not explicitly encode information about the grammar of SMILES. Instead, we expect that the RNN should learn these patterns and if necessary use them to develop intermediate features that would be relevant for predicting a variety of chemical properties. 2.2 Datasets Used Our work creates a RNN model for general chemical property prediction, and ideally it should work effectively for different types of SMILES2vec Dataset Tox21 HIV FreeSolv ESOL KDD 2018, Aug 2018, London, UK Property Task Non-Physical (Toxicity) Non-Physical (Activity) Physical (Solvation) Physical (Solubility) Multi-task classification Single-task classification Single-task regression Single-task regression Size 8014 41,193 643 1128 Table 1: Characteristics of the 4 datasets used to evaluate the performance of SMILES2vec. properties without significant network topology changes. To ensure that our results are comparable with contemporary DL models reported in the literature [42] and earlier work on Chemception CNN models [16, 17], we used the Tox21, HIV, and FreeSolv dataset from the MoleculeNet benchmark [42] for predicting toxicity, activity and solvation free energy respectively. These datasets (see Table 1) represent a good mix of dataset sizes, type of chemical properties and regression vs classification tasks. In addition, we also used the ESOL solubility dataset to evaluate the interpretability of SMILES2vec. 2.3 Relevance to Chemical Industries In terms relevance to chemical-affliated industries, toxicity prediction has importance for chemicals that require FDA approval, which includes drugs and other therapeutics (pharmaceuticals) as well as cosmetics (consumer goods). [27] Activity is a measurement of how well a chemical binds to its intended target and is one of the factors that determine how well a chemical may perform as a drug. [3] Therefore, accurate activity predictions are of relevance to both pharmaceuticals and biotechnology industries. Predicting solubility is an important consideration for developing formulations for products relevant to pharmaceuticals and consumer goods, [11] and it also affects the bioavailability of drugs. Lastly, free energy values itself are computable by physics-based simulations, and such methods are currently being employed by pharmaceuticals, consumer goods and materials industries. [7] the string. Apart from the above-mentioned steps, no additional data augmentation steps were performed. 2.5 2.6 Data Preparation The length of the SMILES string directly impacts the compute resources required to train RNN models. To maintain a balance between maximum amount of SMILES data, but also rapid training time, we surveyed the ChEMBL database, a collection of industriallyrelevant chemicals that has over 1 million entries. [13] Using this database as a proxy for relevant chemicals, we calculated that setting a maximum length of 250 characters would encompass 99.9% of existing entries. Therefore, in the above-listed datasets, we excluded entries of more than 250 characters in the dataset. Next, we created a dictionary that mapped the unique characters as one-hot encodings. Zero padding was also applied to ensure that shorter strings had a uniform size of 250 characters. In addition, extra padding of 10 zeroes were added both to the left and right of Bayesian Optimization of Neural Network Design We used a Bayesian optimizer, SigOpt [10] to optimize the hyperparameters related to the neural network topology. Each different set of network hyperparameters are defined as a separate trial, and for each trial, we trained the model to completion using a standardized supervised training protocol. After each trial, the validation metric (AUC for classification tasks, RMSE for regression tasks) was used as input to the Bayesian optimizer for suggesting new network designs. To prevent overfitting during this optimization process, the splitting of the dataset between training and validation sets was governed by a random seed. However, a fixed test set was maintained throughout, and this is also not used in the optimization process. By comparing the difference in validation and test set metrics, it would thus allow us to determine if the network design was being overfitted to the training/validation data. No hyperparameters optimization was performed for the learning protocol. Lastly, it should be noted that only a subset of the dataset was used in the Bayesian optimization. Specifically, we used only a single task (nr-ahr toxicity) from the Tox21 dataset and the Freesolv dataset. 2.7 2.4 Data Splitting We used a dataset splitting approach that is similar to that reported in previous work [16]. A separate test set was first partitioned out to serve as a test for model generalizability. For the Tox21 and HIV dataset, 1/6th was partitioned out to form the test set, and for the FreeSolv and ESOL dataset, 1/10th was used to create the test set. The remaining 5/6th or 9/10th of the dataset was then used in the random 5-fold cross validation approach for training. Model performance and early stopping criterion was determined by validation loss. Lastly, we oversampled the minority class for classification tasks (Tox21, HIV) to mitigate class imbalance. This was achieved by computing the ratio of both classes, and appending additional data from the smaller class by that ratio. The oversampling step was performed after stratification, to ensure that the same molecule is not repeated across training/validation/test sets. Training the Neural Network SMILES2vec was trained using a Tensorflow backend [1] with GPU acceleration using NVIDIA CuDL libraries. [5] The network was created and executed using the Keras 2.0 functional API interface [8]. Thee RMSprop algorithm [19] was used to train for 250 epochs using the standard settings recommended (learning rate = 10−3 , ρ = 0.9, ϵ = 10−8 ). The batch size was 32, and we also included early stopping to reduce overfitting. This was done by monitoring the loss of the validation set, and if there was no improvement in the validation loss after 25 epochs, the last best model was saved as the final model. For classification tasks, we used the binary crossentropy loss function for training. The performance metric reported in our work is area under the ROC curve (AUC). For regression tasks, we used the mean average error as the loss function for training. The KDD 2018, Aug 2018, London, UK performance metric reported is RMSE. Unless specified otherwise, the reported results in our work denote the mean value of the performance metric, obtained from the 5 runs in the 5-fold cross validation. 3 SMILES2vec Neural Network Design RNNs, particularly those based on LSTMs [20] or GRUs [6] are effective neural network designs for learning from text data. Its effectiveness has been demonstrated in examples like the Google Neural Translation Machine that uses an architecture of 8+8 layers of residual LSTM units [41]. Most of the other reported application of RNNs in NLP research are similarly used to model sequence-tosequence predictions, and often fewer (i.e. 2 to 4) layers have been found to be sufficiently accurate for their tasks. Our work differs from conventional NLP research as we are modeling sequence-to-vector predictions, where the sequence is a SMILES string, and the vector is a measured chemical property. Because of this, and also because SMILES is a fundamentally different language, commonly-used techniques in NLP research, such as embeddings like Word2vec [29] cannot be easily adapted for use in our work. Therefore, a substantial component of our work is in the design of the RNN architecture specific to SMILES. 3.2 Architectural Class Exploration We first explore the RNN model’s architecture class, which primarily includes high-level design choices, such as the type of units used, type of layers, arrangement of layers, etc. LSTMs and GRUs are the two major RNN units used in the literature, and form the basis of two architectural classes. The template design for each class starts with an embedding layer that feeds into a 2-layer bidirectional GRU or 2-layer bidirectional LSTM as illustrated in Figure 1. In addition, we explored the utility of adding a 1D convolutional layer between the embedding and GRU/LSTM layers. This design forms the template of the other two architectural classes explored. A separate Bayesian optimization was used to optimize the hyperparameters of each architectural class. Specifically, we varied the size of the embedding from 10 to 60 in intervals of 10. The number of units in the GRU/LSTM layers ranged from 8 to 384 in intervals of 8, and the number of units in the convolutional layer ranged from 4 to 192 in intervals of 4. For the convolutional layer, a size of 3 and a stride of 1 was used, which is based on the design principles from modern convolutional neural network [37]. No additional optimization was performed on the size or stride of the convolutional layers. In addition, no specific shape of the network topology was enforced. 3.3 a) Embedding (10-60) b) Embedding (10-60) GRU (8-384) LSTM (8-384) GRU (8-384) LSTM (8-384) Softmax/Linear Softmax/Linear EXPERIMENTS In this section, we first conduct several Bayesian optimization experiments to optimize SMILES2vec’s architecture and hyperparameters. Then, we conduct further experiments to develop an explanation mask for improving interpretability of the model. 3.1 Goh G.B. et al. Bayesian Optimization of Hyperparameters In order for Bayesian methods to be effective, a sufficient number of trials for different neural network design has to be performed. In practice, it has been recommended that a minimum of 10N trials c) Embedding (10-60) d) Embedding (10-60) Conv (4-192) Conv (4-192) GRU (8-384) LSTM (8-384) GRU (8-384) LSTM (8-384) Softmax/Linear Softmax/Linear Figure 1: Illustration of the 4 architectural classes investigated, (a) GRU, (b) LSTM, (c) CNN-GRU and (d) CNN-LSTM. Number of units explored is indicated in parenthesis. be performed, where N is the number of tunable hyperparameters. In our work, we performed 60 trials for each of the 4 architectural class. In addition, we manually seeded 6 initial designs for each class. Specifically, we used initial designs that had an embedding size of 40, a convolution layer with 16 filters, and both LSTM/RNN layer with [8, 16, 32, 64, 128, 256] units. In addition, because we are developing a general-purpose neural network design that can be re-used for a broad range of property prediction, it would not be feasible to include all conceivable training data to optimize the network design within the limits of available computing resources. Therefore, a subset of the datasets were used in the Bayesian optimization (see section 2.5 for details), and separate optimizations were performed for the Tox21 classification and the FreeSolv regression tasks. Figure 2: Results of Bayesian optimization of the hyperparameters of the 4 architectural classes for the (a) Tox21 classification and (b) Freesolv regression tasks. The results of the Bayesian optimization across all 4 classes and 2 tasks are as indicated in Figure 2. For Tox21 classification, we observed that an additional convolutional layer between the embedding and RNN/LSTM layers improved model performance relative to their counterparts, and the best performing model was SMILES2vec em size #conv #rnn1 #rnn2 50 192 224 384 Table 2: Best CNN-GRU network design for the final SMILES2vec model. the CNN-LSTM class, with CNN-GRU trailing slightly behind. For FreeSolv regression, we observed that GRU-based networks outperform LSTM-based networks. Taking into considerations for generalization to other type of chemical properties, we selected the CNN-GRU architectural class for the remainder of this work. Then, we selected the best network design of this class, which is summarized in Table 2. Lastly, because the Bayesian algorithm uses the validation metric as a means to optimize the network’s hyperparameters, there is a possibility that as one progresses, there may be overfitting towards the validation set. To determine the extent of overfitting, we examined the correlation between the validation metrics (whose validation set data would be changing during the Bayesian optimization) and the test metrics (whose test set data is fixed, and was never used in the Bayesian optimization). As illustrated in Figure 3, the correlation between validation and test metrics is 0.54 for the Tox21 dataset and 0.78 for the FreeSolv dataset. The lower correlation of the Tox21 dataset relative to the FreeSolv dataset may be explained by noting the AUC performance metric on which the optimization was performed, is not the same as the crossentropy loss function used for training the network. KDD 2018, Aug 2018, London, UK 3.5 Training the Explanation Mask We train a neural network generated mask to identify the important characters of the input. The procedure is as follows: First, we use the final SMILES2vec model (Table 2) as the base network. Next, we construct another neural network to produce a mask over the input data, with the objective to train the mask such that the output of the base neural network remains the same but it masks as much data as possible. We freeze the base neural network, and we train the explanation mask end-to-end, as shown in Figure 4. Figure 4: Structure for training the explanation network. The SMILES input is passed through the embedding layer, then into the explainer. This produces a mask that is placed over the original embedding and sent through the pre-trained base model. With the weights of the base network frozen, the mask being learned will be specific to the SMILES2vec model. Each input will produce a different mask. To avoid the mask being trivial (completely uniform), we added two forms of regularization, a small L2 regularization, and we also penalized the mask for having high entropy (putting equal weight on all inputs). The overall loss function for a single element of each mini-batch is as follows: Lossi =|| f (SMILESi , θ ) − Sol(SMILESi )||2 + 1e −6 ||MASKi ||2 + 0.05H (MASKi ), Figure 3: Correlation plot between validation and test metrics for all trials enumerated for the (a) Tox21 and (b) Freesolv datasets. 3.4 SMILES2vec Interpretation To gain a better insight into the SMILES2vec model, we developed a method to gain some level of interpretability. Here, our objective is to identify the part(s) of the SMILES string that is responsible for the neural network’s decision. Methods for explaining “black box” models exist [32], but most of these methods tend to require explicit combinatorial analysis. The approach we provide here provides insight into how the neural network analyzes the data, without combinatorially probing the input. This is achieved by training an explanation mask, whereby a separate explanation network learns to mask input data to produce near identical output as would be obtained from the original data. where f (SMILESi , θ ) is the base neural network applied to the ith SMILES, Sol(SMILESi ) is the solubility, H is the entropy over the mask (normalized to sum to 1), and MASKi is the vector of the calculated explanation mask at each entry in the input SMILES string. The explanation network used to create the mask was a 20 layer residual network with SELU [26] activations. The padding was fixed such that the length of the input remained the same at each layer. The input to the network is the embedding of the SMILES string. The last layer is a 1D convolution of length 1, followed by a batch normalization, then by a softplus activation. We observed that the final batch normalization layer to be very important for trainability. This provides an output between 0 and infinity at each SMILES position. A mask output of 0 would prevent the base SMILES2vec from receiving that input character. A mask of ∞ would cause the SMILES2vec to put more attention on that input character. We trained with Adam [25] until convergence. We started the learning rate at 10−2 and divided by 10 as the training error plateaued, ultimately training down to 10−6 . KDD 2018, Aug 2018, London, UK Goh G.B. et al. SMILES Solubility Top-3 Chars c1ccncc1 1.18 c,c,n O=Cc1ccco1 -0.87 C,c,o Clc1ccc(cc1Cl)c2ccccc2 -5.93 c,c,c Cc1c2ccccc2c(C)c3ccccc13 -6.91 c,c,c Table 3: Sample SMILES entries, their predicted solubility value, and the top-3 most important characters are bolded. 4 PERFORMANCE In this section, we quantity the accuracy of interpretability on the solubility dataset, Then, we demonstrate generalizability of the SMILES2vec model by evaluating its performance on other datasets. 4.1 Interpreting Chemical Solubility We demonstrate proof-of-concept for an interpretable SMILES2vec network using the ESOL solubility dataset. [42] Chemical solubility is a well-understood and simple chemical property where there is established first-principles knowledge. Briefly, parts of a chemical (i.e. functional groups) can typically be classified as either hydrophilic or hydrophobic. Hydrophilic “water-loving” groups, like alcohols, amines and carboxyl form strong interactions with water and increase the overall solubility of a compound, and they typically contain non-carbon atoms like nitrogen and oxygen. The reverse is true for hydrophobic “water-hating” groups, which tend to make chemicals more insoluble, and they typically are carbonbased chains/rings and halogens (chlorine, bromine, iodine). We used the pre-trained the SMILES2vec base model, which attained a validation RMSE of 0.63. Solubility values are reported on the log10 scale, with less soluble compounds having more negative number. The mask outputs a normalized attention value that denotes the importance of a particular character in the network’s decision. For each SMILES string, we identified the top-3 characters (see Table 3 for examples). Then, we separated the dataset into soluble (¿ -1.0) and insoluble (¡ -5.0) compounds. Using established knowledge of chemical solubility to establish the ground truth, we expect that soluble compounds should have higher attention on the atoms O, N, and insoluble compounds to have higher attention on atoms C, F, Cl, Br, I. With this ground truth labeling in expected atoms, we computed the top-3 accuracy of SMILES2vec interpretability, which is 88%. In addition, we also qualitatively examined the outputs of the masks by mapping the SMILES character to the corresponding atom(s) in the molecular structure, and examples are shown in Figure 5. For molecules with low solubility, the characters c, C, and Cl tend to receive more attention than others, which correspond to hydrophobic groups. In contrast, molecules with high solubility have attention focused on the characters O and N, which correspond to hydrophilic groups. The localization of appropriate atoms on each functional group type depending on the chemical’s predicted solubility value indicates that SMILES2vec has learned representations that correspond to known chemistry concepts. Lastly, we emphasize that SMILES2vec has developed these representations without being provided any explicit chemical information. While chemical information is implicitly encoded in the SMILES string, no “decoding Figure 5: Colored circles of increasing darkness indicate the locations of increasing attention on the molecule. The explanation mask validates established knowledge by focusing on atoms of known hydrophobic and hydrophilic functional groups. solution” was provided to the network, neither was further feature engineering required. Our work therefore demonstrates the effectiveness of representation learning from raw data in the chemical sciences. 4.2 Generalization of SMILES2vec Models Thus far, we have only evaluated the performance of SMILES2vec on the ESOL solubility dataset. Unlike solubility, the other 3 datasets (toxicity, activity, solvation energy) are more complex properties, for which no simple rule-based methods exist in the chemistry literature. Without the ability to generate ground-truth labels, quantifying the accuracy of the SMILES2vec interpretation is nontrivial, and is beyond the scope of this work. Nevertheless, the accuracy of the model’s predictions can still be evaluated. We also note that the architectural optimization of SMILES2vec only included a small fraction of the 4 datasets identified for this work; the HIV dataset was not included, and 11 out of 12 toxicity tasks were not included. Hence, this section also determines how generalizable the Bayesian optimized network design will be to other chemical tasks. First, we determined the effectiveness of generalizing SMILES2vec to the 3 remaining datasets. The following validation performance metrics were obtained: AUC of 0.80 for the full Tox21 dataset, AUC of 0.78 for the HIV dataset, and RMSE 1.4 kcal/mol for the FreeSolv dataset. Furthermore, we note that in all models, the difference between the validation and test metrics is small, further confirming the generalization of the model to compounds it has not seen either during the model training, or in the Bayesian hyperparameter optimization. Using a recently developed pre-training approach, [15] we were also able to improve the performance of SMILES2vec slightly, attaining AUC of 0.81 for the full Tox21 dataset, AUC of 0.80 for the HIV dataset, and RMSE 1.2 kcal/mol for the FreeSolv dataset. Based on these results, we conclude that the Bayesian optimization of the network architectural design was effective in developing a general-purpose SMILES2vec network design for other chemical properties. We also note in recent literature there has been a trend towards using other ”black box” approaches as a solution for network architecture design, for example using RNNs and reinforcement learning to optimize the design of a target neural network. [43] However, such methods typically require on the order of ˜10,000 trials, which is much more than the ˜500 trials used in our work. SMILES2vec In addition, given that the template of each architectural class was fixed, adaptive methods that automtically grow or shrink the neural network are also viable alternatives to network design. [35] Next, we compare the performance of the best SMILES2vec model against contemporary deep neural networks that have reported results on the same datasets (Tox21, HIV, FreeSolv) that we have evaluated our model on. We compare against a typical MLP network that uses engineered features [42], a chemistry-specific molecular graph convolutional neural network [42], and Chemception, a deep CNN that uses images [17]. KDD 2018, Aug 2018, London, UK network architecture is effective in predicting a wide range of properties. SMILES2vec achieved a validation AUC of 0.81 and 0.80 for Tox21 toxicity and HIV activity prediction respectively, and a validation RMSE of 1.2 kcal/mol and 0.63 for solvation energy and solubility. Using the solubility dataset as an illustration of SMILES2vec interpretability, we construct explanation masks that indicate SMILES2vec localizes on specific characters in hydrophilic or hydrophobic groups, with a top-3 accuracy of 88%. Identification of such functional groups and their relationship to chemical solubility is a key first-principles concept in chemistry, which SMILES2vec was able to discover on its own. Compared to other DL models, SMILES2vec’s accuracy outperforms the typical MLP DL models that uses engineered features as input. Against the current state-ofthe-art (convolutional graph networks), SMILES2vec outperforms on regression tasks and matches on classification tasks. These results indicate that SMILES2vec can accurately predict a broad range of properties and learn technically accurate chemical concepts, which suggest that it can be used as an interpretable tool for the future of deep learning driven chemical design. ACKNOWLEDGMENTS Figure 6: Performance of SMILES2vec against contemporary deep neural networks trained on engineered features, image and graph data. For Tox21 and HIV, higher AUC is better. For FreeSolv, lower RMSE is better. The results are presented in Figure 6, and we use validation metrics to evaluate the quality of the model. In comparing the 4 methods, we observed that the standard MLP DL models that uses engineered features (fingerprints) performed the worst. SMILES2vec outperformed CNN models such as Chemception in classification tasks, but slightly underperformed in regression tasks. As indicated in our previous work, it is likely that the lack of atomic number information, which is not embedded in the SMILES format is responsible for its lower performance in predicting calculable physical properties. [17] In addition, SMILES2vec also outperformed first-principles models for computing solvation free energy (note: there are no first-principles models for computing toxicity/activity), which is especially noteworthy since SMILES2vec (and neural networks in general) can predict values much faster than traditional computational chemistry simulations, which typically require minutes to hours for each calculation. Against convolutional graphs, which is the current state-of-the-art for many chemical tasks, SMILES2vec either matches for classification tasks (Tox21: 0.81 vs 0.81, HIV: 0.80 vs 0.80) or outperforms for regression task (FreeSolv: 1.2 vs 1.3). Therefore, SMILES2vec is not only as accurate as the current state-of-the-art in chemistry DL models, but more importantly it is also an interpretable model. 5 CONCLUSION In this paper, we develop SMILES2vec, the first general-purpose deep neural network that uses chemical text data (SMILES) for predicting chemical property, with an explanation mask that improves interpretability. By performing extensive Bayesian optimization experiments, we identified a specific CNN-GRU neural The authors would like to thank Dr. Nathan Baker for helpful discussions. This work is supported by the following PNNL LDRD programs: Pauling Postdoctoral Fellowship and Deep Learning for Scientific Discovery Agile Investment. REFERENCES [1] Martı́n Abadi, Paul Barham, Jianmin Chen, Zhifeng Chen, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Geoffrey Irving, Michael Isard, et al. 2016. TensorFlow: A System for Large-Scale Machine Learning.. In OSDI, Vol. 16. 265–283. [2] Esben Jannik Bjerrum. 2017. SMILES Enumeration as Data Augmentation for Neural Network Modeling of Molecules. arXiv preprint arXiv:1703.07076 (2017). [3] Peter Buchwald and Nicholas Bodor. 2002. Computer-aided drug design: the role of quantitative structure–property, structure–activity and structure–metabolism relationships (QSPR, QSAR, QSMR). Drugs Future 27, 6 (2002), 577–588. [4] Artem Cherkasov, Eugene N Muratov, Denis Fourches, Alexandre Varnek, Igor I Baskin, Mark Cronin, John Dearden, Paola Gramatica, Yvonne C Martin, Roberto Todeschini, et al. 2014. QSAR modeling: where have you been? Where are you going to? Journal of medicinal chemistry 57, 12 (2014), 4977–5010. [5] Sharan Chetlur, Cliff Woolley, Philippe Vandermersch, Jonathan Cohen, John Tran, Bryan Catanzaro, and Evan Shelhamer. 2014. cudnn: Efficient primitives for deep learning. arXiv preprint arXiv:1410.0759 (2014). [6] Kyunghyun Cho, Bart Van Merriënboer, Dzmitry Bahdanau, and Yoshua Bengio. 2014. On the properties of neural machine translation: Encoder-decoder approaches. arXiv preprint arXiv:1409.1259 (2014). [7] John D Chodera, David L Mobley, Michael R Shirts, Richard W Dixon, Kim Branson, and Vijay S Pande. 2011. Alchemical free energy methods for drug discovery: progress and challenges. Current opinion in structural biology 21, 2 (2011), 150–160. [8] François Chollet et al. 2015. Keras. (2015). [9] George E Dahl, Navdeep Jaitly, and Ruslan Salakhutdinov. 2014. Multi-task neural networks for QSAR predictions. arXiv preprint arXiv:1406.1231 (2014). [10] Ian Dewancker, Michael McCourt, Scott Clark, Patrick Hayes, Alexandra Johnson, and George Ke. 2016. Evaluation System for a Bayesian Optimization Service. arXiv preprint arXiv:1605.06170 (2016). [11] Li Di, Paul V Fish, and Takashi Mano. 2012. Bridging solubility between drug discovery and development. Drug Discovery Today 17, 9-10 (2012), 486–495. [12] David K Duvenaud, Dougal Maclaurin, Jorge Iparraguirre, Rafael Bombarell, Timothy Hirzel, Alán Aspuru-Guzik, and Ryan P Adams. 2015. Convolutional networks on graphs for learning molecular fingerprints. In Advances in neural information processing systems. 2224–2232. [13] Anna Gaulton, Louisa J Bellis, A Patricia Bento, Jon Chambers, Mark Davies, Anne Hersey, Yvonne Light, Shaun McGlinchey, David Michalovich, Bissan Al-Lazikani, et al. 2011. ChEMBL: a large-scale bioactivity database for drug discovery. Nucleic acids research 40, D1 (2011), D1100–D1107. KDD 2018, Aug 2018, London, UK [14] Garrett B Goh, Nathan O Hodas, and Abhinav Vishnu. 2017. Deep learning for computational chemistry. Journal of Computational Chemistry (2017). [15] Garrett B Goh, Charles Siegel, Abhinav Vishnu, and Nathan O Hodas. 2017. ChemNet: A Transferable and Generalizable Deep Neural Network for SmallMolecule Property Prediction. arXiv preprint arXiv:1712.02734 (2017). [16] Garrett B Goh, Charles Siegel, Abhinav Vishnu, Nathan O Hodas, and Nathan Baker. 2017. Chemception: A Deep Neural Network with Minimal Chemistry Knowledge Matches the Performance of Expert-developed QSAR/QSPR Models. arXiv preprint arXiv:1706.06689 (2017). [17] Garrett B Goh, Charles Siegel, Abhinav Vishnu, Nathan O Hodas, and Nathan Baker. 2017. How Much Chemistry Does a Deep Neural Network Need to Know to Make Accurate Predictions? arXiv preprint arXiv:1710.02238 (2017). [18] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. 2015. Delving deep into rectifiers: Surpassing human-level performance on imagenet classification. In Proceedings of the IEEE international conference on computer vision. 1026–1034. [19] G Hinton, N Srivastava, and K Swersky. 2012. RMSProp: Divide the gradient by a running average of its recent magnitude. Neural networks for machine learning, Coursera lecture 6e (2012). [20] Sepp Hochreiter and Jürgen Schmidhuber. 1997. Long short-term memory. Neural computation 9, 8 (1997), 1735–1780. [21] Tyler B Hughes, Na Le Dang, Grover P Miller, and S Joshua Swamidass. 2016. Modeling Reactivity to Biological Macromolecules with a Deep Multitask Network. ACS central science 2, 8 (2016), 529–537. [22] Stanisaw Jastrzebski, Damian Lesniak, and Wojciech Marian Czarnecki. 2016. Learning to SMILE (S). arXiv preprint arXiv:1602.06289 (2016). [23] William L Jorgensen. 2004. The many roles of computation in drug discovery. Science 303, 5665 (2004), 1813–1818. [24] Steven Kearnes, Kevin McCloskey, Marc Berndl, Vijay Pande, and Patrick Riley. 2016. Molecular graph convolutions: moving beyond fingerprints. Journal of computer-aided molecular design 30, 8 (2016), 595–608. [25] Diederik P Kingma and Jimmy Ba. 2014. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980 (2014). [26] Günter Klambauer, Thomas Unterthiner, Andreas Mayr, and Sepp Hochreiter. 2017. Self-normalizing neural networks. In Advances in Neural Information Processing Systems. 972–981. [27] Naomi L Kruhlak, Joseph F Contrera, R Daniel Benz, and Edwin J Matthews. 2007. Progress in QSAR toxicity screening of pharmaceutical impurities and other FDA regulated products. Advanced drug delivery reviews 59, 1 (2007), 43–55. [28] Andreas Mayr, Günter Klambauer, Thomas Unterthiner, and Sepp Hochreiter. 2016. DeepTox: toxicity prediction using deep learning. Frontiers in Environmental Science 3 (2016), 80. [29] Tomas Mikolov, Kai Chen, Greg Corrado, and Jeffrey Dean. 2013. Efficient estimation of word representations in vector space. arXiv preprint arXiv:1301.3781 (2013). [30] John R Platt. 1947. Influence of neighbor bonds on additive bond properties in paraffins. The Journal of Chemical Physics 15, 6 (1947), 419–420. [31] Bharath Ramsundar, Steven Kearnes, Patrick Riley, Dale Webster, David Konerding, and Vijay Pande. 2015. Massively multitask networks for drug discovery. arXiv preprint arXiv:1502.02072 (2015). [32] Marco Tulio Ribeiro, Sameer Singh, and Carlos Guestrin. 2016. Why should i trust you?: Explaining the predictions of any classifier. In Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining. ACM, 1135–1144. [33] David Rogers and Mathew Hahn. 2010. Extended-connectivity fingerprints. Journal of chemical information and modeling 50, 5 (2010), 742–754. [34] David E Shaw, JP Grossman, Joseph A Bank, Brannon Batson, J Adam Butts, Jack C Chao, Martin M Deneroff, Ron O Dror, Amos Even, Christopher H Fenton, et al. 2014. Anton 2: raising the bar for performance and programmability in a special-purpose molecular dynamics supercomputer. In Proceedings of the international conference for high performance computing, networking, storage and analysis. IEEE Press, 41–53. [35] Charles Siegel, Jeff Daily, and Abhinav Vishnu. 2016. Adaptive neuron apoptosis for accelerating deep learning on large scale systems. In Big Data (Big Data), 2016 IEEE International Conference on. IEEE, 753–762. [36] John E Stone, David J Hardy, Ivan S Ufimtsev, and Klaus Schulten. 2010. GPUaccelerated molecular modeling coming of age. Journal of Molecular Graphics and Modelling 29, 2 (2010), 116–125. [37] Christian Szegedy, Wei Liu, Yangqing Jia, Pierre Sermanet, Scott Reed, Dragomir Anguelov, Dumitru Erhan, Vincent Vanhoucke, and Andrew Rabinovich. 2015. Going deeper with convolutions. In Proceedings of the IEEE conference on computer vision and pattern recognition. 1–9. [38] Roberto Todeschini and Viviana Consonni. 2008. Handbook of molecular descriptors. Vol. 11. John Wiley & Sons. [39] Izhar Wallach, Michael Dzamba, and Abraham Heifets. 2015. AtomNet: a deep convolutional neural network for bioactivity prediction in structure-based drug discovery. arXiv preprint arXiv:1510.02855 (2015). [40] David Weininger. 1988. SMILES, a chemical language and information system. 1. Introduction to methodology and encoding rules. Journal of chemical information Goh G.B. et al. and computer sciences 28, 1 (1988), 31–36. [41] Yonghui Wu, Mike Schuster, Zhifeng Chen, Quoc V Le, Mohammad Norouzi, Wolfgang Macherey, Maxim Krikun, Yuan Cao, Qin Gao, Klaus Macherey, et al. 2016. Google’s neural machine translation system: Bridging the gap between human and machine translation. arXiv preprint arXiv:1609.08144 (2016). [42] Zhenqin Wu, Bharath Ramsundar, Evan N Feinberg, Joseph Gomes, Caleb Geniesse, Aneesh S Pappu, Karl Leswing, and Vijay Pande. 2017. MoleculeNet: A Benchmark for Molecular Machine Learning. arXiv preprint arXiv:1703.00564 (2017). [43] Barret Zoph and Quoc V Le. 2016. Neural architecture search with reinforcement learning. arXiv preprint arXiv:1611.01578 (2016).
2cs.AI
SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE arXiv:1711.04463v1 [math.AG] 13 Nov 2017 MICHAEL KEMENY Abstract. We survey three results on syzygies of curves beyond Green’s conjecture, with a particular emphasis on drawing connections between the study of syzygies and other topics in moduli theory. 1. Introduction Arguably the central concept of modern commutative algebra is that of a minimal free resolution. Let S be either a local Noetherian ring or a positively graded, finitely generated algebra over a field. The task is then to describe the shape of the minimal free resolutions of various classes of S modules. In this survey, we restrict attention to the graded ring R = C[x0 , . . . , xm ], with grading Rd = {polynomials of degree d}. There is one particular class of graded R-modules which are the most interesting to algebraic geometers, namely those of the form M H 0 (X, L⊗n ), ΓX (L) := n≥0 where X is a projective variety, L is a very ample line bundle with m sections, and where ΓX (L) is a R ≃ Sym(H 0 (X, L)) module in the natural way. By the Hilbert Syzygy Theorem, any finitely generated, graded R module M has a minimal free resolution 0 ← M ← F0 ← F1 ← . . . ← Fk ← 0 of length at most k ≤ m. Decomposing each term M R(−i − j)bi,j (M ) Fi = j into its graded pieces, this resolution defines invariants bi,j (M ) of the module, called the Betti numbers of M . Question. In the case M = ΓX (L), what geometric information about X can be gleaned from the Betti numbers bi,j (X, L) := bi,j (ΓX (L))? The case which has received the most attention is when the variety is a projective curve C of genus g and L = ωC . For a projective curve, the geometric information one is most interested in is perhaps the gonality gon(C), which is the least degree d such that there exists a degree d cover C → P1 (we call such a cover a minimal pencil). In practice, on sometimes needs to replace gonality with a slightly refined invariant, called the Clifford index and defined as Cliff(C) := min {deg M − 2h0 (M ) + 2 | M ∈ Pic(C), deg(M ) ≤ g − 1, h0 (M ) ≥ 2}. There is always the bound Cliff(C) ≤ gon(C) − 2, which, at least conjecturally, is an equality for most curves, [20]. Here one has the celebrated: Conjecture (Green’s Conjecture, [34]). We have the following vanishing of quadratic Betti numbers: bp,2 (C, ωC ) = 0 for p < Cliff(C). 1 2 MICHAEL KEMENY Here Cliff(C) denotes the Clifford index of the curve C. This conjecture provides a sweeping generalisation of the following classical results of Noether and Petri: Theorem (Noether, Petri). Assume C is not hyperelliptic. Then the canonical embedding C ֒→ Pg−1 is projectively normal. If, further, C does not admit a degree three cover of P1 , then IC/Pg−1 is generated by quadrics. The first serious approach to Green’s conjecture, due to Schreyer [40], relies on the observation that if a curve admits a minimal pencil f : C → P1 of degree d, then the canonical curve C lies on the rational normal scroll X ⊆ Pg−1 which can be geometrically described as the union of the span of the divisors f −1 (p) in Pg−1 as p ∈ P1 varies. The minimal free resolution of the scroll X can be described by an Eagon–Northcott resolution: Theorem (Eagon–Northcott [17]). Let R be a ring and f : Rr → Rs be a ring homomorphism for r ≥ s. There is a complex ∧s f ∗ ⊗ ∧r R r ← 0 0 ← R ←−− ∧s Rr ← S1∗ ⊗ ∧s+1 Rr ← . . . ← Sr−s where S = R[x1 , . . . , xs ], which is exact if and only if depth (Is (f )) = r − s + 1. In the theorem above, Ij (f ) denotes the ideal generated by j × j minors of f , for any 1 ≤ j ≤ s. By restriction to the canonical curve, the Eagon–Northcott resolution injects into the linear strand of the minimal resolution of the curve. This translates Green’s Conjecture into the prediction that the length of the Eagon–Northcott resolution equals the length of the linear strand of the canonical curve. Eagon–Northcott resolutions form an important class of resolutions in their own right, and the work of Buchsbaum and Eisenbud on understanding and generalising these resolutions led to several results which have been seminal to the development of modern commutative algebra. For example, the famous Criterion for Exactness came out of this: Theorem (Buchsbaum-Eisenbud [9]). Let R be a ring and let f1 f2 fn F• : F0 ←− F1 ←− F2 ← . . . ←− Fn ← 0 be a complex of free R modules. Assume (1) rank Fi = rank fi + rank fi+1 (2) if I(fi ) 6= R then depth I(fi ) ≥ i Then F• is exact. Here I(fi ) is defined to be Irkfi (fi ). Using this criterion, Buchsbaum and Eisenbud construct resolutions generalising the Eagon–Northcott resolution in [10]. Perhaps surprisingly, some of the most effective tools for approaching Green’s Conjecture have come from geometry rather than algebra. It was observed early on by Green and Lazarsfeld that there is an intimate connection between Green’s Conjecture and the theory of K3 surfaces and moduli spaces of sheaves on such surfaces. This connection has proven to be surprisingly deep and has significantly influenced the subsequent development of K3 surface theory. As just one example, the following fundamental theorem came about as a verification of a prediction from Green’s Conjecture: Theorem (Green–Lazarsfeld [36]). Let X be a K3 surface and L ∈ Pic(X) a base point free line bundle. Then Cliff(C) is constant amongst all smooth curves C ∈ |L|. In another direction, the study of syzygies of curves has proven to be remarkably important for the study of the birational geometry of the moduli space of curves, see [32], [22]. In a landmark pair of papers, Green’s Conjecture was eventually proven for a generic curve of arbitrary genus by C. Voisin, [42], [43]. Voisin’s proof relied on a new interpretation of the problem in terms of the Hilbert scheme of points on a K3 surface: SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 3 Theorem (Voisin). Let X be a complex projective variety and L a line bundle. Then bp,1 (X, L) equals the corank of the natural map [p+1] H 0 (Xcurv , det L[p+1] ) → H 0 (Ip+1 , (q ∗ det L[p+1] )|Ip+1 ) [p+1] where Xcurv is the curvilinear locus in the Hilbert scheme of points, L[p+1] is the tautological [p+1] [p+1] bundle, Ip+1 ⊆ Xcurv × X is the incidence variety and q : Ip+1 → Xcurv is the projection. In this survey, we outline some new avenues of research going out in various directions from Green’s Conjecture, with a focus on demonstrating the connections between the study of syzygies and other aspects of moduli theory. The first of these directions is the Secant Conjecture of Green and Lazarsfeld, [35]. This conjecture gives a condition for the vanishing of quadratic syzygies of a curve embedded by a nonspecial line bundle L. The Secant Conjecture generalises the following well-known theorem of Castelnuovo–Mumford in much the same way as Green’s conjecture generalises the Theorem of Noether–Petri: Theorem 1.1 (Castelnuovo–Mumford). Let L be a very ample line bundle on a curve with deg(L) ≥ 2g + 1 then φL : C ֒→ Pr is projectively normal. Green and Lazarsfeld proved that one can replace the bound in Castelnuovo–Mumford’s theorem with deg(L) ≥ 2g + 1 − Cliff(C). The Secant Conjecture then extends the above results to higher syzygies. The second direction we discuss is the Prym–Green Conjecture. For a general canonical curve C ֒→ Pg−1 the generic Green’s Conjecture as proved by Voisin suffices to describe the shape of the free resolution of the homogeneous coordinate ring of C. The Prym–Green conjecture likewise predicts a similar shape for the homogeneous coordinate ring of a general paracanonical curve, that is a curve embedded by a twist of the canonical line bundle by a torsion line bundle. Lastly, we come back to Schreyer’s original approach and consider the question of whether all the syzygies in the last position of the linear strand of a canonical curve come from the syzygies of the scrolls associated to the minimal pencils of the curve. Our approach to this question is a blend of Schreyer’s original approach using the Eagon–Northcott complex with the approach of Hirschowitz–Ramanan, [38], which suggests that one should construct and study appropriate divisors on moduli spaces. In our case the moduli spaces are spaces of stable maps to Pm , which have some peculiarities in comparison with the moduli space of curves, and several natural questions are left open. Acknowledgments: It is a pleasure to thank the organisers of the Abel Symposium 2017 for a wonderful conference in a spectacular location. The results in this survey are joint work with my coauthor Gavril Farkas, who has taught me much of what I know about syzygies. I also thank D. Eisenbud and F.-O. Schreyer for enlightening conversations on these topics. This survery is an amalgamation of material taken from my course on syzygies in Spring 2017 as well as talks given at UCLA and Berkeley in Autumn 2017. In particular, I thank Aaron Landesman for several corrections and improvements to my course notes. 2. The Eagon–Northcott Complex It is quite rare for one to able to construct an explicit free resolution of a module, so those few families of resolutions which we have are much prized. Perhaps the most well known and useful resolutions is given by the Koszul complex. Let R be a ring and {f1 , . . . , fr } a sequence of elements in R. Let f¯ : Rr → R be the map sending the ith basis element ei of Rr to fi for 1 ≤ i ≤ r. The Koszul complex associated to f¯ is the complex ¯ f d d − . . . ← ∧r R r ← 0 − ∧2 R r ← − Rr ← K• (f¯) : R ← 4 MICHAEL KEMENY where the differential is defined by p X (−1)j+1 fij ei1 ∧ . . . ∧ êij ∧ . . . ∧ eip . d(ei1 ∧ . . . ∧ eip ) = j=1 The Eagon–Northcott complex was the very influential discovery that one could generalise the construction of the Koszul complex and associate a complex to any ring homomorphism ḡ : Rr → Rs with r ≥ s. To describe how this works, we follow [18] to construct the complex as a strand of a graded Koszul complex. Consider the graded polynomial ring S := R[x1 , . . . , xs ]. We may identify S1 with Rs via the standard basis. Setting F := S(−1)⊕r ≃ (Rr ⊗R S)(−1), then ḡ defines a morphism g̃ : F → S of graded S modules. Explicitly, if e1 , . . . , er is a basis of Rr , then ge(ei ⊗ 1) = ḡ(ei ) ∈ Rs ≃ S1 . Taking the Koszul complex of ge, we get K• (e g ) : S ← F ← ∧2 F ← . . . ← ∧r F ← 0. This is a graded complex and taking the kth graded piece of this complex yields δ δ K• (e g )k : Sk ← − Sk−1 ⊗R Rr ← − Sk−2 ⊗ ∧2 Rr ← . . . ← Sk−r ⊗ ∧r Rr ← 0. d ∗ ← − Dualizing this and using the identification ∧i Rr ≃ ∧r−i (Rr )∗ we get a complex K•∗ (e g )k : Sk−r ∗ r ∗ r r ∗ ∗ Sk−r+1 ⊗ R ← . . . ← Sk ⊗ ∧ R ← 0. Now set k = r − s. The first s terms S−s , . . . , S−1 are all zero, so we get a complex d ∗ − S1∗ ⊗ ∧s+1 Rr ← . . . ← Sr−s ⊗ ∧r Rr ← 0. ∧s R r ← The Eagon–Northcott complex ∧s ḡ d ∗ − S1∗ ⊗ ∧s+1 Rr ← . . . ← Sr−s ⊗ ∧r Rr ← 0, EN (ḡ) : R ←−− ∧s Rr ← is then obtained by extending the above complex by ḡ (it remains a complex). Let Ij (ḡ) denote the ideal generated by the j × j minors of ḡ. Theorem ([17]). The complex EN (ḡ) is exact if and only if depth Is (ḡ) = r − s + 1. For example, in the special case s = 1, this gives us the well-known statement that K• (f¯) is exact if and only if {f1 , . . . , fr } forms a regular sequence. Let us now restrict attention to the graded polynomial ring R = C[x0 , . . . , xm ] and set V = R1 , which is an m+1 dimensional complex vector space. Then {x0 , . . . , xm } forms a regular sequence, and and taking the Koszul complex produces the resolution 0 ← C ← R ← V ⊗C R ← ∧2 V ⊗ R ← . . . ← ∧m+1 V ⊗ R ← 0, of C ≃ R/(x0 , . . . , xm ). Let M be a graded R module, and consider the minimal free resolution 0 ← M ← F0 ← F1 ← . . . ← Fk ← 0. The Betti numbers of bi,j (M ) are defined to be the (i + j)th graded piece of ToriR bi,j (M ) := dim ToriR (M, C)i+j . L bi,j (M ) . By tensoring the In terms of the minimal free resolution above, Fi = j R(−i − j) Koszul resolution of C by M and using symmetry of Tor, one immediately obtains a more concrete description of the syzygy spaces ToriR (M, C)i+j : SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 5 Proposition 2.1. The (i, j)th syzygy space ToriR (M, C)i+j is the middle cohomology of i+1 ^ V ⊗ Mj−1 → i ^ V ⊗ Mj → i−1 ^ V ⊗ Mj+1 , where the maps are the Koszul differentials and V = R1 . 3. Rational Normal Scrolls and Schreyer’s Approach In this section we discuss Schreyer’s approach to Green’s conjecture using rational normal scrolls. Let C be a smooth, projective curve of genus g, and let R := Sym H 0 (C, ωC ) ≃ C[x0 , . . . , xg−1 ]. We are interested in the Betti numbers of the graded R module M ΓC (ωC ) := H 0 (C, ω ⊗n ). n≥0 We define bi,j (C, ωC ) := bi,j (ΓC (ωC )). Suppose C has gonality d and let f : C → P1 be a minimal pencil, i.e. suppose φ has the minimal degree d. It was observed by Schreyer [40] and Green–Lazarsfeld [34, Appendix], that the minimal pencil imposes conditions on the possible values of the Betti numbers bp,1 (C, ωC ). In this section, we describe Schreyer’s approach. Suppose C is not hyperelliptic, so that |ωC | embeds the curve C in Pg−1 . If f : C → P1 is a minimal pencil, then for a general p ∈ P1 , the divisor f −1 (p) is a finite set of d points in Pg−1 . By geometric Riemann–Roch, the dimension of the span < f −1 (p) > is given by dim < f −1 (p) >= d − h0 (C, f ∗ OP1 (1)) = d − 2. Now consider the union Xf := [ < f −1 (p) > . p∈P1 Then Xf ⊆ Pg−1 is smooth, d − 1 dimensional projective variety known as a rational normal scroll which furthermore contains the curve C ⊆ Pg−1 . Rational normal scrolls have the minimal possible degree deg(X) = 1 + codimX, and as such they have been widely studied since Bertini classified varieties of minimal degree in 1907, [8]. Following [19], one may give a determinantal description of the variety Xf . Let u, v be a basis of H 0 (C, f ∗ OPg−1 (1)) and y1 , . . . , ys a basis of H 0 (C, ωC ⊗ f ∗ OPg−1 (−1)), where s = g + 1 − d. Consider the 2 × (g + 1 − d) matrix   uy1 . . . uys := A. vy1 . . . vys The canonical embedding gives an identification H 0 (C, ωC ) ≃ H 0 (Pg−1 , O(1)) and we may therefore consider A as a matrix of linear forms, that, is as a morphism A Rs (−1) − → R⊕2 . Then Xf is defined be the locus of 2 × 2 minors of A, or, equivalently, is the locus where A does not have full rank. The homogeneous coordinate ring OXf of Xf is then the cokernel of 2 2 ^ ^ ∧2 A R2 ≃ R. ( Rs )(−2) −−→ 6 MICHAEL KEMENY Since Xf has codimension g − d in Pg−1 , depth I2 (A) = g − d, so the Eagon–Northcott complex gives a free resolution ∧2 A 0 ← OXf ← R ←−− 2 ^ Rs (−2) ← (R2 )∗ ⊗ ∧3 Rs (−3) ← Sym2 (R2 )∗ ⊗ ∧4 Rs (−4) ← . . . ← Symd−2 (R2 )∗ ⊗ ∧s Rs (−s) ← 0. As all differentials in the above resolution are matrices with linear entries, the graded Nakayama lemma immediately implies that this Eagon–Northcott complex is minimal. In particular, the scroll Xf has Betti numbers   g+1−d bp,1 (Xf , O(1)) = p , p+1 with bp,q (Xf , O(1)) = 0 for q ≥ 2. The restriction OXf ։ ΓC (ωC ) induces injective maps Torp (OXf , C)p+1 ֒→ Torp (ΓC (ωC ), C)p+1 and hence we derive the bounds   g+1−d bp,1 (C, ωC ) ≥ p . p+1 In particular, bg−d,1 (C, ωC ) ≥ g − d. Schreyer’s Conjecture states that, under appropriate conditions, this is an equality. Conjecture (Schreyer). Suppose C is a curve of gonality 3 ≤ d ≤ g+1 2 . Assume C has a unique minimal pencil f : C → P1 and that further the Brill–Noether locus Wd1 (C) = {f ∗ O(1)} is reduced. Assume furthermore that f ∗ O(1) is the unique line bundle achieving the Clifford index. Then bg−d,1 (C, ωC ) = g − d. The condition d ≤ g+1 2 is precisely that C have non-maximal gonality. Any curve satisfying the assumptions and conclusion of Schreyer’s Conjecture must also satisfy Green’s Conjecture. Indeed, under the assumptions Cliff(C) = d − 2 and Green’s Conjecture is the statement bd−3,2 (C, ωC ) = 0. Using Serre duality, this is equivalent to bg−d+1,1 C, ωC ) = 0. But if bg−d,1 (C, ωC ) = g−d, then Torg−d (OXf , C)g−d+1 → Torg−d (ΓC (ωC ), C)g−d+1 is surjective. But then any linear relation amongst the syzygies in Torg−d (ΓC (ωC ), C)g−d+1 would also be a relation amongst syzygies in Torg−d (OXf , C)g−d+1 . As there are no such relations, we must have bg−d+1,1 C, ωC ) = 0. In [41], Schreyer verified his conjecture for general curves of gonality d with g ≫ d. This has since been verified for general curves of gonality 3 ≤ d ≤ g+1 2 in [25]. 4. Lattice Polarised K3 Surfaces and the Secant Conjecture Consider a projective K3 surface X ⊆ Pg . If H ⊆ Pg is a hyperplane then the adjunction formula implies C := X ∩ H ⊆ Pg−1 ≃ H is a canonical curve. This simple observation has deep applications to the study of syzygies of canonical curves. To explain this should be the case, we first introduce some new notation. Let SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 7 Y be any smooth projective variety and L, M line bundles on Y with L base point free and ample. Set R := Sym H 0 (Y, L) and consider the graded R module M ΓY (M, L) := H 0 (Y, L⊗n ⊗ M ). n∈Z We define bi,j (Y, M, L) := bi,j (ΓY (M, L)). Proposition 4.1 (Hyperplane Restriction Theorem, [34], [26]). Let X be a K3 surface and let L, H be line bundles with H effective and base point free. Assume either (i) L ≃ OX or (ii) (H · L) > 0 and H 1 (X, qH − L) = 0 for q ≥ 0. Then for each smooth curve D ∈ |H| bp,q (X, −L, H) = bp,q (D, −LD , ωD ) for all p, q. Proof. Let R = Sym H 0 (X, H). Let s ∈ H 0 (X, H) define D. By our assumptions, we have a short exact sequence ⊗s 0 → ΓX (−L, H)(−1) −− → ΓX (L, H) → ΓD (LD , ωD ) → 0 of R modules. Taking the (p + q)th graded piece of the long exact sequence of TorR ( , C) ⊗s → TorpR (ΓX (−L, H), C)p+q−1 −−→ TorpR (ΓX (−L, H), C)p+q → TorpR (ΓD (−LD , ωD ), C)p+q → Torp−1 R (ΓX (−L, H), C)p+q−1 → ⊗s The map TorpR (ΓX (−L, H), C)p+q−1 −−→ TorpR (ΓX (−L, H), C)p+q is zero, [34, §1.6.11]. Thus TorpR (ΓD (−LD , ωD ), C)p+q ≃ TorpR (ΓX (−L, H), C)p+q ⊕ Torp−1 R (ΓX (−L, H), C)p+q−1 . Let R′ := Sym H 0 (D, ωD ). Using the exact sequence 0 → C → H 0 (X, H) → H 0 (D, ωD ) → 0 one sees TorpR (ΓD (−LD , ωD ), C)p+q ≃ TorpR′ (ΓD (−LD , ωD ), C)p+q ⊕ Torp−1 R′ (ΓD (−LD , ωD ), C)p+q−1 . Thus bp,q (X, −L, H) + bp−1,q (X, −L, H) = bp,q (D, −LD , ωD ) + bp−1,q (D, −LD , ωD ). The claim now follows by induction on p, since b−1,q (X, −L, H) = b−1,q (D, −LD , ωD ) = 0.  The Hyperplane Restriction Theorem is very powerful due to the combination of the following two facts: (1) Thanks to Voisin’s groundbreaking work as well as the work of Aprodu–Farkas, Green’s Conjecture is now known for any curve on a K3 surface, [42], [43], [2]. (2) By the Global Torelli Theorem for K3 surfaces, given any even lattice Λ of signature (1, ρ− 1) with ρ ≤ 10, there is a nonempty moduli space of K3 surfaces X with Pic(X) ≃ Λ, [16]. Item (2) gives a very powerful method for constructing examples of curves with prescribed properties. We will illustrate how this works with an application to the Secant Conjecture of Green–Lazarsfeld. A line bundle L on a curve is said to satisfy property (Np ) if we have the vanishings bi,j (C, L) = 0 for i ≤ p, j ≥ 2. In terms of the classical projective geometry, then φL : C ֒→ Pr is projectively normal if and only if L satisfies (N0 ), whereas the ideal IC/Pr is generated by quadrics if, in addition, it satisfies (N1 ). The line bundle L is called p-very ample if for every effective divisor D of degree p + 1 the evaluation map ev : H 0 (C, L) → H 0 (D, L|D ) 8 MICHAEL KEMENY is surjective. Conjecture 4.2 (Secant Conjecture, [35]). Let L be a globally generated line bundle of degree d on a curve C of genus g such that d ≥ 2g + p + 1 − 2h1 (C, L) − Cliff(C). Then (C, L) fails property (Np ) if and only if L is not p + 1-very ample. It is rather straightforward to see that if L is not p + 1 very ample then bp,2 (C, L) 6= 0. The harder part is to go in the other direction. In the case h1 (C, L) 6= 0, then the Secant Conjecture reduces to Green’s Conjecture, so we will focus on the case of a non-special line bundle L, i.e. one with h1 (C, L) = 0. Theorem 4.3 ([26]). The Secant Conjecture holds for a general curve C of genus g and a general line bundle L of degree d on C. An elementary argument shows that if C is general then the general L ∈ Picd (C) is (p+1)-very ample if and only if d ≥ g + 2p + 3. Using this inequality and the fact that if L is a globally generated, nonspecial, line bundle with bp,2 (C, L) = 0 then bp−1,2 (C, L(−x)) = 0 for a general x ∈ C, Theorem 4.3 reduces to finding a general curve C together with a non-special line bundle L ∈ Picd (C) with bp,2 (C, L) = 0 in the following two cases (1) g = 2i + 1, d = 2p + 2i + 4, p ≥ i − 1 (2) g = 2i, d = 2p + 2i + 3, p ≥ i − 1. We construct such curves C and line bundles L using lattice polarized K3 surfaces. Consider first the odd genus case g = 2i + 1. Let Λ = Z[C] ⊕ Z[L] be a lattice with intersection pairing     4i 2p + 2i + 4 (C)2 (C · L) = . 2p + 2i + 4 4p + 4 (C · L) (L)2 Consider a general K3 surface X with PicX ≃ Λ. We need to prove that bp,2 (C, LC ) = 0. From the short exact sequence 0 → ΓX (−C, L) → ΓX (L) → ΓC (LC ) → 0 we get → TorpR (ΓX (L), C)p+2 → TorpR (ΓC (LC ), C)p+2 → Torp−1 R (ΓX (−C, L), C)p+2 → for R = Sym H 0 (X, L) ≃ Sym H 0 (C, LC ). So it suffices to prove bp,2 (X, L) = bp−1,3 (X, −C, L) = 0, or, by the Hyperplane Restriction Theorem bp,2 (D, ωD ) = bp−1,3 (D, OD (−C), ωD ) = 0 where D ∈ |L| is a smooth curve. An easy computation shows D has genus 2p + 3 and Clifford index p + 1, so the vanishing bp,2 (D, ωD ) = 0 follows from Green’s Conjecture. For the vanishing bp−1,3 (D, OD (−C), ωD ) = 0, we need to replace the use of Green’s Conjecture with the following important result: Theorem 4.4 ([30]). Let C be a non hyperelliptic curve of genus g and η ∈ Picg−2j−1 (C) a line bundle such that η ∈ / Cg−j−1 − Cj for some 1 ≤ j ≤ g−1 2 . Then bj−1,3 (C, −(ωC ⊗ η), ωC ) = 0. SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 9 This implies that that for a general line bundle η of degree ≤ 2, bp−1,3 (D, −(ωD ⊗ η), ωD ) = 0, where the above result further specifies what is meant by “general”. We apply this in our case to the line bundle L∗D (C) which has degree 2i − 2p ≤ 2. The case of even genus g = 2i is similar. In this case one uses K3 surfaces with Picard lattice   4i − 2 2p + 2i + 3 . 2p + 2i + 3 4p + 4 5. The Wahl Map and the Prym–Green Conjecture Consider the moduli space Rg,ℓ parametrising pairs (C, τ ) of a smooth, genus g curve together with a torsion bundle τ of order exactly ℓ. This is an irreducible moduli space which admits a compactification Rg,ℓ , [11], [13]. Here are a few reasons one might be interested in Rg,ℓ : (1) Rg,ℓ can be considered as a higher genus analogue of the modular curve parametrizing elliptic curves plus ℓ-torsion line bundles and as such ought to be interesting from a number-theoretic point of view. (2) The moduli space Rg,ℓ is very closely related to the stack of ℓ-spin curves {(C, L) | L⊗ℓ ≃ ωC } and the two spaces are often considered together, [11]. The space of ℓ-spin curves has important applications to Gromov–Witten theory, [47]. (3) In the case ℓ = 2, the space Rg,2 has been much studied in relation to Abelian varieties, due to a construction of Prym which associates an Abelian variety to a point (C, τ ) ∈ Rg,2 , [39]. Let us explain (3) in more detail. There is the Prym map Pg : Rg,2 → Ag−1 defined as follows. Let (C, τ ) ∈ Rg,2 be a point and consider the associated double cover e→C ν : C which has the property ν∗ OCe ≃ OC ⊕ τ . Pushforward of divisors defines the Norm map e → Pic2g−2 (C). Nmν : Pic2g−2 (C) Then Nm−1 ν (ωC ) has two isomorphic connected components. The Abelian variety Pg (C, τ ) is the component 0 {L ∈ Nm−1 ν (ωC ) : h (C, L) = 0 mod 2} with principal polarization given by the Theta divisor 0 0 Θ := {L ∈ Nm−1 ν (ωC ) : h (C, L) ≥ 2, h (C, L) = 0 mod 2} If (C, τ ) ∈ Rg,ℓ , then the associated paracanonical curve is the embedded curve φωC ⊗τ : C ֒→ Pg−2 . In the case ℓ = 2, Mumford noticed that there was a close relationship between the projective geometry of a general paracanonical curve and the geometry of the Prym map. Indeed, the differential of the Prym map at a point (C, τ ) ∈ Rg,2 ⊗2 ∗ ) → (Sym2 H 0 (C, ωC ⊗ τ ))∗ dPg : H 0 (C, ωC is injective if and only if the multiplication map ⊗2 ) Sym2 H 0 (C, ωC ⊗ τ ) → H 0 (C, ωC is surjective, i.e. if and only if the corresponding paracanonical curve is projectively normal. Using a degeneration argument, Beauville verified that this indeed holds for the general (C, τ ) ∈ Rg,2 , provided g ≥ 6, [6]. Debarre went one step further and showed that the ideal IC/Pg−2 10 MICHAEL KEMENY is generated by quadrics for (C, τ ) ∈ Rg,2 general and g ≥ 9, [15]. Using this, he was able to conclude that Pg is in fact generically injective for g ≥ 9. It is tempting to imitate Green’s conjecture and try to generalize the Beauville–Debarre results to higher syzygies. This is achieved in the following result, which answers affirmatively a conjecture of Farkas–Ludwig [29] and Chiodo–Eisenbud–Farkas–Schreyer, [12]: Theorem 5.1 ([28]). Let g = 2i + 5 be odd and (C, τ ) ∈ Rg,ℓ general. Then bi+1,1 (C, ωC ⊗ τ ) = bi−1,2 (C, ωC ⊗ τ ) = 0. The result above suffices to completely determine all Betti numbers bp,q (C, ωC ⊗τ ) of a general paracanonical curve of arbitrary level ℓ and odd genus g = 2i + 5. Indeed, the Betti table, i.e. table with (q, p)th entry bp,q (C, ωC ⊗ τ ) of such a curve is 1 2 ... i − 1 i i + 1 i + 2 . . . 2i + 2 b1,1 b2,1 . . . bi−1,1 bi,1 0 0 ... 0 0 0 ... 0 bi,2 bi+1,2 bi+2,2 . . . b2i+2,2 where bp,1     (p + 1)(2p − 2i + 1) 2i + 4 p(2i − 2p + 1) 2i + 4 if p ≤ i , bp,2 = = 2i + 3 2i + 3 p+1 p+2 if p ≥ i. In even genus, it is known that the analogous conjecture does not always hold see [12], [14]. In order to prove Theorem 5.1, one might like to use the method described in the previous section and work with suitable K3 surfaces. This was successfully carried out assuming that the torsion level is large compared to the genus, [27]. When one attempts to prove the result for all levels, one immediate difficulty arises. Since the Picard group of a K3 surface is torsion free, it is difficult to construct K3 surfaces containing paracanonical curves in such a way that the torsion bundle τ comes as a pull-back of a line bundle on the surface, at least if ℓ is arbitrary. The solution we take in [28] is to look for something which is similar to a K3 surface but for which the Picard group admits torsion. To explain how such surfaces come about naturally, we need to describe the work of Wahl on classifying curves lying on a K3 surface, [46]. Let C be a smooth, complex curve. The Wahl map 2 ^ ⊗3 ), H 0 (C, ωC ) → H 0 (C, ωC is defined by the following rule. Choose analytic coordinate charts for C. A section s ∧ t is mapped under the Wahl map to the section specified by the formula (ds)t − t(ds) on these charts, see also [45]. Let C ⊆ Pg−1 be a canonical curve and let Y ⊆ Pg , denote the cone over C. Wahl discovered his map by studying the graded module of first order deformations of Y , [44]. The first interesting graded piece of this module is precisely the cokernel of the Wahl map. In particular, if the Wahl map is nonsurjective, and if furthermore a certain obstruction group vanishes, then Y may be deformed to a Gorenstein surface X ′ ⊆ Pg−1 with ωX ′ ≃ OX ′ which is not a cone. Such a surface looks somewhat like a K3 surface, with the caveat that it may have nasty singularities. This led Wahl to conjecture: Conjecture (Wahl’s Conjecture). Let C be a curve which is Brill–Noether–Petri general. Then C lies on a K3 surface if and only if the Wahl map is nonsurjective. SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 11 One direction of this is relatively easy: if C lies on a K3 surface then it follows from the infinitesimal analysis above that the Wahl map is never surjective, see [44]. Also see [7] for a simple, direct proof of this fact without deformation theory. As stated above, Wahl’s conjecture needs a slight modification. Arbarello–Bruno–Sernesi proved the following: Theorem ([4]). Let C be a Brill–Noether–Petri general curve of genus g ≥ 12. Then C lies on a projective K3 surface X ⊆ Pg , or is a limit of such curves, if and only if the Wahl map is nonsurjective. The result above is shown to be optimal in [3]. The proof of Arbarello–Bruno–Sernesi proceeds as follows. First of all, they verify that the obstruction group of [46] vanishes for a Brill–Noether– Petri general curve C. Thus if the Wahl map of C is nonsurjective, the cone Y can be deformed to some Gorenstein surface X ′ 6= Y with canonical curves as hyperplane sections. Such surfaces were classified by Epema in his thesis, [21]. This boils the task down to deciding when the surfaces appearing in Epema’s list can be smoothed (the smoothing of any such surface must be a K3 surface). In particular, there is one class of surface which features prominently in [4]. These are surfaces whose desingularization is a projective bundle over an elliptic curve. Such surfaces are an excellent candidate for proving the Prym–Green conjecture for the following reasons: (i) they arise as degenerations of smooth K3 surfaces, (ii) their general hyperplane sections are Brill–Noether–Petri general [33], (iii) by pulling back bundles from the elliptic curve, we have an abundance of torsion line bundles to work with. More precisely, let E be an elliptic curve and set X := P(OE ⊕ η) where η ∈ Pic0 (E) is neither trivial nor torsion. Then φ : X →E admits two sections J0 and J1 corresponding to the quotients η and OE respectively. Let r ∈ E be general, set fr := φ−1 (r) and consider the linear system |gJ0 + fr |. The general curve C ∈ |gJ0 + fr | is smooth of genus g and passes through two base points x ∈ J0 and y ∈ J1 . If e denotes the blow-up at these two points, then X KXe ≃ −(J0′ + J1′ ), e is the resolution of a limiting where J0′ , J1′ are the proper transforms of J0 , J1 . The surface X g K3 surface Y ⊆ P with two elliptic singularities. Now let b ∈ E be such that τ = b − r is ℓ-torsion, write η = a − b for some a ∈ E and set L = (g − 2)J0 + fa on X. By adjunction LC ≃ KC + τ and we prove that the paracanonical curve (C, LC ) satisfies the Prym–Green conjecture. One of the crucial new ingredients in the proof is that there is a canonical degeneration of C to J0 ∪ D where D ∈ |(g − 1)J0 + fr | has genus g − 1, which allows one to make inductive arguments on the genus. 6. Divisors on Moduli Spaces and the extremal Betti number of a canonical curve It has been known for some time that some of the most interesting loci in the moduli space of curves can be constructed using syzygies. For example, consider the divisor K := {C ∈ M10 | ∃L ∈ Pic12 (C) with h0 (L) = 4 and b0,2 (C, L) 6= 0} 12 MICHAEL KEMENY in the moduli space of curves of genus 10. It was shown in [32] that the closure of this locus violates the famous Slope Conjecture of Harris–Morrison. In practice, such syzygetic loci tend to give more information about the birational geometry of moduli spaces than other kinds of loci (such as Brill–Noether loci), [23], [12]. Rather than using our knowledge of syzygies of curves to describe the geometry of moduli spaces, we can also reverse the process and use cycle calculations on moduli spaces in order to obtain information about syzygies of curves. In [38], Hirschowitz–Ramanan construct determinantally a divisor Kos ⊆ M2k−1 parametrising {C ∈ M2k−1 | bk−1,1 (C, ωC ) 6= 0} and show that it coincides set-theoretically with the divisor Hur ⊆ M2k−1 parametrising {C ∈ M2k−1 | gon(C) ≤ k} studied by Harris–Mumford, [37]. Further, as divisors Kos = (k − 1)Hur ∈ A1 (M2k−1 , Q). Using this, Hirschowitz and Ramanan concluded that Green’s Conjecture holds for any curve of genus g = 2k − 1 and, furthermore, Schreyer’s Conjecture holds for curves of genus g = 2k − 1 and gonality k. It was discovered by Aprodu that one can use the Hirschowitz–Ramanan computation to obtain results about curves of arbitrary gonality, [1]. Let C be a curve of genus g and non1 (C) denote the subvariety of Picm (C) consisting of line maximal gonality k ≤ ⌊ g2 ⌋ + 2. Let Wm bundles with at least two sections. We say C satisfies linear growth if 1 (C) ≤ n for all 0 ≤ n ≤ g − 2k + 2. dim Wk+n Aprodu proved that the general k-gonal curve satisfies linear growth (if k is non-maximal) and further: Theorem (Aprodu). Let C satisfy linear growth. Then C satisfies Green’s Conjecture. Aprodu’s Theorem is the sharpest known result on Green’s conjecture. Further, it was a key step in verifying that Green’s Conjecture holds for curves on arbitrary K3 surfaces, [2]. Aprodu’s Theorem relies on the following trick with nodal curves (which is a variant of an argument of Voisin [42]): let C and be in the theorem, with k = gon(C), choose n = g + 3 − 2k general pairs of points (xi , yi ) ∈ C, 1 ≤ i ≤ n and let D be the nodal curve obtained from D by identifying xi and yi . Then D has genus g + n = 2(g − k + 1) − 1 and Aprodu shows that the linear growth condition implies D ∈ / Hur. By Hirschowitz–Ramanan’s calculation, this implies bg−k+1,1 (D, ωD ) = 0. But, as Voisin shows, there is a natural injective map g−k+1 TorR (C, ωC )g−k+2 ֒→ Torg−k+1 (D, ωD )g−k+2 , R2 1 where R1 = SymH 0 (ωC ), R2 = SymH 0 (ωD ). Hence bg−k+1,1 (C, ωC ) = 0 as predicted by Green’s Conjecture. We now turn back to the problem of attempting to describe the Betti table of a canonical curve of non-maximal gonality k. Recall from Section 3 that if C admits m minimal pencils f1 , . . . , fm then the associated scrolls Xf1 , . . . , Xfm each contribute to the syzygies of C. Recall further that the “extremal” Betti number bg−k,1 (C, ωC ) was singled out by Schreyer’s conjecture to be of particular importance. We prove Theorem 6.1 ([24]). Let C be a smooth curve of genus g and gonality k ≤ ⌊ g+1 2 ⌋. Assume C admits m minimal pencils, and that the pencils are infinitesimally and geometrically in general position. Assume further that C satisifies bpf-linear growth. Then bg−k,1 (C, KC ) = m(g − k). SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 13 In other words, one can read off the number of minimal pencils from the last Betti number in the linear strand, under certain generality assumptions on the minimal pencils. Let us first state the meaning of the assumptions. A curve C of genus g and gonality k satisfies bpf-linear growth provided we have the dimension estimates 1 (C) ≤ m, for 0 ≤ m ≤ g − 2k + 1 dim Wk+m 1,bpf dim Wk+m (C) < m, for 0 < m ≤ g − 2k + 1, 1,bpf where Wk+m (C) denotes the locus of base point free line bundles. This condition is a slight strengthening of Aprodu’s linear growth assumption. Next, the condition that the pencils are infinitesimally in general position means that the deformation theory of any subset σ = {σi } ⊆ {f1 , . . . , fm } of the pencils is unobstructed (modulo the PGL(2) action). More precisely, setting Fσ := (fσi ) : C → (P1 )|σ| , we require Ext2C (Ω•Fσ , OC (−p − q − r)) = 0 for all subsets σ and general p, q, r ∈ C, where Ω•Fσ is the cotangent complex of Fσ . Lastly, the condition that the pencils be geometrically in general position is a condition to ensure that the scrolls contribute syzygies independently into the extremal Betti number of the curve. To describe it, choose a general divisor T of degree g − 1 − k on C. Let Qf1 , . . . , Qfm be the quadrics obtained by projecting the scrolls Xf1 , . . . , Xfm away from T . We say {f1 , . . . , fm } is geometrically in general position if the set {Qf1 , . . . , Qfm } ⊆ |OPk (2)| is in general position. In practice, these three assumptions seem relatively easy to verify. For instance, they can be checked to hold for a general curve of non-maximal gonality k admitting m ≤ 2 minimal pencils. When m ≥ 3, we lack a good understanding of when the moduli space of curves with m minimal pencils is nonempty and irreducible, which makes it harder to approach this case, but computational evidence suggests, for instance, that the assumptions are verified for g = 11 and k = 6 provided 1 ≤ m ≤ 10, which excludes only the “sporadic” cases m = 12, 20 (the assumptions should be satisfied up until the first m where the moduli space of curves with m pencils becomes empty, which in this case is m = 11). We just state a few words about the proof, for more details see the forthcoming [24]. The proof works by ultimately reducing to the case g = 2k − 1 using a variant of Aprodu’s trick. The reduction is significantly more difficult than in Aprodu’s case, as we are required to work with stable maps with unstable curves on the base, and involves the notion of “twisting” for line bundles on a family of curves with central fibre a reducible curve, see [31], [5]. In the case g = 2k − 1, in our setting the role of the Koszul divisor of Hirschowitz–Ramanan is replaced with “Eagon–Northcott” divisors defined on an appropriate moduli space H(m) of stable maps C → (P1 )m with three base points. Letting H(m) → H(1), denote the projection to the first factor, these divisors push forward to give codimension m + 1 cycles EN m ∈ Am+1 (H(1), Q), where H(1) is a suitable subset of the space of degree k stable maps C → P1 from curves of genus 2k − 1 (with three base points, to account for the automorphisms of P1 ). These cycles satisfy the identity EN m = (k − 1)BN m+1 where BN m+1 ∈ Am (H(1), Q) is a cycle corresponding to curves with m + 1 minimal pencils. This equation should be seen as a generalization of Hirschowitz–Ramanan’s equation Kos = (k − 1)Hur ∈ A1 (M2k−1 , Q). 14 MICHAEL KEMENY References [1] M. Aprodu. Remarks on szyzgies of d-gonal curves. Math. Res. Lett., 12:387–400, 2005. [2] M. Aprodu and G. Farkas. Green’s conjecture for curves on arbitrary K3 surfaces. Comp. Math., 147(03):839– 851, 2011. [3] E. Arbarello and A. Bruno. Rank two vector bundles on polarised Halphen surfaces and the Gauss-Wahl map for du Val curves. arXiv:1609.09256. [4] E. Arbarello, A. Bruno, and E. Sernesi. On hyperplane sections of K3 surfaces. arXiv:1507.05002 (to appear in Algebraic Geometry). [5] M. Bainbridge, D. Chen, Q. Gendron, S. Grushevsky, and M. Moeller. Compactification of strata of abelian differentials, 2016. arXiv:1604.08834. [6] A. Beauville. Prym varieties and the Schottky problem. Invent. Math., 41(2):149–196, 1977. [7] A. Beauville and J.-Y. Mérindol. Sections hyperplanes des surfaces K3. Duke Math. J., 55(4):873–878, 1987. [8] E. Bertini. Introduzione alla geometria proiettiva degli iperspazi: con appendice sulle curve algebriche e loro singolarità. Enrico Spoerri, Pisa, 1907. [9] D. Buchsbaum and D. Eisenbud. What makes a complex exact? Journal of Algebra, 25(2):259–268, 1973. [10] D. Buchsbaum and D. Eisenbud. Generic free resolutions and a family of generically perfect ideals. Advances in Math., 18(3):245–301, 1975. [11] A. Chiodo. Stable twisted curves and their r-spin structures. Ann. Inst. Fourier, 58(5):1635–1689, 2008. [12] A. Chiodo, D. Eisenbud, G. Farkas, and F.-O. Schreyer. Syzygies of torsion bundles and the geometry of the level l modular variety over Mg . Invent. Math., 194(1):73–118, 2013. [13] A. Chiodo and G. Farkas. Singularities of the moduli space of level curves. J. Euro Math. Soc., 19(3):603–658, 2017. [14] E. Colombo, G. Farkas, A. Verra, and C. Voisin. Syzygies of prym and paracanonical curves of genus 8. Épijournal de Géométrie Algébrique, 1(1), 2017. [15] O. Debarre. Sur le probleme de Torelli pour les variétés de Prym. American Journal of Math., 111(1):111–134, 1989. [16] I.V. Dolgachev. Mirror symmetry for lattice polarized K3 surfaces. J. Math. Sci., 81(3):2599–2630, 1996. [17] J. Eagon and D. Northcott. Ideals defined by matrices and a certain complex associated with them. In Proceedings of the Royal Society of London, volume 269, pages 188–204, 1962. [18] D. Eisenbud. Commutative algebra with a view toward algebraic geometry. GTM150. Springer, 1995. [19] D. Eisenbud and J. Harris. On varieties of minimal degree (A Centennial Account). In Proc. Sympos. Pure Math, volume 46, pages 3–13, 1985. [20] D: Eisenbud, H. Lange, G. Martens, and F.-O. Schreyer. The Clifford dimension of a projective curve. Comp. Math., 72(2):173–204, 1989. [21] D. Epema. Surfaces with canonical hyperplane sections, cwi tract 1. Stichting Mathematisch Centrum, Centrum voor Wiskunde en Informatica, Amsterdam, 1984. [22] G. Farkas. Syzygies of curves and the effective cone of M g . Duke Math. J., 135(1):53–98, 2006. [23] G. Farkas. Koszul divisors on moduli spaces of curves. American Journal of Math., 131(3):819–867, 2009. [24] G. Farkas and M. Kemeny. In Preparation. [25] G. Farkas and M. Kemeny. Linear syzygies of curves with prescribed gonality, 2016. arXiv:1610.04424. [26] G. Farkas and M. Kemeny. The generic Green–Lazarsfeld secant conjecture. Invent. Math., 203(1):265–301, 2016. [27] G. Farkas and M. Kemeny. The Prym-Green Conjecture for torsion bundles of high order. Duke Math. J., 166(6):1103–1124, 2017. [28] G. Farkas and M. Kemeny. The Resolution of Paracanonical Curves of Odd Genus, 2017. arXiv:1707.06297. [29] G. Farkas and K. Ludwig. The Kodaira dimension of the moduli space of Prym varieties. JEMS, 12(3):755– 795, 2010. [30] G. Farkas, M. Mustaţă, and M. Popa. Divisors on Mg,g+1 and the Minimal Resolution Conjecture for points on canonical curves. Annales Scientifiques de l’École Normale Supérieure, 36(4):553–581, 2003. [31] G. Farkas and R. Pandharipande. The moduli space of twisted canonical divisors. Journal of the Institute of Mathematics of Jussieu, pages 1–58, 2016. [32] G. Farkas and M. Popa. Effective divisors on Mg , curves on K3 surfaces, and the Slope Conjecture. J. Algebraic Geom., 14(2):241–267, 2005. [33] G. Farkas and N. Tarasca. Du Val curves and the pointed Brill–Noether Theorem. Selecta Mathematica, 23(3):2243–2259, 2017. [34] M. Green. Koszul cohomology and the geometry of projective varieties. J. Diff. Geo., 19(1):125–171, 1984. [35] M. Green and R. Lazarsfeld. On the projective normality of complete linear series on an algebraic curve. Invent. Math., 83(1):73–90, 1986. SYZYGIES OF CURVES BEYOND GREEN’S CONJECTURE 15 [36] M. Green and R. Lazarsfeld. Special divisors on curves on a K3 surface. Invent. Math., 89:357–370, 1987. [37] J. Harris and D. Mumford. On the Kodaira dimension of the moduli space of curves. Invent. Math., 67(1):23– 86, 1982. [38] A. Hirschowitz and S. Ramanan. New evidence for green’s conjecture on syzygies of canonical curves. Annales Scientifiques de l’École Normale Supérieure, 31(2):145–152, 1998. [39] D. Mumford. Prym varieties I. Contributions to analysis (a collection of papers dedicated to Lipman Bers), 325:350, 1974. [40] F. Schreyer. Syzygies of canonical curves and special linear series. Math. Ann., 275(1):105–137, 1986. [41] F.-O. Schreyer. Green’s conjecture for general p-gonal curves of large genus. Algebraic curves and projective geometry, pages 254–260, 1989. [42] C. Voisin. Green’s generic syzygy conjecture for curves of even genus lying on a K3 surface. JEMS, 4(4):363– 404, 2002. [43] C. Voisin. Green’s canonical syzygy conjecture for generic curves of odd genus. Comp. Math., 141(5):1163– 1190, 2005. [44] J. Wahl. The Jacobian algebra of a graded Gorenstein singularity. Duke Math. J., 55(4):843–511, 1987. [45] J. Wahl. Gaussian maps on algebraic curves. J. Diff. Geo., 32(1):77–98, 1990. [46] J. Wahl. On the cohomology of the square of an ideal sheaf. J. Alg. Geom., 76:481–871, 1997. [47] E. Witten. Algebraic geometry associated with matrix models of two-dimensional gravity. Topological methods in modern mathematics (Stony Brook, NY, 1991), pages 235–269, 1993.
0math.AC
A Projected Gradient Descent Method for CRF Inference allowing End-To-End Training of Arbitrary Pairwise Potentials Måns Larsson1 , Anurag Arnab2 , Fredrik Kahl1,3 , Shuai Zheng2 , and Philip Torr2 arXiv:1701.06805v3 [cs.CV] 2 Jan 2018 1 3 Chalmers University of Technology, Gothenburg, Sweden 2 University of Oxford, Oxford, England Centre for Mathematical Sciences, Lund University, Lund, Sweden Abstract. Are we using the right potential functions in the Conditional Random Field models that are popular in the Vision community? Semantic segmentation and other pixel-level labelling tasks have made significant progress recently due to the deep learning paradigm. However, most state-of-the-art structured prediction methods also include a random field model with a hand-crafted Gaussian potential to model spatial priors, label consistencies and feature-based image conditioning. In this paper, we challenge this view by developing a new inference and learning framework which can learn pairwise CRF potentials restricted only by their dependence on the image pixel values and the size of the support. Both standard spatial and high-dimensional bilateral kernels are considered. Our framework is based on the observation that CRF inference can be achieved via projected gradient descent and consequently, can easily be integrated in deep neural networks to allow for end-to-end training. It is empirically demonstrated that such learned potentials can improve segmentation accuracy and that certain label class interactions are indeed better modelled by a non-Gaussian potential. In addition, we compare our inference method to the commonly used mean-field algorithm. Our framework is evaluated on several public benchmarks for semantic segmentation with improved performance compared to previous state-of-the-art CNN+CRF models. Keywords: Conditional Random Fields, Segmentation, Convolutional Neural Networks 1 Introduction Markov Random Fields (MRFs), Conditional Random Fields (CRFs) and more generally, probabilistic graphical models are a ubiquitous tool used in a variety of domains spanning Computer Vision, Computer Graphics and Image Processing [23,4]. In this paper, we focus on the application of CRFs for Computer Vision problems involving per-pixel labelling such as image segmentation. There are many successful approaches in this line of research, such as the interactive segmentation of [31] using graph cuts and the semantic segmentation works of [25,35] where the parallel mean-field inference algorithm was applied for fast inference. Recently, Convolutional Neural Networks ×10 -3 0 4 2 k spatial ×10 -4 9 k spatial k spatial ×10 -4 20 8 4 2 0 -2 x-shift -4 -4 -2 0 2 y-shift terrain - traffic light 4 6.4 4 2 0 -2 x-shift 7.4 -4 -4 -2 0 2 y-shift vegetation - traffic sign 4 0 -2 x-shift -4 -4 -2 0 2 4 y-shift road - sidewalk Fig. 1. Learned spatially invariant CRF filters for C ITYSCAPES. These filters model contextual relationships between classes and their values can be understood as the energy added when setting one pixel to the first class (e.g., vegetation) and the other pixel with relative position (x-shift,yshift) to the second class (e.g., traffic sign). Note how the terrain-traffic light filter favours vertical edges. In addition, the model can learn filters of different shapes which is shown by the roadsidewalk filter. (CNNs) have dominated the field in a variety of recognition tasks [18,33,30]. However, we observe that leading segmentation approaches still include CRFs, either as a postprocessing step [10,16,9,11], or as part of the deep neural network itself [38,26,2,27,22]. We leverage on the idea of embedding inference of graphical models into a neural network. An early example of this idea was presented in [7] where the authors back propagated through the Viterbi algorithm when designing a document recognition system. Similar to [38,2,3,37], we use a recurrent neural network to unroll the iterative inference steps of a CRF. This was first used in [38] and [32] to imitate mean-field inference and to train a fully convolutional network [28,10] along with a CRF end-to-end via back propagation. In contrast to mean-field, we do not optimize the KL-divergence. Instead, we use a gradient descent approach for the inference that directly minimises the Gibbs energy of the random field and hence avoids the approximations of mean-field. A similar framework was recently suggested in [3] for multi-label classification problems in machine learning with impressive results. However, [3] uses a Structured SVM approach for training whereas we do back propagation through the actual steps of the gradient descent method. Moreover, [15] have recently shown that one can obtain lower energies compared to mean-field inference using gradient descent based optimization schemes. Still, we lack formal algorithmic guarantees of the solution quality compared to, e.g., graph cuts [8]. In many works, the pairwise potentials consist of parametrized Gaussians [24,38,2] and it is only the parameters of this Gaussian which are learned. Our framework can learn arbitrary pairwise potentials which need not be Gaussian, cf. Fig. 1. An early work which learned potentials of a linear chain CRF for sequence modelling is [29]. In [12], a general framework for learning arbitrary potentials in deep structured models was proposed based on approximate Maximum Likelihood learning. One of the advantages with that framework is that data likelihood is maximized in the learning process. However, this involves approximating the partition function which is otherwise intractable. This hinders the handling of large structured output spaces like in our case. The experiments of [12] and [3] are limited to multi-label classification where there is no spatial relationship between different labels as in pixel-labelling tasks. Morever, [22] have also observed that the memory requirements of the method of [12] renders it infeasible for the large datasets common in Computer Vision. Another approach to learning arbitrary 2 pairwise potentials was presented in [22] which uses Gibbs sampling. Again they struggle with the difficulty of computing the partition function. In the end, only experiments on synthetic data restricted to learned 2D potentials are presented. The authors of [26] and [9] also learn arbitrary pairwise potentials to model contextual relations between parts of the image. However, their approaches still perform post-processing with a CRF model with parametric Gaussian potentials. In [20], a pairwise potential is learned based on sparse bilateral filtering. Applying such a filter can be regarded as one iteration of mean field CRF inference. Contrasting [20], we not only learn sparse high-dimensional bilateral filters, but also learn arbitrary spatial filters. Such spatial 2D potentials are computationally much more efficient and easier to analyze and interpret compared to their high-dimensional counterparts. In summary, our contributions are as follows. – Our main contribution is a new framework for non-parametric CRF inference and learning which is integrated with standard CNNs. During inference, we directly minimize the CRF energy using gradient descent and during training, we back propagate through the gradient descent steps for end-to-end learning. – We analyze the learned filter kernels empirically and demonstrate that in many cases it is advantageous with non-Gaussian potentials. – We experimentally compare our approach to several leading methodologies, e.g., [38,16,28] and improve on state of the art on two public benchmarks: NYU V2 [36] and C ITYSCAPES [14]. Our framework has been implemented in both C AFFE [21] and M AT C ONV N ET [34], and all source code will be made publicly available to facilitate further research. 2 CRF Formulation Consider a Conditional Random Field over N discrete random variables X = {X1 , ..., XN } conditioned on an observation I and let G = {V, E} be an undirected graph whose vertices are the random variables {X1 , ..., XN }. Each random variable corresponds to a pixel in the image and takes values from a predefined set of L labels L = { 0, ..., L−1 }. The pair (X , I) is modelled as a CRF characterized by the Gibbs distribution P (X = x|I) = 1 exp(−E(x|I)), Z(I) (1) where E(x|I) denotes the Gibbs energy function with respect to the labeling x ∈ LN and Z(I) is the partition function. To simplify notation the conditioning on I will from now on be dropped. The MAP inference problem for the CRF model is equivalent to the problem of minimizing the energy E(x). In this paper, we only consider energies containing unary and pairwise terms. The energy function can hence be written as X X E(x) = ψi (xi ) + ψij (xi , xj ) (2) i∈V (i,j)∈E where ψi : L → R and ψij : L × L → R are the unary and pairwise potentials, respectively. 3 2.1 Potentials The unary potential ψi (xi ) specifies the energy cost of assigning label xi to pixel i. In this work we obtain our unary potentials from a CNN. Roughly speaking, the CNN outputs a probability estimate of each pixel containing each class. Denoting the output of the CNN for pixel i and class xi as zi:xi , the unary potential is ψi (xi ) = −wu log(zi:xi + ) (3) where wu is a parameter controlling the impact of the unary potentials, and  is introduced to avoid numerical problems. The pairwise potential ψij (xi , xj ) specifies the energy cost of assigning label xi to pixel i while pixel j is assigned label xj . Introducing pairwise terms in our model enables us to take dependencies between output data into account. We consider the following set of pairwise potentials ψij (xi , xj ) = kxspatial (pi − pj ) + kxbilateral (fi − fj ) i ,xj i ,xj (4) denotes a spatial kernel with compact support. Its value depends on the Here kxspatial i ,xj relative position coordinates pi − pj between pixels i and j. We do not restrict these spatial terms to any specific shape, cf. Fig. 1. However, we restrict the support of the potential meaning that if pixels i and j are far apart, then the value of kxspatial (pi − pj ) i ,xj will be zero. CRFs with Gaussian potentials do not in theory have compact support, and therefore, they are often referred to as dense. However, in practice, the exponential function in the kernel drops off quickly and effectively. The interactions between pixels far apart are negligible and are commonly truncated to 0 after two standard deviations. The term kxbilateral is a bilateral kernel which depends on the feature vectors fi and i ,xj fj for pixels i and j, respectively. Following several previous works [24,38,11], we let the vector depend on pixel coordinates pi and RGB values associated to the pixel, hence fi is a 5-dimensional vector. Note that for both the spatial and the bilateral kernels, there is one kernel for each label-to-label (xi and xj ) interaction to enable the model to learn differently shaped kernels for each of these interactions. 2.2 Multi-label Graph Expansion and Relaxation To facilitate a continuous relaxation of the energy minimisation problem we start off by expanding our original graph in the following manner. Each vertex in the original graph G will now be represented by L vertices Xi:λ , λ ∈ L. In this way, an assignment of labels in L to each variable Xi is equivalent to an assignment of boolean labels 0 or 1 to each node Xi:λ , whereby an assignment of label 1 to Xi:λ means that in the multilabel assignment, Xi receives label λ. As a next step, we relax the integer program by allowing real values on the unit interval [0, 1] instead of booleans only. We denote the relaxed variables qi:λ ∈ [0, 1]. We can now write our problem as a quadratic program X X min ψi (λ)qi:λ + ψij (λ, µ)qi:λ qj:µ i∈V,λ∈L (i,j)∈E λ,µ∈L s.t. qX i:λ ≥ 0 qi:λ = 1 ∀i ∈ V, λ ∈ L ∀i ∈ V. λ∈L 4 (5) Note that the added constraints ensure that our solution lies on the probability simplex. A natural question is what happens when the domain is enlarged, allowing real values instead of booleans. Somewhat surprisingly, the relaxation is tight [6]. Proposition 1 Let E(x∗ ) and E(q ∗ ) denote the optimal values of (5), where x∗ is restricted to boolean values. Then, E(x∗ ) = E(q ∗ ). In the supplementary material, we show that for any real q, one can obtain a binary x such that E(x) ≤ E(q). In particular, it will be true for x∗ and q ∗ , which implies E(x∗ ) = E(q ∗ ). Note that the proof is constructive. In summary, it has been shown that to minimize the energy function E(x) over x ∈ LN , one may work in the continuous domain, minimize over q, and then replace any solution q by a discrete solution x which has lower or equal energy. It will only be possible to find a local solution q, but still the discrete solution x will be no worse than q. 3 Minimization with Gradient Descent To solve the program stated in (5) we propose an optimization scheme based on projected gradient descent, see Algorithm 1. It was designed with an extra condition in mind, that all operations should be differentiable to enable back propagation during training. Initialize q 0 for t from 0 to T − 1 do Compute the gradient ∇q E(q t ). Take a step in the negative direction, q̃ t+1 P = qt − γ ∇q E. t+1 L Project q̃i:λ to the simplex 4 satisfying λ∈L q̃i:λ = 1 and 0 ≤ q̃i:λ ≤ 1, q t+1 = Proj4L (q̃). end Output: q T −1 Algorithm 1: Algorithm 1. Projected gradient descent algorithm. The gradient ∇q E of the objective function E(q) in (5) has the following elements X ∂E = ψi (λ) + ψij (λ, µ)qj:µ . (6) ∂qi:λ j:(i,j)∈E µ∈L The contribution from the spatial kernel in ψij , cf. (4), can be written as X spatial spatial vi:λ = kλ,µ (pi − pj )qj:µ . j:(i,j)∈E µ∈L 5 (7) spatial Since the value of the kernel vi:λ only depends on the relative position of pixels i and j, the contribution for all pixels and classes can be calculated by passing qj:µ through a standard convolution layer consisting of L × L filters of size (2s + 1) × (2s + 1) where L is the number of labels and s the number of neighbours each pixel interacts with in each dimension. The contribution from the bilateral term is X bilateral bilateral vi:λ = kλ,µ (fi − fj )qj:µ . (8) j:(i,j)∈E µ∈L For this computation we utilize the method presented by Jampani et al. [20] which is based on the permutohedral lattice introduced by Adams et al. [1]. Efficient computations are obtained by using the fact that the feature space is generally sparsely populated. Similar to the spatial filter we get L × L filters, each having size of (s + 1)d+1 − sd+1 where s is the number of neighbours each pixel interacts with in each dimension in the sparse feature space. Next, we simply take a step in the negative direction of the gradient according to q̃ t+1 = qt − γ ∇q E, (9) where γ is the the step size. P Finally, we want to project our values onto the simplex 4L satisfying λ∈L qi:λ = 1 and 0 ≤ qi:λ ≤ 1. This is done following the method by Chen et al. [13] that efficiently calculates the euclidean projection on the probability simplex 4L , for details see the supplementary materials. Note that this projection is done individually for each pixel i. Comparison to Mean-Field. In recent years, a popular choice for CRF inference is to apply the mean-field algorithm. One reason is that the kernel evaluations can be computed with fast bilateral filtering [25]. As we have seen in this section, it can be accomplished with our framework as well. The main difference is that our framework directly optimizes the Gibbs energy which corresponds to the MAP solution while mean-field optimizes KL-divergence which does not. 4 Integration in a Deep Learning Framework In this section we will describe how the gradient descent steps of Algorithm 1 can be formulated as layers in a neural network. We need to be able to calculate error derivatives with respect to the input given error derivatives with respect to the output. In addition we need to be able to calculate the error derivatives with respect to the network parameters. This will enable us to unroll the entire gradient descent process as a Recurrent Neural Network (RNN). A schematic of the data flow for one step is shown in Fig. 2. In the supplementary material, all derivative formulae are given. Initialization. The variables q 0 are set as the output of the CNN, which has been pretrained to estimate the probability of each pixel containing each class and has a softmax layers at the end to ensure that the variables lies within zero and one as well as sum to one for each pixel. 6 Unary Bilateral + Spatial Fig. 2. The data flow of one iteration of the projected gradient descent algorithm. Each rectangle or circle represent an operation that can be performed within a deep learning framework. Gradient Computations. We have previously explained the gradient computations in Section 3 for the forward pass. To describe the calculation of the error derivatives we first notice that the gradient is calculated by summing three terms, the unary, spatial and bilateral pairwise terms. We can hence treat these three terms separately and combine them using element-wise summing. The unary term in (3) is an element-wise operation with the CNN output as input and the unary weight wu as parameter. The operation is obviously differentiable with respect to both the layer input as well as its parameter. Note that for wu we get a summation over all class and pixel indexes for the error derivatives while for the input the error derivatives are calculated element-wise. The spatial pairwise term of the gradient can be calculated efficiently using standard 2D convolution. In addition to giving us an efficient way of performing the forward pass we can also utilize the 2D convolution layer to perform the backward pass, calculating the error derivatives with respect to the input and parameters. Similar to the spatial term, the bilateral term is also calculated utilizing a bilateral filtering technique. Jampani et al. [20] also presented a way to calculate the error derivatives with respect to the parameters for an arbitrary shaped bilateral filter. Gradient Step. Taking a step in the negative direction of the gradient is easily incorporated in a deep learning framework by using an element-wise summing layer. The layer takes the variables q t as the first input and the gradient (scaled by −γ) as the second input. Simplex Projection As a final step, the variables from the gradient step q̃ t are projected onto the simplex 4L . In reality we use a leaky version of the last step of the projection algorithm to avoid error derivatives becoming zero during back propagation. Since the projection is done individually for each pixel it can be described as a function f (q̃) : RL → RL of which we can calculate the Jacobian, see supplementary materials. Knowing the Jacobian, the error derivatives with respect to the input can be computed during back propagation. 7 Projected Gradient Descent Step CNN Fig. 3. The data flow of the deep structured model. Each rectangle or circle represent an operation that can be performed within a deep learning framework. 5 Recurrent Formulation as a Deep Structured Model Our iterative solution to the CRF energy minimisation problem by projected gradient descent, as described in the previous sections, is formulated as a Recurrent Neural Network (RNN). The input to the RNN is the image, and the outputs of a CNN, as shown in Fig. 3. The CNN’s output, z, are the unary potentials and obtained after the final softmax layer (since the CNN is initially trained for classification). Each iteration of the RNN performs one projected gradient descent step to approximately solve (5). Thus, one update step can be represented by: q t+1 = f (q t , z, I, w). (10) As illustrated in Fig. 3, the gating function G1 sets q t to z at the first time step, and to q t−1 at all other time steps. In our iterative energy minimisation formulated as an RNN, the output of one step is the input to the next step. We initialise at t = 0 with the output of the unary CNN. The output of the RNN can be read off q T where T is the total number of steps taken. In practice, we perform a set number of T steps where T is a hyperparameter. It is possible to run the RNN until convergence for each image (thus a variable number of iterations per image), but we observed minimal benefit in the final Intersection over Union (IoU) from doing so, as opposed to T = 5 iterations. The parameters of the RNN are the filter weights for the spatial and bilateral kernels, and also the weight for the unary terms. Since we are able to compute error derivatives with respect to the parameters, and input of the RNN, we can back propagate error derivates through our RNN to the preceding CNN and train our entire network end-toend. Furthermore, since the operations of the RNN are formulated as filtering, training and inference can be performed efficiently in a fully-convolutional manner. Implementation Details. Our proposed CRF model has been implemented in the C AFFE [21] library, and also has a Matlab wrapper allowing it to be used in M AT C ONV N ET [34]. The Unary CNN part of our model is initialised from a pre-trained segmentation network. As we show in our experiments, different pre-trained networks for different applications can be used. The CRF model has several tunable parameters. The step size γ and the number of iterations T specify the properties of the gradient decent algorithm. Too high a step size γ might make the algorithm not end up in a minimum while setting a low step size and a low number of iterations might not give the algorithm a chance to converge. The kernel sizes for the spatial and bilateral kernels also need to be set. Choosing the value 8 Input zhorse 1 qhorse 2 qhorse 3 qhorse 4 qhorse 5 qhorse Ground truth Fig. 4. Visualization of intermediate states of the CRF-Grad layer for the W EIZMANN H ORSE dataset. Note how each step of the gradient descent algorithm refines the segmentation slightly, removing spurious outlier pixels classified as horse. zhorse is the CNN output. of these parameters gives a trade-off between model expression ability and number of parameters, which may cause (or hinder) over-fitting. The spatial weights of the CRF model are all initialized as zero with the motivation that we did not want to impose a shape for these filters, but instead see what was learned during training. The bilateral filters were initialized as Gaussians with the common Potts class interaction (the filters corresponding to interactions between the same class were set to zero) as done in [25,10,38]. Note that unlike [25,10] we are not limited to only Potts class interactions. 6 Experiments We evaluate the proposed approach on three datasets: W EIZMANN H ORSE [5], NYU V2 [36] and C ITYSCAPES [14]. In these experiments, we show that the proposed approach, denoted CRF-Grad, has advantages over baseline approaches such as CRFasRNN [38] and complement other networks such as FCN-8s [28] and LRR [16]. In addition we compare our inference method to mean-field inference. Hyperparameter values not specified in this section can be found in the supplementary materials. 6.1 Weizmann Horse The W EIZMANN H ORSE dataset contains 328 images of horses in different environments. We divide these images into a training set of 150 images, a validation set of 50 images and a test set of 128 images. Our purpose is to verify our ability to learn reasonable kernels and study the effects of different settings on a relatively small dataset. The CNN part of our model was initialized as an FCN-8s network [28] pre-trained without the CRF layer. We then compare several variants of our model. We start off by training a variant of our CRF model only using the 2D spatial kernel. We compare these results to using a Gaussian spatial filter, where the parameters for the Gaussian kernel were evaluated using cross-validation. In addition we train the full model with both the spatial and bilateral kernels, once keeping the filters fixed as Gaussians and once allowing arbitrarily shaped filters. 9 The mean Intersection over Union (IoU) on the test set, for different configurations of our model, is shown in Table 1. Our results show that allowing arbitrarily shaped filters gives better performance than keeping the filters fixed as Gaussian. This is the case for both the spatial and bilateral kernels. Also, adding bilateral filters improves the results compared to using spatial filters only. In addition the model trained with our inference method performs better than the model (with the same unary and pairwise potentials) trained with mean-field inference. W EIZMANN H ORSE NYU V2 C ITYSCAPES Method IoU (%) Method IoU (%) Method IoU (%) FCN-8s (only) 80.0 R-CNN [17] 40.3 CRFasRNN* [38] 62.5 FCN-8s + spatial (G) 81.3 Joint HCRF [36] 44.2 Deeplabv2-CRF [11] 70.4 FCN-8s + spatial 82.0 Modular CNN [19] 54.3 Adelaide context [26] 71.6 FCN-8s + full (G) 82.9 CRFasRNN [38] 54.4 LRR-4x [16] 71.8 FCN-8s + full 84.0 CRF-Grad (Ours) 55.0 CRF-Grad (Ours) 71.9 FCN-8s + full (MF) 83.3 * Note that CRFasRNN uses a different CNN model than ours on the C ITYSCAPES dataset. Table 1. Quantitative results comparing our method to baselines as well as state-of-the-art methods. Mean intersection over union for the test set is shown for W EIZMANN H ORSE and C ITYSCAPES, for NYU V2 there is no test set and validation score is presented. In the entry denoted “full” the complete CRF-Grad layer was used, while in “spatial” no bilateral kernel was used. A (G) means that the filters were restricted to a Gaussian shape and (MF) means that the inference method was switched to mean field. For the entries denoted CRF-Grad the full model was used. In Fig. 4 the intermediate states of the layer (qt for each gradient descent step) are shown. Fig. 5 presents a convergence analysis for the full version of our layer as well as a comparison to mean-field inference. The results show that the CRF energy converges in only a few iteration steps and that increasing the number of iterations barely affects performance after T = 6 iterations. It also shows that our inference method achieves lower Gibbs energy as well as higher IoU results compared to mean-field, even for models trained with mean-field inference. Looking at using mean field inference for the model trained with projected gradient descent we see that the energy increases for each iteration. The reason for this is that the mean-field method doesn’t actually minimize the energy but the Kullback-Liebler divergence between the Gibbs distribution and the solution. This is, as shown in the supplementary materials, equivalent to minimizing the energy minus the entropy. The extra entropy term favors “uncertain” solutions, i.e. solution with values not close to zero or one, which increases the energy for some models. 6.2 NYU V2 The NYU V2 dataset contains images taken by Microsoft Kinect V-1 camera in 464 indoor scenes. We use the official training and validation splits consisting of 795 and 10 Projected Gradient Descent × 10 4 Mean Field × 10 5 -5.5 0.86 -1.2 0.84 -1.25 -1.3 0.82 -6 Energy mean IoU Energy -1.35 mean mean - MF inference per image mean mean - PGD inference per image -1.4 0.8 PGD MF PGD - MF inference MF - PGD inference 0.78 -1.45 -6.5 0.76 -1.5 0.74 -1.55 -7 0.72 0 1 2 3 iteration 4 5 6 7 0 1 2 3 iteration 4 5 6 7 0 1 2 3 4 5 6 7 iteration Fig. 5. Left and Middle: CRF energy, as defined in (5), as a function of inference iterations. The thin blue lines show the different instances, the thicker red line show the mean while the green line shows the mean when the inference method has been switched. The model has been trained with the inference method shown in respective title. For these calculations the leak factor was set to zero, meaning that the solutions satisfy the constraints of (5). Note that, for presentation purposes, all energies have been normalized to have the same final energy. Right: Mean IoU as a function of iterations for the two different models and inference methods. The number of iterations were set to five during training. All results are from the test set of the W EIZMANN H ORSE data set. 654 images, respectively. Following the setting described in Wang et al. [36], we also include additional images for training. These are the images from the NYU V1 dataset that do not overlap with the images in the official validation set. This gives a total of 894 images with semantic label annotations for training. As in [36] we consider 5 classes conveying strong geometric properties: ground, vertical, ceiling, furniture and objects. The CNN part of our model was initialized as the fully convolutional network FCN8s [28] pre-trained on the data. Afterwards we added our CRF-Grad layer and trained the model end-to-end. As shown in Table 1, we achieved superior results for semantic image segmentation on the NYU V2 dataset. Some example segmentations are shown in Fig. 6. Additional examples are included in the supplementary material. 6.3 Cityscapes The C ITYSCAPES dataset [14] consists of a set of images of street scenes collected from 50 different cities. The images are high resolution (1024 × 2048) and are paired with pixel-level annotations of 19 classes including road, sidewalk, traffic sign, pole, building, vegetation and sky. The training, validation and test sets consist of 2975, 500 and 1525 images, respectively. In addition there are 20000 coarsely annotated images that can be used for training. The CNN part of our model was initialized as an LRR network [16] pre-trained on both the fine and the coarse annotations. We then added our CRF-Grad layer and trained the model end-to-end on the finely annotated images only. In Table 1 the results of evaluating our model on the test set are compared to current state of the art. As can be seen, our model is on par although the improvement upon LRR is minor. An interesting aspect of C ITYSCAPES is that it contains classes of thin and vertical objects, e.g., traffic light and pole. What we noticed is that the spatial filters for these classes usually get a more oblong shape. This type of pairwise filters does not add as much energy for switching classes going in the horizontal direction, favoring 11 Input FCN-8s CRF-RNN CRF-Grad Ground truth Fig. 6. Qualitative results on the NYU V2 dataset. Note that the CRF-Grad captures the shape of the object instances better compared to the baselines. This effect is perhaps most pronounced for the paintings hanging on the walls. vertically elongated segmentations. This can be seen in the spatial filter for the class interaction between “terrain” and “traffic light” in Fig. 1. Some example segmentations are shown in Fig. 7. Additional examples as well as class-wise results are included in the supplementary material. Our method got better, or equal, results for 14 of the 19 classes compared to the baseline. 7 Concluding Remarks In this paper, we have introduced a new framework capable of learning arbitrarily shaped pairwise potentials in random fields models. In a number of experiments, we have empirically demonstrated that our developed framework can improve state-of-theart CNNs by adding a CRF layer. We have also seen that the learned filters are not necessarily Gaussian, and may capture other kinds of interactions between labels. In addition, we have shown advantages of our inference method compared to the commonly used mean-field method. A key factor for the success of deep learning and by now a well-established paradigm is that the power of convolutions should be used, especially for the first layers in a CNN. Our work supports that repeated usage of convolutions in the final layers is also beneficial. We also note that our gradient descent steps resemble the highly successful R ES N ET [18], as one step in gradient descent is, in principle, an identity transformation plus a correction term. There are several future research avenues that we intend to explore. In our model, many free variables are introduced and this may lead to over-fitting. One way to compensate would be to collect larger datasets and consider data augmentation. An alternative approach would be to directly encode geometric shape priors into the random fields and thereby reducing the required amount of data. 12 Input LRR LRR + CRF-Grad Ground truth Fig. 7. Qualitative results on the C ITYSCAPES validation set. Black regions in the ground truth are ignored during evaluation. Our CRF models contextual relationships between classes, hence unlike LRR, it does not label “road” as being on top of “sidewalk” (Row 2). Note that the traffic lights are better segmented with the additional CRF-Grad layer. Adding the CRF-Grad layer increased the IoU of the class traffic lights from 66.8 to 68.1. Acknowledgements. This work has been funded by the Swedish Research Council (grant no. 2016-04445), the Swedish Foundation for Strategic Research (Semantic Mapping and Visual Navigation for Smart Robots), Vinnova / FFI (Perceptron, grant no. 2017-01942), ERC (grant ERC-2012-AdG 321162-HELIOS) and EPSRC (grant Seebibyte EP/M013774/1 and EP/N019474/1). References 1. A. Adams, J. Baek, and M. A. Davis. Fast high-dimensional filtering using the permutohedral lattice. Computer Graphics Forum, 2010. 2. A. Arnab, S. Jayasumana, S. Zheng, and P. H. S. Torr. Higher order conditional random fields in deep neural networks. In European Conference on Computer Vision, 2016. 3. D. Belanger and A. McCallum. Structured prediction energy networks. In International Conference on Machine Learning, 2016. 4. A. Blake, P. Kohli, and C. Rother. Markov Random Fields for Vision and Image Processing. MIT Press, 2011. 5. E. Borenstein and S. Ullman. Class-specific, top-down segmentation. In European Conference on Computer Vision, 2002. 6. E. Boros and P.L. Hammer. Pseudo-boolean optimization. Discrete Appl. Math., 123:155– 225, 2002. 7. L. Bottou, Y. Bengio, and Y. Le Cun. Global training of document processing systems using graph transformer networks. In IEEE Conference on Computer Vision and Pattern Recognition, pages 489–494. IEEE, 1997. 8. Y. Boykov, O. Veksler, and R. Zabih. Fast approximate energy minimization via graph cuts. IEEE Transactions on Pattern Analysis and Machine Intelligence, 23(11):1222–1239, 2001. 13 9. S. Chandra and I. Kokkinos. Fast, exact and multi-scale inference for semantic image segmentation with deep gaussian crfs. In European Conference on Computer Vision, 2016. 10. L. Chen, G. Papandreou, I. Kokkinos, K. Murphy, and A. L. Yuille. Semantic image segmentation with deep convolutional nets and fully connected crfs. In International Conference on Learning Representations, 2015. 11. L. Chen, G. Papandreou, I. Kokkinos, K. Murphy, and A. L. Yuille. Deeplab: Semantic image segmentation with deep convolutional nets, atrous convolution, and fully connected crfs. arXiv preprint arXiv:1606.00915, 2016. 12. L.C. Chen, A.G. Schwing, A.L. Yuille, and R. Urtasun. Learning deep structured models. In Int. Conf. Machine Learning, Lille, France, 2015. 13. Y. Chen and X. Ye. Projection onto a simplex. arXiv preprint arXiv:1101.6081, 2011. 14. M. Cordts, M. Omran, S. Ramos, T. Rehfeld, M. Enzweiler, R. Benenson, U. Franke, S. Roth, and B. Schiele. The cityscapes dataset for semantic urban scene understanding. In IEEE Conference on Computer Vision and Pattern Recognition, 2016. 15. A. Desmaison, R. Bunel, P. Kohli, P. H. S. Torr, and M. P. Kumar. Efficient continuous relaxations for dense CRF. In European Conference on Computer Vision, 2016. 16. G. Ghiasi and C. Fowlkes. Laplacian reconstruction and refinement for semantic segmentation. In European Conference on Computer Vision, 2016. 17. R. Girshick, J. Donahue, T. Darrell, and J. Malik. Rich feature hierarchies for accurate object detection and semantic segmentation. In IEEE Conference on Computer Vision and Pattern Recognition, 2014. 18. K. He, X. Zhang, S. Ren, and J. Sun. Deep residual learning for image recognition. In IEEE Conference on Computer Vision and Pattern Recognition, 2016. 19. O. H. Jafari, O. Groth, A. Kirillov, M. Y. Yang, and C. Rother. Analyzing modular cnn architectures for joint depth prediction and semantic segmentation. In International Conference on Robotics and Automation, 2017. 20. V. Jampani, M. Kiefel, and P. V. Gehler. Learning sparse high dimensional filters: Image filtering, dense crfs and bilateral neural networks. In IEEE Conference on Computer Vision and Pattern Recognition, June 2016. 21. Y. Jia, E. Shelhamer, J. Donahue, S. Karayev, J. Long, R. Girshick, S. Guadarrama, and T. Darrell. Caffe: Convolutional architecture for fast feature embedding. arXiv preprint arXiv:1408.5093, 2014. 22. A. Kirillov, D. Schlesinger, S. Zheng, B. Savchynskyy, P.H.S. Torr, and C. Rother. Joint training of generic cnn-crf models with stochastic optimization. In Asian Conference on Computer Vision, 2016. 23. D. Koller and N. Friedman. Probabilistic Graphical Models. MIT Press, 2009. 24. P. Kraehenbuehl and V. Koltun. Parameter learning and convergent inference for dense random fields. In Proceedings of The 30th International Conference on Machine Learning, pages 513–521, 2013. 25. P. Krähenbühl and V. Koltun. Efficient inference in fully connected CRFs with gaussian edge potentials. In Neural Information Processing Systems. 2011. 26. G. Lin, C. Shen, A. Hengel, and I. Reid. Efficient piecewise training of deep structured models for semantic segmentation. In IEEE Conference on Computer Vision and Pattern Recognition, June 2016. 27. Z. Liu, X. Li, P. Luo, C. C. Loy, and X. Tang. Semantic image segmentation via deep parsing network. In International Conference on Computer Vision, 2015. 28. J. Long, E. Shelhamer, and T. Darrell. Fully convolutional networks for semantic segmentation. In IEEE Conference on Computer Vision and Pattern Recognition, 2015. 29. J. Peng, L. Bo, and J. Xu. Conditional neural fields. In Advances in neural information processing systems, pages 1419–1427, 2009. 14 30. S. Ren, K. He, R. Girshick, and J. Sun. Faster R-CNN: Towards real-time object detection with region proposal networks. In Neural Information Processing Systems, 2015. 31. C. Rother, V. Kolmogorov, and A. Blake. ”GrabCut”: Interactive foreground extraction using iterated graph cuts. In ACM Transactions on Graphics, pages 309–314, 2004. 32. A. Schwing and R. Urtasun. Fully connected deep structured networks. In arXiv preprint arXiv:1503.02351, 2015. 33. K. Simonyan and A. Zisserman. Very deep convolutional networks for large-scale image recognition. In International Conference on Learning Representations, 2015. 34. A. Vedaldi and K. Lenc. Matconvnet – convolutional neural networks for matlab. In Proceeding of the ACM International Conference on Multimedia, 2015. 35. V. Vineet, J. Warrell, and P.H.S. Torr. Filter-based mean-field inference for random fields with higher order terms and product label-spaces. In European Conference on Computer Vision, 2012. 36. P. Wang, X. Shen, Z. Lin, S. Cohen, B. Price, and A. Yuille. Towards unified depth and semantic prediction from a single image. In IEEE Conference on Computer Vision and Pattern Recognition, 2014. 37. W. Wang, S. Fidler, and R. Urtasun. Proximal deep structured models. In Neural Information Processing Systems, 2016. 38. S. Zheng, S. Jayasumana, B. Romera-Paredes, V. Vineet, Z. Su, D. Du, C. Huang, and P. Torr. Conditional random fields as recurrent neural networks. In International Conference on Computer Vision, 2015. 15 Supplementary Material Proof of Proposition 1 Let E(x∗ ) and E(q ∗ ) denote the optimal values of (5), where x∗ is restricted to boolean values. Then, E(x∗ ) = E(q ∗ ). Proof. We will show that for any real q, one can obtain a binary x such that E(x) ≤ E(q). In particular, it will be true for x∗ and q ∗ , which implies E(x∗ ) = E(q ∗ ). Let q be given, and let x ∈ LN . One may define E m (x, q) = E(x1 , . . . , xm , qm+1 , . . . , qN ) such that each xi or qi is a vector with entries such as qi:λ or xi:λ , but for each i only one value xi:λ is non-zero (and equal to 1). Since E 0 = E(q) and E N = E(x) it will be sufficient to find a x such that E m (x, q) ≤ E m−1 (x, q) for all m. The required x will be constructed one element at a time. The key observation is that E m is multilinear in the qi . Then, it follows that E m−1 (x, q) = E(x1 , . . . , xm−1 , qm , . . . qN ) X = qm:xm E(x1 , . . . , xm , qm+1 , . . . qN ). xm ∈L P Here, xm is treated as a variable and x1 , . . . , xm−1 are fixed. Since xm ∈L qm:xm = 1 there must be at least one choice of xm such that E m−1 (x, q) ≥ E(x1 , . . . , xm , qm+1 , . . . qm ) = E m (x, q). Mean-Field Objective In this section, we give a brief derivation of what is minimized with the mean-field method. The key idea behind the method is to approximate a complex probability distribution P by a simpler one Q that one can solve (find its mode), using the simpler distribution as a stand-in for the actual probability distribution (MRF) of interest. As previously, we consider a probability distribution P for a random field, given by the Gibbs distribution. The probability of an assignment x ∈ LN is P (x) = 1 exp (−E(x)) . Z (11) A natural measure commonly used as a measure of distance between two probability distributions P and Q is the KL divergence D(Q k P ) defined by D(Q k P ) = X  Q(x) log x∈LN =− X Q(x) P (x)  Q(x) log P (x)+ x∈LN X x∈LN 16 (12) Q(x) log Q(x). Now, plugging in the form of the probability P (x) given in (11) into (12), we obtain D(Q k P ) =   X X 1 − Q(x) log exp (−E(x)) + Q(x) log Q(x) Z x∈LN x∈LN X X = Q(x)E(x) + log Z + Q(x) log Q(x), x∈LN x∈LN P where we have used the fact that x∈LN Q(x) = 1. Because log Z is a constant, minimizing the KL divergence between these two distributions is equivalent to minimizing the following quantity: X X Q(x)E(x) + Q(x) log Q(x). (13) x∈LN x∈LN The first term is equal to the expected value of the energy E(x) under the probability distribution Q; for now we will write this as EQ [E]. Now, P consider the second term. The entropy of a probability distribution Q is equal to − x∈LN Q(x) log Q(x). Writing the entropy of Q as H(Q), (13) takes the form EQ [E] − H(Q), (14) so the quantity is equal to the expectation of the Gibbs energy under distribution Q minus the entropy of Q. Hyperparameter Settings Weizmann Horse All the models presented in the experiments section were trained end-to-end with learning rate of 10−3 (normalized by the number of pixels), momentum 0.9, weight decay 5 · 10−3 and batch size 20. The size of the spatial filters for these runs were 9 × 9 if not specified as other. The number of iterations were set to 5, step size to 0.5 and unary weight was initialized as 0.5. For the models with bilateral filter s, the number of neighbours each pixel interacts with in each dimension, were set to 1. NYU V2 The model used on the NYU V2 data set was trained with learning rate 10−11 (not normalized), momentum 0.99, weight decay 0.005 and batch size 10. The size of the spatial filters were set to 9 × 9 and the bilateral filters to s = 1. The number of iterations were set to 5, step size to 0.5 and unary weight was initialized as 0.5. Cityscapes The model used on the C ITYSCAPES data set was trained with a learning rate of 10−3 (normalized by the number of pixels), momentum 0.9 and weight decay 5 · 10−3 . The size of the spatial filters for these runs were 9 × 9 and the bilateral filters to s = 1. The number of iterations were set to 5, step size to 0.5 and unary weight was initialized as 0.5. 17 Simplex Projection L As P mentioned in the paper we want to project our values onto the simplex 4 satisfying q = 1 and 0 ≤ q ≤ 1 for each step in our gradient descent algorithm. This i:λ λ∈L i:λ is done following the method presented by Chen et al. [13] which is summarized in Algorithm 2. Note that this projection is done individually for each pixel i, for derivation of this algorithm we refer to the article. 1. Sort q̃i ∈ RL inPascending order and set k = L - 1 L q̃i:j −1 , If ti ≥ q̃i:k set t̂ = ti and go to step 4, otherwise set 2. Compute ti = j=k+1 L−k k ← k −P 1 and redo step 2, if k = 0 go to step 3 L q̃i:j −1 3. Set t̂ = j=1L  4. Return qi , where qi:λ = max q̃i:λ − t̂, 0 , λ ∈ L Algorithm 2: Algorithm 2. Projection of q̃i ∈ RL onto the simplex 4L satisfying P λ∈L qi:λ = 1 and 0 ≤ qi:λ ≤ 1. In reality we use a leaky version of the last step of the projection algorithm, i.e. instead of the max(·, 0) operator we use the following function  fα (q̃i:λ ) = q̃i:λ − t̂  0 ≤ q̃i:λ − t̂ α q̃i:λ − t̂ q̃i:λ − t̂ < 0 (15) where α is a parameter controlling the level of leakage. Note that for α = 0 we get the the strict max(·, 0) operator. As previously mentioned, the projection is done individually for each pixel. It can be described as a function f (q̃) : RL → RL , which Jacobian has the elements     α 1 − ∂∂q̃t̂µ q̃µ − t̂ < 0   µ=λ   1 − ∂ t̂ ∂fλ q̃µ − t̂ ≥ 0 ∂ q̃µ (16) = (  ∂ q̃µ  −α ∂∂q̃t̂µ q̃µ − t̂ < 0   µ 6= λ   − ∂∂q̃t̂µ q̃µ − t̂ ≥ 0 1 where ∂∂q̃t̂µ = L−k if q̃µ > t̂ and 0 otherwise (L and k defined as in Algorithm 2). Knowing the Jacobian, the error derivatives with respect to the input can be computed during back propagation. The reason for introducing the leaky version is to avoid error derivatives becoming zero during back propagation. A non-zero α was found to facilitate the training process considerably with the drawback that we do not necessarily satisfy the constraints in (5). However, one could set α to zero during inference to strictly satisfy (5). 18 Convergence analysis Since the forward operation of the CRF-Grad layer performs gradient descent, we are interested in knowing how many iterations are needed to converge. In Fig. 8 we have plotted the CRF energy as a function of the number of iterations on the W EIZMANN H ORSE data set for the different models. In addition Fig. 9 shows the mean IoU as a function of the number of iterations for the W EIZMANN H ORSE test data. Both of these results point to the fact that it is sufficient to run the model for about five iterations and that running it further would not increase the result considerably. It also might be interesting to investigate the intermediate states q t . in Fig. 10 the intermediate states of the CRF-Grad layers is shown. This figure gives a good indication on affect the CRF-Grad layer has. As can be seen in the figure, each step refines the segmentation slightly, removing spurious outlier pixels classified as horse, in addition to refining the boundaries slightly. Also included in the supplementary material is short movie, crfgd2 mov.avi, showing how the CRF energy decreases with each step of our projected gradient descent algorithm. For this example a Potts model is used and the projected gradient descent solution is compared to the globally optimal solution obtained by graph cut. Error Derivatives for the CRF-Grad layer In this section, we will explicitly formulate the error derivative necessary to train our deep structure model jointly. The notation used in the section is not very strict. Derivatives, gradients and jacobians are all referred to as derivatives. Denoting the output of our CRF-Grad layer y we need expressions for the derivatives ∂y ∂z , where z is the output from the CNN and hence also the input to the CRF-Grad layer. In addition we need ∂y ∂y ∂y , ∂w and ∂w to be able to update the weights of the layer. To simto calculate ∂w u s b plify the notation we abbreviate the update step by q t+1 = f (q t , z, I, w). Note that the output y = q T where T is the total number of iterations for the RNN. We have ∂y ∂wu ∂y ∂ws ∂y ∂wb ∂y ∂z = = = = ∂y ∂f (qT −1 ) ∂y ∂f (q0 ) + . . . + ∂q T ∂wu ∂q 1 ∂wu T −1 ) ∂y ∂f (q ∂y ∂f (q0 ) + . . . + ∂q T ∂ws ∂q 1 ∂ws T −1 ∂y ∂f (q ) ∂y ∂f (q0 ) + . . . + ∂q T ∂wb ∂q 1 ∂wb 0 ∂y ∂q ∂y ∂ψu + , ∂q 0 ∂z ∂ψu ∂z (17) (18) (19) (20) where ψu denote the unary part of the CRF energy function. Note that ∂y ∂y ∂f (qt−1 ) = ) ∂q t−1 ∂q t ∂q t−1 (21) To be able to calculate these we need the derivatives of the function f with respect to qt , wu , ws and wb . We denote the spatial and bilateral filtering operations as ψs ∗ q t 19 and ψb ∗ q t respectively. An update step can then be written as q t+1 = Proj4L (qt − γ(ψu + ψs ∗ q t + ψb ∗ q t )) = Proj4L (q̃t+1 ). And the aforementioned derivatives become ∂f =Proj04L (q̃t+1 ) ∂qt  · 1 − γ(ψu + ψs ∗ qt + ψb ∗ qt )   ∂(ψs ∗ qt ) ∂(ψb ∗ qt ) · + , ∂qt ∂qt (22) for q t , and for the weights ∂f = Proj04L (q̃t+1 )· ∂wu  ∂ψu −γ(ψu + ψs ∗ qt + ψb ∗ qt · , ∂wu ∂f = Proj04L (q̃t+1 )· ∂ws  ∂(ψs ∗ qt ) , −γ(ψu + ψs ∗ q + ψb ∗ q · ∂ws t  ∂(ψb ∗ qt ) −γ(ψu + ψs ∗ qt + ψb ∗ qt · , ∂wb t (24) t ∂f = Proj04L (q̃t+1 )· ∂wb t (23) (25) t t s ∗q ) b ∗q ) b ∗q ) ∂(ψs ∗q ) Note that ∂(ψ∂q , ∂(ψ∂q , ∂ws and ∂(ψ∂w can be calculated using the backt t b ward routines for a standard convolutional layer and bilateral filtering layer described in the main paper. Additional Results In this section we present some additional results from the different datasets. Class-wise results for the C ITYSCAPES dataset is presented in Table 2. For the W EIZMANN H ORSE dataset these results can be seen in Fig. 11, for the C ITYSCAPES dataset in Fig. 12 and for the NYU V2 dataset in Fig. 13. 20 terrain vegetation traffic sign traffic light pole fence wall building sidewalk road LRR-4x CRF-Grad 95 95 bicycle motorcycle train bus truck car rider person sky LRR-4x 97.9 81.5 91.4 50.5 52.7 59.4 66.8 72.7 92.5 70.1 CRF-Grad 97.9 81.3 91.4 51.4 52.9 60.65 68.1 73.5 92.6 69.1 81.3 60.1 94.3 51.2 67.7 54.6 55.6 69.6 81.6 59.5 94.1 45.5 68.4 56 56 70.2 Table 2. Class-wise results compairing our model to the baseline, LRR. The results are presented as IoU (%). × 10 5 × 10 5 spatial (gaussian) spatial -4 mean per image -4.1 -5 -4.2 -5.1 -5.2 Energy -4.3 Energy mean per image -4.9 -4.4 -5.3 -5.4 -4.5 -5.5 -4.6 -5.6 -5.7 -4.7 -5.8 0 1 2 3 4 5 6 7 0 iteration full (gaussian) × 10 4 1 2 3 4 5 -5.5 mean per image 6 7 iteration full × 10 4 mean per image -2.6 -6 Energy Energy -2.7 -2.8 -2.9 -6.5 -3 -3.1 -7 0 1 2 3 4 5 6 7 iteration 0 1 2 3 4 5 6 7 iteration Fig. 8. CRF energy, as defined in (5), plotted as a function of iterations of the gradient descent method. These energies are calculated while running the trained models on the W EIZMANN H ORSE dataset, The thin blue lines shows the imagewise energy change while the thicker red line show the mean. For these calculations the leak factor was set to zero, meaning that the solutions satisfy the constraints of (5). Note that, for presentation purposes, all energies have been normalized to have the same final energy. 21 spatial (gaussian) 0.8135 spatial 0.821 0.82 0.813 0.819 0.818 mean IoU mean IoU 0.8125 0.812 0.817 0.816 0.815 0.814 0.8115 0.813 0.812 0.811 0 1 2 3 4 5 6 0 7 1 2 4 5 6 7 4 5 6 7 full full (gaussian) 0.835 3 iteration iteration 0.85 0.84 0.83 0.83 mean IoU mean IoU 0.825 0.82 0.82 0.81 0.8 0.815 0.79 0.78 0.81 0 1 2 3 4 5 6 7 0 1 2 3 iteration iteration Fig. 9. Mean IoU plotted as a function of iterations for the W EIZMANN H ORSE test data. Note that, for the non-gaussian versions of the model, the performance of the layer does not increase after six iterations. The number of iterations were set to five during training. Input zhorse 1 qhorse 2 qhorse 3 qhorse 4 qhorse 5 qhorse Ground truth Fig. 10. Visualization of intermediate states of the CRF-Grad layer for the W EIZMANN H ORSE dataset. Note how each step of the projected gradient descent algorithm refines the segmentation slightly, removing spurious outlier pixels classified as horse. 22 Fig. 11. Qualitative results on the W EIZMANN H ORSE dataset. From left: Original image, Ground truth, FCN-8s segmentation results, CRF-Grad segmentation results (spatial kernel only), CRFGrad segmentation results (spatial and bilateral kernels). Note how adding the CRF-Grad layer gives more refined segmentations, removing spurious outlier pixels previously classified as horse. 23 Input LRR LRR + CRF-Grad Ground truth Fig. 12. Qualitative results on the C ITYSCAPES validation set. Black regions in the ground truth are ignored during evaluation. Our CRF models contextual relationships between classes, hence unlike LRR, it does not label “road” as being on top of “sidewalk” (Row 2). Note that the traffic lights are better segmented with the additional CRF-Grad layer. Adding the CRF-Grad layer increased the IoU of the class traffic lights from 66.8 to 68.1. 24 Input FCN-8s CRF-RNN CRF-Grad Ground truth Fig. 13. Qualitative results on the NYU V2 dataset. Note that the CRF-Grad captures the shape of the object instances better compared to the baselines. This effect is perhaps most pronounced for the paintings hanging on the walls. 25
1cs.CV
arXiv:1705.09542v1 [math.ST] 26 May 2017 An Inverse Problem for Infinitely Divisible Moving Average Random Fields W. Karcher, S. Roth, E. Spodarev, C. Walk April 2, 2018 Ulm University Abstract Given a low frequency sample of an infinitely divisible moving average R random field { Rd f (x−t)Λ(dx); t ∈ Rd } with a known simple function f , we study the problem of nonparametric estimation of the Lévy characteristics of the independently scattered random measure Λ. We provide three methods, a simple plug-in approach, a method based on Fourier transforms and an approach involving decompositions with respect to L2 -orthonormal bases, which allow to estimate the Lévy density of Λ. For these methods, the bounds for the L2 -error are given. Their numerical performance is compared in a simulation study. Keywords: Infinitely divisible random measure; stationary random field; Lévy process, moving average; Lévy density; Fourier transform; Banach fixed–point theorem. 1 Introduction Let Λ be a stationary infinitely divisible independently scattered random measure with Lévy characteristics (a0 , b0 , v0 ), where a0 ≥ 0, b0 ∈ R and v0 is a Lévy density. Let furthermore X = {X(t); t ∈ Rd } be a moving average infinitely divisible random field on Rd defined by X(t) = Z Rd f (x − t)Λ(dx), 1 t ∈ Rd , (1) An Inverse Problem for ID Moving Averages with Lévy characteristics (a1 , b1 , v1 ), where f = nk=1 fk 1I∆k is a simple function. Suppose a sample (X(t1 ), . . . , X(tN )) from X is available. The problem studied in this paper is the nonparametric estimation of (a0 , b0 , v0 ). For any simple function f with congruent sets ∆k , X(t) in (1) has the same distribution as a linear combination of i.i.d. infinitely divisible random variables. Therefore, existence and uniqueness of a characteristic triplet (a0 , b0 , v0 ) with the property that a certain linear combination of independent random variables with the corresponding infinitely divisible distribution leading to a random variable with Lévy characteristics (a1 , b1 , v1 ) becomes a characterization problem for such distributions. For certain distributions, namely the Poisson and the Gaussian one as well as a mixture of both, all possible distributions for the summands in the linear combination can be described (see e.g. [1]). The disadvantage of those characterization theorems is that they do not give any information about the involved parameters (expectation and variance of each summand) and so it is not possible to derive sufficient conditions for the existence of a solution in terms of the kernel function f . Therefore, to solve the inverse problem, we prefer to use concrete relations between the characteristic triplets of X and Λ (Section 3) given in terms of f . P The recent preprint [2] covers the case d = 1 estimating the Lévy density v0 of the R integrator Lévy process {Ls } of a moving average process X(t) = R f (t − s) dLs , t ∈ R. It is assumed that E L20 < ∞. The estimate is based on the inversion of the Mellin transform of the second derivative of the cumulant of X(0). A uniform error bound as well as the consistency of the estimate are given. It is not assumed that f is simple, however, main results are subject to a number of quite restricting integrability assumptions onto x2 v0 (x) and f as well as mixing properties of {Ls } that are tricky to check. Additionally, the logarithmic convergence rate shown there (cf. [2, Corollary 1]) is too slow. In our approach, we develop the ideas of [3] and use Banach fixed–point theorem combined with a recursive iteration procedure (Theorem 4.1) to give sufficient conditions for the existence of a (unique) solution of our (generally speaking, ill– posed) inverse problem v1 7→ v0 . We consider simple functions f since 1. in applications, f is mainly discretely sampled, 2. any f ∈ L1 (Rd ) can be approximated in the k · k1 –norm by a sequence of simple f (m) ∈ L1 (Rd ) (attaining a finite number of values) arbitrarily well, 3. this allows us to use relatively simple arguments in the proofs and to avoid complex assumptions that are not easy to verify, 4. the L2 –convergence rate of our estimates of v0 to its true value is O(N −1 ), cf. Corollaries 5.2 and 5.3. 2 An Inverse Problem for ID Moving Averages The case of arbitrary integrable f is considered in our forthcoming paper [4]. This paper is organized as follows: Section 2 gives an introduction to the theory of infinitely divisible random measures and stochastic integrals as well as a short overview on m-dependent and φ-mixing random fields together with some moment inequalities (cf. Section 2.3). In Section 3, we describe the inverse problem in detail and give formulas for the relationship between the characteristics (a0 , b0 , v0 ) and (a1 , b1 , v1 ). In Section 4, we obtain sufficient conditions for the existence and uniqueness of the solution of the direct problem, i.e. we propose conditions under which the mapping (a0 , b0 , v0 ) 7→ (a1 , b1 , v1 ) is a bijection. It turns out that this holds true if either one of the coefficients f1 , . . . , fn dominates all the others or one of them repeats often enough in some sense. Estimates for the characteristic Lévy triplet of X are given in Section 5 for pure jump infinitely divisible random fields. Here we use the ideas of [5], [6] and [7] originally designed to estimate the Lévy density of Lévy processes. The main result of this section is the proof of the upper bound for the L2 -error of the proposed estimator without the assumption of independence of observations X(t1 ), . . . , X(tN ). The estimation error remains of the same structure as in the Lévy process case if the random field X is assumed to be m-dependent or φ-mixing. For the ease of reading, long proofs of the results of this section are moved to Appendix. Section 6 provides three estimation approaches for the density v0 of Λ. The first method is a simple plug-in approach. The second one, the Fourier method, is based on the idea of estimating first the Fourier transform of v0 followed by another plug-in procedure. The last method uses orthonormal bases in the Hilbert space L2 [−A, A], A > 0, for a representation of the solution v0 of the inverse problem. After approximating v0 by cutting off its expansion, the coefficients can be estimated by solving a system of linear equations. For all our methods, we propose upper bounds for the L2 -estimation error. In the last section, the performance of the methods is compared by numerical simulations. 2 Preliminaries Introduce some notation that will be used throughout this paper. By B(Rd ) we denote the Borel σ-field on the d-dimensional Euclidean space Rd . The Lebesgue measure on Rd is denoted by νd . We briefly write νd (dx) = dx if we integrate w.r.t. νd on Rd . The collection of all bounded Borel sets in Rd will be denoted by E0 (Rd ). For any measurable space (M, M, µ) we denote by Lα (M ), 1 ≤ α < ∞, the space of all M|B(R)-mesurable functions f : M → R R R with M |f |α (x)µ(dx) < ∞. Equipped with the norm ||·||α = ( M |f |α (x)µ(dx))1/α , 3 An Inverse Problem for ID Moving Averages Lα (M ) becomes a BanachR space and even in the case α = 2 a Hilbert space with scalar product hf, giα = M f (x)g(x)µ(dx), for any f, g ∈ L2 (M ). With L∞ (M ) (i.e. if α = ∞) we denote the space of all real valued bounded functions on M . In case (M, M, µ) = (R, B(R), ν1 ) we denote by H δ (R) = {f ∈ L2 (R) : Z |Ff |2 (x)(1 + x2 )δ dx < ∞} R the Sobolev space of order δ > 0 equipped with the Sobolev norm ||f ||H δ = ||Ff (·)(1 + ·2 )δ/2 ||2 , where FR is the Fourier transform on L2 (R). For f ∈ L1 (R), Ff is defined by Ff (x) = R eitx f (t)dt, x ∈ R. If (M, M, µ) = (N, 2N , µ) or (M, M, µ) = ({1, . . . , n}, 2{1,...,n} , µ), n ∈ N, with µ being the counting measure, then we write as usual lα (M ) instead of Lα (M ) and all integrals above become sums. Throughout the rest of this paper (Ω, A, P ) denotes a probability space. Note that in this case Lα (Ω) is the space of all random variables with finite α-th moment as well as ||X||α = (E|X|α )1/α , if 1 ≤ α < ∞ and ||X||α = supω∈Ω X(ω) if α = ∞, for any X ∈ Lα (Ω). For an arbitrary set A we introduce furthermore the notation card(A) for its cardinality. Let suppf = {x ∈ Rd : f (x) 6= 0} be the support set of a function f : Rd → R. Denote by diam(A) = sup{kx − yk∞ : x, y ∈ A} the diameter of a bounded set A ⊂ Rd . 2.1 ID Random Measures and Fields Recall some definitions and give a brief overview of infinitely divisible (ID) random measures and fields. Let Λ = {Λ(A); A ∈ E0 (Rd )} be an ID random measure on some probability space (Ω, A, P ), i.e. a random measure such that 1. for each sequence (Em )m∈N of disjoint sets in E0 (Rd ) it holds (a) Λ(∪∞ m=1 Em ) = P∞ m=1 d Λ(Em ) a.s., whenever ∪∞ m=1 Em ∈ E0 (R ), (b) (Λ(Em ))m∈N is a sequence of independent random variables. 2. the random variable Λ(A) has an ID distribution for any choice of A ∈ E0 (Rd ). Due to the infinite divisibility of the random variable Λ(A), its characteristic function, which will be denoted by ϕΛ(A) , has a Lévy-Khintchin representation which will assumed to be of the form ϕΛ(A) (t) = exp {νd (A)K(t)} , 4 A ∈ E0 (Rd ), (2) An Inverse Problem for ID Moving Averages with Z   1 2 eitx − 1 − itx1I[−1,1] (x) v0 (x)dx, K(t) = ita0 − t b0 + 2 (3) R where a0 ∈ R, 0 ≤ b0 < ∞ and v0 is a Lévy density, i.e. R min{1, x2 }v0 (x)dx < ∞. The triplet (a0 , b0 , v0 ) will be referred to as Lévy characteristic of Λ. It uniquely determines the distribution of the process Λ. A general form for the characteristic function of any ID random measure can be found in [8, p. 456]. The particular structure of the characteristic function in (2) means that the random measure Λ is stationary with control measure λ : B(R) → [0, ∞) given by R   λ(A) = νd (A) |a0 | + b0 + Z min{1, x2 }v0 (x)dx , A ∈ E0 (Rd ). R Now we can define the stochastic integral w.r.t. the ID random measure Λ. 1. Let f = nj=1 xj 1IAj be a real simple function on Rd , where Aj ∈ E0 (Rd ) are pairwise disjoint. Then for every A ∈ B(Rd ) we define P Z f (x)Λ(dx) = n X xj Λ(A ∩ Aj ). j=1 A 2. A measurable function f : (Rd , B(Rd )) → (R, B(R)) is said to be Λ-integrable, if there exists a sequence (f (m) )m∈N of simple functions as in 1. such that (a) f (m) → f , λ-a.e. R  (b) for every A ∈ B(Rd ), the sequence A f (m) (x)Λ(dx) probability as m → ∞. In this case we set Z Z f (x)Λ(dx) = P-lim m→∞ m∈N converges in f (m) (x)Λ(dx). A A A useful characterization of Λ-integrability is given in [8, Theorem 2.7]. Now let {f (t − ·); t ∈ Rd } be a family of Λ-integrable functions induced by the Borel measurable map f : Rd → R. Then we define the ID moving average random field X = {X(t); t ∈ Rd } by X(t) = Z f (t − x)Λ(dx), Rd 5 t ∈ Rd . (4) An Inverse Problem for ID Moving Averages A random field is called ID if its finite dimensional distributions are ID. The random field X defined in (4) is stationary and ID and the characteristic function of ϕX(0) of X(0) is given by ϕX(0) (u) = exp   Z    K(uf (s)) ds ,     Rd with K given in (3). It is easy to see that Z Rd Z 1 2 K(uf (s)) ds = iua1 − u b1 + (eiux − 1 − iux1I[−1,1] (x))v1 (x) dx 2 (5) R with a1 = Z U (f (s))ds, b1 = b0 Rd v1 (x) = Z f 2 (s) ds (6) Rd ! 1 x v0 ds, |f (s)| f (s) Z S (7) where a1 ∈ R, b1 ≥ 0, v1 is the Lévy density of X(0), S = supp(f ) = {s ∈ Rd : f (s) 6= 0} denotes the support of f and the function U is defined via   U (u) = u a0 + Z h i x 1I[−1,1] (ux) − 1I[−1,1] (x) v0 (x)dx . (8) R The triplet (a1 , b1 , v1 ) is again referred to as Lévy characteristic (of X(0)) and determines the distribution of X(0) uniquely. Note that due to Λ-integrability of f all integrals above are finite. This immediately implies that f ∈ L1 (Rd )∩L2 (Rd ). For details on the theory of infinitely divisible measures and fields with spectral representation as well as proofs for the above stated facts we refer the interested reader to [8]. 2.2 m-Dependent and φ-Mixing Random Fields A random field X = {X(t), t ∈ T }, T ⊆ Rd defined on (Ω, A, P ) is called mdependent if for some m ∈ N and any finite subsets U and V of T the random vectors (X(u))u∈U and (X(v))v∈V are independent, whenever ||u − v||∞ = max |ui − vi | > m, 1≤i≤d 6 An Inverse Problem for ID Moving Averages for all u = (u1 , . . . , ud )> ∈ U and v = (v1 , . . . , vd )> ∈ V . Note that a random field X as in (4) is m-dependent, if the support S of f is bounded with m ≥ diam(S). Besides, we define the notion of φ-mixing random fields. The mixing coefficient φ is defined as follows. For any U ⊂ T , let FU = σ(X(t), t ∈ U ) be the σ–field generated by random variables X(t), t ∈ U . Let furthermore U and V be two sub-σ-fields of A. Define n o φ(U, V) := sup |P (V |U ) − P (V )| : V ∈ V, U ∈ U, P (U ) 6= 0 (9) and for k, l, r ∈ N n o φk,l (r) := sup φ(FΓ1 , FΓ2 ) : card(Γ1 ) ≤ k, card(Γ2 ) ≤ l, d(Γ1 , Γ2 ) ≥ r , (10) where d(Γ1 , Γ2 ) := min{||i − j||∞ : i ∈ Γ1 , j ∈ Γ2 } for Γ1 , Γ2 ⊂ T . A random field X = {X(t), t ∈ T } on (Ω, A, P ) is called φ-mixing or uniform mixing if lim φk,l (r) = 0 (11) r→∞ for any k, l ∈ N. Equation (11) is called φ-mixing condition, see e.g. [9] for more details on mixing. 2.3 Moment and Exponential Inequalities for Random Fields In the literature, one can find many moment and exponential inequalities for sums of independent and identically distributed random variables, e.g., the classical Rosenthal inequality [10] or the Bernstein inequality [11]. Similar inequalities hold true for random fields. For i ∈ Zd define the set Vi1 = {j ∈ Zd : j <lex i}, where <lex denotes the lexicographic order. Let Vik = Vi1 ∩{j ∈ Zd : ||i − j||∞ ≥ k} for k ≥ 2. For f (X(t)) ∈ L1 (Ω) set for k ∈ N h i Ek [f (X(t))] := E f (X(t))|FVtk . Figure 1 shows the sets Vt1 and Vtk for some t = (t1 , t2 ) ∈ Z2 . The following two results can be found in [12, pp. 12-14]. Theorem 2.1. Let X = {X(t), t ∈ Zd } be a centered and square-integrable random field. Let U ⊂ Zd be a finite subset. Then for any p ≥ 2 it holds p !1/p E X X(t) !1/2 ≤ 2p t∈U where bt,α (X) = kX(t)2 kα + α ≥ 1. X bt,p/2 (X) , t∈U P k∈Vt1 kX(k) Ekk−tk∞ [X(t)]kα , for t ∈ U and for any 7 An Inverse Problem for ID Moving Averages (b) Vtk = Vt1 ∩ {j ∈ Z2 : kt − jk∞ ≥ k} (a) Vt1 = {j ∈ Z2 : j <lex t} Figure 1: The sets Vt1 and Vtk for some t = (t1 , t2 ) ∈ Z2 and k ∈ N. Theorem 2.2. Let X = {X(t), t ∈ Zd } be a field of bounded and centered random P variables. Set b = t∈U bt,∞ (X). Then for any positive and real x it holds P ( ) 1 x2 X(t) > x ≤ exp − . e 4eb t∈U  X Note that Theorem 2.1 and Theorem 2.2 are extensions of Burkholder’s [13] and Azuma’s [14] inequality for martingales. The next theorem [9, p. 32] states a Rosenthal-type inequality for φ-mixing random fields. Theorem 2.3. Let X = {X(t), t ∈ Zd } be a random field. For p ≥ 2 let c be the smallest even integer such that c ≥ p. Assume ∞ X (r + 1)d(c−u+1)−1 [φu,v (r)]1/c < ∞ (12) r=1 for all u, v ∈ N with u + v ≤ c, u, v ≥ 2. Let U be a finite subset of Zd . If X(t) belongs to Lp (Ω) and is centered for all t ∈ U , then there exists a positive constant C that depends on p and on the mixing coefficient φu,v (r) of X(t) such that p E X t∈U X(t) ≤ C · max ( X p E |X(t)| , t∈U X E |X(t)| t∈U Additionally, the following result can be found in [12, p. 15]. 8 2 p/2 ) . An Inverse Problem for ID Moving Averages Theorem 2.4. Let X = {X(t), t ∈ Zd } be a strictly stationary field of bounded and centered random variables. Take h ≥ kX(0)k∞ and set B(φ) = X φ∞,1 (|j|) < ∞. (13) j∈Zd \0 For any at ∈ [−1, 1], t ∈ Zd set A(U ) := real x we have P 3 P t∈U |at | for U ⊂ Zd . For any positive ( ) 1 x2 at X(t) > x ≤ exp − . e 4(1 + B(φ))A(U )eh2 t∈U  X Inverse Problem In this section, we give a description of the inverse problem treated in this paper. Let Λ = {Λ(A), A ∈ E0 (Rd )} be a homogeneous ID random measure with Lévy P characteristics (a0 , b0 , v0 ). Consider f = nk=1 fk 1I∆k to be a simple function, where fk ∈ R\{0} and ∆k ∈ E0 (Rd ) pairwise disjoint, k = 1, . . . , n. Assume furthermore X = {X(t), t ∈ Rd } to be an ID moving average random field of the form X(t) = Z f (t − x)Λ(dx) = n X fk Λ(t − ∆k ), t ∈ Rd , (14) k=1 Rd where t − A = {t − x : x ∈ A} ⊂ Rd , t ∈ Rd for an arbitrary set A. The Inverse Problem. Given N ∈ N observations X(t1 ), . . . , X(tN ) at points t1 , . . . , tN ∈ Rd of the random field X, estimate the Lévy triplet (a0 , b0 , v0 ) of the ID random measure Λ. Formulas (6) and (7) then become a1 = n X U (fk )νd (∆k ), k=1 n X b1 = b0 n X fk2 νd (∆k ), k=1 ! νd (∆k ) x v1 (x) = v0 , fk k=1 |fk | x ∈ R\{0}, (15) with U defined in (8). For known a1 , b1 , v0 , the above equations are easily solvable w.r.t. a0 and b0 , thus providing an estimation approach for a0 and b0 . So, given v1 , the main point is now to find a solution v0 of the last equation. In the next section, we give some sufficient conditions under which a solution exists and is unique. 9 An Inverse Problem for ID Moving Averages 4 Existence and Uniqueness of a Solution for v0 In the following, we assume w.l.o.g. that νd (∆k ) = 1 for all k = 1, . . . , n. Typically it is common to estimate xn v1 (x) rather than v1 (x) itself, since many of the estimators for Lévy densities are based on derivatives of the Fourier transform (in the context of Lévy processes, see e.g. [5, 6, 7]). For this purpose let h : R → R be a measurable function such that min{1, ·2 }g(·)/h(·) ∈ L1 (R) for any g ∈ L2 (R), (16) s(y) = sup{|h(x)|/|h(yx)|)} < ∞ for any y 6= 0. (17) x A sufficient condition for (16) to hold is Z R min{1, x4 } dx < ∞. h2 (x) (18) Indeed, the Cauchy-Schwarz inequality yields !1/2 Z g(x) min{1, x4 } min{1, x } dx ≤ dx ||g||2 < ∞. h(x) h2 (x) R R Z 2 Examples of functions h satisfying (16)–(18) are h(x) = 1, h(x) = |x|β , β ∈ (1/2, 5/2) and h(x) = xβ , β = 1, 2. Consider the modified equation (hv1 )(x) = n X 1 h(x) (hv0 )(x/fk ). k=1 |fk | h(x/fk ) (h) (19) (h) It is understood in L2 (R)-sense, where it is assumed that g0 = hv0 and g1 = hv1 are both in L2 (R). Let Q = {1 ≤ k ≤ n : fk = f1 } be the set of all indices of coefficients fk that coincide with f1 . Denote by n1 = card(Q) its cardinality. Define sk = s(f1 /fk ), k = 1, . . . , n. (20) The following theorem states conditions, under which equation (19) has a unique (h) solution for fixed g1 ∈ L2 (R). Theorem 4.1. Let a function h : R → R be given as above. Then equation (19) (h) (h) has a unique solution g0 ∈ L2 (R) for any g1 ∈ L2 (R) if e(f, h) = 1 X sk · (|f1 |/|fk |)1/2 < 1. n1 k:fk 6=f1 10 (21) An Inverse Problem for ID Moving Averages The solution is given by the formula (h) g0 (·) = + |f1 | h(·) (h) g (f1 ·) n1 h(f1 ·) 1 ∞ X (22) (|f1 |/n1 )j+1 h(·) f1j+1  j+1  g1(h) · . |fi1 . . . fij | h f1 · f i 1 . . . f ij fi ...fi ! (−1) j=1 j X ... X i1 :fi1 6=f1 ij :fij 6=f1 1 j (h) Proof. Let g1 ∈ L2 (R). Define the operator ϕg(h) : L2 (R) → L2 (R) by 1 ! X |f1 | h(·) |f1 | h(·) (h) f1  r ϕg(h) (r) = g1 (f1 ·) − · f 1 1 n1 h(f1 ·) fk k:fk 6=f1 n1 |fk | h fk · Then formula (19) yields a fixed point of ϕg(h) , i.e., is a solution of equation 1 (h) (h) g0 = ϕg(h) (g0 ). (23) 1 It is straight forward to see that for any functions u1 , u2 ∈ L2 (R) it holds ||ϕg(h) (u1 ) − ϕg(h) (u2 )||2 ≤ e(f, h)||u1 − u2 ||2 , 1 1 i.e. ϕg(h) is a contraction. By Banach fixed-point theorem there exists a unique 1 (h) solution g0 ∈ L2 (R) to the equation (23) which shows the first part of the theorem. (h) Relation (22) can easily be obtained by iterating equation (23) w.r.t. g0 . Remark 4.2. Note that the choice of f1 in this setting is arbitrary. The statement of Theorem 4.1 does not depend on a certain order of the coefficients f1 , . . . , fn . In particular, this means that f1 in the definitions of Q and n1 can be replaced by any other coefficient fj0 , j0 ∈ {2, . . . , n}. Consequently, substituting f1 by fj0 (h) in Theorem 4.1 leads to the same solution g0 . Indeed, let fj , j 6= 1 be any (h) other coefficient that fulfills the conditions of Theorem 4.1, and let ḡ0 be the corresponding solution of (19). Then 0= n X 1 h(x) (h) (h) (g0 − ḡ0 )(x/fk ) |f | h(x/f ) k k k=1 Due to Theorem 4.1, this equation has a unique solution. Since 0 is a solution it (h) (h) thus follows that g0 − ḡ0 = 0 (in L2 (R)-sense). 11 An Inverse Problem for ID Moving Averages Remark 4.3. Theorem 4.1 gives sufficient conditions for the existence and uniqueness of a solution (22) of equation (19). If condition (21) fails to hold, no solution as well as infinitely many solutions of (19) are possible. One can easily construct corresponding examples illustrating that. Consider e.g. n = 2, f1 = 1 and f2 = −1. Now choose h to be any odd function satisfying (16)-(18). Clearly condition (21) is not fulfilled. Then (19) becomes (h) (h) g1 (x) = g0 (x) + h(x) (h) (h) (h) g0 (−x) = g0 (x) − g0 (−x). h(−x) (h) (h) 1. Let g1 ∈ L2 (R) be any even function, g1 solution since its right–hand side is odd. (24) 6= 0 a.e. Then (24) has no (h) (h) 2. If, on the other hand, g1 (x) = 0 a.e. then any even L2 -function g0 solution of (24). (h) is a (h) Note that condition (17) ensures that h(·)g1 (f1 ·)/h(f1 ·) ∈ L2 (R) for any g1 ∈ (h) L2 (R). This condition is necessary. Consider e.g. g1 (x) = e−|x|/2 , h(x) = e|x| , x ∈ R, as well as f1 = f2 = f3 = 1/4, f4 = 1/16. Then, except for (17), all (h) conditions of Theorem 4.1 are fulfilled, but h(·)g1 (f1 ·)/h(f1 ·) 6∈ L2 (R) in this case. Thus (22) cannot be an L2 -solution. Remark 4.4. Condition (21) is not necessary for the existence and uniqueness of a solution of equation (19). As a counterexample, consider n = 3, f1 = eα , f2 = e2α , f3 = e3α , and h(x) = x. If √ ! √ ! −1 + 5 1+ 5 2 log ≤ α ≤ 2 log 2 2 then none of the coefficients fulfills (21). In our paper [4] we prove necessary and sufficient conditions for existence and uniqueness of a solution of integral equation P (7). It can be shown that f = 3k=1 ekα 1I∆k satisfies those conditions and hence (h) there is a unique solution of (19) for any g1 ∈ L2 (R). Condition (21) means that one of the coefficients (here f1 ) dominates all others either in its magnitude |f1 | or in its frequency n1 . To illustrate this, consider any power function h(x) = |x|β with β ∈ (1/2, 5/2) and |x|β v1 (x) ∈ L2 (R). Then sk = (|fk |/|f1 |)β , k = 1, . . . , n and the equation is solvable w.r.t. |x|β v0 (x) if 1 X |fk | n1 k:fk 6=f1 |f1 | !β−1/2 < 1. In particular, if n1 = 1 this means that |f1 | > max{|f2 |, . . . , |fn |}. If h is strictly positive and super-homogeneous of degree α, i.e. h(cx) ≥ cα h(x), 12 x∈R An Inverse Problem for ID Moving Averages for all c ≥ 0 and some α > 0, then condition (17) is fulfilled if all the coefficients fk have the same sign. Then (21) holds if 1 X fk n1 k:fk 6=f1 f1 5 (h) Estimation of g1 Fields !α−1/2 < 1. for Pure Jump ID Random Modern statistical literature contains quite a number of methods to estimate the Lévy density v1 of X(0) if d = 1, i.e., X is a Lévy process, see [15, 7, 5, 16, 6, 17, 18], [19] and references therein. They range from moment fitting and maximum likelihood ratio to inverse Fourier methods based on the empirical characterstic function of X(0). For simplicity, one often assumes that the drift and the Gaussian part of X(0) vanish, thus letting X be a pure jump Lévy process. In the recent preprint [19], the problem of estimation of the Lévy measure of X(0) was solved for compound Poisson Lévy processes X using variational analysis on the cone of measures and the steepest descent method of minimizing of a certain risk functional implemented for the discrete (atomic) measures. The resulting estimate of v1 can be obtained out of these measures by smoothing. (h) For all our estimation approaches in the next section, either estimators for g1 or (h) at least for its Fourier transform F[g1 ] are required to proceed with the estimation of v0 . Therefore we adopted an estimation procedure from [16, 5] for pure jump Lévy processes to estimate v1 . The main difference to Lévy processes is in our case the assumption of independent increments which obviously is not given for random fields in arbitrary dimension d. Nevertheless, assuming X to be m-dependent or (h) φ-mixing allows us to use the same ideas for the estimation of g1 . Consider a stationary random field X as in (14) with characteristic function ϕX(0) (u) given by  Z  ψ(u) := ϕX(0) (u) = EeiuX(0) = exp  R    eiux − 1 v1 (x)dx . 1 Note that its logarithm coincides with formula (5) by taking a1 = −1 xv1 (x)dx R and b1 = 0. Under the additional assumption R |x|v1 (x)dx < ∞ it holds R 0 ψ (u) = iψ(u) Z eiux xv1 (x)dx = iψ(u)F[xv1 ](u), R 13 An Inverse Problem for ID Moving Averages that is equivalent to F[g1 ](u) = −i ψ 0 (u) , ψ(u) (25) (h) where g1 (x) := g1 (x) = xv1 (x) (taking h(x) = x) and F[g1 ] denotes the Fourier transform of g1 . Now let X be discretely observed on a regular grid ∆Zd with mesh size ∆ > 0, i.e. we consider the random field Y = {Yj ; j ∈ Zd }, where Yj = X(∆j), ∆j = (∆j1 , . . . , ∆jd ), j = (j1 , . . . , jd ) ∈ Zd . (26) For a finite nonempty set W ⊂ Zd with cardinality N = |W | let (Yj )j∈W be a sample from Y . By taking the empirical counterparts ψ̂(u) = 1 X iuYj e , N j∈W θ̂(u) = 1 X Yj eiuYj , N j∈W (27) of ψ(u) and θ(u) := ψ 0 (u) on the right–hand side of (25) an estimator for F[g1 ] can be defined as [1 ](u) = −i θ̂(u) , (28) F[g ψ̃(u) where 1 1 1I{|ψ̂(u)| > N −1/2 }. := ψ̃(u) ψ̂(u) (29) The indicator function on the right hand side of (29) ensures the stability of the estimator for small values of |ψ̂(u)|. Based on this idea Comte and Genon-Catalot [16] provided the estimator πl 1 Z −ixu [ ĝ1,l (x) = e F[g1 ](u)du 2π −πl for g1 . We make the following assumptions: for a k ∈ N (H1) g1 ∈ L1 (R) ∩ L2 (R) (H2)k R R |x|k−1 |g1 (x)|dx < ∞ (H3) ∃ cψ , Cψ > 0 and β ≥ 0 such that for all x ∈ R cψ (1 + x2 )−β/2 ≤ |ψ(x)| ≤ Cψ (1 + x2 )−β/2 (H4) g1 ∈ H β (R) where β > 0 is as in (H3). 14 An Inverse Problem for ID Moving Averages Assumptions (H1)–(H2)k are moment conditions for X(0). Assumptions (H3)– (H4) are used to compute L2 –error bounds and rates of convergence of Lévy density estimates, cf. [5]. For the random field Y we define (1)   (2)   ξt (u) = Yt cos(uYt ) − E Y0 cos(uY0 ) , ξt (u) = Yt sin(uYt ) − E Y0 sin(uY0 ) , (1) ξ˜t (u) = cos(uYt ) − E cos(uY0 ), (2) ξ˜t (u) = sin(uYt ) − E sin(uY0 ), where u ∈ R, t ∈ Zd . Under condition (H2)2 , it holds E X 2 (0) < ∞ and hence 2  2  (i) (i) E ξt (u) < ∞, E ξ˜t (u) < ∞ for i = 1, 2, t ∈ Zd and u ∈ R. Introduce 1/2 the notation kξk· = (Ekξk22 ) ξ ∈ L2 (Ω × R). for any random function ξ : Ω × R → C s.t. The following L2 -error bounds for ĝ1,l will be proven in Appendix. Theorem 5.1. Assume that (H1), (H2)4 hold and that we observe the strictly stationary random field Y = {Yt , t ∈ Zd }. Further assume that either (i) the field Y is m-dependent or (ii) the random field Y is φ-mixing such that equations (12)–(13) hold. Then for all l ∈ N kg1 − ĝ1,l k2· ≤ kg1 − g1,l k22   Z πl K q dx 2 4 + E |Y0 | + kg1 k1 , N −πl |ψ(x)|2 where K > 0 is a constant, g1,l is given by g1,l (x) = and N ∈ N is the sample size. 1 2π R πl −πl (30) θ(u) e−iux ψ(u) du for x ∈ R, Notice that random fields (14) are m–dependent with m = diam(suppf ) since a simple function f has a compact support. Introduce the notation L := kg1 k2H β . The following corollary is an immediate consequence of Theorem 5.1. Corollary 5.2. If additionally (H3) and (H4) hold then the bound in Theorem 5.1 can be improved to ! kg1 − ĝ1,l k2· ≤ kg1 − g1,l k22 Z πl q K̃ dx + 1 + E |Y0 |4 , N −πl |ψ(x)|2 where K̃ > 0 is constant. 15 An Inverse Problem for ID Moving Averages Corollary 5.3. Under the assumptions of Corollary 5.2 it holds kg1 − ĝ1,l k2· ≤  where K̄ = 2πKcψ q L 1 + (πl)2 β + β K̄  l 1 + (πl)2 , N (31)  E |Y0 |4 + kg1 k21 . The upper bound (31) allows to choose the cut–off parameter l > 0 optimally by minimizing the right–hand side expression in (31) numerically. Choosing N, l → +∞ such that l1+2β /N → 0 yields the L2 –consistency of the estimate ĝ1,l . 6 Estimation of the Lévy Density v0 In the following Section three different estimation approaches will be discussed. The plug-in and the Fourier method are both based on formula (22), whereas the third one, which uses orthonormal bases (OnB’s) in L2 (R), is totally different from them. For this reason, the problem will be reformulated in terms of L2 –OnB’s there. Nevertheless it turns out that the sufficient conditions for the existence of a solution do not change essentially. 6.1 Plug-In Estimator (h) (h) Let ĝ1 be an estimator for g1 = h · v1 . We now consider a simple plug-in (h) (h) estimator ĝ0 of g0 = h · g0 defined by (h) ĝ0 (x) = |f1 | h(x) (h) ĝ (f1 x) n1 h(f1 x) 1 f1j+1 (|f1 |/n1 )j+1 h(x)  j+1  ĝ1(h) + (−1) ... x , f1 f . . . f i i 1 j j=1 i1 :fi1 6=f1 ij :fij 6=f1|fi1 . . . fij | h x fi ...fi nN X ! j X X 1 (32) j where N ∈ N denotes the sample size and nN is a certain cut-off parameter depending on N . The following theorem gives a bound for the mean square error (h) (h) ||g0 − ĝ0 ||· . (h) (h) (h) Theorem 6.1. Consider g0 ∈ L2 (R) and let ĝ1 ∈ L2 (R) be an estimator of g1 . Let furthermore the conditions of Theorem 4.1 be fulfilled. Then with the notation 16 An Inverse Problem for ID Moving Averages given there it holds (h) (h) kg0 − ĝ0 k· ≤  |f1 |1/2 s(f1 ) n1  (33)  (h) (e(f, h))nN +1 ||g1 ||2  (h) (h) . × 1 + (e(f, h))j  kg1 − ĝ1 k· + 1 − e(f, h) j=1 nN X (h) (h) (h) (h) In particular, if ĝ1 is an L2 -consistent estimator for g1 (i.e., kg1 − ĝ1 k· → 0 (h) (h) as N, nN → ∞) then ĝ0 is as well an L2 -consistent estimator for g0 . Proof. First of all, we observe that for each k ∈ N and fi1 , . . . , fik 6= f1 it holds f k−1 |h(x)| f k+1 |h( fi 1···fi 1 k k f1 1 1 |h( fi ···f x)| |h( f f···f x)| |h(x)| |h( fi1 x)| ik−1 i1 ik 1 = · · · 2 f1k f1k+1 |h( ffi1 x)| |h( f1 x)| |h( fi ···f x)| x)| |h( x)| fi fi 1 fi ···fi i 1 2 1 k 1 k ≤ si1 si2 · · · sik s(f1 ). (h) By relation (19) and condition (17), g1 ∈ L2 (R) as well, cf. Lemma 6.2. Using formula (22) it follows by triangle inequality and a simple integral substitution that |f1 |1/2 (h) (h) (h) (h) s(f1 )kg1 − ĝ1 k· kg0 − ĝ0 k· ≤ n1 + nN X X ··· k=1 i1 :fi1 6=f1 ∞ X + |f1 |k+1 |fi1 · · · fik | 1 X k+1 ik :fik 6=f1 n1 X ··· k=nN +1 i1 :fi1 6=f1 |f1 |k+1 |fi1 · · · fik | 1 X !1/2 k+1 ik :fik 6=f1 n1 f1k+1 s f i1 · · · f ik !1/2 ! (h) (h) kg1 − ĝ1 k· f1k+1 s f i1 · · · f ik ! (h) ||g1 ||2 |f1 |1/2 (h) (h) ≤ s(f1 )kg1 − ĝ1 k· n1 + nN X X + 1 ik :fik 6=f1 nk+1 1 ··· k=1 i1 :fi1 6=f1 ∞ X X X ··· k=nN +1 i1 :fi1 6=f1 1/2 =  k+1 ik :fik 6=f1 n1 nN X  + 1 − 1 X |f1 | n1 k:fk 6=f1 |fk | !1/2 X k:fk 6=f1 −1  sk  !1/2  |f1 | |fk | (h) !1/2 !1/2 (h) si1 si2 · · · sik s(f1 )||g1 ||2 j  (h) sk    kg1 1 X |f1 | n1 k:fk 6=f1 |fk | 17 (h) si1 si2 · · · sik s(f1 )kg1 − ĝ1 k· |f1 |k+1 |fi1 · · · fik | 1 X |f1 | 1   s(f1 )  1 + n1 j=1 n1  |f1 |k+1 |fi1 · · · fik | !1/2 (h) − ĝ1 k·  nN +1 sk  (h) kg1 k2  .  An Inverse Problem for ID Moving Averages  |f1 | Since n11 k:fk 6=f1 |f k| this approximation. P 1/2 sk < 1 the consistency result follows immediately from (h) (h) Lemma 6.2. Let g0 ∈ Lp (R), p ≥ 1, and condition (17) hold. Then g1 ∈ Lp (R). Proof. Using relation (19), condition (17) and triangle inequality, we get (h) kg1 kp ≤ n X (h) s(1/fk )kg0 kp . k=1 (h) Using the estimator ĝ0 in practice reveals that 1. the choice nN = 1, 2, 3 suffcies completely to get good results due to fast convergence of the geometric series in (33), (h) 2. ĝ0 oscillates much in a neighborhood of the origin. Hence, one has to regularize it applying a usual smoothing procedure. Convolve (h) ĝ0 with a smoothing kernel Kb : R → R+ which depends on its bandwidth b > 0 and satisfies the following assumptions: (K1) Kb ∈ L1 (R) ∩ L2 (R), R R Kb (x) dx = 1 for all b > 0 (K2) supx |F[Kb ](x)| ≤ CK where CK ∈ (0, +∞) is a constant independent of b>0 (K3) |1 − F[Kb ](x)| ≤ c1 min{1, b|x|} for all b > 0, x ∈ R where c1 > 0 is a constant. For the resulting estimator (h) (h) g̃0 (x) = ĝ0 ∗ Kb (x) = Z (h) Kb (x − y)ĝ0 (y) dy (34) R we give an upper bound of its mean square error and prove its consistency as N, nN → ∞ and b → +0. (h) (h) Theorem 6.3. Let g0 ∈ L1 (R) ∩ H δ (R) for some δ > 1/2, and let ĝ1 ∈ L1 (R) ∩ (h) L2 (R) be an estimator of g1 . For a kernel Kb satisfying assumptions (K1) –(K3), b ∈ (0, 1) it holds (h) (h) kg0 − g̃0 ||· ≤ CK (h) (h) (h) 1/2 (h) 1/2 kg0 − ĝ0 k· + ||g0 ||1 ||g0 ||H δ aδ (b), 2π where aδ (b) =    (2δ−1)  O b1∧ 4 ,    O b(− log b)1/4 , 18 δ 6= 5/2, δ = 5/2. (35) (36) An Inverse Problem for ID Moving Averages Proof. By triangle inequality, Plancherel identity and convolution property of F we have (h) (h) (h) (h) (h) (h) kg0 − g̃0 ||· ≤ kg0 ∗ Kb − ĝ0 ∗ Kb k· + kg0 ∗ Kb − g0 k· 1 1 (h) (h) (h) ≤ kF[g0 − ĝ0 ]F[Kb ]k· + kF[g0 ](F[Kb ] − 1)k2 2π 2π 1 CK (h) (h) (h) ≤ kg − ĝ0 k· + kF[g0 ](F[Kb ] − 1)k2 , 2π 0 2π (h) since ĝ0 ∈ L1 (R) ∩ L2 (R) by relation (32). By assumption (K3) and CauchySchwartz inequality, we have (h) ||F[g0 ](1 − F[Kb ])||2 = Z (h) |F[g0 ](x)|2 |1 2 − F[Kb ](x)| dx 1/2 R (h) 1/2 ≤c1 ||g0 ||1 Z (h) |F[g0 ](x)|(1 2 δ/2 +x ) 2 −δ/2 (1 + x ) 1/2 2 min{1, b|x|} dx R (h) 1/2 (h) 1/2 ≤c1 ||g0 ||1 ||g0 ||H δ Z min{1, b|x|}4 (1 + x2 )−δ dx 1/4 . R The rest of the proof follows by observing that for b ∈ (0, 1) aδ (b) := ≤ c1 Z min{1, b|x|}4 (1 + x2 )−δ dx 2π R !   c1 4   πb   c1 4   πb R1 x4 dx 0 R1 0 (1+x2 )δ x4 dx (1+x2 )δ + 1 5−2δ + b2δ−5 2δ−5 + c1 b2δ−1 π(2δ−1)   = O b4∧(2δ−1) , δ 6= 5/2, ! + 1 4 − c1 4 b π log b = O (−b4 log b) , δ = 5/2, as h → 0. There are many examples of kernels satisfying assumptions (K1)–(K3), e.g., the 2 2 2 2 1 e−x /(2b ) . Since F[Kb ](x) = e−b x /2 , (K1)–(K2) Gaussian kernel Kb (x) = √2πb are trivial. Condition (K3) holds from the inequality |F[Kb ] − 1| = |e−b 2 x2 /2 − 1| ≤ b2 x2 /2 ≤ 2 min{1, b|x|}, x ∈ R, b > 0. Another class of examples is provided by Kb (x) = RK(x/b)/b, x ∈ R, where K ∈ L1 (R) ∩ L2 (R) is a nonnegative function such that R K(x) dx = 1, supp(F[K]) ⊆ [−1, 1] and F[K] is a Lipschitz continuous function. While (K1)–(K2) trivially hold in this case, (K3) can be seen from the following lemma. 19 An Inverse Problem for ID Moving Averages Lemma 6.4. Let K : R → R+ be as above. Then |1 − F[Kb ](x)| ≤ c1 min{1, b|x|}, x ∈ R, where c1 = max{1, LK } with LK > 0 being the Lipschitz constant of K. Proof. Because of supp(F[K]) ⊆ [−1, 1] and the Lipschitz continuity of F[K] it follows  1, b|x| > 1, |1 − F[Kb ](x)| = |1 − F[K](bx)| = ≤ LK b|x|, b|x| ≤ 1. Thus |1 − F[Kb ](x)| ≤ c1 min{1, b|x|}. (h) Corollary 6.5. Choose ĝ1 = ĝ1,l , h(x) = x as in Section 5. Under the as(h) sumptions of Theorem 4.1, Corollary 5.2 and Theorem 6.3 the estimator g̃0 is L2 -consistent for g0 as N, nN → ∞ and b → +0. (h) Proof. Applying Theorem 6.1 and Corollary 5.3 yields kg0 −ĝ0 ||· → 0 as N, l → ∞ for any sequence nN → ∞. Relation aδ (b) → 0 as b → +0 finishes the proof. Remark 6.6. The choice of bandwidth b > 0 in (34) can be made by solving the following minimization problem numerically: (h) ∂g̃0 ∂b → min, b>0 2 (h) which means that we are seeking for a sufficiently smooth estimate g̃0 . Assuming that Kb is a C 1 –smooth function of parameter b > 0 and that the differentiation with respect to b and the integral can be interchanged we get by Plancherel identity and convolution property of F that  (h) ∂g̃0 ∂b 2 (h)  ∂g̃ = F 0  ∂b = F 2 h (h) ĝ0 i " ∂Kb F ∂b # → min . 2 b>0 b For easy particular functions Kb hthe Fourier transform of ∂K can be usually cal∂b i (h) culated explicitly. In contrast, F ĝ0 has to be estimated from the data, compare [0 ] to assess F [ĝ0 ]. Section 6.2 for h(x) = x. There, we use the estimate F[g 20 An Inverse Problem for ID Moving Averages 6.2 Fourier Approach (h) A common strategy in the estimation of g1 (e.g. in the case of Lévy processes) is (h) first to estimate its Fourier transform F[g1 ] and then to invert it. This causes an error in the estimation of the Fourier transform and additionally in the inversion procedure. Using plug-in estimators of Section 6.1, this may increase the estima(h) (h) tion error for g0 . For this reason, here we estimate F[g1 ] directly to recover (h) g0 . From now on, set h(x) = xβ for some β ∈ N. In other words, equation (22) is of the form 1 g0 (·) = sign(f1 )β |f1 |1−β g1 (f1 ·) n1 !β !1−β ! (37) j+1 j+1 ∞ j+1 X X X f 1 |f | f 1 1 1 + (−1)j ... g1 · , j+1 sign fi1 . . . fij |fi1 . . . fij | fi1 . . . fij j=1 i1 :fi 6=f1 ij :fi 6=f1n1 1 j β where g0 (x) = x v0 (x) and g1 (x) = xβ v1 (x). Suppose that g0 ∈ L1 (R) and the conditions of Theorem 4.1 are fulfilled. Then g1 ∈ L1 (R) as well by Lemma 6.2. The following construction of ĝ0,l (t) and ĝ1,l (t) is motivated by estimation approaches for the characteristic triplet of Lévy processes (see e.g. [7]). Taking Fourier transforms on both sides of (37) yields t 1 sign(f1 )β |f1 |−β F [g1 ] F[g0 ](t) = n1 f1 + ∞ X (−1)j j=1 X ··· i1 :fi1 6=f1 X 1 ij :fij 6=f1 nj+1 1 ! f1j+1 sign fi1 . . . fij !β |f1 |j+1 |fi1 . . . fij | !−β ! fi1 . . . fij F [g1 ] t f1j+1 [1 ] be any estimator for the Fourier transform of g1 . Then we for t ∈ R. Let F[g [0 ] for F[g0 ] via define the estimator F[g [0 ](t) = 1 sign(f1 )β |f1 |−β F[g [1 ] t F[g n1 f1 + nN X (−1)j j=1 X i1 :fi1 6=f1 ··· X 1 ij :fij 6=f1 nj+1 1 ! f1j+1 sign fi1 . . . fij !β |f1 |j+1 |fi1 . . . fij | !−β ! [1 ] fi1 . . . fij t , F[g f1j+1 [1 ] is locally square integrable, an estimator ĝ0,l of g0 is constructed t ∈ R. If F[g for some l > 0 as πl 1 Z −itu [ ĝ0,l (t) = e F[g0 ](u)du, 2π −πl 21 t ∈ R. (38) An Inverse Problem for ID Moving Averages The last expression can be rewritten as ! Zπl 1 u β −β 1 −itu [ ĝ0,l (t) = sign(f1 ) |f1 | du e F[g1 ] n1 2π f1 −πl nN X + (−1)j X 1 ij :fij 6=f1 nj+1 1 ··· i1 :fi1 6=f1 j=1 X f1j+1 sign fi1 . . . fij !β |f1 |j+1 |fi1 . . . fij | !−β ! πl 1 Z −itu [ fi1 . . . fij u du × e F[g1 ] j+1 2π f 1 −πl = 1 sign(f1 )β |f1 |1−β ĝ1, l (f1 t) |f1 | n1 nN X (−1)j + j+1 j=1 n1 × ĝ 1, X ··· i1 :fi1 6=f1 fi ...fi 1 j j+1 f 1 !β f1j+1 sign fi1 . . . fij 6 f1 = |f1 |j+1 |fi1 . . . fij | X ij :fij f1j+1 t f i1 . . . f ij !1−β ! πl 1 −itu [ F[g1 ](u)du being an estimator of g1 . with ĝ1,l (t) = 2π −πl e Remark 6.7. The estimator (28) from Section 5 is locally square integrable. In this case an appropriate choice for the parameter l > 0 can be achieved e.g. by minimizing the right-hand side of (31) for any fixed sample size N (see also the discussion following Corollary 5.3). R Similar as in Theorem 6.1 one can obtain an upper bound for the L2 -error. With R πl 1 −itu F[g1 ](u)du we get the notation g1,l (t) = 2π −πl e !nN +1  1 kĝ0,l − g0 k· ≤ n1 |f1 |β       1 n1 ĝ1, l |f1 | − g1 + · 1 P sk k:fk 6=f1 P − n11 k:fk 6=f1 sk kg1 k2 (39)  + nN X X j=1 i1 :fi1 6=f1 ··· X ij :fij 6=f1 si1 . . . sij ĝ nj1 1, fi ...fi 1 j j+1 f 1 l  − g1  , · where sk = (|fk |/|f1 |)β , k = 2, . . . , n. Assume e(f, | · |β+1/2 ) = 1 X sk < 1. n1 k:fk 6=f1 22 (40) An Inverse Problem for ID Moving Averages Choose the estimator ĝ1,l of g1 in an L2 –consistent way. Then, as N, l, nN → ∞ in an appropriate manner, the above upper bound (39) tends to zero, and ĝ0,l is L2 –consistent for g0 . For instance, one can choose ĝ1,l from Section 5, which is L2 –consistent under assumptions of Corollary 5.2. Assume, in addition to (40), that |f1 | > maxk:fk 6=f1 |fk |. By (31), the upper bound of kg1 − ĝ1,l k· is monotonously non–decreasing in l. Since f i1 . . . f ij l l< j+1 |f1 | f1 we get by (39) and (31) that   nN X 1  l2β+1 1 j β+1/2  kĝ0,l − g0 k· ≤ 1 + + e (f, | · | ) O n1 |f1 |β l2β N j=1  + nN +1 e(f, | · |β+1/2 ) 1 − e(f, | · 1 ≤ n1 |f1 |β  +  kg1 k2   e(f, | · |β+1/2 ) l2β+1 1 1+ O + 1 − e(f, | · |β+1/2 ) l2β N ! nN +1 e(f, | · |β+1/2 ) 1 − e(f, | · as N, nN , l → ∞ such that 6.3 |β+1/2 ) l2β+1 N |β+1/2 ) ! !  kg1 k2  →0 → 0. Orthonormal Basis Approach Since the series representation (22) is sensitive to noise and bad estimates for v1 , the aim is to obtain an estimation approach that uses (local) orthonormal bases (e.g., Haar wavelets) of L2 . Moreover, from the numerical point of view it is much more convenient to find a solution only on a finite interval. For this reason, the problem of Section 4 should be reformulated for functions on L2 (R) with support contained in a finite interval. For 0 < A < ∞, consider UA = {u ∈ L2 (R) : u = 0 a.e. on R\[−A, A]} to be the closed linear subspace of L2 (R) equipped with the usual scalar product (h) (h) on L2 (R). Find a function g0 ∈ UA that fulfills equation (19) for fixed g1 . Because of the scalings on the right hand side of this equation, we have to extend 23 An Inverse Problem for ID Moving Averages (h) the assumptions on g1 and the coefficients |fj | a bit. Let |f1 | ≥ maxk:fk 6=f1 |fk | be (h) the largest coefficient and define M = min{1, |f1 |}. Then for g1 ∈ UAM it follows (h) that g1 (f1 ·) ∈ UA . Since |f1 | is the largest coefficient, it holds moreover that (h) (h) g0 (f1 /fj x) = 0, for all |x| > A, i.e. g0 (f1 /fj ·) ∈ UA for all j = 1, . . . , n. For this reason the restriciton ϕg(h) |UA of the function ϕg(h) from the proof of Theorem 1 1 4.1 is a map on UA . Then one can show the following theorem with the same arguments applied to ϕg(h) |UA . 1 (h) Theorem 6.8. Let h : R → R, sk be as in Theorem 4.1, and let g1 ∈ UAM with M defined as before. Assume furthermore that |f1 | ≥ maxk:fk 6=f1 |fk | and relation (h) (21) holds. Then there exists a unique function g0 ∈ UA such that (h) g1 (·) = n X 1 h(·) (h) · ) · g0 ( fk k=1 |fk | h( fk ) (h) a.e. on [−AM, AM ]. The solution g0 (41) can be expressed as in (22). (h) (h) (h) Note that the solution g0 fulfills the equation ϕg(h) |UA (g0 ) = g0 a.e. on the 1 whole interval [−A, A], whereas (41) holds only on [−AM, AM ], which is merely (h) the same if M = 1, i.e. in the case |f1 | ≥ 1. Notice that g1 ∈ UAM means that the random field X has a compound Poisson marginal distribution if h(x) ≡ 1. (h) The last theorem stated the existence of a solution g0 (h) (h) ϕg(h) |UA (g0 ) = g0 or equivalently for of the fixpoint equation 1 n X h(·) (h) 1 h(·) (h) f1   g0 ḡ1 (·) := g1 (f1 ·) = · . f1 h(f1 ·) fk · k=1 |fk | h ! (42) fk (h) Now let (ψn )n∈N be an orthonormal basis (OnB) of UA . Since g0 = it holds ∞ D n EX X 1 h(·) (h) f1 1 h(·) (h)   g0   ψj · = g , ψ j 0 f f1 1 fk · · j=1 k=1 |fk | h k=1 |fk | h n X ! fk fk P∞ D (h) j=1 E g0 , ψj ψj ! f1 · . fk (43) Note that because of |f1 | ≥ maxk:fk 6=f1 |fk | the function ψj (f1 /fk ·) is in UA for all k ∈ N. Set ! n X 1 h(·) f1   ψj ηj (·) = · , j ∈ N. f1 fk · k=1 |fk | h fk (h) Then we can conclude that there exists a solution g0 ∈ UA of (42) if and only P 2 if the function ḡ1 admits a representation ḡ1 = ∞ j=1 xj ηj with some l -sequence 24 An Inverse Problem for ID Moving Averages (h) (xj )j∈N . In this case, a solution g0 is given by ∞ j=1 xj ψj . It is unique if and only if the scalar sequence (xj )j∈N is unique. In other words, the problem is characterized by the operator T : l2 → UA , P T : x = (xj )j∈N 7→ ∞ X xj η j . j=1 If T is surjective there exists a solution. If it is bijective the solution is unique. It is clear now that under the conditions of Theorem 6.8 the operator T is a bijection. Nevertheless, let us reformulate this theorem in terms of the OnB (ψl )l∈N and give another proof for it. Theorem 6.9. Let (ψl )l∈N be an OnB of UA , and let the conditions of Theorem 6.8 be fulfilled. Then there exists a unique sequence x ∈ l2 such that the operator T is one–to–one. Proof. We would like to show that the system (ηj )j∈N is a basis for UA . First we show, by contradiction, that V := span((ηj )j∈N ) = UA . Therefore assume that V ⊂ UA . Since V is a closed subspace of UA it follows by Riesz lemma (see e.g. [20]) that for any 0 < δ < 1 there exists a function gδ ∈ UA with kgδ k2 = 1 such that kgδ − vk2 ≥ 1 − δ, for all v ∈ V . Now P choose δ := (1 − e(f, h)) /2. Then we can write gδ = ∞ k=1 hgδ , ψk i ψk . Define the 2 sequence x = (xk )k∈N ∈ l via xk = |f1 | hgδ , ψk i /n1 , k ∈ N. Since kgδ k2 = 1 it P follows kxk2 = |f1 |/n1 . Clearly, we have ∞ k=1 xk ηk ∈ V . By triangle inequality, a substitution in the integral and the definition of sk it can be observed that 1 − δ ≤ gδ − ∞ X k=1 ! xk ηk 2 1 X |f1 | h(·) f1   gδ = · f 1 n1 j:fj 6=f1 |fj | h fj · fj ≤ e(f, h), 2 which is a contradiction to the fact that 1 − δ > e(f, h), i.e. V = UA . In the second step of the proof, we use [21, Theorem 3.1.4] to show that (ηj )j∈N is a basis for UA . Therefore we have to verify the assumptions there. First of all, 25 An Inverse Problem for ID Moving Averages we observe that ηl are non-zero functions, since ! X n1 1 h(·)   ψj kηj k2 = ψj + f1 |f1 | k:fk 6=f1 |fk | h fk · − X k:fk 6=f1 ≥ ! 1 h(·)   ψj |fk | h f1 · f1 · fk fk X n1 1 − sk |f1 | k:fk 6=f1 |fk | · |f1 | 2 f1 · fk ≥ 2 n1 |f1 | X n1 h(·) 1   ψj ≥ − |f1 | k:fk 6=f1 |fk | h f1 · fk !1/2 = ! f1 · fk 2 n1 (1 − e(f, h)) , |f1 | where the latter is strictly positive, i.e. (ηj )j∈N is a sequence of non-zero functions in the Hilbert space UA . Now let (cj )j∈N be an arbitrary real valued sequence and m, l ∈ N with m ≤ l. Show that there exists a constant K such that Pl P k m j=1 cj ηj k2 . If c1 = c2 = · · · = cl = 0 then this relation is j=1 cj ηj k2 ≤ Kk obviously true for any choice of K. Otherwise, l X ≥ cj η j j=1 2  1/2 n1 (1 − e(f, h)) c21 + · · · + c2l > 0. |f1 | Thus, we have m P j=1 l P j=1 cj ηj cj ηj 2 1/2 ≤ e(f, h) (c21 + · · · + c2m ) (1 − e(f, h)) (c21 + · · · + 1/2 c2l ) ≤ e(f, h) =: K. 1 − e(f, h) 2 This means (ηj )j∈N is a basis for UA , i.e. for any function f ∈ UA there is a unique P scalar sequence (cj (f ))j∈N with f = ∞ j=1 cj (f )ηj . Since kf k2 = ∞ X j=1  cj (f )ηj 2 1/2 ∞ X n1 ≥ (1 − e(f, h))  c2j (f ) |f1 | j=1 , the sequence (cj (f ))j∈N is furthermore an element of l2 . Choosing f= h(·) (h) g (f1 ·) h(f1 ·) 1 completes the proof. Note that the proof of the last theorem shows that the system (ηj )j∈N is a basis for the L2 -subspace UA . Therefore we can orthonormalize it by Gram–Schmidt method to an OnB (ej )j∈N of UA given by e1 = η1 /||η1 ||2 and succesively k−1 ηk − i=1 hηk , ei i ei ek = , Pk−1 kηk − i=1 hηk , ei i ei k2 P 26 k = 2, 3, . . . . An Inverse Problem for ID Moving Averages Now let ḡˆ1 be any estimator for ḡ1 ∈ UA and let Pm be the orthogonal projection of UA onto the m-dimensional subspace Vm = span{η1 , . . . , ηm } = span{e1 , . . . , em } P which is given by Pm f = m j=1 hf, ej i ej . Define the sequence (ŷj )j∈N by D  ḡ ˆ E 1 , ej , ŷj = 0, 1 ≤ j ≤ m, j > m. Then the orthogonal projection of ḡˆ1 onto Vm is ḡˆ1,m := Pm ḡˆ1 = ∞ X  ŷj ej = j=1 (h) (h) Now, an estimator ĝ0,m for g0 m X  ŷj ej  . j=1 will be constructed as follows: 1.) Let (x̂1,m , . . . , x̂m,m ) be the unique solution to ŷj = m X x̂i,m hηi , ej i , j = 1, . . . , m. (44) i=1 Set  x̂ x̂i =  0 i,m ; 1≤i≤m ; i > m. 2.) Then we define (h) ĝ0,m = ∞ X x̂i ψi i=1 = m X ! (45) x̂i ψi . i=1 m Equation (44) comes from the fact that for any f ∈ Vm , m i=1 λi ηi = i=1 hf, ei i ei Pm if and only if hf, ei i = j=1 λj hηj , ei i. Note that hei , ηj i = 0 whenever i > j since ηj is a linear combination of e1 , . . . , ej . In particular, formula (44) stays true if j > m. Due to that, the system of linear equations there becomes diagonal and can easily be solved by backward substitution. P P Theorem 6.10. Let ḡ1 ∈ UA and ḡˆ1 ∈ UA be an estimator of ḡ1 . Let furthermore ḡˆ1,m := Pm ḡˆ1 be the orthogonal projection of ḡˆ1 onto Vm . Then under the conditions (h) of Theorem 6.9 it holds for ĝ0,m as in (45) that (h) (h) kg0 − ĝ0,m k· ≤ D |f1 | (h)  n1 1 − e(f, h)   2 ∞ X j=m+1 E where xj = g0 , ψj , j ∈ N. 27  + kḡ1 − ḡˆ1,m k·  , xj ηj 2 (46) An Inverse Problem for ID Moving Averages Proof. First of all, it holds  "m ∞ X X  j=1 #2 1/2 xi hηi , ej i − ŷj   = i=1 "m ∞ X X j=1 m X = i=1 #2 1/2 x̂i hηi , ej i  i=1 m  X n1  1 − e(f, h) (xi − x̂i )2 ≥ |f1 | i=1 (xi − x̂i )ηi i=1 xi hηi , ej i − m X 2 !1/2 , and therefore m X  |f1 | 2 (xi − x̂i ) ≤  i=1  n1 1 − e(f, h)  = 2  j=1 2 |f1 | (h) (h) ∞ X ∞ X   n1 1 − e(f, h) xj ψj − j=1 m X #2 xi hηi , ej i − ŷj i=1  yj P∞ i=1 j=1 (47) xi hηi , ej i, j ∈ N, compare (43). Then ∞ X + xj ψj j=m+1 · xi hηi , ej i , i=m+1 ≤ x̂j ψj 2 ∞ X − ŷj − j=1 with (yj )j∈N defined by yj = hḡ1 , ej i = kg0 − ĝ0,m k· = "m ∞ X X m X (xj − x̂j )ψj . (48) j=1 2 · By (47) together with the triangle inequality we get m X (xj − x̂j )ψj j=1 = E !1/2 m X 2 (xi − x̂i ) i=1 · ≤ = |f1 |  n1 1 − e(f, h)  ∞ X  (yj E n1 1 − e(f, h) ∞ X − ḡˆ1,m k· + ≥ n1 |f1 | 2   ∞ X xi η i   i=m+1  1 − e(f, h) 2  xi η i  . i=m+1 xi ηi i=m+1 + j=1  kḡ1  ∞ P − ŷj )2   |f1 | Taking into account that 1/2 ∞ P j=m+1 2 the state- xj ψj 2 ment of the theorem follows by (48). Remark 6.11. The term ∞ P i=m+1 P∞ in (46) is the approximation error of ḡ1 = xi η i 2 xi ηi by the first m summands of its series. As m → ∞, the upper bound (46) tends to  |f1 |  kḡ1 − ḡˆ1 k· . In order to estimate ḡ1 , the method of Section 5 can i=1 n1 1−e(f,h) be used if the random field X satisfies the assumptions given there. In this case, Corollaries 5.2 and 5.3 yield an upper bound for kḡ1 − ḡˆ1 k· leading to L2 –consistent (h) estimates of g0 . 28 An Inverse Problem for ID Moving Averages (h) Since the estimator in (45) is strongly oscillating, a smoothed version g̃0,m = (h) (h) ĝ0,m ∗ Kb of ĝ0,m is considered here, where Kb is a smoothing kernel with properties (h) (h) (K1)-(K3) from Section 6.1. It is clear that g0 ∈ L1 (R), ĝ0,m ∈ L1 (R) ∩ L2 (R), (h) because both are in UA by assumption. If additionally g0 ∈ H δ (R) for some δ > 1/2 then it immediately follows from the proof of Theorem 6.3 that (h) (h) kg̃0,m − g0 k· ≤ CK (h) (h) (h) 1/2 (h) 1/2 kĝ − g0 k· + ||g0 ||1 ||g0 ||H δ aδ (b) 2π 0,m with aδ given in (36). The bandwidth b > 0 can be chosen as in Remark 6.6. 7 Numerical Performance of the Estimators In order to compare the three approaches of Section 6, we consider Λ(∆) to be a compound Poisson random variable d Λ(∆) = N X Yk , k=1 where {Yk }k∈N is a sequence of independent and identically distributed random variables, independent of N ∼ P oi(νd (∆)). Then for any simple function f = Pn k=1 fk 1I∆k with νd (∆k ) = νd (∆) for all k = 1, . . . , n it holds d X(0) = n X fk W k , k=1 d where W1 , . . . , Wn are i.i.d. with W1 = Λ(∆). In the following examples, we assumed d = 2, n = 4, f1 = 1.3, f2 = 0.2, f3 = f4 = 0.1 as well as ν2 (∆) = 1. Then v0 is the density of the random variable Y1 , and due to formula (15), v1 is given by 1 x 1 x 2 x v1 (x) = v0 + v0 + v0 1.3 1.3 0.2 0.2 0.1 0.1       or, equivalently,  g1 (x) = g0 x x x + g0 + 2g0 , 1.3 0.2 0.1      where g1 (x) = xv1 (x) and g0 (x) = xv0 (x), h(x) = x. Note that the coefficients f1 , . . . , f4 fulfill conditions of Theorem 4.1, i.e. for given g1 ∈ L2 (R) there exists 29 −0.2 −0.2 −0.1 −0.1 0.0 0.0 0.1 0.1 0.2 0.2 An Inverse Problem for ID Moving Averages −6 −4 −2 0 2 4 6 −6 x −4 −2 0 2 4 6 x (b) Fourier Method −0.2 −0.1 0.0 0.1 0.2 (a) Plug-In Method −6 −4 −2 0 2 4 6 x (c) OnB Method √ Figure 2: g0 (x) = ( 2π)−1 x exp(−x2 /2) (dashed line) and a realization of the corresponding estimator (red line) for each of the three estimation approaches with sample size N = 10000. a solution g0 ∈ L2 (R) to the above equation. In our examples, we simulated the random field X on an integer grid. The estimators for g0 based on the corresponding sample with sample size N = 10000 were compared to the original g0 for the following examples: √ Y1 ∼ N (0, 1), i.e. v0 (x) = ( 2π)−1 exp(−x2 /2) (Fig. 2(a)-2(c)) and (49) Y1 ∼ Exp(1), i.e. v0 (x) = exp(−x)1I(0,∞) (x) (Fig. 3(a)-3(c)) (50) 30 0.0 0.0 0.1 0.1 0.2 0.2 0.3 0.3 0.4 An Inverse Problem for ID Moving Averages −6 −4 −2 0 2 4 6 −6 −4 −2 x 0 2 4 6 x (b) Fourier Method 0.0 0.1 0.2 0.3 (a) Plug-In Method −6 −4 −2 0 2 4 6 x (c) OnB Method Figure 3: g0 (x) = x exp(−x)1I(0,∞) (x) (dashed line) and a realization of the corresponding estimator (red line) for each of the three estimation approaches with sample size N = 10000. For the estimators based on the Fourier method from Section 6.2, the parameter l = 1 is chosen due to Corollary 5.3, cf. Section 5. For both the plug-in (Section 6.1) and the Fourier method, we used furthermore the cut-off parameter nN = 1. For the smoothing procedure, the Epanechnikov kernel Kb (x) = 0.75b−1 (1 − (xb−1 )2 )1I{|x| ≤ b} with bandwidths b = 0.5 and b = 1.0 was used in examples (49) and (50) respectively, chosen according to Remark 6.6. For the OnB method, Haar wavelets 31 An Inverse Problem for ID Moving Averages {ψj } on [−A, A] for A = 6 were used together with the cut–off parameter m = 7. The parameter l > 0 and the bandwidth b > 0 for the estimator in (45) (using Epanechnikov kernel Kb ) were chosen based on a simulation study with different parameters. It turned out that visually the best choice for the example in (49) is l = 4.5, b = 0.7 whereas for the example in (50) the parameters l = 4.0, b = 1.1 turned out to be optimal. Figures 2 and 3 show realizations of the estimated g0 (red) by our methods compared to the original g0 (dashed) from examples (49) and (50). The empirical mean and the standard deviation of the mean square errors of our estimation (assessed upon estimation results for g0 out of 100 simulations of X) are given in Table 1. It is seen there that plug-in and Fourier methods perform equally well whereas the mean error for the OnB method is significantly higher. Regarding their computation times (see Table 2), the Fourier approach outperforms the others since its algorithm is at least 10 times faster. To summarize, we recommend the Fourier method for the estimation of v0 unless the plug-in approach can be used under milder assumptions on v0 and v1 . This essentially depends on the estimator for v1 which is chosen as a plug-in. Method of estimation plug-in Fourier OnB Y1 ∼ N (0, 1) mean 0.005291606 0.0005609035 sd 0.0004369446 0.0003471337 0.02257974 0.001865197 Y1 ∼ Exp(1) mean sd 0.1446655 0.007453711 0.1240124 0.004051844 0.1306668 0.005115684 Table 1: Empirical mean and standard deviation of the mean square errors of our estimations based on 100 simulations. Appendix Here we give a proof of Theorem 5.1 and its corollaries. Before doing so we prove auxiliary statements. Lemma 7.1. Let Y = {Yt , t ∈ Zd } be a random field defined in (26) satisfying (H2)2 such that Y is either (i) m-dependent or (ii) φ-mixing and condition (12) holds. 32 An Inverse Problem for ID Moving Averages Method of estimation plug-in Y1 ∼ N (0, 1) mean sd 1031.18 54.19 Y1 ∼ Exp(1) mean sd 1262.24 13.93 Fourier OnB 74.95 2726.07 3.66 1120.59 121.24 18.14 3165.08 721.25 Table 2: Mean and standard deviation of the estimation CPU-times (in seconds). The computations were performed on a CPU Intel Xeon E5-2630v3, 2.4 GHz with 128 GB RAM. Furthermore, let W ⊂ Zd be a finite subset, N = card(W ), and let θ̂(u) = 1 P iuYt and θ(u) = E Y0 eiuY0 . Then t∈W Yt e N 4 E θ̂(u) − θ(u) ≤ C E |Y0 |4 , N2 where C > 0 is a constant. Proof. It holds that 4 v u X 2  X 2 u 1 (1) (2) E θ̂(u) − θ(u) = 4 Et ξt (u) + ξt (u)  N t∈W t∈W 4 # " 4 4 X (2) X (1) 2 ξt (u) . ξt (u) + E ≤ 4 E N t∈W t∈W (i) By Theorem 2.1 it holds for p = 4, α = 1 and i = 1, 2 E X (i) 4  X ξt (u) ≤ 8 (i) 2 bt,2 (ξt ) t∈W t∈W 2  6 =2  X    t∈W (i) kξt (u)k22 + X (i) ξk (u) Ekk−tk∞ h k∈Vt1 | i (i) ξt (u) {z :=D     1  } . To determine expression D it is useful to decompose it into two parts. The first part consists of all k for which kkk∞ > m and the second part contains all other k. Hence, D= X (i) h (i) i ξk (u) Ekk−tk∞ ξt (u) k∈Vt1 kk−tk∞ >m 33 1 + X k∈Vt1 kk−tk∞ ≤m (i) h (i) ξk (u) Ekk−tk∞ ξt (u) i 1 . An Inverse Problem for ID Moving Averages (i) For the first part it holds due to m–dependence of {ξt (u)} that X (i) h (i) ξk (u) E ξt (u)|FV kk−tk∞ i 1 t k∈Vt1 kk−tk∞ >m X = h (i) (i) ξk (u) E ξt (u) k∈Vt1 kk−tk∞ >m i 1 = 0, (i) since ξt (u) is centered. Furthermore, for the second sum in expression D it follows by Hölder inequality that X h (i) (i) ξk (u) E ξt (u)|FV kk−tk∞ X 1 t k∈Vt1 kk−tk∞ ≤m ≤ i k∈Vt1 kk−tk∞ ≤m h (i) ξk (u) 2 i (i) E ξt (u)|FV kk−tk∞ (i) 2 t ≤ ξt (u) (i) X ξk (u) . (51) 2 k∈Vt1 kk−tk∞ ≤m 2 Let Ṽt1 := {k ∈ Vt1 : kk − tk∞ ≤ m} and nt := card(Ṽt1 ). This set is shown in Figure 4 for d = 2. Figure 4: The set Ṽt1 = {k ∈ Vt1 , kk − tk∞ ≤ m} (blue points) for m ∈ N. Note that for i = 1, 2 due to stationarity of Y (i) p E ξt (u) ≤ 2p E |Y0 |p , p = 1, . . . , 4. (52) (i) Therefore, for all t ∈ W and i = 1, 2 it holds that ξt (u) plying this to (51), we get (i) ξt (u) P 2 34 k∈Ṽt1 (i) ξk (u) 2 2 ≤ 2kY0 k2 . Ap- ≤ 4nt kY0 k22 . Moreover, An Inverse Problem for ID Moving Averages it follows E 4 X (i) ξt (u) ≤ 26 X 2kY0 k22 + 4nt kY0 k22 2 t∈W t∈W 6 ≤2  2N kY0 k22 + 4n ∗ N kY0 k22 2 = 28 N 2 kY0 k42 (1 + 2n∗ )2 (53) with n∗ := max{nt }. By Ljapunov inequality, it holds t∈W 210 (1 + 2n∗ )2 E |Y0 |4 . N2 4 E θ̂(u) − θ(u) ≤ (ii) Using Theorem 2.3 with p = 4 and applying the Ljapunov inequality we get E ( 4 X (i) X ξt (u) ≤ Ci · max E 4 (i) ξt (u) , ( X ≤ Ci · max E 4 (i) ξt (u) , t∈W  E  2 2 (i) ξt (u) ) t∈W t∈W t∈W X X E  4 1/2 2 (i) ξt (u) ) t∈W (i) 4 (i) = Ci · max N E ξ0 (u) , N 2 E ξ0 (u) 4  4 (i) = Ci N 2 E ξ0 (u) ≤ 24 Ci N 2 E |Y0 |4 for some constants Ci > 0, i = 1, 2, where the last inequality follows by equation (52). Thus, we have E |θ̂(u) − θ(u)|4 ≤ 2 4 C 2 4 4 2 4 E |Y0 |4 , 2 C N E |Y | + 2 C N E |Y | = 1 0 2 0 N4 N2   where C = 25 (C1 + C2 ) > 0 is constant. If assumption (i) holds then the constant C is given by C = 210 (1 + 2n∗ )2 , where n∗ ≤ md is the maximum over the cardinalities of the sets Ṽt1 for every t ∈ W . Therefore, in the first case the constant C depends on m. In the second case the constant C = 25 (C1 + C2 ) depends on the mixing coefficient φu,v (r) by Theorem 2.3. P Lemma 7.2. Let ψ̂(u) = N1 t∈W eiuYt and ψ(u) = E eiuY0 where N = card(W ). Under the assumptions of Lemma 7.1 for p ≥ 2 there exists a constant Cp > 0 such that p E ψ̂(u) − ψ(u) ≤ 35 Cp . N p/2 An Inverse Problem for ID Moving Averages Proof. Since x 7→ |x|p , p ≥ 2 is a convex function it holds 1 E ψ̂(u) − ψ(u) = p E N p X 2 + " 2 (2) ξ˜t (u) t∈W X (1) ˜ p p X (2) ˜ # ξt (u) ξt (u) + E E Np 2 p/2 X t∈W p/2−1 ≤ (1) ξ˜t (u) (54) . t∈W t∈W (i) Applying Theorem 2.1 with α = 1 we get for i = 1, 2 E X (i) ˜ p  ξt (u) ≤ 2p X (i) ξ˜t (u) t∈W t∈W 2 2 X + p/2 i h (i) (i) ξ˜k (u) Ekk−tk∞ ξ˜t (u) 1 k∈Vt1 . Since (i) ξ˜t (u) ≤ 2 (i) a.s. for all t ∈ Zd , u ∈ R, i = 1, 2 (55) 2 it follows ξ˜t (u) ≤ 4. Analogously to the calculations in the proof of 2 Lemma 7.1 (i) we observe X i h (i) (i) ξ˜k (u) Ekk−tk∞ ξ˜t (u) k∈Vt1 1 = X h (i) (i) ξ˜k (u) E ξ˜t (u)|FV kk−tk∞ t k∈Ṽt1 i 1 ≤ 4nt , and hence E p X (i) ˜  ξt (u) ≤ 2p X p/2 (4 + 4nt ) 3 ≤ 2 2 p pp/2 (N (1 + n∗ ))p/2 . t∈W t∈W So all in all we get from (54) that E ψ̂(u) − ψ(u) Cp = 22p pp/2 (1 + n∗ )p/2 > 0 and n∗ ≤ md . p Cp N p/2 ≤ for the constant (ii) Using Theorem 2.3 and inequality (55) it follows for p ≥ 2 and i = 1, 2 that E p X (i) ˜ ξt (u) ≤ Ci · max t∈W ( X E p (i) ξ˜t (u) , t∈W   p (i) (i) ≤ Ci · max N E ξ˜t (u) , N p/2 E ξ˜t (u) X By equation (54) it finally follows E ψ̂(u) − ψ(u) 3 p−1 2 E t∈W   2 p/2 p  2 p/2 (i) ˜ ξt (u) ) ≤ Ci N p/2 2p . ≤ Cp , N p/2 where Cp = 2 (C1 + C2 ) > 0 is a constant depending on p and the mixing coefficient (i) ˜ of {ξt }, i = 1, 2. 36 An Inverse Problem for ID Moving Averages The following lemma is a generalization of [22, Lemma 2.1] (proven there for independent random variables and p = 1) to the case of weakly dependent random fields. Lemma 7.3. Under the assumptions of Lemma 7.1 together with condition (13) there exists a constant C > 0 such that for p ∈ N 1 1 − E ψ̃(u) ψ(u) Proof. 2p     N −p 1 ≤ C · min , .  |ψ(u)|4p |ψ(u)|2p  (56) 1.) Let |ψ(u)| < 2N −1/2 . Then it holds 1 1 − E ψ̃(u) ψ(u) =E 2p =E 1I{|ψ̂(u)| ≥ N −1/2 } 1 − ψ(u) ψ̂(u) 1I{|ψ̂(u)| ≥ N −1/2 } · (ψ(u) − ψ̂(u)) + ψ̂(u)ψ(u)  2p ψ̂(u)1I{|ψ̂(u)| < N −1/2 } 2p ψ̂(u)ψ(u)   1 |ψ(u) − ψ̂(u)|2p −1/2  ≤ 22p−1  P (| ψ̂(u)| < N ) + E 1I{|ψ̂(u)| ≥ N −1/2 } 2p 2p |ψ(u)|2p |ψ̂(u)| |ψ(u)|   1 C2p N −p  1 ≤ 22p−1  + =O , 2p −p 2p |ψ(u)| N |ψ(u)| |ψ(u)|2p ! where the last inequality follows by Lemma 7.2 and the fact that an indicator is always smaller or equal than 1. In this case, we get for |ψ(u)| < 2N −1/2 that N −p 1 N −p Np 2−2p N −p = · > · = . |ψ(u)|4p |ψ(u)|2p |ψ(u)|2p |ψ(u)|2p 22p |ψ(u)|2p 2.) Let |ψ(u)| ≥ 2N −1/2 . Then we get P (|ψ̂(u)| < N −1/2 ) = P (|ψ(u)| − |ψ̂(u)| > |ψ(u)| − N −1/2 )    X   1 N iuYt iuY0 ≤ P |ψ̂(u) − ψ(u)| > |ψ(u)| = P e − Ee > |ψ(u)| 2 2 t∈W = v u X 2 u (1) P t ξ˜ (u) t +  X ˜(i)  t∈W  ≤ P max i=1,2 2 (2) ξ˜t (u) N > √ |ψ(u)| 2 2  37 N |ψ(u)| 2  > t∈W ξt (u) t∈W X An Inverse Problem for ID Moving Averages ≤P N ξt (u) > √ |ψ(u)| + P 2 2 t∈W  X ˜(1)  N ξt (u) > √ |ψ(u)| . (57) 2 2 t∈W  X ˜(2)  To calculate this probability, we consider assumptions (i) and (ii) separately. (i) Here we can apply Theorem 2.2 and we get for i = 1, 2 P ( N 1 ξt (u) > √ |ψ(u)| ≤ exp − e 2 2 t∈W   X ˜(i)  2 ) N √ |ψ(u)| 2 2 , 4ebi where X bi = bt,∞ (ξ˜(i) ) = t∈W X   (i) ˜ ξt (u) 2 + ∞ t∈W h  i (i) (i) ξ˜k (u) Ekk−tk∞ ξ˜t (u) X k∈Vt1 ∞ and kZk∞ := inf{c > 0 : P (|Z| > c) = 0} for a random variable Z. By inequality (55) and m-dependence i h (i) (i) ξ˜k (u) Ekk−tk∞ ξ˜t (u) X k∈Vt1 ∞ h i (i) (i) ξ˜k (u) Ekk−tk∞ ξ˜t (u) X = k∈Ṽt1 ∞ ≤ 4nt . Therefore, bi can be estimated as bi ≤ t∈W (4 + 4nt ) ≤ 4N (1 + n∗ ), i = 1, 2, with n∗ as in the proof of Lemma 7.1. For expression (57) we get P P N ξt (u) > √ |ψ(u)| + P 2 2 t∈W N ξt (u) > √ |ψ(u)| 2 2 t∈W  X ˜(1)   X ˜(2) ( ) N −p =O . |ψ(u)|2p N |ψ(u)|2 1 − ≤ 2 · exp e 128e(1 + n∗ )    (i) (ii) Apply Theorem 2.4 to {ξ˜t (u)} with at = 1 for all t ∈ W and h = 2. Then, A(W ) = N , and we have P N ξt (u) > √ |ψ(u)| + P 2 2 t∈W  X ˜(1)  2 N |ψ(u)|2 1 8 ≤ 2 · exp − e 16(1 + B(φ))N e  −p  N . =O |ψ(u)|2p   N ξt (u) > √ |ψ(u)| 2 2 t∈W  X ˜(2)  1 N |ψ(u)|2 = 2 · exp − e 128(1 + B(φ))e  So we get in both cases P (|ψ̂(u)| < N −1/2 ) = O 38  N −p . |ψ(u)|2p   An Inverse Problem for ID Moving Averages It holds that 1 |ψ̂(u)|2p = p  |ψ(u)|2p |ψ(u)|2p |ψ̂(u)|2p = |ψ(u) − ψ̂(u) + ψ̂(u)|2   |ψ(u)|2 |ψ̂(u)|2 p  p  1 |ψ̂(u) − ψ(u)|2  1 |ψ̂(u) − ψ(u)|2  1 + ≤ + = . |ψ(u)|2 |ψ(u)|2p |ψ̂(u)|2 |ψ(u)|2 |ψ̂(u)|2 Applying the binomial theorem and |ψ̂(u)| ≥ N −1/2 we get  p p X 1 |ψ̂(u) − ψ(u)|  1 p |ψ̂(u) − ψ(u)|2k 1 + = |ψ(u)|2p |ψ(u)|2p k=0 k |ψ̂(u)|2 |ψ̂(u)|2k 2 ! p X p |ψ̂(u) − ψ(u)|2k 1 ≤ . |ψ(u)|2p k=0 k N −k ! Therefore,   p X |ψ̂(u) − ψ(u)|2p 1 p −1/2   E |ψ̂(u) − ψ(u)|2k+2p N k E 1I{|ψ̂(u)| ≥ N } ≤ 4p 2p 2p |ψ(u)| k=0 k |ψ̂(u)| |ψ(u)| " !   p X 1 p N −p −k−p k ≤ . C2k+2p N N =O |ψ(u)|4p k=0 k |ψ(u)|4p " ! # So all in all, it holds 1I{|ψ̂(u)| ≥ N −1/2 } E ψ̂(u) 1 − ψ(u) 2p ≤  1 P (|ψ̂(u)| < N −1/2 ) |ψ(u)|2p  |ψ̂(u) − ψ(u)|2p N −p + E 1I{|ψ̂(u)| ≥ N −1/2 } = O , |ψ(u)|4p |ψ̂(u)|2p |ψ(u)|2p   that concludes the proof. Now we can finalize the proof of Theorem 5.1. Proof of Theorem 5.1. Note that g1 − g1,l is orthogonal to ĝ1,l − g1,l , since hg1 − g1,l , ĝ1,l − g1,l i = hg1 , ĝ1,l i − hg1 , g1,l i − hg1,l , ĝ1,l i + hg1,l , g1,l i  1 = hF[g1 ], F[ĝ1,l ]i − hF[g1 ], F[g1,l ]i − hF[g1,l ], F[ĝ1,l ]i + hF[g1,l ], F[g1,l ]i 2π =0 39 # An Inverse Problem for ID Moving Averages due to isometry property of F in L2 (R). By Pythagorean theorem we get kg1 − ĝ1,l k22 = kg1 − g1,l k22 + kg1,l − ĝ1,l k22 , and the second term can further be determined by kĝ1,l − g1,l k22 1 = F[ĝ1,l ] − F[g1,l ] 2π 2 1 Z πl θ̂(x) θ(x) = − dx. 2π −πl ψ̃(x) ψ(x) 2 2 Furthermore, kĝ1,l − g1,l k2· 2 θ̂(x) 1 Z πl θ̂(x) θ̂(x) θ(x) = dx E − + − 2π −πl ψ̃(x) ψ(x) ψ(x) ψ(x)    2 Z πl 1 E |θ̂(x) − θ(x)|2  1 Z πl 1 ≤ E θ̂(x) dx + − dx π −πl |ψ(x)|2 −πl ψ̃(x) ψ(x)   " 2# Z πl 2 1 1 Z πl E | θ̂(x) − θ(x)| 1 = E |θ̂(x) − θ(x) + θ(x)|2 − dx + dx π −πl |ψ(x)|2 −πl ψ̃(x) ψ(x)  " 1  Z πl 1 1 ≤ E |θ̂(x) − θ(x)|2 2 − π −πl ψ̃(x) ψ(x) +  2 Z πl 2# E |θ̂(x) − θ(x)|2  dx |ψ(x)|2 " 1 1 E |θ̂(x) − θ(x)| − −πl ψ̃(x) ψ(x) π " 1 1 E |θ(x)|2 dx + 2 − −πl ψ̃(x) ψ(x) Z πl  Z πl −πl = 2# | 2# 2 dx {z } =:(I)  2 Z πl 1 1 E |θ̂(x) − θ(x)|2  |F[g1 ](x) · ψ(x)|2 E − + dx + dx . 2|ψ(x)|2 −πl −πl ψ̃(x) ψ(x) Z πl | {z } =:(II) | {z =:(III) } First we calculate expression (I). Using the Cauchy-Schwarz inequality and applying Lemma 7.1 and Lemma 7.3 it holds " 1 1 E |θ̂(x) − θ(x)| − ψ̃(x) ψ(x) 2 ≤ 2# ≤ q v u u c1 t · c2 E |Y0 |4 · , N2 |ψ(x)|4 40 v u u 4 E |θ̂(x) − θ(x)| tE 1 1 − ψ̃(x) ψ(x) 4 dx An Inverse Problem for ID Moving Averages where c1 , c2 > 0 are some constants. Now we get " 1 1 − E |θ̂(x) − θ(x)| −πl ψ̃(x) ψ(x) Z πl √ 2# 2 dx ≤ Z πl c1 · c2 q 1 4 E |Y0 | dx. N −πl |ψ(x)|2 For the second term (II) we use again Lemma 7.3. Then it holds 1 1 − E ψ̃(u) ψ(u) 2 ≤ 1 c · , N |ψ(x)|4 for some c > 0. Using this, we get 2 1 c Z πl 1 1 dx ≤ − |F[g1 ](x)|2 |F[g1 ](x) · ψ(x)| E dx (58) N −πl |ψ(x)|2 −πl ψ̃(x) ψ(x) R Z πl 1 c Z πl ( R |g1 (x)|dx)2 c 2 ≤ dx = kg1 k1 dx. 2 N −πl |ψ(x)| N −πl |ψ(x)|2 Z πl 2 Part (III) can be estimated by Ljapunov inequality and Lemma 7.1 as √ q  1/2 C E |Y0 |4 . E |θ̂(x) − θ(x)|2 ≤ E |θ̂(x) − θ(x)|4 ≤ N So putting all these results together, it follows for some constant K > 0 that " √ Z πl 1 1 2 c1 · c2 q 2 2 4 kg1 − ĝ1,l k· ≤ kg1 − g1,l k2 + E |Y0 | dx π N −πl |ψ(x)|2 √ q # Z πl Z πl 2c 1 C 1 2 4 + kg1 k1 dx + dx E |Y0 | N N −πl |ψ(x)|2 −πl |ψ(x)|2   Z πl K q 1 ≤ kg1 − g1,l k22 + E |Y0 |4 + kg1 k21 dx, N −πl |ψ(x)|2 that completes the proof. Proof of Corollary 5.2. Consider expression (58) in the proof of Theorem 5.1. Using assumptions (H3)– (H4) there, it holds Z πl −πl L |F[g1 ](x)|2 1 Z 2 2 β dx ≤ |F[g ](x)| (1 + x ) dx ≤ . 1 2 |ψ(x)|2 cψ R c2ψ 41 An Inverse Problem for ID Moving Averages Proof of Corollary 5.3. Since F is an isometry of L2 (R) one has kg − g1,l k22 = kF[g1 ]1I{| · | > ≤ max (1 + x2 )−β |x|>πl Z πl}k22 = Z |x|>πl |F[g1 ](x)|2 (1 + x2 )β (1 + x2 )−β dx |F[g1 ](x)|2 (1 + x2 )β dx ≤ R L (1 + (πl)2 )β by assumption (H4). Using (H3) one gets Z πl −πl Z πl   dx 2 β 2 β . ≤ c (1 + x ) dx ≤ 2c πl 1 + (πl) ψ ψ |ψ(x)|2 −πl Plugging this into (30) yields the result. Acknowledgement W. Karcher and E. Spodarev are grateful to E. V. Jensen for her hospitality during their stay at Aarhus University in February 2011 where this research was initiated. The authors thank M. Reiß for the fruitful discussions on the subject of the paper. They also acknowledge the valuable help of O. Moreva in implementing the algorithms of Section 7. References [1] A.M. Kagan, Yu.V. Linnik, and R. C. Rao. Characterization Problems in Mathematical Statistics. John Wiley & Sons, New York, 1973. [2] D. Belomestny, V. Panov, and J. Woerner. Low frequency estimation of continuous–time moving average Lévy processes. arXiv: 1607.00896v1, 2016. [3] W. Karcher. On Infinitely Divisible Random Fields with an Application in Insurance. Phd thesis, Ulm University, 2012. [4] J. Glück, S. Roth, and E. Spodarev. A solution of a linear integral equation with the application to statistics of infinitely divisible moving averages. Preprint, 2017. [5] M. H. Neumann and M. Reiß. Nonparametric estimation for Lévy processes from low-frequency observations. Bernoulli, 15(1):223–248, 2009. [6] S. Gugushvili. Nonparametric inference for discretely sampled Lévy processes. In Ann. Inst. H. Poincaré, Probab. Statist., volume 48, pages 282–307, 2012. 42 An Inverse Problem for ID Moving Averages [7] F. Comte and V. Genon-Catalot. Nonparametric estimation for pure jump Lévy processes based on high frequency data. Stochastic Processes and their Applications, 119(12):4088–4123, 2009. [8] B. S. Rajput and J. Rosinski. Spectral representations of infinitely divisible processes. Probab. Th. Rel. Fields, (82):451–487, 1989. [9] P. Doukhan. Mixing: Properties and Examples, Lecture Notes in Statistics. Springer New York, 1994. [10] H. P. Rosenthal. On the subspaces of Lp (p > 2) spanned by sequences of independent random variables. Israel Journal of Mathematics, 8(3):273–303, 1970. [11] D. Pollard. Convergence of Stochastic Processes. Springer, New York, 1984. [12] J. Dedecker. Exponential inequalities and functional central limit theorems for random fields. ESAIM: Probability and Statistics, 5(1):77–104, 2001. [13] P. Hall and C. C. Heyde. Martingale Limit Theory and its Application, Probability and Mathematical Statistics. Academic Press, New York, 1980. [14] K. Azuma. Weighted sums of certain dependent random variables. ESAIM: Probability and Statistics, 19(3):357–367, 1967. [15] A. Antoniadis and J. Bigot. Poisson inverse problems. The Annals of Statistics, 34(5):2132–2158, 2006. [16] F. Comte and V. Genon-Catalot. Nonparametric adaptive estimation for pure jump Lévy processes. Ann. Inst. H. Poincaré Probab. Statist., 46(3):595–617, 2010. [17] S. Gugushvili, F. van der Meulen, and P. Spreij. Nonparametric Bayesian inference for multidimensional compound Poisson processes. Modern Stochastics: Theory and Applications, 2(1):1–15, 2015. [18] S. Gugushvili, F. van der Meulen, and P. Spreij. A non-parametric Bayesian approach to decompounding from high frequency data. arXiv: 1507.03263. [19] A. Lindo, S. Sagitov, and S. Zuyev. Nonparametric estimation of infinitely divisible distributions based on variational analysis of measures. arXiv: 1510.04968v1, 2015. [20] D. Werner. Funktionalanalysis. Springer-Verlag, Berlin, 2011. [21] O. Christensen. An Introduction to Frames and Riesz Bases. Birkhäuser, Boston, 2003. 43 An Inverse Problem for ID Moving Averages [22] M. H. Neumann and O. Hössjer. On the effect of estimating the error density in nonparametric deconvolution. Journal of Nonparametric Statistics, 7(4):307– 330, 1997. 44
10math.ST
1 An Enhanced Access Reservation Protocol with a Partial Preamble Transmission Mechanism in NB-IoT Systems arXiv:1712.05133v1 [cs.IT] 14 Dec 2017 Taehoon Kim, Dong Min Kim, Nuno Pratas, Petar Popovski, and Dan Keun Sung Abstract—In this letter, we propose an enhanced Access Reservation Protocol (ARP) with a partial preamble transmission (PPT) mechanism for the narrow band Internet of Things (NB-IoT) systems. The proposed ARP can enhance the ARP performance by mitigating the occurrence of preamble collisions, while being compatible with the conventional NB-IoT ARP. We provide an analytical model that captures the performance of the proposed ARP in terms of false alarm, mis-detection and collision probabilities. Moreover, we investigate a trade-off between the mis-detection and the collision probabilities, and optimize the proposed ARP according to the system loads. The results show that the proposed ARP outperforms the conventional NB-IoT ARP, in particular at heavier system loads. Index Terms—NB-IoT, Random access, Preamble structure. I. I NTRODUCTION The support for Internet of Things (IoT) plays a major role in the evolution of wireless/cellular systems, including the upcoming 5G communication systems [1]. There are two general classes of IoT transmission technologies: (1) Low-power widearea (LPWA) communication technologies (e.g., LoRa [2], Sigfox [3], IEEE 802.11ah) that operate in unlicensed spectra, and offer low-cost devices and ease of network deployment; (2) Cellular IoT technologies (e.g., LTE Cat-1, LTE Cat-0, LTE-M Cat-M1, NB-IoT) that operate in licensed spectra. Among these, NB-IoT is a recent technology that has gained a significant momentum, as observed by the fast standardization during 2016 [4] and the increasing number of deployments. NB-IoT is designed to accommodate a massive number of low-throughput, low-cost, and delay-tolerant devices. Similarly to LTE networks, each device registers at the network through an Access Reservation Protocol (ARP), i.e., random access, in which time and frequency misalignments can be adjusted. The preamble sequence is transmitted at the first step of the ARP, however, the preamble structure is no longer based on Zadoff-Chu sequence. The preamble design and detection algorithm for the NB-IoT ARP was presented in [5], while an overview of the NB-IoT air interface was given in [6]. The performance of the ARP significantly degrades due to preamble mis-detections and collisions. The preambles in NBIoT systems were designed with a goal of extending coverage This work has been in part supported by the National Research Foundation of Korea (NRF) grant funded by the Korea government (MSIP) (No. 2014R1A2A2A01005192), and in part by the European Research Council (ERC Consolidator Grant Nr. 648382 WILLOW) within the Horizon 2020 Program. T. Kim, and D. K. Sung are with the School of Electrical Engineering, KAIST, Daejeon 34134, Republic of Korea (e-mail: {thkimm, dksung}@kaist.ac.kr). D. M. Kim, N. Pratas, and P. Popovski are with the Department of Electronic Systems, Aalborg University, Aalborg 9000, Denmark (e-mail: {dmk, nup, petarp}@es.aau.dk). and reducing the occurrence of mis-detections. Yet, the number of devices within cell coverage is expected to grow, leading to an increasing number of preamble collisions. This motivates us to configure the preamble structure by considering the effect of collisions. This letter presents an enhanced ARP with a partial preamble transmission (PPT) mechanism that leverages the trade-off between mis-detections and collisions. We can significantly improve the performance of the ARP by puncturing the preamble sequence through the proposed PPT mechanism. It is worth noting that the proposed ARP requires only minor modifications on how the preambles are transmitted and detected, which can be easily implemented in NB-IoT systems. II. ACCESS R ESERVATION P ROTOCOL IN NB-I OT In NB-IoT systems, the ARP consists of 5 steps, and the detail of each step is described as follows: • Step 1: The device selects one of the available preamble sequences, and transmits it in the Narrowband Physical Random Access Channel (NPRACH); • Step 2: The eNodeB detects the preamble sequences and responds to the detected preamble sequences by sending a Random Access Response (RAR), which includes the index of the preamble sequence, the time alignment (TA) offset and an uplink grant; • Step 3: The device proceeds with the signaling information exchange on the resources indicated by the RAR, termed the RRC Connection Request; • Step 4: The eNodeB acknowledges the signaling information received from the device with the RRC Connection Setup message; • Step 5: Finally, the device transmits its data concatenated with the RRC Connection Setup Complete message. NB-IoT can be implemented with a 180kHz bandwidth, composed of 48 sub-carriers with each sub-carrier spacing of 3.75kHz, which can be configured for the NPRACH; allowing 12, 24, 36, or 48 orthogonal RA preamble sequences to be available. A preamble sequence is composed of multiple symbol groups as shown in Fig. 1, where a single symbol group consists of a cyclic prefix (CP) and ξ symbols. The rationale behind this structure is to reduce the relative CP overhead, and, thus, ξ should be carefully set to be sufficiently small so that the channel condition remains the same within each of the symbol groups. All of symbols have the same value of “1”. ν symbol groups configure a basic unit for repetition, which can be repeated M times, where M = 2q , q = 0, ..., 7. Therefore, the length of a preamble sequence, L, can be represented as L = ν·M . ξ and ν are commonly set to 5 and 4, respectively. 2 Symbol group Preamble Index i Partial unit CP Frequency NPRACH bandwidth 1st repetition mth repetition 2nd repetition ... Mth repetition Preamble Index i ... Basic unit (a) Lp = 4 (Mp = 1), G = 4. Time Fig. 1. Structure of a preamble sequence in a single NPRACH. Each symbol group uses a single carrier, and hops across frequency to facilitate to estimate uplink timing alignment at the eNodeB. Thus, selecting a preamble sequence implies that each device selects a hopping pattern, and Ω(·) represents a mapping function from a preamble index to the set of subcarrier indices which are used by the corresponding preamble sequence. The sub-carrier index used by the l-th symbol group i of the i-th preamble  i sequence  is denoted as ωl , l = 1, ..., L, i and, thus, Ω(i) = ω1 , ..., ωL . Finally, NB-IoT networks can support up to 3 coverage classes, which can be configured with different values of M , in order to support specific coverage requirements. However, in this letter, we focus on a single coverage class. III. P ROPOSED ACCESS R ESERVATION P ROTOCOL WITH A PARTIAL P REAMBLE T RANSMISSION M ECHANISM A. Partial Preamble Transmission Mechanism The key idea of a partial preamble transmission (PPT) mechanism is to allow each device to transmit a fraction of a preamble sequence, which is called a partial preamble sequence (PPS). According to the PPS configuration, the NPRACH can be virtually divided into multiple subNPRACHs, each of which is named a partial unit, where a single PPS is transmitted. We note that this approach does not alter the intrinsic structure of the protocol, and is instead a reconfiguration of the protocol. In the baseline ARP, when the amount of NPRACH resources is determined, the length of the preamble sequence is configured as Lb = ν · Mb , where Mb represents the number of repetitions. However, in the proposed scheme, a PPS with a length of Lp can be configured as Lp = ν · Mp = ν · 2qp , with qp = 0, 1, ..., 7, where Mp represents the number of repetitions in the PPSs. In this case, the eNodeB can configure G nonoverlapping PPSs, where G = Lb /Lp . In Fig. 2, we show three examples of the configuration of PPSs when Lb = 16. Note that when Lp = Lb , the proposed ARP utilizes the assigned NPRACH in the same way as in the baseline ARP. This partitioning of the preamble sequences may lead to degradation in the detection performance, while allowing the same preamble sequence to be reused up to G times by multiple devices, thus reducing the occurrence of collisions. In essence, we establish a trade-off relationship between the occurrence of mis-detections and collisions. A decrease in the detection performance of the PPSs can be to some extent compensated by suitably increasing the PPS transmit power. Partial unit (b) Lp = 8 (Mp = 2), G = 2. Partial unit Preamble Index i (c) Lp = 16 (Mp = 4), G = 1. Fig. 2. Configuration of partial preamble sequences when Lb = 16 (Mb =4). B. An Enhanced Access Reservation Protocol with a Partial Preamble Transmission Mechanism The proposed ARP with the PPT mechanism mainly differs from the baseline NB-IoT ARP at the first two steps as follows: • Step 1: Each device randomly selects an index of preamble sequence among NP preambles, and randomly selects a partial unit among the G available partial units. Each device transmits a PPS on the selected partial unit. • Step 2: The eNodeB determines which PPSs are received. The eNodeB accumulates the received power spread over each of the partial units, and compares it with the predefined detection threshold, dTH , at every partial unit1 . If a certain PPS is detected, then the eNodeB transmits the RAR, which consists of an index of preamble, an index of partial unit, a TA offset, and an uplink grant. Each device uses both the index of preamble and the index of partial unit to identify the destination of the RAR. IV. P ERFORMANCE A NALYSIS We now mathematically characterize the detection and collision probabilities associated with the proposed ARP; and formulate an optimization problem where the objective is to maximize the ARP success probability. A. System Model We focus on a single NB-IoT cell, consisting of an eNodeB and IoT devices, which attempt to access the network through the ARP. Let NM denote the number of IoT devices which attempt the ARP in a single ARP session. Let NP denote the number of preambles configured in a single NPRACH. We assume that each device performs an open-loop power control to compensate for the path loss. Thus, the channel between each device and the eNodeB can be modeled as a single-tap flat fading channel, where the channel coefficient follows a Rayleigh distribution, i.e., h ∼ CN (0, 1). For simplicity, we assume that the channel does not vary in a block of ν symbol groups, i.e., a single basic unit, but varies independently over the blocks.2 1 The number of detection events is increased by G times, however, the number of correlations per detection event remains the same, and, thus, this is not a severe burden for the eNodeB from the detection complexity perspective. 2 Note that under the block fading channel model where ν is any positive integer, our mathematical analysis is still applicable. 3 Let yk denote the received signal of a tagged preamble sequence, which is simultaneously utilized by k devices. It can  k  , for m = 1, ..., M , j = 1, ..., ν, be expressed as yk = ym,j,i k and i = 1, ..., ξ, where ym,j,i represents the i-th received k symbol in the j-th symbol group at the m-th repetition. ym,j,i can be represented as: Xk √ ′ k ym,j,i = P · hkm,j,i · xm,j,i + wm,j,i , (1) ′ k =1 ′ hkm,j,i , A mis-detection occurs when a desired PPS is not detected, and its probability, pmd , can be expressed as:  1 XN M pmd = pk · Pr Jnk < dTH (6) k=1 δ   Mp 1 XN M pk · F dTH ; Mp , = k=1 δ (kP (νξ)2 + νξ)2σ 2   dTH · Mp pk 1 XN M , · γ Mp , = k=1 Γ (Mp ) δ (kP (νξ)2 + νξ)2σ 2 where P , xm,j,i , and wm,j,i represent the received power per symbol at the eNodeB, the channel coefficient between the eNodeB and the k ′ -th device among k devices which use the tagged preamble sequence, the i-th transmitted symbol in the j-th symbol group at the m-th repetition, and the Gaussian noise with zero mean and variance of 2σ 2 , respectively. where δ represents a scaling factor which is defined as δ = 1 − p0 , while pk represents the probability that k IoT devices simultaneously utilize the same tagged PPS, which is modeled by a binomial distribution as:  k  NM −k  1 1 NM 1− pk = . (7) k NP · G NP · G B. Normalized Received power D. Collision probability To be able to perform the decision whether a certain PPS has been transmitted or not, the eNodeB needs to accumulate the received power of the PPS spread over the multiple symbol groups corresponding to the sequence. The normalized received power of a tagged PPS, which is transmitted simultaneously by k IoT devices, Jnk is represented as: A collision occurs when two or more IoT devices select the same PPS. When a tagged IoT device selects a PPS, the average collision probability of the tagged IoT device, pc , can be expressed as:  NM −1 1 pc = 1 − 1 − . (8) NP · G 2 Jnk = Mp Mp ξ ν 1 X 1 X XX 2 , (2) r k |Rm | = Mp m=1 Mp m=1 j=1 i=1 ym,j,i xm,j,i where ryx represents the correlation between y and x given by ryx = y · x∗ , where (·)∗ denotes the complex conjugate. The term rym,j,i k xm,j,i can be expressed as: rym,j,i k xm,j,i = Xk k′ =1 √ ′ P · hkm,j,i + w̃m,j,i , (3) where w̃m,j,i follows the same distribution as wm,j,i , and, thus, 2 rym,j,i k xm,j,i ∼ CN (0, 2(kP + 1)σ ) [7]. Therefore,   Mp Jnk ∼ Γ Mp , , (4) 2(kP (νξ)2 + νξ)σ 2 where Γ (α, β) represents a gamma distribution with shape α and rate β. C. False-alarm and mis-detection probabilities A false-alarm occurs when a PPS that was not transmitted by any device, is detected to be active at the eNodeB. The false-alarm probability, pfa , is expressed as:  (5) pfa = Pr Jn0 > dTH   Mp = 1 − F dTH ; Mp , 2νξσ 2   1 dTH · Mp =1− , · γ Mp , Γ (Mp ) 2νξσ 2 where F (x; α, β) represents the cumulative distribution function (CDF) of a gamma distribution, Γ (α, β). Note that F (x; α, β) can be expressed as F (x; α, β) = γ(α,βx) Γ(α) , where γ(α, βx) and Γ(·) represent the lower incomplete gamma function and the gamma function, respectively. E. Optimal PPS configuration The occurrence of mis-detections and collisions affects the ARP performance 3 . We evaluate this performance through the ARP success probability, ps , which is expressed as: ps = (1 − pc )(1 − pmd ), (9) where both pc and pmd are functions of Mp , and, thus, we can formulate an optimization problem to find the optimal configuration of the PPSs as follows: Mp⋆ = argmax ps (Mp ). (10) Mp The optimal value of Mp can be found numerically, while assuming that Mb , P , ν, ξ and an estimate of the number of contending devices is available. V. N UMERICAL R ESULTS We present the numerical results related to the detection performance and success probability of the proposed ARP. We have performed simulations using Matlab and the system parameters used during the evaluation are listed in Table I. We first evaluate the impact of the PPT mechanism on the detection performance metrics for a single device, i.e. NM = 1. In Fig. 3, we depict pfa and pmd for varying dTH values. Generally, the pfa decreases and the pmd increases as the dTH value increases when the Mp value is given. Furthermore, a higher Mp leads to a lower pfa and pmd . The former is due to 3 The limited amount of available uplink/downlink resources can also affect the ARP performance, yet the same level of performance degradation would be observed in the baseline protocol. Therefore, in this letter, our focus is solely on the effects associated with the expansion of the contention space through the PPT mechanism. 4 100 10-1 Probability TABLE I S IMULATION PARAMETERS AND VALUES Parameters Values ξ, ν 5, 4 Number of preambles (NP ) 12 Number of repetitions in baseline ARP (Mb ) 64 q Number of repetitions in proposed ARP (Mp ) 2 p ,qp = 0, .., 7 Number of devices per a single ARP session (NM ) 1 ∼ 10 Detection threshold (dTH ) -5 ∼ 15 dB SNR (ρ) -10, -5 dB Performance of the conventional ARP 10-2 10-3 10-4 100 Collision probability Mis-detection probability ARP success probability 12 4 8 16 32 64 Number of repetitions in partial preamble sequences (Mp ) Fig. 4. Collision probability, mis-detection probability, and ARP success probability for varying the Mp value of PPSs. Probability 10-1 10-2 TABLE II T HE SOLUTIONS OF THE OPTIMIZATION PROBLEM -3 10 FA. prob (Mp =64,P =-10dB) FA. prob (Mp =16,P =-10dB) FA. prob (Mp =16,P =-5dB) MD. prob (Mp =64,P =-10dB) MD. prob (Mp =16,P =-10dB) MD. prob (Mp =16,P =-5dB) 10-4 10-5 -5 0 5 Detection threshold [dB over noise level] 10 15 Fig. 3. Detection performance for varying the detection threshold, dTH . (Marker: Simulation, Line: Analysis) noise averaging; the latter is due to a higher diversity gain. In the proposed ARP, only a fraction of a preamble sequence is transmitted by each device, therefore the eNodeB is not able to fully exploit the diversity associated with the original preamble sequence, and, thus, the detection performance degrades (i.e., a higher pmd is observed). However, if each device transmits the PPS with a higher transmit power, then the pmd can be decreased. In practice, the preamble detector aims to provide a constant pfa , e.g., if we set a target pfa , i.e., ptarget , to fa 10−4 , then the detection thresholds should be set to 1.86dB and 3.44dB, for Mp = 64 and Mp = 16, respectively. Fig. 4 shows the performance of the proposed ARP for varying the Mp value of PPSs when Mb = 64, P = −5dB, and NM = 5. Decreasing the Mp implies that the eNodeB can generate more contention resources from a single original preamble sequence while slightly sacrificing the detection performance. As the Mp increases, the pmd decreases, however, the pc increases. When the Mp is equal to the Mb , the performance becomes the same as that of the baseline ARP. Due to this trade-off relationship according to how to utilize the given NPRACH resources, there exists an optimal point for maximizing the ARP success probability. Table II shows the solutions of the optimization problem in Eq. (10) for varying NM and P when the parameters are given as NP = 12, Mb = 64, and ptarget = 10−4 . The baseline fa ARP can guarantee extremely low mis-detection probabilities, since a sufficient number of repetitions are used to improve the detection performance. As a result, the ARP success probability is affected mostly by the collision probability. On the other hand, in the proposed ARP, we can adjust the configuration of the PPSs. Therefore, when the system load is light, then it mitigates the mis-detection probability. However, when the system load becomes heavy, it mitigates the collision probability even though the detection performance degrades, and, thus, the ARP success probability can be drastically improved, compared to that of the baseline ARP. Note that Mb = 64, NP = 12, ptarget = 10−4 fa Parameters Conventional ARP Proposed ARP NM P (dB) Mb pc (%) pmd ps (%) Mp⋆ pc (%) pmd −5 0 100 64 0 0 1 0 −10 8.41e−7 100 64 0 8.41e−7 −5 0 91.7 16 2.08 4.46e−6 2 8.3 −10 8.04e−7 91.7 32 4.2 4.34e−3 64 −5 0 70.6 8 4.10 1.48e−2 5 29.4 −10 7.01e−7 70.6 32 15.7 4.06e−3 −5 0 45.7 8 8.99 1.44e−2 10 54.3 −10 5.51e−7 45.7 16 17.3 1.26e−1 ps (%) 100 100 97.9 95.4 94.5 84.0 89.7 72.3 if we consider more constraints on either pc or pmd then the Mp⋆ may change. VI. C ONCLUSIONS We proposed an enhanced access reservation protocol (ARP) with a partial preamble transmission (PPT) mechanism for NB-IoT systems. The proposed ARP can mitigate the collision probability while slightly sacrificing the detection performance. We mathematically analyzed our proposed ARP in terms of the false alarm and mis-detection probabilities, and collision probability. We also investigated the trade-off relationship between the mis-detection probability and the collision probability, and found an optimal resource utilization strategy according to the system loads. Through extensive simulations, we verified that the proposed ARP outperforms the conventional NB-IoT ARP. R EFERENCES [1] M. R. Palattella, M. Dohler, A. Grieco, G. Rizzo, J. Torsner, T. Engel, and L. Ladid , “Internet of things in the 5G era: Enablers, architecture, and business models,” IEEE J. Select. Areas Commun., vol. 34, no. 3, pp. 510–527, Mar. 2016. [2] “LoRa Alliance - Wide Area Networks for The Internet of Things,” 2015. [Online]. Available: https://www.lora-alliance.org/ [3] “SigFox - Global Cellular Connectivity for The Internet of Things.” 2015. [Online]. Available: http://www.sigfox.com/ [4] Technical specification group radio access network; evolved universal terrestrial radio access (E-UTRA); physical channels and modulation, 3GPP Std. TS 36.211, Rev. Release 14, Sept. 2016. [5] X. Lin, A. Adhikary, Y.-P. E. Wang, “Random access preamble design and detection for 3GPP narrowband IoT systems,” IEEE Wireless Commun. Lett., vol. 5, no. 6, pp. 640–643, Dec. 2016. [6] Y.-P. E. Wang, X. Lin, A. Adhikary, A. Grovlen, Y. Sui, Y. Blankenship, J. Bergman, and H. S. Razaghi, “A primer on 3GPP narrowband internet of things (NB-IoT),” IEEE Communications Magazine, vol. 55, no. 3, pp. 117–123, Mar. 2017. [7] T. Kim, K. S. Ko, and D. K. Sung, “Transmit power optimization for prioritized random access in OFDMA based systems,” in Proc. IEEE ICC 2016, May 2016.
7cs.IT
Total Capture: A 3D Deformation Model for Tracking Faces, Hands, and Bodies∗ Hanbyul Joo Tomas Simon Yaser Sheikh Carnegie Mellon University arXiv:1801.01615v1 [cs.CV] 5 Jan 2018 {hanbyulj,tsimon,yaser}@cs.cmu.edu Figure 1: Frankenstein (silver) and Adam (gold). This paper presents a 3D human model capable of concurrently tracking the large-scale posture of the body along with the smaller details of a persons facial expressions and hand gestures. Abstract interacting individuals, gestures such as a gentle shrug of the shoulders, a quick turn of the head, or an uneasy shifting of weight from foot to foot, all transmit critical information about the attention, emotion, and intention to observers. Notably, these social signals are usually transmitted by the organized motion of the whole body: with facial expressions, hand gestures, and body posture. These rich signals layer upon goal-directed activity in constructing the behavior of humans, and are therefore crucial for the machine perception of human activity. We present a unified deformation model for the markerless capture of multiple scales of human movement, including facial expressions, body motion, and hand gestures. An initial model is generated by locally stitching together models of the individual parts of the human body, which we refer to as the “Frankenstein” model. This model enables the full expression of part movements, including face and hands by a single seamless model. Using a large-scale capture of people wearing everyday clothes, we optimize the Frankenstein model to create “Adam”. Adam is a calibrated model that shares the same skeleton hierarchy as the initial model but can express hair and clothing geometry, making it directly usable for fitting people as they normally appear in everyday life. Finally, we demonstrate the use of these models for total motion tracking, simultaneously capturing the large-scale body movements and the subtle face and hand motion of a social group of people. However, there are no existing systems that can track, without markers, the human body, face, and hands simultaneously. Current markerless motion capture systems focus at a particular scale or on a particular part. Each area has its own preferred capture configuration: (1) torso and limb motions are captured in a sufficiently large working volume where people can freely move [17, 21, 44, 19]; (2) facial motion is captured at close range, mostly frontal, and assuming little global head motion [5, 24, 6, 9, 51]; (3) finger motion is also captured at very close distances from hands, where the hand regions are dominant in the sensor measurements [36, 49, 42, 50]. These configurations make it difficult to analyze these gestures in the context of social communication. 1. Introduction Social communication is a key function of human motion [7]. We communicate tremendous amounts of information with the subtlest movements. Between a group of In this paper, we present a novel approach to capture the motion of the principal body parts for multiple interacting ∗ Website: http://www.cs.cmu.edu/ hanbyulj/totalcapture ˜ 1 people (see Fig. 1). The fundamental difficulty of such capture is caused by the scale differences of each part. For example, the torso and limbs are relatively large and necessitate coverage over a sufficiently large working volume, while fingers and faces, due to their smaller feature size, require close distance capture with high resolution and frontal imaging. With off-the-shelf cameras, the resolution for face and hand parts will be limited in a room-scale, multi-person capture setup. To overcome this sensing challenge, we use two general approaches: (1) we leverage keypoint detection (e.g., faces [18], bodies [54, 14, 35], and hands [41]) in multiple views to obtain 3D keypoints, which is robust to multiple people and object interactions; (2) to compensate for the limited sensor resolution, we present a novel generative body deformation model, which has the ability to express the motion of the each of the principal body parts. In particular, we describe a procedure to build an initial body model, named “Frankenstein”, by seamlessly consolidating available part template models [33, 13] into a single skeleton hierarchy. We optimize this initialization using a capture of 70 people, and learn a new deformation model, named “Adam”, capable of additionally capturing variations of hair and clothing, with a simplified parameterization. We present a method to capture the total body motion of multiple people with the 3D deformable model. Finally, we demonstrate the performance of our method on various sequences of social behavior and person-object interactions, where the combination of face, limb, and finger motion emerges naturally. 2. Related Work Motion capture systems performed by tracking retroreflective markers [55] are the most widely used motion capture technology due to their high accuracy. Markerless motion capture methods [23, 17, 21, 44] have been explored over the past two decades to achieve the same goal without markers, but they tend to implicitly admit that their performance is inferior by treating the output of marker based methods as a ground truth or an upper bound. However, over the last few years, we have witnessed a great advance in key point detections from images (e.g., faces [18], bodies [54, 14, 35], and hands [41]), which can provide reliable anatomical landmark measurements for markerless motion capture methods [19, 28, 41], while the performance of marker based methods relatively remains the same with their major disadvantages including: (1) a necessity of sparsity in marker density for reliable tracking which limits the spatial resolution of motion measurements, and (2) a limitation in automatically handling occluded markers which requires an expensive manual clean-up. Especially, capturing high-fidelity hand motion is still challenging in marker-based motion capture systems due to the severe self- occlusions of hands [59], while occlusions are implicitly handled by guessing the occluded parts with uncertainty using the prior learnt from a large scale dataset [41]. Our method shows that the markerless motion capture approach potentially begins to outperform the marker-based counterpart by leveraging the learning based image measurements. As an evidence we demonstrate the motion capture from total body, which has not been demonstrated by other existing marker based methods. In this section, we review the most relevant markerless motion capture approaches to our method. Markerless motion capture largely focuses on the motion of the torso and limbs. The standard pipeline is based on a multiview camera setup and tracking with a 3D template model [32, 23, 15, 10, 29, 16, 52, 11, 44, 17, 20, 19]. In this approach, motion capture is performed by aligning the 3D template model to the measurements, which distinguish the various approaches and may include color, texture, silhouettes, point clouds, and landmarks. A parallel track of related work therefore focuses on capturing and improving body models for tracking, for which a highly controlled multiview capture system—specialized for single person capture—is used to build precise models. With the introduction of commodity depth sensors, single-view depth-based body motion capture became a popular direction [3, 40]. A recent collection of approaches aims to reconstruct 3D skeletons directly from monocular images, either by fitting 2D keypoint detections with a prior on human pose [60, 8] or getting even closer to direct regression methods [61, 34, 48]. Facial scanning and performance capture has been greatly advanced over the last decade. There exist multiview based methods showing excellent performance on high-quality facial scanning [5, 24] and facial motion capture [6, 9, 51]. Recently, light-weighed systems based on a single camera show a compelling performance by leveraging morphable 3D face model on 2D measurements[22, 18, 31, 47, 13, 12, 56]. Hand motion captures are mostly lead by single depth sensor based methods [36, 46, 49, 30, 57, 45, 53, 43, 39, 42, 50, 58], with few exceptions based on multi-view systems [4, 43, 38]. In this work, we take the latter approach and use the method of [41] who introduced a hand keypoint detector for RGB images which can be directly applicable in multiview systems to reconstruct 3D hand joints. As a way to reduce the parameter space and overcome the complexity of the problems, generative 3D template models have been proposed in each field, for example the methods of [2, 33, 37] in body motion capture, the method of [13] for facial motion capture, and very recently, the combined body+hands model of Romero et al. [38]. A generative model with expressive power for total body motion has not been introduced. Figure 2: Part models and a unified Frankenstein model. (a) The body model [33]; (b) the face model [13]; and (c) a hand rig, where red dots have corresponding 3D keypoints reconstructed from detectors in (a-c). (d) Aligned face and hand models (gray meshes) to the body model (the blue wireframe mesh); and (e) the seamless Frankenstein model. 3. Frankenstein Model The motivation for building the Frankenstein body model is to leverage existing part models—SMPL [33] for the body, FaceWarehouse [13] for the face, and an artistdefined hand rig—each of which capture shape and motion details at an appropriate scale for the corresponding part. This choice is not driven merely by the free availability of the component models: note that due to the trade-off between image resolution and field of view of today’s 3D scanning systems, scans used to build detailed face models will generally be captured using a different system than that used for the rest of the body. For our model, we merge all transform bones into a single skeletal hierarchy but keep the native parameterization of each component part to express identity and motion variations, as explained below. As the final output, the Frankenstein model produces motion parameters capturing the total body motion of humans, and generates a seamless mesh by blending the vertices of the component meshes. 3.1. Stitching Part Models Each of the component part models maps from a subset of the above parameters to a set of vertices, respecB F H tively, VB ∈ RN ×3 , VF ∈ RN ×3 , VLH ∈ RN ×3 , and H VRH ∈ RN ×3 , where the number of vertices of each mesh part is N B =6890, N H =2068, and N F =11510. The U final mesh of the Frankenstein model, VU ∈RN ×3 , is defined by linearly blending them with a matrix C ∈ U B F H RN ×(N +N +2N ) : VU = C h VB T VF T VLH T VRH T i T , (4) where T denotes the transpose of a matrix. Note that VU has fewer vertices than the sum of part models because there are redundant parts in the body model (e.g., face and hands of the body model). In particular, our final mesh has N U =18540 vertices. Figure 2 shows the part models which are aligned by manually clicking corresponding points between parts, and also shows the final mesh topology of Frankenstein model at the mean shape in the rest pose. The blending matrix C is a very sparse matrix and most rows have a single column set to one with zeros elsewhere, simply copying the vertex locations from the corresponding part models with minimal interpolation at the seams. In the Frankenstein model, all parts are rigidly linked by a single skeletal hierarchy. This unification is achieved by substituting the hands and face branches of the SMPL body skeleton with the corresponding skeletal hierarchies of the detailed part models. All parameters of the Frankenstein model are jointly optimized for motion tracking and identity fitting. The parameterization of each of the part models is detailed in the following sections. 3.2. Body Model The Frankenstein model M U is parameterized by motion parameters θ U , shape (or identity) parameters φU , and a global translation parameter tU , For the body, we use the SMPL model [33] with minor modifications. In this section, we summarize the salient aspects of the model in our notation. The body model, M B , is defined as follows, VU = M U (θ U , φU , tU ), VB = M B (θ B , φB , tB ) (1) where VU is a seamless mesh expressing the motion and shape of the target subject. The motion and shape parameters of the model are a union of the part models’ parameters: θ U = {θ B , θ F , θ LH , θ RH }, (2) φU = {φB , φF , φLH , φRH }, (3) where the superscripts represent each part model: B for the body model, F for the face model, LH for for the left hand model, and RH for the right hand model. (5) B with VB = {viB }N i=1 . The model uses a template mesh of N B =6890 vertices, where we denote the i-th vertex as viB ∈ R3 . The vertices of this template mesh are first displaced by a set of blendshapes describing the identity or body shape. Given the vertices in the rest pose, the posed mesh vertices are obtained by linear blend skinning using transformation matrices TB j ∈ SE(3) for each of J joints, B viB = I3×4 · J X j=1 B wi,j TB j  PKb k B  viB0 + k=1 bi φk , 1 (6) where bki ∈ R3 is the i-th vertex of the k-th blendshape, B Kb φB with Kb =10 k is the k-th shape coefficient in φ ∈ R the number of identity body shape coefficients, and viB0 is the i-th vertex of the mean shape. The transformation matrices TB j encode the transform for each joint j from the rest pose to the posed mesh in world coordinates, which is constructed by following skeleton hierarchy from the root joint with pose parameter θ B (see [33]). The j-th pose parameter θjB is the angle-axis representation of the relative B is rotation of joint j with respect to its parent joints. wi,j B the weight with which transform Tj affects vertex i, with PJ B j=1 wi,j =1 and I3×4 is the 3×4 truncated identity matrix to transform from homogenous coordinates to a 3 dimensional vector. We use J B =21 with θ B ∈ R21×3 , ignoring the last joint of each hand of the original body model. For simplicity, we do not use the pose-dependent blendshapes. 3.3. Face Model As a face model, we build a generative PCA model from the FaceWarehouse dataset [13]. Specifically, the face part model, M F , is defined as follows, F {viF }N i=1 , viF Kf X k=1 fik φF k + Ke X esi θsF We use an artist rigged hand mesh. Our hand model has J H =16 joints and the mesh is deformed via linear blend skinning. The hand model has a fixed shape, but we introduce scaling parameters for each bone to allow for different finger sizes. The transform for each joint j is parameterized by the Euler angle rotation with respect to its parent, θ j ∈ R3 , and an additional anisotropic scaling factor along each axis, φj ∈ R3 . Specifically, the linear transform for joint j in the bone’s local reference frame becomes eul(θ j )·diag(sj ), where eul(θ j ) converts from an Euler angle representation to a 3 × 3 rotation matrix and diag(φj ) is the 3 × 3 diagonal matrix with the X,Y ,Z scaling factors φj on the diagonal. The vertices of the hand in world H coordinates are given by LBS with weights wi,j : H vi = I3×4 · TB j=H · Γ · J X H wi,j TH j   vi0 . 1 (10) (7) 3 with V = where the i-th vertex is ∈ R , and N F =11510. The vertices are represented by the linear combination of the subspaces: v̂iF = viF 0 + 3.4. Hand Model j=1 VF = M F (θ F , φF , TF ), F where the transform ΓF , directly determined by the body shape parameters φB , aligns the face model with the body model. (8) s=1 where, as before, viF 0 denotes i-th vertex of the mean shape, F and φF k and θs are k-th face shape identity (shape) and sth facial expression (pose) parameters respectively. Here, fik ∈ R3 is the i-th vertex of the k-th identity blendshape (Kf = 150), and esi ∈ R3 is the i-th vertex of the s-th expression blendshape (Ke = 200). Finally, a transformation TF brings the face vertices into world coordinates. To ensure that the face vertices transform in accordance to the rest of the body, we manually align the mean face viF 0 with the body mean shape, as shown in Fig. 2. This way, we can apply the transformation B of the body model’s head joint TB j=F (θ ) as a global transformation for the face model in Eq. 9. However, to keep the face in alignment with the body, an additional transform matrix ΓF ∈ SE(3) is required to compensate for displacements in the root location of the face joint due to body shape changes in Eq. 6. Finally, each face vertex position is given by:  F v̂i F B F vi = I3×4 · Tj=F · Γ , (9) 1 where TH j is each bone’s composed transform (with all parents in the hierarchy), TB j=H is the transformation of the corresponding hand joint in the body model, and ΓH is the transformation that aligns the hand model to the body model. As with the face, this transform depends on the shape parameters of the body model. 4. Motion Capture with Frankenstein Model We fit the Frankenstein model to data to capture the total body motion, including the major limbs, the face, and fingers. Our motion capture method relies heavily on fitting mesh correspondences to 3D keypoints, which are obtained by triangulation of 2D keypoint detections across multiple camera views. To capture shape information we also use point clouds generated by multiview stereo reconstructions. Model fitting is performed by an optimization framework to minimize distances between corresponded model joints and surface points and 3D keypoint detections, and iterative closest point (ICP) to the 3D point cloud. 4.1. 3D Measurements We incorporate two types of measurements in our framework as shown in Fig. 3: (1) corresponded 3D keypoints, which map to known joints or surface points on the mesh models (see Fig. 2), and (2) uncorresponded 3D points from multiview stereo reconstruction, which we match using ICP. 3D Body, Face, and Hand Keypoints: We use the OpenPose detector [25] in each available view, which produces 2D keypoints on the body with the method of [14], are expressed as combinations of vertices via a regression U matrix J ∈ RC×N , where C denotes the number of correspondences and N U is the number of vertices in the model. Let D denote the set of available detections in a particular frame. The cost is then: X Ekeypoints = λkeypoints ||Ji V − yiT ||2 , (12) i∈D Figure 3: 3D measurements and Frankenstein fitting result. and hand and face keypoints using the method of [41]. 3D body skeletons are obtained from the 2D detections using the method of [28], which uses known camera calibration parameters for reconstruction. The 3D hand keypoints are obtained by triangulating 2D hand pose detections, following the method of [41], and similarly for the facial keypoints. Note that subsets of 3D keypoints can be entirely missing if there aren’t enough 2D detections for triangulation, which can happen in challenging scenes with interocclusions or motion blur. 3D Feet Keypoints: An important cue missing from the OpenPose detector are landmarks on the feet. For motion capture, this is an essential feature to prevent footskate, as well as to accurately determine the orientation of the feet. We therefore train a keypoint detector for the tip of the big toe, the tip of the little toe, and the ball of the foot. We annotate these 3 keypoints per foot in each of around 5000 person instances of the COCO dataset, and use the neural network architecture presented by [54] with a bounding box around the feet determined by the 3D body detections1 . 3D Point Clouds: We use the commercial software Capturing Reality to obtain 3D point clouds from the multiview images, with associated point normals. 4.2. Objective Function We initially fit every frame in the sequence independently. For clarity, we drop the time index from the notation and describe the process for a single frame, which optimizes the following cost function:  E θU , φU , tU = Ekeypoints + Eicp + Eseam + Eprior (11) Anatomical Keypoint Cost: the term Ekeypoints matches 3D keypoint detections which are in direct corresponce to our mesh models. This includes joints (or end effects) in the body and hands, and also contains points corresponding to the surface of the mesh (e.g., facial keypoints and the tips of fingers and toes). Both of these types of correspondence 1 More details provided in the supplementary material. where Ji indexes a row in the correspondence regression matrix and represents an interpolated position using a small number of vertices, and yi ∈ R3×1 is the 3D detection. The λkeypoints is a relative weight for this term. ICP Cost: The 3D point cloud measurements are not a priori in correspondence with the model meshes. We therefore establish their correspondence to the mesh using Iterative Closest Point (ICP) during each solver iteration. We find the closest 3D point in the point cloud to each of the mesh vertices, i∗ = arg mini ||xi − vj ||2 , (13) where xi∗ is the closest 3D point to vertex j, where vj is a vertex2 in VU of the Frankenstein model. To ensure that this is a correct correspondence, we use thresholds for the distance and normals during the correspondence search. Finally, for each vertex j we compute the point-to-plane residual, i.e., the distance along the normal direction, X Eicp = λicp n(xi∗ )T (xi∗ − vj ), (14) vj ∈VtU where n(·) ∈ R3 represents the point’s normal, and λicp is a relative weight for this term. Seam Constraints: The part models composing the Frankenstein model are rigidly linked by the skeletal hierarchy. However, the independent surface parameterizations of each of the part models may introduce discontinuities at the boundary between parts (e.g., a fat arm with a thin wrist). To avoid this artifact, we encourage the vertices around the seam parts to be close by penalizing differences between the last two rings of vertices around the seam of each part, and the corresponding closest point in the body model in the rest pose expressed as barycentric coordinates (see the supplementary materials for details). Prior Cost: Depending on the number of measurements available in a particular frame, the set of parameters of M u may not be determined uniquely (e.g., the width of the fingers). More importantly, the 3D point clouds are noisy and cannot be well explained by the model due to hair and clothing, which are not captured by the SMPL and 2 We do not consider some parts (around hands and face), as depth sensor resolution is too low to improve the estimate. These parts are defined as a mask. Figure 4: Regressing detection target positions. (Left) The template model is aligned with target object. (Mid.) The torso joints of the template model (magenta) have discrepancy from the joint definitions of 3D keypoint detection (cyan). (Right) The newly regressed target locations (green) are more consistent with 3D keypoint detections. FaceWarehouse meshes, which can result in erroneous correspondences during ICP. Additionally, the joint locations of the models are not necessarily consistent with the annotation criteria used to train the 2D detectors. We are therefore forced to set priors over model parameters to avoid the model from overfitting to these sources of noise, F B H Eprior = Eprior + Eprior + Eprior . The prior for each part is defined by corresponding shape and pose priors, for which we use 0-mean standard normal priors for each parameter except for scaling factors, which are encouraged to be close to 1. Details and relative weights can be found in supplementary materials. 4.3. Optimization Procedure The complete model is highly nonlinear, and due to the limited degrees of freedom of the skeletal joints, the optimization can get stuck in bad local minima. Therefore, instead of optimizing the complete model initially, we fit the model in phases, starting with a subset of measurements and strong priors that are relaxed as optimization progresses. Model fitting is performed on each frame independently. To initialize the overall translation and rotation, we use four keypoints on the torso (left and right shoulders and hips) without using the ICP term, and with strong weight on the priors. Once the torso parts are approximately aligned, we use all available keypoints of all body parts, with small weight for the priors. The results at this stage already provide reasonable motion capture but do not accurately capture the shape (i.e., silhouette) of the subject. Finally, the entire optimization is performed including the ICP term to find correspondences with the 3D point cloud. We run the final optimization two times, finding new correspondences each time. For the optimization we use LevenbergMarquardt with the Ceres Solver library [1]. 5. Creating Adam We derive a new model, which we call Adam, enabling total body motion capture with a simpler parameterization than the part-based Frankenstein model. In particular, this new model has a single joint hierarchy and a common parameterization for all shape degrees of freedom, tying together the face, hand, and body shapes and avoiding the need for seam constraints. To build the model, it is necessary to reconstruct the shape and the motion of all body parts (face, body, and hands) from diverse subjects where model can learn the variations. To do this, we leverage our Frankenstein model and apply it on a dataset of 70 subjects where each of them performs a short range of motion in a multiview camera system. We selected 5 frames for each person in different poses and use the the reconstruction results to build Adam. From the data, both joint location information and linear shape blendshapes are learnt. Because we derive the model from clothed people, the blendshapes explain some variations of them. 5.1. Regressing Detection Targets There exists a discrepancy between the joint locations of the body model (e.g., SMPL model in our case) and the location of the keypoint detections (i.e., a model joint vs. a detection joint), as shown in Fig. 4. This affects mainly the shoulder and hip joints, which are hard to precisely annotate. This difference has the effect of pulling the Frankenstein model towards a bad fit even while achieving a low keypoint cost, Ekeypoints . We alleviate this problem by computing the relative location of the 3D detections with respect to the fitted mesh vertices by leveraging the the reconstructed 70 people data. This allows us to define new targets for the keypoint detection cost that, on average, are a better match for the location of the 3D detections with respect to the mesh model, as shown in Fig. 4. In particular, given the fitting results of 70 identities, we approximate the target 3D keypoint locations as a function of the final fitted mesh vertices following the procedure of [33] to find a sparse, linear combination of vertices that approximates the position of the target 3D keypoint. Note that we do not change the joint location used in the skeleton hierarchy during LBS deformation, only the regression matrices Ji in Eq. (12). 5.2. Fitting Clothes and Hair The SMPL model captures the shape variability of human bodies, but does not account for clothing or hair. Similarly, the FaceWarehouse template mesh was not design to model hair. However, for the natural interactions that we are most interested in capturing, people wear everyday clothing and sport typical hairstyles. To learn a new set of linear blendshapes that better capture the rough geometry of clothed people and jointly model face, it is required to reconstruct the accurate geometry of the source data. For this purpose, we reconstruct the out-of-shape spaces in the reconstructed 70 people results by Frankenstein model fitting. For each vertex in the Frankenstein model, we write ṽi = vi + n(vi )δi , (15) where δi ∈ R is a scalar displacement meant to compensate for the discrepancy between the Frankenstein model vertices and the 3D point cloud, along the normal direction at each vertex. We pose the problem as a linear system,     NT (P − VU )T ∆ = , (16) 0 (WLN)T U where ∆ ∈ RN contains the stacked per-vertex displacements, VU are the vertices in the Frankenstein model, P ∈ U U RN ×3 are corresponding point cloud points, N ∈ RN ×3 U U contains the mesh vertex normals, and L ∈ RN ×N is the Laplace-Beltrami operator to regularize the deformation. We also use a weight matrix W to avoid large deformations where the 3D point cloud has lower resolution than the original mesh, like details in the face and hands. Figure 5: (Top) Visualization of silhouette from different methods with Ground-truth. The ground truth is drawn on red channel and the rendered silhouette masks from each model is drawn on green channel. Thus, the correctly overlapped region is shown as yellow color.; (Bottom) Silhouette accuracy compared to the ground truth silhouette. 5.3. Building the Shape Deformation Space After ∆ fitting, we warp each frame’s surface to the rest pose, applying the inverse of the LBS transform. With the fitted surfaces warped to this canonical pose, we do PCA analysis to build a joint linear shape space that captures shape variations across the entire body. As in Section 3.3, we separate the expression basis for the face and retain the expression basis from the FaceWarehouse model, as our MVS point clouds are of too low resolution to fit facial expressions. This model now can have shape variation for all parts, including body, hand, and face. The model also includes deformation of hair and clothing. That is this model can substitute parameters of φF , φB , and φH . M T (θT , φT , tT ) = VT (17) T T with VT = {viT }N i=1 and N =18540. As in SMPL, the vertices of this template mesh are first displaced PKTby ka set of blendshapes in the rest pose, v̂iT = viT 0 + k=1 si φB k, k 3 where si ∈ R is the i-th vertex of the k-th blendshape, φTk is the k-th shape coefficients of φT ∈ RKb , and KT = 40 is the number of identity coefficients, vT 0 is the mean shape and vT 0 is its i-th vertex. However, these blendshapes now capture variation across the face, hands, and body. These are then posed using LBS as in Eq. (6). We define the joints and weights for LBS followoing the part models, which is further explained in the supplementary material. 5.4. Tracking with Adam The cost function to capture total body motion using Adam model is similar to Eqn. 11 without the seam term:  E θT , φT , tT = Ekeypoints + Eicp + Eprior . (18) Table 1: Accuracy of Silhouettes from different models Mean Std. SMPL[33] 84.79% 4.55 Franken 85.91% 4.57 Franken ICP 87.68% 4.53 Adam ICP 87.74% 4.18 However, Adam is much easier to use than Frankenstein, because it only has a single type of shapes and pose parameters for all parts. Conceptually, it is based on the SMPL model parameterization, but with additional joints for the hands and facial expression blendshapes. Optical Flow Propagation: While fitting each frame independently has benefits—-it does not suffer from error accumulation and frames can be fit in parallel—it typically produces jittery motion. To reduce this jitter, we use optical flow to propagate the initial, per-frame fit to neighboring frames to find a smoother solution. More concretely, given the fitting results at the frame t, we propagate this mesh to frames t−1 and t+1 using optical flow at each vertex, which is triangulated into 3D using the method of [27]. Therefore, each vertex has at most three candidate positions: the original mesh, and the forward and backward propagated vertices (subject to a forward-backward consistency check). Given these propagated meshes, we reoptimize the model parameters by using all propagated mesh vertices as additional keypoints to find a compromise mesh. We run this process multiple times (3, in our case), to further reduce jitter and fill in frames with missing detections. 6. Results We perform total motion capture using our two models, Frankenstein and Adam, on various challenging sequences. Figure 6: Total body reconstruction results on various human body motions. For each example scene, the fitting results from three different models are shown by different colors (pink for SMPL [33], silver for Frankenstein, and gold for Adam). For experiments, we use the dataset captured in the CMU Panoptic Studio [26]. We use 140 VGA cameras to reconstruct 3D body keypoints, 480 VGA cameras for feet, and 31 HD cameras for faces and hands keypoints, and 3D point clouds. We compare the fits produced by our models with the body-only SMPL model [33]. 6.1. Quantitative Evaluation We evaluate how well each model can match a moving person by measuring overlap with the ground truth silhouette across 5 different viewpoints for a 10 second range of motion sequence. To obtain the ground truth silhouette, we run a background subtraction algorithm using a Gaussian model for the background of each pixel with a postprocessing to remove noise by morphological transforms. As an evaluation metric, we compute the percentage of overlapping region compared to the union between the GT silhouettes and the rendered forground masks after fitting each model. Here, we compare the fitting results of 3 different models: SMPL, our Frankenstein, and our Adam models. An example result is shown in Figure 5, and the results are shown in Fig 5 and Table 1. We first compare accuracy between SMPL and Frankenstein model by using only 3D keypoints as measurement cues. The major source of im- provement of Frankenstein over SMPL is in the articulated hand model (by construction, the body is almost identical), as seen in Fig. 5 (a). Including ICP term as cues provides better accuracy. Finally in the comparison between our two models, they show almost similar performance. Ideally we expect the Adam outperforms Frankenstein because it has more expressive power for hair and clothing, and it shows it shows better performance in a certain body shape (frame 50-75 in Fig 5). However, Adam sometimes produces artifacts showing lower accuracy; it tends to generate thinner legs, mainly due to poor 3D point cloud reconstructions on the source data on which Adam is trained. However, Adam is simpler for total body motion capture purpose and has potential to be improved once a large scale dataset is available with more optimized capture setup. 6.2. Qualitative Results We run our method on sequences where face and hand motions are naturally emerging with body motions. The sequences include short range of motions for 70 people used to build Adam, social communications of multiple people, a furniture building sequence with dexterous hand motions, musical performances such as cello and guitars, and commonly observable daily motions such as keyboard typing. Most of these sequences are rarely demonstrated in previous markerless motion capture methods since capturing subtle details are the key to achieve the goal. The example results are shown in Figure 6. Here, we also qualitatively compare our models (in silver color for Frankenstein, and gold for Adam) with the SMPL model (in pink) [33]. It should be noted that the total body motion capture results based on our models produce much better realism for the scene by capturing the subtle details from hands and faces. Our results are best shown in the accompanying videos. 7. Discussion We present the first markerless method to capture total body motion including facial expression, coarse body motion from torso and limbs, and hand gestures at a distance. To achieve this, we present two types of models which can express motion in each of the parts. Our reconstruction results show compelling and realistic results, even when using only sparse 3D keypoint detections to drive the models. References [1] S. Agarwal, K. Mierle, and Others. Ceres solver. http: //ceres-solver.org. [2] D. Anguelov, P. Srinivasan, D. Koller, S. Thrun, J. Rodgers, and J. Davis. Scape: shape completion and animation of people. In ToG, 2005. [3] A. Baak, M. Müller, G. Bharaj, H.-P. Seidel, and C. Theobalt. A data-driven approach for real-time full body pose reconstruction from a depth camera. In Consumer Depth Cameras for Computer Vision. Springer, 2013. [4] L. Ballan, A. Taneja, J. Gall, L. Van Gool, and M. Pollefeys. Motion capture of hands in action using discriminative salient points. In ECCV, 2012. [5] T. Beeler, B. Bickel, P. Beardsley, B. Sumner, and M. Gross. High-quality single-shot capture of facial geometry. In TOG, 2010. [6] T. Beeler, F. Hahn, D. Bradley, B. Bickel, P. Beardsley, C. Gotsman, R. Sumner, and M. Gross. High-quality passive facial performance capture using anchor frames. In TOG, 2011. [7] R. Birdwhistell. Kinesics and context: Essays on body motion communication. In University of Pennsylvania Press, Philadelphia., 1970. [8] F. Bogo, A. Kanazawa, C. Lassner, P. V. Gehler, J. Romero, and M. J. Black. Keep it SMPL: automatic estimation of 3d human pose and shape from a single image. In CoRR, 2016. [9] D. Bradley, W. Heidrich, T. Popa, and A. Sheffer. High resolution passive facial performance capture. In TOG, 2010. [10] C. Bregler, J. Malik, and K. Pullen. Twist based acquisition and tracking of animal and human kinematics. In IJCV, 2004. [11] T. Brox, B. Rosenhahn, J. Gall, and D. Cremers. Combined region and motion-based 3D tracking of rigid and articulated objects. In TPAMI, 2010. [12] C. Cao, D. Bradley, K. Zhou, and T. Beeler. Real-time highfidelity facial performance capture. In TOG, 2015. [13] C. Cao, Y. Weng, S. Zhou, Y. Tong, and K. Zhou. Facewarehouse: A 3d facial expression database for visual computing. In TVCG, 2014. [14] Z. Cao, T. Simon, S.-E. Wei, and Y. Sheikh. Realtime multiperson 2d pose estimation using part affinity fields. In CVPR, 2017. [15] K. M. Cheung, S. Baker, and T. Kanade. Shape-fromsilhouette across time part i: Theory and algorithms. In IJCV, 2005. [16] S. Corazza, L. Mündermann, E. Gambaretto, G. Ferrigno, and T. P. Andriacchi. Markerless Motion Capture through Visual Hull, Articulated ICP and Subject Specific Model Generation. In IJCV, 2010. [17] E. de Aguiar, C. Stoll, C. Theobalt, N. Ahmed, H.-P. Seidel, and S. Thrun. Performance capture from sparse multi-view video. In SIGGRAPH, 2008. [18] F. De la Torre, W.-S. Chu, X. Xiong, F. Vicente, X. Ding, and J. F. Cohn. Intraface. In FG, 2015. [19] A. Elhayek, E. Aguiar, A. Jain, J. Tompson, L. Pishchulin, M. Andriluka, C. Bregler, B. Schiele, and C. Theobalt. Efficient convnet-based marker-less motion capture in general scenes with a low number of cameras. In CVPR, 2015. [20] Y. Furukawa and J. Ponce. Dense 3d motion capture from synchronized video streams. In CVPR, 2008. [21] J. Gall, C. Stoll, E. De Aguiar, C. Theobalt, B. Rosenhahn, and H.-P. Seidel. Motion capture using joint skeleton tracking and surface estimation. In CVPR. IEEE, 2009. [22] P. Garrido, L. Valgaerts, C. Wu, and C. Theobalt. Reconstructing detailed dynamic face geometry from monocular video. In TOG, 2013. [23] D. Gavrila and L. Davis. Tracking of humans in action: A 3-D model-based approach. In ARPA Image Understanding Workshop, 1996. [24] A. Ghosh, G. Fyffe, B. Tunwattanapong, J. Busch, X. Yu, and P. Debevec. Multiview face capture using polarized spherical gradient illumination. In TOG, 2011. [25] G. Hidalgo, Z. Cao, T. Simon, S.-E. Wei, H. Joo, and Y. Sheikh. Openpose. https://github.com/ CMU-Perceptual-Computing-Lab/openpose. [26] H. Joo, H. Liu, L. Tan, L. Gui, B. Nabbe, I. Matthews, T. Kanade, S. Nobuhara, and Y. Sheikh. Panoptic studio: A massively multiview system for social motion capture. In ICCV, 2015. [27] H. Joo, H. S. Park, and Y. Sheikh. Map visibility estimation for large-scale dynamic 3d reconstruction. In CVPR, 2014. [28] H. Joo, T. Simon, X. Li, H. Liu, L. Tan, L. Gui, S. Banerjee, T. Godisart, B. Nabbe, I. Matthews, et al. Panoptic studio: A massively multiview system for social interaction capture. In TPAMI, 2017. [29] R. Kehl and L. V. Gool. Markerless tracking of complex human motions from multiple views. In CVIU, 2006. [30] C. Keskin, F. Kıraç, Y. E. Kara, and L. Akarun. Hand pose estimation and hand shape classification using multi-layered randomized decision forests. In ECCV, 2012. [31] H. Li, J. Yu, Y. Ye, and C. Bregler. Realtime facial animation with on-the-fly correctives. In TOG, 2013. [32] Y. Liu, J. Gall, C. Stoll, Q. Dai, H.-P. Seidel, and C. Theobalt. Markerless motion capture of multiple characters using multiview image segmentation. In TPAMI, 2013. [33] M. Loper, N. Mahmood, J. Romero, G. Pons-Moll, and M. J. Black. Smpl: A skinned multi-person linear model. In TOG, 2015. [34] D. Mehta, S. Sridhar, O. Sotnychenko, H. Rhodin, M. Shafiei, H. Seidel, W. Xu, D. Casas, and C. Theobalt. Vnect: Real-time 3d human pose estimation with a single RGB camera. In TOG, 2017. [35] A. Newell, K. Yang, and J. Deng. Stacked hourglass networks for human pose estimation. In ECCV, 2016. [36] I. Oikonomidis, N. Kyriazis, and A. A. Argyros. Tracking the articulated motion of two strongly interacting hands. In CVPR, 2012. [37] G. Pons-Moll, J. Romero, N. Mahmood, and M. J. Black. Dyna: A model of dynamic human shape in motion. In TOG, 2015. [38] J. Romero, D. Tzionas, and M. J. Black. Embodied hands: Modeling and capturing hands and bodies together. In TOG, 2017. [39] T. Sharp, C. Keskin, D. Robertson, J. Taylor, J. Shotton, D. Kim, C. Rhemann, I. Leichter, A. Vinnikov, Y. Wei, et al. Accurate, robust, and flexible real-time hand tracking. In CHI, 2015. [40] J. Shotton, A. Fitzgibbon, M. Cook, and T. Sharp. Real-time human pose recognition in parts from single depth images. In CVPR, 2011. [41] T. Simon, H. Joo, I. Matthews, and Y. Sheikh. Hand keypoint detection in single images using multiview bootstrapping. In CVPR, 2017. [42] S. Sridhar, F. Mueller, A. Oulasvirta, and C. Theobalt. Fast and robust hand tracking using detection-guided optimization. In CVPR, 2015. [43] S. Sridhar, A. Oulasvirta, and C. Theobalt. Interactive markerless articulated hand motion tracking using RGB and depth data. In ICCV, 2013. [44] C. Stoll, N. Hasler, J. Gall, H.-P. Seidel, and C. Theobalt. Fast articulated motion tracking using a sums of gaussians body model. In ICCV, 2011. [45] X. Sun, Y. Wei, S. Liang, X. Tang, and J. Sun. Cascaded hand pose regression. In CVPR, 2015. [46] D. Tang, H. Jin Chang, A. Tejani, and T.-K. Kim. Latent regression forest: Structured estimation of 3D articulated hand posture. In CVPR, 2014. [47] J. Thies, M. Zollhofer, M. Stamminger, C. Theobalt, and M. Nießner. Face2face: Real-time face capture and reenactment of rgb videos. In CVPR, 2016. [48] D. Tome, C. Russell, and L. Agapito. Lifting from the deep: Convolutional 3d pose estimation from a single image. In CVPR, 2017. [49] J. J. Tompson, A. Jain, Y. LeCun, and C. Bregler. Joint training of a convolutional network and a graphical model for human pose estimation. In NIPS, 2014. [50] D. Tzionas, L. Ballan, A. Srikantha, P. Aponte, M. Pollefeys, and J. Gall. Capturing hands in action using discriminative salient points and physics simulation. In IJCV, 2016. [51] L. Valgaerts, C. Wu, A. Bruhn, H.-P. Seidel, and C. Theobalt. Lightweight binocular facial performance capture under uncontrolled lighting. In TOG, 2012. [52] D. Vlasic, I. Baran, W. Matusik, and J. Popović. Articulated mesh animation from multi-view silhouettes. In TOG, 2008. [53] C. Wan, A. Yao, and L. Van Gool. Direction matters: hand pose estimation from local surface normals. In arXiv preprint arXiv:1604.02657, 2016. [54] S.-E. Wei, V. Ramakrishna, T. Kanade, and Y. Sheikh. Convolutional pose machines. In CVPR, 2016. [55] H. Woltring. New possibilities for human motion studies by real-time light spot position measurement. In Biotelemetry, 1973. [56] C. Wu, D. Bradley, M. Gross, and T. Beeler. An anatomically-constrained local deformation model for monocular face capture. In TOG, 2016. [57] C. Xu and L. Cheng. Efficient hand pose estimation from a single depth image. In ICCV, 2013. [58] Q. Ye, S. Yuan, and T.-K. Kim. Spatial attention deep net with partial pso for hierarchical hybrid hand pose estimation. In ECCV, 2016. [59] W. Zhao, J. Chai, and Y.-Q. Xu. Combining marker-based mocap and rgb-d camera for acquiring high-fidelity hand motion data. In ACM SIGGRAPH/eurographics symposium on computer animation, 2012. [60] X. Zhou, S. Leonardos, X. Hu, and K. Daniilidis. 3d shape estimation from 2d landmarks: A convex relaxation approach. In CVPR, 2015. [61] X. Zhou, X. Sun, W. Zhang, S. Liang, and Y. Wei. Deep kinematic pose regression. In ECCV Workshop on Geometry Meets Deep Learning, 2016.
1cs.CV
Inference of High-dimensional Autoregressive Generalized Linear Models Eric C. Hall∗, Garvesh Raskutti†, and Rebecca M. Willett‡ arXiv:1605.02693v2 [stat.ML] 24 Jun 2017 June 27, 2017 Abstract Vector autoregressive models characterize a variety of time series in which linear combinations of current and past observations can be used to accurately predict future observations. For instance, each element of an observation vector could correspond to a different node in a network, and the parameters of an autoregressive model would correspond to the impact of the network structure on the time series evolution. Often these models are used successfully in practice to learn the structure of social, epidemiological, financial, or biological neural networks. However, little is known about statistical guarantees on estimates of such models in non-Gaussian settings. This paper addresses the inference of the autoregressive parameters and associated network structure within a generalized linear model framework that includes Poisson and Bernoulli autoregressive processes. At the heart of this analysis is a sparsity-regularized maximum likelihood estimator. While sparsity-regularization is well-studied in the statistics and machine learning communities, those analysis methods cannot be applied to autoregressive generalized linear models because of the correlations and potential heteroscedasticity inherent in the observations. Sample complexity bounds are derived using a combination of martingale concentration inequalities and modern empirical process techniques for dependent random variables. These bounds, which are supported by several simulation studies, characterize the impact of various network parameters on estimator performance. 1 Autoregressive Processes in High Dimensions Imagine recording the times at which each neuron in a biological neural network fires or “spikes”. Neuron spikes can trigger or inhibit spikes in neighboring neurons, and understanding excitation and inhibition among neurons provides key insight into the structure and operation of the underlying neural network [1, 2, 3, 4, 5, 6, 7]. A central question in the design of this experiment is “for how long must I collect data before I can be confident that my inference of the network is accurate?” Clearly the answer to this question will depend not only on the number of neurons being recorded, but also on what we may assume a priori about the network. Unfortunately, existing statistical and machine learning theory give little insight into this problem. Neural spike recordings are just one example of a non-Gaussian, high-dimensional autoregressive processes, where the autoregressive parameters correspond to the structure of the underlying network. This paper examines a broad class of such processes, in which each observation vector is modeled using an exponential family distribution. In general, autoregressive models are a widely-used mechanism for studying time series in which each observation depends on the past sequence of observations. Inferring these dependencies is a key challenge in many settings, including finance, neuroscience, epidemiology, and sociology. A precise understanding of these dependencies facilitates more accurate predictions and interpretable models of the forces that determine the distribution of each new observation. ∗ E. C. Hall is with the Wisconsin Institute of Discovery, University of Wisconsin-Madison, Madison, WI, 53706, USA. e-mail: [email protected] University of Wisconsin-Madison, Madison, WI, 53706, USA. e-mail: [email protected] ‡ R. M. Willett is with the Department of Electrical and Computer Engineering, University of Wisconsin-Madison, Madison, WI 53706, USA. e-mail: [email protected]. We gratefully acknowledge the support of the awards NSF CCF-1418976, NIH 1 U54 AI117924-01, 14AFOSR-1103, and NSF DMS-1407028. † G. Raskutti is with the Department of Statistics, 1 Much of the autoregressive modeling literature focuses on Gaussian noise and perturbation models, but in many settings Gaussian noise fails to capture the data at hand. This challenge arises, for instance, when observations correspond to count data – e.g., when we collect data by counting individual events such as neurons spiking. Another example arises in epidemiology, where a common model involves infection traveling stochastically from one node in a network to another based on the underlying network structure in a process known as an “epidemic cascade” [8, 9, 10, 11]. These models are used to infer network structure based on the observations of infection time, which is closely related to the Bernoulli autoregressive model studied in this paper. Further examples arise in a variety of applications, including vehicular traffic analysis [12, 13], finance [14, 15, 16, 17], social network analysis [18, 19, 20, 21, 22], biological neural networks [1, 2, 3, 4, 5, 6, 7], power systems analysis [23], and seismology [24, 25]. Because of their prevalence across application domains, time series count data (cf. [26, 27, 28, 29, 30]) and other non-Gaussian autoregressive processes (cf. [31, 32, 33]) have been studied for decades. Although a substantial fraction of the this literature is focused on univariate time series, this paper focuses on multivariate settings, particularly where the vector observed at each time is high-dimensional relative to the duration of the time series. In the above examples, the dimension of the each observation vector would be the number of neurons in a neural network, the number of people in a social network, or the number of interacting financial instruments. In this paper, we conduct a detailed investigation of a particular family of time series that we call the vector generalized linear autoregressive (GLAR) model. In addition, we examine our results for two members of this family: the Bernoulli autoregressive and the log-linear Poisson autoregressive (PAR) model. The PAR model has been explicitly studied in [34, 35, 36] and is closely related to the continuous-time Hawkes point process model [37, 38, 39, 40, 41] and the discrete-time INGARCH model [42, 43, 44, 45]. However, that literature does not contain the sample complexity results presented here. The INGARCH literature is focused on low-dimensional settings, typically univariate, whereas we are focused on the high-dimensional setting where the number of nodes or channels is high relative to the number of observations. Additionally, existing sample complexity bounds for Hawkes processes [40] focus on a linear (as opposed to log-linear) model with samples collected after reaching the stationary distribution. The log-linear model is largely used in practice both for numerical reasons and modeling efficacy for real world data. We note that linear models can predict inadmissible negative event rates, whereas the log-linear model enforces the feasibility of the predicted model. The log-linear and linear models exhibit very different behaviors in their properties and stationary distributions, making this work a significant step forward from the analysis of linear models. The extension of these prior investigations to the high-dimensional, non-stationary setting is non-trivial and requires the development of new theory and methods. This paper focuses on estimating the parameters of a vector GLAR model from a time series of observations. We adopt a regularized likelihood estimation approach that extends and generalizes our previous work on Poisson inverse problems (cf. [46, 47, 48, 49]). While similar algorithms have been proposed in the above-mentioned literature, little is known about their sample complexity or how inference accuracy scales with the key parameters such as the size of the network or number of entities observed, the time spent collecting observations, and the density of edges within the network or dependencies among entities. There has been a large body of work providing theoretical results for certain high-dimensional models under lowdimensional structural constraints (see e.g., [50, 49, 51, 52, 53, 54, 55, 56, 41]). The majority of prior work has focused on the setting where samples are independent and/or follow a Gaussian distribution. In the GLAR setting, however, non-Gaussianity and temporal dependence among observations can make such analyses particularly challenging and beyond the scope of much current research in high-dimensional statistical inference (see [57] for an overview). Perhaps the most closely related prior work to our setting in the high-dimensional setting is [58]. In [58], several performance guarantees are provided for different linear Gaussian problems with dependent samples including the Gaussian autoregressive model. Since [58] deals exclusively with linear Gaussian models, they exploit many properties of linear systems and Gaussian random variables that cannot be applied to non-Gaussian and non-linear autoregressive models. In particular, compared to standard autoregressive processes with Gaussian noise, in the GLAR setting the conditional variance of each observation is dependent on previous data instead of being a constant equal to the noise variance. Works such as [49, 50, 59] provide results for non-Gaussian models but still rely on independent observations. Weighted LASSO estimators for Hawkes processes address some of these challenges in a continuoustime setting [40]. To see why GLAR analysis can be challenging, consider momentarily a LASSO estimator of the autoregressive 2 parameters. In the classical LASSO setting, the accuracy of the estimate depends on characteristics of the Gram matrix associated with the design or sensing matrix. This matrix may be stochastic, but it is usually considered independent of the observations and performance guarantees for the estimator depend on the assumption that the matrix obeys certain properties (e.g., the restricted eigenvalue condition [60]). In our setting, however, the “design” matrix is a function of the observed data, which in turn depends on the true underlying network or autoregressive model parameters. Thus a key challenge in the analysis of a LASSO-like estimator in the GLAR setting involves showing that the data- and network-dependent Gram matrix exhibits properties that ensure reliable estimates. In this paper, we develop performance guarantees for the vector GLAR model that provide sample complexity guarantees in the high-dimensional setting under low-dimensional structural assumptions such as sparsity of the underlying autoregressive parameters. In particular, our main contributions are the following: • Formulation of a maximum penalized likelihood estimator for vector GLAR models in high-dimensional settings with sparse structure. • Mean-squared-error bounds on the proposed estimator as a function of the problem dimension, sparsity, and the number of observations in time for general GLAR models. • Application of our general result to obtain sample complexity bounds for Bernoulli and Poisson GLAR models. • Analysis techniques that simultaneously leverage martingale concentration inequalities, empirical risk minimization analysis, and covering arguments for high-dimensional linear regression. This problem is substantially harder than the Gaussian case from a technical perspective because we can not exploit linearity and spectral properties of linear Gaussian time-series. In our case we have signal-dependent noise, and we can not exploit the same spectral properties. Additionally, with non-Gaussian noise, we are not guaranteed strong convexity of the objective function in the entire domain of possible solutions, and so extra care must be taken to define regions of strong convexity. Thus we have to develop new theoretical techniques, using new concentration bounds and a more refined analysis. The remainder of the paper is structured as follows: Section 2 introduces the generalized linear autoregressive model and Section 3 presents the novel risk bounds associated with the RMLE of the process. We then use our theory to examine two special cases (the Poisson and Bernoulli models) in Sections 3.1 and 3.2, respectively. The main proofs are provided in Section 4, while supplementary lemmas are deferred to the appendix. Finally, Section 5 contains a discussion of our results, their implications in different settings, and potential avenues for future work. 2 Problem Formulation In this paper we consider the generalized linear autoregressive model: Xt+1,m |Xt ∼ p(νm + a∗> m Xt ), (1) ∗ M is an unknown where Xt+1,m is the mth observation of Xt+1 , (Xt )∞ t=0 are M -variate vectors and a ∈ [amin , amax ] M parameter vector, ν ∈ [νmin , νmax ] is a known, constant offset parameter, and p is an exponential family probability distribution. Specifically, X ∼ p(θ) means that the distribution of the scalar X is associated with the density p(x|θ) = h(x) exp[φ(x)θ − Z(θ)], where Z(θ) is the so-called log partition function, φ(x) is the sufficient statistic of the data, and h(x) is the base measure of the distribution. Distributions that fit such assumptions include the Poisson, Bernoulli, binomial, negative binomial and exponential. According to this model, conditioned on the previous data, the elements of Xt are independent of one another and each have a scalar natural parameter. The input of the function p in (1) is the natural parameter for the distribution, i.e., ν + a∗> m Xt is the natural parameter of the conditional distribution at time t + 1 for observation m. A similar, but low-dimensional, model appears in [36], but that work focuses on maximum likelihood and weighted least squares estimators in univariate settings that are known to perform poorly in high-dimensional settings (as is our focus). For these distributions it is straightforward to show when they have strongly convex log-partition functions, which will be crucial to our analysis. Note that this distribution has 00 ∗> E[φ(Xt+1,m )|Xt ] = Z 0 (ν + a∗> m Xt ) and Var(φ(Xt+1,m )|Xt ) = Z (ν + am Xt ), the first and second derivatives 3 of the log-partition function, respectively. Compared to standard autoregressive processes with Gaussian noise, the conditional variance is now dependent on previous data instead of being a constant equal to the noise variance. We can state the conditional distribution explicitly as: P(Xt+1 |Xt ) = M Y  ∗> h(Xt+1,m ) exp φ(Xt+1,m )(νm + a∗> m Xt ) − Z(νm + am Xt ) , m=1 where h is the base-measure of the distribution p. Using this equation and observations, we can find an estimate for th the network A∗ which is constructed row-wise by a∗m . (i.e. a∗> row of A∗ ). m is the m T In general, we observe T samples (Xt )t=0 and our goal is to infer the matrix A∗ . In the setting where M is large, we need to impose structural assumptions on A∗ in order to have strong performance guarantees. Let S := {(`, m) ∈ {1, . . . , M }2 : A∗`,m 6= 0}. In this paper we assume that the matrix A∗ is s-sparse, meaning that A∗ belongs to the following class:  As = A ∈ [amin , amax ]M ×M | kAk0 ≤ s . where kAk0 := more, we define PM PM `=1 m=1 1(|A`,m | 6= 0) and 1(·) is the indicator function. That is, we assume |S| = s. Furtherρm , ka∗m k0 ρ , max ρm , and m ∗ so ρ is the maximum number of non-zero elements in a row of A . We might like to estimate A∗ via a constrained maximum likelihood estimator by solving the following optimization problem:  T −1 M  1 XX > > Z(νm + am Xt ) − am Xt φ(Xt+1,m ) (2) arg min A∈As T t=0 m=1 or its Lagrangian form arg min A∈[amin ,amax ]M ×M  T −1 M  1 XX > Z(νm + a> X ) − a X φ(X ) + λkAk0 . t+1,m m t m t T t=0 m=1 (3) However, these are difficult optimization problems due to the non-convexity of the `0 norm. Therefore, we instead find an estimator using the element-wise `1 regularizer, the convex relaxation of the `0 function, along with the negative log-likelihood to create the following estimator: b= A arg min A∈[amin ,amax ]M ×M  T −1 M  1 XX > Z(νm + a> X ) − a X φ(X ) + λkAk1,1 , t+1,m m t m t T t=0 m=1 (4) PM where k · k1 is the `1 norm and kAk1,1 = m=1 kam k1 . The above is the regularized maximum likelihood estimator (RMLE) for the problem, which attempts to find an estimate of A∗ which both fits the empirical distribution of the data while also having many zero-valued elements. Notice that we assume the elements of A∗ are bounded and we use these bounds in the estimator definition. One reason for this is that bounds on the elements of A∗ can enforce stability. If the elements of A∗ are allowed to be arbitrarily large, the system may become unstable and therefore impossible to make proper estimates. Knowing loose bounds facilitates our analysis but in practice does not appear to be necessary. In the experiment section we discuss choosing these bounds in the estimation process. We note that while we assume that ν is a known constant vector, if we assume there is some unknown constant offset that we would like to estimate, we can fold it into the estimation of A. For instance, consider appending ν as an extra column of the matrix A∗ , and appending a 1 to the end of each observation Xt . Then for indices 1, . . . , M the ∗ observation model becomes Xt+1,m |Xt ∼ p(a∗> m Xt ) where am and Xt are the appended versions. We can then find b the RMLE of this distribution to find both A and νb, but for clarity of exposition we assume a known ν. 4 Estimating the network parameters in the autoregressive setting with Gaussian observations can be formulated as a sparse inverse problem with connections to the well-known LASSO estimator. Consider the problem of estimating the a∗m . Define     X2,m X1,1 X1,2 ··· X1,M  X3,m   X2,1 X2,2 ··· X2,M      ym =  .  and X =  . , .. . . ..  ..   ..  . . . XT −1,1 XT,m XT −1,2 ··· XT −1,M th where ym is the time series of observed counts associated with the m node and X is a matrix of the observed counts associated with all nodes. Then ym = Xa∗m + m , where m := ym − Xa∗m is noise, and we could consider the LASSO estimator for each m: âm = arg min kym − Xak22 + λkak1 . a However, there are two key challenges associated with the LASSO estimator in this context: (a) the squared residual term does not account for the non-Gaussian statistics of the observations and (b) the “design matrix” is data-dependent and hence a function of the unknown underlying network. In classical LASSO analyses, performance bounds depend on the design matrix satisfying the restricted eigenvalue condition or restricted isometry property or some related condition; it is relatively straightforward to ensure such a condition is satisfied when the design matrix is independent of the data, but much more challenging in the current context. As a result, despite the fact that we face a sparse inverse problem, the existing LASSO literature does not address the subject of this proposal. 3 Main Results b − A∗ k2 , the difference in Frobenius norm between the In this section, we turn our attention to deriving bounds for kA F b and the true generating network, A∗ , under the assumption that the true regularized maximum likelihood estimator, A, network is sparse. We assume that A∗ ∈ As . Recall ρ , max ka∗m k0 is the maximum number of non-zero elements m in a row of A∗ . First we state assumptions on the GLAR process which are sufficient conditions to ensure the RMLE admits small errors. Asumption 1. We assume that for any realization of the process defined by Equation 1 there exists a subset of |T | observations {XTt }t=1 for T ⊆ {0, 1, . . . , T − 1} that satisfies the conditions: 1. There exists a constant U such that U ≥ maxt∈T kXt k∞ where U is independent of T . 2. Z(·) is σ-strongly convex on a domain determined by U : Z(x) ≥ Z(y) + Z 0 (y)(x − y) + σ kx − yk22 2 for all x, y ∈ [−ν̃ − 9ρãU, ν̃ + 9ρãU ] where ν̃ , max(|νmin |, |νmax |), and ã , max(|amin |, |amax |), where σ is independent of T . 3. The smallest eigenvalue of Γt , E[XTt XT>t |XTt−1 ] is lower bounded by ω > 0, which is independent of T . We define the constant ξ as a constant such that ξ ≤, |T |/T , which will be determined in part by the constant U , and can be set such that ξ is very close to 1. For ξ ≈ 1, Assumption 1 means most of the observed data is bounded independent of T . The assumption allows us to analyze time series in which the maximum of a series of iid random variables can grow with T , but any percentile |T | is bounded by a constant. Our analysis will then be conducted on the bounded series {XTt }t=1 . The assumptions are proven to be true with high probability for the Bernoulli and Poisson cases in Sections 3.1 and 3.2, respectively, and the corresponding values of U , σ, ξ, and ω are computed explicitly. 5 Theorem 1. Assume λ ≥ max1≤m≤M PT −1  2 T t=0  φ(Xt+1,m ) − E[φ(Xt+1,m )|Xt ] Xt ∞ b be the RMLE , and let A for a process which obeys the conditions of Assumption 1. For any row of the estimator and for any δ ∈ (0, 1), with probability at least 1 − δ, 144 kb am − a∗m k22 ≤ 2 2 2 ρm λ2 ξ σ ω   cρ2 ρm log(2M ) + log(1/δ) where c is independent of M, T, ρ and s. Furthermore, for T ≥ ωm 2 2 ω b − A∗ k2F ≤ kA with probability greater than 1 − δ for T ≥ cρ2 ω2 ρ ω2 144 sλ2 ξ2 σ2 ω2   + 1 log(2M ) + log(1/δ) . To apply Theorem 1 to specific GLAR models, we need to provide bounds on λ, as well as σ, ω, U and ξ for Assumption 1. We do this in the next section for Bernoulli and Poisson GLAR models. We can compare the results of Theorem 1 to the related results of [58]. In that work they arrive at rates for the Gaussian autoregressive process that are equivalent with respect to the sparsity parameter, number of observations and regularization parameter. However, we incur slightly different dependencies on ξ, σ and ω. These are due mainly to the fact that our bounds hold for a wide family of distributions and not just the Gaussian case, which has nice properties related to restricted strong convexity and specialized concentration inequalities. Additionally, the way λ is defined is very similar, but bounding λ for a non-Gaussian distribution will result in extra log factors. It is an open question whether this bound is rate optimal in the general setting. 3.1 Example 1: Bernoulli Distribution For the Bernoulli distribution we have the following autoregressive model:   1 Xt+1,m |Xt ∼ Bernoulli . 1 + exp(−ν − a∗> m Xt ) (5) The first observation about this model is that the sufficient statistic φ(x) = x and the log-partition function Z(θ) = log(1 + exp(θ)), which is strongly convex when the absolute value of θ is bounded. One advantage of this model is that the observations are inherently bounded due to the nature of the Bernoulli distribution, so T = [0, 1, . . . , T − 1] and ξ = 1. Using this observation we derive the strong convexity parameter of Z on the bounded range, thus σ = (3 + exp(ν̃ + 9ρã))−1 . To derive rates from Theorem 1, we must prove that Assumption 1 holds; this is shown with high-probability by Theorem 2. Theorem 2. For a sequence Xt generated from the Bernoulli autoregressive process with the matrix A∗ with and the vector ν, we have the following properties: 1. The smallest eigenvalue of the matrix Γt = E[Xt Xt> |Xt−1 ] is lower bounded by ω = (3 + exp(ν̃ + ρã))−1 . 2. Assuming 1 ≤ t ≤ T and that T ≥ 2 and log(M T ) ≥ 1, then max 1≤i,j≤M T −1 1 X 3 log(M T ) √ Xt−1,i (Xt,j − E[Xt,j |Xt−1 ]) ≤ T t=0 T with probability at least at least 1 − 1 MT . Using these results we get the final sample error bounds for the Bernoulli autoregressive process. 6 T) √ Corollary 1. The RMLE for the Bernoulli autoregressive process defined by Equation 5, and setting λ = 6 log(M T has error bounded by 2  b 2F ≤ C 3 + eν̃+9ρã 4 s log (M T ) kA∗ − Ak ξ2T    2 ρ 2 with probability at least 1 − δ for T ≥ max δM , cρ for constants C, c > 0 which 1 + log(2M ) + log(2/δ) 2 2 ω ω are independent of M, T, s and ρ. The lower bound on the number of observations T comes from needing to satisfy the conditions of both parts of Theorems 1 and 2. In order to get this statement we use a union bound over the high probability statements of Theorem 1 described in (9) and Theorem 2 which holds with probability greater than 1 − M1T . 3.2 Example 2: Poisson Distribution In this section, we derive the relevant values to get error bounds for the vector autoregressive Poisson distribution. Under this model we have Xt+1,m |Xt ∼ Poiss(exp(ν + a∗> m Xt )). We assume that amax = 0 for stability purposes, thus we are only modeling inhibitory relationships in the network. Deriving the sufficient statistic and log-partition function yields φ(x) = x and Z(θ) = exp(θ). The next important values are the bounds on the magnitude of the observations, which will both ensure the strong convexity of Z and the stability of the process. Lemma 1. For the Poisson autoregressive process generated with A∗ ∈ [amin , 0]M ×M and constant vector ν ∈ [νmin , νmax ]: 1. If log M T ≥ 1, there exists constants C and c which depend on the value νmax , but are independent of T, M, s and ρ such that 0 ≤ Xt,m ≤ C log(M T ) with probability at least 1 − e−c log(M T ) for all 1 ≤ t ≤ T and 1 ≤ m ≤ M. 2. For any α ∈ (0, 1) such that αM T is an integer, there exist constants U and c which depend on the values of νmax and α, but independent of T, M, s and ρ, such that with probability at least 1 − e−cM T , 0 ≤ Xt,m ≤ U for at least αM T of the indices. We define T to be these αM T indices. As a consequence of Lemma 1, we have kXt k∞ ≤ U for at least ξT values of t ∈ {1, 2, . . . , T } where ξ = 1 − (1 − α)M . We additionally assume that U is large enough such that α > MM−1 and therefore ξ ∈ (0, 1). Using this Lemma,we prove that Assumption 1 holds with high-probability, by deriving the strong convexity parameter of Z and a lower bound on the smallest eigenvalue of Γt . In the Poisson case, Z(·) = exp(·) and therefore the strong convexity parameter, σ = exp(−ν̃ + 9ρamin U ). Theorem 3. For a sequence Xt generated from the Poisson autoregressive process with the matrix A∗ , with all nonpositive elements, and the vector ν, we have the following properties 1. The smallest eigenvalue of the matrix Γt = E[XTt XT>t |XTt−1 ], for consecutive indices Tt and Tt−1 in T as defined in Assumption 1, is lower bounded by 4ξ 5 exp(νmin + ρamin U ). 2. Assuming Xt,m ≤ C log(M T ) for all 1 ≤ m ≤ M and 1 ≤ t ≤ T and that T ≥ 2 and log(M T ) ≥ 1, then max 1≤i,j≤M T −1 1 X log3 (M T ) √ Xt−1,i (Xt,j − E[Xt,j |Xt−1 ]) ≤ 4C 2 eνmax T t=0 T with probability at least at least 1 − exp(−c log(M T )) for some c > 0 independent of ρ, s, M and T . Using Theorem 3, we can find the error bounds for the PAR process by using the result of Theorem 1. 7 800 10 30 50 10 30 50 Squared Frobenius Error Times T Squared Frobenius Error 700 10 0 600 500 400 300 200 100 100 150 200 250 300 350 0 50 400 100 150 200 T 300 350 400 450 T (b) MSE ·T vs T (a) MSE vs. T 8 0.35 Squared Frobenius Error Divided by Sparsity 100 250 400 7 6 Squared Frobenius Error 250 5 4 3 2 1 0 100 250 400 0.3 0.25 0.2 0.15 0.1 0.05 0 0 10 20 30 40 50 60 0 10 Sparsity 20 30 40 50 60 Sparsity (c) MSE vs s (d) MSE/s vs s Figure 1: The top row of plots shows the MSE behavior over a range of T values, from 100 to 400 all less than or equal to M 2 = 400 , where (a) is the MSE and (b) is the MSE multiplied by T to show that the MSE is behaving as 1/T . The bottom row shows the MSE behavior over a range of s values, where (c) shows MSE and (d) shows MSE divided by s to show that the MSE is linear is s. In all plots the median value of 100 trials is shown, with error bars denoting the middle 50 percentile. Corollary 2. Using the results of Theorem 1 and using the Poisson autoregressive model with A∗ with all non-positive values, the RMLE admits the overall error rate of k − A∗ k2F ≤ C exp(20|amin |U ρ) with probability at least 1 − δ for T ≥ max which are independent of M, T, s and ρ   4 c δM 2 , cρ ω2 ρ ω2 s log6 (M T ) ξ3T   + 1 log(2M ) + log(4/δ) for constants C, c > 0 Again, the lower bound on the number of observations comes from combining the high probability statements of each of the constituent parts of the corollary in the same way as was done in the Bernoulli case. In this case all of Theorem 1, both parts of Lemma 1 and Theorem 3 need to hold. 3.3 Experimental Results We validate our theoretical results with experimental results performed on synthetically generated data using the Poisson autoregressive process. We generate many trials of synthetic data with known underlying parameters and then compare the estimated values. For all trials the constant offset vector ν is set identically at 0, and the 20 × 20 matrices A∗ are set such that s randomly assigned values are in the range [−1, 0] and with constant ρ = 5. Data is then generated according the process described in Equation 1 with the Poisson distribution. X0 is chosen as a 20 dimensional vector drawn randomly from Poisson(1), then T observations are used to perform the estimation. The parameters s and T are then varied over a wide range of values. For each (s, T ) pair 100 trials are performed, the 8 (a) Ground Truth A∗ Matrix (b) Estimate for T = 100 (c) Estimate for T = 316 (d) Estimate for T = 1000 Figure 2: These images show the ground truth A∗ matrix (a) and 3 different estimates of the matrix created using increasing amounts of data. We observe that even for a relatively low amount of data we have picked out most of the support but with several spurious artifacts. As the amount of data increases, fewer of the erroneous elements are estimated. All images are scaled from 0 (dark) to -1 (bright). √ regularized maximum likelihood estimate  is calculated with λ = 0.1/ T and the MSE is recorded. The MSE curves are shown in Figure 1. Notice that the true values of A∗ are bounded by -1 and 0, but in our implementation we do not enforce these bounds (we set amin = −∞ and amax = ∞ in Equation 4). While amin = −∞ would cause the theoretical bounds to be poor, the theory can be applied with the smallest and largest elements of the matrix estimated from the unconstrained optimization. In other words, the theory depends on having an upper and lower bound on the rates, but mostly as a theoretical convenience, while the estimator can be computed in an unconstrained way. We show a series of plots which compare the MSE versus increasing behavior of T and s, as well as comparing the behavior of MSE·T and of MSE/s. Plotted in each figure is the median of 100 trials for each (s, T ) pair, with error bars denoting the middle 50 percentile. These plots show that setting λ proportional to T −1 gives us the desired T −1 error decay rate. Additionally, we see that the error increases approximately linearly in the sparsity level s, as predicted by the theory. Finally, Figure 2 shows one specific example process and the estimates produced. The first image is the ground truth matrix, generated to be block diagonal, in order to more easily visualize support structure whereas in the first experiment the support is chosen at random. One set of data is generated using this matrix, and then estimates are constructed using the first T = 100, 316 and 1000 data points. The figure shows how with more data, the estimates become closer to the original, where much of the error comes from including elements off the support of the true matrix. One important characteristic of the our results is that it does not depend on any assumptions about the stationarity or the mixing time of the process. To show that this is truly a property of the system and not just our proof technique, we repeat the experimental process described above, but for each set of observations of length T , we first generate 10,000 observations to allow the process to mix. In other words, for every matrix A we generate T + 10, 000 observations, but only use the last T to find the RMLE. The plots in figure 3 show the results of this experiment. The important observation is that the results both scale the same way, and have approximately the same magnitude as the experiment when no mixing was done. 9 800 10 30 50 10 30 50 Squared Frobenius Error Times T Squared Frobenius Error 700 10 0 600 500 400 300 200 100 100 150 200 250 300 350 0 50 400 100 150 200 T 300 350 400 450 T (b) MSE ·T vs T (a) MSE vs. T 8 0.35 Squared Frobenius Error Divided by Sparsity 100 250 400 7 6 Squared Frobenius Error 250 5 4 3 2 1 0 100 250 400 0.3 0.25 0.2 0.15 0.1 0.05 0 0 10 20 30 40 50 60 Sparsity 0 10 20 30 40 50 60 Sparsity (c) MSE vs s (d) MSE/s vs s Figure 3: Repeat of experimental set up from Figure 1, but now allowing for mixing. The top row of plots shows the MSE behavior over a widely varying range of T values, from 100 to 400, where (a) is the MSE and (b) is the MSE multiplied by T to show that the MSE is behaving as 1/T . The bottom row shows the MSE behavior over a range of s values, where (c) shows MSE and (d) shows MSE divided by s to show that the MSE is linear is s. In all plots the median value of 100 trials is shown, with error bars denoting the middle 50 percentile. Most importantly, the behavior and magnitude of errors in this plot matches the results with no mixing. 4 4.1 Proofs Proof of Theorem 1 Proof. We start the proof by making an important observation about the estimator defined in Equation 4: this loss function can be completely decoupled by a sum of functions on rows. Therefore we can bound the error of a single row of the RMLE and add the errors to get the final bound. For each row we use a standard method in empirical risk minimization and the definition of the minimizer of the regularized likelihood for each row: T −1 1 X Z(νm + b a> a> am k1 m Xt ) − b m Xt φ(Xt+1,m ) + λkb T t=0 T −1 1 X ∗> ∗ ≤ Z(νm + a∗> m Xt ) + am Xt φ(Xt+1,m ) + λkam k1 . T t=0 We define t,m , φ(Xt+1,m ) − E[φ(Xt+1,m )|Xt ], which is conditionally zero mean random variable. By using a moment generating function argument, we know that E[φ(Xt+1,m )|Xt ] = Z 0 (νm + a∗> m Xt ), and therefore 10 φ(Xt+1,m ) = Z 0 (νm + a∗> m Xt ) + t,m . Hence T −1 1 X 0 ∗> Z(νm + b a> a> am k1 m Xt ) − b m Xt (Z (νm + am Xt ) + t,m ) + λkb T t=0 ≤ T −1 1 X ∗> 0 ∗> ∗ Z(νm + a∗> m Xt ) − am Xt (Z (νm + am Xt ) + t,m ) + λkam k1 . T t=0 Now we use the definition of a Bregman divergence to lower bound the left hand side. An important property of Bregman divergences is that if they are induced by a strongly convex function, then the Bregman can be lower bounded by a scaled `2 difference of its arguments. This is where our squared error term will come. T −1  1 X ∗> 0 ∗> ∗> Z(νm + b a> a> m Xt ) − Z(νm + am Xt ) − Z (νm + am Xt )(b m Xt − am Xt ) T t=0 ≤ T −1 1 X ∗ am k1 ), t,m ∆> m Xt + λ(kam k1 − kb T t=0 where ∆m = b am − a∗m . Let BZ (·k·) denote the Bregman divergence induced by Z. Hence T −1 1 X ∗> BZ (νm + b a> m Xt kνm + am Xt ) ≤ T t=0 T −1 1 X ∗ t,m ∆> am k1 ). m Xt + λ(kam k1 − kb T t=0 First we upper bound the right-hand side of the inequality as follows: T −1 1 X ∗> BZ (νm + b a> m Xt kνm + am Xt ) ≤ T t=0 T −1 1 X ∗ t,m ∆> am k1 ) m Xt + λ(kam k1 − kb T t=0 = T −1 1 X ∗ t,m ∆> am,S k1 − kb am,S c k1 ) m Xt + λ(kam,S k1 − kb T t=0 ≤ T −1 1 X t,m ∆> m Xt + λk∆m,S k1 − λk∆m,S c k1 T t=0 ≤ k∆m k1 T −1 1 X Xt t,m T t=0 + λk∆m,S k1 − λk∆m,S c k1 . ∞ In the above, we use the defintion of S as the true support of A∗ and have used the decomposability of k · k1 . The decomposability of the norm means that we have the property kxk1 = kxS k1 + kxS C k1 . Note that 1 T PT −1 t=0 Xt t,m ∞ ≤ max1≤m≤M 1 T PT −1 t=0 Xt t,m ∞ . Under the assumption that PT −1 max1≤m≤M T1 t=0 Xt t,m ≤ λ/2 and by the non-negativity of the Bregman divergence on the left hand ∞ side of the inequality, we have that 0≤ λ k∆m k1 + λk∆m,S k1 − λk∆m,S c k1 . 2 Using the decomposability of the `1 norm, this inequality implies that for all rows 1 ≤ m ≤ M , we have that k∆m,S c k1 ≤ 3k∆m,S k1 . Since k∆m,S c k1 ≤ 3k∆m,S k1 , k∆m k1 ≤ 4k∆m,S k1 and consequently X k∆m k1 ≤ 4 |∆m,j | ≤ 8ρm ã j∈S 11 where the final inequality follows since |∆m,j | ≤ 2ã for all j. Using this inequality and the fact that ka∗m k1 ≤ ρm ã > implies that kâm k1 ≤ 9ρm ã, and therefore for all t ∈ T the range of both νm + a∗> m Xt and νm + âm Xt are in [−ν̃ − 9ρã, ν̃ + 9ρã]. Now to lower bound the Bregman divergence in terms of the Frobenius norm, we use the first condition of Assumption 1. Inherently, the RMLE will admit estimates which should converge to the true matrix A∗ under a Bregman divergence induced by the log-partition function, but we are interested in convergence of the Frobenius norm. Therefore, to convert from one to the other, we require the log-partition function to be strongly convex. This issue is side-stepped in the Gaussian noise case, due to the fact that the Bregman in question would identically be the Frobenius norm. By σ > 2 ∗> Assumption 1, Z is σ-strongly convex, and therefore on T it is true that BZ (ν + b a> m Xt kνm + am Xt ) ≥ 2 (∆m Xt ) > ∗> and BZ (νm + b am Xt kνm + am Xt ) ≥ 0 on the rest of the time indices. Therefore T −1 1 X ∗> BZ (νm + b a> m Xt kνm + am Xt ) ≤ T t=0 λ k∆m k1 + λk∆m,S k1 − λk∆m,S c k1 , 2 implies σ X > (∆m Xt )2 2T ≤ t∈T Define k∆m k2T = 1 T P t∈T λ k∆m k1 + λk∆m,S k1 − λk∆m,S c k1 . 2 2 M ×M , then we have the bound: (∆> m Xt ) for any ∆ ∈ R σ k∆m k2T 2 ≤ λ 3λ k∆m k1 + λk∆m,S k1 − λk∆m,S c k1 ≤ k∆m,S k1 . 2 2 Therefore we can define the cone on which the vector ∆m must be defined: Bm,S := {∆ ∈ [amin − amax , amax − amin ]M | k∆m,S c k1 ≤ 3k∆m,S k1 }, √ and restrict ourselves to studying properties of vectors in that set. Since k∆m,S k1 ≤ ρm k∆m k2 where ρm is the ∗ number of non-zeros of am , we have that k∆m k2T ≤ 3 √ λ ρm k∆m k2 = δm k∆m k2 , σ (6) √ where δm , σ3 λ ρm . Now we consider three cases: if k∆m kT ≥ k∆m k2 , then max(k∆m kT , k∆m k2 ) ≤ δm . On the other hand if k∆m kT ≤ k∆m k2 and k∆m k2 ≤ δm , then max(k∆m kT , k∆m k2 ) ≤ δm . Hence the final case we need to consider is k∆m kT ≤ k∆m k2 and k∆m k2 ≥ δm . Now we follow a similar proof technique to that used in Raskutti et al. [55] adapted to dependent sequences, to understand this final scenario. Let us define the following set: Bm (δm ) := {∆m ∈ Bm,S | k∆m k2 ≥ δm }. (7) Further, let us define the alternative set: 0 Bm (δm ) := {∆m ∈ Bm,S | k∆m k2 = δm }. (8) We wish to show that for ∆m ∈ Bm (δm ), we have k∆m k2T ≥ κk∆m k22 for some κ ∈ (0, 1) with high probability, and therefore Equation 6 would imply that max(k∆m kT , k∆m k2 ) ≤ δm /κ. We claim that it suffices 0 to show that k∆m k2T ≥ κk∆m k22 is true on Bm (δm ) with high probability. In particular, given an arbitrary ˜ m = δm ∆m . Since ∆m ∈ Bm (δm ), we have non-zero ∆m ∈ Bm (δm ), consider the re-scaled vector ∆ k∆m k2 ˜ m ∈ Bm (δm ) and k∆ ˜ m k2 = δm by construction. Together, these facts imply ∆ ˜ m ∈ B 0 (δm ). Furthermore, if ∆ m 2 2 2 2 ˜ ˜ k∆m kT ≥ κk∆m k2 is true, then k∆m kT ≥ κk∆m k2 is also true. Alternatively if we define the random variable 0 2 2 0 2 ZT (Bm ) = sup∆m ∈Bm 0 (δ ) {δm − k∆m kT }, then it suffices to show that ZT (Bm ) ≤ (1 − κ)δm . m 12 For this step we use some recent concentration bounds [61] and empirical process techniques [62] for martingale P |T | random variables. Recall that the empirical norm is k∆m k2T = T1 t∈T (∆Tm Xt )2 . Further let (ti )i=1 denote the indices in T . Next we define the conditional expectation |T |  1X  T YT := E (∆m Xti )2 |Xt1 , Xt2 , . . . , Xti −1 . T i=1 Then we have 0 ZT (Bm )= sup 2 {δm − k∆m k2T } ≤ 0 (δ ) ∆m ∈Bm m 2 {δm − YT } + sup 0 (δ ) ∆m ∈Bm m sup {YT − k∆m k2T }. 0 (δ ) ∆m ∈Bm m 2 To bound the first quantity, sup∆m ∈Bm 0 (δ ) {δm − YT }, we first note that m sup 2 2 2 2 {δm − YT } ≤ δm − δm ω = (1 − ω)δm 0 (δ ) ∆m ∈Bm m 2 0 by Assumption 1 and the fact that k∆m k22 = δm since ∆m ∈ Bm (δm ). Thus 0 2 ZT (Bm ) ≤ (1 − ω)δm + sup 0 (δ ) ∆m ∈Bm m {YT − k∆m k2T }. 2 Now we focus on bounding sup∆m ∈Bm 0 (δ ) {YT − k∆m kT }. First, we use a martingale version of the bounded m difference inequality using Theorem 2.6 in [61] (see Appendix 7.4): sup {YT − k∆m k2T } ≤ E[ 0 (δ ) ∆m ∈Bm m sup {YT − k∆m k2T }] + 0 (δ ) ∆m ∈Bm m 2 ωδm , 4 2 2 2 2 2 with high probability. Recall that on T , we have 0 ≤ (∆> m Xt ) ≤ k∆m k1 kXt k∞ ≤ U k∆m k1 . Because ∆m ∈ 0 Bm (δT ), it is true that k∆m k1 ≤ 4k∆m,S k1 . We then use the the relationship between the `1 and `2 norms to say √ √ k∆m,S k1 ≤ ρm k∆m,S k2 ≤ ρm k∆m k2 where ρm is the number of non-zeros in the mth row of the true matrix 2 2 2 A∗ . Putting these together means (∆> m Xt ) ≤ 16U ρm δm . In particular, we apply Theorem 4 in Appendix 7.4 2 2 2 16U 2 ρm δm 16U 2 ρm δm ωδ 2 m and Ut = , and therefore with ZT = sup∆m ∈Bm 0 (δ ) {YT − k∆m kT }, a = m 4 , Lt = − T T CT2 = 4 324 U 4 ρ2m δm . T Therefore, applying Theorem 4 sup 0 (δ ) ∆m ∈Bm m {YT − k∆m k2T } ≤ E[ sup {YT − k∆m k2T }] + 0 (δ ) ∆m ∈Bm m 2 ωδm , 4 4 4 2 with probability at least 1−exp(− 3242T U 4 ρ2m ). Since T ≥ 32 U ρm log(M ), the above statement holds with probability at least 1 − M12 . Hence 0 2 ZT (Bm ) ≤ (1 − ω)δm + 2 ωδm + E[ sup {YT − k∆m k2T }]. 4 0 (δ ) ∆m ∈Bm m 2 Now we bound E[sup∆m ∈Bm 0 (δ ) {YT − k∆m kT }]. Here we use a recent symmetrization technique adapted for m martingales in [62]. To do this, we introduce the so-called sequential Rademacher complexity defined in [62]. Let (t )Tt=1 be independent Rademacher random variables, that is P(t = +1) = P(t = −1) = 21 . For a function class F, the sequential Rademacher complexity RT (F) is: RT (F) := sup X1 ,X2 ,...,XT   T 1X E sup t f (Xt (1 , 2 , . . . , t−1 )) . f ∈F T t=1 13 Note here that Xt is a function of the previous independent random variables (1 , 2 , . . . , t−1 ). Using Theorem 2 in [62] (also stated Appendix 7.4) with f (Xt ) = (∆Tm Xt )2 and noting that even though we use the index set T , (Xt )t∈T is still a martingale, it follows that: " E # sup {YT − 0 (δ ) ∆m ∈Bm m k∆m k2T } ≤2  E sup Xt1 ,Xt2 ,...,X|T |  |T | 1X ti (∆Tm Xti )2 . 0 (δ ) T ∆m ∈Bm m i=1 sup √ Additionally since |∆> m Xt | ≤ 4U ρm δm by the argument above and using the symmetry of Rademacher random variables " #   |T | 1X 2 T T {YT − k∆m kT } E sup ≤ 2 sup E sup ti ∆m Xti |∆m Xti | 0 (δ ) 0 (δ ) T X1 ,X2 ,...,X|T | ∆m ∈Bm ∆m ∈Bm m m i=1 ≤ √ 8U ρm δm  E sup X1 ,X2 ,...,X|T |  |T | 1X T sup ti ∆m Xti 0 (δ ) T ∆m ∈Bm m i=1 The final step is to upper bound the sequential Rademacher complexity RT = E[sup∆∈Bm 0 (δ ) m where Xti is a function of (1 , 2 , . . . , ti −1 ). Clearly: |T | 1X t ∆ > m Xti T i=1 |T | 1X t Xti T i=1 ≤ E # {YT − sup 0 (δ ) ∆m ∈Bm m k∆m k2T } √ ≤ 8U ρm δm  E sup X1 ,X2 ,...,X|T | √ ≤ 8U ρm δm sup X1 ,X2 ,...,X|T | > i=1 t ∆m Xti ] k∆m k1 . ∞ √ 0 (δ ) we have k∆m k1 = k∆m,S k1 + k∆m,S c k1 ≤ 4k∆m,S k1 and k∆m,S k1 ≤ Because ∆m ∈ Bm √ √ m ρm k∆m k2 = ρm δm . " P|T | 1 T ρm k∆m,S k2 ≤  |T | 1X T sup ti ∆m Xti 0 (δ ) T ∆m ∈Bm m i=1 |T | 1X t Xt (1 , . . . , ti −1 ) T i=1 i i sup ∞ 0 (δ ) ∆m ∈Bm m |T | 2 ≤ 32U 2 ρm δm sup X1 ,X2 ,...,X|T | 1X t Xt (1 , . . . , ti −1 ) T i=1 i i . ∞ Finally, we use Lemma 6 applied to the index set T : " E # sup {YT − 0 (δ ) ∆m ∈Bm m k∆m k2T } 2 ≤ 32U 2 ρm δm sup X1 ,X2 ,...,X|T | |T | 1X t Xt (1 , . . . , ti −1 ) T i=1 i i 2 log(M T ) √ ≤ 128U 4 ρm δm , T with probability at least 1 − 1 (M T )2 . Now if we set T ≥ 2562 U 8 ρ2m log2 (M T ) , ω2 " E # sup {YT − 0 (δ ) ∆m ∈Bm m k∆m k2T } with probability 1 − (M T )−2 . 14 ≤ 2 ωδm 4 ∞ k∆m k1 0 2 Overall this tells us that on the set Bm (δm ) we have that k∆m k2T ≥ 3ω 4 k∆m k2 with high probability. Now we return to the main proof. After considering all three cases that can follow from 6, we have max(k∆m k22 , k∆m k2T ) ≤ 0 144 ρm λ2 2 σ ω2 ξ2 2 with probability at least 1 − exp( c ωρ2m log(2M ) − cωρ2 T ), which bounds the error accrued on any single row, as a m function of the sparsity of the true row. Combining, to get an overall error yields, b − A∗ k2F ≤ kA M X 144 144 2 ρm = 2 2 2 λ2 s λ σ 2 ω 2 ξ 2 m=1 σ ω ξ with probability at least   c0 ρ cω 2 T 1 − exp log(M ) + 2 log(2M ) − ω ρ2 (9) . 4.2 Proof of Theorem 2 4.2.1 Part 1 Proof. The matrix Γt can be expanded as E[Xt Xt> |Xt−1 ] = E[Xt |Xt−1 ]E[Xt |Xt−1 ]> + Diag(Var(Xt |Xt−1 )) Thus Γt has two parts, one is the outer product of a vector with itself, and the second is a diagonal matrix. Therefore, the smallest eigenvalue will be lower bounded by the smallest element of the diagonal matrix, because the outer product matrix will always be positive semi-definite with smallest eigenvalue equal to 0. Using properties of the Bernoulli distribution, the conditional variance is explicitly given as (2 + exp(ν + A∗ Xt−1 ) + exp(−ν − A∗ Xt−1 ))−1 and therefore the smallest eigenvalue of Γt is lower bounded by (3 + exp(ν̃ + ρã))−1 . 4.2.2 Part 2 Proof. In order to prove this part of the Theorem, we use of Markov’s inequality and Lemma 5 in the case of the Bernoulli autoregressive process. Define the sequence (Yn , n ∈ N) as Yn , n−1 1 X Xt,m (Xt+1,` − E[Xt+1,` |Xt ]). T t=0 Notice the following values: Xn−1,m (Xn,` − E[Xn,` |Xn−1 ]) T " #  k n X Xi−1,m k Mn = E (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 . T i=1 Yn − Yn−1 = The first value shows that E[Yn − Yn−1 |X1 , . . . , Xn−1 ] = 0 and therefore Yn (and the negative of the sequence, −Yn ) is a martingale. Additionally, we know |Yn − Yn−1 | ≤ T1 , B and " # 2 n X X i−1,m Mn2 = E (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 T i=1 = n 1 X 2 n cn2 Xi−1,m E[(Xi,` − E[Xi,` |Xi−1 ])2 |Xi−1 ] ≤ ,M 2 T i=1 4T 2 15 where the last step follows because Bernoulli random variables are bounded by one, and the variance is bounded by 1/4. We also need to bound Mnk as follows: # " k n X X i−1,m (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 Mnk = E T2 i=1 " # 2  k−2 n X Xi−1,m Xi−1,m (Xi,` − E[Xi,` |Xi−1 ]) (Xi,` − E[Xi,` |Xi−1 ]) |Xi−1 = E T2 T2 i=1 ≤B k−2 Mn2 We use these values to get a bound on the summation term used in Lemma 5. Dn , X ηk k≥2 en , D k! X ηk k≥2 k! Mnk ≤ X η k B k−2 M 2 n k≥2 k! ≤ cn2 X (ηB)k M bn ,D B2 k! k≥2 b n. (−1)k Mnk ≤ D e n corresponds to the sum corresponding to the negative sequence −Y0 , −Y1 , . . . which we also need to In the above D obtain the desired bound. Now we use a variant of Markov’s inequality to get a bound on the desired quantity. P(|Yn | ≥ y) =P(Yn ≥ y) + P(−Yn ≥ y) ≤ E[eηYn ]e−ηy + E[eη(−Yn ) ]e−ηy =E[eηYn −Dn +Dn ]e−ηy + E[eη(−Yn )−Dn +Dn ]e−ηy e e ≤E[eηYn −Dn ]eDn −ηy + E[eη(−Yn )−Dn ]eDn −ηy ≤ 2eDn −ηy . b e b b The final inequality comes from the use of Lemma 5, which states that the given terms are supermartingales with initial term equal to 1, so the entire expectation is less than or equal to 1. The final step of the proof is to find the optimal value of η to minimize this upper bound. ! c2  M n ηB b n − ηy) = 2 exp e − 1 − ηB − ηy P(|Yn | ≥ y) ≤ 2 exp(D B2 Setting η = 1 B log  yB c2 M n  + 1 yields the lowest such bound, giving cn2 M B2 yB yB P(|Yn | ≥ y) ≤2 exp − log +1 c2 c2 M M n n !! cn2 yB M =2 exp − 2 H cn2 B M where H(x) = (1 + x) log(1 + x) − x. We use the fact that H(x) ≥ P(|Yn | ≥ y) ≤ 2 exp −3y 2 cn2 2yB + 6M 16 ! !! y − log B 3x2 2(x+3) yB +1 c2 M !! n for x ≥ 0 to further simplify the bound.   6y 2 T 2 = 2 exp − 4yT + 3n To complete the proof, we set n = T and take a union bound over all indices because YT considered specific indices m and `, which gives the bound  P T −1 log(M T )  1 X Xt−1,i (Xt,j − E[Xt,j |Xt−1 ]) ≥ 3 √ 1≤i,j≤M T T t=0   54 log(M T ) √ ≤ exp log(2M 2 ) − 12/ T + 3 1 ≤ . MT max Here we have additionally assumed that T ≥ 2 and that log(M T ) ≥ 1. 4.3 Proof of Theorem 3 4.3.1 Part 1 Proof. We start with the following observation: E[XTt XT>t |XTt−1 ] = E[XTt |XTt−1 ]E[XTt |XTt−1 ]> + Diag(Var(XTt |XTt−1 )) Thus Γt has two parts, one is the outer product of a vector with itself, and the second is a diagonal matrix. Therefore, the smallest eigenvalue will be lower bounded by the smallest element of the diagonal matrix. In order to lower bound this variance, we must consider the two cases, one where Tt−1 = Tt − 1 where the previous term in the sequence T is the previous term in the overall sequence, and the other case where Tt−1 < Tt − 1 where the previous term is not in the sequence T . The variance of XT can be characterized based on these two possible situations: Var(XTt,i |XTt−1 ) = pVar(XTt,i |XTt−1 , Tt−1 = Tt − 1) + (1 − p)Var(XTt,i |XTt−1 , Tt−1 < Tt − 1) where p is the probability that Tt−1 = Tt − 1. Because variances are lower bounded by 0, we can lower bound this entire term by the first part of the sum, where Tt−1 = Tt − 1. For this term, we know that XTt is drawn from a Poisson distribution, with the added information that each element is bounded above by U because it is an element of the sequence XT1 , XT2 , . . .. Thus using Lemma 3 we know that the variance of each value is lower bounded by 4 ∗> 5 exp(νi + ai XTt−1 ) which can in turn be lower bounded by exp(νmin + ρamin U ). Finally, since there are at least ξT elements of 1, 2, . . . , T which are in the bounded set of observations, then the worst case distribution of the observations with elements greater than U is that they are never consecutive. This maximizes the number of times there is a break in the sequence T1 , T2 , . . ., which means there would be a total of T − ξT times when there was a break. Thus the probability that consecutive elements are in the set is at least ξ, meaning that the minimum eigenvalue of E[XTt XT>t |XTt−1 ] is lower bounded by 4ξ 5 exp(νmin + ρamin U ). 4.3.2 Part 2 Proof. To prove this part of the Theorem, we use of Markov’s inequality and Lemma 5 as they pertain specifically to our problem. Define the sequence (Yn , n ∈ N) as Yn , n−1 1 X Xt,m (Xt+1,` − E[Xt+1,` |Xt ]). T t=0 Notice the following values: Xn−1,m (Xn,` − E[Xn,` |Xn−1 ]) T " # k  n X Xi−1,m k Mn = E (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 . T i=1 Yn − Yn−1 = 17 The first value shows that E[Yn − Yn−1 |X1 , . . . , Xn−1 ] = 0 and therefore Yn (and the negative of the sequence, −Yn ) is a martingale. Additionally, we have assumed that |Xm,i | ≤ C log M T for 1 ≤ m ≤ M and 1 ≤ i ≤ T , so it is true 2 2 that |Yn − Yn−1 | ≤ C logT (M T ) , B. Additionally: # " 2 n X X i−1,m Mn2 = (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 E T i=1 = n 1 X 2 X E[(Xi,` − E[Xi,` |Xi−1 ])2 |Xi−1 ] T 2 i=1 i−1,m = n nC 2 log2 (M T )eνmax 1 X 2 ∗> cn2 ,M X exp(ν + a X ) ≤ ` i−1 ` T 2 i=1 i−1,m T2 where the last step follows because X`,i |Xi−1 ∼ Poisson(exp(ν` + a∗> ` Xi−1 )) and the mean and variance of a Poisson random variable are equal. The final line uses the fact that Xt is bounded. We will also need to bound Mnk as follows: " # k n X Xi−1,m k (Xi,` − E[Xi,` |Xi−1 ]) |X1 , . . . , Xi−1 Mn = E T2 i=1 # " 2  k−2 n X Xi−1,m Xi−1,m (Xi,` − E[Xi,` |Xi−1 ]) (Xi,` − E[Xi,` |Xi−1 ]) |Xi−1 E = T2 T2 i=1 ≤B k−2 Mn2 We need to use these values to get a bound on the summation term used in Lemma 5. Dn , X ηk k≥2 en , D k! X ηk k≥2 k! Mnk ≤ X η k B k−2 M 2 n k≥2 k! ≤ c2 X (ηB)k M n bn ,D B2 k! k≥2 bn (−1)k Mnk ≤ D e n corresponds to the sum corresponding to the negative sequence −Y0 , −Y1 , . . . which we will also In the above D need to obtain the desired bound. Now we are able to use a variant of Markov’s inequality to get a bound on the desired quantity. P(|Yn | ≥ y) =P(Yn ≥ y) + P(−Yn ≥ y) ≤ E[eηYn ]e−ηy + E[eη(−Yn ) ]e−ηy =E[eηYn −Dn +Dn ]e−ηy + E[eη(−Yn )−Dn +Dn ]e−ηy e e ≤E[eηYn −Dn ]eDn −ηy + E[eη(−Yn )−Dn ]eDn −ηy ≤ 2eDn −ηy b e b b The final inequality comes from the use of Lemma 5, which states that the given terms are supermartingales with initial term equal to 1, so the entire expectation is less than or equal to 1. The final step of the proof is to find the optimal value of η to minimize this upper bound. ! c2  M n ηB b n − ηy) = 2 exp e − 1 − ηB − ηy P(|Yn | ≥ y) ≤ 2 exp(D B2 18 Setting η = 1 B log  yB c2 M n  + 1 yields the lowest such bound, giving cn2 M B2 yB yB P(|Yn | ≥ y) ≤2 exp − log +1 cn2 cn2 M M !! cn2 M yB =2 exp − 2 H cn2 B M !! y − log B yB +1 cn2 M !! 2 3x where H(x) = (1 + x) log(1 + x) − x. We can use the fact that H(x) ≥ 2(x+3) for x ≥ 0 to further simplify the bound. !   3y 2 T 2 −3y 2 = 2 exp − 2 P(|Yn | ≥ y) ≤ 2 exp cn2 2C (T y + 3neνmax ) log2 (M T ) 2yB + 6M To prove the proof, we set n = T and take a union bound over all indices because YT considered specific indices m and `, which gives the bound T −1  1 X log3 (M T )  √ Xt−1,i (Xt,j − E[Xt,j |Xt−1 ]) ≥ 4C 2 eνmax P max i,j T T t=0 ! 4 4 2νmax log (M T ) 48C exp 2 √ ≤ exp log(2M ) − 8C 4 eνmax log3 (M T )/ T + 6C12 eνmax   24C 2 eνmax log(M T ) √ ≤ exp 2 log(M T ) − 4C 2 / T + 3 ≤ exp (−c log(M T )) 2 νmax −8C where c = 24C e 4C 2 +3 and that log(M T ) ≥ 1. 5 2 −6 which is positive for sufficiently large C. Here we have additionally assumed that T ≥ 2 Discussion Corollaries 1 and 2 provide several important facts about the inference process. Primarily, if ρ is fixed as a constant for increasing M (suggesting that the maximum degree of a node does not increase with the number of nodes in a network), then the error scales inversely with T , linearly with the sparsity level s and only logarithmically with the dimension M in order to estimate M 2 parameters. These parameters will dictate how much data needs to be collected to achieve a desired accuracy level. This rate illustrates the idea that doing inference in sparse settings can greatly reduce the needed amount of sensing time, especially when s  M 2 . Another quantity to notice is that we require T ≥ ω −4 ρ3 log(M ). If ρ is fixed as a constant for increasing M , this tells us that T needs to be on the order of log(M ), which is significantly less than the total M 2 parameters which are being estimated, and therefore including the sparsity assumption has lead to a significant gain. One final observation from the risk bound is that it provides guidance in the setting of the regularization parameter. We see that we would like to set λ generally as small as possible, since the error scales approximately like λ2 , but we also require λ at least as large as Õ(T −1/2 ) for the bounds to hold. The balance between setting λ small enough to have low error, while maintaining that it’s large enough is an equivalent argument to needing to set λ large enough for it to take effect, but not too large to cause over smoothing. 5.1 Dense rows of A∗ The exponential scaling in Corollaries 1 and 2 with the maximum number of non-zeros in a row, ρ, at first seems unsatisfying. However, we can imagine a worst-case scenario where a large ρ relative to s and M would actually lead to very poor estimation. Consider the case of a large star-shaped network, where every node in the network influences and is influenced by a single node, and there are no other edges in the network. This would correspond to a matrix 19 with a single, dense row and corresponding column. Therefore, we would have ρ = M and s = 2M − 1. In the Poisson setting, this network would have M − 1 independently and identically distributed Poisson random variables at every time with mean ν, but the central node of the network would be constantly inhibited, almost completely. In a large network, it would be very difficult to know if this inhibition was coming from a few strong connections or from the cumulative effect of all the inhibitions. Additionally, since the central node would almost never have a positive count, it would also be difficult to learn about the influence that node has on the rest of the network. Because of networks like this, it is important that not only is the overall network sparse, but each row also needs to be sparse. This requirement might seem restrictive, but it has been shown in many real world networks that the degree of a node in the network follows a power-law which is independent of the overall size of the network [63], and ρ would grow slowly with growing M . 5.2 Bounded observations and higher-order autoregressive processes Recall that Assumption 1 ensures that most observations are bounded. Bounded observations are important to our analysis because we use martingale concentration inequalities [64] which depend on bounded conditional means and conditional variances, the latter condition being equivalent to Z being strongly convex. Since the conditional means and variances are data-dependent, bounded data (at least with high probability) is a sufficient condition for bounded conditional means and conditional variances. In some settings (e.g., Bernoulli), bounded observations are natural and in Assumption 1 ξ = 1. In other settings (e.g., Poisson) there is no constant U independent of T that is an upper bound for all observations with high probability. Furthermore, if we allow U to increase with T in violation of Assumption 1, b − A∗ k2 that increases polynomially with T . To avoid this and get the far better bound in we derive a bound on kA F Theorem 1, our proof focuses on characterizing the error on the set T defined in Assumption 1. Thus far we have focused on the case where Xt+1,m |Xt ∼ p(ν + a∗> m Xt ), a first order autoregressive process. However, we could imagine a simple, higher-order version where Xt+1,m |Xt−q+1 , . . . , Xt ∼ Pq−1 p(ν + a∗> This process could be reformulated as a process i. m i=0 αi Xt−i ) for some known sequence αP q−1 X̃ ) where X̃ , Xt+1,m |Xt−q+1 , . . . , Xt ∼ p(ν + a∗> t t m i=0 αi Xt−1 , and much of the same proof techniques would still hold, especially in the case of the Bernoulli autoregressive process, where T is easily defined. However, in the more general GLAR case finding the right analogy to T in the higher is not an obvious extension. A true Pspace q−1 order-q autoregressive process where X̃t+1,m |Xt−q+1 , . . . , Xt ∼ p(ν + i=0 a∗> m,i Xt−i ) could also be formulated as an order-1 process by properly stacking vectors and matrices, however, in this case proving the key lemmas and showing that the process obeys Assumption 1 is also an open question. 5.3 Stationarity As stated in the problem formulation, we restrict our attention to bounded matrices A∗ ∈ [amin , amax ]M ×M ; in the specific context of the log-linear Poisson autoregressive model, we use amax = 0, corresponding to a model that only accounts for inhibitory interactions. One might ask whether these constraints could be relaxed and whether the Poisson model could also account for stimulatory interactions. These boundedness constraints are sufficient to ensure that the observed process has a stationary distribution. The stationarity of processes is heavily studied; once a process has reached its stationary distribution, then data can be approximated as independent samples from this distribution and temporal dependencies can be can be ignored. While stationarity does not play an explicit role in our analysis, we can identify several sufficient conditions to ensure the vector GLAR processes of interest are stationary. In particular we assume that A∗ = A∗> which ensures reversibility of the Markov chain described by the process defined by Xt+1,m |Xt ∼ p(νm + a∗> m Xt ). We derive the stationary distribution π(x), and then establish bounds on the mixing time. Note that this is a Markov chain with transition kernel: ! M M X Y P (x, y) = P(Xt+1 = y|Xt = x) = exp ν > y + y > A∗ x − Z(νm + a∗> h(ym ). m X) i=m m=1 If we further assume that the entries of Xt take on values on a countable domain to ensure a countable Markov chain, we can derive bounds on the mixing time. 20 Lemma 2. Assume A∗ = A∗> , then the Markov chain Xt+1,m ∼ p(νm + a∗> m Xt ) is a reversible Markov chain with stationary distribution: ! M M X Y > ∗> π(x) = Cν,A∗ exp ν x + Z(νm + am x) h(xm ) m=1 for Cν,A∗ = R R x1 x2 ... m=1  R xM Q PM M exp ν > x + m=1 Z(νm + a∗> m x) m=1 h(xm )dxM . . . dx2 dx1 . Further, if Xt ∈ ZM + , amax amin = 0 and Z(·) is an increasing function, then for any y ∈ ZM + , if νm ≤ νmax < ∞ for all 1 ≤ m ≤ M and ≤ 0 we have that t  kP t (y, .) − π(.)kT V ≤ 1 − h(0)−2M e−2M Z(νmax ) . Notice that for large M , the chain will mix very slowly, and additionally this bound has no dependence on the sparsity of the true matrix A∗ . Conversely, our results require T to be greater than a value that scales roughly like ρ3 log(M ), which has a much milder dependence on M , and varies based on the sparsity of A∗ . What we can conclude from these observations is that while the RMLE needs a certain amount of observations to yield good results, we do not necessarily need enough data to reach the stationary distribution. Additionally, under conditions where mixing time guarantees are not given (i.e. non-symmetric A∗ , uncountable domain), we still have guarantees on the performance of the RMLE. 6 Conclusions Instances of the generalized linear autoregressive process has been used successfully in many settings to learn network structure. However, this model is often used without rigorous non-asymptotic guarantees of accuracy. In this paper we have shown important properties of the Regularized Maximum Likelihood Estimator of the GLAR process under a sparsity assumption. We have proven bounds on the error of the estimator as a function of sparsity, maximum degree of a node, ambient dimension and time, and shown how these bounds look for the specific examples of the Bernoulli and Poisson autoregressive proceses. In order to prove this risk bound, we have incorporated many recently developed tools of statistical learning, including concentration bounds for dependent random variables. Our results show that by incorporating sparsity the amount of data needed is on the order of ρ3 log(M ) for bounded degree networks, which is a significant gain compared to the M 2 parameters being estimated. While this paper has focused on generalized linear models, we believe that the extension of these ideas to other models is possible. Specifically, for modeling firing rates of neurons in the brain, we are interested in settings in which we observe Xt+1,m |Xt ∼ Poisson(g(a∗> m Xt + ν)) and exploring possible functions g beyond the exponential function considered here. Such analysis would allow our results to apply to stimulatory effects in addition to inhibitory effects, but key challenges include ensuring that the process is stable and, with high probability, bounded. Another direction would be settings where the counts are drawn from more complicated higher-order or autoregressive moving average (ARMA) models which would better model real-world point processes. 7 7.1 Appendix Supplementary Lemmas First we present supplementary Lemmas which we use throughout the proofs of the main Theorems. Lemma 3. Let X be a Poisson random variable, with the following probability density function: p(X = k|λ) = 21 λk e−k k! and let X 0 be a random variable defined by the following pdf: ( c k −λ λ e if k ≤ U q(k|λ) = k! 0 otherwise 1 0 where c = 1−P(X>U ) > 1. Roughly speaking, X is generated by taking a Poisson pdf, and removing the tail probability, and scaling the remaining density so that it is a valid pdf. For this random variable, assuming U ≥ max(6, 1.5eλ, λ + 5) then 4 4λ Var(X 0 ) ≥ Var(X) = 5 5 Proof. Define the error terms 1 , E[X]2 − E[X 0 ]2 and 2 , E[X 2 ] − E[X 02 ]. We know Var(X 0 ) = E[X 02 ] − E[X 0 ]2 = (E[X 2 ] − 2 ) − (E[X]2 − 1 ) ≥ (E[X 2 ] − E[X]2 ) −(|1 | + |2 |) = λ − (|1 | + |2 |) | {z } (10) Var(X) Our strategy will be to show 1 , 2 are small relative to λ, which will tell us Var(X 0 ) ≈ Var(X) = λ. Intuitively, the error terms should be small relative to λ because X 0 differs from X only by cutting off the extreme edge of the pdf, given the assumptions on the size of U relative to λ. First, we bound 1 . We have 1 = E[X]2 − E[X 0 ]2 = (E[X] + E[X 0 ])(E[X] − E[X 0 ]) Since E[X 0 ] ≤ E[X], the first term is bounded by 2E[X] = 2λ. To bound the second term, we note that the pdf for X 0 is given explicitly as ( c k −λ λ e if k ≤ U q(k|λ) = k! 0 otherwise where c = 1 1−P(X>U ) > 1. And therefore E[X 0 ] = c U U X X λk e−λ λk e−λ ≥ (k − 1)! (k − 1)! k=1 k=1 Using this fact to bound E[X] − E[X 0 ] gives us E[X] − E[X 0 ] ≤ E[X] − U ∞ ∞ X X λk e−λ λk e−λ λ X λk = = λ (k − 1)! (k − 1)! e k! k=1 k=U +1 k=U P∞ k Note k=U λk! is the remainder term of the degree U − 1 Taylor Polynomial for eλ . We can bound this using Taylor’s Remainder theorem: ∞ X λk eλ λ U ≤ k! U! k=U and so λU λ ( Ue )U ≤ U! 1.5U U ! where the second inequality comes from the assumption that U ≥ 1.5eλ. Here, the second fraction is small by Sterling’s approximation formula. Formally, Sterling tells us E[X] − E[X 0 ] ≤ λ ( Ue )U 1 ≤√ U! 2πU 22 and therefore E[X] − E[X 0 ] ≤ 1.5U λ √ 2πU . Combining the two terms tells us |1 | ≤ 2λ 1.5U λ √ 2πU ≤ λ 10 since U ≥ 6. Next we bound 2 = E[X 2 ] − E[X 02 ]. We have U U X X kλk e−λ kλk e−λ E[X ] = c ≥ (k − 1)! (k − 1)! 02 k=1 and therefore 2 ≤ E[X 2 ] − k=1 ∞ U ∞ X X (U + 1)λ2 X λk kλk e−λ kλk e−λ = ≤ (k − 1)! (k − 1)! U eλ k! k=1 k=U −1 k=U +1 P∞ k k where the last inequality is due to the fact that k−1 ≤ UU+1 for all k ≥ U + 1. Here k=U −1 λk! is the remainder term for the degree U − 2 Taylor Polynomial approximation to eλ . By the Taylor’s remainder formula, we can bound this by eλ λU −1 (U − 1)! and so λU |1 | ≤ λ(U + 1) U! U and since λ ≤ 1.5e , it follows from Sterling’s approximation that |1 | ≤ λ U +1 λ √ ≤ 10 1.5U 2πU since U ≥ 6. Putting the bounds for 1 and 2 back into Equation 10 to get the final form of the Lemma Var(X 0 ) ≥ 4 4 Var(X) = λ 5 5 We next present a one-sided concentration bound for Poisson random variables due to Bobkov and Ledoux [65]: random variables. Lemma 4 (Proposition 10 in [65]). If X ∼ Poisson(λ):  t t P X − λ > t ≤ exp(− log(1 + )). 4 2λ Lemma 5 (Lemma 3.3 in [64]). Let (Yn , n ∈ N) be a martingale. For all k ≥ 2, let Mnk , n X E[(Yi − Yi−1 )k |Fi−1 ]. i=1 Then for all integers n ≥ 1 and for all η such that for all i ≤ n, E[exp(|η(Yi − Yi−1 )|)] ≤ ∞,   X ηk εn , exp ηYn − M k k! n k≥2 is a super-martingale. Additionally, if Y0 = 0, then E[εn ] ≤ 1. 23 Lemma 6. Let (t )Tt=0 be i.i.d. Rademacher random variables (i.e. P(t = +1) = P(t = −1) = −1 and {Xt }Tt=0 are a sequence of random variables, where Xt ∈ [0, U ]M , Xt (1 , 2 , . . . , t−1 ) is a function of (1 , 2 , . . . , t−1 ). Then T 1X log(M T ) , sup k Xt (1 , 2 , . . . , t−1 )t k∞ ≤ 2U √ T X1 ,...,XT T t=1 with probability at least 1 − 1 (M T )2 . Proof. To prove this Lemma, we once again use Markov’s inequality and Lemma 5. For a fixed m ∈ {1, . . . , M }, define the sequence (Yn , n ∈ N) as n 1X Yn , Xt,m t . T t=1 Notice the following values: 1 Yn − Yn−1 = n Xn,m T " # k n X 1 k Mn = E Xt,m t |1 , . . . , t−1 . T t=1 The first value shows that E[Yn − Yn−1 |1 , . . . , n−1 ] = 0 and therefore Yn (and the negative of the sequence, −Yn ) is a martingale. Additionally, we have assumed that 0 ≤ Xm,i ≤ U for 1 ≤ m ≤ M and 1 ≤ i ≤ T , so it is true that |Yn − Yn−1 | ≤ 2U T , B. Additionally: " # 2 n X 1 2 Mn = E Xt,m t |1 , . . . , t−1 T t=1 = n  1 X 2  2  E Xt,m |1 , . . . , t−1 T 2 t=1 t ≤ 4nU 2 c2 ,M n T2 We will also need to bound Mnk as follows: Mnk   n k X t E Xt,m |1 , . . . , t−1 = T2 t=1   n 2   k−2 X t t = E Xt,m Xt,m |1 , . . . , t−1 T2 T2 t=1 ≤B k−2 Mn2 We need to use these values to get a bound on the summation term used in Lemma 5. Dn , X ηk k≥2 en , D k! X ηk k≥2 k! Mnk ≤ X η k B k−2 M 2 n k≥2 k! ≤ cn2 X (ηB)k M bn ,D B2 k! k≥2 bn (−1)k Mnk ≤ D e n corresponds to the sum corresponding to the negative sequence −Y0 , −Y1 , . . . which we will also In the above D need to obtain the desired bound. Now we are able to use a variant of Markov’s inequality to get a bound on the 24 desired quantity. P(|Yn | ≥ y) =P(Yn ≥ y) + P(−Yn ≥ y) ≤ E[eηYn ]e−ηy + E[eη(−Yn ) ]e−ηy =E[eηYn −Dn +Dn ]e−ηy + E[eη(−Yn )−Dn +Dn ]e−ηy e e ≤E[eηYn −Dn ]eDn −ηy + E[eη(−Yn )−Dn ]eDn −ηy ≤ 2eDn −ηy b e b b The final inequality comes from the use of Lemma 5, which states that the given terms are supermartingales with initial term equal to 1, so the entire expectation is less than or equal to 1. The final step of the proof is to find the optimal value of η to minimize this upper bound. ! c2  M n ηB b e − 1 − ηB − ηy P(|Yn | ≥ y) ≤ 2 exp(Dn − ηy) = 2 exp B2 Setting η = 1 B log  yB c2 M n  + 1 yields the lowest such bound, giving cn2 M B2 yB yB − log +1 P(|Yn | ≥ y) ≤2 exp 2 c c2 Mn M n !! c2 M yB n =2 exp − 2 H cn2 B M !! y − log B yB +1 c2 M !! n 2 3x where H(x) = (1 + x) log(1 + x) − x. We can use the fact that H(x) ≥ 2(x+3) for x ≥ 0 to further simplify the bound. !   −3y 2 3y 2 T 2 P(|Yn | ≥ y) ≤ 2 exp = 2 exp − c2 8(T y + 3n) 2yB + 6M n To complete the proof, we set n = T and take a union bound over all indices because YT considered specific indices m, which gives the bound T  1 X log(M T )  P max Xt,m t ≥ 2U √ m T T t=1   2 12U T log2 (M T ) √ ≤ exp log(M ) − 4U 2 ( T log(M T ) + 3T )   3 log(M T ) ≤ exp log(M T ) − √ 1/ T + 3/ log(M T ) ≤ exp (−2 log(M T )) . 7.2 Proof of Lemma 1 7.2.1 Part 1 ∗> Proof. For all 1 ≤ t ≤ T and 1 ≤ m ≤ M , Xt,m |Xt−1 is drawn from a Poisson distribution with mean eνm +am Xt−1 ∗> for some a∗m ∈ [amin , 0]M . Because of the range of values a∗m can take, we know that eνm +am Xt−1 ≤ eνmax where νm ≤ νmax for some νmax < ∞ for all m. Therefore, we know that P(Xt,m ≥ η + eνmax |Xt−1 ) ≤ P(Y ≥ η + eνmax ) 25 where Y is a Poisson random variable with mean eνmax . To bound this quantity we use the result of Lemma 4,  η  η  . P(Y > η + eνmax ) ≤ exp − log 1 + νmax 4 2e Setting η = C log M T − eνmax , P(Y > C log M T ) ≤ ≤    C log M T − eνmax C log M T − eνmax exp − log 1 + 4 2eνmax   C log M T − eνmax exp − . 4 Here, we have assumed that C ≥ eνmax (2e − 1) and log M T ≥ 1. This upper bound is not dependent on the value of Xt−1 , so this quantity is also an upper bound for the unconditional probability of Xt,m ≥ C log M T . Using this for a single index t, m of our data X, and taking a union bound over all possible indices 1 ≤ m ≤ M, 1 ≤ t ≤ T gives     C log M T − eνmax ≤ exp(−c log M T ) (11) P max Xt,m > C log M T ≤ exp log M T − 1≤m≤M,1≤t≤T 4 for c ≤ 7.2.2 C−eνmax 4 − 1. Thus if C > max(eνmax (2e − 1), 4 + eνmax ), then c > 0, and the bound is valid. Part 2 Proof. We are interested in bounding the number of observations Xt,m for 1 ≤ m ≤ M and 1 ≤ t ≤ T that are above the value U . Saying at least j , αM T observations are less than a certain value, is equivalent to saying that the j th smallest observation is less than that value. Therefore, ! T X M X P(j th smallest observation Xt,m > U ) = P Yt,m ≤ j − 1 t=1 m=1 = j−1 X `=0 P M T X X ! Yt,m = ` t=1 m=1 ≤ j X X P(Y = y). `=0 y∈Y ` PT PM Here we define Yt,m , 1{Xt,m ≤ U }, and Y ` = {y ∈ {0, 1}M ×T | t=1 m=1 yt,m = `}. We then condition the values of Yt on all previous values of Y and then understand this as a marginal of the joint distribution over Yt and Xt−1 . Below we use the notation Y1:t to denote all the time indices of Y from 1 to t, and similarly for y. P(Y = y) = T Y P(Yt = yt |Y1:t−1 = y1:t−1 ) t=1 = T X Y (P(Yt = yt |Y1:t−1 = y1:t−1 , Xt−1 = xt−1 )P(Xt−1 = xt−1 |Y1:t−1 = y1:t−1 )) t=1 xt−1 = T X Y M Y t=1 xt−1 m=1 ! ! P(Yt,m = yt,m |Xt−1 = xt−1 ) P(Xt−1 = xt−1 |Y1:t−1 = y1:t−1 ) In the last line we use the fact that conditioned on Xt−1 , Yt is independent across dimensions m, and independent of previous values Y1:t−1 . We now make the observation that P(Xt,m > U |Xt−1 = xt−1 ) is exactly the probability that a Poisson random variable with rate exp(νm + a∗> m xt−1 ) is greater than U , which can be upper-bounded by the probability that a Poisson random variable with rate exp(νmax ) is greater than U because we have assumed all values P P MT − of a∗m are non-positive. Call this probability pνmax . Thus we have P(Y = y) ≤ pνmax 26 T t=1 m m=1 yt,m and therefore, P T X M X ! Yt,m ≤ j − 1 t=1 m=1 ≤  j  X MT T −` pνMmax = (1 + pνmax )M T − M TX −j−1   MT ` pνmax ` ` `=0 `=0 M T −j    MT MTe T −j j M T −j (1 + pνmax )j pM ≤ (1 + pνmax ) pνmax ≤ νmax . MT − j MT − j The second inequality is from the application of Taylor’s Remainder Theorem, and the third is from the fact that   n ne k . Now use the fact that j = αM T as stated in the Lemma, to give k k ≤ P T X M X ! Yt,m ≤ j − 1 t=1 m=1  ≤ pνmax e 1−α (1−α)M T (1 + pνmax )αM T ≤ " pνmax e 1−α 1−α #M T 2α . By using Lemma 4 in a similar way as was used in the proof of Lemma 1 part 1, pνmax can be controlled by U in the following way,      U − eνmax U − eνmax U − eνmax pνmax =P (X > U ) ≤ exp − log 1 + ≤ exp − , 4 2eνmax 4 when U ≥ eνmax (2e − 1). Plugging the result back into the bound gives P M T X X ! Yt,m ≤ j − 1 " ≤ t=1 m=1 exp(1 − (U − eνmax )/4) 1−α 1−α #M T α 2 . log(2) − 4 log(1 − α) and additionally greater than eνmax (2e − 1) the condition from above, When U > 4 + eνmax + 4α1−α  νmax then the probability of this event is decaying in M and T . Therefore, for c = − 1 − U −e4 − log(1 − α) (1 − α) − α log(2), we have the inequality P(at least αM T observations Xt,m ≤ U ) ≥ 1 − e−cM T 7.3 Proof of Lemma 2 Proof. To prove the form of the stationary distribution we show that Z π(y) = π(x)P (x, y), x where > > ∗ P (x, y) = exp ν y + y A x − M X m=1 27 ! Z(νm + a> m x) M Y m=1 h(ym ). Plugging in π(x) as specified, Z Z π(x)P (x, y) =Cν,A∗ x > exp ν x + x M X Z(νm + > ∗ +ν y+y A x− M Y =Cν,A∗ exp(ν > y) Z (h(ym )) M Y exp ν > x + y > A∗ x x Z (h(ym )) exp ν > x + x> A∗ y Z(νm + M Y M Y h(xm )h(ym ) m=1 h(xm ) M Y h(xm ) m=1 Z M  Y =Cν,A∗ exp(ν y) h(ym ) > exp νm xm + xm a∗> m y   h(xm ) xm m=1 exp ν y + ! a∗> m x) m=1 x m=1 > M X m=1 m=1 =C > m=1 =Cν,A∗ exp(ν > y) ν,A∗ a∗> m x) M X ! Z(νm + M Y a∗> m y) m=1 h(ym ) = π(y) m=1 The second to last equality uses the definition of Z as the log partition function, and the third uses the assumption that A∗ = A∗> . To prove the upper bound on total variation distance for Markov chains on countable domains, we define two chains, one chain Yt begins at the stationary distribution and the other independent chain starts at Xt begins at some arbitrary random state x, both with transition kernel P . These two chains are said to be coupled if they are run independently until the first time where the states are equal, then are equal for the rest of the trial. The notation P t (x, y) denotes the probability of transitioning from state y to state x in exactly t steps. Theorem 5.2 of [66] asserts that: kP t (x, ·) − π(·)kT V ≤ Px (τcouple > t),   t Y where τcouple := min : Xt = Yt . Note first that P(τcouple > t) ≤ (1 − P(Xτ = Yτ = 0)). Since the chains t>0 τ =0 are independent until τcouple , P(Xτ = Yτ = 0) = P(Xτ = 0)P(Yτ = 0). Note also that: ! M X M ∗> P(Xτ = 0|Xτ −1 = x) =h(0) exp − Z(νm + am x) m=1 ≥h(0)M exp − M X ! Z(νm ) ≥ h(0)M exp(−M Z(νmax )), m=1 where the first inequality is due to the fact that Z is an increasing function, and from the assumption that Ai,j ≥ 0. Qt Hence P(τcouple > t) ≤ τ =0 (1 − h(0)−2M exp(−2M Z(νmax ))) = (1 − h(0)−2M exp(−2M Z(νmax )))t . 7.4 Empirical processes for martingale sequences To concretely define the martingale, let (Xt )t≥1 be a sequence of random variables adapted to the filtration (At )t≥1 . First we present a bounded difference inequality for martingales developed by van de Geer [61]. Theorem 4 (Theorem 2.6 in [61]). Fix T ≥ 1 and let ZT be an AT -measurable random variable, satisfying for each t = 1, 2, . . . , t, Lt ≤ E[ZT |At ] ≤ Ut , PT almost surely where Lt < Ut are constants. Define CT2 = t=1 (Ut − Lt )2 . Then for all a > 0, P(ZT − E[ZT ] ≥ a) ≤ exp(− 28 2a2 ). CT2 The second important result we need is a notion of sequential Rademacher complexity for martingales that allows us to do symmetrization, an important step in empirical process theory (see e.g. [67]). To do this we use machinery developed in [62]. Recall that (Xt )t≥1 is a martingale and let χ be the range of each Xt . Let F be a function class where for all f ∈ F, f : χ → R. To define the notion of sequential Rademacher complexity, we first let (t )Tt=1 be a sequence of independent Rademacher random variables (i.e. P(t = +1) = P(t = −1) = 12 ). Next we define a tree process as a function of these independent Rademacher random variables. A χ-valued tree x of depth T is a rooted complete binary tree with nodes labelled by elements of χ. We identify the tree x with the sequence (x1 , x2 , . . . , xT ) of labeling functions xt : {±1}t−1 → χ which provide the labels for each node. Here x1 ∈ χ is the label for the root of the tree, while xt for t > 1 is the label of the node obtained by following the path of length t − 1 from the root, with +1 indicating “right” and −1 indicating “left.” Based on this tree, xt is a function of (1 , 2 , . . . , t−1 ). Based on this, we define the sequential Rademacher complexity of a function class F. Definition 1 (Definition 3 in [62]). The sequential Rademacher complexity of a function class F on a χ-valued tree x is defined as   RT (F) , sup E sup t f (xt (1 , 2 , . . . , t−1 )) x f ∈F  where the outer supremum is taken over all χ-valued trees. Importantly note that t f (xt (1 , 2 , . . . , t−1 ) t≥1 is a martingale. Now we are in a position to state the main result which allows us to do symmetrization for functions of martingales. Theorem 5 (Theorem 2 in [62]).   T 1X E[f (Xt )|At−1 ] − f (Xt ) ≤ 2RT (F). E sup f ∈F T t=1 For further details refer to [62]. References [1] E. N. Brown, R. E. Kass, and P. P. Mitra, “Multiple neural spike train data analysis: state-of-the-art and future challenges,” Nature neuroscience, vol. 7, no. 5, pp. 456–461, 2004. [2] T. P. Coleman and S. Sarma, “Using convex optimization for nonparametric statistical analysis of point processes,” in Proc. ISIT, 2007. [3] A. C. Smith and E. N. Brown, “Estimating a state-space model from point process observations,” Neural Computation, vol. 15, pp. 965–991, 2003. [4] M. Hinne, T. Heskes, and M. A. J. van Gerven, “Bayesian inference of whole-brain networks,” arXiv:1202.1696 [q-bio.NC], 2012. [5] M. Ding, CE Schroeder, and X. Wen, “Analyzing coherent brain networks with Granger causality,” in Conf. Proc. IEEE Eng. Med. Biol. Soc., 2011, pp. 5916–8. [6] J. W. Pillow, J. Shlens, L. Paninski, A. Sher, A. M. Litke, E. J. Chichilnisky, and E. P. Simoncelli, “Spatiotemporal correlations and visual signalling in a complete neuronal population,” Nature, vol. 454, pp. 995–999, 2008. [7] M. S. Masud and R. Borisyuk, “Statistical technique for analysing functional connectivity of multiple spike trains,” Journal of Neuroscience Methods, vol. 196, no. 1, pp. 201–219, 2011. 29 [8] Praneeth Netrapalli and Sujay Sanghavi, “Learning the graph of epidemic cascades,” in ACM SIGMETRICS Performance Evaluation Review. ACM, 2012, vol. 40, pp. 211–222. [9] Fabrizio Altarelli, Alfredo Braunstein, Luca Dall’Asta, Alessandro Ingrosso, and Riccardo Zecchina, “The patient-zero problem with noisy observations,” Journal of Statistical Mechanics: Theory and Experiment, vol. 2014, no. 10, pp. P10016, 2014. [10] David Kempe, Jon Kleinberg, and Éva Tardos, “Maximizing the spread of influence through a social network,” in Proceedings of the ninth ACM SIGKDD international conference on Knowledge discovery and data mining. ACM, 2003, pp. 137–146. [11] M. Kuperman and G. Abramson, “Small world effect in an epidemiological model,” Physical Review Letters, vol. 86, no. 13, pp. 2909, 2001. [12] Per Johansson, “Speed limitation and motorway casualties: a time series count data regression approach,” Accident Analysis & Prevention, vol. 28, no. 1, pp. 73–87, 1996. [13] David S Matteson, Mathew W McLean, Dawn B Woodard, and Shane G Henderson, “Forecasting emergency medical service call arrival rates,” The Annals of Applied Statistics, pp. 1379–1406, 2011. [14] Tina Hviid Rydberg and Neil Shephard, “A modelling framework for the prices and times of trades made on the new york stock exchange,” Tech. Rep., Nuffield College, 1999, Working Paper W99-14. [15] Y. Aı̈t-Sahalia, J. Cacho-Diaz, and R. J. A. Laeven, “Modeling financial contagion using mutually exciting jump processes,” Tech. Rep., National Bureau of Economic Research, 2010. [16] V. Chavez-Demoulin and J. A. McGill, “High-frequency financial data modeling using Hawkes processes,” Journal of Banking & Finance, vol. 36, no. 12, pp. 3415–3426, 2012. [17] A Colin Cameron and Pravin K Trivedi, Regression analysis of count data, vol. 53, Cambridge university press, 2013. [18] M. Raginsky, R. Willett, C. Horn, J. Silva, and R. Marcia, “Sequential anomaly detection in the presence of noise and limited feedback,” IEEE Transactions on Information Theory, vol. 58, no. 8, pp. 5544–5562, 2012. [19] J. Silva and R. Willett, “Hypergraph-based anomaly detection in very large networks,” IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 31, no. 3, pp. 563–569, 2009, doi:10.1109/TPAMI.2008.232. [20] A. Stomakhin, M. B. Short, and A. Bertozzi, “Reconstruction of missing data in social networks based on temporal patterns of interactions,” Inverse Problems, vol. 27, no. 11, 2011. [21] C. Blundell, K. A. Heller, and J. M. Beck, “Modelling reciprocating relationships with Hawkes processes,” in Proc. NIPS, 2012. [22] K. Zhou, H. Zha, and L. Song, “Learning social infectivity in sparse low-rank networks using multi-dimensional Hawkes processes,” in Proceedings of the 16th International Conference on Artificial Intelligence and Statistics (AISTATS), 2013. [23] Shyh-Jier Huang and Kuang-Rong Shih, “Short-term load forecasting via arma model identification including non-Gaussian process considerations,” Power Systems, IEEE Transactions on, vol. 18, no. 2, pp. 673–679, 2003. [24] D. Vere-Jones and T. Ozaki, “Some examples of statistical estimation applied to earthquake data,” Ann. Inst. Statist. Math., vol. 34, pp. 189–207, 1982. [25] Y. Ogata, “Seismicity analysis through point-process modeling: A review,” Pure and Applied Geophysics, vol. 155, no. 2-4, pp. 471–507, 1999. 30 [26] Kurt Brännäs and Per Johansson, “Time series count data regression,” Communications in Statistics-Theory and Methods, vol. 23, no. 10, pp. 2907–2925, 1994. [27] Iain L MacDonald and Walter Zucchini, Hidden Markov and other models for discrete-valued time series, vol. 110, CRC Press, 1997. [28] Scott L Zeger, “A regression model for time series of counts,” Biometrika, vol. 75, no. 4, pp. 621–629, 1988. [29] Bent Jørgensen, Soren Lundbye-Christensen, PX-K Song, and Li Sun, “A state space model for multivariate longitudinal count data,” Biometrika, vol. 86, no. 1, pp. 169–181, 1999. [30] Ludwig Fahrmeir and Gerhard Tutz, Multivariate statistical modelling based on generalized linear models, Springer Science & Business Media, 2013. [31] Gary K Grunwald, Rob J Hyndman, Leanna Tedesco, and Richard L Tweedie, “Theory & methods: NonGaussian conditional linear AR (1) models,” Australian & New Zealand Journal of Statistics, vol. 42, no. 4, pp. 479–495, 2000. [32] Michael A Benjamin, Robert A Rigby, and D Mikis Stasinopoulos, “Generalized autoregressive moving average models,” Journal of the American Statistical association, vol. 98, no. 461, pp. 214–223, 2003. [33] Christian Gouriéroux and Joann Jasiak, “Autoregressive gamma processes,” Les Cahiers du CREF of HEC Montréal Working Paper, , no. 05-03, 2005. [34] Konstantinos Fokianos, Anders Rahbek, and Dag Tjøstheim, “Poisson autoregression,” Journal of the American Statistical Association, vol. 104, no. 488, pp. 1430–1439, 2009. [35] Fukang Zhu and Dehui Wang, “Estimation and testing for a Poisson autoregressive model,” Metrika, vol. 73, no. 2, pp. 211–230, 2011. [36] Konstantinos Fokianos and Dag Tjøstheim, “Log-linear Poisson autoregression,” Journal of Multivariate Analysis, vol. 102, no. 3, pp. 563–578, 2011. [37] A. G. Hawkes, “Point spectra of some self-exciting and mutually-exciting point processes,” Journal of the Royal Statistical Society. Series B (Methodological), vol. 58, pp. 83–90, 1971. [38] A. G. Hawkes, “Point spectra of some mutually-exciting point processes,” Journal of the Royal Statistical Society. Series B (Methodological), vol. 33, pp. 438–443, 1971. [39] D. J. Daley and D. Vere-Jones, An introduction to the theory of point processes, Vol. I: Probability and its Applications, Springer-Verlag, New York, second edition, 2003. [40] Niels Richard Hansen, Patricia Reynaud-Bouret, and Vincent Rivoirard, “LASSO and probabilistic inequalities for multivariate point processes,” Bernoulli, vol. 21, no. 1, pp. 83–143, 02 2015. [41] Muzy Bacry, Gaiffas, “A generalization error bound for sparse and low-rank multivariate hawkes processes,” arXiv:1501.00725, 2015. [42] Andréas Heinen, “Modeling time series count data: an autoregressive conditional Poisson model,” Available at SSRN 1117187, 2003. [43] Fukang Zhu, “A negative binomial integer-valued garch model,” Journal of Time Series Analysis, vol. 32, no. 1, pp. 54–67, 2011. [44] Fukang Zhu, “Modeling time series of counts with COM-poisson INGARCH models,” Mathematical and Computer Modelling, vol. 56, no. 9, pp. 191–203, 2012. [45] Fukang Zhu, “Modeling overdispersed or underdispersed count data with generalized Poisson integer-valued garch models,” Journal of Mathematical Analysis and Applications, vol. 389, no. 1, pp. 58–71, 2012. 31 [46] R. Willett and R. Nowak, “Multiscale Poisson intensity and density estimation,” IEEE Transactions on Information Theory, vol. 53, no. 9, pp. 3171–3187, 2007, doi:10.1109/TIT.2007.903139. [47] M. Raginsky, R. Willett, Z. Harmany, and R. Marcia, “Compressed sensing performance bounds under Poisson noise,” IEEE Transactions on Signal Processing, vol. 58, no. 8, pp. 3990–4002, 2010, arXiv:0910.5146. [48] M. Raginsky, S. Jafarpour, Z. Harmany, R. Marcia, R. Willett, and R. Calderbank, “Performance bounds for expander-based compressed sensing in Poisson noise,” IEEE Transactions on Signal Processing, vol. 59, no. 9, 2011, arXiv:1007.2377. [49] X. Jiang, R. Willett, and G. Raskutti, “Minimax rates of estimation for high-dimensional linear regression over `q -balls,” IEEE Transactions on Information Theory, vol. 61, pp. 4458–4474, 2015. [50] S. van de Geer, “High-dimensional generalized linear models and the LASSO,” Annals of Statistics, vol. 36, pp. 614–636, 2008. [51] V. Koltchinskii and M. Yuan, “Sparse recovery in large ensembles of kernel machines,” in Proceedings of COLT, 2008. [52] L. Meier, S. van de Geer, and P. Buhlmann, “High-dimensional additive modeling,” Annals of Statistics, vol. 37, pp. 3779–3821, 2009. [53] S. Negahban, P. Ravikumar, M. J. Wainwright, and B. Yu, “A unified framework for high-dimensional analysis of M-estimators with decomposable regularizers,” Statistical Science, vol. 27, no. 4, pp. 538–557, 2010. [54] G. Raskutti, M. J. Wainwright, and B. Yu, “Minimax rates of estimation for high-dimensional linear regression over `q -balls,” IEEE Transactions on Information Theory, vol. 57, pp. 6976–6994, 2011. [55] G. Raskutti, M. J. Wainwright, and B. Yu, “Minimax-optimal rates for sparse additive models over kernel classes via convex programming,” Journal of Machine Learning Research, vol. 13, pp. 398–427, 2012. [56] P. Zhao and B. Yu, “On model selection consistency of LASSO,” Journal of Machine Learning Research, vol. 7, pp. 2541–2567, 2006. [57] P. Bühlmann and S. van de Geer, Statistics for High-Dimensional Data: Methods, Theory and Applications, Springer, 2011. [58] S. Basu and G. Michailidis, “Regularized estimation in sparse high-dimensional time series models,” Annals of Statistics, vol. 43, no. 4, pp. 1535–1567, 2015. [59] X. Jiang, P. Reynaud-Bouret, V. Rivoirard, L. Sansonnet, and R. Willett, “A data-dependent weighted LASSO under Poisson noise,” arXiv preprint arXiv:1509.08892, 2015. [60] P. Bickel, Y. Ritov, and A. Tsybakov, “Simultaneous analysis of Lasso and Dantzig selector,” Annals of Statistics, vol. 37, no. 4, pp. 1705–1732, 2009. [61] S. van de Geer, Empirical Process Techniques for Dependent Data, Springer-Verlag, New York, NY, 2002. [62] A. Rakhlin, K. Sridharan, and A. Tewari, “Sequential complexities and uniform martingale laws of large numbers,” Probability Theory and Related Fields, vol. 1, no. 161, pp. 111–153, February 2015. [63] Albert-László Barabási and Réka Albert, “Emergence of scaling in random networks,” Science, vol. 286, no. 5439, pp. 509–512, 1999. [64] Christian Houdré and Patricia Reynaud-Bouret, “Exponential inequalities, with constants, for U-statistics of order two,” in Stochastic inequalities and applications, pp. 55–69. Springer, 2003. [65] S. G. Bobkov and M. Ledoux, “On modified logarithmic Soboloev inequalities for Bernoulli and Poisson measures,” Journal of Functional Analysis, vol. 156, pp. 347–365, 1998. 32 [66] D. A. Levin, Y. Peres, and E. L. Wilmer, Markov Chains and Mixing Times, American Mathematical Society, 2008. [67] D. Pollard, Convergence of Stochastic Processes, Springer-Verlag, New York, 1984. 33
7cs.IT
Improved Approximation Algorithms for Projection Games Pasin Manurangsi1? and Dana Moshkovitz2 ?? arXiv:1408.4048v2 [cs.DS] 15 Nov 2015 1 2 University of California, Berkeley, CA 94720, USA [email protected] Massachusetts Institute of Technology, Cambridge MA 02139, USA [email protected] Abstract. The projection games (aka Label Cover) problem is of great importance to the field of approximation algorithms, since most of the NP-hardness of approximation results we know today are reductions from Label Cover. In this paper we design several approximation algorithms for projection games: 1. A polynomial-time approximation algorithm that improves on the previous best approximation by Charikar, Hajiaghayi and Karloff [8]. 2. A sub-exponential time algorithm with much tighter approximation for the case of smooth projection games. 3. A polynomial-time approximation scheme (PTAS) for projection games on planar graphs and a tight running time lower bound for such approximation schemes.3 Keywords: Label Cover, projection games 1 Introduction The projection games problem (also known as Label Cover) can be defined as follows. Input: A bipartite graph G = (A, B, E), two finite sets of alphabets (aka labels) ΣA , ΣB , and, for each edge e = (a, b) ∈ E, a “projection” πe : ΣA → ΣB . Goal: Find an assignment to the vertices ϕA : A → ΣA and ϕB : B → ΣB that maximizes the number of edges e = (a, b) that are “satisfied”, i.e., πe (ϕA (a)) = ϕB (b). An instance is said to be “satisfiable” or “feasible” or have “perfect completeness” if there exists an assignment that satisfies all edges. An instance is said to be “δ-nearly satisfiable” or “δ-nearly feasible” if there exists an assignment ? ?? 3 Part of this work was completed while the author was at Massachusetts Institute of Technology. This material is based upon work supported by the National Science Foundation under Grant numbers 1218547 and 1452302. The conference version of this paper had only the PTAS but not the running time lower bound. that satisfies (1 − δ) fraction of the edges. In this work, we focus on satisfiable instances of projection games. Label Cover has gained much significance for approximation algorithms because of the following PCP Theorem, establishing that it is NP-hard, given a satisfiable projection game instance, to satisfy even an ε fraction of the edges: Theorem 1 (Strong PCP Theorem). For every n, ε = ε(n), there is k = k(ε), such that deciding Sat on inputs of size n can be reduced to finding, given a satisfiable projection game on alphabets of size k, an assignment that satisfies more than an ε fraction of the edges. This theorem is the starting point of the extremely successful long-code based framework for achieving hardness of approximation results [7,13], as well as of other optimal hardness of approximation results, e.g., for Set Cover [11,18,9]. We know several proofs of the strong PCP theorem that yield different parameters in Theorem 1. The parallel repetition theorem [21], applied on the basic PCP Theorem [5,4,3,2], yields k(ε) = (1/ε)O(1) . Alas, it reduces exact Sat on input size n to Label Cover on input size nO(log 1/ε) . Hence, a lower bound of 2Ω(n) for the time required for solving Sat on inputs of size n only implies Ω(1/ log 1/ε) a lower bound of 2n for Label Cover via this theorem. This bound deteriorates as ε approaches zero; for instance, if ε = (1/n)O(1) , then the bound is Ω(1), which gives us no information at all. A different proof is based on PCP composition [19,9]. It has smaller blow up but larger alphabet size. Specifically, it shows a reduction from exact Sat with input size n to Label Cover with input size n1+o(1) poly(1/ε) and alphabet size exp(1/ε). One is tempted to conjecture that a PCP theorem with both a blow-up of n1+o(1) poly(1/ε) and an alphabet size (1/ε)O(1) holds. See [18] for a discussion of potential applications of this “Projection Games Conjecture”. Finding algorithms for projection games is therefore both a natural pursuit in combinatorial optimization, and also a way to advance our understanding of the main paradigm for settling the approximability of optimization problems. Specifically, our algorithms help make progress towards the following questions: 1. Is the ”Projection Games Conjecture” true? What is the tradeoff between the alphabet size, the blow-up and the approximation factor? 2. What about even stronger versions of the strong PCP theorem? E.g., Khot introduced “smooth” projection games [15] (see discussion below for the definition). What kind of lower bounds can we expect to get via such a theorem? 3. Does a strong PCP theorem hold for graphs of special forms, e.g., on planar graphs? 2 2 Our Results 2.1 Better Approximation in Polynomial Time In 2009, Charikar, Hajiaghayi and Karloff presented a polynomial-time O((nk)1/3 )approximation algorithm for Label Cover on graphs with n vertices and alphabets of size k [8].4 This improved on Peleg’s O((nk)1/2 )-approximation algorithm [20]. Both Peleg’s and the CHK algorithms worked in the more general setting of arbitrary (not necessarily projections) constraints on the edges and possibly unsatisfiable instances. We show a polynomial-time algorithm that achieves a better approximation for satisfiable projection games: Theorem 2. There is a polynomial-time algorithm that, given a satisfiable instance of projection games on a graph of size n and alphabets of size k, finds an assignment that satisfies Ω(1/(nk)1/4 ) fraction of the edges. 2.2 Algorithms for Smooth Projection Games Khot introduced “smooth” projection games in order to obtain new hardness of approximation results, e.g., for coloring problems [15]. In a smooth projection game, for every vertex a ∈ A, the assignments projected to a’s neighborhood by the different possible assignments σa ∈ ΣA to a, differ a lot from one another (alternatively, form an error correcting code with high relative distance). More formally: Definition 1. A projection game instance is µ-smooth if for every a ∈ A and any distinct assignments σa , σa0 ∈ ΣA , we have P rb∈N (a) [π(a,b) (σa ) = π(a,b) (σa0 )] ≤ µ where N (a) is the set of neighbors of a. Intuitively, smoothness makes the projection games problem easier, since knowing only a small fraction of the assignment to a neighborhood of a vertex a ∈ A determines the assignment to a. Smoothness can be seen as an intermediate property between projection and uniqueness, with uniqueness being 0-smoothness. Khot’s Unique Games Conjecture [16] is that the Strong PCP Theorem holds for unique games on nearly satisfiable instances for any constant ε > 0. The Strong PCP Theorem (Theorem 1) is known to hold for µ-smooth projection games with µ > 0. However, the known reductions transform Sat instances of size n to instances of smooth Label Cover of size at least nO((1/µ) log(1/ε)) [15,14]. Hence, a lower bound of 2Ω(n) for Sat only translates into a lower bound of Ω(µ/ log(1/ε)) 2n for µ-smooth projection games. 4 Recall that, for α ≥ 1, an α-approximation algorithm for a maximization problem is an algorithm that, for every input, outputs a solution of value at least 1/α times the value of the optimal solution. α is called the “approximation ratio” of the algorithm. 3 Interestingly, the efficient reduction of Moshkovitz and Raz [19] inherently generates instances that are not smooth. Moreover, for unique games it is known that if they admit a reduction from Sat of size n, then the reduction must incur Ω(1) a blow-up of at least n1/δ for δ-almost satisfiable instances. This follows from the sub-exponential time algorithm of Arora, Barak and Steurer [1]. Given this state of affairs, one wonders whether a large blow-up is necessary for smooth projection games. We make progress toward settling this question by showing: Theorem 3. For any constant c ≥ 1, the following holds: there is a randomized algorithm that given a µ-smooth satisfiable projection game in which all vertices in A have degrees at least c logµ |A| , finds an optimal assignment in time exp(O(µ|B| log |ΣB |))poly(|A|, |ΣA |) with probability 1/2. Moreover, there is a deterministic O(1)-approximation algorithm for µ-smooth satisfiable projection games of any degree. The deterministic algorithm runs in time exp(O(µ|B| log |ΣB |))poly(|A|, |ΣA |) as well. The algorithms work by finding a subset of fraction µ in B that is connected to all, or most, of the vertices in A and going over all possible assignments to it. Theorem 3 essentially implies that a blow-up of n/µ is necessary for any reduction from Sat to µ-smooth Label Cover, no matter what is the approximation factor ε. 2.3 PTAS For Planar Graphs As the strong PCP Theorem (Theorem 1) shows, Label Cover is NP-hard to approximate even to within subconstant ε fraction. Does Label Cover remain as hard when we consider special kinds of graphs? In recent years there has been much interest in optimization problems over planar graphs. These are graphs that can be embedded in the plane without edges crossing each other. Many optimization problems have very efficient algorithms on planar graphs. We show that while projection games remain NP-hard to solve exactly on planar graphs, when it comes to approximation, they admit a PTAS: Theorem 4. The following hold: 1. Given a satisfiable instance of projection games on a planar graph, it is NPhard to find a satisfying assignment. 2. There is a polynomial time approximation scheme for projection games on planar graphs that runs in time (nk)O(1/ε) . Moreover, this running time is essentially tight: there is no PTAS for projection games on planar graphs 1−δ γ running in time 2O(1/ε) (nk)O(1/ε) for any constants γ, δ > 0 unless the exponential time hypothesis (ETH) 5 fails. 5 Note that the exponential time hypothesis states that 3-SAT cannot be solved in sub-exponential time. 4 The NP-hardness of projection games on planar graphs is based on a reduction from 3-colorability problem on planar graphs. The PTAS works via Baker’s approach [6] of approximating the graph by a graph with constant tree-width. Finally, the running time lower bound is shown via a reduction from from Matrix Tiling problem introduced by Marx in [17]. 3 Conventions We define the following notation to be used in the paper. – Let nA = |A| denote the number of vertices in A and nB = |B| denote the number of vertices in B. Let n denote the number of vertices in the whole graph, i.e. n = nA + nB . – Let dv denote the degree of a vertex v ∈ A ∪ B. – For a vertex u, we use N (u) to denote set of vertices that are neighbors of u. Similarly, for a set of vertex U , we use N (U ) to denote the set of vertices that are neighbors of at least one vertex in U . – For each vertex u, define N2 (u) to be N (N (u)). This is the set of neighbors of neighbors of u. – Let σvOP T be the assignment to v in an assignment to vertices that satisfies all the edges. In short, we will sometimes refer to this as “the optimal assignment”. This is guaranteed to exist from our assumption that the instances considered are satisfiable. – For any edge e = (a, b), we define pe to be |π −1 (σbOP T )|. In other words, pe is the number of assignments to a that satisfy the edge e given that b is assigned σbOP T , the P optimal assignment. Define p to be the average of pe pe over all e; that is p = e∈E . |E| – For each set of vertices S, define E(S) to be the set of edges of G with at least one endpoint in S, i.e., E(S) = {(u, v) ∈ E | u ∈ S or v ∈ S}. – For each a ∈ A, let h(a) denote |E(N2 (a))|. Let hmax = maxa∈A h(a). For simplicity, we make the following assumptions: – G is connected. This assumption can be made without loss of generality, as, if G is not connected, we can always perform any algorithm presented below on each of its connected components and get an equally good or a better approximation ratio. – For every e ∈ E and every σb ∈ ΣB , the number of preimages in πe−1 (σb ) is the same. In particular, pe = p for all e ∈ E. We only make use of the assumptions in the algorithms for proving Theorem 2. We defer the treatment of graphs with general number of preimages to the appendix. 5 4 Polynomial-time Approximation Algorithms for Projection Games In this section, we present an improved polynomial time approximation algorithm for projection games and prove Theorem 2. To prove the theorem, we proceed to describe four polynomial-time approximation algorithms. In the end, by using the best of these four, we are able to produce a polynomial-time O (nA |ΣA |)1/4 -approximation algorithm as desired. Next, we will list the algorithms along with its rough descriptions (see also illustrations in Figure 1 below); detailed description and analysis of each algorithm will follow later in this section: 1. Satisfy one neighbor – |E|/nB -approximation. Assign each vertex in A an arbitrary assignment. Each vertex in B is then assigned to satisfy one of its neighboring edges. This algorithm satisfies at least nB edges. 2. Greedy assignment – |ΣA |/p-approximation. Each vertex in B is assigned an assignment σb P ∈ ΣB that has the largest number of preimages −1 across neighboring edges a∈N (b) |π(a,b) (σb )|. Each vertex in A is then assigned so that it satisfies as many edges as possible. This algorithm works well when ΣB assignments have many preimages. 3. Know your neighbors’ neighbors – |E|p/hmax -approximation. For a vertex a0 ∈ A, we go over all possible assignments to it. For each assignment, we assign its neighbors N (a0 ) accordingly. Then, for each node in N2 (a0 ), we keep only the assignments that satisfy all the edges between it and vertices in N (a0 ). When a0 is assigned the optimal assignment, the number of choices for each node in N2 (a0 ) is reduced to at most p possibilities. In this way, we can satisfy 1/p fraction of the edges that touch N2 (a0 ). This satisfies many edges when there exists a0 ∈ A such that N2 (a0 ) spans many edges. 4. Divide and Conquer – O(nA nB hmax /|E|2 )-approximation. For every a ∈ A we can fully satisfy N (a) ∪ N2 (a) efficiently, and give up on satisfying other edges that touch N2 (a). Repeating this process, we can satisfy Ω(|E|2 /(nA nB hmax )) fraction of the edges. This is large when N2 (a) does not span many edges for all a ∈ A. The smallest of the four approximation factors is at most as large as their geometric mean, i.e., s ! |ΣA | |E|p nA nB hmax 4 |E| · = O((nA |ΣA |)1/4 ). O · · nB p hmax |E|2 All the details of each algorithm are described below. Satisfy One Neighbor Algorithm. We will present a simple algorithm that gives |E| nB approximation ratio. 6 (1) (2) (3) (4) Fig. 1. An Overview of The Algorithms in One Figure. Four algorithms are used to prove Theorem 2: (1) In satisfy one neighbor algorithm, each vertex in B is assigned to satisfy one of its neighboring edges. (2) In greedy assignment algorithm, each vertex in B is assigned with an assignment with largest number of preimages. (3) In know your neighbors’ neighbors algorithm, for a vertex   a0 , choices for each node in N2 (a0 ) are reduced to at most O(p) possibilities so O p1 fraction of edges that touch N2 (a0 ) are satisfied. (4) In divide and conquer algorithm, the vertices are seperated to subsets, each of which is a subset of N (a) ∪ N2 (a), and each subset is solved separately. Lemma 1. For satisfiable instances of projection games, an assignment that satisfies at least nB edges can be found in polynomial time, which gives the approximation ratio of |E| nB . 7 Proof. For each node a ∈ A, pick one σa ∈ ΣA and assign it to a. Then, for each b ∈ B, pick one neighbor a of b and assign ϕ(b) = πe (σa ) for b. This guarantees that at least nB edges are satisfied. Greedy Assignment Algorithm. The idea for this algorithm is that if there are many assignments in ΣA that satisfy each edge, then one satisfies many edges by guessing assignments at random. The algorithm below is the deterministic version of this algorithm. Lemma 2. There exists a polynomial-time satisfiable instances of projection games. |ΣA | p -approximation algorithm for Proof. The algorithm works as follows: P −1 1. For each b, assign it σb∗ that maximizes a∈N (b) |π(a,b) (σb )|. ∗ 2. For each a, assign it σa that maximizes the number of edges satisfied, |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }|. Let e∗ be the number of edges that get satisfied by this algorithm. We have X e∗ = |{b ∈ N (a) | π(a,b) (σa∗ ) = σb∗ }|. a∈A Due to the second step, for each a ∈ A, the number of edges satisfied is at least an average of the number of edges satisfy over all assignments in ΣA . This can be written as follows. P X σ ∈Σ |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }| ∗ a A e ≥ |ΣA | a∈A P −1 X b∈N (a) |π(a,b) (σb∗ )| = |ΣA | a∈A X X 1 −1 = |π(a,b) (σb∗ )| |ΣA | a∈A b∈N (a) 1 X X −1 = |π(a,b) (σb∗ )|. |ΣA | b∈B a∈N (b) Moreover, from the first step, we can conclude that, for each b, −1 OP T )|. As a result, we can conclude that a∈N (b) |π(a,b) (σb P e∗ ≥ 1 X X −1 |π(a,b) (σbOP T )| |ΣA | b∈B a∈N (b) 1 X = pe |ΣA | e∈E |E|p = |ΣA | 8 P a∈N (b) −1 |π(a,b) (σb∗ )| ≥ Hence, this algorithm satisfies at least p |ΣA | fraction of the edges. Thus, this |ΣA | p -approximation is a polynomial-time algorithm for satisfiable instances of projection games, which concludes our proof. Know Your Neighbors’ Neighbors Algorithm The next algorithm shows that if the neighbors of neighbors of a vertex a0 ∈ A expand, then one can satisfy many of the (many!) edges that touch the neighbors of a0 ’s neighbors. Lemma 3. For each a0 ∈ A, there exists a polynomial-time algorithm for satisfiable instances of projection games. |E|p h(a0 ) -approximation Proof. To prove Lemma 3, we want to find an algorithm that satisfies at least h(a0 ) edges for each a0 ∈ A. p The algorithm works as follows: 1. Iterate over all assignments σa0 ∈ ΣA to a0 : (a) Assign σb = π(a0 ,b) (σa0 ) to b for all b ∈ N (a0 ). (b) For each a ∈ A, find the set of plausible assignments to a, i.e., Sa = {σa ∈ ΣA | ∀b ∈ N (a) ∩ N (a0 ), π(a,b) (σa ) = σb }. If for any a, the set Sa is empty, then we proceed to the next assignment without executing the following steps. (c) For all b ∈ B, pick an assignment σb∗ for b that maximizes the average number of satisfied edges overPall assignments in Sa to vertices a in −1 N (b) ∩ N2 (a0 ), i.e., maximizes a∈N (b)∩N2 (a0 ) |π(a,b) (σb ) ∩ Sa |. ∗ (d) For each vertex a ∈ A, pick an assignment σa ∈ Sa that maximizes the number of satisfied edges, |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }|. 2. Pick an assignment {σa∗ }a∈A , {σb∗ }b∈B from the previous step that satisfies the most edges. We will prove that this algorithm indeed satisfies at least h(a) p edges. Let e∗ be the number of edges satisfied by the algorithm. We have X e∗ = |{b ∈ N (a) | π(a,b) (σa∗ ) = σb∗ }|. a∈A Since in step 1, we try every possible σa0 ∈ ΣA , we must have tried σa0 = T σaOP . This means that the assignment to a0 is the optimal assignment. As a 0 result, the assignments to every node in N (a0 ) is the optimal assignment; that is σb = σbOP T for all b ∈ N (a0 ). Note that when the optimal assignment is assigned to a0 , we have σaOP T ∈ Sa for all a ∈ A. This means that the algorithm proceeds until the end. Thus, the solution this algorithm gives satisfies at least as many edges as when σv = σvOP T for all v ∈ {a0 } ∪ N (a0 ). From now on, we will consider only this case. Since for each a ∈ A, the assignment σa∗ is chosen to maximize the number of edges satisfied, we can conclude that the number of edges satisfied by selecting σa∗ is at least the average of the number of edges satisfied over all σa ∈ Sa . 9 As a result, we can conclude that P X σ ∈S |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }| a a e∗ ≥ |Sa | a∈A P P X σa ∈Sa b∈N (a) 1π(a,b) (σa )=σ∗ b = |Sa | a∈A P P X b∈N (a) σa ∈Sa 1π(a,b) (σa )=σ∗ b = |Sa | a∈A P −1 X b∈N (a) |π(a,b) (σb∗ ) ∩ Sa | = |Sa | a∈A = −1 X X |π(a,b) (σb∗ ) ∩ Sa | |Sa | b∈B a∈N (b) ≥ X −1 |π(a,b) (σb∗ ) ∩ Sa | X |Sa | b∈B a∈N (b)∩N2 (a0 ) Now, for each a ∈ N2 (a0 ), consider Sa . From the definition of Sa , we have \ −1 Sa = {σa ∈ ΣA | ∀b ∈ N (a) ∩ N (a0 ), π(a,b) (σa ) = σb } = π(a,b) (σb ). b∈N (a)∩N (a0 ) As a result, we can conclude that |Sa | ≤ = −1 {|π(a,b) (σb )|} min b∈N (a)∩N (a0 ) −1 {|π(a,b) (σbOP T )|} min b∈N (a)∩N (a0 ) = {p(a,b) }. min b∈N (a)∩N (a0 ) Note that since a ∈ N2 (a0 ), we have N (a) ∩ N (a0 ) 6= ∅. Since we assume for simplicity that pe = p for all e ∈ E, we can conclude that |Sa | ≤ p. This implies that X 1X −1 e∗ ≥ |π(a,b) (σb∗ ) ∩ Sa |. p b∈B a∈N (b)∩N2 (a0 ) P −1 Since we pick the assignment σb∗ that maximizes a∈N (b)∩N2 (a0 ) |π(a,b) (σb∗ ) ∩ Sa | for each b ∈ B, we can conclude that X 1X −1 e∗ ≥ |π(a,b) (σb∗ ) ∩ Sa | p b∈B a∈N (b)∩N2 (a0 ) ≥ 1X p X −1 |π(a,b) (σbOP T ) ∩ Sa |. b∈B a∈N (b)∩N2 (a0 ) 10 Since the optimal assignment satisfies every edge, we can conclude that −1 σaOP T ∈ π(a,b) (σbOP T ) and σaOP T ∈ Sa , for all b ∈ B and a ∈ N (b) ∩ N2 (a0 ). This implies that 1X p X 1X ≥ p X e∗ ≥ −1 |π(a,b) (σbOP T ) ∩ Sa | b∈B a∈N (b)∩N2 (a0 ) 1. b∈B a∈N (b)∩N2 (a0 ) The last term can be written as X 1X p 1= b∈B a∈N (b)∩N2 (a0 ) 1 p X X 1 a∈N2 (a0 ) b∈N (a) 1 (h(a0 )) p h(a0 ) = . p = As a result, we can conclude that this algorithm gives an assignment that satisfies at least h(ap 0 ) edges out of all the |E| edges. Hence, this is a polynomialtime |E|p h(a0 ) -approximation algorithm as desired. Divide and Conquer Algorithm. We will present an algorithm that separates the graph into disjoint subgraphs for which we can find the optimal assignments in polynomial time. We shall show below that, if h(a) is small for all a ∈ A, then we are able to find such subgraphs that contain most of the graph’s edges.   B hmax Lemma 4. There exists a polynomial-time O nA n|E| -approximation algo2 rithm for satisfiable instances of projection games. Proof. To proveLemma 4, we  will describe an algorithm that gives an assignment |E|3 that satisfies Ω nA nB hmax edges. We use P to represent the collection of subgraphs we find. The family P S consists of disjoint sets of vertices. Let VP be P ∈P P . For any set S of vertices, define GS to be the graph induced on S with respectSto G. Moreover, define ES to be the set of edges of GS . We also define EP = P ∈P EP . The algorithm works as follows. 1. Set P ← ∅. 2 2. While there exists a vertex a ∈ A such that |E(N (a)∪N2 (a))−VP | ≥ 14 n|E| : A nB (a) Set P ← P ∪ {(N2 (a) ∪ N (a)) − VP }. 3. For each P ∈ P, find in time poly(|ΣA |, |P |) an assignment to the vertices in P that satisfies all the edges spanned by P . 11 We will divide the proof into two parts. First, we will show that when we cannot find a vertex a in step 2, E(A∪B)−VP ≤ |E| we will 2 . Second,  show that  |E|3 nA nB hmax the resulting assignment from this algorithm satisfies Ω edges. We will start by showing that if no vertex a in step 2 exists, then E(A∪B)−VP ≤ |E| 2 . Suppose that we cannot find a vertex a in step 2. In other words, |E(N (a)∪N2 (a))−VP | < 2 1 |E| 4 nA nB for all a ∈ A. P Consider a∈A |E(N (a)∪N2 (a))−VP |. Since |E(N (a)∪N2 (a))−VP | < a ∈ A, we have the following inequality. 2 1 |E| 4 nA nB for all X |E|2 ≥ |E(N (a)∪N2 (a))−VP |. 4nB a∈A Let N p (v) = N (v) − VP and N2p (v) = N2 (v) − VP . Similary, define N p (S) for a subset S ⊆ A ∪ B. It is easy to see that N2p (v) ⊇ N p (N p (v)). This implies that, for all a ∈ A, we have |E(N p (a)∪N2p (a)) | ≥ |E(N p (a)∪N p (N p (a))) |. Moreover, it Pis not hardp to see that, for all a ∈ A − VP , we have |E(N p (a)∪N p (N p (a))) | = b∈N p (a) |N (b)|. Thus, we can derive the following: X |E(N (a)∪N2 (a))−VP | = a∈A X |E(N p (a)∪N2p (a)) | a∈A X ≥ |E(N p (a)∪N2p (a)) | a∈A−VP X ≥ X |N p (b)| a∈A−VP b∈N p (a) X X b∈B−VP a∈N p (b) = X = |N p (b)| |N p (b)|2 . b∈B−VP From Jensen’s inequality, we have X a∈A 1 |E(N (a)∪N2 (a))−VP | ≥ |B − VP | !2 X |N p (b)| b∈B−VP 1 = E(A∪B)−VP |B − VP | 1 2 ≥ E(A∪B)−VP . nB 12 2 2 P P Since |E| a∈A |E(N (a)∪N2 (a))−VP | ≥ a∈A |E(N (a)∪N2 (a))−VP | and 4nB ≥ we can conclude that 1 nB |E| ≥ E(A∪B)−VP 2 which concludes the first part of the proof. Next, 3we will  show that the assignment the algorithm finds satisfies at least |E| Ω nA nB hmax edges. Since we showed that |E| 2 ≥ E(A∪B)−VP when the algo 2 rithm terminates, it is enough to prove that |EP | ≥ 4nA n|E| |E| − E(A∪B)−VP . B hmax Note that the algorithm guarantees to satisfy all the edges in EP . We will prove this by using induction to show that at any point in the algo 2 |E| − E(A∪B)−VP . rithm, |EP | ≥ 4nA n|E| B hmax  2 Base Case. At the beginning, we have |EP | = 0 = 4nA n|E| |E| − E(A∪B)−VP , B hmax which satisfies the inequality. Inductive Step. The only step in the algorithm where any term in the inequality changes is step 2a. Let Pold and Pnew be the set P before and after step 2a is executed, respectively. Let a be the vertex selected from step 2. Suppose that Pold satisfies the inequality. From the condition in step 2, we have |E(N (a)∪N2 (a))−VPold | ≥ |EPnew | = |EPold | + |E(N (a)∪N2 (a))−VPold |, we have |EPnew | ≥ |EPold | + 2 1 |E| 4 nA nB . Since 1 |E|2 . 4 nA nB    Now, consider |E| − |E(A∪B)−VPnew | − |E| − |E(A∪B)−VPold | . We have    |E| − |E(A∪B)−VPnew | − |E| − |E(A∪B)−VPold | = |E(A∪B)−VPold | − |E(A∪B)−VPnew | Since VPnew = VPold ∪ (N2 (a) ∪ N (a)), we can conclude that ((A ∪ B) − VPold ) ⊆ ((A ∪ B) − VPnew ) ∪ (N2 (a) ∪ N (a)) . Thus, we can also derive E(A∪B)−VPold ⊆ E((A∪B)−VPnew )∪(N2 (a)∪N (a)) = E(A∪B)−VPnew ∪ {(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)}. From the definition of N and N2 , for any (a0 , b0 ) ∈ E, if b0 ∈ N (a) then a ∈ N2 (a). Thus, we have {(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)} = {(a0 , b0 ) ∈ E | a0 ∈ N2 (a)} = E(N2 (a)). The cardinality of the last term was defined to be 0 13 2 E(A∪B)−VP , h(a). Hence, we can conclude that |E(A∪B)−VPold | ≤ |E(A∪B)−VPnew ∪ {(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)}| ≤ |E(A∪B)−VPnew | + |{(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)}| = |E(A∪B)−VPnew | + |{(a0 , b0 ) ∈ E | a0 ∈ N2 (a)}| = |E(A∪B)−VPnew | + |E(N2 (a))| = |E(A∪B)−VPnew | + h(a) ≤ |E(A∪B)−VPnew | + hmax .  increases by at most hmax . This implies that |E| − E(A∪B)−V P  Hence, since |E| − E(A∪B)−VP increases by at most hmax and |EP | increases by at least that 2 1 |E| 4 nA nB |EPnew | ≥ and from the inductive hypothesis, we can conclude  |E|2 |E| − E(A∪B)−VPnew . 4nA nB hmax Thus, the inductive step is true and the inequality holds at any point during the execution of the algorithm.  2 When the algorithm terminates, since |EP | ≥ 4nA n|E| |E| − E(A∪B)−VP B hmax 3 |E| and |E| 2 ≥ E(A∪B)−VP , we can conclude that |EP | ≥ 8nA nB hmax . Since the algorithm guarantees to satisfy every edge in EP , we can conclude that the algorithm B hmax gives O( nA n|E| ) approximation ratio, which concludes our proof of Lemma 4. 2 Proof of Theorem 2 Proof. Using Lemma 3 with a0 that maximizes the value of h(a0 ), i.e., h(a0 ) = hmax , we can conclude that there exists a polynomial-time h|E|p -approximation max algorithm for satisfiable instances of projection games. Moreover, from Lemmas 1, 2 and 4, there exists a polynomial-time |E| nB approximation algorithm, a polynomial-time |ΣpA | -approximation algorithm and   B hmax a polynomial time O nA n|E| -approximation algorithm for satisfiable in2 stances of projection games. By picking we can get an approximation  the  best out of these four algorithms,  |E|p |ΣA | |E| nA nB hmax ratio of O min hmax , p , nB , . |E|2 Since the minimum is at most the value of the geometric mean, we deduce that the approximation ratio is s ! p  |ΣA | |E| nA nB hmax 4 4 |E|p O · · · = O n |Σ | . A A hmax p nB |E|2 This concludes the proof of Theorem 2. 14 5 Sub-Exponential Time Algorithms for Smooth Projection Games In this section, we prove Theorem 3 via Lemma 5 and Lemma 6 stated in the following subsections. Before we proceed to state and prove the lemmas, let us start by noting the following observation which follows immediately from the definition of smoothness (Definition 1). Observation 1. For any µ-smooth satisfiable projection game and any vertex a in A, if more than µda neighbors of a are assigned according to the optimal assignment, then there is only one σa ∈ ΣA that satisfies all edges from a to those neighbors. This σa is the optimal assignment for a. We will use this observation in the proofs of both lemmas. 5.1 Exact Algorithm for Graphs With Sufficiently Large Degrees The idea of this algorithm is to randomly select Θ(µnB ) vertices from B and try all possible assignments for them. When the assignment for the selected set is correct, we can determine the optimal assignment for every a ∈ A such that more than µda of its neighbors are in the selected set. The next lemma shows that, provided that the degrees of the vertices in A are not too small, the algorithm gives an assignment that satisfies all the edges with high probability. Lemma 5. For every constant c ≥ 1, the following statement holds: given a satisfiable instance of projection games that satisfies the µ-smoothness property and that da ≥ c logµ nA for all a ∈ A, one can find the optimal assignment for the game in time exp(O(µnB log |ΣB |)) · poly(nA , ΣA ) with probability 1/2. Proof. Let c1 be a constant greater than one. The algorithm is as follows. 1. For each b ∈ B, randomly pick it with probability c1 µ. Call the set of all picked vertices B ∗ . 2. Try every possible assignments for the vertices in B ∗ . For each assignment: (a) For each node a ∈ A, try every assignment σa ∈ ΣA for it. If there is exactly one assignment that satisfies all the edges that touch a, pick that assignment. 3. If encountered an assignment satisfying all edges, return that assignment. Next, we will show that, with probability 1/2, the algorithm returns the optimal assignment in time exp(O(µnB log |ΣB |)) · poly(nA , |ΣA |). For each b ∈ B, let Xb be an indicator variable for whether the vertex b is picked, i.e. b ∈ B ∗ . From step 1, we have E[Xb ] = c1 µ. 15 Let X be a random variable representing the number of vertices that are selected in step 1, i.e. X = |B ∗ |. We have E[X] = X E[Xb ] = nB c1 µ. b∈B For each a ∈ A, let Ya be a random variable representing the number of their neighbors that are picked, i.e. Ya = |B ∗ ∩ N (a)|. We have E[Ya ] = X E[Xb ] = da c1 µ. b∈N (a) Clearly, by iterating over all possible assignments for B ∗ , the algorithm run∗ ning time is |ΣB |O(|B |) = exp(O(|B ∗ | log |ΣB |)). Thus, if X = |B ∗ | = O(µnB ), the running time for the algorithm is exp(O(µnB log |ΣB |)). Let c2 be a constant greater than one. If X ≤ c2 c1 µnB , then the running time of the algorithm is exp(O(µnB log |ΣB |)) as desired. Since {Xb }b∈B are independent, using Chernoff bound, we have P r[X > c2 c1 µnB ] = P r[X > c2 E[X]]  c2 −1 nB c1 µ e < (c2 )c2 = e−nB c1 (c2 (log c2 −1)+1)µ . Now, consider each a ∈ A. By going through all possible combinations of assignments of vertices in B ∗ , we must go over the optimal assignment for B ∗ . In the optimal assignment, if more than µ fraction of a’s neighbors is in B ∗ (i.e., Ya > µda ), then in step 3, we get the optimal assignment for a due to Observation 1. Since {Xb }b∈N (a) are independent, using Chernoff bound, we can obtain the following inequality. P r[Ya ≤ da µ] = P r[Ya ≤  1 1 E[Ya ]] c1 da c1 µ −1  e c1  <   1  1 c1 c1 1 1 = e−da c1 (1− c1 − c1 16 log c1 )µ . Hence, we can conclude that the probability that this algorithm returns an optimal solution within exp(O(µnB log |ΣB |))-time is at least " ! # " ! # ^ _ Pr (Ya > da µ) ∧ (X ≤ c2 c1 µnB ) = 1 − P r (Ya ≤ da µ) ∨ (X > c2 c1 µnB ) a∈A a∈A ! ≥1− X − P r[X > c2 c1 µnB ] P r[Ya > da µ] a∈A >1− X e −da c1 (1− c1 − c1 log c1 )µ 1 ! 1 − e−nB c1 (c2 (log c2 −1)+1)µ a∈A Since c1 (1 − c11 − c11 log c1 ) and c1 (c2 (log c2 − 1) + 1) are constant, we can define constants c3 = c1 (1 − c11 − c11 log c1 ) and c4 = c1 (c2 (log c2 − 1) + 1). The probability that the algorithm returns an optimal solution can be written as X 1 − e−nB µc4 − e−da µc3 . a∈A Moreover, since we assume that da ≥ c logµ nA for all a ∈ A, we can conclude that the probability above is at least X 1 − e−nB µc4 − e−cc3 log nA = 1 − e−nB µc4 − nA e−cc3 log nA a∈A = 1 − e−nB µc4 − e−(cc3 −1) log nA Note that for any constants c∗3 , c∗4 , we can choose constants c1 , c2 so that c3 = c1 (1 − c11 − c11 log c1 ) ≥ c∗3 and c4 = c1 (c2 (log c2 − 1) + 1) ≥ c∗4 . This means that we can select c1 and c2 so that c3 ≥ 1c + c log2 nA ∈ O(1) and c4 ≥ nB2 µ ∈ O(1). Note also that here we can assume that log nA > 0 since an instance is trivial when nA = 1. Plugging c3 and c4 into the lower bound above, we can conclude that, for this c1 and c2 , the algorithm gives the optimal solution in the desired running time with probability more than 1/2. 5.2 Deterministic Approximation Algorithm For General Degrees A deterministic version of the above algorithm is shown below. In this algorithm, we are able to achieve an O(1) approximation ratio within asymptotically the same running time as the algorithm above. In contrast to the previous algorithm, this algorithm works even when the degrees of the vertices are small. The idea of the algorithm is that, instead of randomly picking a subset B ∗ of B, we will deterministically pick B ∗ . We say that a vertex a ∈ A is saturated if more than µ fraction of its neighbors are in B ∗ , i.e. |N (a) ∩ B ∗ | > µda . In each step, we pick a vertex in B that neighbors the highest number of unsaturated vertices, and add it to B ∗ . We do this until a constant fraction of the edges are satisfied. 17 Lemma 6. There exists an exp(O(µnB log |ΣB |)) · poly(nA , |ΣA |)-time O(1)approximation algorithm for satisfiable µ-smooth projection game instances. Proof. First, observe that when µ ≥ 1/4, we can simply enumerate all the assignments for B and then pick an assignment in A that maximizes number of satisfied edges. This algorithm runs in exp(O(nB log |ΣB |)) · poly(nA , |ΣA |) = exp(O(µnB log |ΣB |)) · poly(nA , |ΣA |) time and always returns an optimal assignment as desired. From this point onwards, we will focus on only when µ < 1/4. Next, we will consider two cases based on whether nA /|E| is larger than 1/4. First, if nA /|E| ≥ 1/4, then we use the following polynomial-time algorithm that works in a similar manner as the satisfy one neighbor algorithm: −1 1. For each b ∈ B, assign to b any σb ∈ ΣB such that π(a 6 ∅ for every 0 ,b) (σb ) = 0 a ∈ N (b). −1 2. For each a ∈ A, pick one neighbor ba of a. Assign to a any σa ∈ π(a,b (σb ). a) Observe that, in the first step, we can find σb for every b ∈ B because σbOP T satisfies the condition. Moreover, from the second step, (a, ba ) is satisfied for every a ∈ A. Thus, the output assignment that satisfies at least nA edges, which is at least 1/4 = Ω(1) fraction of all the edges as desired. We now turn our attention to the remaining case where nA /|E| < 1/4. Observe that, without loss of generality, we can assume that µ ≥ 1/da for all a ∈ A. This is because µ-smoothness is the same as uniqueness when µ < 1/da , and, after determining an optimal assignment for all saturated vertices, one can also find an optimal assignment for all the a’s with µ < 1/da in polynomial time (similarly to solving satisfiable instances of unique games in polynomial time). For convenience, let c1 be 1/4. The algorithm for this case can be described in the following steps. 1. Set B ∗ ← ∅. 2. Let S be the set ofPall saturated vertices, i.e. S = {a ∈ A | |N (a) ∩ B ∗ | > µda }. As long as | a∈S da | < c1 |E|: (a) Pick a vertex b∗ ∈ B − B ∗ with maximal |N (b) − S|. Set B ∗ ← B ∗ ∪ {b∗ }. 3. Iterate over all possible assignments to the vertices in B ∗ : (a) For each saturated vertex a ∈ S, search for an assignment that satisfies all edges in {a} × (N (a) ∩ B ∗ ). If, for any saturated vertex a ∈ S, this assignment cannot be found, skip the next part and go to the next assignment for B ∗ . (b) Assign each vertex in B an assignment in ΣB that satisfies the maximum number of edges that touch it. (c) Assign arbitrary elements from ΣA to the vertices in A that are not yet assigned. 4. Output the assignment that satisfies the maximum number of edges. We will divide the proof into two steps. First, we will show that the number of edges satisfied by the output assignment is at least c1 |E|. Second, we will show that the running time for this algorithm is exp(O(µnB log |ΣB |))·poly(nA , |ΣA |). 18 Observe that since we are going through all the possible assignments of B ∗ , we must go through the optimal assignment. Focus on this assignment. From Observation 1, for each saturated vertex a ∈ S, there is exactly one assignment that satisfies all the edges to B ∗ ; this assignment is the optimal assignment. Since we have the optimal assignments for all a ∈ S, we can satisfy P all the edges with one endpoint in S; the output assignment satisfies at least a∈S da edges. Moreover, when the algorithm Pterminates, the condition in step 2 must be false. Thus, we can conclude that a∈S da ≥ c1 |E|. As a result, the algorithm gives an approximation ratio of c11 = 4 = O(1). Since we go through all possible assignments for B ∗ , the running time of ∗ this algorithm is |ΣB |O(|B |) · poly(nA , |ΣA |). In order to prove that the running time is exp(O(µnB log |ΣB |)) · poly(nA , |ΣA |), we only need to show that |B ∗ | = O(µnB ). When the algorithm picks a vertex b∗ ∈ B to B ∗ we say that it hits all its neighbors that are unsaturated. Consider the total number of hits to all the vertices in A. Since saturated vertices do not get hit any more, we can conclude that each vertex a ∈ A gets at most µda + 1 hits. As a result, the total number of hits to all vertices a ∈ A is at most X (µda + 1) = µ|E| + nA . a∈A Next, consider the set B ∗ . Let B ∗ = {b1 , . . . , bm } where b1 , · · · , bm are sorted by the time, from the earliest to the latest, they get added into B ∗ . Let v(bi ) be the number of hits bi makes. Since the total number of hits by B ∗ equals the total number of hits to A, from the bound we established above, we have m X v(bi ) ≤ µ|E| + nA . i=1 Now, consider the adding of bi to B ∗ . Let Bi∗ be {b1 , . . . , bi−1 }, the set B ∗ at the time right before bi is added to B ∗ , and let Si be {a ∈ A | |N (a)∩Bi∗ | > µda }, the set of saturated vertices at the time right before bi is added to B ∗ . Since we are picking bi from B − Bi∗ with the maximum number of hits, the number of hits from bi is at least the average number of possible hits over all vertices in B − Bi∗ . That is v(bi ) = |N (bi ) − Si |   X 1  ≥ |N (b) − Si | |B − Bi∗ | b∈B−Bi∗   !  X X 1  ≥ |N (b) − Si | −  |N (b) − Si | . nB ∗ b∈B b∈Bi 19 We can also derive the following inequality. X X |N (b) − Si | = b∈B X 1 b∈B a∈N (b)−Si = X X 1(a,b)∈E b∈B a∈A−Si X X = 1(a,b)∈E a∈A−Si b∈B X = da a∈A−Si ! = |E| − X da a∈Si > (1 − c1 )|E|. Note that the last inequality comes from the condition in step 2 of the algorithm. Moreover, we have X |N (b) − Si | = b∈Bi∗ i−1 X |N (bj ) − Si | j=1 (Since Sj ⊆ Si ) ≤ i−1 X |N (bj ) − Sj | j=1 = ≤ i−1 X j=1 m X v(bj ) v(bj ) j=1 ≤ µ|E| + nA . Putting them together, we have v(bi ) > 1 ((1 − c1 )|E| − µ|E| − nA ) nB for all i = 1, . . . , m Pm From this and from i=1 v(bi ) ≤ µ|E| + nA , we can conclude that m< 1 nB ((1 = nB µ µ|E| + nA − c1 )|E| − µ|E| − nA ) ! nA 1 + |E|µ . nA (1 − c1 ) − µ − |E| 20 n Consider the term A 1+ |E|µ n A (1−c1 )−µ− |E| . Since c1 = 1/4, µ < 1/4 and nA |E| < 1/4, we can conclude that the denominator is Θ(1). Consider nA |E|µ . We have |E|µ = X µda . a∈A Since we assume that da ≥ 1/µ for all a ∈ A, we have nA ≤ |E|µ. In other nA words, |E|µ ≤ 1. Hence, we can conclude that the numerator is Θ(1). As a result, we can deduce that m = O(µnB ). Thus, the running time for the algorithm is exp(O(µn log |ΣB |)) · poly(nA , |ΣA |), which concludes our proof. 6 PTAS for Projection Games on Planar Graphs In this section, we prove our results for projection games on planar graphs. The section is divided naturally into three subsections. First, we show the NPhardness of projection games on planar graphs. Next, we describe PTAS for the problem. Lastly, we prove a matching running time lower bound for the PTAS. 6.1 NP-Hardness of Projection Games on Planar Graphs The NP-hardness of projection games on planar graphs is proved by reduction from 3-coloring on planar graphs. The latter was proven to be NP-hard by Garey, Johnson and Stockmeyer [12]. Theorem 5. Label Cover on planar graphs is NP-hard. Proof. We will prove this by reducing from 3-colorability problem on planar graph, which was proven by Garey, Johnson and Stockmeyer to be NP-hard [12]. The problem can be formally stated as following. Planar Graph 3-Colorability: Given a planar graph Ǧ = (V̌ , Ě), decide whether it is possible to assign each node a color from {red, blue, green} such that, for each edge, its endpoints are of different colors. Note that even though Ǧ is an undirected graph, we will represent each edge as a tuple (u, v) ∈ Ě where u, v ∈ V̌ . We will never swap the order of the two endpoints within this proof. We create a projection game (A, B, E, ΣA , ΣB , {πe }e∈E ) as follows: – Let A = Ě and B = V̌ . – E = {(a, b) ∈ A × B | b is an endpoint of a with respect to Ǧ}. – ΣA = {(red, blue), (red, green), (blue, red), (blue, green), (green, red), (green, blue)} and ΣB = {red, blue, green}. – For each e = (u, v) ∈ Ě = A, let π(e,u) : (c1 , c2 ) → c1 and π(e,v) : (c1 , c2 ) → c2 , i.e., π(e,u) and π(e,v) are projections to the first and the second element of the tuple respectively. 21 It is obvious that G = (A, B, E) is a planar graph since A, B are Ě, V̌ respectively and there exists an edge between a ∈ A and b ∈ B if and only if node corresponding to b in V̌ is an endpoint of an edge corresponding to a in Ě. This means that we can use the same planar embedding from the original graph Ǧ except that each node represent a node from B and at each edge, we put in a node from A corresponding to that edge. It is also clear that the size of the projection game is polynomial of the size of Ǧ. The only thing left to show is to prove that (A, B, E, ΣA , ΣB , {πe }e∈E ) is satisfiable if and only if Ǧ is 3-colorable. (⇒) Suppose that (A, B, E, ΣA , ΣB , {πe }e∈E ) is satisfiable. Let σu be the assignment for each vertex u ∈ A∪B that satisfies all the edges in the projection game. We will show that by assigning σv to v for all v ∈ V̌ = B, we are able to color Ǧ with 3 colors such that, for each edge, its endpoints are of different color. Since V̌ = B, σv ∈ {red, blue, green} for all v ∈ V̌ . Thus, this is a valid coloring. To see that no two endpoints of any edge are of the same color, consider an edge e = (u, v) ∈ Ě = A. From definition of E, we have (e, u) ∈ E and (e, v) ∈ E. Moreover, from definition of π(e,u) and π(e,v) , we can conclude that σe = (σu , σv ). Since σe ∈ ΣA , we can conclude that σu 6= σv as desired. Thus, Ǧ is 3-colorable. (⇐) Suppose that Ǧ is 3-colorable. In a valid coloring scheme, let cv be a color of node v for each v ∈ V̌ = B. Define the assignment of the projection game ϕA , ϕB as follows ϕA (a) = (cu , cv ) for all a = (u, v) ∈ A = Ě, ϕB (b) = cb for all b ∈ B = V̌ . Since cu 6= cv for all (u, v) ∈ Ě, we can conclude that the range of ϕA is a subset of ΣA . Moreover, it is clear that the range of ϕB is a subset of ΣB . As a result, the assignment defined above is valid. Moreover, it is obvious that πe (ϕA (a)) = ϕB (b) for all e = (a, b) ∈ E. Hence, the projection game (A, B, E, ΣA , ΣB , {πe }e∈E ) is satisfiable. As a result, we can conclude that Label Cover on planar graph is NP-hard. 6.2 PTAS for Projection Games on Planar Graphs We use the standard Baker’s technique for finding PTAS for problems on planar graphs [6] to construct one for projection games. Although not realized in the original paper by Baker, the technique relies on the concept of treewidth, which we will review the definition next. In this perspective, Baker’s technique constructs an algorithm based on two main steps: 1. Thinning Step: given a graph G = (V, E), partition E into subsets S1 , . . . , Sh such that, for each i = 1, . . . , h, we obtain a graph with bounded treewidth when all edges in Si are deleted from the original graph. 22 2. Dynamic Programming Step: for each i = 1, . . . , h, use dynamic programming to solve the problem on (V, E −Si ), which has bounded treewidth. Then, output the best solution among these h solutions. Tree Decomposition and Treewidth Before proceed to the algorithm, we first define tree decomposition. A tree decomposition of a graph G = (V, E) is a collection of subsets B1 , . . . , Bn ⊆ V and a tree T on these subsets such that 1. V = B1 ∪ · · · ∪ Bn . 2. For each edge (u, v) ∈ E, there exists Bi such that u, v ∈ Bi . 3. For each Bi and Bj , if v ∈ Bi ∩ Bj , then v must be in every subset along the path in T from Bi to Bj . The width of a tree decomposition ({B1 , . . . , Bn }, T ) is the largest size of B1 , . . . , Bn minus one. The treewidth of a graph is the minimum width across all possible tree decompositions. Thinning Even though a planar graph does not necessarily have a bounded treewidth, it is possible to delete a “small” set of edges from the graph to obtain a graph with bounded treewidth; by “small”, we do not refer to the size but refer to the change in the optimal solution for the projection game after we delete the edges from the set. To achieve this, we partition E into h sets such that, when deleting all edges from each set, the treewidth is bounded linearly on h. Later on, we will show that, for at least one of the sets, deleting all the edges from it affects the optimal solution of projection games by at most a factor of 1 − 1/h. Baker implicitly proved the following partitioning lemma in her paper [6]. For a more explicit formulation, please see [10]. 6 Lemma 7 ([6]). For any planar graph G = (V, E) and integer h, there is a O(h(|V | + |E|))-time algorithm that outputs a partition (S1 , . . . , Sh ) of E ,and, for each i, a tree decomposition of (V, E − Si ) having width at most O(h). Next, we will show that, for at least one of the Si ’s, removing all the edges from it affects the optimal solution by at most a factor of 1 − 1/h: Lemma 8. For any projection games instance on graph G = (V, E) and any partition (S1 , . . . , Sh ) of E, there exists i ∈ {1, . . . , h} such that the projection game instance resulted from removing all the edges in Si has the optimal solution that is within 1 − 1/h factor of the optimal of the original instance. Proof. Suppose that Esat is the set of all the edges satisfied by the optimal assignment ϕOP T of the original instance. From the pigeonhole principle, there exists at least one i ∈ {1, . . . , h} such that |Si ∩Esat | ≤ |Esat |/h. Since ϕOP T still 6 In both [6] and [10], the vertices, not edges, are partitioned. However, it is obvious that the lemma works for edges as well. 23 satisfies all the edges in E − (Si ∩ E) in the projection game instance induced by (V, E − Si ), we can conclude that the optimal assignment to this instance satisfies at least (1 − 1/h)|Esat | edges, which concludes the proof of this lemma. For the purpose of our algorithm, we select h = 1 + 1ε , which ensures that the treewidth of (V, E − Si ) is at most O(h) = O(1/ε) for each i = 1, . . . , h. Moreover, from the above lemma, we can conclude that, for at least one such i, the optimal solution of the projection game instance induced on (V, E − Si ) satisfies at least 1 − 1/h = 1/(1 + ε) times as many edges satisfied by the optimal solution of the original instance. Dynamic Programming Next, we present a dynamic programming algorithm that solves a projection game in a bounded treewidth bipartite graph G0 = (A0 , B 0 , E 0 ), given its tree decomposition ({B1 , . . . , Bn }, T ) of width w. At a high level, the algorithm works as follows. We use depth-first search starting at B1 to traverse the tree T . At each node Bi and each assignment ϕ : Bi → (ΣA ∪ ΣB ) of Bi , the subproblem is to find the maximum number of satisfied edges with both endpoints in one of the nodes in the subtree of T rooted at Bi when all the vertices in Bi are assigned according to ϕ. Let us call the answer to this subproblem aBi ,ϕ . After finish solving all such subproblems, we go through all assignments ϕ’s for B1 and output the maximum aB1 ,ϕ among such ϕ’s. This is the optimum of the projection game. Now, we give details on how to find each aBi ,ϕ based on the previously solved subproblems. We start by setting aBi ,ϕ to be the number of edges with both endpoints in Bi that are satisfied by ϕ. Then, for each child Bj of Bi , find the maximum value of aBj ,ϕ0 among all “compatible” assignments ϕ0 of Bj , i.e., ϕ0 such that ϕ(u) = ϕ0 (u) for all u ∈ Bi ∩ Bj . For each Bj , add this value to aBi ,ϕ . Lastly, for each Bj , find the number of edges with both endpoints in Bi ∩ Bj that are satisfied by ϕ and subtract this from aBi ,ϕ . The correctness of the algorithm follows easily from the description of the algorithm. To analyze the running time of the algorithm, first observe that there are (|ΣA |+|ΣB |)|Bi | ≤ (|ΣA |+|ΣB |)w+1 possible assignments for Bi .Thus, there are at most n(|ΣA | + |ΣB |)w+1 subproblems. Moreover, observe that the running time of the algorithm is dominated by the time spent to compute the maximum value of aBj ,ϕ0 for each child Bj . Since Bi has at most n children and there are at most (|ΣA | + |ΣB |)w+1 assignments for Bj , there are at most n(|ΣA | + |ΣB |)w+1 such (Bi , ϕ) pairs to enumerate for each (Bi , ϕ). Hence, the running time to solve each subproblem is O(n(|ΣA | + |ΣB |)w+1 ). As a result, the overall running time for the dynamic programming algorithm is O(n2 (|ΣA | + |ΣB |)2w+2 ). Summary We use the dynamic programming algorithm presented above to solve the projection game instance induced by the graph Gi = (V, E − Si ) for each i = 1, . . . , h. We then output the solution that satisfies most edges among 24 all i’s. As shown earlier, since we select h to be 1 + 1ε , at least one of the solution 1 found on Gi ’s satisfies at least 1+ε times as many edges as the optimal solution, which means that our algorithm is indeed an (1 + ε)-approximation algorithm. Finally, since we use the dynamic programming algorithm h times, the running time of the algorithm is O(hn2 (|ΣA |+|ΣB |)2w+2 ) = (nk)O(w+h) = (nk)O(h) = (nk)O(1/ε) . This gives us the desired PTAS for projection games on planar graphs. 6.3 PTAS Running Time Lower Bound for Projection Games on Planar Graphs We devote this subsection to prove the running time lower bound for PTAS for projection games on planar graphs as formalized in a theorem below. Theorem 6. If ETH holds, then there is no PTAS for projection games on γ 1−δ planar graphs running in time 2O(1/ε) (nk)O(1/ε) for any constants γ, δ > 0. The theorem essentially means that the PTAS in the previous subsection cannot be substantially improved in terms of running time unless ETH is false. The main idea of our proof is a reduction from Matrix Tiling problem introduced by Marx who has successfully used the problem as a basis for proving PTAS running time lower bounds for many problems [17]. Before we proceed to the proof, we start by reviewing the definition of Matrix Tiling and stating a theorem from [17] that we will use in the proof. The Matrix Tiling problem can be defined as follows. Input: Positive integers k̃, ñ and sets Si,j ⊆ [ñ] × [ñ] for each i, j = 1, . . . , k̃. Goal: Select si,j ∈ Si,j ∪ {F} for every i, j = 1 . . . , k̃ such that – for every i ∈ [k̃], j ∈ [k̃ − 1], if si,j , si,j+1 = 6 F, then (si,j )1 = (si,j+1 )1 , and, – for every i ∈ [k̃ − 1], j ∈ [k̃], if si,j , si+1,j = 6 F, then (si,j )2 = (si+1,j )2 that maximizes the number of (i, j) ∈ [k̃] × [k̃] such that si,j 6= F. Note here that [k̃] denotes {1, . . . , k̃} and (si,j )1 represents the value in the first coordinate of si,j . Similar notations in this section are defined in similar manners. We extract a running time lower bound for approximating Matrix Tiling from Theorem 2.3 in [17] below. Lemma 9 ([17]). If ETH holds, then one cannot distinguish a Matrix Tiling instance of optimum k̃ 2 (i.e. none of si,j is F) from that of optimum k̃ 2 /(1 + ε0 ) 0 1−δ 0 γ in time 2O(1/ε ) (k̃ñ)O(1/ε ) for any constants γ, δ > 0. 7 Now that we have stated the preliminaries, we are ready to describe the reduction from Matrix Tiling to the projection games problem: 7 In [17], the theorem is phrased as a running time lower bound for PTAS but it is clear from the proof that the theorem can be stated as our more specific version too. 25 Lemma 10. There is a polynomial-time reduction from a Matrix Tiling instance to a Label Cover instance with alphabet size k = O(ñ2 ) on planar graph with n = O(k̃ 2 ) vertices and |E| = 4k̃ 2 − 4k̃ edges such that – if the Matrix Tiling instance is of optimum k̃ 2 , then the projection game instance is satisfiable, and, – for any 0 ≤ l ≤ k̃ 2 − 1, if the Matrix Tiling instance is of optimum k̃ 2 − l, then the projection game is of optimum at least |E| − l/2 (i.e. at most l/2 edges are not satisfied in the optimal solution). Proof. The reduction proceeds as follows: – Let A be a set containing k̃ 2 vertices; call the vertices ai,j for all i, j ∈ [k̃]. – Let B be a set containing 2k̃ 2 − 2k̃ vertices; call the vertices bi+0.5,j for all i ∈ [k̃ − 1], j = [k̃] and bi,j+0.5 for all i ∈ [k̃], j = [k̃ − 1]. – Let E be {(ax,y , bz,t ) ∈ A × B | |x − z| + |y − t| = 0.5}. – Let ΣA be [ñ] × [ñ]. – Let ΣB be [ñ] ∪ {, }. – The projections πe ’s where e = (ax,y , bz,t ) can be defined as follows.  s1 if s ∈ Sx,y and x = z,    s if s ∈ S 2 x,y and y = t, πe (s) =   if s ∈ / Sx,y , x ≥ z and y ≥ t,     if s ∈ / Sx,y , x ≤ z and y ≤ t, for all (ax,y , bz,t ) ∈ E and for all s ∈ ΣA . For an illustration of the reduction, please refer to Figure 2 below. It is obvious that the reduction runs in polynomial time, and that k = O(ñ2 ), n = 3k̃ 2 − 2k̃ = O(k̃ 2 ) and |E| = 4k̃ 2 − 4k̃. Moreover, observe that (A ∪ B, E) is planar since, if we place ax,y on the plane at (x, y) for all ax,y ∈ A and place bz,t at (z, t) for all bz,t ∈ B, then no edges intersect each other. Now, we will prove the first property. Suppose that the Matrix Tiling instance has optimum k̃ 2 . In other words, there exists si,j ∈ Si,j for all i, j ∈ [k̃] such that, for each i, (si,j )1 ’s are equal for all j ∈ [k̃], and, for each j, (si,j )2 ’s are equal for all i ∈ [k̃]. By simply picking ϕA (ai,j ) = si,j for every ai,j ∈ A, ϕB (bi+0.5,j ) = (s1,j )2 for every bi+0.5,j ∈ B and, ϕB (bi,j+0.5 ) = (si,1 )1 for every bi,j+0.5 ∈ B, we can conclude that the projection game is satisfiable. Next, we will show the second property by contrapositive. Suppose that there is an assignment ϕA : A → ΣA and ϕA : B → ΣB that satisfies more than |E| − l/2 edges in the projection game. In other words, less than l/2 edges are not satisfied. We create a solution to Matrix Tiling instance as follows: ( ϕA (ai,j ) if all edges with one endpoint in N (ai,j ) are satisfied, si,j = F otherwise. 26 Fig. 2. An Example of the Reduction from Matrix Tiling to Label Cover. The Matrix Tiling instance is shown on the left and the projection game is on the right. For the projection game, circles represent vertices of the graph whereas squares represent alphabet symbols. Shaded circles are vertices in B and white circles are those in A. Each line between two squares means that the corresponding projection maps the alphabet symbol from a vertex in A to the alphabet symbol from a vertex in B. for every i, j ∈ [k̃]. Note here that N (ai,j ) is a set of neighbors of ai,j . To see that this is a solution to the Matrix Tiling instance, consider any i, j such that si,j 6= F. If i ≤ k̃ − 1, from the definition of si,j , the edges (ai,j , bi+0.5,j ) and (ai+1,j , bi+0.5,j ) are satisfied. This implies that ϕA (ai,j ) ∈ Si,j and (ϕA (ai,j ))2 = (ϕA (ai+1,j ))2 . In other words, si,j and si+1,j will not contradict each other in Matrix Tiling. Similarly, si,j does not contradict with si−1,j , si,j+1 , si,j−1 . Thus, the defined solution is a valid solution for Matrix Tiling. Next, since each unsatisfying edge can have an endpoint in N (ai,j ) for at most two pairs of i, j ∈ [k̃], the number of F’s in a solution to Matrix Tiling is at most 2 times the number of unsatisfied edges in the projection game. Thus, the solution to Matrix Tiling has less than l F’s. In other words, the optimum of Matrix Tiling instance is more than k̃ 2 − l, which completes our proof. Finally, we will use Lemma 9 together with the reduction to prove Theorem 6. Proof (Proof of Theorem 6). Suppose that there is a PTAS for planar projection γ 1−δ games with running time 2O(1/ε) (nk)O(1/ε) for some constants γ, δ > 0. We will now use Lemma 9 to show that ETH fails. Given a Matrix Tiling instance and ε. We use the reduction from Lemma 10 to create a projection game instance with k = O(ñ2 ), n = O(k̃ 2 ) and |E| = 4k̃ 2 − 4k̃. From the first property of the reduction, if the Matrix Tiling instance is of optimum k̃ 2 , then the projection game is satisfiable, i.e., is of optimum 4k̃ 2 − 4k̃. 27 On the other hand, for any ε0 > 0, from the second property, if the Matrix Tiling instance is of optimum at most k̃ 2 /(1 + ε0 ) = k̃ 2 − ε0 k̃ 2 /(1 + ε0 ), then the projection game is of optimum at most 4k̃ 2 − 4k̃ − ε0 k̃ 2 /(2(1 + ε0 )). Pick ε to be ε0 /20. From our choice of ε, if ε ≤ 1, then we have (4k̃ 2 − 4k̃)/(1 + ε) = 4k̃ 2 − 4k̃ − ε(4k̃ 2 − 4k̃)/(1 + ε) (From our choice of ε) = 4k̃ 2 − 4k̃ − ε0 (k̃ 2 − k̃)/(5(1 + ε0 /20)) ≥ 4k̃ 2 − 4k̃ − ε0 k̃ 2 /(5(1 + ε0 /20)) (ε ≤ 1) = 4k̃ 2 − 4k̃ − ε0 k̃ 2 /(2(1 + ε0 )). In other words, if we run the PTAS with the selected ε on the projection game, then we are able to distinguish the game with optimum 4k̃ 2 − 4k̃ from that with optimum at most 4k̃ 2 − 4k̃ − ε0 k̃ 2 /(2(1 + ε0 )). Hence, we can also distinguish a Matrix Tiling instance of optimum k̃ 2 from that of optimum k̃ 2 /(1 + ε0 ). Moreover, from our assumption, the running time of the PTAS is γ 2O(1/ε) (nk)O(1/ε) γ 1−δ 1−δ (Since k = O(ñ2 ) and n = O(k̃ 2 )) = 2O(1/ε) (ñk̃)O(1/ε) 0 γ 0 1−δ (Since ε = ε0 /20) = 2O(1/ε ) (ñk̃)O(1/ε ) . Thus, from Lemma 9, ETH fails, which concludes the proof for Theorem 6. References 1. Arora, S., Barak, B., and Steurer, D. Subexponential algorithms for unique games and related problems. In Proceedings of the 51st IEEE Symposium on Foundations of Computer Science (Washington, DC, USA, 2010), FOCS ’10, IEEE Computer Society, pp. 563–572. 2. Arora, S., Lund, C., Motwani, R., Sudan, M., and Szegedy, M. Proof verification and the hardness of approximation problems. Journal of the ACM 45, 3 (May 1998), 501–555. 3. Arora, S., and Safra, S. Probabilistic checking of proofs: A new characterization of NP. Journal of the ACM 45, 1 (Jan. 1998), 70–122. 4. Babai, L., Fortnow, L., Levin, L. A., and Szegedy, M. Checking computations in polylogarithmic time. In Proceedings of the 23rd ACM Symposium on Theory of Computing (New York, NY, USA, 1991), STOC ’91, ACM, pp. 21–32. 5. Babai, L., Fortnow, L., and Lund, C. Non-deterministic exponential time has two-prover interactive protocols. Computational Complexity 1, 1 (1991), 3–40. 6. Baker, B. S. Approximation algorithms for NP-complete problems on planar graphs. Journal of the ACM 41, 1 (Jan. 1994), 153–180. 7. Bellare, M., Goldreich, O., and Sudan, M. Free bits, pcps, and nonapproximability—towards tight results. SIAM Journal on Computing 27, 3 (June 1998), 804–915. 8. Charikar, M., Hajiaghayi, M., and Karloff, H. Improved approximation algorithms for label cover problems. Algorithmica 61, 1 (Sept. 2011), 190–206. 28 9. Dinur, I., and Steurer, D. Analytical approach to parallel repetition. In Proceedings of the 46th ACM Symposium on Theory of Computing (New York, NY, USA, 2014), STOC ’14, ACM, pp. 624–633. 10. Eppstein, D. Diameter and treewidth in minor-closed graph families. Algorithmica 27, 3 (2000), 275–291. 11. Feige, U. A threshold of ln n for approximating set cover. Journal of the ACM 45, 4 (July 1998), 634–652. 12. Garey, M., Johnson, D., and Stockmeyer, L. Some simplified NP-complete graph problems. Theoretical Computer Science 1, 3 (1976), 237 – 267. 13. Håstad, J. Some optimal inapproximability results. Journal of the ACM 48, 4 (July 2001), 798–859. 14. Holmerin, J., and Khot, S. A new PCP outer verifier with applications to homogeneous linear equations and max-bisection. In Proceedings of the 36th ACM Symposium on Theory of Computing (New York, NY, USA, 2004), STOC ’04, ACM, pp. 11–20. 15. Khot, S. Hardness results for coloring 3-colorable 3-uniform hypergraphs. In Proceedings of the 43rd IEEE Symposium on Foundations of Computer Science (Washington, DC, USA, 2002), FOCS ’02, IEEE Computer Society, pp. 23–32. 16. Khot, S. On the power of unique 2-prover 1-round games. In Proceedings of the 34th ACM Symposium on Theory of Computing (New York, NY, USA, 2002), STOC ’02, ACM, pp. 767–775. 17. Marx, D. On the optimality of planar and geometric approximation schemes. In Proceedings of the 48th IEEE Symposium on Foundations of Computer Science (Washington, DC, USA, 2007), FOCS ’07, IEEE Computer Society, pp. 338–348. 18. Moshkovitz, D. The projection games conjecture and the NP-hardness of ln napproximating set-cover. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Techniques, A. Gupta, K. Jansen, J. Rolim, and R. Servedio, Eds., vol. 7408 of Lecture Notes in Computer Science. Springer Berlin Heidelberg, 2012, pp. 276–287. 19. Moshkovitz, D., and Raz, R. Two-query PCP with subconstant error. Journal of the ACM 57, 5 (June 2008), 29:1–29:29. 20. Peleg, D. Approximation algorithms for the label-cover max and red-blue set cover problems. Journal of Discrete Algorithms 5, 1 (Mar. 2007), 55–64. 21. Raz, R. A parallel repetition theorem. SIAM Journal on Computing 27, 3 (1998), 763–803. 29 Appendix A Polynomial-time Approximation Algorithms for Projection Games for Nonuniform Preimage Sizes 1 In this section, we will describe a polynomial time O((nA |ΣA |) 4 )-approximation algorithm for satisfiable projection games, including those with nonuniform preimage sizes. It is not hard to see that, if the pe ’s are not all equal, then “know your neighbors’ neighbors” algorithm from Subsection 4 does not necessarily end up with at least hmax /p fraction of satisfied edges anymore. The reason is that, for a vertex a with large |N2 (a)| and any assignment σa ∈ ΣA to the vertex, the number of preimages in πe−1 (π(a,b) (σa )) might be large for each neighbor b of a and each edge e that has an endpoint b. We solve this issue, by instead of using all the edges for the algorithm, only using “good” edges whose preimage sizes for the optimal assignments are at most a particular value. However, this definition of “good” does not only depend on an edge but also on the assignment to the edge’s endpoint in B, which means that we need to have some extra definitions to address the generalization of h and p as follows. σbmax for each b ∈ B, denotes σb ∈ ΣB that maximizes the value of P −1 a∈N (b) |π(a,b) (σb )|. for each edge e = (a, b), denotes πe−1 (σbmax ) , the size of the pmax e preimage of e if b is assigned σbmax . P 1 max max over all e ∈ E, i.e. |E| . p denotes the average of pmax e e∈E pe max as a threshold for determining “good” edges We will use 2p as we shall see below. E(S) for each set of vertices S, denotes the set of edges with at least one endpoint in S, i.e. {(u, v) ∈ E | u ∈ S or v ∈ S}. max denotes the maximum number of edges coming out of N (a) for EN all a ∈ A, i.e., maxa∈A {|E(N (a))|}. ∗ ΣA (a) for each a ∈ A, denotes the set of all assignments σa to a that, for every b ∈ B, there exists an assignment σb such that, if a is assigned σa , b is assigned σb and all a’s neighbors are assigned according to a, then there are still possible assignments left for all vertices in N2 (a) ∩ N (b), i.e., {σa ∈ ΣA | for each b ∈ B, there is σb ∈ ΣB suchthat, for all T −1 −1 a0 ∈ N2 (a) ∩ N (b), b0 ∈N (a0 )∩N (a) π(a0 ,b0 ) (π(a,b0 ) (σa )) ∩ π(a0 ,b) (σb ) 6= ∅}. ∗ ∗ Note that σaOP T ∈ ΣA (a). In other words, if we replace ΣA with ΣA (a) for each a ∈ A, then the resulting instance is still satisfiable. −1 ∗ N ∗ (a, σa ) for each a ∈ A and σa ∈ ΣA (a), denotes {b ∈ N (a) | |π(a 0 ,b) (π(a,b) (σa ))| max 0 ≤ 2p for some a ∈ N (b)}. Provided that we assign σa to a, this set contains all the neighbors of a with at least one good edge as we discussed above. Note that π(a,b) (σa ) is the assignment to b 30 corresponding to the assignment of a. ∗ N2∗ (a, σa ) for each a ∈ A and σa ∈ ΣA (a), denotes all the neighbors of neighbors of a with at least one good edge with another endpoint in N (a) when a S −1 max is assigned σa , i.e., b∈N ∗ (a,σa ) {a0 ∈ N (b) | |π(a }. 0 ,b) (π(a,b) (σa ))| ≤ 2p ∗ ∗ ∗ h (a, σa ) for each a ∈ A and σa ∈ ΣA (a), denotes |E(N2 (a, σa ))|. In other words, h∗ (a, σa ) represents how well N2∗ (a, σa ) spans the graph G. ∗ ∗ E (a, σa ) for each a ∈ A and σa ∈ ΣA (a), denotes {(a0 , b) ∈ E | b ∈ N ∗ (a, σa ), −1 a0 ∈ N2∗ (a, σa ) and |π(a0 ,b) (π(a,b) (σa ))| ≤ 2pmax }. When a is assigned σa , this is the set of all good edges with one endpoint in N (a). h∗max denotes maxa∈A,σa ∈ΣA∗ (a) h∗ (a, σa ). 0 E denotes the set of all edges e ∈ E such that pe ≤ 2pmax , i.e., E 0 = {e ∈ E | pe ≤ 2pmax }. Recall that pe is defined earlier as |π −1 (σbOP T )|. Since E 0 depends on σbOP T , E 0 will not be used in the algorithms below but only used in the analyses. Same goes for all the notations defined below. G0 denotes a subgraph of G with its edges being E 0 . 0 E (S) for each set of vertices S, denotes the set of all edges in E 0 with at least one endpoint in S, i.e., {(u, v) ∈ E 0 | u ∈ S or v ∈ S}. 0 ES for each set of vertices S, denotes the set of edges with both endpoints in S, i.e. ES0 = {(a, b) ∈ E 0 | a ∈ S and b ∈ S}. 0 N (u) for each vertex u, denotes the set of vertices that are neighbors of u in the graph G0 . 0 N (U ) for each set of vertices U , denotes the set of vertices that are neighbors of at least one vertex in U in the graph G0 . 0 N2 (u) for each vertex u, denotes N 0 (N 0 (u)), the set of neighbors of neighbors of u in G0 . From the definitions above, we can derive two very useful observations as stated below. Observation 2. |E 0 | ≥ |E| 2 Proof. Suppose for the sake of contradiction that |E 0 | < |E| 2 . From the definition of E 0 , this means that, for more than |E| edges e, we have pe > 2pmax . As a 2 result, we can conclude that X |E|pmax < pe e∈E = X X p(a,b) b∈B a∈N (b) = X X −1 |π(a,b) (σbOP T )| b∈B a∈N (b) ≤ X X b∈B a∈N (b) = |E|pmax . 31 −1 |π(a,b) (σbmax )| This is a contradiction. Hence, |E 0 | ≥ |E| 2 . ∗ Observation 3. If σa = σaOP T , then N (a, σa ) = N 0 (a), N2∗ (a, σa ) = N20 (a) and E ∗ (a, σa ) = E 0 (N 0 (a)). This observation is obvious since, when pluging in σaOP T , each pair of definitions of N ∗ (a, σa ) and N 0 (a), N2∗ (a, σa ) and N20 (a), and E ∗ (a, σa ) and E 0 (N 0 (a)) becomes the same. Note also that from its definition, G0 is the graph with good edges when the optimal assignments are assigned to B. Unfortunately, we do not know the optimal assignments to B and, thus, do not know how to find G0 in polynomial time. max ∗ , ΣA (a), However, directly from the definitions above, σbmax , pmax , pmax , EN e ∗ ∗ ∗ ∗ N (a, σa ), N2 (a, σa ), h (a, σa ) and hmax can be computed in polynomial time. These notations will be used in the upcoming algorithms. Other defined notations we do not know how to compute in polynomial time and will only be used in the analyses. For the nonuniform preimage sizes case, we use five algorithms as opposed to four algorithms used in uniform case. We will proceed to describe those five algorithms. In the end, by using the best of these five, we are able to produce a polynomial-time O (nA |ΣA |)1/4 -approximation algorithm as desired. We now list the algorithms along with their rough descriptions; detailed description and analysis of each algorithm will follow later on: 1. Satisfy one neighbor – |E|/nB -approximation. Assign each vertex in A an arbitrary assignment. Each vertex in B is then assigned to satisfy one of its neighboring edges. This algorithm satisfies at least nB edges. 2. Greedy assignment – |ΣA |/pmax -approximation. Each vertex in B is assigned an assignment σbP∈ ΣB that has the largest number of preimages −1 across neighboring edges a∈N (b) |π(a,b) (σb )|. Each vertex in A is then assigned so that it satisfies as many edges as possible. This algorithm works well when ΣB assignments have many preimages. max -approximation. For a vertex a0 ∈ A, 3. Know your neighbors – |E|/EN ∗ pick an element of ΣA (a0 ) and assign it to a0 . Assign its neighbors N (a0 ) accordingly. Then, for each node in N2 (a0 ), we find one assignment that satisfies all the edges between it and vertices in N (a0 ). 4. Know your neighbors’ neighbors – O(|E|pmax /h∗max )-approximation. ∗ For a vertex a0 ∈ A, we go over all possible assignments in ΣA (a) to it. For each assignment, we assign its neighbors N (a0 ) accordingly. Then, for each node in N2 (a0 ), we keep only the assignments that satisfy all the edges between it and vertices in N (a0 ). When a0 is assigned the optimal assignment, the number of choices for each node in N2∗ (a0 ) is reduced to at most 2pmax possibilities. In this way, we can satisfy 1/2pmax fraction of the edges that touch N2∗ (a0 ). This satisfies many edges when there exists a0 ∈ A such that N2∗ (a0 ) spans many edges. max 5. Divide and Conquer – O(nA nB (h∗max + EN )/|E|2 )-approximation. ∗ ∗ For every a ∈ A, we can fully satisfy N (a) ∪ N2 (a) efficiently, and give up on satisfying other edges that touch this subset. Repeating this process, we max can satisfy Ω(|E|2 /(nA nB (h∗max + EN ))) fraction of the edges. 32 Aside from the new “know your neighbors” algorithm, the main idea of each algorithm remains the same as in the uniform preimage sizes case. All the details of each algorithm are described below. Satisfy One Neighbor Algorithm. The algorithm is exactly the same as that of the uniform case. Lemma 11. For satisfiable instances of projection games, an assignment that satisfies at least nB edges can be found in polynomial time, which gives the approximation ratio of |E| nB . Proof. The proof is exactly the same as that of Lemma 1. Greedy Assignment Algorithm. The algorithm is exactly the same as that of the uniform case. Lemma 12. There exists a polynomial-time satisfiable instances of projection games. |ΣA | pmax -approximation algorithm for Proof. The proof of this lemma differs only slightly from the proof of Lemma 2. The algorithm works as follows: P −1 1. For each b, assign it σb∗ that maximizes a∈N (b) |π(a,b) (σb )|. ∗ 2. For each a, assign it σa that maximizes the number of edges satisfied, |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }|. Let e∗ be the number of edges that get satisfied by this algorithm. We have X e∗ = |{b ∈ N (a) | π(a,b) (σa∗ ) = σb∗ }|. a∈A Due to the second step, for each a ∈ A, the number of edges satisfied is at least an average of the number of edges satisfied over all assignments in ΣA . This can be written as follows. X e∗ = |{b ∈ N (a) | π(a,b) (σa∗ ) = σb∗ }| a∈A ≥ X P |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }| |ΣA | P −1 |π(a,b) (σb∗ )| σa ∈ΣA a∈A = X a∈A = 1 |ΣA | b∈N (a) |ΣA | X X −1 |π(a,b) (σb∗ )|. a∈A b∈N (a) 33 From the definition of σbmax , we can conclude that σb∗ = σbmax for all b ∈ B. As a result, we can conclude that 1 X X −1 e∗ ≥ |π(a,b) (σb∗ )| |ΣA | a∈A b∈N (a) 1 X X −1 = |π(a,b) (σbmax )| |ΣA | a∈A b∈N (a) 1 X X max = p(a,b) |ΣA | a∈A b∈N (a) 1 = |E||pmax | |ΣA | pmax = |E|. |ΣA | Hence, this algorithm satisfies at least concludes our proof. pmax |ΣA | fraction of the edges, which Know Your Neighbors Algorithm The next algorithm shows that one can satisfy all the edges with one endpoint in the neighbors of a vertex a0 ∈ A. Lemma 13. For each a0 ∈ A, there exists a polynomial time algorithm for satisfiable instances of projection games. |E| |E(N (a0 ))| -approximation Proof. The algorithm works as follows: ∗ (a0 ) and assign it to a0 : 1. Pick any assignment σa0 ∈ ΣA 2. Assign σb = π(a0 ,b) (σa0 ) to b for all b ∈ N (a0 ). 3. For each a ∈ N2 (a0 ), find the set of plausible assignments to a, i.e., Sa = {σa ∈ ΣA | ∀b ∈ N (a) ∩ N (a0 ), π(a,b) (σa ) = σb }. Pick one σa∗ from this set ∗ and assign it to a. Note that Sa 6= ∅ from the definition of ΣA (a0 ). 4. Assign any assignment to unassigned vertices. 5. Output the assignment {σa∗ }a∈A , {σb∗ }b∈B from the previous step. From step 3, we can conclude that all the edges in E(N (a0 )) get statisfied. This yields |E(N|E| (a0 ))| approximation ratio as desired. Know Your Neighbors’ Neighbors Algorithm The next algorithm shows that if the neighbors of neighbors of a vertex a0 ∈ A expand, then one can satisfy many of the (many!) edges that touch the neighbors of a0 ’s neighbors. While the core idea is similar to the uniform version, in this version, we will need to consider N2∗ (a0 , σa0 ) instead of N2 (a0 ) in order to ensure that the number of possible choices left for each vertex in this set is at most 2pmax . 34 ∗ Lemma 14. For  each a0 ∈ A and σa0 ∈ ΣA (a0 ), there exists a polynomialmax |E|p time O h∗ (a0 ,σa ) -approximation algorithm for satisfiable instances of projec0 tion games. ∗ Proof. To prove Lemma 14, we first a0 ∈ A  fix  and σa0 ∈ ΣA (a0 ). We will de∗ h (a0 ,σa0 ) scribe an algorithm that satisfies Ω edges, which implies the lemma. pmax The algorithm works as follows: 1. Assign σb = π(a0 ,b) (σa0 ) to b for all b ∈ N (a0 ). 2. For each a ∈ A, find the set of plausible assignments to a, i.e., Sa = {σa ∈ ΣA | ∀b ∈ N (a) ∩ N (a0 ), π(a,b) (σa ) = σb }. Note that Sa 6= ∅ from the ∗ definition of ΣA (a0 ). 3. For all b ∈ B, pick an assignment σb∗ for b that maximizes the average number of satisfied edges in Sa to vertices a in N (b) ∩ N2∗ (a0 ), Pover all assignments −1 i.e., maximizes a∈N (b)∩N ∗ (a0 ) |π(a,b) (σb ) ∩ Sa |. 2 4. For each vertex a ∈ A, pick an assignment σa∗ ∈ Sa that maximizes the number of satisfied edges, |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }| over all σa ∈ Sa . h∗ (a ,σ ) 0 a0 edges. We will prove that this algorithm indeed satisfies at least pmax Let e∗ be the number of edges satisfied by the algorithm. We have X e∗ = |{b ∈ N (a) | π(a,b) (σa∗ ) = σb∗ }|. a∈A Since for each a ∈ A, the assignment σa∗ is chosen to maximize the number of edges satisfied, we can conclude that the number of edges satisfied by selecting σa∗ is at least the average of the number of edges satisfied over all σa ∈ Sa . As a result, we can conclude that P X σ ∈S |{b ∈ N (a) | π(a,b) (σa ) = σb∗ }| ∗ a a e ≥ |Sa | a∈A P P X σa ∈Sa b∈N (a) 1π(a,b) (σa )=σ∗ b = |Sa | a∈A P P X b∈N (a) σa ∈Sa 1π(a,b) (σa )=σ∗ b = |Sa | a∈A P −1 X b∈N (a) |π(a,b) (σb∗ ) ∩ Sa | = |Sa | a∈A = −1 X X |π(a,b) (σb∗ ) ∩ Sa | |Sa | b∈B a∈N (b) ≥ X −1 |π(a,b) (σb∗ ) ∩ Sa | X b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) 35 |Sa | From the definition of N2∗ (a0 , σa0 ), we can conclude that, for each a ∈ −1 max there exists b0 ∈ N ∗ (a0 ) ∩ N (a) such that |π(a,b . 0 ) (σb0 )| ≤ 2p −1 Moreover, from the definition of Sa , we have Sa ⊆ π(a,b0 ) (σb0 ). As a result, we can arrive at the following inequalities. N2∗ (a0 , σa0 ), −1 |Sa | ≤ |π(a,b 0 ) (σb0 )| ≤ 2pmax . This implies that e∗ ≥ 1 X X −1 |π(a,b) (σb∗ ) ∩ Sa |. max 2p b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) ∗ (a0 ), we can conclude that, for each b ∈ B, there From the definition of ΣA −1 exists σb ∈ B such that π(a,b) (σb ) ∩ Sa 6= ∅ for all a ∈ N2 (a0 ) ∩ N (b). Since −1 N2∗ (a0 , σa0 ) ⊆ N2 (a0 ), we can conclude that |π(a,b) (σb ) ∩ Sa | ≥ 1 for all a ∈ ∗ N2 (a0 , σa0 ) ∩ N (b). P −1 Since we pick the assignment σb∗ that maximizes a∈N (b)∩N ∗ (a0 ) |π(a,b) (σb∗ )∩ 2 Sa | for each b ∈ B, we can conclude that e∗ ≥ ≥ ≥ 1 2pmax 1 2p max 2p max X X b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) X X −1 |π(a,b) (σb∗ ) ∩ Sa | −1 |π(a,b) (σb ) ∩ Sa | b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) 1 X X 1. b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) The last term can be rewritten as 1 2p X X max 1= b∈B a∈N (b)∩N2∗ (a0 ,σa0 ) = = 1 X X a∈N2∗ (a0 ,σa0 ) b∈N (a) max 2p 1 2pmax X 1 da a∈N2∗ (a0 ,σa0 ) h∗ (a0 , σa0 ) . 2pmax As a result, we can conclude that this algorithm gives an assignment that sath∗ (a0 ,σa0 ) isfies at least 2pmax edges out of all the |E| edges. Hence, this is a polynomial  |E|pmax time O h∗ (a0 ,σa ) -approximation algorithm as desired. 0 36 Divide and Conquer Algorithm. We will present an algorithm that separates the graph into disjoint subgraphs for which we can find the optimal assignments in polynomial time. We shall show below that, if h∗ (a, σa ) is small for all a ∈ A ∗ and σa ∈ ΣA (a), then we are able to find such subgraphs that contain most of the graph’s edges.   max n n (h∗ +EN ) -approximation Lemma 15. There exists a polynomial-time O A B max |E|2 algorithm for satisfiable instances of projection games. Proof. To prove this lemma, we will present an algorithm that gives an assign  3 ment that satisfies Ω nA nB (h∗|E| +E max ) edges. max N We use P to represent the collection of subgraphs we find. The family P S consists of disjoint sets of vertices. Let VP be P ∈P P . For any set S of vertices, define GS to be the graph induced on S with respectSto G. Moreover, define ES to be the set of edges of GS . We also define EP = P ∈P EP . Note that ES is similar to ES0 defined earlier in the appendix. The only difference is that ES0 is with respect to G0 instead of G. The algorithm works as follows. 1. Set P ← ∅. ∗ (a) such that 2. While there exists a vertex a ∈ A and σa ∈ ΣA |E ∗ (a, σa ) ∩ E(A∪B)−VP | ≥ 1 |E|2 : 16 nA nB (a) Set P ← P ∪ {(N2∗ (a, σa ) ∪ N ∗ (a, σa )) − VP }. 3. For each P ∈ P, find in time poly(|ΣA |, |P |) an assignment to the vertices in P that satisfies all the edges spanned by P . This can be done easily by assigning σa to a and π(a,b) (σa ) to b ∈ B ∩ P . Then assign any plausible assignment to all the other vertices in A ∩ P . We will divide the proof into two parts. First, we will show that when we ∗ cannot find a vertex a and an assignment σa ∈ ΣA (a) in step 2, E(A∪B)−VP ≤ 3|E| 4 . Second,  we will show that  the resulting assignment from this algorithm satisfies Ω |E|3 max ) nA nB (h∗ max +EN edges. ∗ We will start by showing that, if no vertex a and an assignment σa ∈ ΣA (a) 3|E| in step 2 exist, then E(A∪B)−VP ≤ 4 . ∗ Suppose that we cannot find a vertex a and an assignment σa ∈ ΣA (a) in 2 1 |E| ∗ step 2. In other words, |E (a, σa ) ∩ E(A∪B)−VP | < 16 nA nB for all a ∈ A and ∗ σa ∈ ΣA (a). ∗ Since σaOP T ∈ ΣA (a) for all a ∈ A, we can conclude that |E ∗ (a, σaOP T ) ∩ E(A∪B)−VP | < 37 1 |E|2 . 16 nA nB From Observation 3, we have E ∗ (a, σ OP T ) = E 0 (N 0 (a)). As a result, we have 1 |E|2 > |E ∗ (a, σaOP T ) ∩ E(A∪B)−VP | 16 nA nB = |E 0 (N 0 (a)) ∩ E(A∪B)−VP | for all a ∈ A. 0 Since E 0 (N 0 (a)) = EN 0 (a)∪N 0 (a) , we can rewrite the last term as 2 0 0 0 |E (N (a)) ∩ E(A∪B)−VP | = |EN 0 (a)∪N 0 (a) ∩ E(A∪B)−VP | 2 0 = |EN 0 (a)∪N 0 (a)−V |. P 2 P 0 0 Consider a∈A |EN 0 (a)∪N 0 (a)−V |. Since |EN 0 (a)∪N 0 (a)−V | < P P 2 2 a ∈ A, we have the following inequality: 2 1 |E| 16 nA nB for all X |E|2 0 > |EN 0 (a)∪N 0 (a)−V |. P 2 16nB a∈A Let N (v) = N (v) − VP and N2p (v) = N20 (v) − VP . Similary, define N p (S) for a subset S ⊆ A∪B. It is easy to see that N2p (v) ⊇ N p (N p (v)). This implies that, 0 0 for all a ∈ A, we have |EN p (a)∪N p (a) | ≥ |EN p (a)∪N p (N p (a)) |. Moreover, it is easy 2 P 0 p to see that, for all a ∈ A − VP , we have |EN p (a)∪N p (N p (a)) | = b∈N p (a) |N (b)|. Thus, the following holds: X X 0 |E(N |E(N p (a)∪N2p (a)) | 0 (a)∪N 0 (a))−V | = P 2 0 p a∈A a∈A ≥ X |E(N p (a)∪N2p (a)) | a∈A−VP = X X |N p (b)| a∈A−VP b∈N p (a) = X X |N p (b)| b∈B−VP a∈N p (b) = X |N p (b)|2 . b∈B−VP From Jensen’s inequality, we have X a∈A 1 0 |E(N 0 (a)∪N 0 (a))−V | ≥ P 2 |B − VP | !2 X |N p (b)| b∈B−VP 1 = E0 |B − VP | (A∪B)−VP 2 1 0 ≥ E(A∪B)−V . P nB 38 2 Since 1 nB |E|2 16nB ≥ P a∈A |E(N 0 (a)∪N20 (a))−VP | and P a∈A |E(N 0 (a)∪N20 (a))−VP | ≥ 2 0 , we can conclude that E(A∪B)−V P |E| 0 . ≥ E(A∪B)−V P 4 0 and E(A∪B)−VP . We have Consider E(A∪B)−V P 0 E(A∪B)−V ∪ (E − E 0 ) ⊇ E(A∪B)−VP P 0 + |E − E 0 | ≥ E(A∪B)−VP E(A∪B)−V P |E| + |E − E 0 | ≥ E(A∪B)−VP . 4 From Observation 2, we have |E 0 | ≥ |E| 2 . Thus, we have 3|E| ≥ E(A∪B)−VP , 4 which concludes the first part of the proof. show Next, we will  that the assignment the algorithm finds satisfies at least 3 Ω nA nB (h∗|E| +E max ) edges. Since we showed that 3|E| ≥ E(A∪B)−VP when 4 max N  2 the algorithm terminates, it is enough to prove that |EP | ≥ 16nA nB (h|E| . max ) |E| − E(A∪B)−VP ∗ max +EN Note that the algorithm guarantees to satisfy all the edges in EP . We will prove this by using induction to show that at any point in the algo 2 rithm, |EP | ≥ 16nA nB (h|E| . max ) |E| − E(A∪B)−VP ∗ max +EN  2 Base Case. At the beginning, we have |EP | = 0 = 16nA nB (h|E| , max ) |E| − E(A∪B)−VP ∗ +E max N which satisfies the inequality. Inductive Step. The only step in the algorithm where any term in the inequality changes is step 2a. Let Pold and Pnew be the set P before and after step 2a is executed, respectively. Let a be the vertex selected in step 2. Suppose that Pold satisfies the inequality. Since |EPnew | = |EPold | + |E(N ∗ (a,σa )∪N2∗ (a,σa ))−VPold |, we have |EPnew | = |EPold | + |E(N ∗ (a,σa )∪N2∗ (a,σa ))−VPold | = |EPold | + |E(N ∗ (a,σa )∪N2∗ (a,σa )) ∩ E(A∪B)−VPold |. From the condition in step 2, we have |E ∗ (a, σa ) ∩ E(A∪B)−VPold | ≥ Moreover, E(N ∗ (a,σa )∪N2∗ (a,σa )) ⊇ E ∗ (a, σa ) holds. As a result, we have |EPnew | = |EPold | + |E(N ∗ (a,σa )∪N2∗ (a,σa )) ∩ EA∪B−VPold | ≥ |EPold | + |E ∗ (a, σa ) ∩ E(A∪B)−VPold | ≥ |EPold | + 1 |E|2 . 16 nA nB 39 2 1 |E| 16 nA nB .    Now, consider |E| − |E(A∪B)−VPnew | − |E| − |E(A∪B)−VPold | . We have    |E| − |E(A∪B)−VPnew | − |E| − |E(A∪B)−VPold | = |E(A∪B)−VPold | − |E(A∪B)−VPnew | Since VPnew = VPold ∪ (N2∗ (a, σa ) ∪ N ∗ (a, σa )), we can conclude that ((A ∪ B) − VPold ) ⊆ ((A ∪ B) − VPnew ) ∪ (N2∗ (a, σa ) ∪ N ∗ (a, σa )) . Thus, we can also derive E(A∪B)−VPold ⊆ E((A∪B)−VP (N2∗ (a,σa )∪N ∗ (a,σa )) ∪ {(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa ) or b0 ∈ N ∗ (a, σa )}. new )∪ = E(A∪B)−VPnew Moreover, we can write {(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa ) or b0 ∈ N ∗ (a, σa )} as {(a , b0 ) ∈ E | a0 ∈ N2∗ (a, σa )} ∪ {(a0 , b0 ) ∈ E | b0 ∈ N ∗ (a, σa )}. Since N ∗ (a, σa ) ⊆ N (a), we can conclude that 0 {(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa ) or b0 ∈ N ∗ (a, σa )} ⊆{(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa )} ∪ {(a0 , b0 ) ∈ E | b0 ∈ N (a)}. Thus, we can conclude that |{(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa ) or b0 ∈ N ∗ (a, σa )}| ≤ |{(a0 , b0 ) ∈ E | a0 ∈ N2∗ (a, σa )}| + |{(a0 , b0 ) ∈ E | b0 ∈ N (a)}| = h∗ (a, σa ) + |E(N (a))|. Hence, we can conclude that E(A∪B)−VPold ≤ E(A∪B)−VPnew ∪ {(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)} ≤ E(A∪B)−VPnew + |{(a0 , b0 ) ∈ E | a0 ∈ N2 (a) or b0 ∈ N (a)}| ≤ E(A∪B)−VPnew + h∗ (a, σa ) + |E(N (a))| max . ≤ E(A∪B)−VPnew + h∗max + EN  max ∗ . EN This implies that |E| − E(A∪B)−V  P increases by at most∗ hmax +max and Hence, since |E| − E(A∪B)−VP increases by at most hmax + EN |EP | increases by at least conclude that |EPnew | ≥ 2 1 |E| 16 nA nB and from the inductive hypothesis, we can  |E|2 |E| − E(A∪B)−VPnew . max ∗ 16nA nB (hmax + EN ) Thus, the inductive step is true and the inequality holds at any point during the execution of the algorithm.  2 When the algorithm terminates, since |EP | ≥ 16nA nB (h|E| ∗ +E max ) |E| − E(A∪B)−VP max and 3|E| 4 ≥ E(A∪B)−VP , we can conclude that |EP | ≥ the algorithm guarantees to satisfy every edge in EP , it approximation ratio, which concludes our proof of Lemma 15. 40 N |E|3 max ) . Since 64nA nB (h∗ +EN max  max nA nB (h∗ ) max +EN yields an O |E|2 Proof of Theorem 2 Proof. Using Lemma 14 with a0 and σa0 that maximizes the value of h∗ (a0 , σa0 ), ∗ i.e., σa0 ) = h∗max , we can conclude that there exists a polynomial-time  h (a0 ,  O |E|pmax h∗ max -approximation algorithm for satisfiable instances of projection games. Similarly, from Leamma 13 with a0 that maximizes the value of E(N (a0 )), max i.e., |E(N (a0 ))| = EN , there exists a polynomial-time E|E| max -approximation N algorithm for satisfiable instances of projection games. Moreover, from Lemmas 11, 12 and 15, there exists a polynomial-time |E| nB A| approximation algorithm, a polynomial-time p|Σ max -approximation algorithm and   max n n (h∗ +EN ) -approximation algorithm for satisfia polynomial time O A B max |E|2 able instances of the projection game. Consider the following two cases. max max )/|E|2 ) = O(nA nB h∗max /|E|2 ). , we have O(nA nB (h∗max +EN First, if h∗max ≥ EN Using the best of the first, second, fourth and fifth algorithms, the smallest of the four approximation factors is at most as large as their geometric mean, i.e., s ! |ΣA | |E|pmax nA nB h∗max 4 |E| O · = O((nA |ΣA |)1/4 ). · · nB pmax h∗max |E|2 max max max Second, if EN > h∗max , we have O(nA nB (h∗max +EN )/|E|2 ) = O(nA nB EN /|E|2 ). We use the best answer we get from the first, second, third and fifth algorithms. The smallest of the four approximation factors is at most as large as their geometric mean, i.e., s !  1/4 ! max nA nB EN |E| |ΣA | nA |ΣA | |E| 4 · · max · =O . O nB pmax EN |E|2 pmax It is obvious that pmax is at least one. Thus, we can conclude that the approxi1 mation factor is at most O((nA |ΣA |) 4 ). This concludes the proof of Theorem 2 for the nonuniform preimage sizes case. 41
8cs.DS
Distributed Online Learning of Event Definitions Nikos Katzouris1 , Alexander Artikis2,1 , and Georgios Paliouras1 1 arXiv:1705.02175v1 [cs.AI] 5 May 2017 2 National Center for Scientific Research “Demokritos”, Athens, Greece Department of Maritime Studies, University of Piraeus, Piraeus, Greece {nkatz,a.artikis,paliourg}@iit.demokritos.gr Abstract. Logic-based event recognition systems infer occurrences of events in time using a set of event definitions in the form of first-order rules. The Event Calculus is a temporal logic that has been used as a basis in event recognition applications, providing among others, direct connections to machine learning, via Inductive Logic Programming (ILP). OLED is a recently proposed ILP system that learns event definitions in the form of Event Calculus theories, in a single pass over a data stream. In this work we present a version of OLED that allows for distributed, online learning. We evaluate our approach on a benchmark activity recognition dataset and show that we can significantly reduce training times, exchanging minimal information between processing nodes. 1 Introduction Event recognition systems [5] process sequences of simple events, such as sensor data, and recognize complex events, i.e. events that satisfy some pattern. Logic-based systems for event recognition typically use a knowledge base of first-order rules to represent complex event patterns and a reasoning engine to detect such patterns in the incoming data. The Event Calculus (EC) [16] has been used as the basis for event recognition systems [1], offering direct connections to machine learning, via Inductive Logic Programming (ILP) [4]. Event recognition applications deal with noisy data streams. Methods that learn from such streams typically build a decision model by a single pass over the input [9]. OLED (Online Learning of Event Definitions) [15] is an ILP system that learns event definitions in the form of EC theories in a single pass over a relational data stream. In this work we present an extension of OLED, that allows for learning a theory in an online and parallel fashion, from disjoint, possibly geographically distributed data streams (it therefore assumes no shared memory). Our approach is based on a simple parallelization scheme of the core OLED functionality and it is approapriate for distributed learning. OLED learns clauses in top-down manner, by gradually specializing an over-general clause. Its single-pass strategy is based on the Hoeffding bound [12], a tool that allows to build decision models by estimating their quality on a small subset of the input. OLED uses the Hoeffding bound to estimate the quality of candidate specializations of a clause on subsets of the input stream. In the proposed prallelization strategy, clauses are evaluated independently on disjoint data streams and their scores are combined whenever a specialization decision must be made. We present an evaluation of our approach on an a benchmark activity recognition dataset and show that 2 Katzouris et al. Predicate happensAt(E, T ) initiatedAt(F, T ) Predicate Meaning Axioms Event E occurs at time T holdsAt(F, T + 1) ← At time T a period of time for initiatedAt(F, T ). (1) which fluent F holds is initiated terminatedAt(F, T ) At time T a period of time for holdsAt(F, T + 1) ← which fluent F holds is terminated holdsAt(F, T ), (2) not terminatedAt(F, T ). holdsAt(F, T ) Fluent F holds at time T Table 1. The basic predicates and domain-independent axioms of the EC dialect. we can significantly reduce training times, exchanging minimal information between processing nodes. This work, therefore, paves the way for relational learning in highvelocity data streams. The rest of this paper is structured as follows: In Section 2 we present some background on the EC and provide a running example. In Section 3 we present OLEDand in Section 4 we present its distributed version. In Section 5 we present our experimental results, while in Section 6 we discuss related work. Finally, in Section 7 we discuss some directions for future work and conclude. 2 Background and Running Example The Event Calculus (EC) [16] is a temporal logic for reasoning about events and their effects. Its ontology consists of time points (integer numbers); fluents, i.e. properties that have different values in time; and events, i.e. occurrences in time that may alter fluents’ values. The axioms of the EC incorporate the common sense law of inertia, according to which fluents persist over time, unless they are affected by an event. We use a simplified version of the EC that has been shown to suffice for event recognition [1]. The basic predicates and its domain-independent axioms are presented in Table 1. Axiom (1) states that a fluent F holds at time T if it has been initiated at the previous time point, while Axiom (2) states that F continues to hold unless it is terminated. Definitions for initiatedAt/2 and terminatedAt/2 predicates are given in an applicationspecific manner by a set of domain-specific axioms. We illustrate our approach using the task of activity recognition, as defined in the CAVIAR project3 . The CAVIAR dataset consists of videos where actors perform some activities. Manual annotation (performed by the CAVIAR team) provides ground truth for two activity types. The first type corresponds to simple events and consists of knowledge about the activities of a person at a certain video frame/time point, such as walking, or standing still. The second activity type corresponds to complex events and consists of activities that involve more than one person, e.g. two people meeting each other, or moving together. The goal is to recognize complex events as combinations of simple events and additional domain knowledge, such as a person’s direction and position. Table 2(a) presents some example CAVIAR data, consisting of a narrative of simple events in terms of happensAt/2, expressing people’s short-term activities, and context properties in terms of holdsAt/2, denoting people’ coordinates and direction. Table 2(a) 3 http://homepages.inf.ed.ac.uk/rbf/CAVIARDATA1/ Distributed Online Learning of Event Definitions 3 (a) Narrative for time 1: Narrative for time 2: (b) Two Domain-specific axioms: happensAt(walk (id1 ), 1 ) happensAt(walk (id2 ), 1 ) holdsAt(coords(id1 , 201 , 454 ), 1 ) holdsAt(coords(id2 , 230 , 440 ), 1 ) holdsAt(direction(id1 , 270 ), 1 ) holdsAt(direction(id2 , 270 ), 1 ) happensAt(walk (id1 ), 2 ) initiatedAt(moving(X, Y ), T ) ← happensAt(walk (id2 ), 2 ) happensAt(walk (X ), T ), holdsAt(coords(id1 , 201 , 454 ), 2 ) happensAt(walk (Y ), T ), holdsAt(coords(id2 , 227 , 440 ), 2 ) distLessThan(X , Y , 25 , T ), holdsAt(direction(id1 , 275 ), 2 ) dirLessThan(X , Y , 45 , T ). holdsAt(direction(id2 , 278 ), 2 ) Annotation for time 1: not holdsAt(move(id1 , id2 ), 1) Annotation for time 2: holdsAt(move(id1 , id2 ), 2) terminatedAt(move(X, Y ), T ) ← happensAt(inactive(X ), T ), distMoreThan(X , Y , 30 , T ). Table 2. (a) Example data from activity recognition. E.g., at time point 1 person id1 is walking, her (x, y) coordinates are (201, 454) and her direction is 270◦ . The annotation for the same time point states that persons id1 and id2 are not moving together, in contrast to the annotation for time point 2. (b) An example of two domain-specific axioms in the EC. E.g. the first clause dictates that moving of two persons X and Y is initiated at time T if both X and Y are walking at time T , their euclidean distance is less than 25 and their difference in direction is less than 45◦ . also shows the annotation of complex events (long-term activities) for each time-point in the narrative. Negated complex events’ annotation is obtained via the closed world assumption (although both positive and negated annotation atoms are presented in Table 2, to avoid confusion). Table 2(b) presents two domain-specific axioms in the EC. Our goal is to learn definitions of complex events in terms of initiation and termination conditions, as in Table 2(b). In the Learning from Interpretations [3] ILP setting that we use in this work, each training example is an interpretation, i.e. a set of true ground atoms, as in Table 2(a). Given a set of training interpretations I and some background theory B, which in our case consists of the domain-independent axioms of the EC, the goal is to find a theory H, such that B ∪ H covers as many I ∈ I as possible, where B ∪ H covers I when I is a model of B ∪ H. Although different semantics are possible, in this work a “model” is a stable model [10]. 3 The OLED System OLED [15] learns a theory by joining together independently-constructed clauses, each of which is learnt in an online fashion. OLED relies on the Hoeffding bound [12] to approximate the quality of a clause on the entire input using only a subset of the input. Given a random variable X with range in [0, 1] and an observed mean X of its values after n independent observations, the Hoeffding Bound states that, with probability 1 − δ, the true mean X̂ of the variable lies in an interval (X − , X + ), where  = q ln(1/δ) 2n . In other words, the true average can be approximated by the observed one with probability 1 − δ, given an error margin  that becomes smaller as the number of observations n increases. OLED learns a clause in a top-down fashion, by specializing it using literals from a bottom clause [4]. The Hoeffding bound is utilized in the specialization process a follows: Given a clause evaluation function G and some clause r, OLED evaluates r and all of its candidate specializations on training examples that stream-in. Assume that 4 Katzouris et al. after n training examples from the input stream, r1 is r’s specialization with the highest observed mean G-score G and r2 is the second-best one, i.e. ∆G = G(r1 )−G(r2 ) > 0. Then by the Hoeffding bound we have that for the true mean of the scores’ difference q ∆Ĝ it holds that ∆Ĝ > ∆G − , with probability 1 − δ, where  = ln(1/δ) 2n . Hence, if ∆G >  then ∆Ĝ > 0, implying that r1 is indeed the best specialization, with probability 1 − δ. In order to decide which specialization to select, it thus suffices to accumulate examples from the input stream until ∆G > . These examples need not be stored or reprocessed. Each example is processed once to extract the necessary statistics for calculating G-scores and it is subsequently discarded, thus giving rise to an online (single-pass) clause construction strategy. To ensure that no clause r is replaced by a specialization of lower quality, r itself is also considered as a potential candidate along with its specializations, ensuring that specializing r is a better decision, with probability 1 − δ, than not specializing it at all. The default specialization process follows a FOIL-like, hill-climbing strategy, where a single literal is added to a clause at each specialization step. However, OLED supports different specialization strategies as well, e.g. by allowing to simultaneously try all specializations up to a given clause length, or by supporting user-defined, TILDE-like look-ahead specifications [2]. To calculate G-scores, each clause r is equipped with a true positive (TP ), a false positive (FP ) and a false negative (FN ) counter, whose values are updated accordingly as r gets evaluated on training examples that stream-in. True negative counts are not taken into account, since the annotation for complex events is acquired via the closed world assumption. Also, r has an example counter that counts the number of examples on which r has been evaluated so far and is used in the calculation of  in the Hoeffding bound-based search heuristic. Although different scoring functions may be plugged into OLED, in this work we use precision, to score initiation clauses, and recall, to score termination clauses, as in [15]. Moreover, OLED supports a clause pruning mechanism, that allows to remove low-quality clauses (e.g. clauses that have been generated from noisy examples) and a tie-breaking mechanism, that allows to randomly select between equally good specializations. We refer to [15] for more details on these features. In the general case, a theory learnt by OLED is a collection of clauses constructed with the online mechanism described above. Starting with an empty theory H = ∅, an initial clause is generated from the first positive example that streams-in, by constructing a bottom clause ⊥ from that example and adding the empty-bodied clause r = head(⊥) ← to theory H. From that point on, r is gradually specialized by the addition of literals from ⊥ to its body. New clauses are added to H whenever existing clauses in H become too specific to account for new incoming examples. When learning domain-specific axioms in the Event Calculus, the aforementioned generic theory construction strategy must be modified to account for the fact that initiation and termination clauses behave differently w.r.t. encountered TP , FP and FN complex event instances. A description of this behavior is illustrated in Figure 1(A). To handle this behavior, initiation and termination clauses are learnt separately, by two parallel processes, each of which runs the core OLED Algorithm. The input stream is forwarded to each of these processes simultaneously. Figure 1(B) presents the different actions that each learner takes whenever it encounters TP , FP and FN instances. Distributed Online Learning of Event Definitions 5 (A) TP Annotation holds Inferred holds No actions necessary FP Annotation not holds Incorrectly initiated by clause rinit OR Specialize rinit Inferred holds FN No termination clause “fires” Generate new termination clause Annotation holds No initiation OR clause “fires” Generate new initiation clause Inferred not holds Incorrectly treminated by clause rterm Specialize rterm (B) TP instance occurs FP instance occurs FN instance occurs InitiationLearner Reward all clauses that correctly initiate the complex event. Penalize all clauses that incorrectly initiate the complex event. Generate new initiation clause. TerminationLearner Reward all clauses that correctly allow the complex event to persist. Generate new termination clause. Penalize all clauses that incorrectly terminate the complex event. Fig. 1. (A) Different behaviors of initiation and termination clauses w.r.t. to occurrences of TP , FP and FN complex event instances. Dash-lined boxes explain what it means to encounter a TP , FP , FN complex event instance, in terms of (dis)agreement between the actual label of the instance and the one inferred by the theory. Round-cornered boxes describe the causes of FP, FN occurrences w.r.t. the different types of clause (initiation or termination). Regular boxes at the “leaves” of the tree-like structures indicate proper courses of action in order to eliminate FP/FN instances. (B) Actions taken by the two different processes that learn initiation and termination clauses in parallel, w.r.t. TP , FP , FN complex event occurrences. These actions are in accordance with the indicated actions in (A) (leaves of the trees). “Rewarding” a clause refers to increasing the TP count of the clause, while “penalizing” a clause refers to increasing its FP or FN counts. Penalizing clauses reduces their score, it therefore contributes to their specialization after a sufficient number of examples. 4 A Distributed Version of OLED We now proceed to the description of a distributed version of OLED. Evaluating a clause and its candidate specializations on incoming examples, may be performed in parallel, by distributing the clause evaluation workload across multiple processing nodes that operate on independent data partitions. When needed, e.g. when the Hoeffding test succeeds at some processing node, evaluation results from other nodes may be combined in order to make a more informed decision. We next describe this strategy in more detail. We assume that learning is performed by a set N of independent, possibly distributed processing nodes. Each node Ni ∈ N handles a separate stream Si of training examples. The nodes in N communicate by exchanging messages and they learn a theory H simultaneously, each node using its own training stream. The distributed version of OLED differs from the sequential algorithm in the following respects: New clause addition: When a node Ni generates a new clause r, it broadcasts r to all other nodes in N , via a AddNewClause(r ) message (see Table 3 for the main types of message of distributed OLED). Each node that receives such a message adds clause r 6 Katzouris et al. to its own theory and starts scoring r, and its candidate specializations, on its own data. As in the single-core version of OLED, a new clause r consists of an empty-bodied clause head (⊥r ) ←, where ⊥r is a bottom clause generated at Ni . Clause specialization: When a node Ni is about to specialize a clause r, i.e. when OLED’s Hoeffding test for clause r succeeds, locally at Ni , node Ni sends a SpecializeRequest(rid ) message to all other nodes, where rid is a unique identifier of clause r, common to all copies of r shared among processing nodes. Upon receiving such a message, each node uses rid to retrieve its own evaluation statistics for clause r and its candidate specializations, which are sent over to the requesting node Ni . These statistics consist of TP , FP , FN and E counts for clause r and its candidate specializations, where by E we denote the number of examples on which a clause has been evaluated so far. The received counts for clause r and its specializations are combined with node Ni ’s local counts as follows (we describe the process for clause r only, but it is similar for each one of its specializations). Denoting by TPrj , FPrj , FNrj and Erj the respective counts for clause r, received from node Nj ∈ N , j 6= i, the current node Ni updates r’s counts accordingly, by increasing r’s local counts with those received from other nodes.PFor instance, the new TP count for clause r in node Ni becomes TPrj . FPri , FNri and Eri counts are updated in a similar fashion. TPri = TPri + Nj ∈N Each processing node Ni ∈ N maintains a record, for each clause r in its theory and each one of r’s specializations, that contains the exact counts previously received for them, from each node Nj ∈ N , j 6= i. When node Ni receives a set of new TPrj , FPrj , FNrj and Erj counts for clause r from node Nj , j 6= i, the respective previous counts are subtracted from the new ones, to avoid over-scoring r with counts that have already been taken into account in previous updates. The same holds for r’s specializations. Once individual clause evaluation statistics are combined as described above, node Ni repeats the Hoeffding test for clause r to assess if the test still succeeds after the accumulated counts from all other nodes, for clause r and its specializations, have been taken into account. If it does, clause r is replaced in H, the current theory at node Ni , by its best-scoring specialization r0 that results from the Hoeffding test. Then node Ni sends out a Replace(rid , r 0 ) message to all other nodes, instructing them to also replace r in their own theories with r0 . If, on the other hand, the Hoeffding test fails at node Ni after the updated counts are taken into account, clause r is not specialized and all nodes continue evaluating their theories on new incoming examples from their training streams. Clause pruning: For a clause r to be pruned away, two conditions must hold: First, clause r must be unchanged (not specialized) for a sufficiently long period, which, in the single-core version of OLED, is set to the average number of examples, observed so far in the learning process, for which the Hoeffding test succeeds, i.e. the average value of n = O( 12 ln 1δ ) that has resulted in clause specializations so far. Second, from that point on where clause r remains unchanged, a sufficiently large number of examples must be seen, in order to use a Hoeffding test to infer that, with probability 1 − δ, the quality of clause r is below the pruning threshold. In the distributed version of OLED, each node uses the above heuristics to decide locally whether a clause r should be pruned. Once it has seen enough data from its Distributed Online Learning of Event Definitions 7 Message Conditions for meassage broadcast Actions upon message receipt AddNewClause(r ) Generation of clause r. Add r to local theory. SpecializeRequest(rid ) Clause with id rid is about to Reply to the sender by the local be specialized. TP , FP , FN , E counts for clause with id rid and for each of its candidate specializations. Replace(rid , r 0 ) Clause with id rid has been specialized to clause r0 . Replace clause with id rid by r0 in local theory. PruneRequest(rid ) Clause with id rid is about to be pruned. Reply to the sender by the local TP , FP , FN , E counts for clause with id rid , as well as the period for which r remains (locally) unchanged. Remove(rid ) Clause with id rid has been pruned. Remove clause with id rid from local theory. Table 3. The main messages exchanged between data processing nodes in distributed OLED. own stream to make that decision for clause r, it sends a PruneRequest(rid ) message to all other nodes. Each node that receives such a message sends back to the requesting node the necessary information (period for which clause r remains unchanged and TP , FP , FN and Er counts for clause r), which node Ni uses to re-assess whether clause r should be pruned, based on the global view of clause r, obtained by combining r’s separate evaluations from all processing nodes. If node Ni eventually decides to pruned clause r, it sends a Remove(rid ) to all other nodes, which instructs them to also remove clause r from their theories. Algorithm 1 illustrates learning in distributed OLED by displaying the functionality of each processing node. To ensure that all nodes have the same theory at each point during the learning process, processing nodes often block their execution. For instance, whenever a node Nj sends out a SpecializeRequest(rid ), it blocks untils it receives the necessary statistics for clause rid from all other nodes. Similarly, whenever a node Ni , i 6= j receives such a message, it replies by sending over to Nj the necessary statistics for clause rid and then blocks its execution, waiting for a “verdict” from Nj . A “verdict” may be a Replace(rid , r0 ) message, which instructs node Ni to replace clause rid by its specialization r0 , or, it may be a Proceed message (this type of message is omitted from Table 3), signifying the fact that the Hoeffding test for clause rid at node Nj failed, after accumulated counts from all other nodes were taken into account, and therefore node Ni may continue processing new examples without altering its current theory. A similar blocking behavior occurs during message passing for clause pruning, to ensure that all all nodes remove (or preserve) a clause in a synchronized fashion. While exchanging messages during learning, care must be taken to avoid deadlocks and race conditions. An example of such situations is the case where the Hoeffding test 8 Katzouris et al. Algorithm 1 OLEDNode(H, G, I, N 0 ) Input: H: A potentially empty hypothesis; G: A clause evaluation function; I: A stream of training interpretations; N 0 : Set of peer processing nodes. 1: H := ∅ 2: while true do 3: Let I be the next training interpretation 4: G-score each clause r ∈ H on I 5: if a new clause should be generated then 6: Generate a new clause r and add to H. 7: Send r to each node in N 0 . 8: for each clause r ∈ H do 9: if the Hoeffding test for r succeeds then 10: Request the counts for r, and all of r’s specializations, from all nodes in N 0 . 11: Add the received counts to the current ones and repeat the Hoeffding test. 12: if the Hoeffding test for r still succeeds then 13: Replace r in H with its best-scoring specialization. 14: Notify all nodes in N 0 to also replace r with its best-scoring specialization. 15: if r should be pruned then 16: Request the counts for r from all nodes in N 0 . 17: Add the received counts for r to the current ones. 18: if r still should be pruned then 19: Remove r from the current theory. 20: Notify all nodes in N 0 to also remove r from their theories. 21: return H for specializing a single clause r succeeds simultaneously at two different nodes Ni and Nj . In such a case, nodes Ni and Nj send a SpecializeRequest(rid ) message to each other (in addition to all other nodes), requesting each other’s counts for clause r. Subsequently, both nodes enter a “waiting state” as mentioned above, waiting to receive the requested counts in order to proceed with repeating the Hoeffding test. This results in a deadlock, since each node is waiting for the other node’s reply. A similar situation may occur with pruning. To avoid such problems, all communication between nodes regarding clause specialization and pruning is mediated by a separate node, whose sole role is to assign priorities in such cases, so that such deadlocks are avoided. When two or more nodes request to specialize or prune a clause (almost) simultaneously, the mediator node prioritizes one of them randomly, enqueueing the other nodes for proceeding at a later time. The enqueued nodes reply to the requests of the prioritized node. Once the prioritized node finishes, the next node from the queue is prioritized. In such cases, a node from the queue abandons its effort to specialize or prune a clause r, if r gets specialized or pruned by the previously prioritized node. To sum-up, all nodes in N share a copy of the same theory H at each point in learning. H is learnt in an online fashion, simultaneously from all nodes in N , each node handling its own training stream. As in the single-core version, initiation and termination clauses are learnt independently, by two separate groups of processes, each of which learns one type of clause and implements the distributed version of OLED described in this section. Distributed Online Learning of Event Definitions (A) (B) F1 -score Theory size 9 #cores Time (sec) Speedup #Msgs Msg size (KB) Meeting 1 2 4 8 46 17 15 14 – 2.7 3 3.2 0.794 0.802 0.798 0.800 28 32 32 34 – 34 52 88 – 97 122 182 Moving 1 2 4 8 73 34 30 28 – 2 2.4 2.6 0.731 0.729 0.731 0.730 21 21 23 23 – 41 64 108 – 102 188 218 Meeting 1 2 4 8 423 122 116 110 – 3.4 3.6 3.8 0.832 0.832 0.832 0.832 36 36 36 36 – 105 298 518 – 247 705 1527 Moving 1 2 4 8 514 238 225 221 – 2.1 2.2 2.3 0.758 0.758 0.758 0.758 21 21 21 21 – 97 265 482 – 218 607 1422 Table 4. (A) Experimental results from the CAVIAR dataset; (B) Experimental results from a dataset consisting of 10 copies of CAVIAR. 5 Experimental Evaluation We present an experimental evaluation of our approach on CAVIAR (described in Section 2), a benchmark dataset for activity recognition. CAVIAR contains 282,067 training interpretations with a mean size of 25 atoms each.OLED is implemented in the Scala programming language. It uses Clingo4 as its main reasoning component and Scala’s akka Actors library5 to model the behavior of a processing node (Algorithm 1) and implement message passing. The code and data are available online6 . All experiments were conducted on a Linux machine with a 3.6GHz processor (4 cores and 8 threads) and 16GB of RAM. The purpose of our experiments was to compare the distributed version of OLED with its monolithic counterpart. We performed learning with 1, 2, 4 and 8 processing cores for acquiring the definitions of two target complex events, related to two persons meeting each other or moving together. CAVIAR contains 6,272 interpretations in which moving occurs and 3,722 in which meeting occurs. For the experiments with the distributed version of OLED positive and negative interpretations for the target complex events were evenly distributed across different processing cores. The results were obtained by tenfold cross-validation and are presented in Table 4(A), in the form of averages for training time, F1 -score and theory size (total number of literals), as well 4 5 6 http://potassco.sourceforge.net/ http://akka.io/ https://github.com/nkatzz/OLED 10 Katzouris et al. as average exchanged message number and size. F1 -scores were obtained by microaveraging results from each fold. With respect to the predictive accuracy, multiple-core learning resulted in theories of slightly higher F1 -score for the meeting complex event, as compared to single-core learning. In the monolithic setting, OLED postpones the generation of new clauses, up to the point where existing clauses become too specific to cover new examples. During this time, positive examples which may result in good clauses (recall that OLED learns by “encoding” examples into bottom clauses), are “skipped”, i.e. they are not used for learning new clauses, since they are covered by existing ones. In contrast, the data distribution in the multi-core setting results in cases where interesting examples that would have been missed in the monolithic setting, are actually used for learning. This resulted in OLED learning slightly “richer” theories for the meeting complex event in the multi-core setting.A similar effect was not observed for the moving complex event, which has a simpler definition than meeting. Regarding training times, OLED achieves a signicant speed-up, by moving from monolithic learning to learning with two cores. This is achieved by exchanging very little information between the processing cores (see the last column of Table 4(A)). When additional cores are added, the speed-up is sub-linear, mainly due to the increased number of exchanged messages that result in blocking processing cores. To test distributed OLED further, we used a larger dataset obtained by sequentially appending to each other 10 copies of CAVIAR, “pushing forward” the time-stamps of the data in each copy. The experimental setting for the ×10 CAVIAR experiment was identical to the one described above for the ×1 CAVIAR experiment. The results are presented in Table 4(B). Training times in the ×10 CAVIAR experiment follow the same speed-up pattern observed in the ×1 experiment. In this set of experiments, the speed-up factor reaches 3.8, leading to highly reduced training times. Due to the repetition of the training data in the ×10 CAVIAR experiment, each fold of the tenfold cross-validation process converged to identical theories, regardless of the number of cores used. F1 -scores are therefore identical for all number of cores, and are also improved as compared to the ×1 CAVIAR experiment. In the latter experiment, good clauses were often constructed “too-late”, from examples that were encountered shortly before the data were exhausted (in which case OLED terminates). Such clauses may be discarded, since OLED uses a “warm-up” period parameter that controls a minimum number of examples on which a clause must be evaluated in order to be included in an output hypothesis. In contrast, in the ×10 CAVIAR experiment such problems were avoided, thanks to the increase in training data size. 6 Related Work An overview of existing approaches to learning theories in the Event Calculus with ILP may be found at [14,13] and a discussion on how OLED compares to such approaches may be found at [15,13]. In this section we mainly discuss distributed/parallel ILP algorithms, for which a substantial amount of work exists in the literature. A thorough review may be found in [8,22]. Parallel ILP algorithms exploit parallelism across three Distributed Online Learning of Event Definitions 11 main axes [8]: Searching through the hypothesis space in parallel (search parallelism); splitting the training data and learning from data subsets (data parallelism); and evaluating candidate clauses in parallel (evaluation/coverage parallelism). In [20] the authors present a a data-parallel version of a standard set-cover loop: Each processing node learns a fragment of the concept definition from a partition of the data, and then these fragments are exchanged between all nodes. Good-enough clauses are kept by all nodes. A cover removal step is subsequently implemented by each core and the set-cover loop continues. Overall, the approach in [20] learns much faster that a sequential algorithm, achieving super-linear speed-ups. A similar approach is proposed in [7], where the training examples are split across multiple nodes and searched in parallel, while the best rules from each node are “pipe-lined” to all other nodes. In [22] the authors use a MapReduce-based framework to parallelize the operation of a classical set-cover ILP algorithm towards both evaluation-parallelism and searchparallelism. In the former case, coverage tests of candidate clauses are performed in parallel, on disjoint partitions of the data. In the latter case, bottom clauses (which are generalized to acquire a hypothesis clause) are generated and searched in a concurrent fashion from more than one “seed” examples. The reducer then selects the best hypothesis clause that results from this process. A similar approach for parallel exploration of independent hypotheses has been proposed in [18], while similar approaches towards parallel coverage tests have been proposed in [11,6]. In [17], the approach of [22] was extended to a framework that is capable of self-regulating the workload of distributing learning costs across multiple nodes. A main difference of the work presented here from the aforementioned approaches to parallel ILP is that they all rely on iterative ILP algorithms (basically, a set-cover loop), and they all require several passes over the data to compute a hypothesis. In contrast, OLED is an online, single-pass algorithm. In relation to the latter, some work on streaming ILP exists. However, existing approaches are either oriented towards unsupervised tasks like frequent pattern discovery [19], or they rely on propositionalization techniques and off-the-self, online propositional learners [21]. 7 Conclusions and Future Work We presented a distributed version of a recently proposed algorithm for online learning of complex event definitions in the form of domain-specific axioms in the Event Calculus. We also presented an experimental evaluation of our approach on a benchmark dataset for activity recognition, which demonstrates that we can significantly reduce training times. As future work, we aim to evaluate our approach on larger datasets, in terms of in-situ, geographically distributed learning, as in the case of maritime monitoring. Also, we plan to remove the requirement that all processing nodes block their execution, while waiting for replies during message passing. Acknowledgments. This work was funded by the H2020 project DATACRON. 12 Katzouris et al. References 1. Alexander Artikis, Marek Sergot, and Georgios Paliouras. An event calculus for event recognition. Knowledge and Data Engineering, IEEE Transactions on, 27(4):895–908, 2015. 2. Hendrik Blockeel and Luc De Raedt. Top-down induction of first-order logical decision trees. Artificial intelligence, 101(1):285–297, 1998. 3. Hendrik Blockeel, Luc De Raedt, Nico Jacobs, and Bart Demoen. Scaling up inductive logic programming by learning from interpretations. Data Mining and Knowledge Discovery, 3(1):59–93, 1999. 4. Luc De Raedt. Logical and relational learning. Springer Science & Business Media, 2008. 5. Opher Etzion and Peter Niblett. Event processing in action. Manning Publications Co., 2010. 6. Andreas K Fidjeland, Wayne Luk, and Stephen H Muggleton. Customisable multi-processor acceleration of inductive logic programming. Latest Advances in Inductive Logic Programming, pages 123–141, 2014. 7. Nuno A. Fonseca, Fernando M. A. Silva, Vı́tor Santos Costa, and Rui Camacho. A pipelined data-parallel algorithm for ILP. In 2005 IEEE International Conference on Cluster Computing (CLUSTER 2005), September 26 - 30, 2005, Boston, Massachusetts, USA, pages 1–10, 2005. 8. Nuno A Fonseca, Ashwin Srinivasan, Fernando Silva, and Rui Camacho. Parallel ilp for distributed-memory architectures. Machine learning, 74(3):257–279, 2009. 9. Joao Gama. Knowledge discovery from data streams. CRC Press, 2010. 10. Martin Gebser, Roland Kaminski, Benjamin Kaufmann, and Torsten Schaub. Answer set solving in practice. Synthesis Lectures on Artificial Intelligence and Machine Learning, 6(3):1–238, 2012. 11. James H. Graham, C. David Page Jr., and Ahmed H. Kamal. Accelerating the drug design process through parallel inductive logic programming data mining. In 2nd IEEE Computer Society Bioinformatics Conference, CSB 2003, Stanford, CA, USA, August 11-14, 2003, pages 400–402, 2003. 12. Wassily Hoeffding. Probability inequalities for sums of bounded random variables. Journal of the American statistical association, 58(301):13–30, 1963. 13. Nikos Katzouris. Scalable relational learning for event recognition. PhD Thesis, University of Athens, 2017. 14. Nikos Katzouris, Alexander Artikis, and Georgios Paliouras. Incremental learning of event definitions with inductive logic programming. Machine Learning, 100(2-3):555–585, 2015. 15. Nikos Katzouris, Alexander Artikis, and Georgios Paliouras. Online learning of event definitions. TPLP, 16(5-6):817–833, 2016. 16. Robert Kowalski and Marek Sergot. A logic-based calculus of events. New Generation Computing, 4(1):67–95, 1986. 17. Hiroyuki Nishiyama and Hayato Ohwada. Yet another parallel hypothesis search for inverse entailment. In ILP, 2015. 18. Hayato Ohwada and Fumio Mizoguchi. Parallel execution for speeding up inductive logic programming systems. In International Conference on Discovery Science, pages 277–286. Springer, 1999. 19. Andreia Silva and Cláudia Antunes. Multi-relational pattern mining over data streams. Data Mining and Knowledge Discovery, 29(6):1783–1814, 2015. 20. David B Skillicorn and Yu Wang. Parallel and sequential algorithms for data mining using inductive logic. Knowledge and Information Systems, 3(4):405–421, 2001. 21. Ashwin Srinivasan and Michael Bain. Relational models with streaming ilp. In ILP, 2013. 22. Ashwin Srinivasan, Tanveer A Faruquie, and Sachindra Joshi. Data and task parallelism in ilp using mapreduce. Machine learning, 86(1):141–168, 2012.
2cs.AI
A Parameterized Strongly Polynomial Algorithm for Block Structured Integer Programs∗ Martin Koutecký1 , Asaf Levin1 , and Shmuel Onn1 1 Technion – Israel Institute of Technology, Haifa, Israel {koutecky,levinas,onn}@technion.ac.il arXiv:1802.05859v1 [cs.DS] 16 Feb 2018 Abstract The theory of n-fold integer programming has been recently emerging as an important tool in parameterized complexity. The input to an n-fold integer program (IP) consists of parameter A, dimension n, and numerical data of binary encoding length L. It was known for some time that such programs can be solved in polynomial time using O(ng(A) L) arithmetic operations where g is an exponential function of the parameter. In 2013 it was shown that it can be solved in fixed-parameter tractable time using O(f (A)n3 L) arithmetic operations for a single-exponential function f . This, and a faster algorithm for a special case of combinatorial n-fold IP, have led to several very recent breakthroughs in the parameterized complexity of scheduling, stringology, and computational social choice. In 2015 it was shown that it can be solved in strongly polynomial time using O(ng(A) ) arithmetic operations. Here we establish a result which subsumes all three of the above results by showing that n-fold IP can be solved in strongly polynomial fixed-parameter tractable time using O(f (A)n3 ) arithmetic operations. In fact, our results are much more general, briefly outlined as follows. There is a strongly polynomial algorithm for integer linear programming (ILP) whenever a so-called Graver-best oracle is realizable for it. Graver-best oracles for the large classes of multi-stage stochastic and tree-fold ILPs can be realized in fixed-parameter tractable time. Together with the previous oracle algorithm, this newly shows two large classes of ILP to be strongly polynomial; in contrast, only few classes of ILP were previously known to be strongly polynomial. We show that ILP is fixed-parameter tractable parameterized by the largest coefficient kAk∞ and the primal or dual treedepth of A, and that this parameterization cannot be relaxed, signifying substantial progress in understanding the parameterized complexity of ILP. 1998 ACM Subject Classification F.2.2 Nonnumerical Algorithms and Problems, G.1.6 Optimization Keywords and phrases integer programming, parameterized complexity, Graver basis, n-fold integer programming Digital Object Identifier 10.4230/LIPIcs.CVIT.2016.23 1 Introduction In this article we consider the general linear integer programming (ILP) problem in standard form, min {wx | Ax = b , l ≤ x ≤ u , x ∈ Zn } . ∗ (ILP) M. Koutecký supported by a postdoctoral fellowship at the Technion. A. Levin supported by a grant from the GIF, the German-Israeli Foundation for Scientific Research and Development (grant number I-1366-407.6/2016). S. Onn supported by the Dresner chair. © Martin Koutecký, Asaf Levin, and Shmuel Onn; licensed under Creative Commons License CC-BY 42nd Conference on Very Important Topics (CVIT 2016). Editors: John Q. Open and Joan R. Acces; Article No. 23; pp. 23:1–23:18 Leibniz International Proceedings in Informatics Schloss Dagstuhl – Leibniz-Zentrum für Informatik, Dagstuhl Publishing, Germany 2 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs with A an integer m × n matrix, b ∈ Zm , w ∈ Zn , l, u ∈ (Z ∪ {±∞})n . It is well known to be strongly NP-hard, which motivates the search for tractable special cases. The first important special case is ILP in fixed dimension. In the ’80s it was shown by Lenstra and Kannan [17, 21] that (ILP) can be solved in time nO(n) L, where L is the length of the binary encoding of the input. Secondly, it is known that if the matrix A is totally unimodular (all subdeterminants between −1 and 1), all vertices of the feasible region are integral and thus applying any polynomial algorithm for linear programming (LP) suffices. Later, Veselov and Chirkov [26] have shown that the more general class of bimodular ILP is also polynomial-time solvable. Other results exploit certain structural properties of A. These include the large classes of n-fold [13], tree-fold [4], 2-stage and multi-stage stochastic [3], and 4-block n-fold [12] ILPs, as well as algorithms for ILPs with bounded treewidth [11], treedepth [10] and fracture number [7] of certain graphs related to the matrix A. A fundamental question regarding problems involving large numbers is whether there exists an algorithm whose number of arithmetic operations does not depend on the length of the numbers involved; if this number is polynomial, this is a strongly polynomial algorithm [25]. For example, the ellipsoid method or the interior-point method which solve LP take time which does depend on the encoding length, and the existence of a strongly polynomial algorithm for LP remains a major open problem. So far, the only strongly polynomial ILP algorithms we are aware of exist for totally unimodular ILP [14], bimodular ILP [2], so-called binet ILP [1], and n-fold IP with constant block dimensions [6]. All remaining results, such as Lenstra’s famous algorithm or the fixed-parameter tractable algorithm for n-fold IP which has recently led to several breakthroughs [4, 16, 18, 19], are not strongly polynomial. 1.1 Our Contributions To clearly state our results we introduce the following terminology. The input to a problem will be partitioned into three parts (α, β, γ), where α is the parametric input, β is the arithmetic input, and γ is the numeric input. A strongly fixed-parameter tractable (FPT) algorithm for the problem is one that solves it using f (α)poly(β) arithmetic operations and g(α)poly(β, γ) time, where f, g are some computable functions. If such an algorithm exists, we say that the problem is strongly fixed-parameter tractable (FPT) parameterized by α. Thus, such an algorithm both demonstrates that the problem is FPT parameterized by α because it runs in FPT time g(α)poly(β, γ), and provides a strongly polynomial algorithm for each fixed α. Having multiple parameters α1 , . . . , αk simultaneously is understood as taking the aggregate parameter α = α1 + · · · + αk . If the algorithm involves oracles then the oracle queries are also counted as arithmetic operations and the answers to oracle queries should be polynomial in (β, γ). Each part of the input may have several entities, which may be presented in unary or binary, where hei denotes the encoding length of an entity e presented in binary. For the parametric input the distinction between unary and binary is irrelevant. ILP abounds in natural parameters: the dimension n, number of inequalities m, largest coefficient kAk∞ , largest right-hand side kbk∞ , various structural parameters of A, etc. Here, we are interested in algorithms which are both strongly polynomial and FPT. Recently it was shown that, if we have access to the so-called Graver basis of A, the problem (ILP) is polynomial time solvable even for various nonlinear objective functions [5, 22]. We show that all of these results can be extended to be strongly polynomial with only hAi as the arithmetic input. I Theorem 1. The problem (ILP) with arithmetic input hAi and numeric input hw, b, l, ui, endowed with a Graver-best oracle for A, is solvable by a strongly polynomial oracle algorithm. The existence of Graver-best oracles is thus of prime interest. We show such oracles for the wide classes of multi-stage stochastic and tree-fold ILPs; for precise definitions of these M. Koutecký, A. Levin, and S. Onn 3 classes cf. Section 3.1.2. See Table 1 for a summary of improvements over the current state of the art. I Theorem 2. Multi-stage stochastic ILP with blocks B1 , . . . , Bτ , Bi ∈ Zl×ni , is strongly FPT parameterized by l + n1 + · · · + nτ and kAk∞ . I Theorem 3. Tree-fold ILP with blocks A1 , . . . , Aτ , Ai ∈ Zri ×t , is strongly FPT parameterized by r1 + · · · + rτ and kAk∞ . This improves on the algorithm for tree-fold ILP [4] not only by making it strongly FPT, but also by leaving the block length t out of the parameter. Similarly, the following algorithm for the special case of n-fold ILP greatly improves both on the previous results of Hemmecke et al. [13] and Knop et al. [18] and is the currently fastest algorithm for this problem: I Theorem 4. n-fold ILP with blocks A1 ∈ Zr×t and A2 ∈ Zs×t can be solved in time 2 2 aO(r s+rs ) (nt)3 +L(hAi), where L(hAi) is the runtime of a strongly polynomial LP algorithm. Next, we turn our attention to structural parameters of the constraint matrix A. We focus on two graphs which can be associated with A: the primal graph GP (A), which has a vertex for each column and two vertices are connected if there exists a row such that both columns are non-zero, and, the dual graph GD (A) = GP (A| ), which is the above with rows and columns swapped. Two standard parameters of structural sparsity are the treewidth (measuring the “tree-likeness” of a graph) and the more restrictive treedepth (measuring its “star-likeness”). We denote the treewidth of GP (A) and GD (A) by twP (A) and twD (A); for treedepth we have tdP (A) and tdD (A). Note that bounded treedepth implies bounded treewidth but not vice versa. We show that ILP parameterized by tdP (A) + kAk∞ and tdD (A) + kAk∞ can be reduced to the previously mentioned classes, respectively, implying (ILP) with these parameters is strongly FPT. I Theorem 5. (ILP) is strongly FPT parameterized by tdP (A) and kAk∞ . This improves in two ways upon the result of Ganian and Ordyniak [10] who show that (ILP) with w ≡ 0 (i.e. deciding the feasibility) is FPT parameterized by tdP (A) + kA, bk∞ [10]. First, we use the smaller parameter kAk∞ instead of kA, bk∞ , and second, we solve not only the feasibility but also the optimization problem. An analogous results holds for the parameter tdD (A), for which previously nothing was known at all. I Theorem 6. (ILP) is strongly FPT parameterized by tdD (A) and kAk∞ . We emphasize that the parameterizations cannot be relaxed neither from treedepth to treewidth, nor by removing the parameter kAk∞ : (ILP) is NP-hard already on instances with twP (A) = 3 and kAk∞ = 2 [10, Thm 12], and it is strongly W[1]-hard parameterized by tdP (A) alone [10, Thm 11]; the fact that a problem is W[1]-hard is strong evidence that it is not FPT. Similarly, deciding feasibility is NP-hard on instances with twD (A) = 3 and kAk∞ = 2 (Lemma 32) and strongly W[1]-hard parameterized by tdD (A) alone [19, Thm 5]. 1.2 Interpretation of Results We believe our approach also leads to several novel insights. First, we make it clear that the central question is finding Graver-best oracles; provided these oracles, Theorem 1 shows that tasks such as optimization and finding initial solutions can be handled under very mild assumptions. Even though we show these tasks are routine, they have been reimplemented repeatedly [4, 12, 13, 18]. 4 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs Type of instance Previous best run time n-fold ILP aO(rst+st ) n3 L [13] Our result n-fold ILP tO(r) (ar)r n3 L if A2 = (1 1 · · · 1) [18] n-fold ILP nf1 (a,r,s,t) [6] tree-fold ILP ftf0 (a, n1 , . . . , nτ , t)n3 L [4] ftf (a, n1 , . . . , nτ )(nt)3 + L(hAi) Thm 3 Multi-stage stochastic ILP fmss (a, n1 , . . . , nτ , l)n3 L [3] fmss (a, n1 , . . . , nτ , l)n3 + L(hAi) Thm 2 Bounded dual treedepth Open whether fixed-parameter tractable Bounded primal treedepth fP 0 (a, kbk∞ , tdP (A))nL [10] 2 2 aO(r 2 s+sr 2 ) (nt)3 + L(hAi) Thm 4 fD (a, tdD (A)(nt)3 + L(hAi) Thm 6 fP (a, tdP (A))n3 + L(hAi) Thm 5 Table 1 Run time improvements implied by this paper. We denote by L the binary length of the numeric input b, l, u, w, i.e., L = hb, l, u, wi, and consider hAi to be part of the arithmetic input. We denote by a = max{2, kAk∞ },r, s, t are relevant block dimensions (cf. Section 3.1), and L(hAi) is the runtime of a strongly polynomial LP algorithm [25]. Second, we show that the special classes of highly uniform block structured ILPs, namely multi-stage stochastic and tree-fold ILPs, are in some sense universal for all ILPs of bounded primal or dual treedepth, respectively. Specifically, we show that any ILP with bounded primal or dual treedepth can be embedded in an equivalent multi-stage stochastic or tree-fold ILP, respectively (Lemmas 29 and 30). Third, we show that, besides bounded primal or dual treedepth, the crucial property for efficiency is the existence of augmenting steps with bounded `∞ - or `1 -norms, respectively (Lemmas 21 and 24). This suggests that for ILPs whose primal or dual graph is somehow “sparse” and “shallow”, finding augmenting steps of bounded `∞ - or `1 -norm might be both sufficient for reaching the optimum and computationally efficient. 1.3 Related Work We have already covered all relevant work regarding strongly polynomial algorithms for ILP. Let us focus on structural parameterizations. It follows from Freuder’s algorithm [9] and was reproven by Jansen and Kratsch [15] that (ILP) is FPT parameterized by twP (A) and the largest domain ku − lk∞ . Regarding the dual graph GD (A), the parameters tdD (A) and twD (A) were only recently considered by Ganian et al. [11]. They show that even deciding feasibility of (ILP) is NP-hard on instances with twI (A) = 3 (twI (A) denotes the treewidth of the incidence graph; twI (A) ≤ twD (A) + 1 always holds) and kAk∞ = 2 [11, Theorem 12]. Furthermore, they show that (ILP) is FPT parameterized by twI (A) and parameter Γ, which is an upper bound on any prefix sum of Ax for any feasible solution x. Dvořák et al [7] introduce the parameter fracture number; having a bounded variable fracture number pV (A) implies that deleting a few columns of A breaks it into independent blocks of small size; similarly for constraint fracture number pC (A) and deleting a few rows. Because bounded pV (A) implies bounded tdP (A) and bounded pC (A) implies bounded tdD (A), our results generalize theirs. The remaining case of mixed fracture number p(A), where deleting both rows and columns is allowed, reduces to the 4-block n-fold ILP problem, which is not known to be either FPT or W[1]-hard. Because bounded p(A) implies bounded tdI (A), ILP parameterized by tdI (A) + kAk∞ is at least as hard as 4-block n-fold ILP, highlighting its status as an important open problem. Organization. The paper contains three main parts. In Section 2, we provide the proof of Theorem 1, showing the existence of a strongly polynomial algorithm whenever a Graverbest oracle is provided. Then, in Section 3, we provide Graver-best oracles for multi-stage stochastic and tree-fold ILPs and discuss n-fold ILP, and prove Theorems 2, 3 and 4. Finally, M. Koutecký, A. Levin, and S. Onn 5 in Section 4 we show how to embed any instance of bounded primal or dual treedepth into a multi-stage stochastic or tree-fold ILP without increasing the relevant parameters, proving Theorems 5 and 6. 2 2.1 The Graver-best Oracle Algorithm Preliminaries For positive integers m, n, m ≤ n, we set [m, n] = {m, . . . , n} and [n] = [1, n]. We write vectors in boldface (e.g., x, y) and their entries in normal font (e.g., the i-th entry of x is xi ). If A is a matrix, Ar denotes its r-th column. For an integer a ∈ Z, we denote by hai = 1 + log2 a the binary encoding length of a; we extend this notation to vectors, matrices P and tuples of these objects. For example, hA, bi = hAi + hbi, and hAi = i,j haij i. For a graph G we denote by V (G) its set of vertices. Graver bases and augmentation. Let us now introduce Graver bases and discuss how they are used for optimization. We define a partial order v on Rn as follows: for x, y ∈ Rn we write x v y and say that x is conformal to y if xi yi ≥ 0 (that is, x and y lie in the same orthant) and |xi | ≤ |yi | for i ∈ [n]. It is well known that every subset of Zn has finitely many v-minimal elements. I Definition 7 (Graver basis). The Graver basis of an integer m × n matrix A is the finite set G(A) ⊂ Zn of v-minimal elements in {x ∈ Zn : Ax = 0, x 6= 0}. We say that x is feasible for (ILP) if Ax = b and l ≤ x ≤ u. Let x be a feasible solution for (ILP). We call g a feasible step if x + g is feasible for (ILP). Further, call a feasible step g augmenting if w(x + g) < w(x). An augmenting step g and a step length α ∈ Z form an x-feasible step pair with respect to a feasible solution x if l ≤ x + αg ≤ u. An augmenting step h is a Graver-best step for x if w(x + h) ≤ w(x + λg) for all x-feasible step pairs (g, λ) ∈ G(A) × Z. The Graver-best augmentation procedure for (ILP) with a given feasible solution x0 works as follows: 1. If there is no Graver-best step for x0 , return it as optimal. 2. If a Graver-best step h for x0 exists, set x0 := x0 + h and go to 1. I Proposition 8 ([22, Lemma 3.10]). Given a feasible solution x0 for (ILP), the Graver-best augmentation procedure finds an optimum of (ILP) in at most (2n − 2) log F steps, where F = wx0 − wx∗ and x∗ is any minimizer of wx. I Definition 9 (Graver-best oracle). A Graver-best oracle for an integer matrix A is one that, queried on w, b, l, u and x feasible to (ILP), returns a Graver-best step h for x. 2.2 The Algorithm It follows from Proposition 8 that given a Graver-best oracle, problem (ILP) can be solved in time which is polynomial in the binary encoding length hA, w, b, l, ui of the input. We now show that, in fact, given such an oracle, the problem admits a strongly polynomial algorithm. In the next theorem the input has only arithmetic and numeric parts and no parametric part. I Theorem 1. The problem (ILP) with arithmetic input hAi and numeric input hw, b, l, ui, endowed with a Graver-best oracle for A, is solvable by a strongly polynomial oracle algorithm. I Remark. The partition of the input to the arithmetic input hAi and the numeric input hw, b, l, ui is the same as in the classical results for linear programming [8, 25]. Proof. The algorithm which demonstrates the theorem consists of several steps as follows. 6 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs Step 1: Reducing b, l, u. Apply the strongly polynomial algorithm of Tardos [25] to the linear programming relaxation min {wy | y ∈ Rn , Ay = b, l ≤ y ≤ u}; the algorithm performs L(hAi) = poly(hAi) arithmetic operations. If the relaxation is infeasible then so is (ILP) and we are done. If it is unbounded then (ILP) is either infeasible or unbounded too, and in this case we set w := 0 so that all solutions are optimal, and we proceed as below and terminate at the end of step 3. Suppose then that we obtain an optimal solution y∗ ∈ Rn to the relaxation, with round down by∗ c ∈ Zn . Let a := max{2, kAk∞ }. Let C(A) ⊆ G(A) be the set of circuits of A, which are those c ∈ G(A) with support which is a circuit of the n linear matroid of A. Let c∞ := maxc∈C(A) kck∞ . We have c∞ ≤ n 2 an [22, Lemma 3.18]. We now use the proximity results of [12, 14] which assert that either (ILP) is infeasible or n it has an optimal solution x∗ with kx∗ − y∗ k∞ ≤ nc∞ and hence kx∗ − by∗ ck∞ ≤ n 2 +1 an + 1. Thus, making the variable transformation x = z + by∗ c, problem (ILP) reduces to following,  n min w(z + by∗ c) | z ∈ Zn , A(z + by∗ c) = b , l ≤ z + by∗ c ≤ u , kzk∞ ≤ n 2 +1 an + 1 , which is equivalent to the program  min wz | z ∈ Zn , Az = b̄ , l̄ ≤ z ≤ ū (1) where n n b̄ := b−Aby∗ c, ¯li := max{li −byi∗ c, −(n 2 +1 an +1)}, ūi := min{ui −byi∗ c, n 2 +1 an +1} . If some ¯li > ūi then (1) is infeasible and hence so is (ILP), so we may assume that n n −(n 2 +1 an + 1) ≤ ¯li ≤ ūi ≤ n 2 +1 an + 1, for all i . n This implies that if z is any feasible point in (1) then kAzk∞ ≤ na(n 2 +1 an + 1) and so n we may assume that kb̄k∞ ≤ na(n 2 +1 an + 1) else there is no feasible solution. So we have kb̄k∞ , kl̄k∞ , kūk∞ ≤ 2O(n log n) aO(n) and hence hb̄, l̄, ūi is polynomial in hAi . Step 2: Solving the system of equations. We first search for an integer solution to the system of equations Az = b̄. This can be done by computing the Hermite normal form of A, see [24], using a number of arithmetic operations polynomial in hAi and time polynomial in hA, b̄i which is polynomial in hAi, and hence strongly polynomially in our original input. Then either we conclude that there is no integer solution to Az = b̄ and hence (1) is infeasible, or we find a solution z ∈ Zn with hzi polynomially bounded in hA, b̄i and hence also in hAi. Step 3: Finding a feasible point. Define relaxed bounds by ˆli := min{¯li , zi }, ûi := max{ūi , zi }, i ∈ [n] . Now for i ∈ [n] iterate the following. If ¯li ≤ zi ≤ ūi then simply increment i and repeat. If zi < ¯li (and hence ˆli = zi and ûi = ūi ) then consider the following auxiliary integer program, max n o xi | x ∈ Zn , Ax = b̄ , l̂ ≤ x ≤ û . (2) Starting from the point z feasible in (2), and using the Graver-best oracle for A, we can solve program (2) using Proposition 8 in polynomial time and in a number of arithmetic operations and oracle queries which is polynomial in n and log F (recall F = zi∗ − zi for some minimizer zi∗ ), which is bounded by log(ûi − ˆli ) = log(ūi − zi ), thus polynomial in hAi. Let x be an optimal solution of (2). If xi < ¯li then (1) is infeasible and we are done. Otherwise (in which case ¯li ≤ xi ≤ ūi ) we update ˆli := ¯li and z := x, increment i and repeat. The last case zi > ūi is treated similarly where in (2) we minimize rather than maximize xi . Thus, strongly polynomially we either conclude at some iteration i that program (1) is infeasible or complete all iterations and obtain l̂ = l̄, û = ū, and a point z feasible in (1). M. Koutecký, A. Levin, and S. Onn 7 n Step 4: Reducing w. Let N := 2n(n 2 +1 an + 1) + 1. Now apply the strongly polynomial algorithm of Frank and Tardos [8], which on arithmetic input n, hN i and numeric input 3 2 hwi, outputs w̄ ∈ Zn with kw̄k∞ ≤ 2O(n ) N O(n ) such that sign(wx) = sign(w̄x) for all x ∈ Zn with kxk1 < N . Since hN i = O(log N ) = O(n log n + n log a) is polynomial in hAi, this algorithm is also strongly polynomial in our original input. Now, for every two points n x, z feasible in (1) we have kx − zk1 < 2n(n 2 +1 an + 1) + 1 = N , so that for any two such points we have wx ≤ wz if and only if w̄x ≤ w̄z, and therefore we can replace (1) by the equivalent program  min w̄z : z ∈ Zn , Az = b̄ , l̄ ≤ z ≤ ū , (3) where kw̄k∞ = 2O(n 3 log n) O(n3 ) a and hence hw̄, b̄, l̄, ūi is polynomial in hAi . Step 5: Finding an optimal solution. Starting from the point z which is feasible in (3), and using the Graver-best oracle for A, we can solve program (3) using again Proposition 8 in polynomial time and in a number of arithmetic operations and oracle queries which is  polynomial in n and in log F , which is bounded by log nkw̄k∞ kū − l̄k∞ , which is polynomial in hAi, and hence strongly polynomially. J I Remark. In fact, the reduced objective w̄ in step 4 need not be constructed: already its existence implies that (1) is solved in the same number of iterations as (3). 3 Multi-stage Stochastic and Tree-fold ILP In this section we prove Theorems 2 and 3. We first formalize a common construction for a Graver-best oracle: one constructs a set of relevant step lenghts Λ and then for each λ ∈ Λ finds a λ-Graver-best step. A step with the best improvement among these is then guaranteed to be a Graver-best step. Thus, we reduce our task to constructing a Λ-Graver-best oracle. Both algorithms for multi-stage stochastic ILP and tree-fold ILP follow the same pattern: 1. show that all elements of G(A) have bounded norms (`∞ and `1 , respectively), 2. show that A has bounded treewidth (primal and dual, respectively), 3. apply existing algorithms for (ILP) which are FPT parameterized by kAk∞ , max kxk∞ and max kxk1 , and twP (A) and twD (A), respectively. 3.1 3.1.1 Preliminaries Relevant Step Lengths We say that h ∈ {x ∈ Zn | Ax = 0} is a λ-Graver-best step if λh is a feasible step and λwh ≤ λwg for any g ∈ G(A) such that λg is a feasible step. We denote by g1 (A) = maxg∈G(A) kgk1 and g∞ (A) = maxg∈G(A) kgk∞ . The following lemma states that provided a bound on g∞ (A), in order to find a Graver-best step, it is sufficient to find a λ-Graver-best step for all λ ∈ Λ for some not too large set Λ. I Definition 10 (Graver-best step-lengths). Let x be a feasible solution to (ILP). We say that λ ∈ N is a Graver-best step-length for x if there exists g ∈ G(A) with x + λg feasible, such that ∀λ0 ∈ N and ∀g0 ∈ G(A), x + λ0 g0 is either infeasible or w(x + λg) ≤ w(x + λ0 g0 ). We denote by Λ(x) ⊆ N the set of Graver-best step-lengths for x. I Lemma 11 (Polynomial Λ ⊇ Λ(x)). Let x be a feasible solution to (ILP), let M ∈ N be such that g∞ (A) ≤ M . Then it is possible to construct in time O(M n) a set Λ ⊆ N of size at most 2M n such that Λ(x) ⊆ Λ. 8 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs Proof. Observe that if λg is a Graver-best step for x, it is tight in at least one coordinate i ∈ [n], meaning that li ≤ xi + λgi ≤ ui but either xi + (λ + 1)gi < li or xi + (λ + 1)gi > ui . Thus, for every i ∈ [n] and every µ ∈ [−M, M ], µ = 6 0, add to Λ the unique number λ ∈ N for which li ≤ xi + λµ ≤ ui holds but li ≤ xi + (λ + 1)µ ≤ ui does not hold. J With this Λ at hand, in order to realize a Graver-best oracle, it suffices to realize an oracle which finds a λ-Graver-best step for a given λ: I Definition 12 (Λ-Graver-best oracle). A Λ-Graver-best oracle for an integer matrix A is one that, queried on w, b, l, u, x feasible to (ILP), and an integer λ ∈ N, returns a λ-Graver-best step h for x. I Lemma 13 (Λ-Graver-best oracle ⇒ Graver-best oracle). Let A be an integer matrix and let M ∈ N satisfy g∞ (A) ≤ M . Then a Graver-best oracle for A can be realized with 2M n calls to a Λ-Graver-best oracle for A. Proof. Construct the set Λ by Lemma 11 and for each λ ∈ Λ, call the Λ-Graver-best oracle and denote its output hλ . Then, return hλ which minimizes wλhλ over all λ ∈ Λ. By Lemma 11 it is guaranteed to be Graver-best step, and since |Λ| ≤ 2M n we have made at most this many calls of the Λ-Graver-best oracle. J 3.1.2 Multi-stage Stochastic and Tree-fold Matrices Let the height of a rooted tree or forest be the maximum root-to-leaf distance in it (i.e., the number of edges along the root-to-leaf path). For a vertex v ∈ T , let Tv be the subtree of T rooted in v and let `(v) denote the number of leaves of T contained in Tv . In the following we let T be a rooted tree of height τ − 1 ∈ N whose all leaves are at depth τ − 1, that is, the length of every root-leaf path is exactly τ − 1. Let B1 , B2 , . . . , Bτ be a sequence of integer matrices with each Bs having l ∈ N rows and ns columns, where ns ∈ N, ns ≥ 1. We shall define a multi-stage stochastic matrix T P (B1 , . . . , Bτ ) inductively; the superscript P refers to the fact that T P (B1 , . . . , Bτ ) has bounded primal treedepth tdP , as we will later see. For a leaf v ∈ T , TvP (Bτ ) := Bτ . Let d ∈ N, 0 ≤ d ≤ τ − 2, and assume that for all vertices v ∈ T at depth d + 1, matrices TvP (Bτ −d , . . . , Bτ ) have been defined. For s ∈ N, 1 ≤ s ≤ τ , we set TvP (B[s:τ ] ) = TvP (Bs , . . . , Bτ ). Let v ∈ T be a vertex at depth d with δ children v1 , . . . , vδ . We set   Bτ −d−1,`(v1 ) TvP1 (B[τ −d:τ ] ) · · · 0   .. .. .. .. TvP (B[τ −d−1:τ ] ) :=   . . . . Bτ −d−1,`(vδ ) Bs where, for N ∈ N, Bs,N = ··· 0 TvPδ (B[τ −d:τ ] ) ! .. . consists of N copies of the matrix Bs . Bs The structure of a multi-stage stochastic matrix makes it natural to partition any solution of a multi-stage stochastic ILP into bricks. Bricks are defined inductively: for TvP (Bτ ) there is only one brick consisting of all coordinates; for TvP (B[s:τ ] ) the set of bricks is composed of all bricks for all descendants of v, plus the first ns coordinates form an additional brick. I Example 14. For τ = 3 and T with root r of degree 2 and its  children u and  v of  B2 B3 P 2 B3 B2 B3 degree 2 and 3, we have TuP (B2 , B3 ) = B , and B2 B3 , Tv (B2 , B3 ) = B2 B3 B B B  1 P T (B1 , B2 , B2 ) = TrP (B1 , B2 , B2 ) 2 B B2 1 =  B1 B1 B1 3 B3 B2 B3 B2 B3 B2 B3 , with a total of 8 bricks. M. Koutecký, A. Levin, and S. Onn 9 Tree-fold matrices are essentially transposes of multi-stage stochastic ILP matrices. Let T be as before and A1 , . . . , Aτ be a sequence of integer matrices with each As ∈ Zrs ×t , where t ∈ N, rs ∈ N, rs ≥ 1. We shall define T D (A1 , . . . , Aτ ) inductively; the superscript D refers to the fact that T D (A1 , . . . , Aτ ) has bounded dual treedepth. The inductive definition is the same as before except that, for a vertex v ∈ T at depth d with δ children v1 , . . . , vδ , we set   Aτ −d−1,`(v1 ) Aτ −d−1,`(v2 ) · · · Aτ −d−1,`(vδ )  TvD (A[τ −d:τ ] )  0 ··· 0  1  D   0 Tv2 (A[τ −d:τ ] ) · · · 0 TvD (A[τ −d−1:τ ] ) :=     .. .. .. ..   . . . . 0 0 ··· TvDδ (A[τ −d:τ ] ) where, for N ∈ N, As,N = (As · · · As ) consists of N copies of the matrix As . A solution x of a tree-fold ILP is partitioned into bricks (x1 , . . . , xn ) where n is the number of leaves of T , and each xi is a t-dimensional vector. 3.1.3 Structural Parameters We consider two graph parameters, namely treewidth tw(G) and treedepth td(G). I Definition 15 (Treewidth). A tree decomposition of a graph G = (V, E) is a pair (T, B), where T is a tree and B is a mapping B : V (T ) → 2V satisfying for any uv ∈ E, there exists a ∈ V (T ) such that u, v ∈ B(a), if v ∈ B(a) and v ∈ B(b), then v ∈ B(c) for all c on the path from a to b in T . We use the convention that the vertices of the tree are called nodes and the sets B(a) are called bags. The treewidth tw((T, B)) of a tree decomposition (T, B) is the size of the largest bag of (T, B) minus one. The treewidth tw(G) of a graph G is the minimum treewidth over all possible tree decompositions of G. I Definition 16 (Treedepth). The closure cl(F ) of a rooted forest F is the graph obtained from F by making every vertex adjacent to all of its ancestors. The treedepth td(G) of a graph G is one more than the minimum height of a forest F such that G ⊆ cl(F ). It is known that tw(G) ≤ td(G). The treedepth td(G) of a graph G with a witness forest F can be computed in time ftd (td(G)) · |V (G)| for some computable function ftd [23]. I Definition 17 (Primal and dual graph). Given a matrix A ∈ Zm×n , its primal graph GP (A) = (V, E) is defined as V = [n] and E = {{i, j} ∈ [n] 2 | ∃k ∈ [m] : Ak,i , Ak,j 6= 0}. In other words, its vertices are the columns of A and two vertices are connected if there is a row with non-zero entries at the corresponding columns. The dual graph of A is defined as GD (A) = GP (A| ), that is, the primal graph of the transpose of A. Graphs of A. Besides GP (A) and GD (A), also the incidence graph is studied. The incidence graph of A GI (A) = (VI , EI ) is defined as VI = {vi | i ∈ [n]} ∪ {cj | j ∈ [m]} and EI = {{vi , cj } | Ai,j 6= 0, i ∈ [n], j ∈ [m]} To gain some intuition for how the primal, dual and incidence graphs are related, consider the following. For a graph G let G2 denote the square of G which is obtained from G by adding an edge between all vertices in distance 2. For a subset of vertices W ⊆ V (G), we denote by G[W ] the subgraph of G induced by W . It is easy to see that GP (A) = GI (A)2 [{vi | i ∈ [n]}] and GD (A) = GI (A)2 [{cj | j ∈ [m]}]. I Definition 18 (Matrix treewidth). Given a matrix A, its primal treewidth twP (A) is defined as the treewidth of its primal graph, i.e., tw(GP (A)), and its dual treewidth twD (A) is tw(GD (A)). Similarly, we define the primal and dual treedepth as tdP (A) = td(GP (A)) and tdD (A) = td(GD (A)), respectively. 10 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs We have the following similar bounds which will be useful later. I Lemma 19 (Kolaitis and Vardi [20]). twI (A) ≤ twP (A) + 1 and twI (A) ≤ twD (A) + 1. Proof. Construct a tree decomposition T 0 of GI (A) from an optimal tree decomposition T of GP (A) as follows. Consider a row ai of A: its non-zeros correspond to a clique of columns in GP (A), so there must exist a bag of T containing all of them; now add the vertex corresponding to ai to this bag. Repeating this for all rows and possibly copying bags obtains T 0 of width at most one larger than T . A similar argument applies for GD (A), exchanging rows for columns and vice-versa. J I Lemma 20. For A ∈ Zm×n , we have tdI (A) ≤ tdP (A) + 1 and tdI (A) ≤ tdD (A) + 1. Proof. We shall prove tdI (A) ≤ tdP (A) + 1; the other claim follows by noting that GI (A| ) = GI (A). Let F be a forest of height tdP (A) − 1 such that GP (A) ⊆ cl(F ). Every root-leaf path p in F corresponds to a subset Sp ⊆ [n] of columns of A. Let Rp ⊆ [m] be the subset of rows of A whose non-zero entries are contained in Sp . Obtain F 0 from F by, for every root-leaf path p, appending a leaf to the last vertex of p for every r ∈ Rp . Let us argue that GI (A) ⊆ cl(F 0 ). Every non-zero row r belongs to some Rp and thus has a corresponding leaf. Moreover, r only has edges in GI (A) connecting it to vertices from Sp , and all such edges belong to cl(F 0 ). Finally, the depth of F 0 is clearly 1 plus the height of F as we have only added one more layer of leaves. J 3.2 Multi-stage Stochastic ILP is strongly FPT To prove Theorem 2, we need two ingredients: a bound on g∞ (A), and an algorithm for (ILP) with bounded twP (A) and max kxk∞ . I Lemma 21 (Multi-stage stochastic ⇒ bounded g∞ (A)). Let A = T P (B1 , . . . , Bτ ). Then g∞ (A) ≤ fmss-norm (a, n1 , . . . , nτ , l) for some computable function fmss-norm . Proof. Aschenbrenner and Hemmecke [3] show that each brick of g comes from a union Sτ k=1 Hk,∞ which is independent of n and finite [3, Proposition 8.11]. Thus, kgk∞ ≤ fmss-norm (a, n1 , . . . , nτ , l) for some function fmss-norm which is computable by arguments in [3, Section 9]. J I Lemma 22. Let X ∈ N. Problem (ILP) with the additional constraint kxk∞ ≤ X can be solved in time (X + 1)O(twP (A)) · (n + m). Proof. The algorithm follows from Freuder’s algorithm: O(tw (A)) I Proposition 23 (Freuder [9, 15]). (ILP) can be solved in time ku − lk∞ P · n. We apply it to (ILP) with modified bounds l̃ and ũ defined by ˜li = max{li , −X} and ũi = min{ui , X}. It is clear that kũ − l̃k∞ ≤ X and since A and thus twP (A) stay the same, the claim follows. J Proof of Theorem 2. Let A = T P (B1 , . . . , Bτ ) be a multi-stage stochastic matrix. By Lemma 21, g∞ (A) is bounded by M = fmss-norm (a, n1 , . . . , nτ , l). We show how to construct a Λ-Graver-best oracle. Given an integer λ ∈ N, use Lemma 22 to solve min{λwh | Ah = 0, l ≤ x + λh ≤ u, khk∞ ≤ M } . This returns a λ-Graver-best step, because any optimal solution satisfies λh ≤ λg for all g ∈ G(A). Using a simple induction and the inductive construction of A, one gets that A has twP (A) ≤ tdP (A) ≤ n1 + · · · + nτ + 1 and thus the oracle is realized in FPT time. Lemma 13 then yields a Graver-best oracle, which, combined with Theorem 1, finishes the proof. J M. Koutecký, A. Levin, and S. Onn 3.3 11 Tree-fold ILP is strongly FPT As before, to prove Theorem 3, we need two ingredients: a bound on g1 (A), and an algorithm for (ILP) with bounded twD (A) and max kxk1 . I Lemma 24 (Tree-fold ⇒ bounded g1 (A)). Let Ai ∈ Zri ×t for i ∈ [τ ] with a = max{2, maxi∈[τ ] kAi k∞ }, Pτ r = i=1 ri . Let A = T D (A1 , . . . , Aτ ). There exists a computable function ftf-norm (a, r1 , . . . , rτ ) such that g1 (A) ≤ ftf-norm (a, r1 , . . . , rτ ). ! ! A1 Ã1 .. .. Proof. Let C = and obtain C̃ = by deleting duplicitous columns of C. Let . . Aτ Ãτ à = T D (Ã1 , . . . , Ãτ ). This tree-fold matrix (unlike A itself) satisfies the property that the number t̃ of columns of Ãi , for each i ∈ [τ ], is bounded by (2a + 1)r . Let n0 ∈ N be the number of bricks of A. Chen and Marx [4, Lemma 11] show that P 0 for every g̃ = (g̃1 , . . . , g̃n ) ∈ G(Ã) and for every I ⊆ [n0 ], i∈I g̃i is a sum of at most f2 (Ã1 , . . . , Ãτ ) elements from G(Ãτ ) for some computable function f2 . By [22, Lemma 3.20], √ g1 (Ãτ ) ≤ (t̃ − rτ )(a rτ )rτ ≤ t̃(arτ )O(rτ ) =: ζ, and thus ζ · f2 (Ã1 , . . . , Ãτ ) is an upper bound on g1 (Ã). Observe that A can be obtained from à by repeating columns. De Loera et al. [5, Corollary 3.7.2] show that repeating columns does not increase the `1 -norm of Graver elements, and thus g1 (A) ≤ ftf-norm (a, r1 , . . . , rτ ) = ζ · f2 (Ã1 , . . . , Ãτ ). J I Lemma 25. Let X ∈ N. Problem (ILP) with the additional constraint kxk1 ≤ X can be solved in time (aX)O(twD (A)) · n, where a = max{2, kAk∞ }. Proof. The algorithm follows from a recent result of Ganian et al. [11]: I Proposition 26 (Ganian et al. [11, Theorem 6]). (ILP) can be solved in time ΓO(twI (A)) · n, Pi where Γ = maxx∈Zn : Ax=b, l≤x≤u maxi∈[n] . j=1 Aj xj ∞ In other words, the parameter Γ is bounding the largest number in absolute value which appears in any prefix sum of Ax for any feasible solution x. Note that twI (A) ≤ twD (A) + 1 by Lemma 19; our proof applies for the more general case of incidence treewidth, but we only state Lemma 25 in terms of twD (A) for simplicity of exposition. In order to use Proposition 26, our only task is to formulate an auxiliary problem where we replace the nonlinear constraint kxk1 ≤ X with a linear constraint. This is easy by − splitting every variable xi into its positive and negative part x+ i and xi which we force to − + be nonnegative by setting xi , xi ≥ 0. Correspondingly, every column Ai of A is now split − − into A+ to li ≤ x+ i = Ai and Ai = −Ai . The bounds li ≤ xi ≤ ui are rewrittenP i − xi ≤ ui . n − + Finally, kxk1 ≤ X in the original problem is equivalent to setting i=1 (xi + xi ) ≤ X, + and we additionally set 0 ≤ x− i , xi ≤ X. It is easy to observe that this auxiliary problem − has incidence treewidth at most 2twI (A) + 2: replace xi in each bag by x+ i , xi , add the Pn − − + + + constraint i=1 (xi + xi ) ≤ X into each bag, and add one of l ≤ xi − xi or xi − x− i ≤u for at most one i for each bag, perhaps for multiple copies of the original bag. Moreover, by the fact that kxk1 ≤ X and a = kAk∞ , we have that Γ ≤ aX. The claim follows. J Proof of Theorem 3. Let A = T D (A1 , . . . , Aτ ) be a tree-fold matrix. By Lemma 24 we have that g1 (A) ≤ ftf-norm (a, r1 , . . . , rτ ) =: M We show how to construct a Λ-Graver-best oracle. Given an integer λ ∈ N, solve min{λwh | Ah = 0, l ≤ x + λh ≤ u, khk1 ≤ M } using Lemma 25; clearly the result is a λ-Graver-best step. Using a simple induction and the inductive construction of A, one gets that A has twD (A) ≤ tdD (A) ≤ r1 + · · · + rτ + 1 and thus the oracle is realized in FPT time. Lemma 13 then yields a Graver-best oracle, which, combined with Theorem 1, finishes the proof. J 12 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs n-fold ILP. A special case of tree-fold ILP is n-fold ILP, obtained by taking T to be the star with n leaves and A = T D (A1 , A2 ), where A1 ∈ Zr×t and A2 ∈ Zs×t . Proof of Theorem 4. Before we apply Lemma 25, we need to bound g1 (A). It follows from the proof of [13, Lemma 6.1] that there is a number g(A) = maxv∈G(A1 G(A2 )) kvk1 such that g1 (A) ≤ g(A) · g1 (A2 ). Let d2 ≤ (2a + 1)s be the number of distinct columns of A2 . De Loera et al. [5] give a bound on g1 (A) in terms of the number of distinct columns of a matrix A: I Lemma 27 (g1 (A) only depends on distinct columns [5, Corollary 3.7.4]). Let A ∈ Zm×n be a matrix of rank r, let d be the number of different columns in A, and let a = max{2, kAk∞ }. √ Then g1 (A) ≤ (d − r)(r + 1)( ma)m . √ Thus, g1 (A2 ) ≤ (d2 − s)(s + 1)( sa)s ≤ (as)O(s) . Let G2 be a matrix whose columns are elements of G(A2 ). We have that kA1 G2 k∞ ≤ a · (as)O(s) ≤ (as)O(s) . Moreover, since r A1 G2 has r rows, it has at most d1 = (as)O(s) = (as)O(rs) distinct columns. Again, √ by Lemma 27 we have that g(A) = g1 (A1 G2 ) ≤ (d1 − r)(r + 1)( ras)O(s) )r ≤ (ars)O(rs) . Combining, we get g1 (A) ≤ (ars)O(rs) · (as)O(s) ≤ (ars)O(rs) =: M . We have twD (A) ≤ r + s + 1 and thus running the algorithm of Lemma 25 once takes r+s 2 2 time (ars)O(rs) nt ≤ (ars)O(r s+rs ) nt and finds the λ-Graver-best step. Lemma 13 then yields a Graver-best oracle, which, combined with Theorem 1, finishes the proof. J 4 Primal and Dual Treedepth We prove Theorems 5 and 6 by showing that an ILP with bounded primal (dual) treedepth can be embedded into a multi-stage stochastic (tree-fold) ILP without increasing the parameters too much. The precise notion of how one ILP is embedded in another is captured as follows. I Definition 28 (Extended formulation). Let n0 ≥ n, m0 ∈ N, A ∈ Zm×n , b ∈ Zm , l, u ∈ 0 0 0 0 (Z ∪ {±∞}n and A0 ∈ Zm ×n , b0 ∈ Zm , l0 , u0 ∈ (Z ∪ {±∞})n . We say that A0 (x, y) = 0 0 b , l ≤ (x, y) ≤ u0 is an extended formulation of Ax = b, l ≤ x ≤ u if {x | Ax = b, l ≤ x ≤ u} = {x | ∃y : A0 (x, y) = b0 , l0 ≤ (x, y) ≤ u0 }. We note that from here on we always assume that if tdP (A) = k or tdD (A) = k, then there is a tree (not a forest) F of height k − 1 such that GP (A) ⊆ cl(F ) or GD (A) ⊆ cl(F ), respectively. Otherwise GP (A) is not connected and each component corresponds to a subset of variables which defines an ILP that can be solved independently; similarly for GD (A). 4.1 Primal Treedepth I Lemma 29 (Bounded primal treedepth ⇒ multi-stage stochastic). Let A, b, l and u as 0 0 in (ILP) be given, let a = max{2, kAk∞ } and τ + 1 = tdP (A). Then there exists C ∈ Zm ×n , 0 0 2 b0 ∈ Zm and l0 , u0 ∈ (Z∪{±∞})n , n0 ≤ nτ , m0 ≤ (2a+1)τ , which define an integer program C(x, y) = b0 , l0 ≤ (x, y) ≤ u0 , which is an extended formulation of Ax = b, l ≤ x ≤ u.  τ2 2 (2a+1)τ × τ +(2a+1)τ 2 Moreover, there exist matrices B1 , . . . , Bτ −1 ∈ Z(2a+1) ×τ and Bτ ∈ Z and a tree T such that C = T P (B1 , . . . , Bτ ) is a multi-stage stochastic constraint matrix, and all can be computed in time fP-embed (a, tdP (A)) · n2 for some computable function fP-embed . Proof. Let F be a rooted tree of height τ such that GP (A) ⊆ cl(F ) (recall that it can be computed in time ftd (tdP (A)) · |V (GP (A))|). M. Koutecký, A. Levin, and S. Onn F̂ 1 1 2 2 4 5 13 4 3 6 F̂ 0 5 3 6 Figure 1 Tree F̂ 0 obtained from F̂ by the transformation of step 1. We have τ = 3, squares correspond to original variables; discs correspond to dummy variables; the frets are encircled. Step 1: Dummy columns. We make F structured by adding dummy columns. Observe that every root-leaf path is of length at most τ and thus contains at most τ branching vertices. Unless F is a path, obtain a matrix A0 from A by inserting zero columns into A in order to make the path between any two branching vertices of length τ ; a special case is the root which we force to be in distance τ − 1 from the closest branching vertex. Set lower and upper bounds on the corresponding new variables to 0. A zero column is an isolated vertex in the primal graph and thus can be inserted to an arbitrary path of the tree F . Moreover, if any leaf is at depth less than τ 2 − 1, insert zero columns in the same way to make it be at depth exacty τ 2 − 1. Now there exists a rooted tree F 0 of height τ 2 − 1 such that GP (A0 ) ⊆ cl(F 0 ), all branching vertices are in distances 0, τ − 1, 2τ − 1, . . . , (τ − 1)τ − 1 from the root, and all leaves are at depth exactly τ 2 − 1. We call all vertices at depth 0 or iτ − 1, for i ∈ [τ ], frets, including the root and leaves. For example, take the tree F̂ in Figure 1; the result F̂ 0 of this procedure is depicted next to it. Step 2: Multi-stage stochastic extended formulation. Consider a root-leaf path P in F 0 : its vertex set V (P ) corresponds to a certain subset of the columns of A0 , with |V (P )| ≤ τ 2 . Furthermore, any row a of A0 with supp(a) ⊆ V (P ) can be written as a vector (a1 , . . . , aτ ) ∈ 2 Zτ with ai ∈ Zτ for each i ∈ [τ ], and with kak∞ ≤ a. The bricks ai correspond to segments between frets (including the end fret, i.e., the fret farthest from the root; segments adjacent to the root also contain the root). Also, for any row a of A0 , there exists some root-leaf path P such that supp(a) ⊆ V (P ). τ2 2 This inspires the following construction: let B ∈ Z(2a+1) ×τ be the matrix whose 2 τ2 columns are all the possible vectors a ∈ Zτ with kak∞ ≤ kAk∞ . Let Bi ∈ Z(2a+1) ×τ , for i ∈ [τ ], be the submatrix of B formed by rows (i − 1)τ + 1, . . . , iτ and modify the last such τ2 τ2 submatrix Bτ by putting Bτ := (Bτ | I) where I ∈ Z(2a+1) ×(2a+1) is the identity matrix; the variables corresponding to columns of I will play the role of slack variables. Let T be the tree of height τ obtained from F 0 by contracting all paths between frets. Now, let C = T P (B1 , . . . , Bτ ). Obtain F̃ from F 0 by appending a leaf to every leaf, and observe that GP (T P (B1 , . . . , Bτ )) ⊆ cl(F̃ ); the new leaves correspond to the slack variables 14 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs in Bτ . Our goal now is to construct a right hand side vector b0 and lower and upper bounds l0 , u0 to enforce exactly the constraints present in Ax = b. For every root-leaf path P in F 0 there is a corresponding root-leaf path P̃ in F̃ such that P̃ is P with an additional leaf. Fix a root-leaf path P in F 0 . For every row a of A0 with supp(a) ⊆ V (P ) and right hand side β, there exists a unique row c of C with supp(c) ⊆ V (P̃ ) such that c = (a, 1), and we set the right hand side of row c to β. For every row c of C which was not considered in the previous paragraph, set the right hand side to 0 and for the slack variable of this row set the lower bound to −∞ and the upper bound to ∞. Let us remark in passing that we are not limited by using the standard equality form of ILP: transforming an instance Ax ≤ b into the standard equality form by adding slack variables only possibly increases the treedepth by 1. J 4.2 Dual Treedepth I Lemma 30 (Bounded dual treedepth ⇒ tree-fold). Let A, b, l and u be as in (ILP), 0 0 0 a = max{2, kAk∞ } and τ + 1 = tdD (A). Then there exists D ∈ Zm ×n , b0 ∈ Zm and 0 l0 , u0 ∈ (Z ∪ {±∞})n , n0 ≤ nt, t ≤ n, m0 ≤ m · τ , which define an extended formulation of Ax = b, l ≤ x ≤ u. Moreover, there exist matrices A1 , . . . , Aτ ∈ Zτ ×t and a tree T such that D = T D (A1 , . . . , Aτ ) is a tree-fold constraint matrix, and all can be computed in time fD-embed (a, tdD (A)) · n2 for some computable function fD-embed . Proof. The construction is analogous to the one in Lemma 29; the key differences are that the paths in a tree F (GD (A) ⊆ cl(F )) correspond to collections of columns of A instead of rows and thus there are no slack variables in the tree-fold instance which we shall construct, however we have to deal with duplicitous columns. Let F be a tree of height τ such that GD (A) ⊆ cl(F ), let A0 be a matrix and F 0 be a tree of height τ 2 − 1 obtained as in the proof of Lemma 29 (swapping rows and columns and noting that adding zero rows with zero right hand sides does not change the problem) such that GD (A0 ) ⊆ cl(F 0 ). Similarly let T be the tree obtained from F 0 by contracting all paths between frets. 2 τ2 Let C̃ ∈ Zτ ×(2a+1) be the matrix of all columns of dimension τ 2 with values from [−a, a]. For every column c of C̃ let mc = maxP : root-leaf path in F 0 |{a | a = c, supp(a) ⊆ V (P )}| be the maximum multiplicity of columns identical to c over all root-leaf paths in F 0 . Now let P 2 C ∈ Zτ ×t , t = c∈C mc , be obtained from C̃ by taking each column c with multiplicity mc and let Ai ∈ Zτ ×t for i ∈ [τ ] be the matrix composed of rows (i − 1)τ + 1, . . . , iτ of C. Finally, let D = T D (A1 , . . . , Aτ ); we have GD (T D (A1 , . . . , Aτ )) ⊆ cl(F 0 ). It is now easy to see that we can construct an injective mapping ϕ from the columns of A0 to the columns of D such that ϕ(a) = d satisfies a = d and supp(a) = supp(d) = V (P ) for some root-leaf path P in F 0 . It remains to construct l0 , u0 and b0 . Let b0 be constructed from b by inserting zeroes in place where zero rows were inserted when constructing A0 from A. Let ai be the i-th column of A0 and dj = ϕ(ai ) be the j-th column of D. Then set lj0 = li and u0j = ui . For every column dj of D without a preimage in ϕ set lj0 = u0j = 0. We show that Dx0 = b0 , l0 ≤ x0 ≤ u0 is an extended formulation of Ax = b, l ≤ x ≤ u. The columns of D which do not have a preimage in A0 correspond to variables which are always 0, so we can disregard them. Thus the set of columns of D corresponding to possibly non-zero variables is exactly the set of columns of A0 . Moreover, A0 has been derived from A by inserting zero rows, which do not affect feasibility. J M. Koutecký, A. Levin, and S. Onn 4.3 15 Avoiding Reductions We desire to highlight that it is in fact not necessary to reduce a bounded primal (dual) treedepth instance to a multi-stage stochastic (tree-fold) instance. All that is needed are the bounds on g∞ (A) and g1 (A), since then the algorithms we use (Lemma 22 and Lemma 25) already work on bounded treedepth instances. To see that, it suffices to show that g∞ (A) ≤ g∞ (A0 ) and g1 (A) ≤ g1 (A0 ) for any extended formulation of (ILP) with a matrix A0 , i.e., the norm bounds transfer. These claims are an easy corollary of the following stronger lemma. I Lemma 31 (Graver basis of extended formulations). Let A0 (x, y) = b0 , l0 ≤ (x, y) ≤ u0 be an extended formulation of Ax = b, l ≤ x ≤ u. Then G(A) ⊆ H = {g | ∃h : (g, h) ∈ G(A0 )}. To prove the lemma we need the notion of a test set. A set T ⊆ Zn is a test set for (ILP) if, for any non-optimal feasible solution x, there exists g ∈ T such that x + g is feasible and w(x + g) < wx. It is known that G(A) is an inclusion-wise minimal test set for all ILPs with the constraint matrix A [5, Lemma 3.3.2]. Proof of Lemma 31. It suffices to show that H is a test set. Let x be a non-optimal feasible solution in (ILP). By definition, there exists a y such that (x, y) is a non-optimal feasible solution in A0 (x, y) = b0 , l0 ≤ (x, y) ≤ u0 . By the test set property of G(A0 ) we have that there exists (g, h) ∈ G(A0 ) which is an augmenting step for (x, y) and thus g is an augmenting step for x. J 4.4 Hardness Using a proof of Ganian et al. [11, Theorem 12] we show that we cannot hope to relax the parameter tdD (A) to twD (A), even if kAk∞ was a constant. I Lemma 32. (ILP) is NP-hard already when twD (A) = 3, kAk∞ = 2, and w = 0. Proof. The proof uses the same construction as Ganian et al. [11, Theorem 12]; they only observe that it has bounded incidence treewidth, while we notice that it also has bounded dual treewidth. Let S = {s1 , . . . , sn } ⊆ N, s ∈ N, be an instance of Subset Sum, i.e., we P are to decide whether there is a subset S 0 ⊆ S such that si ∈S 0 si = s. We formulate this as an ILP feasibility problem. Let L = maxi∈[n] hsi i. Let x1 , . . . , xn be binary variables where xi encodes whether si ∈ S 0 . Let zi , . . . , zn be variables where zi has bounds 0 ≤ zi ≤ si and we will enforce (xi = 1) =⇒ (zi = si ) and (xi = 0) =⇒ (zi = 0). The main trick needed to keep the coefficients small is the following. Let oji be the j-th bit of the binary encoding of si . We will introduce variables yij , j ∈ [0, L] and enforce that (xi = 1) =⇒ (yij = oji · 2j ) and PL (xi = 0) =⇒ (yij = 0); thus, we can then set zi = i=0 oji yij . The constraints A(x, y, z) = b are as follows: yi0 = xi yij = 2yij−1 zi = L X oji yij ∀i ∈ [n] (Xi ) ∀i ∈ [n], j ∈ [L] (Yij ) ∀i ∈ [n] (Zi ) . (S) i=0 n X zi = s i=1 Let us analyze the dual graph GD (A). Its vertices are the constraints Xi , Yij , Zi and S. There are the following edges: 16 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs Between S and each Zi , between Zi and each Yij , for all i ∈ [n], between each Yij and Yij+1 , for all i ∈ [n] and j ∈ [0, L − 1], and, between Xi and Yi0 . We can construct a tree decomposition (in fact, a path decomposition) by consecutively taking the following segment of bags for each i ∈ [n]: {S, Zi , Yi0 , Xi }, {S, Zi , Yi0 , Yi1 }, {S, Zi , Yi1 , Yi2 }, . . . , {S, Zi , YiL−1 , YiL } . Since each bag is of size 4, the treewidth is 3; we disregard lower and upper bounds here as they can be handled independently for each variable without increasing the treewidth. Note that due to the long path Yi0 − Yi1 − · · · − YiL we know that tdD (A) ≥ log L, and Subset Sum is only hard for L sufficiently large in n. J The fact that (ILP) is NP-hard already with twP (A), twD (A) and kAk∞ constant suggest that g∞ (A) and g1 (A) should be large; otherwise we could apply Lemma 22 or 25, contradicting P 6= NP. Now we prove that indeed g∞ (A) (and thus also g1 (A)) can be large already for constant twP (A), twD (A) and kAk∞ . I Lemma 33. For each n ≥ 2, n ∈ N, there exists a matrix A ∈ Z(n−1)×n with twP (A) = twD (A) = 1, kAk∞ = 2, and 2n−1 ≤ g∞ (A) ≤ g1 (A). Proof. Let  2  0   A :=   0  .  .. 0 −1 2 0 −1 ··· ··· 0 .. . 2 .. . 0 0 ··· .. . ··· 0 0 .. . −1 2 0 0 .. .     ,   0  −1 be an (n−1)×n matrix. The sequence {1, 2}, {2, 3}, . . . , {n−1, n} forms a tree decomposition of GP (A) of width 1; analogously {1, 2}, {2, 3}, . . . , {n − 2, n − 1} is a tree decomposition of GD (A) of width 1. Observe that every x ∈ Zn with Ax = 0 must satisfy that xi+1 = 2xi for each i ∈ [n − 1]. Clearly h = (1, 2, 4, . . . , 2n ) ∈ Nn satisfies Ah = 0, and from the previous observation it immediatelly follows that there is no h0 ∈ Nn with h0 @ h, and thus h ∈ G(A). J 5 Outlook We highlight a few questions related to our results. First, how far can Theorem 1 be extended towards separable convex objectives? The main missing piece seems to be a strongly polynomial algorithms for some classes of separable convex objectives similar to the algorithm of Tardos [25]. Second, is 4-block n-fold ILP FPT or W[1]-hard? The importance of this notorious problem is highlighted here: we give complete answers for parameter tdP (A) and tdD (A), but parameterization by tdI (A) is still wide open, and 4-block n-fold is the simplest open case. Third, we are interested in other strongly FPT algorithms. References 1 Gautam Appa, Balázs Kotnyek, Konstantinos Papalamprou, and Leonidas Pitsoulis. Optimization with binet matrices. Operations research letters, 35(3):345–352, 2007. M. Koutecký, A. Levin, and S. Onn 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 17 Stephan Artmann, Robert Weismantel, and Rico Zenklusen. A strongly polynomial algorithm for bimodular integer linear programming. In Proceedings of the 49th Annual ACM SIGACT Symposium on Theory of Computing, STOC 2017, pages 1206–1219. ACM, 2017. Matthias Aschenbrenner and Raymond Hemmecke. Finiteness theorems in stochastic integer programming. Foundations of Computational Mathematics, 7(2):183–227, 2007. Lin Chen and Daniel Marx. Covering a tree with rooted subtrees–parameterized and approximation algorithms. In Proceedings of the Twenty-Ninth Annual ACM-SIAM Symposium on Discrete Algorithms, SODA 2018, pages 2801–2820. SIAM, 2018. Jesús A. De Loera, Raymond Hemmecke, and Matthias Köppe. Algebraic and Geometric Ideas in the Theory of Discrete Optimization, volume 14 of MOS-SIAM Series on Optimization. SIAM, 2013. Jesús A. De Loera, Raymond Hemmecke, and Jon Lee. On augmentation algorithms for linear and integer-linear programming: From Edmonds–Karp to Bland and beyond. SIAM Journal on Optimization, 25(4):2494–2511, 2015. Pavel Dvořák, Eduard Eiben, Robert Ganian, Dušan Knop, and Sebastian Ordyniak. Solving integer linear programs with a small number of global variables and constraints. arXiv preprint arXiv:1706.06084, 2017. András Frank and Éva Tardos. An application of simultaneous diophantine approximation in combinatorial optimization. Combinatorica, 7(1):49–65, 1987. Eugene C. Freuder. Complexity of K-tree structured constraint satisfaction problems. In Proceedings of the 8th National Conference on Artificial Intelligence, pages 4–9, 1990. Robert Ganian and Sebastian Ordyniak. The complexity landscape of decompositional parameters for ILP. Artificial Intelligence, 2018. Robert Ganian, Sebastian Ordyniak, and M. S. Ramanujan. Going beyond primal treewidth for (M)ILP. In Satinder P. Singh and Shaul Markovitch, editors, Proceedings of the ThirtyFirst AAAI Conference on Artificial Intelligence, February 4-9, 2017, San Francisco, California, USA, pages 815–821. AAAI Press, 2017. Raymond Hemmecke, Matthias Köppe, and Robert Weismantel. Graver basis and proximity techniques for block-structured separable convex integer minimization problems. Mathematical Programming, 145(1-2, Ser. A):1–18, 2014. Raymond Hemmecke, Shmuel Onn, and Lyubov Romanchuk. N-fold integer programming in cubic time. Mathematical Programming, pages 1–17, 2013. Dorit S Hochbaum and J George Shanthikumar. Convex separable optimization is not much harder than linear optimization. Journal of the ACM (JACM), 37(4):843–862, 1990. Bart M. P. Jansen and Stefan Kratsch. A structural approach to kernels for ILPs: Treewidth and total unimodularity. In Nikhil Bansal and Irene Finocchi, editors, Proceedings of the 23rd Annual European Symposium, ESA 2015, Patras, Greece, September 14-16, 2015, volume 9294 of Lecture Notes in Computer Science, pages 779–791. Springer, 2015. Klaus Jansen, Kim-Manuel Klein, Marten Maack, and Malin Rau. Empowering the configuration-IP – new PTAS results for scheduling with setups times. arXiv preprint arXiv:1801.06460, 2018. Ravi Kannan. Minkowski’s convex body theorem and integer programming. Mathematics of Operations Research, 12(3):415–440, August 1987. Dušan Knop, Martin Koutecký, and Matthias Mnich. Combinatorial n-fold integer programming and applications. In Proceedings of the 25th Annual European Symposium on Algorithms, ESA 2017, September 4-6, 2017, Vienna, Austria, volume 87 of LIPIcs, pages 54:1–54:14. Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, 2017. Extended version available at https://arxiv.org/abs/1705.08657. Dušan Knop, Martin Koutecký, and Matthias Mnich. Voting and bribing in singleexponential time. In Proceedings of the 34th Symposium on Theoretical Aspects of Computer Science, STACS 2017, March 8-11, 2017, Hannover, Germany, volume 66 of LIPIcs, pages 46:1–46:14. Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, 2017. 18 A Parameterized Strongly Polynomial Algorithm for Block Structured ILPs 20 Phokion G Kolaitis and Moshe Y Vardi. Conjunctive-query containment and constraint satisfaction. Journal of Computer and System Sciences, 61(2):302–332, 2000. Hendrik W. Lenstra, Jr. Integer programming with a fixed number of variables. Mathematics of Operations Research, 8(4):538–548, 1983. Shmuel Onn. Nonlinear discrete optimization. Zurich Lectures in Advanced Mathematics, European Mathematical Society, 2010. http://ie.technion.ac.il/∼onn/Book/NDO.pdf. Felix Reidl, Peter Rossmanith, Fernando Sánchez Villaamil, and Somnath Sikdar. A faster parameterized algorithm for treedepth. In Javier Esparza, Pierre Fraigniaud, Thore Husfeldt, and Elias Koutsoupias, editors, Proceedings Part I of the 41st International Colloquium on Automata, Languages, and Programming, ICALP 2014, Copenhagen, Denmark, July 8-11, 2014, volume 8572 of Lecture Notes in Computer Science, pages 931–942. Springer, 2014. Alexander Shrijver. Theory of linear and integer programming. Interscience Series in Discrete Mathematics and Optimization. Wiley, 1986. Éva Tardos. A strongly polynomial algorithm to solve combinatorial linear programs. Operations Research, 34(2):250–256, 1986. Sergey I. Veselov and Aleksandr J. Chirkov. Integer program with bimodular matrix. Discrete Optimization, 6(2):220–222, 2009. 21 22 23 24 25 26
8cs.DS
Fast and Accurate Recurrent Neural Network Acoustic Models for Speech Recognition Haşim Sak, Andrew Senior, Kanishka Rao, Françoise Beaufays Google {hasim,andrewsenior,kanishkarao,fsb}@google.com arXiv:1507.06947v1 [cs.CL] 24 Jul 2015 Abstract We have recently shown that deep Long Short-Term Memory (LSTM) recurrent neural networks (RNNs) outperform feed forward deep neural networks (DNNs) as acoustic models for speech recognition. More recently, we have shown that the performance of sequence trained context dependent (CD) hidden Markov model (HMM) acoustic models using such LSTM RNNs can be equaled by sequence trained phone models initialized with connectionist temporal classification (CTC). In this paper, we present techniques that further improve performance of LSTM RNN acoustic models for large vocabulary speech recognition. We show that frame stacking and reduced frame rate lead to more accurate models and faster decoding. CD phone modeling leads to further improvements. We also present initial results for LSTM RNN models outputting words directly. Index Terms: speech recognition, acoustic modeling, connectionist temporal classification, CTC, long short-term memory recurrent neural networks, LSTM RNN. 1. Introduction While speech recognition systems using recurrent and feedforward neural networks have been around for more than two decades [1, 2], it is only recently that they have displaced Gaussian mixture models (GMMs) as the state-of-the-art acoustic model. More recently, it has been shown that recurrent neural networks can outperform feed-forward networks on large-scale speech recognition tasks [3, 4]. Conventional speech systems use cross-entropy training with HMM CD state targets followed by sequence training. CTC models use a “blank” symbol between phonetic labels and propose an alternative loss to conventional cross-entropy training. We recently showed that RNNs for LVCSR trained with CTC can be improved with the sMBR sequence training criterion and approaches state-of-the-art [5]. In this paper we further investigate the use of sMBR-trained CTC models for acoustic speech recognition and show that with appropriate features and the introduction of context dependent phone models they outperform the conventional LSTM RNN models by 8% relative in recognition accuracy. The next section describes the LSTM RNNs and summarizes the CTC method and sequence training. We then describe acoustic frame stacking as well as context dependent phone and whole-word modeling. The following section describes our experiments and presents results which are summarized in the conclusions. Forward Forward Forward Forward Forward 500 500 500 500 500 Forward Forward Forward input 640 output Forward Forward 300 300 300 300 300 Backward Backward Backward Backward Backward 300 300 300 300 300 input 240 42 or 9248 output 42 or 9248 Figure 1: Layer connections in unidirectional (top) and bidirectional (bottom) 5-layer LSTM RNNs. RNNs model the input sequence either unidirectionally or bidirectionally [6]. Unidirectional RNNs (Figure 1 top) esti− → mate the label posteriors ylt = p(lt |xt , ht ) using only left context of the current input xt by processing the input from left − → to right and having a hidden state ht in the forward direction. This is desirable for applications requiring low latency between inputs and corresponding outputs. Usually output targets are delayed with respect to features, giving access to a small amount of right/future context, improving classification accuracy without incurring much latency. If one can afford the latency of seeing the entire sequence, bidirectional RNNs (Figure 1 bottom) estimate the label poste− → ← − riors p(lt |xt , ht , ht ) using separate layers for processing the input in the forward and backward directions. We use deep LSTM RNN architectures built by stacking multiple LSTM layers. These have been shown to perform better than shallow models for speech recognition [7, 8, 9, 3]. For bidirectional models, we use two LSTM layers at each depth — one operating in the forward and another operating in the backward direction over the input sequence. Both of these layers are connected to both the previous forward and backward layers. The output layer is also connected to both of the final forward and backward layers. We experiment with different acoustic units for the output layer, including context dependent HMM states and phones, both context independent and context dependent (Section 2.4). We train the models in a distributed manner using asynchronous stochastic gradient descent (ASGD) optimization technique allowing parallelization of training over a large number of machines on a cluster and enabling large scale training of neural networks [10, 11, 12, 13, 3]. The weights in all the networks are randomly initialized with a uniform (-0.04, 0.04) distribution. We clip the activations of memory cells to [-50, 50], and their gradients to [-1, 1], making CTC training stable. 2. RNN Acoustic Modeling Techniques In this work we focus on the LSTM RNN architecture which has shown good performance in our previous research, outperforming deep neural networks. 2.1. CTC Training The CTC approach [14] is a technique for sequence labeling using RNNs where the alignment between the inputs and tar- get labels is unknown. CTC can be implemented with a softmax output layer using an additional unit for the blank label used to estimate the probability of outputting no label at a given time. “Blank” is similar to the “non-perceiving state” proposed earlier [15]. The output label probabilities from the network define a probability distribution over all possible labelings of input sequences including the blank labels. The network can be trained to optimize the total log probability of correct labelings for training data as estimated using the network outputs and forward-backward algorithm [16]. The correct labelings for an input sequence are defined as the set of all possible labelings of the input with the target labels in the correct sequence possibly with repetitions and with blank labels permitted between separate labels. The targets for CTC training can be efficiently and easily computed using finite state transducers (FSTs) as described in [5], with additional optional blank states interposed between the states of the sequence labels. While conventional hybrid speech and handwriting recognition systems usually train from fixed alignments, the use of the forward-backward algorithm to reestimate network targets given the current model can equally be applied to conventional recurrent [17] or feed-forward networks [18] if no such alignment is available. These conventional realignment systems have followed the practice of choosing alignments to maximize the likelihood of the data under state sequence(s) that match the transcript, and use posteriors scaled by the label priors. Hence, CTC differs from conventional modeling in two ways. First, the additional blank label relieves the network from making label predictions at a frame when it is uncertain. Second, the training criterion optimizes the log probability of state sequences rather than the log likelihood of inputs. Whether using CTC with posteriors and a blank symbol or a conventional model with scaled posteriors, once the target posteriors are computed by the forward-backward algorithm, gradients of the Cross Entropy loss between the softmax outputs and the targets are backpropagated through the network. As described in [5], one can use the standard beam search algorithm for speech decoding with CTC models, again allowing an optional blank state labels between the output labels in the search graph. In decoding, we only scale the blank label posterior by a constant scalar decided by cross-validation on a held-out set. We found that CTC models with phone labels do not require a language model weight to normalize acoustic model scores with respect to language model scores. However, CTC models with CD phone labels (Section 2.4) perform better with a weighting constant (2.1). be baked into into the bias of the blank label output unit in the RNN model by adding negative log of the scale before starting sMBR training, just as the state priors can be baked into the softmax biases of conventional models before sequence training. To summarize, after sequence discriminative training, the only difference between CTC and “conventional” models is the use of the blank symbol. Henceforth we use “CTC” to refer to these models (and their initial training using unscaled posteriors to generate alignments) and contrast them with “conventional” models which have no blank symbol, and which, in this paper, we train with fixed hard alignments. 2.3. Acoustic Features We use 80-dimensional log mel filterbank energy features computed every 10ms on 25ms windows. We obtained significant improvements by increasing the number of filterbanks from 40 up to 80, but only present results for the latter. In the past, we have observed that training with CTC is unstable, in that some training runs fail to converge. We found [5] that stability was improved by starting training using two output layers with CTC and the conventional CE loss, or initializing from a network whose LSTM layers had been pretrained using the CE loss. We suggest that this is because of the inherent arbitrariness of the alignment with CTC, which considers valid any alignment in which the target symbols are emitted in the correct order interspersed with an arbitrary number of blanks. One way of reducing the huge space of alignments is to reduce the number of input frames. This can be done by simply decimating the input frames, though to present the full acoustic information of the input signal, we first stack frames so that the networks sees multiple (e.g. 8) frames at a time but then decimate the frames so that we skip forward multiple frames (e.g. 3) after processing each such “super-frame”. This process is illustrated in Figure 2. By decimating the frames in this manner, the acoustic model is able to process the full signal but acoustic model computation need only happen every 30ms. For a network of a fixed size this results in a dramatic reduction in the acoustic model computation and decoding time. 2.2. Sequence Discriminative Training Cross-entropy and CTC criteria are suboptimal for the objective of word error rate (WER) minimization in ASR. A number of sequence-level discriminative training criteria incorporating the lexical and language model constraints used in speech decoding have been shown to improve the performance of DNN and RNN acoustic models bootstrapped with CE [19, 20, 12, 21, 4] or CTC training criteria [5]. In this paper, we use the state-level minimum Bayes risk (sMBR) sequence discriminative training criterion [19] for improving accuracy of RNN acoustic models initialized with CE or CTC criterion. As discussed above and before [5], decoding with CTC models requires scaling the blank label posterior. We found that sMBR training can fix this scaling issue if we do not scale the blank label posterior while decoding an utterance to get numerator and denominator lattices during sMBR training. Alternatively, the blank label scaling can Figure 2: Stacking and subsampling of frames. Acoustic features are generated every 10ms, but are concatenated and downsampled for input to the network: 8 frames are stacked for unidirectional (top) and 3 for bidirectional models (bottom). 2.4. Context-Dependent Phones Previously CTC models [8, 5] used context independent outputs, yet it is well known that context dependent states outperform context independent models for conventional speech recognition systems, both GMM-based and neural-network hybrids. We argue that context dependency is an important constraint on decoding and provides a useful labeling for state outputs, so believe it should be useful for CTC models. Previously, [22] it was shown that it is possible to build context dependent whole-phone models, and that for LSTM-HMM hybrid speech recognition, these models can give similar results to context dependent state models, provided that a minimum duration is enforced. We repeat that procedure, using the hierarchical binary divisive clustering algorithm of Young et al. [23] for context-tying. We use three frames of 40-dimensional logmel filterbanks to represent each whole-phone instance. One tree per phone is constructed, with the maximum-likelihoodgain phonetic question being used to split the data at each node. On our training data we end up with 9287 CD phones. As found before, enforcing a minimum duration for each phone was found to improve word error rates, and we again use a 10% cutoff of the training-set duration histogram as the minimum duration for each CD-phone for decoding of our conventional models. For CTC, no such duration model is imposed. 2.5. Word Acoustic Models The combination of LSTM RNNs’ memory and CTC’s ability to learn an alignment between label and acoustic frame sequences, while relieving the network from having to label each frame by introducing the blank label, enables the use of longer duration modeling units. For instance, we can train acoustic models predicting whole words rather than phonemes. There have been previous studies using LSTM RNN CTC models for keyword spotting tasks with small vocabularies (e.g. 12 words [24]). In this paper, we investigate the effectiveness of word acoustic models trained over a large training set with various large vocabularies ranging from 7,000 to 90,000 words. 3. Experiments Unidirectional models used 500 memory cells in each layer and bidirectional models had 300 memory cells for each direction in each layer. For the conventional models, we got the best results with 2 LSTM layers of 1000 cells each with a recurrent projection layer of 512 units. 3.2. Results & Discussion Table 1 shows the word error rates (WERs) on the voice search task for various unidirectional and bidirectional LSTM RNN acoustic models trained with CE or CTC loss with CD HMM state, CI phone or CD phone labels. As can be expected from trying to learn with 3 state HMM labels, CTC CD state models do not perform well. The unidirectional CE CD phone model is marginally better than the corresponding CE CD state model. CTC CI phone models perform very similarly to CE CD state models. CTC CD phone models give significant improvements over CTC CI phone models – about 8% for unidirectional and 3.5% for bidirectional. Bidirectional models improve over unidirectional ones about 10% for CD state and CI phone models – while improving CTC CD phone models only 5%. Labels CD state CI phone CD phone CE (%) Uni Bi 15.6 14.0 15.5 CTC (%) Uni Bi 18.9 16.5 15.5 14.1 14.3 13.6 Table 1: WERs for conventional and CTC initialization of LSTM RNN acoustic models. 3.1. Data & Models We train and evaluate LSTM RNN acoustic models on handtranscribed, anonymized utterances taken from real 16kHz Google voice search traffic. Our training set consists of 3 million utterances with average duration of about 4s. To achieve robustness to background noise and reverberant environments we synthetically distort each utterance in a room simulator with a virtual noise source. Noise is taken from the audio of YouTube videos. Each utterance is randomly distorted to get 20 variations. This “Multi-style training” also alleviates overfitting of CTC models to training data. The test set’s 28,000 utterances are each distorted once with held-out noise samples. Evaluation uses a 5-gram language model pruned to 100 million n-grams. Rescoring word lattices with a larger n-gram model gives similar relative gains for all the acoustic models, therefore we only report results after first pass decoding. For all the experiments, we use a wide beam in decoding to avoid search errors and obtain the best possible performance. For training networks with CE criterion using fixed alignments, the training utterances are force-aligned using an 85 million parameter DNN with 13522 CD HMM states. We explored variations of frame stacking and skipping as described in section 2.3. For the conventional unidirectional models’ inputs, we either stack 8 consecutive feature frames and skip 1 frame or present a single frame with a 5 frames delayed target — both approaches give similar results. For the bidirectional models, we only need to use a single frame input. For bidirectional CTC models, we stack 3 consecutive feature frames as input feature vector and skip 3 frames. For unidirectional CTC models, we stack 8 consecutive feature frames and skip 3 frames (Figure 2). We found longer context helps unidirectional models but is not needed for bidirectional models. For CTC models, we obtained the best results with depth 5. Table 2 shows the results for sequence discriminative training of these initial CE/CTC models with sMBR loss. We can see that sMBR training consistently improves all of the models initially trained with CE or CTC loss about 10% relative. We obtain best results with CTC CD phone models outperforming the second best model about 8% for unidirectional and 4% for bidirectional model. Labels CD state CI phone CD phone Initialization Method Uni CE 15.6 CTC 15.5 CTC 14.3 Bi 14.0 14.1 13.6 +sMBR Uni Bi 14.0 12.9 14.2 12.7 12.9 12.2 Table 2: WERs (%) for sequence-trained LSTM RNN models. Figure 3 shows label posteriors estimated by various CTC phone and CD phone models. It can be seen that spikes for the label posteriors do not correspond to the DNN alignment and differ between the models. Unidirectional models delay their output labels by about 300 milliseconds. As can be expected, bidirectional models make better predictions. The models are not good at modeling silence labels. Sequence discriminative training changes posteriors, but not the spike positions. While learning an alignment in conventional GMM-HMM systems and DNN-HMM hybrid systems has been shown to work well, learning a conventional alignment without blank label using LSTM RNNs does not work well. Figure 4 shows label posteriors estimated using a unidirectional LSTM RNN CD phone model trained with CTC loss with no blank label allowed between CD phone labels. The model has learned an arbitrary alignment. Having a memory as in RNN models in contrast to memoryless feed forward neural networks means the model can delay its outputs instead of making decisions using only local <b> sil m 1 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 m j u z sil j u z i i @ I @ m z I n n S k A g oU S @k A g oU sil (a) unidirectional phone CTC + sMBR <b> sil.1 m.25 1 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 j.35 u.46 z.69 i.113 @.320 m.227 z.87 I.17 n.350 S.41 @.133 k.75 Vocabulary 25k Word 7k Word A.22 g.18 oU.68 m j u z sil <b> sil.1 m.25 i @ m z I n S @k A g oU j.35 u.46 z.69 m j u z sil <b> sil.1 m.25 i.113 @.320 m.227 i z.87 I.17 n.350 @ m z I n S @k S.41 @.133 k.75 A A.22 g.18 oU.68 g oU sil In vocab. WER (%) 14.5 11.8 rectional CTC models with 7k and 90k vocabulary for a heldout utterance. We plot the posteriors for all the labels that were above 0.05 probability at any time. The words ’dietary’ and ’nutritionist’ are OOV for the 7k vocabulary. It is interesting to see that the models make spiky predictions even with a large vocabulary and the predictions for confused words are output at the same time. Although these two models have very similar spike positions for the words, they are different for the 25k model. <b> to do become a diet j.35 u.46 z.69 i.113 @.320 m.227 z.87 I.17 n.350 S.41 @.133 k.75 A.22 g.18 oU.68 sil t u bi k m j u z sil i @ m z I n S @k A g oU temporal information. Therefore, the model learns an alignment where it chooses to adjust its labeling according to its certainty for a label given the input. This results in an arbitrary alignment where some labels are repeated more than others depending on the input. Note that using a hybrid approach with a prior cannot fix this issue. sil j.35 u.46 z.69 m j u z i.113 @.320 m.227 i z.87 I.17 n.350 @ m z I n S @k S.41 @.133 k.75 A A.22 g.18 oU.68 g oU V msil { d aI @ t E r\ i sil n u t r\I S@n@ s t sil what classes should i take for two year program in community college wVt k l { s @ z sil S Ud aI t eI k sil f O r\{ t u j i r\ p r\oUg r\ { m sil I n sil { k@m j un@t i sil k A l @ dZ sil (a) 7k vocabulary sil (d) bidirectional CD phone CTC + sMBR <b> sil.1 m.25 military carry terry minus nutrition nutritional 1 0.8 0.6 0.4 0.2 0 Figure 3: Label posteriors estimated by various LSTM RNN models plotted against fixed DNN frame level alignments shown only for labels in the alignment on a heldout utterance ‘museums in Chicago’. <b> refers to the blank label. 1 0.8 0.6 0.4 0.2 0 WER (%) 19.5 26.8 sil (c) unidirectional CD phone CTC + sMBR 1 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 OOV 4.8 13 Table 3: LSTM RNN CTC word acoustic models. The WERs and out of vocabulary (OOV) rates for word models are on heldout data with no decoding or language model. WERs in the last column are computed ignoring utterances containing OOVs. (b) unidirectional CD phone CTC 1 0.8 0.6 0.4 0.2 0 and predicted word sequence where the word with highest probability is taken ignoring repetitions and the blank label with no language model or decoding. We have also experimented with 90k vocabulary CTC word models, and note that the bidirectional model gives a 25% lower WER than the unidirectional model. Figure 5 shows label posteriors estimated by the bidi- <b> do to become a diet dietary terry nutritional nutritionist nutritious what classes should i take for two year program in community college 1 0.8 0.6 0.4 0.2 0 sil t u bi k V msil { d aI @ t E r\ i sil n u t r\I S@n@ s t sil wVt k l { s @ z sil S Ud aI t eI k sil f O r\{ t u j i r\ p r\oUg r\ { m sil I n sil { k@m j un@t i sil k A l @ dZ sil (b) 90k vocabulary Figure 5: ‘To become a dietary nutritionist what classes should I take for a two year program in a community college’ 4. Conclusions sil Figure 4: Label posteriors for a unidirectional LSTM RNN model with conventional alignment – no blank label. We have experimented with CTC word models with various vocabulary sizes where the output layer directly predicts words rather than phonemes. We have used two different vocabularies with the most frequent 7,000 (≥ 150 exemplars) or 25,000 (≥ 20 exemplars) words from the training data transcripts. Table 3 shows WERs for bidirectional CTC word acoustic models as calculated edit distance between reference word sequence In this work we have shown a number of improvements to recurrent network acoustic models. The use of longer-term feature representations, processed at lower frame rates brought stability to the convergence of CTC training of models with blank symbol outputs while also resulting in a considerable reduction in computation. After sequence training, such models are found to perform better than previous acoustic models. Performance of the blank-symbol acoustic models was further improved by the introduction of context-dependent phonetic units, with the result that these models now outperform conventional sequence trained LSTM-hybrid models. We have also shown that we can train word level acoustic models to achieve reasonable accuracy on medium vocabulary speech recognition without using a language model. 5. References [18] A. Senior, G. Heigold, M. Bacchiani, and H. Liao, “GMM-free DNN training,” in Proc. ICASSP, 2014. [1] A. Robinson, M. Hochberg, and S. Renals, “The use of recurrent networks in continuous speech recognition,” in Automatic Speech and Speaker Recognition, K. K. P. C.-H. Lee, F. K. Soong, Ed. Norwell, MA, USA: Kluwer Academic Publishers, 1996, pp. 233–258. [19] B. Kingsbury, “Lattice-based optimization of sequence classification criteria for neural-network acoustic modeling,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), Taipei, Taiwan, Apr. 2009, pp. 3761–3764. [2] H. Bourlard and N. Morgan, Connectionist speech recognition. Kluwer Academic Publishers, 1994. [20] B. Kingsbury, T. N. Sainath, and H. Soltau, “Scalable minimum Bayes risk training of deep neural network acoustic models using distributed Hessian-free optimization,” in Interspeech, 2012. [3] H. Sak, A. Senior, and F. Beaufays, “Long Short-Term Memory Recurrent Neural Network Architectures for Large Scale Acoustic Modeling,” in INTERSPEECH 2014, 2014. [4] H. Sak, O. Vinyals, G. Heigold, A. Senior, E. McDermott, R. Monga, and M. Mao, “Sequence discriminative distributed training of long short-term memory recurrent neural networks,” in Interspeech, 2014. [5] H. Sak, A. Senior, K. Rao, O. Irsoy, A. Graves, F. Beaufays, and J. Schalkwyk, “Learning acoustic frame labeling for speech recognition with recurrent neural networks,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), 2015. [6] M. Schuster and K. K. Paliwal, “Bidirectional recurrent neural networks,” Signal Processing, IEEE Transactions on, vol. 45, no. 11, pp. 2673–2681, 1997. [7] F. Eyben, M. Wollmer, B. Schuller, and A. Graves, “From speech to letters using a novel neural network architecture for grapheme based ASR,” in Automatic Speech Recognition & Understanding, 2009. ASRU 2009. IEEE Workshop on. IEEE, 2009, pp. 376–380. [8] A. Graves, A. Mohamed, and G. Hinton, “Speech recognition with deep recurrent neural networks,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), 2013. [9] A. Graves, N. Jaitly, and A. Mohamed, “Hybrid speech recognition with deep bidirectional LSTM,” in Automatic Speech Recognition and Understanding (ASRU), 2013 IEEE Workshop on. IEEE, 2013, pp. 273–278. [10] Q. Le, M. Ranzato, R. Monga, M. Devin, K. Chen, G. Corrado, J. Dean, and A. Ng, “Building high-level features using large scale unsupervised learning,” in International Conference on Machine Learning, 2012, pp. 81–88. [11] J. Dean, G. Corrado, R. Monga, K. Chen, M. Devin, Q. Le, M. Mao, M. Ranzato, A. Senior, P. Tucker, K. Yang, and A. Ng, “Large scale distributed deep networks,” in Advances in Neural Information Processing Systems (NIPS), 2012. [12] H. Su, G. Li, D. Yu, and F. Seide, “Error back propagation for sequence training of context-dependent deep networks for conversational speech transcription,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), 2013, pp. 6664–6668. [13] G. Heigold, V. Vanhoucke, A. Senior, P. Nguyen, M. Ranzato, M. Devin, and J. Dean, “Multilingual acoustic models using distributed deep neural networks,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), vol. 1, Vancouver, Canada, Apr. 2013. [14] A. Graves, S. Fernández, F. Gomez, and J. Schmidhuber, “Connectionist temporal classification: Labelling unsegmented sequence data with recurrent neural networks,” in Proceedings of the 23rd International Conference on Machine Learning. ACM, 2006, pp. 369–376. [15] N. Morgan, H. Bourlard, S. Greenberg, and H. Hermansky, “Stochastic perceptual auditory-event-based models for speech recognition,” in ICSLP, 1994. [16] L. R. Rabiner, “A tutorial on hidden Markov models and selected applications in speech recognition,” Proceedings of the IEEE, vol. 77, no. 2, pp. 257–286, Feb. 1989. [17] A. Senior and A. Robinson, “Forward-backward retraining of recurrent neural networks,” in NIPS, 1994. [21] K. Veselý, A. Ghoshal, L. Burget, and D. Povey, “Sequencediscriminative training of deep neural networks,” in Interspeech, 2013. [22] A. Senior, H. Sak, and I. Shafran, “Context dependent phone models for LSTM RNN acoustic modelling,” in IEEE International Conference on Acoustics, Speech, and Signal Processing (ICASSP), 2015. [23] S. Young, J. Odell, and P. Woodland, “Tree-based state tying for high accuracy acoustic modelling,” in Proc. ARPA Human Language Technology Workshop, 1994. [24] S. Fernández, A. Graves, and J. Schmidhuber, “An application of recurrent neural networks to discriminative keyword spotting,” in ICANN, 2007, pp. 220–229.
9cs.NE
1 Nonbinary tree-based phylogenetic networks Laura Jetten and Leo van Iersel arXiv:1601.04974v3 [q-bio.PE] 30 Sep 2016 Abstract Rooted phylogenetic networks are used to describe evolutionary histories that contain non-treelike evolutionary events such as hybridization and horizontal gene transfer. In some cases, such histories can be described by a phylogenetic base-tree with additional linking arcs, which can for example represent gene transfer events. Such phylogenetic networks are called tree-based. Here, we consider two possible generalizations of this concept to nonbinary networks, which we call tree-based and strictly-tree-based nonbinary phylogenetic networks. We give simple graph-theoretic characterizations of tree-based and strictlytree-based nonbinary phylogenetic networks. Moreover, we show for each of these two classes that it can be decided in polynomial time whether a given network is contained in the class. Our approach also provides a new view on tree-based binary phylogenetic networks. Finally, we discuss two examples of nonbinary phylogenetic networks in biology and show how our results can be applied to them. Index Terms Phylogenetic tree, phylogenetic network, evolution, tree-of-life, tree-based ✦ 1 I NTRODUCTION Rooted phylogenetic networks are becoming increasingly popular as a way to describe evolutionary histories that cannot be described by a phylogenetic tree [1], [2]. The leaves of such a network are labelled and represent, for example, currently-living species, while the root of the network represents a common ancestor of those species. Vertices with two or more outgoing arcs represent a divergence event in which a lineage split into two or more lineages, while vertices with two or more incoming arcs represent a convergence of different lineages into a single lineage. The latter events are called reticulate evolutionary events and include, for example, hybridization, introgression and horizontal gene transfer. Therefore, these vertices are called reticulations. A phylogenetic network without reticulations is a (rooted) phylogenetic tree. Hence, phylogenetic networks are a more general model for evolutionary histories than phylogenetic trees. Although the occurence of reticulate evolutionary events is well-accepted, there are different views on their importance. One possibility is to see evolution as a mainly tree-like (vertical) process with sporadic horizontal events. The other extreme is to completely abandon the idea of a tree-of-life and to see evolution purely as a network [3], [4], [5], [6]. This discussion is especially relevant for prokaryotes, where the main form of non-treelike evolution is horizontal gene transer, i.e. genetic material is transferred from one species to another coexisting species that is not a descendant. If the evolutionary history of a group of prokaryotes is mainly tree-like, then you could describe such a history as a phylogenetic species tree with additional cross-connecting arcs describing the horizontal gene transfer events. However, if their evolution is inherently network-like, then it might not be possible to identify any tree-like signal at all. This discussion has recently led to the introduction of a new class of phylogenetic networks called “treebased” [7], which contains those networks that can be described by a phylogenetic base-tree with additional linking arcs between branches of the base-tree. This notion was motivated by the observation that this is not always possible, i.e. there exist networks that can not be described as a base-tree with linking arcs [8]. Francis and Steel showed recently that there is a polynomial-time algorithm to decide whether a given binary phylogenetic network is tree-based or not [7]. In addition, it was shown that any phylogenetic network can be made tree-based by the addition of leaves. Hence, this notion has to be used with caution in the presence of possible extinctions or under-sampling. Even more recently, a simple graph-theoretic characterization was given that can also be used to decide whether a given binary network is tree-based or not [9]. Unfortunately, these results are all restricted to binary phylogenetic networks, in which all vertices • • • E-mail: [email protected] and [email protected] Delft University of Technology, PO-box 5, 2600 AA, Delft, The Netherlands. Leo van Iersel was partly supported by a Vidi grant from the Netherlands Organisation for Scientific Research (NWO) and partly by the 4TU Applied Mathematics Institute (4TU.AMI). 2 Reticulation number 21 6 5 5 Leaves 16 41 7 19 Reticulate Process Tree-based Reference Violets polyploidisation no [15, Figure 4], Figure 19 Origin of Eukaryotes endosymbiosis yes [16, Figure 2], Figure 20 Influenza reassortment yes [17, Figure 1] Cichlids (fish) hybridisation yes [18, Figure 4] TABLE 1 Examples of nonbinary phylogenetic networks in biology. The reticulation number is defined as the total number of “additional branches” in the network, i.e. a reticulation with p parents adds p − 1 to the reticulation number. have at most two incoming and at most two outgoing arcs (see the next section for precise definitions). Moreover, the techniques used by these authors do not (easily) extend to nonbinary networks. Here, we also consider nonbinary phylogenetic networks. In such a network, a vertex can have more than two outgoing arcs, representing uncertainty in the order of divergence events, or more than two incoming arcs, representing uncertainty in the order of reticulate events. See Table 1 for real biological examples of nonbinary phylogenetic networks (also see [10], [11], [12]). In general, such uncertainties cannot simply be overcome by collecting more data [13], [14]. Since the tree-basedness of nonbinary networks has not been introduced or studied before, we discuss different possible definitions of tree-based in the nonbinary case. Roughly speaking, we call a nonbinary phylogenetic network strictly tree-based if it can be obtained from a rooted (nonbinary) phylogenetic tree by adding linking arcs between the branches of the tree, such that no two linking arcs attach at the same point. Consequently, in such a network all vertices have at most two incoming arcs. In addition, all vertices with more than two outgoing arcs correspond to vertices of the basetree, because the new vertices that are created by the addition of linking arcs all get at most two outgoing arcs: one of the base-tree and one linking arc. Hence, a strictly-tree-based network can be nonbinary only because the base-tree can be nonbinary. We also consider tree-based nonbinary phylogenetic networks, which are networks that can be obtained from a rooted (nonbinary) phylogenetic tree by adding linking arcs between branches and/or vertices of the tree. It turns out that a network is in this class precisely if it has at least one binary refinement that is a tree-based binary phylogenetic network. This is a more general class than the strictly-tree-based variant. Our main results are as follows. We first present an alternative view on binary tree-based phylogenetic networks, which can partly be extended to nonbinary networks. We introduce omnians, which we define as non-leaf vertices of which all children are reticulations. We then use this notion to obtain a new, simpler characterization of binary tree-based phylogenetic networks. We show that a binary phylogenetic network is tree-based if and only if every subset S of its omnians has at least |S| different children. We use this to derive, in an alternative (independently discovered) way, the characterization of binary tree-based networks in terms of zig-zag paths [9] and a new matching-based algorithm for deciding whether a given binary network is tree-based. We also show that every binary network with at most two reticulations is tree-based and give a new sufficient condition for a binary network to be tree-based. We then proceed to nonbinary networks. We show that our characterization of binary tree-based phylogenetic networks in terms of omnians can easily be generalized to the nonbinary case. We then obtain the first polynomial-time algorithm for deciding whether a nonbinary phylogenetic network is tree-based. Additionally, we show a simple counter example, showing that the characterization based on zig-zag paths can not be used to characterize nonbinary tree-based networks. However, we also show that nonbinary strictly-tree-based phylogenetic networks can be characterized using zig-zag paths. Consequently, also for this class of networks it can be decided in polynomial time whether a given network belongs to the class. We also discuss “stable” phylognetic networks [19], in which for each reticulation r there exists some leaf x such that all paths from the root to x go through r. We show that, although all binary stable phylogenetic networks are tree-based, this is not always the case for nonbinary networks. This paper is organized as follows. We first give the definitions and new results for binary networks in Section 2, then the definitions and results for nonbinary networks in Section 3. Examples of how these results can be applied to real, biological, nonbinary phylogenetic networks are given in Section 4. We end with a discussion in Section 5. 2 B INARY PHYLOGENETIC NETWORKS 2.1 Preliminaries First, some essential concepts around binary phylogenetic networks will be explained. Phylogenetic networks contain vertices and directed edges. Directed edges will be called arcs from now on. 3 Definition 1. A (rooted) binary phylogenetic network is a directed acyclic graph N = (V, A), which contains a single root with indegree 0 and outdegree 1 or 2 and may in addition contain the following types of vertices: • • • vertices with outdegree 0, called leaves, which are labelled; vertices with indegree 2 and outdegree 1, called reticulations; vertices with indegree 1 and outdegree 2, called tree-vertices. An example of a binary phylogenetic network is given in Figure 1, in which leaves are coloured blue and reticulations are indicated with a pink shading around the nodes. A (rooted) binary phylogenetic tree is a binary phylogenetic network that contains no reticulations. Although every arc is drawn without arrow head, they are all directed to the lowest vertex. This is the case throughout the paper, unless explicitly mentioned otherwise. Root y x c a b Fig. 1. An example of a binary phylogenetic network with leaf labels a, b and c, which can e.g. represent three present-day species, and omnians x and y . Take (u, v) = a ∈ A, an arc from vertex u to v . Then, a is called an outgoing arc of u and an incoming arc of v . Vertex u is a parent of v and v is called a child of u. If there is also an arc (u, w) ∈ A, then vertex w and v have a joint parent, so w and v are called siblings. When a non-leaf vertex z has only reticulations as children, then z is called an omnian. For example in Figure 1, vertices x and y are omnians, since both children of these vertices are reticulations. Vertices can be omnian and reticulation at the same time, see e.g. vertices u and v in Figure 3. Because of the importance of omnians, which will become clear later on in the paper, we always use square nodes for omnians and circular nodes for all other vertices. Definition 2. A binary phylogenetic network N is tree-based with base-tree T , when N can be obtained from T via the following steps: (i) (ii) (iii) Add vertices to the arcs of T . These vertices, called attachment points, have in- and outdegree 1. Add arcs, called linking arcs, between pairs of attachments points, so that N remains binary and acyclic. Suppress every attachment point that is not incident to a linking arc. Note in particular that it is not allowed to create multiple linking arcs between the same pair of attachment points since N is required to be a binary phylogenetic network. A binary phylogenetic network is tree-based if it is tree-based with base-tree T for some binary phylogenetic tree T . An example of the procedure is displayed in Figure 2. An example of a binary network that is not tree-based is given in Figure 3. A rooted spanning tree τ of a phylogenetic network N is a subgraph of N that is a rooted tree and contains all vertices (and a subset of the arcs) of N . A dummy leaf of a rooted spanning tree τ is a vertex that is not a leaf in network N , but is a leaf in τ . Hence, a binary phylogenetic network is tree-based if and only if it has a rooted spanning tree without dummy leaves. We will make heavy use of the following bipartite graph. Let N = (V, A) be a binary phylogenetic network. The bipartite graph associated to N is the bipartite graph B = (U ∪ R, E) containing a vertex vo ∈ U for each v ∈ V that is an omnian, a vertex wr ∈ R for each w ∈ V that is a reticulation, and an edge {vo , wr } ∈ E for each (v, w) ∈ A with v and omnian and w a reticulation. Hence, for a vertex v ∈ V that is a reticulation and an omnian, there is a vertex vo in U as well as a vertex vr in R. For ease of notation, we will omit the subscripts for now on and refer to vo and vr simply as v . An example is given in Figure 4. Let N = (V, A) be a binary phylogenetic network. An antichain is a set of vertices K ⊆ V for which there is no directed path from any vertex in K to any other vertex in K . Network N satisfies the antichainto-leaf property if for every antichain in N there exists a path from every vertex in K to a leaf, so that these paths are arc-disjoint. Which means, for example, that if there is an antichain of three vertices and there are only two leaves in the network, the network does clearly not satisfy the antichain-to-leaf property. 4 a c b a (a) (Base-)tree T a c b a (b) Attachment points added c (c) Linking arcs added c a c b b b (e) Redrawn as the network from Figure 1 (d) Attachment points suppressed Fig. 2. From phylogenetic tree to phyogenetic network in steps (a) to (e), which shows that the network from Figure 1 is tree-based. α1 α2 u i a x j v c b Fig. 3. An example of a non-tree-based binary phylogenetic network. Because arcs i and j are the only outgoing arcs of vertices u and v respectively, they would both have to be present in the base-tree. However, vertex x would then have two incoming arcs in the base-tree, which is not allowed. An example of an antichain can be seen in Figure 3, where vertices α1 and α2 form an antichain. The network does not satisfy the antichain-to-leaf property, because when we look at the antichain formed by vertices u and v , there are no arc-disjoint paths to leaves. A vertex v is called stable if there exists a leaf l for which every path from the root to l passes through v . A network is called stable if every reticulation is stable. Let G = (V, E) be a graph. If v, w ∈ V so that (v, w) ∈ E , then w is a neighbour of v . For a set S ⊆ V , the neighbours of S are denoted by Γ(S). A matching M ⊆ E is a set of edges so that no vertex v ∈ V is incident with more than one edge in M . A maximal path in G is a path that is not contained in a larger path. The following known results will be useful. Proposition 2.1. [7] Consider a binary phylogenetic network N over leaf set X. (i) (ii) If the parents of each reticulation of N are tree-vertices, then N is tree-based. If N has a reticulation whose parents are both reticulations, then N is not tree-based. Proposition 2.2. [19] In a stable binary phylogenetic network N , the child and the parents of each reticulation are tree-vertices. The following observation follows directly from the previous two propositions. Corollary 2.3. Every binary stable phylogenetic network is tree-based. 5 2.2 Results The following theorem will be used to obtain a simple graph-theoretic characterization of binary tree-based phylogenetic networks. Theorem 2.4. Let N be a binary phylogenetic network and B = (U ∪ R, E) the bipartite graph associated to N . Network N is tree-based if and only if there exists a matching M in B with |M | = |U |. Proof. Assume there exists a matching M in B with |M | = |U |, i.e., all omnians are covered by M . Construct a set A of arcs as follows: add the outgoing arc of every reticulation and the incoming arc of all tree-vertices to A. Additionally, for each edge of M , add the corresponding arc of N to A, if it has not yet been added. For every reticulation that has not yet been covered, add one of its incomming arcs to A, arbitrarily. The tree T , consisting of all vertices of N and the set of arcs A, is a rooted spanning tree, because there is precisely one incoming arc of every vertex contained in T . Moreover, there are no dummy leaves, because U is covered by M . Hence, it follows that N is tree-based. Now, assume that N is tree-based with base-tree T . Colour every edge of B that corresponds to an arc in T . When an omnian has outdegree 2 and both outgoing arcs are contained in T , decolourize one of the two corresponding edges of B , arbitrarily. Hence, each vertex of U is incident to at most one coloured edge. Since T is a rooted tree, it contains at most one incoming arc of each reticulation. Hence, also each vertex of R is incident to at most one coloured edge. So the coloured edges of B form a matching M . Because T is a base-tree, there are no dummy leaves, and so all omnians are covered by M . This theorem can be used to verify whether a binary phylogenetic network N is tree-based or not in polynomial time, using an algorithm for maximum cardinality bipartite matching (see e.g. [20]). We will look at an example of a binary phylogenetic network N and the bipartite graph B = (U ∪ R, E) associated to N in Figure 4. Since there exists a matching, which is coloured blue and dash-dotted in Figure 4(b), that covers U , the binary phylogenetic network in Figure 4(a) is tree-based. A base-tree T of network N can be seen in Figure 5, where the arcs that correspond to edges of the matching are dash-dotted and linking-arcs are dashed. U R y y v z y z q a z x x c b d q v (a) A rooted binary phylogenetic network N . (b) The bipartite graph associated to N , with a matching covering U indicated by dash-dotted lines. Fig. 4. Using Theorem 2.4 to show that this is a tree-based binary phylogenetic network. v y q a z x b c d a b c d Fig. 5. A base-tree T of the network in Figure 4(a). Since a binary phylogenetic network that contains no reticulations is a rooted tree, such a network is clearly tree-based. The next theorem shows that this is still the case for all networks with one or two reticulations. On the other hand, Figure 6 shows a part of a network N that contains three reticulations and is not tree-based. So it follows that not all networks with three reticulations are tree-based. 6 Theorem 2.5. If a binary phylogenetic network N contains at most two reticulations, then N is tree-based. Proof. If N contains only one reticulation, then both parents of this reticulation are tree-vertices and with Proposition 2.1 it follows that N is tree-based. Now consider the case that N contains exactly two reticulations x and y . If x and y do not have a parentchild relation, then both parents of x and y are tree-vertices and it follows from Proposition 2.1 that N is tree-based. Now suppose that x is the parent of y . There are two possibilities, x and y having a joint parent and x and y having different parents, both displayed in Figure 7. Fig. 6. Local situation in a network that has three reticulations and is not tree-based. z z w x x y y N1 N2 (a) (b) Fig. 7. The two possibilities that can occur when reticulation x is the parent of reticulation y , used in the proof of Theorem 2.5. From partial networks N1 and N2 of Figure 7 we create two bipartite graphs, A = (U ∪ R, E) associated to N1 and B = (U ∪ R, E) associated to N2 , that are displayed in Figure 8. U R U z x x y R x x (a) Bipartite graph A associated to network N1 . y (b) Bipartite graph B associated to network N2 . Fig. 8. The bipartite graphs associated to the partial networks in Figure 7. In both cases in Figure 8 it is easy to see that there is a matching that covers U . It then follows from Theorem 2.4 that N is tree-based. To obtain a simple characterization of binary tree-based networks, we will use Hall’s Theorem, which is stated below. Theorem 2.6 (Hall’s Theorem [21]). Let B = (U ∪ W, E) be a bipartite graph. There exists a matching in B that covers U if and only if, for every U1 ⊆ U , the number of different neighbours of the vertices in U1 is at least |U1 |. Consider Hall’s Theorem and Theorem 2.4. Combining those two theorems gives a characterization for a binary phylogenetic network to be tree-based. Corollary 2.7. Let N be a binary phylogenetic network and U the set of all omnians of N . Then N is tree-based if and only if for all S ⊆ U the number of different children of the vertices in S is greater than or equal to the number of omnians in S . 7 Proof. Follows directly from Theorem 2.4 and Theorem 2.6. An example of how this theorem and corollary can be applied is given in Figure 9, where an example of a binary phylogenetic network N is displayed in (a) and the bipartite graph B = (U ∪ R, E) associated to N in (b). Omnians are indicated as square nodes and reticulations are marked with a pink shading around the nodes. From the bipartite graph in Figure 9 it follows with Hall’s Theorem, with S = U , that there exists no matching in B that covers U . Therefore, with Theorem 2.4 it follows that N in Figure 9(a) is not treebased. Indeed, we can directly see in N that the omians in S = {a, i, h, f, g} have only four different children {b, c, d, e} (note that, in general, the set S and the set of children of vertices in S do not have to be disjoint). Hence this network is not tree-based. a i b p h x c q g f U f a a b c i y d e h e g f d w R d Fig. 9. Example of a non-tree-based binary phylogenetic network N and the bipartite graph B associated to N . In a previous article, the following necessary condition for a network to be tree-based was found. Proposition 2.8. [7] If a binary phylogenetic network over leaf set X is tree-based, then it satisfies the antichain-toleaf property. On the other hand, if a network is not tree-based, it can still satisfy the antichain-to-leaf property, as shown by the example from [7] in Figure 10. However, it is difficult to see in this network what is going on. Therefore, we show in Figure 11 two examples of local structures that cause a network to be non-tree-based. The example in Figure 11(a) is similar to the local structure that causes the network of Figure 10 not to be tree-based, which can be checked using Corollary 2.7. At first sight, it might look like networks containing the local structures in Figure 11 cannot satisfy the antichain-to-leaf property. However, in Figure 12 we show that it is indeed possible that they do satisfy this property. Although it was already known that networks that satisfy the antichain-to-leaf property are not necessarily tree-based, these figures illuminate why this is possible. Looking at the examples in Figure 11, we see that a pattern has emerged. In (a) the pattern is marked dashed in green. Starting at vertex o1 and ending at vertex o5 , we see a zigzag starting with an omnian, alternating between reticulations and omnians, eventually ending with an omnian. The last omnian in the pattern can be a reticulation that is already part of the path, as can be seen in Figure 11(b). The next theorem shows that every binary phylogenetic network that is not tree-based contains a local structure as in the examples in Figure 11. Theorem 2.9. Let N be a binary phylogenetic network and B = (U ∪ R, E) the bipartite graph associated to N . Network N is tree-based if and only if B contains no maximal path which starts and ends in U . Proof. Notice that every vertex in B is of degree at most 2. Therefore, B is a disjoint union of paths and cycles. Hence, for each connected component B ′ = (U ′ ∪ R′ , E ′ ) of B , there are four possible topologies: 8 o2 o1 r1 r2 o3 Fig. 10. Not tree-based binary phylogenetic network satisfying the antichain-to-leaf property [7]. o2 o1 o3 r1 = o4 o1 o2 r1 o3 r2 o4 r3 r2 o5 r4 (a) r3 (b) Fig. 11. Examples of local structures of binary phylogenetic networks that are not tree-based. i) ii) iii) iv) A maximal path that begins and ends in R. A maximal path that begins in U and ends in R. A maximal path that begins and ends in U . A circuit. i) All vertices in R are of degree at most 2. Because the maximal path begins and ends in R, all vertices in U ′ have degree 2. Let S ⊆ U ′ . Recall that Γ(S) denotes the set of neighbours of vertices in S . The number of edges incident to S = 2 |S| ≤ the number of edges incident to Γ(S) ≤ 2 |Γ(S)|. Therefore, |S| ≤ |Γ(S)| for all S ⊆ U ′ . It follows from Hall’s Theorem that there exists a matching in B ′ that covers U ′ . ii) All vertices in R are of degree at most 2. All vertices in U ′ have degree 2, except for the omnian o1 where the maximal path begins. Let S ⊆ U ′ . Consider the subgraph of B ′ induced by S ∪ Γ(S). It consists of paths. First consider such a path that does not contain o1 . Then the path must begin and end in R, because every omnian in S except for o1 has two neighbours in Γ(S). Hence, the paths contain more reticulations than omnians. Now consider a path that contains o1 . Then it is a path that begins in U and ends in R. Hence, it contains as many omnians as reticulations. It follows that all paths together, i.e. the subgraph of B ′ induced by S ∪ Γ(S), contains more reticulations than omnians, so |S| ≤ |Γ(S)|. Again, since this holds for all S ⊆ U ′ . It follows from Hall’s Theorem that there exists a matching in B ′ that covers U ′ . iii) Let S = U ′ . Then |S| = |Γ(S)|+1. Hence, it follows from Hall’s Theorem that there does not exist a matching in B that covers U . iv) All vertices in B are of degree 2 and it follows in the same way as in case i) that |S| ≤ |Γ(S)| for all S ⊆ U ′ and hence that there exists a matching in B ′ that covers U ′ . 9 (a) (b) Fig. 12. Local structures of binary phylogenetic networks that satisfy the antichain-to-leaf property but are not tree-based. Hence, there exists a matching in B that covers U precisely if there is no maximal path that starts and ends in U . The theorem now follows from Theorem 2.4. Proposition 2.1 showed that a binary phylogenetic network is tree-based if for each reticulation both parents are tree-vertices and not tree-based if for at least one reticulation both parents are reticulations. However, in the situation in which a reticulation in N has one parent that is a reticulation and the other a tree-vertex it is not immediately clear if N is tree-based or not. The next corollary shows that such networks are tree-based if an additional condition is fulfilled. Corollary 2.10. If for every reticulation r in a binary phylogenetic network N either (i) (ii) both parents of r are tree-vertices; or one parent of r is a tree-vertex and the sibling of r is a tree-vertex or a leaf, then N is tree-based. Proof. Let B = (U ∪ R, E) be the bipartite graph associated to N . Since all vertices in B have degree at most two, each connected component of B is a path or a cycle. Assume that there exists a maximal path P that starts and ends in U . Let u ∈ U be the first vertex on this path. Since u is an omnian with only one child, it is also a reticulation. Let r be the only child of u. Since one parent of r is a reticulation, the other parent p of r must be a tree-vertex and the sibling of r also a tree-vertex or a leaf. However, that means that p is not an omnian. Hence, path P ends in r, which is a contradiction to the assumption that P ended in U . It follows that there is no path that starts and ends in U . By Theorem 2.4 it follows that N is tree-based. The following characterization of binary tree-based phylogenetic networks follows directly from Theorem 2.9, thus providing an alternative proof of this characterization which was independently discovered (in a slightly different form) by Louxin Zhang [9]. See Figure 11 for examples. We call a sequence (u1 , v1 , . . . , uk , vk , uk+1 ) of 2k + 1 vertices (k ≥ 1) of a network N a zig-zag path if vi is the child of ui and ui+1 for i = 1, . . . , k . Corollary 2.11. A binary phylogenetic network is tree-based if and only if it contains no zig-zag path (o1 , r1 , . . . , ok , rk , ok+1 ), with k ≥ 1, in which r1 , . . . , rk are reticulations, o1 , . . . , ok+1 are omnians and o1 and ok+1 are reticulations as well as omninans. 3 N ONBINARY PHYLOGENETIC NETWORKS 3.1 Preliminaries We start with the definition of nonbinary networks.1 An example is given in Figure 13. 1. Whenever we refer to nonbinary, we mean “not-necessarily-binary”. 10 Definition 3. A (rooted) nonbinary phylogenetic network is a directed, acyclic graph N = (V, A) that contains a single root with indegree 0 and outdegree 1 or more and may additionally contain the following types of vertices: • • • vertices with indegree 1 and outdegree 0, called leaves (coloured blue in Figure 13), which are labelled; vertices with outdegree 1 and indegree 2 or more, called reticulations (marked in pink in Figure 13); vertices with indegree 1 and outdegree 2 or more, called tree-vertices. Root a b f g d e c Fig. 13. Example of a nonbinary phylogenetic network. A nonbinary phylogenetic tree is a nonbinary phylogenetic network without reticulations. We will consider two different variants of tree-basedness of nonbinary networks, which we name “treebased” and “strictly-tree-based”. Definition 4. A nonbinary phylogenetic network N is called tree-based with base-tree T , when N can be obtained from T via the following steps: (a) (b) (c) Add some vertices to arcs of T . These vertices, called attachment points, have in- and outdegree 1. Add arcs, called linking arcs, between pairs of attachments points and from tree-vertices to attachment points, so that N remains acyclic and so that attachment points have indegree or outdegree 1. Suppress every attachment point that is not incident to a linking arc. Definition 5. A nonbinary phylogenetic network N is called strictly tree-based with base-tree T , when N can be obtained from T via the following steps: (1) (2) Add some vertices to arcs in T . These vertices, called attachment points, have in- and outdegree 1. Add arcs, called linking arcs, between pairs of attachments points, so that N remains acyclic and so that exactly one linking arc is attached to each attachment point. A nonbinary phylogenetic network is tree-based if it is tree-based with base-tree T for some nonbinary phylogenetic tree T . Similarly, a nonbinary phylogenetic network is strictly tree-based if it is strictly tree-based with base-tree T for some nonbinary rooted phylogenetic tree T . The distinction between tree-based and strictly tree-based is illustrated by two examples in Figure 14. An example of a strictly-tree-based nonbinary network can be found in Figure 18(a). a b c d e (a) This network is not strictly tree-based because the linking arc is attached to a vertex of the base-tree, rather than to an attachment point, and this cannot be avoided. a b c d (b) This network is not strictly tree-based because two linking arcs are attached to the same attachment point, and this cannot be avoided. Fig. 14. Two nonbinary networks that are both tree-based but not strictly tree-based. The black solid lines indicate possible base-trees, while the dashed, grey lines are the linking arcs. The following observations are easily verified. 11 Observation 3.1. Let N be a nonbinary phylogenetic network. If N is strictly tree-based, then N is tree-based. If N and N ′ are nonbinary phylogenetic networks, then we say that N ′ is a refinement of N if N can be obtained from N ′ by contracting some of its edges. Observation 3.2. Let N be a nonbinary phylogenetic network. Then N is tree-based if and only if there exists a binary refinement of N that is tree-based. Any definitions from Section 2.1 that have not been mentioned in this section, are defined similarly as in the binary case. We first discuss nonbinary tree-based networks in Section 3.2 and then nonbinary strictly-tree-based networks in Section 3.3. 3.2 Nonbinary tree-based phylogenetic networks We will examine if some of the theorems from Section 2.2 hold for nonbinary phylogenetic networks as well. First, we look at te stability of networks. Proposition 3.3. A nonbinary stable network N has the following property: the child and the parents of every reticulation are tree-vertices. Proof. Can be shown similar to the proof of Proposition 2.2 [19]. Hence, this property holds also for nonbinary networks. Next, we will consider the following two questions. (i) (ii) Is every nonbinary stable phylogenetic network tree-based? (Corollary 2.3 in the binary case) For a nonbinary phylogenetic network N , is N tree-based if all parents of all reticulations of N are tree-vertices? (Proposition 2.1 in the binary case) There is one single example that answers both of the questions. The example, displayed in Figure 15, shows that the answer to both questions is “no”. These properties only hold in the binary case. Fig. 15. A nonbinary network that shows that the answer to Questions (i) and (ii) is negative. We will now show that Theorem 2.4 even holds in the nonbinary case. Theorem 3.4. Given a nonbinary phylogenetic network N and the bipartite graph B that is associated to N . Network N is tree-based if and only if there exists a matching M in B with |M | = |U |. Proof. If there exists a matching M in B with |M | = |U |, then it can be proved similarly as in the binary case (Theorem 2.4), that N is tree-based. Now assume that N is tree-based. Then it can be proved partially similar as in the binary case, that there exists a matching in B that covers all omnians. The only difference is that when an omnian has more than one outgoing arc contained in a base-tree T , that only one edge should be coloured and the rest should not be coloured in B . The rest of the proof is the same as in the proof of Theorem 2.4. This theorem directly leads to a polynomial-time algorithm for deciding if a network is tree-based, using one of the algorithms for maximum cardinality bipartite matching (see e.g. [20]). Corollary 3.5. There exists a polynomial-time algorithm that decides whether a given nonbinary phylogenetic network is tree-based or not. Consider Hall’s Theorem (Theorem 2.6) and Theorem 3.4. Combining those two theorems gives a characterization for nonbinary tree-based phylogenetic networks, similar to Corollary 2.7 in the binary case. 12 Corollary 3.6. Let N be a nonbinary phylogenetic network and U the set of all omnians of N . Then N is tree-based if and only if for all S ⊆ U the number of different children of the vertices in S is greater than or equal to the number of omnians in S . In Theorem 2.9 we showed that a binary network is tree-based if and only if the associated bipartite graph contains no maximal path which starts and ends in U . One might suspect that this also holds in the nonbinary case. We will look at a partial nonbinary phylogenetic network N , which is displayed in Figure 16(a), and the bipartite graph B that is associated to N , which is displayed in 16(b). A matching is drawn in B , which is coloured blue and dash-dotted in Figure 16(b). We see that in B there is a maximal path starting and ending in U : starting in b via f − c − g ending in d. Though in the binary case this would mean that N is not tree-based, we see in Figure 16(b) that there exists a matching that covers U . With Theorem 3.4 it follows that N is tree-based. Therefore, for a nonbinary phylogenetic network N and the bipartite graph B = (U ∪ R, E) associated to N , if there is a maximal path starting and ending in U , then N can still be tree-based. Consequently, also Corollary 3.9 does not hold in the nonbinary case. U R b b a b e c c d e d f g (a) The dash-dotted lines represent the matching in (b). d f g (b) A matching is B indicated in dash-dotted lines. Fig. 16. A partial nonbinary phylogenetic network and the bipartite graph B that is associated to N , showing that Theorem 2.9 does not hold in the nonbinary case. 3.3 Nonbinary strictly-tree-based phylogenetic networks Here we show that the characterization of binary tree-based phylogenetic networks in Corollary 3.9 can be extended to a characterization for nonbinary strictly-tree-based phylogenetic networks. We call vertices with outdegree greater than two multifurcations. In this case, we use a modified bipartite graph. Let N = (V, A) be a nonbinary phylogenetic network. The modified bipartite graph associated to N is the bipartite graph B ∗ = (U ∪ R, E), which is defined as follows. For each vertex v ∈ V of N that is an omnian with outdegree 2, we put a vertex vo in U . For each vertex w ∈ V of N that is a reticulation, we put a vertex wr in R. We put an edge {vo , wr } in E for each vo ∈ U and wr ∈ R with (v, w) ∈ A. Then, for each multifurcation u ∈ V of N that has k children that are reticulations w1 , . . . , wk , with k ≥ 1, we add k vertices u1 , . . . , uk to U and add edges {ui , wi r } for i = 1, . . . , k to E (with wir the reticulation in R corresponding to reticulation wi in V .). As with the previous bipartite graphs, we will omit the subscripts of the vertex labels and refer to vo , wr , ui simply as v, w and u, respectively. Examples are given in Figure 17 and 18. Note in particular that in B ∗ the set U contains not only omnians but also multifurcations that may have non-reticulate children. Using this modified bipartite graph, we can proceed in the same way as in the binary case. Theorem 3.7. Let N be a nonbinary phylogenetic network and B ∗ = (U ∪ R, E) the modified bipartite graph associated to N . Network N is strictly tree-based if and only if all reticulations of N have indegree 2 and there exists a matching M in B ∗ so that |U | = |M |. Proof. It is clear that N cannot be strictly tree-based if at least one of the reticulations has indegree greater than two, because no two linking arcs are allowed to attach to the same attachment point. Hence, we may assume from now on that all reticulations have indegree 2. First assume that N is strictly tree-based with base-tree T . Consider the set of edges E ′ of B ∗ that correspond to arcs of N that are contained in T (i.e., that are not linking arcs w.r.t. base-tree T ). For each multifurcation, each outgoing arc must be contained in T . Moreover, as in the binary case, for each omnian, 13 U b z y q z a x y x R q c d (a) The network from Figure 14(b), which is tree-based but not strictly tree-based. y (b) The modified bipartite graph B ∗ associated to the network in (a). Fig. 17. It is easy to see that the modified bipartite graph B ∗ associated to the nonbinary network in (a) has no matching that covers U . Hence, the network in (a) is not strictly tree-based. U x y a b z c d e f g (a) A strictly-tree-based nonbinary network. R x y x z (b) The modified bipartite graph B ∗ associated to the network in (a). Fig. 18. It is easy to see that the modified bipartite graph B ∗ associated to the nonbinary network in (a) has a matching that covers U . Hence, the network in (a) is strictly tree-based. at least one outgoing arc must be contained in T . Hence, the set E ′ of edges touches all vertices in U . Each vertex r ∈ R has exactly one incident edge in E ′ because T is a tree. For each vertex u ∈ U that has two incident edges in E ′ , remove one of them, arbitrarily. This gives a new set of edges M ⊆ E ′ , which is a matching in B ∗ with |M | = |U |. Now assume that there exists such a matching M . As in the binary case, we construct a set A of arcs by adding the outgoing arc of every reticulation, the incoming arc of every tree-vertex, every arc corresponding to an edge in M (if it has not yet been added) and for every reticulation that has not yet been covered, one of its incomming arcs, arbitrarily. Consider the tree T consisting of all vertices of N and the set of arcs A. As in the binary case, there are no dummy leaves in T because matching M covers all omnians of N . Moreover, for all multifurcations of N , all outgoing arcs are in T because matching M contains all corresponding edges of B ∗ (since they are incident to a degree-1 vertex). Hence, each arc of N that is not in A connects an outdegree-2 vertex with an indegree-2 vertex. These are the linking arcs, and their endpoints the attachment points. Hence, each linking arc is attached to two attachment points, and no two linking arcs are attached to the same attachment point. Hence, N is strictly tree-based. From the above theorem it follows directly that it can be decided in polynomial time whether a nonbinary network is strictly tree-based, using one of the algorithms for maximum cardinality bipartite matching (see e.g. [20]). Theorem 3.8. Let N be a nonbinary phylogenetic network and B ∗ = (U ∪ R, E) the modified bipartite graph associated to N . Network N is strictly tree-based if and only if all reticulations in N have indegree 2 and B ∗ contains no maximal path which starts and ends in U . Proof. It is again clear that N cannot be strictly tree-based if at least one of the reticulations has indegree greater than two. If all reticulations have indegree 2, then all vertices r ∈ R have degree at most two in B ∗ . Moreover, all vertices u ∈ U have degree at most two in B ∗ because each multifurcation of N has been split into multiple vertices in U with one incident edge each. Hence, bipartite graph B ∗ has maximum degree 2 and we can proceed as in the proof of Theorem 2.9. The following characterization in terms of zig-zag paths follows directly from the theorem above. Recall that we call a sequence (u1 , v1 , . . . , uk , vk , uk+1 ) of 2k + 1 vertices (k ≥ 1) of a network N a zig-zag path if vi is the child of ui and ui+1 for i = 1, . . . , k . 14 Corollary 3.9. A nonbinary phylogenetic network N is strictly tree-based if and only if every reticulation has indegree 2 and there is no zig-zag path (s, r1 , o1 , r2 , . . . , ok−1 , rk , t), with k ≥ 1, in which r1 , . . . , rk are reticulations, o1 , . . . , ok−1 are omnians and each of s and t is either a multifurcation or a reticulation and an omnian. 4 A PPLICATION TO BIOLOGICAL PHYLOGENETIC NETWORKS To show how our theorems can be applied to real networks, we discuss two examples of biological phylogenetic networks in this section. Since both networks are nonbinary, previously known theorems do not apply to them. In the following two subsections, we will show how one can use the theorems from this paper to determine whether each of these networks is (strictly) tree-based or not. 4.1 Viola network A nonbinary phylogenetic network for violets from the Viola genus, based on the network published in [15], is displayed in Figure 19. The Viola genus contains about 600 species, which are divided over sixteen different sections. The leaves of the network in Figure 19 represent these sections, relabelled as follows: a = Sect. nov. A, b = Sect. nov. B, c = Melanium, d = Delphiniopsis, e = Sclerosium, f = Viola s.str., g = Plagiostigma, h = Nosphinium s.lat., i = Xylinosium, j = Chamaemelanium, k = Chilenium, l = Erpetion, m = Rubellium, n = Tridens, o = Leptidium, p = Andinium. The 21 reticulations in the network (indicated with pink shading around the nodes) represent polyploidisations. U m p s t x y u i j c a b d w o n v x z e k l f g s z v r r s R u v w y z h (a) A nonbinary phylogenetic network for all sixteen sections of the Viola genus. (b) The bipartite graph associated to the network in (a). Fig. 19. (a) A nonbinary phylogenetic network for all sixteen sections of the Viola genus, based on the network published in [15] and (b) the associated bipartite graph. The network in (a) contains a zig-zag path (s, u, t) from which one can conclude by Corollary 3.9 that the network is not strictly tree-based. Moreover, it follows from Corollary 3.6 that the network is not even treebased, because the three omnians v, x and z together only have two children. In the associated bipartite graph in (b), the vertices from U (the omnians) and the vertices from R (the reticulations) are drawn in the same order (from top to bottom) as they appear in the network (from left to right). Since there exists no matching that covers all vertices of U , the Viola network is not tree-based. First we note that the network is clearly not binary because the nodes labelled r and t are multifurcations. Next, we show how Corollary 3.6 can be used to conclude that this network is not tree-based. Consider the three omnians labelled v , x and z (as before, omnians are indicated with square nodes). Then the total number of different children of these three omnians is two: w and n. Since the number of children is smaller than the number of considered omnians, it follows from Corollary 3.6 that the network is not tree-based. Since the network is not tree-based, it can certainly not be strictly tree-based. To see this directly, we can apply Corollary 3.9. The path (s, u, t) is a zig-zag path starting at a reticulation that is also an omnian (s), zig-zagging via a reticulation (u), and ending at a multifurcation (t). The existence of such a path proves, by Corollary 3.9, that the network is not strictly tree-based. 15 To determine whether a network is tree-based or not, trying all subsets of the omnians is clearly not an efficient method. However, we can do this efficiently if we construct the bipartite graph associated to the network. For this example, the associated bipartite graph is displayed in Figure 19(b). One can decide whether the network is tree-based by determining whether this bipartite graph has a matching that covers all vertices in U , by Theorem 3.4. There exist simple polynomial-time algorithms for this task, see e.g. [20]. In this case, no such matching exists and hence the network is not tree-based. Similarly, we can find out efficiently whether a network is strictly tree-based by constructing the modified bipartite graph and applying Theorem 3.7. 4.2 The origin of Eukaryotes The second example we discuss concerns the origin of Eukaryotes, which is displayed schematically in the phylogenetic network in Figure 20. This figure is based on the network in [16] and has been adapted to make it conform to the definition of phylogenetic networks used in this paper. The leaves of the network have been labelled arbitrarily by labels x1 , . . . , x41 . Moreover, where the original network showed different prokaryotic genomes as differently colored lines inside the lineages, we show only the different lineages as black lines in Figure 20. The six reticulations represent endosymbiosis; the merging of different prokaryotic genomes into a single lineage (present in the same cell). Horizontal gene transfer events between the lineages are not included in the network. The network is clearly nonbinary since the common ancestors of the Archaebacteria and the Eubacteria (the children of the root) are both multifurcations and, in addition, the child of the second reticulation from the top is also a multifurcation. Archaebacteria Eubacteria x1 x2 x40 x41 x3 x4 x5 x6 x34 x35 x36 x39 x37 x38 x7 x8 x11 x12 x9 x10 Eukaryotes x30 x31 x32 x33 x20 x21 x24 x18 x19 x22 x23 x15 x13 x14 x16 x17 x25 x26 x29 x27 x28 Fig. 20. A nonbinary phylogenetic network schematically illustrating the origin of Eukaryotes from Archaebacteria and Eubacteria, created by adapting the network published in [16]. Taxa have been labelled x1 , . . . , x41 arbitrarily. The six reticulations represent the merging of different prokaryotic genomes into a single lineage. Using Corollary 3.6, it can be easily seen that the network is tree-based, since it has no omnians. Moreover, it follows from Corollary 3.9 that the network is even strictly tree-based. As usual, the reticulations are indicated in the figure by pink shading around the nodes. There are no omnians in this network since each non-leaf vertex has at least one non-reticulate child. Therefore, it follows 16 directly from Corollary 3.6 that the network is tree-based. Moreover, we can use Corollary 3.9 to determine whether the network is strictly tree-based. Since all reticulations have indegree-2, there are no omnians, and there is no zig-zag path (multifucation – reticulation – multifurcation), we can conclude directly from Corollary 3.9 that the network is strictly tree-based. This means that the network can be seen as a base-tree augmented with linking-arcs (representing endosymbiosis events) between branches of the base-tree. 5 D ISCUSSION As this is the first paper on tree-basedness for nonbinary phylogenetic networks, we end with a short discussion of our definitions and results. There are different ways to extend the concept of tree-based networks to the nonbinary case. The most general variant allows linking arcs to be attached to vertices of the base-tree as well as to “attachment points” that subdivide the edges of the base-tree, and also allows several linking arcs to attach to the same vertex or attachment point. This can lead to vertices with more than two incoming arcs, and to vertices with more than two outgoing arcs, even if the base-tree is binary. Intuitively, this means that the non-binarity of the network can come both from the base-tree as well as from the way the linking-arcs are attached. Networks that can be formed this way we named tree-based. A second possibility is to look at all binary refinements of a nonbinary network and to check if at least one of them is a tree-based binary network, using the definition of Francis and Steel. It turns out that this definition is equivalent to the previous one. Thus, a nonbinary network is tree-based precisely if it has at least one binary refinement that is tree-based. A more restrictive variant allows the non-binarity of the network only to originate from the base-tree. In this case, linking arcs are only allowed to be attached to attachment points that subdivide the edges of the base-tree, and not to the original vertices of the base-tree. Moreover, no two linking arcs can be attached to the same attachment point. We named the networks that can be formed this way strictly tree-based. This name is used to express that this definition is more restrictive than the previous ones. In particular, all strictly-tree-based networks are semi-binary, meaning that reticulations have exactly two incoming arcs. Of course, there are more possibilities. One could, for example, allow linking arcs to be attached only to attachment points, but still allow different linking arcs to attach to the same attachment point. However, we have not studied such variants as the definitions above seem the most natural ones. We have given a complete characterization of tree-based nonbinary phylogenetic networks in terms of “omnians”, i.e. non-leaf vertices of which all children are reticulations. Moreover, this has also led to a new characterization for tree-based binary networks, which is, in our opinion, even simpler than the previous characterization in terms of “zig-zag paths” [9]. Moreover, we have used our results to derive a characterization in terms of zig-zag paths, similar to the one in [9], for tree-based binary networks and for strictly-tree-based nonbinary networks. We have also shown that zig-zag paths can not be used in the same way to characterize tree-based nonbinary networks. On the algorithmic side, we have shown that it can be decided in polynomial time whether a given nonbinary phylogenetic network is tree-based and whether it is strictly tree-based. We used a different approach from the one by Francis and Steel [7] and Zhang [9], thus also obtaining a new way to decide if a binary network is tree-based. Moreover, we believe that our new approach for binary tree-based networks can be very useful when trying to solve some of the open problems mentioned by Francis and Steel [7]. In particular, is it possible to calculate how many base-trees a given (binary or nonbinary) tree-based network has? In [22], it was shown how the method from this paper can be used to derive an upper bound on this number. Another question by Francis and Steel was whether one can decide in polynomial time if a given binary phylogenetic network N is tree-based with a given tree T as base-tree. However, this problem was very recently shown to be NP-hard [23]. Finally, we have shown how our theorems can be applied to real phylogenetic networks by presenting two biological examples. We have shown that the first considered network, displaying the evolutionary history of the Viola genus, is not tree-based. This means that we cannot see this evolutionary history as a tree-like process augmented with horizontal events. The numerous polyploidisations make this evolutionary history inherently network-like. The second network that we considered, showing the origin of Eukaryotes from Eubacterial and Archaebacterial genomes, turned out to be tree-based (and strictly tree-based). Hence, this evolutionary history can indeed be explained by a tree-like process augmented with horizontal events. However, note that this network is a high-level schematic depiction of the origin of Eukaryotes and the actual evolutionary history is much more complex, especially due to numerous gene transfer events. Moreover, the purpose of these examples is not to draw biological conclusions regarding these evolutionary histories, but to illustrate how our theorems can be applied to real phylogenetic networks. Since both these networks are nonbinary, previously-known theorems could not be applied to them. Moreover, the second example 17 showed that, even though the network looks rather complex, the concept of omnians made it very easy to conclude that it is in fact tree-based. ACKNOWLEDGMENTS The authors would like to thank Mike Steel for interesting and useful discussions on the topic of this paper and the anonymous reviewers for their constructive comments. R EFERENCES [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23] D. H. Huson, R. Rupp, and C. Scornavacca, Phylogenetic networks: concepts, algorithms and applications. Cambridge University Press, 2010. E. Bapteste, L. van Iersel, A. Janke, S. Kelchner, S. Kelk, J. O. McInerney, D. A. Morrison, L. Nakhleh, M. Steel, L. Stougie, and J. Whitfield, “Networks: expanding evolutionary thinking,” Trends in Genetics, vol. 29, no. 8, pp. 439 – 441, 2013. T. Dagan and W. Martin, “The tree of one percent,” Genome Biol, vol. 7, no. 10, p. 118, 2006. W. F. Martin, “Early evolution without a tree of life,” Biol Direct, vol. 6, p. 36, 2011. W. F. Doolittle and E. Bapteste, “Pattern pluralism and the tree of life hypothesis,” Proceedings of the National Academy of Sciences, vol. 104, no. 7, pp. 2043–2049, 2007. E. Corel, P. Lopez, R. Mheust, and E. Bapteste, “Network-thinking: Graphs to analyze microbial complexity and evolution,” Trends in Microbiology, 2016, http://dx.doi.org/10.1016/j.tim.2015.12.003. A. R. Francis and M. Steel, “Which phylogenetic networks are merely trees with additional arcs?” Systematic Biology, vol. 64, no. 5, pp. 768–777, 2015. L. van Iersel, “Different topological restrictions of rooted phylogenetic networks. Which make biological sense?” 2013, http://phylonetworks.blogspot.nl/2013/03/different-topological-restrictions-of.html. L. Zhang, “On tree based phylogenetic networks,” arXiv:1509.01663 [q-bio.PE], 2015. T. Marcussen, K. S. Jakobsen, J. Danihelka, H. E. Ballard, K. Blaxland, A. K. Brysting, and B. Oxelman, “Inferring species networks from gene trees in high-polyploid North American and Hawaiian violets (Viola, Violaceae),” Systematic Biology, vol. 61, no. 1, pp. 107–126, 2012. J. Brassac and F. R. Blattner, “Species-level phylogeny and polyploid relationships in Hordeum (Poaceae) inferred by nextgeneration sequencing and in silico cloning of multiple nuclear loci,” Systematic biology, vol. 64, no. 5, pp. 792–808, 2015. T. Thiergart, G. Landan, M. Schenk, T. Dagan, and W. F. Martin, “An evolutionary network of genes present in the eukaryote common ancestor polls genomes on eukaryotic and mitochondrial origin,” Genome Biology and Evolution, vol. 4, no. 4, pp. 466–485, 2012. S. Patel, R. T. Kimball, and E. L. Braun, “Error in phylogenetic estimation for bushes in the tree of life,” Journal of Phylogenetics & Evolutionary Biology, vol. 1:110, 2013. H. Philippe, H. Brinkmann, D. V. Lavrov, D. T. J. Littlewood, M. Manuel, G. Wörheide, and D. Baurain, “Resolving difficult phylogenetic questions: why more sequences are not enough,” PLoS Biol, vol. 9, no. 3, p. e1000602, 2011. T. Marcussen, L. Heier, A. K. Brysting, B. Oxelman, and K. S. Jakobsen, “From gene trees to a dated allopolyploid network: insights from the angiosperm genus Viola (Violaceae),” Systematic biology, vol. 64, no. 1, pp. 84–101, 2015. W. Martin, “Mosaic bacterial chromosomes: a challenge en route to a tree of genomes,” Bioessays, vol. 21, no. 2, pp. 99–104, 1999. G. J. Smith, D. Vijaykrishna, J. Bahl, S. J. Lycett, M. Worobey, O. G. Pybus, S. K. Ma, C. L. Cheung, J. Raghwani, S. Bhatt et al., “Origins and evolutionary genomics of the 2009 swine-origin H1N1 influenza A epidemic,” Nature, vol. 459, no. 7250, pp. 1122–1125, 2009. S. Koblmüller, N. Duftner, K. M. Sefc, M. Aibara, M. Stipacek, M. Blanc, B. Egger, and C. Sturmbauer, “Reticulate phylogeny of gastropod-shell-breeding cichlids from lake Tanganyika–the result of repeated introgressive hybridization,” BMC Evolutionary Biology, vol. 7, no. 1, p. 7, 2007. A. Gunawan, B. DasGupta, and L. Zhang, “Locating a tree in a reticulation-visible network in cubic time,” RECOMB 2016, to appear. arXiv:1507.02119. A. Schrijver, Combinatorial optimization: polyhedra and efficiency. Springer, 2003. P. Hall, “On representatives of subsets,” J. London Math. Soc, vol. 10, no. 1, pp. 26–30, 1935. L. Jetten, “Characterising tree-based phylogenetic networks,” 2015, bachelor thesis, TU Delft repository uuid:fda2636d0ed5-4dd2-bacf-8abbbad8994e. M. Anaya, O. Anipchenko-Ulaj, A. Ashfaq, J. Chiu, M. Kaiser, M. S. Ohsawa, M. Owen, E. Pavlechko, K. S. John, S. Suleria et al., “On determining if tree-based networks contain fixed trees,” arXiv preprint arXiv:1602.02739, 2016.
8cs.DS
Sparse arrays of signatures for online character recognition Benjamin Graham arXiv:1308.0371v2 [cs.CV] 1 Dec 2013 Dept of Statistics, University of Warwick, CV4 7AL, UK [email protected] December 8, 2013 Abstract In mathematics the signature of a path is a collection of iterated integrals, commonly used for solving differential equations. We show that the path signature, used as a set of features for consumption by a convolutional neural network (CNN), improves the accuracy of online character recognition—that is the task of reading characters represented as a collection of paths. Using datasets of letters, numbers, Assamese and Chinese characters, we show that the first, second, and even the third iterated integrals contain useful information for consumption by a CNN. On the CASIA-OLHWDB1.1 3755 Chinese character dataset, our approach gave a test error of 3.58%, compared with 5.61%[4] for a traditional CNN. A CNN trained on the CASIA-OLHWDB1.0-1.2 datasets won the ICDAR2013 Online Isolated Chinese Character recognition competition. Computationally, we have developed a sparse CNN implementation that make it practical to train CNNs with many layers of maxpooling. Extending the MNIST dataset by translations, our sparse CNN gets a test error of 0.31%. Keywords: online character recognition, signature, iterated integrals, convolutional neural network Condensed running title: Sparse arrays of signatures 1 Introduction Two rather different techniques work well for online Chinese character recognition. One approach is to render the strokes into a 40×40 bitmap embedded 1 in a 48×48 grid, and then to use a deep convolutional neural network (CNN) as a classifier [4]. Another is to draw the character on an 8 × 8 grid, and then in each square calculate a histogram measuring the amount of movement in each of the 8 compass directions, producing a 512-dimensional vector to classify [2]. Intuitively, the first representation records more accurately where the pen went, while the second is better at recording the direction the pen was taking. We attempt to get the best of both worlds by producing an enhanced picture of the character using the path iterated-integral signature. This value-added picture of the character records the pen’s location, direction and the forces that were acting on the pen as it moved. CNNs start with an input layer of size N × N × M . The first two dimensions are spatial; the third dimension is simply a list of features available at each point; for example, M = 1 for grayscale images and M = 3 for color images. When calculating the path signature, we have a choice of how many iterated integrals to calculate. If we calculate the zeroth, first, second, . . . , up to the m-th iterated integrals, then the resulting input vectors are M = 1 + 2 + 22 + · · · + 2m dimensional. This representation is sparse. We only calculate path signatures where the pen actually went: for the majority of the N × N spatial locations, the M -dimensional input vector is simply taken as all-zeros. Taking advantage of this sparsity makes it practical to train much larger networks than would be practical with a traditional CNN implementation. 2 Sparse CNNs: DeepCNet(l, k) Inspired by [4], we have considered a simple family of CNNs with alternating convolutional and max-pooling layers. Let DeepCNet(l, k) denote the CNN with – – – – – an input layer of size N × N × M where N = 3 · 2l , k convolutional filters of size 3 × 3 in the first layer, nk convolutional filters of size 2 × 2 in layers n = 2, . . . , l a layer of 2 × 2 max-pooling after each convolution layer, and a fully-connected final hidden layer of size (l + 1)k. For example, DeepCNet(4, 100) is the architecture from [4] with input layer size N = 48 = 3 · 24 and four layers of max-pooling: input-100C3-MP2-200C2-MP2-300C2-MP2-400C2-MP2-500N-output 2 For general input the cost of the forward operation, in particular calculating the first few hidden layers, is very high. For sparse input, the cost of calculating the lower hidden layers is much reduced, and evaluating the upper layers becomes the computational bottleneck. When designing a CNN, it is important that the input field size N is strictly larger than the objects to be recognized; CNNs do a better job distinguishing features in the center of the input field. However, padding the input in this way is normally expensive. An interesting side effect of using sparsity is that the cost of padding the input disappears. 2.1 Character scale n ≈ N/3 For character recognition, we choose a scale n on which to draw the characters. For the Latin alphabet and Arabic numerals, one might copy MNIST and take n = 20. Chinese characters have a much higher level of detail: [4] uses n = 40, constrained by the computational complexity of evaluating dense CNNs. Given n, we must choose the l-parameter such that the characters fit comfortably into the input layer. DeepCNets seem to work best when n is approximately N/3. There are a couple of ways of justifying the n ≈ N/3 rule: – To process the n × n sized input down to a zero-dimensional quantity, the number of levels of 2 × 2 max-pooling l = log2 (N/3) should be approximately log2 n. – Counting the number of paths through the CNN from the input to output layers reveals a plateau; see Figure 1. Each corner of the input layer has only one route to the output layer; in contrast, the central (N/3) × (N/3) points in the input layer each have 9 · 4l−1 such paths. 2.2 Sparsity For DeepCNets with l > 4, training the network is in general hard work, even using a GPU. However, for character recognition, we can speed things up by taking advantage of the sparse nature of the input, and the repetitive nature of CNN calculations. Essentially, we are memoizing the filtering and pooling operations. First imagine putting an all-zero array into the input layer. As you evaluate the CNN in the forward direction, the translational invariance of the input is propagated to each of the hidden layers in turn. We can therefore 3 Figure 1: A comparison of the number of possible paths from the input layer (96 × 96) to the fully connected layer for l = 5 DeepCNets and LeNet-7 [8]. The DeepCNet’s larger number of hidden layers translates into a larger number of paths, but with a narrower plateau. think of each hidden variable as having a ground state corresponding to receiving no meaningful input; the ground state is generally non-zero because of bias terms. When the input array is sparse, one only has to calculate the values of the hidden variables where they differ from their ground state. To forward propagate the network we calculate two types of list: lists of the non-ground-state vectors (which have size M , k, 2k, . . . ) and lists specifying where the vectors fit spatially in the CNN. This representation is very loosely biologically inspired. The human visual cortex separates into two streams of information: the dorsal (where) and ventral (what) streams. 2.3 MNIST as a sparse dataset To test the sparse CNN implementation we used MNIST [7]. The 28 × 28 digits have on average 150 non-zero pixels. Placing the digits in the middle of a 96 × 96 grid produces a sparse dataset as 150 is much smaller than 962 . It is common to extend the MNIST training set by translations and/or elastic distortions. Here we only use translations of the training set, adding random shifts of up to ±2 pixels in the x- and y-directions. Training a very small-but-deep network, DeepCNet(5, 10), for a very long time, 1000 repetitions of the training set, gave a test error of 0.58%. Using a GeForce GTX 680 graphics card, we can classify 3000 characters per second. We tried increasing the number of hidden units. Training DeepCNet(5, 30) for 200 repetitions of the training set gave a test error of 0.46%. 4 Dropout, in combination with increasing the number of hidden units and the training time generally improves ANN performance [6]. DeepCNet(5, 60) has seven layers of matrix-multiplication. Dropping out 50% of the input to the fourth layer and above during training resulted in a test error of 0.31%. 3 The sparse signature grid representation The expression of the information contained in a path in the form of iterated integrals was pioneered by K.T. Chen [3]. More recently, path signatures have been used to solve differential equations driven by rough paths [11, 12]. The signature extracts enough information from the path to solve any linear differential equation and uniquely characterizes paths of finite length [5]. The signature has been used in sound compression [10]. A stereo audio recording can be seen as a highly oscillating path in R2 . Storing a truncated version of the path signature allows a version of the audio signal to be reconstructed. Although computing the signature of a path is easy, the inverse problem is rather more difficult. The limiting factor in [10] was the lack of an efficient algorithm for reconstructing a path from its truncated signature when m > 2. We side-step the inverse problem by learning to recognize the signatures directly. 3.1 Computation of the path signature Let [S, T ] ⊂ R denote a time interval and let V = Rd with d = 2 denote the writing surface. Consider a pen stroke: a continuous function X : [S, T ] → V . For positive integers k and intervals [s, t] ⊂ [S, T ], the k-th iterated integral of X is the dk -dimensional vector (i.e. a tensor in V ⊗k ) defined by Z k Xs,t = 1 dXu1 ⊗ · · · ⊗ dXuk . s<u1 <···<uk <t By convention, the k = 0 iterated integral is simply the number one. The k = 1 iterated integral is the displacement of the path. The k = 2 iterated integral is related to the curvature of the path. As k increases, it is a case of diminishing returns. The iterated integrals increase rapidly in dimension whilst carrying less information about the large scale shape of X. We therefore consider truncated signatures. The signature, truncated at level m, is the collection of the iterated integrals, 1 2 m S(X)s,t = (1, Xs,t , Xs,t , . . . , Xs,t ). 5 1 ⊗ (1, 1) ⊗ ( 21 , 12 , 12 , 21 ) 1 ⊗ (1, −1) ⊗ ( 12 , − 21 , − 12 , 12 ) 1 ⊗ (2, 0) ⊗ (2, −1, 1, 0) Figure 2: Concatenating paths and the corresponding m = 2 signatures. With d = 2, the dimension of this object is M := 1 + d + · · · + dm = 2m+1 − 1. (1) Let ∆s,t := Xt − Xs denote the path displacement. Thinking of ∆s,t as a row vector, the tensor product corresponds to the Kronecker matrix product (kron in MATLAB). When X is a straight line, the signature can be calculated exactly: 1 Xs,t = ∆s,t , 2 Xs,t = ∆s,t ⊗ ∆s,t , 2! 3 Xs,t = ∆s,t ⊗ ∆s,t ⊗ ∆s,t , 3! ... (2) Joining together two paths to form a longer path results in a type of convolution of the signatures; see Figure 2. With s < t < u, S(X)s,u is calculated from S(X)s,t and S(X)t,u using the formula k Xs,u = k X i k−i Xs,t ⊗ Xt,u , k = 0, 1, 2, . . . , m. (3) i=0 Using (3) inductively we can calculate the signature for any piecewise linear path. 3.2 Representing pen strokes Each character collected by an electronic stylus is represented by a sequence of pen strokes. Each stroke is represented by a sequence of points that we will treat as a piecewise linear path. Recall that n ≈ N/3 denotes the scale at which characters will be drawn. We use another parameter δ = n/5 to describe very approximately the scale of path curvature. Here is an algorithm that takes a character and uses the first m iterated integrals to construct an N × N × M CNN-input-layer array (1). 6 – Initialize an array of size N × N × M to all zeros. Think of this as an N × N array of vectors in RM ; the first two dimensions correspond to the writing surface, and the third corresponds to the elements of the signature. – Rescale the character to fit in an n×n box placed in the center of the N ×N input layer. Let Xi : [0, length(i)] → [0, N ]2 denote the i-th character stroke, parameterized to have unit speed. – Let Xi (t) denote a point moving along the i-th stroke. Mapping Xi (t) into the N × N grid, store S(Xi )t−δ,t+δ in the appropriate column of the array. Note that the first element of the signature corresponds to the zero-th iterated integral which is always a one. Thus if we look at the first N × N × 1 slice of our 3D array we see a 2D bitmap picture of the character. If m > 1, the next two layers contain the first iterated integrals: they encode the direction the pen was moving. If m > 2, the next four layers encode the second iterated integrals, and so on. 4 4.1 Results 10, 26 and 183 character classes We will first look at three relatively small datasets [1] to study the effect of increasing the signature truncation level m. – The Pendigits dataset contains handwritten digits 0-9. It contain about 750 training characters for each of the ten classes. – The UJIpenchars database includes the 26 lowercase letters. The training set contains 80 characters for each of the 26 classes. – The Online Handwritten Assamese Characters Dataset contains 45 samples of 183 Indo-Aryan characters. We used the first k handwriting samples as the training set, and the remaining 45 − k samples for a test set (k = 15 or 36). To make the comparisons interesting, we deliberately restrict the DeepCNet k and l parameters. The justification for this is that increasing k and l is computationally expensive. In contrast, increasing m only increases the cost of evaluating the first layer of the CNN; in general for sparse CNNs the first layer represents only a small fraction of the total cost of evaluating the network. Thus increasing m is cheap, and we will see that it tends to improve test performance. We tried smaller and larger networks, and using the training set with and without increasing its size by affine transformations (a random mix of scalings, rotations and translations). The table shows the test set error rates. 7 Dataset DeepCNet n Transforms m = 0 m = 1 m = 2 m = 3 Pendigits (3,10) 10 × 3.37% 1.60% 1.32% 1.09% Pendigits (5,50) 32 X 0.94% 0.43% 0.40% 0.40% UJI lowercase (4,10) 20 × 18.3% 16.3% 15.3% 13.4% UJI lowercase (5,50) 32 X 7.4% 6.6% 6.9% 6.9% Assamese-15 (5,20) 32 × 48.9% 40.3% 39.8% 34.8% Assamese-15 (5,50) 32 X 12.5% 11.9% 11.0% 11.0% Assamese-36 (6,50) 64 X 2.2% 2.3% 1.6% 2.3% The results show that the first and second, and even the third iterated integrals carry information that CNNs can use to improve generalization from the training to the test set. 4.2 CASIA The CASIA-OLHWDB1.1[9] database contains samples from 300 writers, allocated into training and test sets. It contains samples of the 3755 GBK level-1 Chinese characters. A test error of 5.61% is achieved using a deep CNN applied to pictures drawn from the pen data [4]. Their program took advantage of a couple of features that are often used in the context of CNNs. Rather than simply drawing a binary bitmap of the character, they convolved the images with a Gaussian blur. They also used elastic distortions. We trained a DeepCNet(6, 100) with m = 2 and n = 60. We went through the training data 80 times. For the first 40 repetitions, we randomized the placement of the training characters is a small neighborhood of the center of the input layer. This gave a test error of 4.44%. We then applied affine transformations to the training characters for another 40 repetitions, giving a test error of 4.01%. Modifying the above network by adding dropout—with dropout per level of 0, 0, 0, 0.1, 0.2, 0.3, 0.4, 0.5—resulted in a test error to 3.58%. 5 Conclusion We have studied two methods for improving the performance of CNNs for online handwriting character recognition, enhancing the pictures with signature information and using sparsity to increase the depth of the networks we can train. They work well together on a variety of alphabets. This work raises a number of questions: – Besides the path signature, there are many other ways of describing the shape of a path. You could calculate 8-direction histograms [2] to give a 8 sparse N ×N ×8 input layer. Or you could use an unsupervised learning algorithm to characterize path segments. What is the best way of describing paths for CNNs? – Can our approach be applied to natural images using curves extracted from the image by some deterministic curve tracing algorithm? – Our CNN is sparse with respect to the two spatial dimensions, but not in terms of the third feature-set dimension. Predictive Sparse Decomposition [13] results in sparse feature vectors. Can doubly-sparse CNNs be built to recognize images more efficiently? 6 Acknowledgement Many thanks to Fei Yin, Qiu-Feng Wang and Cheng-Lin Liu for their hard work organizing the ICDAR2013 competition. References [1] K. Bache and M. Lichman. UCI machine learning repository, 2013. [2] Z. L. Bai and Q. A. Huo. A study on the use of 8-directional features for online handwritten Chinese character recognition. In ICDAR, pages I: 262–266, 2005. [3] Kuo-Tsai Chen. Integration of paths—a faithful representation of paths by non-commutative formal power series. Trans. Amer. Math. Soc., 89:395–407, 1958. [4] D. Ciresan, U. Meier, and J. Schmidhuber. Multi-column deep neural networks for image classification. In Computer Vision and Pattern Recognition (CVPR), 2012 IEEE Conference on, pages 3642–3649, 2012. [5] Ben Hambly and Terry Lyons. Uniqueness for the signature of a path of bounded variation and the reduced path group. Ann. of Math. (2), 171(1):109–167, 2010. [6] Geoffrey E. Hinton, Nitish Srivastava, Alex Krizhevsky, Ilya Sutskever, and Ruslan Salakhutdinov. Improving neural networks by preventing co-adaptation of feature detectors. CoRR, abs/1207.0580, 2012. [7] Yann Lecun and Corinna Cortes. The MNIST database of handwritten digits. http://yann.lecun.com/exdb/mnist/. 9 [8] Yann LeCun, Fu-Jie Huang, and Leon Bottou. Learning methods for generic object recognition with invariance to pose and lighting. In Proceedings of CVPR’04. IEEE Press, 2004. [9] C.-L. Liu, F. Yin, D.-H. Wang, and Q.-F. Wang. CASIA online and offline Chinese handwriting databases. In Proc. 11th International Conference on Document Analysis and Recognition (ICDAR), Beijing, China, pages 37–41, 2011. [10] T. Lyons and N. Sidorova. Sound compression—a rough path approach. In In Proceedings of the 4th International Symposium on Information and Communication Technologies, pages 223–229, 2005. [11] Terry Lyons and Zhongmin Qian. System control and rough paths. Oxford Mathematical Monographs. Oxford University Press, Oxford, 2002. Oxford Science Publications. [12] Terry J. Lyons, Michael Caruana, and Thierry Lévy. Differential equations driven by rough paths, volume 1908 of Lecture Notes in Mathematics. Springer, Berlin, 2007. [13] Marc’Aurelio Ranzato, Christopher S. Poultney, Sumit Chopra, and Yann LeCun. Efficient learning of sparse representations with an energybased model. In Bernhard Schölkopf, John C. Platt, and Thomas Hoffman, editors, NIPS, pages 1137–1144. MIT Press, 2006. 10
9cs.NE
TVM: End-to-End Optimization Stack for Deep Learning Tianqi Chen1 , Thierry Moreau1 , Ziheng Jiang2,3 , Haichen Shen1 Eddie Yan1 , Leyuan Wang2,4 , Yuwei Hu5 , Luis Ceze1 , Carlos Guestrin1 , Arvind Krishnamurthy1 arXiv:1802.04799v1 [cs.LG] 12 Feb 2018 1 1 Paul G. Allen School of Computer Science & Engineering, University of Washington 2 Amazon Web Service, 3 Fudan University, 4 UC Davis, 5 TuSimple Abstract Scalable frameworks, such as TensorFlow, MXNet, Caffe, and PyTorch drive the current popularity and utility of deep learning. However, these frameworks are optimized for a narrow range of server-class GPUs and deploying workloads to other platforms such as mobile phones, embedded devices, and specialized accelerators (e.g., FPGAs, ASICs) requires laborious manual effort. We propose TVM, an end-to-end optimization stack that exposes graph-level and operator-level optimizations to provide performance portability to deep learning workloads across diverse hardware back-ends. We discuss the optimization challenges specific to deep learning that TVM solves: high-level operator fusion, low-level memory reuse across threads, mapping to arbitrary hardware primitives, and memory latency hiding. Experimental results demonstrate that TVM delivers performance across hardware back-ends that is competitive with state-of-theart libraries for low-power CPU and server-class GPUs. We also demonstrate TVM’s ability to target new hardware accelerator back-ends by targeting an FPGA-based generic deep learning accelerator. The compiler infrastructure is open sourced. Introduction Deep learning models can now recognize images, process natural language, and defeat humans in challenging strategy games. The steadily advancing compute capabilities of modern hardware has played a prominent role in deep learning’s present ubiquity and relevance in many problem domains. Many of the most popular deep learning frameworks, such as TensorFlow, MXNet, Caffe, and PyTorch, harness the power of modern hardware by focusing support on a narrow class of server-class GPU devices—with this support depending on the use of highly engineered and vendor-specific GPU libraries. However, the number and diversity of specialized deep learning accelerators is increasing rapidly in the wild. These accelerators pose an adoption challenge as they introduce new hardware abstractions that modern compilers and frameworks are ill-equipped to deal with. Providing support in various deep learning frameworks for diverse hardware back-ends in the present ad-hoc fashion is unsustainable. Ultimately, the goal is to easily deploy deep learning workloads to all kinds of hardware targets, including embedded devices, GPUs, FPGAs, and ASICs (e.g, the TPU), which significantly diverge in terms of memory organization, compute etc. as shown in Figure 1. Given these requirements, the development of an optimization frameworks that can lower a high-level specification of a deep learning program down to low-level optimized code for any hardware back-end is critical. Current deep learning frameworks rely on a computational graph intermediate representation to implement optimizations such as auto differentiation and dynamic memory management [3, 7, 4]. Graph-level optimizations, however, are often too high-level to handle hard- Figure 1: CPU, GPU and TPU-like accelerators require different on-chip memory architecture and compute primitives. This divergence must be addressed when generating optimized code. 1 Compiler Runtime graph, lib, params = t.compiler.build(graph, target, params) module = runtime.create(graph, lib, t.cuda(0)) module.set_input(**params) module.run(data=data_array) output = t.nd.empty(out_shape, ctx=t.cuda(0)) module.get_output(0, output) CoreML Frameworks CNTK Computational Graph Section 2 input High level Data-flow Rewriting Tensor Operator Description Section 3 Deployable Module Schedule Accelerators LLVM CUDA/Metal/OpenCL prediction tabby, tabby cat Figure 2: The TVM Stack Diagram. Current stack support: descriptions from many deep learning frameworks and targeting major CPU, GPU and specialized accelerators. ware back-end-specific operator-level transformations. On the other hand, current operator-level libraries that deep learning frameworks rely on are too rigid and specialized to be easily ported across hardware devices. To address these weaknesses, we need a compiler framework that can expose optimization opportunities across both the graph and operator levels to deliver competitive performance across hardware back-ends. Fundamental Optimization Challenges An optimizing compiler for deep learning needs to expose both high-level and low-level optimizations. We summarize four fundamental challenges at the computation graph level and tensor operator level: 1. High-level dataflow rewriting: Different hardware devices may have vastly different memory hierarchies, so enabling strategies to fuse operators and optimize data layouts are crucial for optimizing memory access. 2. Memory reuse across threads: Modern GPUs and specialized accelerators have memory that can be shared across compute cores. The traditional shared-nothing nested parallel model is no longer optimal. Cooperation among threads on shared memory loaded is required for optimized kernels. 3. Tensorized compute intrinsics: The latest hardware provides new instructions that go beyond vector operations, like the GEMM operator in the TPU or the tensor core in NVIDIA’s Volta. Consequently, the scheduling procedure must break computation into tensor arithmetic intrinsics instead of scalar or vector code. 4. Latency Hiding: While traditional architectures with simultaneous multithreading and automatically managed caches implicitly hide latency in modern CPUs/GPUs, specialized accelerator designs usually favor leaner control and offload most of the scheduling complexity to the compiler stack. Still, scheduling must be performed carefully to hide memory access latency. TVM : An End-to-End Optimization Stack We present TVM (shown in Figure 2), an end-to-end optimizing compiler stack to lower and fine-tune deep learning workloads to diverse hardware back-ends. TVM is designed to separate the algorithm description, schedule, and hardware interface. This principle is inspired by Halide [22]’s compute/schedule separation, but extends the concept by separating the schedule from the target hardware intrinsics. This additional separation enables support for novel specialized accelerators and their corresponding new intrinsics. TVM presents two optimization layers: a computation graph optimization layer to address the first scheduling challenge, and a tensor optimization layer with new schedule primitives to address the remaining three challenges. By combining these optimization layers, TVM can take model descriptions from most deep learning frameworks, perform joint highlevel and low-level optimizations, and generate hardware-specific optimized code for back-ends such as the Raspberry Pi, GPUs, and FPGA-based specialized accelerators. Our paper makes the following contributions: 2 Operation conv2d relu dense softmax Description P Bi,y,x = ry,rx,k Ak,y+rx,x+rx Wi,k,ry,rx Bi,y,x =Pmax(Ai,y,x , 0) Bi,j = k Ai,k PWj,k + bi Bi,j = eAi,j / k eAi,k Description DSL Embedded in Python Computational Graph View data net = cg.Variable("data", shape=(1, 3, 28, 28)) w1 = cg.Variable("w1") w2 = cg.Variable("w2") w3 = cg.Variable("w3") net = cg.conv2d(net, w1, channels=32, kernel_size=(3,3), padding=(1,1), use_bias=0) net = cg.relu(net) net = cg.conv2d(net, w2, channels=32, strides=(2,2), kernel_size=(3,3), padding=(1,1), use_bias=0) net = cg.relu(net) net = cg.flatten(net) net = cg.dense(net, w3, units=10, use_bias=False) net = cg.softmax(net) Each operation outputs one or multiple tensors of fixed shape and data type. The shape of weights can be automatically inferred by given operator attributes. w1 conv2d relu w2 conv2d relu flatten w3 attributes channels=32, kernel_size=(3,3), padding=(1,1), use_bias=0 dense operation inputs dataflow dependency softmax shape=(1,10) Figure 3: Example computational graph of a two layer convolutional neural network. Each node in the graph represents an operation that consumes one or more tensors and produces one or multiple tensors. The tensor operation can be parameterized by attributes to configure its behavior (e.g., padding or strides). • We build an end-to-end compilation optimization stack allowing the deployment of deep learning workloads specified in a highlevel framework (including Caffe, MXNet, PyTorch, Caffe2, CNTK) to diverse hardware back-ends (including CPUs, GPUs, and FPGA-based accelerators). • We identify the major optimization challenges in providing performance portability to deep learning workloads across diverse hardware back-ends. We introduce novel schedule primitives to take advantage of cross-thread memory reuse, novel hardware intrinsics, and latency hiding. • We evaluate TVM on a generic FPGA-based accelerator to provide a concrete case study on how to optimally target specialized accelerators. Our compiler generates deployable code that is performance-competitive with state-of-the-art vendor-specific libraries, and can target new specialized accelerator back-ends. The remainder of the paper is organized as follows. We describe graph optimizations in section 2 as well as tensor operator scheduling in section 3. We include experimental results in those two sections to quantitatively assess the optimizations that we propose. We discuss runtime support on section 4. Our end-to-end evaluation is in section 5. Related work is discussed in section 6. 2 Optimizing Computational Graphs Computational Graph Computational graphs are a common way to represent programs in deep learning frameworks [3, 6, 7, 4]. Figure 3 shows an example computational graph representation of a two layer convolutional neural network. The main difference between this high-level representation and a low-level compiler IR, such as LLVM, is that the intermediate data items are large multidimensional tensors. TVM exploits a computational graph representation to apply high-level optimizations: nodes represent operations on tensors of statically known dimensions, and edges represent dataflow data dependences between tensor operations. Computational graphs provide a global view on computation tasks, yet avoid specifying how each computation task needs to be implemented. A static memory planning pass can be performed on the graph to pre-allocate memory to hold each intermediate tensor 3 Constant Parameter Path Pre-Computation (w is marked as a constant parameter) Operator Fusion conv2d w fused-conv2dbn-relu bn sqrt div complexout-fusable mul 1/sqrt(w) Example Application Fuse Rule elemwise relu conv2d complexout-fusable injective Static Memory Reuse Analysis (same color indicates memory sharing) dense dense sigmoid relu dense dense sigmoid relu add add w1 w2 conv2d w1 pack relu pack pack_conv2d conv2d w2 relu relu pack pack_conv2d injective relu injective unpack reduction fused-addsqrt sqrt exp reduction fused-expsum sum Figure 5: Rules for operation fusion pass. w/o fusion w/ fusion memory layout (row-major) tensor organization 0.3 8 0.2 DATA[4][8] 0x00 0x20 0x40 0x60 4 0.1 0.0 add injective injective 0.4 Time (ms) relu Data Layout Transformation Figure 4: High-level dataflow optimizations in TVM. 0.5 fused-conv2dbn-relu bn 2 ResNet ResNet MobileNet conv1x1/f512/s2 conv3x3/f128/s1 conv3x3/dw/s1 256x14x14 128x28x28 128x56x56 2 DATA[2][4][2][2] Convolution-BN-Relu Operation Figure 6: Comparison between fused operations of convolution, batch normalization, and relu, and non-fused operations on NVIDIA Tesla K80. Both are generated by TVM. 0 1 2 3 4 5 6 7 8 9 A B C D E F 0x00 0x20 0x40 0x60 0 4 8 C 1 5 9 D 2 6 A E 3 7 B F Figure 7: Data layout requirements can be affected by tensorization: here a 2×2 tensorized operation dictates a data layout transformation. result. This assignment phase is similar to register allocation passes in traditional compilers. Similar to LLVM IR, a computational graph can be transformed into functionally equivalent graphs to apply optimizations. For example, a constant-folding pass can be applied to pre-compute the parts of the graph that can be determined statically, saving execution cost. Figure 4 gives an overview of novel graph-level optimizations implemented in TVM: operator fusion and data layout transformation. Operator Fusion Fusing multiple operators together is an optimization that can greatly reduce execution time, particularly in GPUs and specialized accelerators. The idea is to combine multiple operators together into a single kernel without saving the intermediate results back into global memory. Specifically, we recognize four categories of graph operators: injective (one-to-one map), reduction, complex-out-fusable (can fuse element-wise map to output), and opaque (cannot be fused). We apply the rules listed in Figure 5 to transform the computation graph into a fused version. Figure 6 demonstrates the impact of this optimization by comparing the performance of fused and non-fused version in three workloads. Data Layout Transformation Tensor operations are the basic operators of computational graphs. The tensors involved in computation can have divergent layout requirements across different operations. For instance, a deep learning accelerator might exploit 4 × 4 tensorized operations, requiring data to be tiled into 4 × 4 chunks to optimize for access locality. Figure 7 shows how a matrix’s data layout can be transformed to accommodate for 2 × 2 tensorized operations on its data. Optimizing data layout starts with specifying the preferred data layout of each operator given the constraints dictated their implementation in hardware. We then perform the proper layout transformation between a producer and a consumer if their data layout does not match. 4 Matrix Multiplication: C = dot(A.T, B) m, n, h = t.var('m'), t.var('n'), t.var('h') A = t.placeholder((m, h), name='A') B = t.placeholder((n, h), name='B') computing rule k = t.reduce_axis((0, h), name='k') C = t.compute((m, n), lambda i, j: t.sum(A[k, i] * B[k, j], axis=k)) result shape Recurrence Block: Y = cumsum(X) m, n = t.var('m'), t.var('n') X = t.placeholder((m, n), name='X') state = t.placeholder((m, n)) init = t.compute((1, n), lambda _,i: X[0, i]) update = t.compute((m, n), lambda t,i: state[t-1,i]+X[t,i]) Y = t.scan(init, update, state, inputs=[X]) Figure 8: Tensor expression language used in TVM for algorithm description. Each compute operation contains the shape of the output tensor, and an expression describing how to compute each element of the output tensor. Limitations of Graph-Level Optimizations While high-level dataflow graph optimizations can greatly improve the efficiency of deep learning workloads, they are only as effective as what the operator library provides. Currently, the few deep learning frameworks that support operator fusion require the operator library to provide an implementation of the fused patterns. With more network operators introduced on a regular basis, the number of possible fused kernels can grow dramatically. This approach is no longer sustainable when targeting an increasing number of hardware back-ends, as the required number of fused patterns implementations grows combinatorially with the number of data layouts, data types, and hardware accelerator intrinsics that need to be supported. It is not feasible to handcraft operator kernels for this massive space of back-end specific operators. To this end, we propose a code-generation approach that can generate tensor operators in the next section. 3 Optimizing Tensor Operations This section addresses how TVM can generate fine-tuned versions of the same operator for a wide array of hardware back-ends. 3.1 Tensor Expression Language We introduce a dataflow tensor expression language to support automatic code generation. Unlike high-level computation graph languages, where the implementation of tensor operations is opaque, each operation is described in an index formula expression language as displayed in Figure 8. Our tensor expression language takes cues from languages like Halide [22], Darkroom [13], and TACO [18]. Our tensor expression language supports common arithmetic and math operations found in common languages like C. We explicitly introduce a commutative reduction operator to easily schedule commutative reductions across multiple threads. We further introduce a high-order scan operator that can combine basic compute operators to form recurrent computations over time. TVM compute operations also support reduction among tuples of tensors, making it easy to support functions like argmax. This representation can describe all tensor operations used in the high-level dataflow graph and covers the common patterns exhibited in deep learning. 3.2 Schedule Space Given a tensor expression, it is still challenging to create high-performance implementations for each hardware back-end. As an example, Figure 9 highlights typical optimizations applied to CPU, GPU, and deep learning accelerator designs. Each optimized low-level program is the result of different combinations of scheduling strategies, imposing a large burden on the kernel writer. We adopt the principle of decoupling compute descriptions from schedule optimizations from Halide [22]. Schedules are the specific rules that lower compute descriptions down to back-end-optimized implementations. The idea is to formally model the schedule space and the transformations used to traverse this space, thus providing different ways to generate low-level code. The schedule space of TVM is shown in Figure 10. 5 CPU: Tiled Computation Persistent Parallel Group launch parallel threads(pg): for each yo in 0..128: for each xo in 0..128 parallel by(pg): alloc CL[8][8] = 0 for each k in 0..1024: alloc AL[8] = A[xo*8:xo*8+8][k] alloc BL[8] = B[yo*8:yo*8+8][k] for each yi in 0..8: for each xi in 0..8: CL[yi][xi] += AL[yi] * BL[xi] C[xo*8:xo*8+8][yo*8:yo*8+8] = CL GPU: Thread Cooperation for thread_group (by, bx) in cross(0..64, 0..64): for thread_item (ty, tx) in cross(0..2, 0..2): local CL[8][8] = 0 shared AS[2][8], BS[2][8] for each k in 0..1024: for each i in 0..4: AS[ty][i*4+tx] = A[by*16+ty*8+i*2+tx][k] for each i in 0..4: BS[ty][i*4+tx] = B[bx*16+ty*8+i*2+tx][k] memory_barrier_among_threads() for each yy in 0..8: for each xx in 0..8: CL[yy][xx] += AS[ty][yy] * BS[tx][xx] for each yi in 0..8: for each xi in 0..8: C[yo*8+yi][xo*8+xi] = CL Accelerator: Tensor Compute Intrinsics Explicit Instruction Synchronization out_buffer CL[2][8][8] in_buffer AL[2][8][8], BL[2][8][8] for each yo in 0..64: q0.push_dep_to(q1) q0.push_dep_to(q1) for each xo in 0..128: q1.pop_dep_from(q0) q1.fill_zero(CL[0]) q1.push_dep_to(q0) q1.pop_dep_from(q0) q1.fill_zero(CL[1]) q1.push_dep_to(q0) for each k in 0..128: q0.pop_dep_from(q1) q0.dma_copy2d(AL[0], A[yo*8:yo*8+8][k]) q0.dma_copy2d(BL[0], B[xo*8:xo*8+8][k]) q0.push_dep_to(q1) q0.pop_dep_from(q1) q0.dma_copy2d(AL[1], A[512+yo*8:512+yo*8+8][k]) q0.dma_copy2d(BL[1], B[xo*8:xo*8+8][k]) q0.push_dep_to(q1) q1.pop_dep_from(q0) q1.fuse_gemm8x8_add(AL[0], BL[0], CL[0]) q1.push_dep_to(q0) q1.pop_dep_from(q0) q1.fuse_gemm8x8_add(AL[1], BL[1], CL[1]) q1.push_dep_to(q0) q0.pop_dep_from(q1) q0.dma_copy2d(C[yo*8:yo*8+8][xo*8:xo*8+8],CL[0]) q0.push_dep_to(q1) q0.pop_dep_from(q1) q0.dma_copy2d(C[512+yo*8:512+yo*8+8][xo*8:xo*8+8],CL[1]) q0.push_dep_to(q1) Figure 9: Matrix multiplication code example to the highlight optimization challenges that each hardware back-end exposes. CPUs require tiling and work distribution across parallel groups to optimize cache locality. GPUs require thread cooperation to allow shared memory reuse among thread groups. ASIC and FPGA accelerators exploit tensorized computation and rely on explicit synchronization to hide memory access latency. In order to quickly explore the schedule space, we need to provide effective schedule primitives that transform schedules. Figure 11 shows a collection of common schedule primitives used in TVM . Many of these primitives echo practices in high-performance computing. We adopt useful schedule primitives from Halide and introduce new ones to tackle the challenges introduced by GPU and specialized hardware accelerators. We describe these primitives in detail in the next three subsections. 3.3 Nested Parallelism with Cooperation Parallel programming is key to improving the efficiency of compute intensive kernels in deep learning workloads. Modern GPUs offer massive parallelism, requiring us to bake parallel programming models into schedule transformations. Most existing solutions adopt a parallel programming model referred to as nested parallel programs, which is a form of fork–join parallelism. Specifically, we can use a parallel schedule primitive to parallelize a data parallel task. Each parallel task can be further recursively subdivided into subtasks to exploit the multi-level thread hierarchy on the target architecture (e.g., thread groups in GPU). We call this model shared-nothing nested parallelism, as one working thread cannot look at the data of its sibling within the same parallel computation stage. Interactions between sibling threads happen at the join stage, when the subtasks are done and next stage can consume the data produced by the previous stage. This programming model does not enable threads to cooperate with each other in order to perform collective task within the same parallel stage. Figure 12 provides a matrix multiplication example demonstrating this limitation. Matrix multiplication on a GPU requires division of work into tiles that are distributed among thread groups, and then assigned to each individual thread. Under shared-nothing nested 6 DataFlow A B AL BL y Equivalent Code Schedule Tree Axis Relation Hyper-Graph CL C x AL for each yo in 0..128: for each xo in 0..128: alloc CL[8][8] = 0 for each k in 0..1024: alloc AL[8], BL[8] for each xa in 0..8: AL[xa] = A[yo*8+ya][k] for each xb in 0..8: BL[xb] = B[xo*8+xb][k] for each yy in 0..8: for each xx in 0..8: CL[yy][xx] += AL[yy] * BL[xx] for each yi in 0..8: for each xi in 0..8: C[yo*8+yi][xo*8+xi] = CL[yi][xi] BL yo s CL s yo k yi yy xi xx xo C yi operation xo xa xb xi leaf computation iteration(loop) axis axis transform relation (s: split, f: fuse, b: bind) loop nest store location Figure 10: Schedule space representation in TVM. This example shows an explicitly tiled matrix multiplication. The dataflow representation provides an expression specifying the computation of each tensor element. The axis relation hyper-graph defines a bijective relation between the original loop axis and the transformed loop axis. The schedule tree represents the loop nest structure and producer store location of the computing structure. The schedule tree representation is derived from Halide [22], with a special emphasis on store location relation. Together, the dataflow representation, axis relation graph, and schedule tree describe a schedule that can be lowered to the code shown in the rightmost panel. Existing Schedule Primitives s[C].reorder(xo, yo) Loop Transformation C yo, yi = s[C].split(y) C yo xo xo yo C yo C yi s[A].compute_at(s[C], yo) C A C yo xo xo yo Attribute A C xy x s f y yo Cache Location y x y C y xy = s[C].fuse(x, y) xy yi s[C].pragma(yo, unroll) C Thread Binding s[C].bind(yo, thread_x) C C yo yo {unroll} xo C yo thread_x xo xo yo b xo thread_x New Schedule Primitives s[AS].set_scope(t.shared) Parallel Cooperation s[AS].bind(ax, tx) C bx AS C ax tx Tensorization C AS bx tx tx operation loop nest store location ko xo yy BL C yo xo CL ko Virtual Thread (Latency Hiding) s[C].bind(yo, vthread) AL BL gemm8x8 C C yo xo yo vthread b xo vthread ki iteration(loop) axis data shared in thread group yo AL xx k k CL s[CL].tensorize(yy, gemm8x8) leaf computation axis transform relation (s: split, f: fuse, b: bind) data local to thread thread group index thread index in group Figure 11: Schedule primitives (i.e. transformations) used in TVM . 7 virtual thread New Schedule: Sharing AS across local workload CL Old Schedule: Shared nothing nested parallelism C CL AS bx by ty tx xa C CL k yy ty yy tx yi xi for thread_group (by, bx) in cross(0..64, 0..64): for thread_item (ty, tx) in cross(0..2, 0..2): local CL[8][8] = 0 shared AS[2][8], BS[2][8] for each k in 0..1024: for each i in 0..4: AS[ty][i*4+tx] = A[by*64+ty*8+i*4+tx][k] for each i in 0..4: BS[ty][i*4+tx] = B[bx*64+ty*8+i*4+tx][k] memory_barrier_among_threads() for each yy in 0..8: for each xx in 0..8: CL[yy][xx] += AS[ty][yy] * BS[tx][xx] for each yi in 0..8: for each xi in 0..8: C[yo*8+yi][xo*8+xi] = CL xa by(blockIdx.y) ty by xx y AS bx k yi Equivalent Code of New Schedule Axis relation of New Schedule s s xx b b s ty(threadIdx.y) tx b b s xi global memory thread group index data shared in thread group All threads cooperatively load AS and BS in different parallel patterns Barrier inserted automatically by compiler data local to thread thread index in group Figure 12: Schedule for cooperative nested parallelism. Memory scoping is introduced to enable task sharing among parallel jobs. The resulting new schedule can take better advantage of the shared memory hierarchy in modern GPUs. Workload within a single 2x2 thread group Each color represent a thread Time (ms) 101 Compute Stage Load Stage Load of BS is similar BS A AS Halide TVM w/o coop. cuBLAS TVM 100 AS 512 1024 Matrix size 2048 Reduction loop over k Figure 14: Matrix multiplication performance compariFigure 13: Memory Loading Pattern of Cooperative Parallel Program son using Halide, TVM with and without cooperation, and cuBLAS on Nvidia K80. By adopting the new schedule primitive, we can generate a kernel that is close to vendoroptimized performance. parallelism, each thread will have to independently fetch the data needed for its tile of the computation during the reduction phase. 1 A better alternative to the shared-nothing approach is to fetch data cooperatively across threads. This pattern is well known in GPU programming using languages like CUDA, OpenCL and Metal, but has not been implemented into a schedule primitive. We introduce the concept of memory scopes to the schedule space, so that a stage can be marked as shared. Without memory scopes, automatic scope inference will mark the relevant stage as thread-local, as shown in Figure 12. The shared task needs to compute the dependencies of all the working threads in the group. We can efficiently schedule the input data loading by distributing the loading task among the same group of threads using the thread binding primitive. It’s worth noting that we are forced to use the same threads to work on the division of shared workload, so threads can persist across the load and compute stages. This improved implementation requires additional compiler support. Specifically, the bound inference algorithm needs to be able to deduce the bounds of the shared task by merging the tasks of all the cooperative threads together. Additionally, memory synchronization barriers need to be properly inserted to guarantee that shared loaded data is visible to the consumers. Figure 14 compares the performance of GPU kernels generated with shared nothing nested parallelism vs. with cooperation. We also compare TVM to Halide, which adopts a shared-nothing nested parallel approach. We find that it is critical to adopt these new schedule 1 It is possible to have a shared loading stage across threads before the reduction, but that requires loading every dependency used in the reduction, using too much memory. 8 Declare Hardware Interface and Lowering Rule w, x = t.placeholder((8, 8)), t.placeholder((8, 8)) k = t.reduce_axis((0, 8)) y = t.compute((8, 8), lambda i, j: t.sum(w[i, k] * x[j, k], axis=k)) Schedule: s[CL].tensorize(yy, gemm8x8) declare behavior lowering rule to generate def gemm_intrin_lower(inputs, outputs): hardware intrinsics to carry ww_ptr = inputs[0].access_ptr(“r") xx_ptr = inputs[1].access_ptr("r") out the computation zz_ptr = outputs[0].access_ptr("w") compute = t.hardware_intrin("gemm8x8", ww_ptr, xx_ptr, zz_ptr) reset = t.hardware_intrin("fill_zero", zz_ptr) update = t.hardware_intrin("fuse_gemm8x8_add", ww_ptr, xx_ptr, zz_ptr) return compute, reset, update gemm8x8 = t.decl_tensor_intrin(y.op, gemm_intrin_lower) xo ko yy ki Compiler dectect n-dimensional copy pattern and generate copy intrinsic. for each yo in 0..128: for each xo in 0..128: acc.fill_zero(CL) for each ko in 0..128: acc.dma_copy2d(AL, A[yo*8:yo*8+8][k]) acc.dma_copy2d(BL, B[xo*8:xo*8+8][k]) acc.fuse_gemm8x8_add(AL, BL, CL) yo CL xx Generated Code with Hardware Intrinsics out_buffer CL[8][8] in_buffer AL[8][8], BL[8][8] C AL C yo BL CL AL ko BL xo gemm8x8 verify that the compute matches declaration and use lowering rule tensor compute intrinsic acc.dma_copy2d(C[yo*8:yo*8+8][xo*8:xo*8+8],CL) Figure 15: Tensorization helps us target specialized accelerators. We use the tensor expression language to describe hardware intrinsics. This approach decouples hardware lowering from scheduling and makes it easy to target new specialized accelerators. primitives to obtain optimal performance on GPUs. Finally, in addition to being useful to GPUs, memory scopes allow us to tag special memory buffers and create special lowering rules when targeting specialized deep learning accelerators. 3.4 Tensorization: Generalizing the Hardware Interface Deep learning workloads have high arithmetic intensity that can be typically decomposed into tensor operators like matrix-matrix multiplication or 1D convolution. These natural decompositions have led to the recent trend of adding tensor compute primitives that go beyond vector instructions. The emerging compute intrinsics are quite diverse, including examples like matrix-matrix multiplication [17], matrix-vector product [1] and 1D convolution [9]. These new primitives create new challenges for the tensor operator schedule: the schedule must use these primitives to benefit from acceleration. We dub this the tensorization problem, analogous to the vectorization problem for SIMD architectures. Tensorization differs significantly from vectorization. The inputs to the tensor compute primitives are multi-dimensional, with fixed or variable lengths, and dictate different data layouts. More importantly, we cannot resort to a fixed set of primitives, as new deep learning accelerators are emerging with their own flavors of tensor instructions. Therefore, we need a solution that is future proof to support new generations of specialized accelerators. To solve this challenge, we separate the hardware interface from the schedule. Specifically, we introduce a tensor intrinsic declaration mechanism. We can use the tensor expression language to declare the behavior of each new hardware intrinsic, as well as the lowering rule associated to it. Additionally, we introduce a tensorize schedule primitive to replace a unit of computation with the corresponding tensor intrinsics. The compiler matches the computation pattern with a hardware declaration, and lowers it to the corresponding the hardware intrinsic. Figure 15 shows an example of tensorization. The tensor expression language describes both the users’ intended compute description, and the abstractions that the hardware exposes. Tensorization decouples the schedule from specific hardware primitives, making TVM easy to extend to support new hardware architectures. The generated code of tensorized schedule aligns with common practices found in high performance computing: break complex operations down into a repeated sequence of micro-kernel calls. Consequently, we can also use the tensorize primitive to take advantage of handcrafted assembly micro-kernels, which can be beneficial in some platforms. For example, tensorizing half-precision GEMM to a 4 × 4 handcrafted micro-kernel on an AMD Vega GPU can yield more than 1.5× speedup over the best non-tensorized version. 9 q0 input_buffer AL[2][8] out_buffer CL[2][8] q1.push_dep_to(q0) q1.push_dep_to(q0) for each ko in 0..128: q0.pop_dep_from(q1) q0.dma_copy2d(AL[0], A[k][0:8]) q0.push_dep_to(q1) q0.pop_dep_from(q1) q0.dma_copy2d(AL[1], A[k][8:16]) q0.push_dep_to(q1) q1 memory instruction q1.pop_dep_from(q0) q1.accumulate(AL[0], CL[0]) q1.push_dep_to(q0) q1.pop_dep_from(q0) q1.accumulate(AL[1], CL[1]) q1.push_dep_to(q0) . . . compute instruction instruction stream synchronization among stream P Figure 16: Low-level program with explicit synchronization. This example demonstrates how to compute Cj = k Ak,j . The hardware contains two instruction streams that need to be explicitly synchronized. Carefully crafting the synchronization messages enables execution overlap between instruction streams. Step 0: High-level Program Step 2: Lower Virtual Threads into One Thread for vthread tx in 0..2: out_buffer CL[8] virtual thread annotation input_buffer AL[8] from schedule for each k in 0..128: q0.dma_copy2d(AL, A>N@[tx*8:tx*8+8]) q1.accumulate(AL, CL) out_buffer CL[2][8] input_buffer AL[2][8] for tx in 0..2: q1.push_dep_to(q0) Step 1: Inject Synchronize Instruction for vthread tx in 0..2: out_buffer CL[8] input_buffer AL[8] q1.push_dep_to(q0) additional push signal to compensate the pop at the loop entry at first iteration for each k in 0..128: q0.pop_dep_from(q1) q0.dma_copy2d(AL, A[k][tx*8:tx*8+8]) q0.push_dep_to(q1) q1.pop_dep_from(q0) q1.accumulate(AL, CL) q1.push_dep_to(q0) rewrite to give each virtual thread its own local memory for each k in 0..128: for tx in 0..2: q0.pop_dep_from(q1) q0.dma_copy2d(AL[tx], A[k][tx*8:tx*8+8]) q0.push_dep_to(q1) for tx in 0..2: q1.pop_dep_from(q0) q1.accumulate(AL[tx], CL[tx]) q1.push_dep_to(q0) interleave instructions of virtual threads instruction dependency to ensure correct ordering Figure 17: Lowering procedure to transform a high-level parallel program with virtual threads to explicit synchronize program model. 3.5 Compiler Support for Latency Hiding Latency hiding refers to the process of overlapping memory operations with computation to maximize memory and compute utilization. It requires different strategies depending on the hardware back-end that is being targeted. On CPUs, memory latency hiding is achieved implicitly with simultaneous multithreading [11] or hardware prefetching techniques [16, 8]. GPUs rely on rapid context switching of many warps of threads to maximize the utilization of functional units [26]. Specialized deep learning accelerators, on the other hand, usually favor leaner control and offload this problem to the compiler stack. Figure 16 demonstrates how a compiler is expected to explicitly handle data dependences on a pipelined deep learning accelerator that follows a decoupled-access/execute philosophy [23, 17]. We assume that the hardware pipeline consists of memory and compute stages that can execute concurrently where each stage is controlled by a independent instruction stream. Explicit synchronization instructions are used to send a signal between pipeline stages to indicate when a given task is completed so that the next dependent stage can start to consume, or overwrite data. This type of explicit dependency tracking is implemented in hardware with FIFO queues, and gives direct control to the programmer and compiler over how hardware tasks execute. By using low-level synchronization primitives exposed by the hardware, we can effectively hide latency. Programming hardware at such a low-level, with explicit synchronization operations, is a difficult and painstaking task. To reduce the burden on the programmer, we provide a virtual threading schedule primitive that lets the programmer specify a high-level data 10 Inference Time (ms) The Lowering can be Viewed as Virtualizing Instruction Queues with less Number of Physical Queues q0 q1 Baseline Latency Hiding resne t[ resne 1] t[ resne 2] t[ resne 3] t[ resne 4] t[ resne 5] t[ resne 6] t[ resne 7] t[ resne 8] t resne [9] t[ resne 10] t[11] good Necessary and SXIficient Condition for Correctness of Thread Virtualization bad good 0.010 0.008 0.006 0.004 0.002 0.000 Figure 18: The lowering process can be viewed as virtualizing Figure 19: The effect of latency hiding on a FPGA-based hardware accelerator design running ResNet inference. thread-local instruction streams onto a lesser amount of physical instruction streams in hardware. The lowering is correct as long as the ordering between each sender/receiver pair in the original virtual stream is preserved after lowering. parallel program that TVM automatically lowers to a low-level explicit data dependence program. The lowering procedure is shown in Figure 17. The algorithm starts with a high-level parallel program and then inserts necessary synchronization instructions to guarantee correct execution order of the operations within each thread. Finally, the operations of all virtual threads are interleaved into one single thread. Correctness of Virtual Thread Lowering An incorrect interleaving of virtual threads can lead to a deadlock. Conceptually, before lowering, each thread has its own private virtual instruction streams. The lowering process maps the instructions of these virtual instruction streams into the limited physical instruction streams. This procedure requires correctness guarantees, as the physical message queue between the physical instruction streams needs to be shared among threads to pass dependencies. We can prove that the lowering is correct as long as ordering is preserved according to the rules displayed in Figure 18. The following theorem gives a necessary and sufficient condition for the correctness of this lowering process. Theorem 3.1. Let < be the partial order of the instructions after lowering, S = {(xi , yi )} be set of all pairs of push pop instructions before lowering. Every push message sent by the sender gets received by the corresponding pop instruction (lowering is correct), if and only if (x0 > x) → (y 0 > y), (x0 < x) → (y 0 < y) ∀(x, y), (x0 , y 0 ) ∈ S (1) In other words, the relative order of receiver of the synchronization message need to be the same as its sender for each send–receive pair. demonstrates this condition. Proof. Proof by contradiction. Let a be the first sender in a physical queue to send its message to wrong receiver d. Then ∃(a, b), (c, d) ∈ S. • a < c since a is the first sender who sent the wrong message. • b < d because of the theorem condition • This means b pops a message from the queue before d from some sender h, and h < a due to the FIFO property of message queue. • This contradicts the fact that a is the first sender in the queue to send to the wrong receiver (h also send to wrong receiver). This condition can be enforced by iterating through the virtual threads in round-robin fashion when each virtual instruction stream is lowered down to a physical instruction stream. This condition not only applies to the case of two physical instruction streams, but can also be used to virtualize the threads into an arbitrary number of physical instruction streams. 11 RPC Server on Embedded Device Compiler Stack lib = t.build(s, [A, B], ‘llvm -target=armv7l-none-linux-gnueabihf‘, name='myfunc') remote = t.rpc.connect(host, port) upload module to remote get remote function lib.save(‘myfunc.o’) remote.upload(‘myfunc.o’) f = remote.load_module(‘myfunc.o') copy data to remote get remote array handle ctx = remote.cpu(0) run function on remote remote_timer = f.time_evaluator(‘myfunc’, ctx, number=10) get profile statistics back copy data back to host for correctness verification a = t.nd.array(np.random.uniform(size=1024), ctx) b = t.nd.array(np.zeros(1024), ctx) time_cost = remote_timer(a, b) np.testing.assert_equal(b.asnumpy(), expected) Figure 20: RPC support in TVM runtime to make it easy to cross compile, deploy, and profile embedded devices. Hardware Evaluation of Latency Hiding We demonstrate the effectiveness of latency hiding on a custom hardware accelerator design which we describe in more depth in subsection 5.3. We run each layer of ResNet on the accelerator, and use TVM to generate two schedules: one with latency hiding, and one without. The schedule with latency hiding applies virtual threading on the program to hide memory access latencies. The results are shown in Figure 19. Overall latency hiding achieves anywhere between 7% up to 54% latency reduction on each kernel by hiding some of the latency of loading data into the accelerator. In terms of compute resources, no latency hiding leads to at best 52% utilization, whereas latency hiding yields up to 74% utilization. 4 Code Generation and Runtime Support After optimizing the schedule, the remaining task is to generate code that can run on the target platform and facilitate the deployment and profiling of the generated kernels. Code Generation For a specific tuple of data-flow declaration, axis relation hyper-graph, and schedule tree, we can generate lowered code by iteratively traversing the schedule tree, inferring the dependent bounds of the input tensors (using the axis relation hyper-graph), and generating the loop nest in the low-level code. The code is lowered to an in-memory representation of an imperative C style loop program. We reuse a variant of Halide’s the loop program data structure in this process. We reuse passes from Halide for common lowering primitives like storage flattening and unrolling, and add GPU/accelerator-specific transformations such as synchronization point detection, virtual thread injection, and module generation. Finally, the loop program is transformed into LLVM or CUDA/Metal/OpenCL source code. Runtime Support For GPU programs, we build the host and device modules separately and provide a runtime module system to launch kernels using their corresponding driver APIs. We build a driver library for the FPGA-based deep learning accelerator used in our evaluation with a C runtime API that can construct instructions and push them to the target accelerator for execution. Our code generation algorithm then translates the accelerator program to a series of calls into the runtime API. Autotuning This paper focuses on providing a novel optimization framework to enable performance-competitive compilation for deep learning systems. The optimizations that we present give the compiler a large space of schedules to explore, in order to generate performance-competitive code. We explore preliminary automatic scheduling techniques and a pass to automatically inline the injective operations. Complex operations such as high dimensional convolution, matrix multiplication, and depthwise convolution are autotuned with a collection of schedule templates. We believe combining our optimizations with more sophisticated search techniques [20] can yield further improvements in the future. 12 H/W IC OC K S 224 56 56 56 56 28 28 28 14 14 14 7 3 64 64 64 64 128 128 128 256 256 256 512 64 64 64 128 128 128 256 256 256 512 512 512 7 3 1 3 1 3 3 1 3 3 1 3 2 1 1 2 2 1 2 2 1 2 2 1 TVM (ms) NNPack (ms) 44.06 24.42 7.69 16.06 3.09 28.78 14.47 2.2 56.44 23.22 3.37 179.81 Speedup 21.93 21.45 3.56 12.62 1.86 21.36 15.36 2.15 23.48 28.56 2.54 62.48 2.01 1.14 2.16 1.27 1.66 1.35 0.94 1.03 2.4 0.81 1.33 2.88 Table 1: Comparison of TVM and NNPack on convolution operators of ResNet on Raspberry Pi. H/W for height and width, IC for input channels, OC for output channels, K for kernel size, S for stride size. H/W C M K S 112 112 56 56 28 28 14 14 7 32 64 128 128 256 256 512 512 1024 1 1 1 1 1 1 1 1 1 3 3 3 3 3 3 3 3 3 1 2 1 2 1 2 1 2 1 TVM (ms) MXKernel (ms) 35.52 20.83 35.54 10.66 19.43 6.81 12.07 4.1 7.48 Speedup 4.33 3.49 4.17 1.68 2.13 0.9 1.43 0.44 0.99 8.21 5.97 8.53 6.34 9.13 7.59 8.43 9.39 7.57 Table 2: Comparison of TVM and MXKernel (native operator in MXNet) on depthwise convolution operators of MobileNet on Raspberry Pi. H/W for height and width, C for channels, M for multiplier, K for kernel size, S for stride size. Because depthwise convolution architecture is relatively new and is not yet optimized by a DNN library, we pick the naive implementation found in the MXNet. TVM generates operator that out-performs the implementation in MXNet. Remote Deployment Profiling TVM also includes infrastructure to make profiling and autotuning easier on embedded devices. Traditionally, targeting an embedded device for tuning requires cross-compiling on the host side, copying to the target device, and timing the execution. This process has to be done manually and prevents the automation of the compile, run, and profile autotuning flow. We provide remote function call support in our compiler stack: through the RPC interface, we can compile the program on a host compiler, upload to remote embedded devices, run the function remotely, and access the results in the same script on the host (Figure 20). We find this approach to be very helpful in optimizing workloads on embedded devices such as the Raspberry Pi and FPGA-based accelerators. 5 Evaluation We evaluate TVM on three types of platforms—an embedded CPU, a server-class GPU, and a deep learning accelerator implemented on a low-power FPGA based SoC. The benchmarks are based on real world deep learning inference workloads including ResNet [12] and MobileNet [15]. We compare our approach with existing deep learning frameworks including MxNet [7] and TensorFlow [2] that rely on highly engineered vendor-specific libraries. 5.1 Raspberry Pi Evaluation We evaluated the performance of TVM on a Raspberry Pi 3B (Quad Core 1.2GHz). We use Apache MXNet (commit: 35ceea) as our baseline system. MXNet uses state-of-the-art operators in NNPack (commit: 57fc2c) for convolution and OpenBLAS for matrix 13 Workload ResNet18 MobileNet MXNet(ms) 1390 2862 TVM (ms) 567 209 Speedup 2.4 12 Time (ms) Table 3: End-to-End Experiment Results on Raspberry Pi 17.5 15.0 12.5 10.0 7.5 5.0 2.5 0.0 Tensorflow XLA Tensorflow MXNet TVM ResNet MobileNet K80 ResNet MobileNet GTX1080 Figure 21: GPU end-to-end comparison of ResNet and MobileNet workloads among TVM , MXNet, Tensorflow, and Tensorflow XLA on NVIDIA Tesla K80 and GTX 1080. multiplication. We carefully tuned the baseline for the best performance. We also enabled Winograd convolution in the NNPack implementation for 3x3 convolutions and multithreading. Table 1 and Table 2 show the comparison between TVM tensor operators against hand-optimized ones for ResNet and MobileNet. We observe that TVM generates operators that outperform the hand-optimized NNPack version for both neural network workloads. The result also demonstrates TVM ’s ability to quickly optimize emerging tensor operators, such as depthwise [15] convolution operators which are not supported in existing DNN libraries. Finally, Table 3 shows an end-to-end comparison of the two network workloads, where TVM outperforms baselines by 2x and 12x for ResNet and MobileNet respectively. 5.2 GPU Evaluation We first compare the end-to-end performance of the ResNet and MobileNet workloads among TVM , MXNet, Tensorflow, and Tensorflow XLA on the NVIDIA Tesla K80 and GTX 1080 GPUs. MXNet and Tensorflow both use cuBLAS v8 and cuDNN v7 for the ResNet workload, and implement their own versions of depthwise convolution in the MobileNet workload as this operation is relatively new and is not yet supported by the latest libraries. On the other hand, Tensorflow XLA uses JIT compilation. Figure 21 shows that TVM outperforms other frameworks in end-to-end execution time under almost all configurations except for the ResNet workload on GTX 1080 where TVM is marginally slower (1.6%) than MXNet. TVM reduces the inference time by 22% and 5% over the second best implementations of ResNet and MobileNet on the Tesla K80, and is 7.7% faster for MobileNet on GTX 1080. We perform a breakdown comparison of stages in Resnet and MobileNet on Nvidia Tesla K80, shown in Table 4 and Table 5. We can see that TVM generates competitive GPU kernels compared to the vendor-specific ones one. This is because TVM has a large design space to search through to generate optimized schedules. More importantly, for new operations such as depthwise convolutions (Table 5), TVM can generate well-optimized GPU kernels. AMD GPU Case Study To highlight the ability of TVM to target multiple GPU backends, we experimented with porting existing schedules to an AMD Vega FE Air (gfx900). When starting from a default GPU schedule template, we are within an order of magnitude of GTX 1080 performance, achieving 10.2 ms and 3.3 ms end-to-end times for ResNet and MobileNet respectively. Quickly tuning the schedule in a matter of hours further improved ResNet performance by roughly 40% and MobileNet performance by roughly 10%. These results highlight that despite AMD and NVIDIA GPUs having ostensibly different architectures with different instructions, TVM 14 H/W IC OC K S 224 56 56 56 56 28 28 28 14 14 14 7 3 64 64 64 64 128 128 128 256 256 256 512 64 64 64 128 128 128 256 256 256 512 512 512 7 3 1 3 1 3 3 1 3 3 1 3 2 1 1 2 2 1 2 2 1 2 2 1 cuDNN (ms) 0.44 0.42 0.23 0.32 0.21 0.44 0.40 0.22 0.56 0.56 0.24 0.75 TVM (ms) 0.45 0.47 0.06 0.38 0.10 0.41 0.37 0.08 0.56 0.47 0.10 0.55 Speedup 0.98 0.90 3.74 0.86 2.08 1.08 1.08 2.67 1.01 1.20 2.47 1.36 Table 4: Comparison of TVM and cuDNN v7 on Conv2D operators of ResNet on Nvidia Tesla K80. H/W for height and width, IC for input channels, OC for output channels, K for kernel size, S for stride size. H/W C M K S 112 112 56 56 28 28 14 14 7 32 64 128 128 256 256 512 512 1024 1 1 1 1 1 1 1 1 1 3 3 3 3 3 3 3 3 3 1 2 1 2 1 2 1 2 1 MXKernel TVM (ms) (ms) 0.34 0.12 0.26 0.34 0.36 0.18 0.21 0.17 0.20 0.07 0.17 0.05 0.17 0.04 0.17 0.03 0.16 0.03 Speedup 2.91 0.75 1.98 1.25 2.71 3.65 4.72 5.45 5.06 Table 5: Comparison of TVM and MXNet on depthwise Conv2D operators on MobileNet running on Nvidia Tesla K80. H/W for height and width, C for channels, M for multiplier, K for kernel size, S for stride size. is general enough to capture their similarities: mainly in their memory hierarchy and organization of threads. Still, we expect further performance improvements with AMD GPU-specific structural changes to the default schedule. 5.3 FPGA Accelerator Evaluation Vanilla Inference Tensor Accelerator We demonstrate how TVM tackles accelerator-specific code generation on a generic inference accelerator design we prototyped on an FPGA. We introduce the Vanilla Inference Tensor Accelerator (VITA) which distills characteristics from previous accelerator proposals [19, 9, 17] into a minimalist hardware architecture. We use VITA in this evaluation to demonstrate TVM ’s ability to generate highly efficient schedules that can target specialized accelerators. Figure 22 shows the highlevel hardware organization of the VITA architecture. VITA is programmed as a tensor processor to efficiently execute operations with high compute intensity (e.g, matrix multiplication, high dimensional convolution). VITA can perform load/store operations to bring blocked 3-dimensional tensors from DRAM to into a contiguous region of SRAM. VITA also provides specialized on-chip memories for network parameters, layer inputs (narrow data type), and layer outputs (wide data type). Finally, VITA provides explicit synchronization control over successive load, compute, and store operations to maximize the overlap between memory and compute operations. Methodology We implement the VITA design on a low-power PYNQ board which incorporates an ARM Cortex A7 dual core CPU clocked at 667MHz and an Artix-7 based FPGA fabric. On the modest FPGA resources, we implement a 16 × 16 matrix-vector unit clocked at 200MHz that performs products of 8-bit values and accumulates them into a 32-bit register every cycle. The theoretical peak throughput of this flavor of the VITA design lies around 102.4GOPS/s. We allocate 32kB of resources for activation storage, 32kB for parameter storage, 32kB for microcode buffers, and 128kB for the register file. These on-chip buffers are nowhere near large enough to provide enough on-chip storage for a single layer of ResNet, and therefore enable a case study on effective memory reuse and latency hiding. End-to-end ResNet Evaluation We leverage TVM to generate ResNet inference kernels on the PYNQ platform and offload as many layers as possible to VITA. We utilize TVM to generate both schedules for the CPU only and CPU+FPGA implementation. Due to its shallow convolution depth, the first ResNet convolution layer could not be efficiently offloaded on the FPGA and is instead computed on the CPU. All other convolution layers in ResNet, however are amenable to efficient offloading. Operations like residual layers, batch normalization, and activations are also performed on the CPU since VITA does not support these operations. Figure 23 shows the ResNet inference time breakdown between the CPU-only execution and the CPU+FPGA execution. Most of the computation is spent on the convolution layers that can be offloaded to VITA. For those convolution layers, the achieved speedup is 40×. Unfortunately, the overall performance of the FPGA accelerated system is bottlenecked by the sections of the workload that have to be executed on the CPU due to Amdahl’s law. We envision that extending the VITA design to incorporate support for these 15 DRAM INSTRUCTION FETCH LOAD Q LOAD→EXE Q COMPUTE Q COMPUTE LOAD Q EXE→LOAD Q MEMORY LOAD EXE→LOAD Q controller REGISTER FILE LOAD BUFFER V_ALU STORE→EXE Q MEMORY STORE GEMM ResNet18 Inference Time (s) 3.5 2.5 2.0 1.5 1.0 0.5 0.0 STORE BUFFER other layer_0 conv 3.0 TVM ARM TVM ARM+FPGA MICRO-OP SRAM Figure 23: We offload convolutions in the ResNet workload to an FPGA-based accelerator. The grayedout bars correspond to layers that cannot be accelerated by the FPGA and therefore have to run on the CPU. The FPGA can provide a 40x acceleration on offloaded convolution layers over the ARM Cortex A9. ACTIVATION SRAM PARAMETER SRAM Figure 22: VITA Hardware Design Overview. other operators will help reduce inference time even further. This FPGA-based experiment showcases TVM’s ability to adapt to new architectures and the hardware intrinsics that they expose. 6 Related Work Deep learning frameworks [3, 6, 7, 4] provide convenient interfaces for users to express deep learning workloads, and deploy them easily on different hardware back-ends. While existing frameworks currently depend on vendor specific tensor operator libraries to execute their workloads, they can leverage TVM ’s stack to generate optimized code a larger hardware devices. High-level computation graph DSLs are a typical way to represent and perform high-level optimizations. Tensorflow’s XLA [3] and the recently introduced DLVM [27] fall into this category. The representations of computation graphs in these works are similar, and a high-level computation graph DSL is also used in this paper. While graph level representations are a good fit for high-level optimizations, they are too high-level to optimize tensor operators under a diverse set of hardware back-ends. Prior work relies on specific lowering rules to directly generate low-level LLVM or resorts to vendor crafted libraries. These approaches require significant engineering effort for each hardware back-end and operator-variant combination. Halide [22] introduced the principle of separation between compute and scheduling. We adopt Halide’s insight and reuse its existing useful scheduling primitives in our compiler. The tensor operator scheduling is also related other works on DSL for GPUs [24, 14] as well as works on polyhedral-based loop transformation [5, 25]. TACO [18] introduces a generic way to generate sparse tensor operators on CPU. Weld [21] is a DSL for data processing tasks. We specifically focus on solving the new scheduling challenges of deep learning workloads for GPUs and specialized accelerators. Our scheduling primitives can be potentially adopted to the optimization pipeline in these works. More importantly, we provide an end-to-end stack that can directly take descriptions from deep learning frameworks, and jointly optimize together with the high-level stack. Despite the trend domain specific accelerators for deep learning [17, 10], it is yet unclear how a compilation stack can be built to effectively target these devices. The VITA design used in the evaluation provides a generic way to summarize the properties of these accelerators, and enables a concrete case study on how such compilation to accelerators can be done. This paper provides a generic solution to effectively target the specialized accelerators via tensorization and compiler-driven latency hiding. 7 Acknowledgements We would like to thank Ras Bodik and James Bornholt for their thorough feedback on earlier versions of this paper. Tianqi Chen is supported by the Google PhD Fellowship. This work was partially supported by the NSF under grant #1518703. 16 8 Conclusion Our work provides an end-to-end stack to solve fundamental optimization challenges across a diverse set of hardware back-ends. We hope our work can encourage more studies of programming languages, compilation, and open new opportunities for hardware co-design techniques for deep learning systems. We open-sourced our compiler stack, and will open source the VITA design to encourage further researches in this direction. References [1] Nvidia tesla v100 gpu architecture: The worldś most advanced data center gpu, 2017. [2] Martı́n Abadi, Ashish Agarwal, Paul Barham, Eugene Brevdo, Zhifeng Chen, Craig Citro, Greg S. Corrado, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Ian Goodfellow, Andrew Harp, Geoffrey Irving, Michael Isard, Yangqing Jia, Rafal Jozefowicz, Lukasz Kaiser, Manjunath Kudlur, Josh Levenberg, Dan Mané, Rajat Monga, Sherry Moore, Derek Murray, Chris Olah, Mike Schuster, Jonathon Shlens, Benoit Steiner, Ilya Sutskever, Kunal Talwar, Paul Tucker, Vincent Vanhoucke, Vijay Vasudevan, Fernanda Viégas, Oriol Vinyals, Pete Warden, Martin Wattenberg, Martin Wicke, Yuan Yu, and Xiaoqiang Zheng. TensorFlow: Large-scale machine learning on heterogeneous systems, 2015. Software available from tensorflow.org. [3] Martin Abadi, Paul Barham, Jianmin Chen, Zhifeng Chen, Andy Davis, Jeffrey Dean, Matthieu Devin, Sanjay Ghemawat, Geoffrey Irving, Michael Isard, Manjunath Kudlur, Josh Levenberg, Rajat Monga, Sherry Moore, Derek G. Murray, Benoit Steiner, Paul Tucker, Vijay Vasudevan, Pete Warden, Martin Wicke, Yuan Yu, and Xiaoqiang Zheng. Tensorflow: A system for large-scale machine learning. In 12th USENIX Symposium on Operating Systems Design and Implementation (OSDI 16), pages 265–283, 2016. [4] Amit Agarwal, Eldar Akchurin, Chris Basoglu, Guoguo Chen, Scott Cyphers, Jasha Droppo, Adam Eversole, Brian Guenter, Mark Hillebrand, Ryan Hoens, Xuedong Huang, Zhiheng Huang, Vladimir Ivanov, Alexey Kamenev, Philipp Kranen, Oleksii Kuchaiev, Wolfgang Manousek, Avner May, Bhaskar Mitra, Olivier Nano, Gaizka Navarro, Alexey Orlov, Marko Padmilac, Hari Parthasarathi, Baolin Peng, Alexey Reznichenko, Frank Seide, Michael L. Seltzer, Malcolm Slaney, Andreas Stolcke, Yongqiang Wang, Huaming Wang, Kaisheng Yao, Dong Yu, Yu Zhang, and Geoffrey Zweig. An introduction to computational networks and the computational network toolkit. Technical Report MSR-TR-2014-112, August 2014. [5] Riyadh Baghdadi, Ulysse Beaugnon, Albert Cohen, Tobias Grosser, Michael Kruse, Chandan Reddy, Sven Verdoolaege, Adam Betts, Alastair F. Donaldson, Jeroen Ketema, Javed Absar, Sven van Haastregt, Alexey Kravets, Anton Lokhmotov, Robert David, and Elnar Hajiyev. Pencil: A platform-neutral compute intermediate language for accelerator programming. In Proceedings of the 2015 International Conference on Parallel Architecture and Compilation (PACT), PACT ’15, pages 138–149, Washington, DC, USA, 2015. IEEE Computer Society. [6] Frédéric Bastien, Pascal Lamblin, Razvan Pascanu, James Bergstra, Ian J. Goodfellow, Arnaud Bergeron, Nicolas Bouchard, and Yoshua Bengio. Theano: new features and speed improvements. Deep Learning and Unsupervised Feature Learning NIPS 2012 Workshop, 2012. [7] Tianqi Chen, Mu Li, Yutian Li, Min Lin, Naiyan Wang, Minjie Wang, Tianjun Xiao, Bing Xu, Chiyuan Zhang, , and Zheng Zhang. MXNet: A flexible and efficient machine learning library for heterogeneous distributed systems. In Neural Information Processing Systems, Workshop on Machine Learning Systems (LearningSys’15), 2015. [8] Tien-Fu Chen and Jean-Loup Baer. Effective hardware-based data prefetching for high-performance processors. IEEE Transactions on Computers, 44(5):609–623, May 1995. [9] Yu-Hsin Chen, Joel Emer, and Vivienne Sze. Eyeriss: A spatial architecture for energy-efficient dataflow for convolutional neural networks. In Proceedings of the 43rd International Symposium on Computer Architecture, ISCA ’16, pages 367–379, Piscataway, NJ, USA, 2016. IEEE Press. [10] Yunji Chen, Tao Luo, Shaoli Liu, Shijin Zhang, Liqiang He, Jia Wang, Ling Li, Tianshi Chen, Zhiwei Xu, Ninghui Sun, and Olivier Temam. Dadiannao: A machine-learning supercomputer. In Proceedings of the 47th Annual IEEE/ACM International Symposium on Microarchitecture, MICRO-47, pages 609–622, Washington, DC, USA, 2014. IEEE Computer Society. [11] S. J. Eggers, J. S. Emer, H. M. Levy, J. L. Lo, R. L. Stamm, and D. M. Tullsen. Simultaneous multithreading: a platform for next-generation processors. IEEE Micro, 17(5):12–19, Sept 1997. 17 [12] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Identity mappings in deep residual networks. arXiv preprint arXiv:1603.05027, 2016. [13] James Hegarty, John Brunhaver, Zachary DeVito, Jonathan Ragan-Kelley, Noy Cohen, Steven Bell, Artem Vasilyev, Mark Horowitz, and Pat Hanrahan. Darkroom: Compiling high-level image processing code into hardware pipelines. ACM Trans. Graph., 33(4):144:1–144:11, July 2014. [14] Troels Henriksen, Niels G. W. Serup, Martin Elsman, Fritz Henglein, and Cosmin E. Oancea. Futhark: Purely functional gpuprogramming with nested parallelism and in-place array updates. In Proceedings of the 38th ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2017, pages 556–571, New York, NY, USA, 2017. ACM. [15] Andrew G. Howard, Menglong Zhu, Bo Chen, Dmitry Kalenichenko, Weijun Wang, Tobias Weyand, Marco Andreetto, and Hartwig Adam. Mobilenets: Efficient convolutional neural networks for mobile vision applications. CoRR, abs/1704.04861, 2017. [16] N. P. Jouppi. Improving direct-mapped cache performance by the addition of a small fully-associative cache and prefetch buffers. In [1990] Proceedings. The 17th Annual International Symposium on Computer Architecture, pages 364–373, May 1990. [17] Norman P. Jouppi, Cliff Young, Nishant Patil, David Patterson, Gaurav Agrawal, Raminder Bajwa, Sarah Bates, Suresh Bhatia, Nan Boden, Al Borchers, Rick Boyle, Pierre-luc Cantin, Clifford Chao, Chris Clark, Jeremy Coriell, Mike Daley, Matt Dau, Jeffrey Dean, Ben Gelb, Tara Vazir Ghaemmaghami, Rajendra Gottipati, William Gulland, Robert Hagmann, C. Richard Ho, Doug Hogberg, John Hu, Robert Hundt, Dan Hurt, Julian Ibarz, Aaron Jaffey, Alek Jaworski, Alexander Kaplan, Harshit Khaitan, Daniel Killebrew, Andy Koch, Naveen Kumar, Steve Lacy, James Laudon, James Law, Diemthu Le, Chris Leary, Zhuyuan Liu, Kyle Lucke, Alan Lundin, Gordon MacKean, Adriana Maggiore, Maire Mahony, Kieran Miller, Rahul Nagarajan, Ravi Narayanaswami, Ray Ni, Kathy Nix, Thomas Norrie, Mark Omernick, Narayana Penukonda, Andy Phelps, Jonathan Ross, Matt Ross, Amir Salek, Emad Samadiani, Chris Severn, Gregory Sizikov, Matthew Snelham, Jed Souter, Dan Steinberg, Andy Swing, Mercedes Tan, Gregory Thorson, Bo Tian, Horia Toma, Erick Tuttle, Vijay Vasudevan, Richard Walter, Walter Wang, Eric Wilcox, and Doe Hyun Yoon. In-datacenter performance analysis of a tensor processing unit. In Proceedings of the 44th Annual International Symposium on Computer Architecture, ISCA ’17, pages 1–12, New York, NY, USA, 2017. ACM. [18] Fredrik Kjolstad, Shoaib Kamil, Stephen Chou, David Lugato, and Saman Amarasinghe. The tensor algebra compiler. Proc. ACM Program. Lang., 1(OOPSLA):77:1–77:29, October 2017. [19] Daofu Liu, Tianshi Chen, Shaoli Liu, Jinhong Zhou, Shengyuan Zhou, Olivier Teman, Xiaobing Feng, Xuehai Zhou, and Yunji Chen. Pudiannao: A polyvalent machine learning accelerator. In Proceedings of the Twentieth International Conference on Architectural Support for Programming Languages and Operating Systems, ASPLOS ’15, pages 369–381, New York, NY, USA, 2015. ACM. [20] Ravi Teja Mullapudi, Andrew Adams, Dillon Sharlet, Jonathan Ragan-Kelley, and Kayvon Fatahalian. Automatically scheduling halide image processing pipelines. ACM Trans. Graph., 35(4):83:1–83:11, July 2016. [21] Shoumik Palkar, James J. Thomas, Deepak Narayanan, Anil Shanbhag, Rahul Palamuttam, Holger Pirk, Malte Schwarzkopf, Saman P. Amarasinghe, Samuel Madden, and Matei Zaharia. Weld: Rethinking the interface between data-intensive applications. CoRR, abs/1709.06416, 2017. [22] Jonathan Ragan-Kelley, Connelly Barnes, Andrew Adams, Sylvain Paris, Frédo Durand, and Saman Amarasinghe. Halide: A language and compiler for optimizing parallelism, locality, and recomputation in image processing pipelines. In Proceedings of the 34th ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI ’13, pages 519–530, New York, NY, USA, 2013. ACM. [23] James E. Smith. Decoupled access/execute computer architectures. In Proceedings of the 9th Annual Symposium on Computer Architecture, ISCA ’82, pages 112–119, Los Alamitos, CA, USA, 1982. IEEE Computer Society Press. [24] Michel Steuwer, Toomas Remmelg, and Christophe Dubach. Lift: A functional data-parallel ir for high-performance gpu code generation. In Proceedings of the 2017 International Symposium on Code Generation and Optimization, CGO ’17, pages 74–85, Piscataway, NJ, USA, 2017. IEEE Press. [25] Sven Verdoolaege, Juan Carlos Juega, Albert Cohen, José Ignacio Gómez, Christian Tenllado, and Francky Catthoor. Polyhedral parallel code generation for cuda. ACM Trans. Archit. Code Optim., 9(4):54:1–54:23, January 2013. 18 [26] Vasily Volkov. Understanding Latency Hiding on GPUs. PhD thesis, University of California at Berkeley, 2016. [27] Richard Wei, Vikram Adve, and Lane Schwartz. Dlvm: A modern compiler infrastructure for deep learning systems. CoRR, abs/1711.03016, 2017. 19
6cs.PL
Learning Robust Video Synchronization without Annotations Patrick Wieschollek∗† , Ido Freeman∗ and Hendrik P.A. Lensch∗ arXiv:1610.05985v3 [cs.CV] 16 Sep 2017 † Max ∗ University of Tübingen Planck Institut for Intelligent Systems Abstract—Aligning video sequences is a fundamental yet still unsolved component for a broad range of applications in computer graphics and vision. Most classical image processing methods cannot be directly applied to related video problems due to the high amount of underlying data and their limit to small changes in appearance. We present a scalable and robust method for computing a non-linear temporal video alignment. The approach autonomously manages its training data for learning a meaningful representation in an iterative procedure each time increasing its own knowledge. It leverages on the nature of the videos themselves to remove the need for manually created labels. While previous alignment methods similarly consider weather conditions, season and illumination, our approach is able to align videos from data recorded months apart. I. I NTRODUCTION Understanding and assessing the current situation around us in a single glance is necessary to interact with the world as we know it. Looking at Figure 1 within few tens of milliseconds, we can verify that the highlighted frames show the same scene although they are recorded at different times, having different illumination, motion blur and seasonal effects. For this task, we are focusing with ease on useful traits like the location of the houses or the shape of the street and are masking irrelevant features such as traffic or the actual road condition. From our experience we are familiar with all effects that might change the current appearance and understand the global context. For computing a temporal video alignment (synchronization), i.e. a dense frame-to-frame mapping for each time step in the involved videos with consistency along the time dimension, classical approaches are based on matching local descriptors [1], [2], [3], [4]. While they allow for accurate video alignments, they are limited to video pairs of short video clips sharing very similar appearance. However, longer videos capturing the same content at different times might look completely different besides additional challenges such as ego- and object-motion or changes of the view angle and illumination. Though data-driven approaches like deep convolutional neural networks have proven excellent performance and capabilities of global scene understanding [5], they usually require a large amount of high-quality labeled training data. One way to automate the labeling process would be to record synchronization signals such as Longitudinal Time Codes, genlock, GPS data or a landmark-based audio fingerprinting [6] during acquisition. Solutions based on this kind of additional data are as accurate as the device which registered the data. Besides its limitation to out-door scenes, GPS has a common precision of three meters [7]. While minor alignment errors would not be visible in vanilla image alignment, any such non-frame accurate alignment would become apparent during simultaneous video playback. In many real-world scenarios, these explicit synchronization signals are not available as most consumer cameras only encode the creation date of the video file within the meta-data. Directly applying learning based approaches like [8] to learn the alignment is not possible in this case. Producing a dense labeling by manual effort is not feasible either1 . Our dataset consists of 28 million frames. Note, the ILSVRC challenge [9] is based on 1.4 million labeled images only. Particularly, in our setting, we deal with unstructured video content without any explicit knowledge about which frames or entire videos do match or not. To overcome these problems, we propose a novel learningbased approach: – Section III introduces a new challenging dataset for video-alignment covering rural scenes as well as city scenes across a year under different appearances. – In Section IV we propose a novel training protocol for training a neural network to match frames from different videos of the same scene without any annotation. – Section IV-C presents a novel method for robust identification and computation of matching tours for partially overlapping video pairs, which is able to automatically detect start and end points of the matching tour. II. R ELATED W ORK The process of video alignment holds a natural relation to image alignment which was addressed by several studies [10], e.g. using stereo correspondence estimation [11] or robust pixel descriptors [12]. Algorithms like video stitching for creating panoramic videos [2], automatic summarization of videos [13], HDR video generation [14], vehicle detection for advanced driver assistance systems [15] and video-copy detection [16] among others are heavily dependent on such a robust and accurate temporal alignment of video-frames between multiple videos. Basic video alignment is commonly used in the field of human action retrieval or surveillance motion capture. Here, finding similarities of human actions in videos are based on 1 Thoroughly aligning a video pair of 8 min length by hand takes 41min. Fig. 1. Given a pair of videos (top) our network has learned to robustly embed each frame (left) in a high dimensional feature space (middle) independently from appearance changes caused by weather, traffic or seasonal effects. Given these feature vectors, the algorithm retrieves the most plausible frame mapping for a synchronous playback (dark path, right). Our approach autonomously learned to compare these frames during training without any human annotation or labels. dynamic time warping of various sensor features to track the human skeleton [17]. Bazin et al. introduced ActionSnapping [18] which focuses on synchronizing actions performed by humans such as weightlifting, baseball pitching or dancing assuming a static background scene and frontal views. Most approaches for spatio-temporal video alignment [19], [20], [21], [22], [23] assume a linear temporal correspondence, i.e. a constant time shift between successive frames or a constant change in playback speed for one video. Sand and Teller [3] compute a matching-likelihood of 3D motion to match videos. A non-linear solution was proposed by Wang et al. [4] based on a matching histogram of SIFT features using nearest neighbour search. Here, the search space increases with the length of the video sequence. In terms of application the most similar work to ours is from Evangelidis et al. [24], [25], which allows for sub-frame accurate alignments of at most one minute video snippets under negligible appearance changes on rather simple street scenes. Another related task is to recognize places from different view angles. A data-driven version of VLAD descriptors by Arandjelovic et al. [8] demonstrates the capability of neural networks to detect specific locations. Compared to place recognition video alignment however requires a much finer resolution. Figure 2 illustrates typical examples of frame-pairs from different datasets which are considered as similar for the specific task. Learning similarities by training neural networks was done previously for very specific applications such as signature verification [26], face recognition [27], [28] and comparing image patches for depth estimation [29]. They rely on datasets with extensive human annotations and reliable ground-truth data. III. DATASET Our underlying dataset comprises of 602 full-HD, 30FPS videos (1.8 TB of raw data) capturing 260 hours of commuters’ car journeys on partially overlapping routes between April 2012 and March 2013 and spanning over approximately 16, 000km. The videos were captured using a GoPro Hero 2 a b c d Fig. 2. Comparing the data sets of related work. Each pair shows a typical matching frame-pair. a) [24] only shows small changes in appearance and perspective, b) [30] has a totally different view angles and c) [31] requires only a constant time shift for alignment. For our dataset d), an alignment method has to handle a different appearance and produce a playback with non-linear speed. camera mounted on the dashboard before every journey without special adjustments. However, the view angle does not feature differences as large as in place recognition tasks [8]. The acquired videos feature both rural landscapes and urban scenes under varying traffic conditions such as temporary road works, rush hour, diverse weather conditions, e.g., snowfall, rain, and seasonal environment appearance, for example effects of vegetation as well as different daytime illumination (see Figure 2d) and the supplemental video https://youtu.be/ vhVsw4qoe70). Most videos show journeys between the same two cities but still have a variation in start and end locations and the actual roads driven. The temporal alignment of the videos thus poses a further challenge when trying to match stationary situations like waiting in traffic during rush hour with a video showing little traffic. This is different to linear video alignment tasks like copy-detection described in [31]. The enormous range of possible variations in the video content which also suffers from a noisy acquisition (e.g. different viewing angles, wipers, raindrops, camera transformation, etc.) requires some understanding of context of the entire scene rather than a simple local feature matching like histogram based methods [4], [18], [25]. Moreover, the videos might show interrupted content, e.g. when the lens is cleaned or remounted during recording. We propose a framework to learn descriptors for all frames such that the Euclidean distance represents a similarity metric between captured scenes or locations. By properly designing the training protocol this generic approach features fast matching computation, robustness against seasonal effects and it does not rely on pre-existing labels for training. The similarity metric can be exploited to robustly synchronize videos as will be explained in Section IV-C. While first establishing the procedure to align partially overlapping video pairs (X, Y ) it is straightforward to extend it to multiple videos in a collection (see Figure 13). a) Curriculum Learning.: The algorithm alternates between two steps: the learning step and the label generation step. In the learning step, we assume given labels ℓ and train a neural network to produce meaningful descriptors for a similarity metric δ. The label-generation is based on the current version of the trained network combined with tour matching (Section IV-C) to exploit temporal consistency. Given the learned similarity metric δ novel, potentially more reliable labels are produced, replacing the old ones. Over multiple iterations, more and more sophisticated and more informative training data is generated. None of these steps requires any human annotation nor recorded GPS signals. A. Learning Step In the learning step we want to learn an embedding of frames to establish a similarity measure between individual frames (x, y). Relying on the currently available labels from the training data we train a convolutional neural network (CNN) [32] to predict a high-dimensional descriptor Φi for each frame i such that the Euclidean distance (1) (x, y) 7→ δ(x, y) := kΦx − Φy k2 is small when the frames are similar and vice versa. We use the standard ResNet-50 architecture [33] and add a projection from the pool5 layer to learn the 1000-dimensional descriptors Φi . As CNNs tend to learn edge filters in the first layers, we use a pre-trained ResNet version for object recognition as initialization. In order to efficiently train the concept of similarity the triplet neural network approach [34] with weight-sharing is used, which generalizes well to unseen examples. It requires labels ℓ = (a, p, n) in the form of triplets of frames: for an anchor frame a the label needs one similar or positive frame p and one negative/dissimilar frame n. The similarity metric δ (Eq. (1)) is enforced by minimizing the triplet loss by Hoffer et al. [34] h i 2 2 L(a, p, n) = m + kΦa − Φp k2 − kΦa − Φn k2 (2) + for some margin m ∈ R. The first term penalizes embeddings of similar frame-pairs (a, p) that are too far away from each other in the high dimensional feature space. The latter penalizes embeddings of negative (non-matching) frame-pairs (a, n) if they are too close to each other (closer than some triplet IV. U NSUPERVISED C URRICULUM L EARNING a CNN p CNN n CNN Φa Φp Φn Fig. 3. Let (a, p, n) be a frame-triplet with descriptors (Φa , Φp , Φn ) produced by the same CNN. During training, the CNN is optimized to embed positive frames p close to the anchor point a, while negative frames n are pulled away from the anchor point if the distance is smaller than a margin m. margin m – Figure 3). In practice, we constrain this embedding to live on the d-dimensional hypersphere, i.e. kΦi k2 = 1 and set m to 0.5. B. Label Generating Step While the learning step is rather straight-forward the challenge lies in automatically generating appropriate frame-triplet labels as training data. This label-generating step automatically harvests new training data for subsequent learning steps by explicitly exploiting the coherence in videos and by proposing and judging video alignments based on current knowledge. The goal is to gather more and more informative training data in each iteration by successively increasing the difficulty, i.e. to find positive frame pairs which show the same scene location but with potentially different appearance as well as finding negative pairs which currently are assigned rather similar embeddings. This is achieved in three waves: Iteration 0: intra-video sampling of nearby frames for initial training Iteration 1+: inter-video sampling of frames from matching tours Iteration 2+: transitive inter-video sampling of frames from matching tours by propagation of alignments to other videos After each iteration of the label-generating step we retrained the neural network in the learning step, alternating between training and label generation. a) Iteration 0.: In Iteration 0 one has to solve the dilemma of generating reliable labels ℓ without having any trained network for proposing distances δ. Instead we rely on the inherent coherence within the same video. Any arbitrary frame-pair which is at most 15 frames apart serves as positive sample (a, p). Any other random frame sufficiently far away from a is regarded as a negative frame n. b) Iteration 1+.: After the first iteration the network is trained and can now produce features Φi for each frame i which is carried out for every tenth frame of all videos in the data set. One can use the proposed Φi for approximating the pair-wise similarity, but since the network is not fully trained p n a i) iii) Fig. 5. Computed similarity matrix from the first iteration in our training process (left). As they contain highly correlated entries, directly finding a matching tour would fail. After the de-correlation of the cost matrix (middle) finding a path (right) is significantly more robust. ii) iv) Fig. 4. Development of the cost matrix of the same video pair throughout the iterative training process. Dark entries represent frame-pairs that are considered similar having a small distance in the feature space. Note how the path (red) of similar frame-pairs becomes more distinct. Large coherent regions along the path indicate stand-still, e.g. waiting at a traffic light. We further highlight matching frames a, p and hard negative n. yet it is essential to judge whether we can rely on a particular frame encoding or not. The criteria for accepting a positive frame pair or detecting a negative one in this step is based on temporal coherence by potential matching tours between distinct videos (X, Y ). A cost matrix C = (δ(Φx , Φy ))x,y , x ∈ X, y ∈ Y (3) can be computed containing all coarse pair-wise distances of frames. Corresponding frames should have a small distance. Though this might not always be the case in early iterations, it might already be possible to detect a matching tour as explained in Section IV-C, i.e. to find an optimal path through the cost matrix (see Figure 4). If the path is sufficiently distinct the path will synchronize both videos correctly and all nodes on the path resemble positive pairs with row a and column p, independent of the currently proposed measure δ(a, p). Some new positive pairs might be found this way giving hints on how to optimize the embedding in the next training phase. Similarly, we can harvest challenging negative pairs (a, n) by just choosing a column n sufficiently far away from the path. Most informative will be such a pair if δ(a, n) is currently rather small, indicating similarity though the frames clearly should be rated distinct. Though we might not find all possible paths between all videos yet, the resulting labels ℓ(a, p, n) will be more informative than in the previous iteration as the appearance between two videos will more likely be different even for matching frames. The process is visualized in Figure 4 where the correct matching path becomes more obvious and easier to detect throughout the iterative training. c) Iteration 2+.: Computing a cost matrix for each single video pair is inefficient. Instead, we propagate detected matching tours transitively to other pairs. Based on the property of “X and Y have a matching tour”, denoted as X ∼ Y , is a equivalence relation (meeting the requirements reflexivity, symmetry and transitivity), we propose a transitive sampling. In fact, our entire dataset can be split into distinct equivalent classes V / ∼ under the relation X ∼ V when videos X and V share a part of the same tour. Hence for any two videos X and Y ∈ V / ∼ we already know the existence of a matching tour X ∼ V and V ∼ Y . Transitivity also directly gives us a matching tour for X ∼ Y if both share some overlap. This allows us to sparsely sample video-pairs and propagate matching frames across videos. Using a tree-based index structure reduces the complexity to O(n log n) when synchronizing n videos (see Figure 13). Through transitivity one can establish matching tours which so far could not be detected using the previously trained embeddings. With this iterative process we can quickly generate a huge number of challenging and informative training triplets ℓ(a, p, n) even for videos which have been captured months apart. Starting in iteration 2 we mix the obtained training examples from inter-video sampling (iteration 1+) and transitive intervideo sampling (iteration 2+). C. Finding Matching Tours We will now describe how to find a matching tour given a cost matrix C. The entire iterative scheme is based on robustly detecting false-positives from the network prediction and producing complex training data in a reliable way. 1) Pre-Processing: De-correlate Costs: Particularly in the early iterations, the similarity matrices C produced by the CNN contain a lot of false predictions, since it is not yet fully adapted to the task. These errors exhibit a low-rank structure, because any frame that is not correctly embedded is likely to corrupt an entire column (or row) of the similarity matrix (left of Figure 5). Additionally, some of the pairs are, indeed rather similar although we would like to treat them as different. For example, many journeys through rural areas with little information but crop fields on both sides of the road appear extremely similar. As a pre-processing to the tour extraction c̃s,t = 0, (c̃)i,j = min {c̃i−1,j , c̃i−1,j−1 , c̃i,j−1 } (cdirect )i,j = arg min {c̃i−1,j , c̃i−1,j−1 , c̃i,j−1 } (4) (5) and infinite costs ∞ for not reachable frames. Following the path backwards encoded in (cdirect ) from (v, w) gives a path P with lowest costs between (s, t) and (v, w). Figure 5 shows such a path from our augmented version. 3) Augmented Dijkstra’s Algorithm: Unfortunately, we neither know the start- nor end-point in contrast to the vanilla version used in [4] nor can we guarantee that there is a path through the entire cost matrix, e.g. consider different sub-tours. For most videos of a large collection one does not even know if two videos match at all. We augment Dijkstra’s algorithm by processing subsequences individually with the goal to flexibly handle non-matching regions without corrupting the entire path when searching for the global optimum over the entire matrix. The coarse cost matrix C is split along one time dimension into multiple overlapping column-stripes C0 , C1 , . . . , Cn (see Figure 6) each containing 90 seconds of the video. Now, our approach tries to find a matching tour through the entire cost matrix building on possible tours from each stripe. a) Local tours within stripes.: Let us consider such a single stripe Ck . Introducing an artificial start node with zero costs to the left enables almost complete freedom regarding the location of each match within one stripe. We are only interested in finding a matching tour from the left ci,0 to the right cj,N in the current stripe. Further, this artificial start node allows us to treat each stripe individually For the final extraction we remove path parts from the overlap –taking all information but the overlap– as Dijkstra tends to deviate (see Figure 7) from the correct path near the borders of the stripe. For each stripe the vanilla regularized S1 c11 c12 c13 c21 c22 c23 c31 c32 c33 S2 c14 c15 c16 c24 c25 c26 c34 c35 c36 timeline of video b timeline of video a we remove those correlation effects Pr by subtracting a low-rank matrix approximation C ′ ← C− k=1 Uk Σk Vk⋆ from singular value decomposition U ΣV ⋆ of C. The result is illustrated in Figure 5 (middle) using rank r = 5. Abusing notation we further denote the de-correlated cost matrix C ′ as C. 2) Formulation as a Shortest Path Algorithm: The only missing step for aligning a video pair is to find a plausible path through its respective de-correlated cost matrix. Intuitively, a path is a collection of consecutive frame-pairs of minimal matching costs. Matching frame-pairs should lie on a clearly distinct path in the cost matrix. A well-studied algorithm to solve a shortest-path problem is Dijkstra’s Algorithm. For a given start- and endpoint it computes the globally optimal path with minimum cost. We shortly outline the vanilla grid-version when applying to the cost matrix C. a) Dijkstra’s algorithm.: For detecting paths we only allow for three directions: downwards, rightwards and a diagonal bottom-right step basically preventing reverse playback and assuming non-negative costs, i.e. cij ≥ 0. Given a start-entry (s, t) and end-point (v, w) with s ≤ v and t ≤ w the algorithm propagates costs C̃ in a dynamic programming approach with entries C0 C1 C2 Fig. 6. Given a cost matrix C, we split up one video by dividing the cost matrix into overlapping stripes C0 , C1 , . . .. Finding the local shortest path in each stripe independently and testing for plausibility in the overlap region, we obtain a reliable matching tour for synchronizing videos. Ci Fig. 7. For any decorrelated cost matrix C (left), we applied our augmented Dijkstra’s algorithm unaware of start- and endpoint for overlapping stripes. This gives stripe-wise propagated costs for the entire video snippet (middle). Our heuristic classifies between non-consistent tours-snippets (red, e.g. the deviation effect) and reliable tour-snippets (green). The parts illustrated as blue lines will be only taken into account if the do not violate the global consistency constraint. All images are best viewed in the electronic version. Dijkstra’s algorithm is applied as described from St to St+1 by only allowing the three mentioned directions. Each possible path Pt = (St , p1 , p2 , . . . , pn , St+1 ) has associated matching costs defined as X c(p), (6) π(Pk ) = p∈Pk where c(p) is equivalent to an entry cab in the cost matrix C for the frame-pair p = (a, b). Combining local tours to a global matching tour.: As a robust global matching tour does not necessarily span the entire cost matrix and all stripes, e.g. for detours, we reject local stripes which cannot be connected to any neighboring stripes with a tolerance of up to two seconds. This tolerance accounts for the fact that we currently only consider coarse information (each 10-th frame). Further, applying Dijkstra’s algorithm to each stripe individually might generate local paths of minimum costs, which are not necessarily a matching tour – there does not have to be such a matching tour at all. We therefore, reject local stripes with entries (x, y) ∈ Pk from the local matching tour, if an alternative frame-pair p′ ∈ {(x ± ε, y), (x, y ± ε)} does not have significant higher associated costs than p, i.e. we simply use the threshold c(p′ ) > 65 c(p). This threshold might be conservative but the specific choice only impacts a small fraction of paths during exploration. TABLE I T IMINGS FOR EXTRACTING FEATURES FROM UNSEEN VIDEOS . E NABLING HIGH FRAME - RATES IS ESSENTIAL ON LARGE - SCALE DATASETS . approach [24], [25] [4] [31] ours fps 0.11 3.77 15 140 All remaining frame-pairs from the global matching tour are considered for the generation of the next training dataset version. D. Final Alignment of Videos So far, we only considered each 10-th frame during training. In order to prevent visual miss-alignment due to interpolation artifacts in the final alignment the full temporal resolution is required. A coarse-to-fine approach only computes entries of C̄ at finer resolution if they are near a matching tour in the coarse cost matrix C. The global matching tour is split into chunks of the same size. For each chunk, we compute all frame distances. As the start and end point of the matching tour through a single box is known, we directly apply vanilla Dijkstra’s algorithm without further modification. Modifying the playback speed of only one video would introduce visible jumps and spurts in this video when matching to the reference video. Consider a linear playback of a reference scene with green traffic light, while the other video has to jump over the frames when waiting on red. To achieve visually pleasing video playback, we smooth the matching tour along both time dimensions using Kalman filters with the additional constraint to not revert the time line of a single video. seconds due to multiple runs of the path finding procedure on finer scale. This gives a speed-up factor of at least 300 compared to [4], [24], [25]. So far ours is the first approach enabling large-scale interactive applications. See the https://youtu.be/vhVsw4qoe70 for a real-time demonstration. For processing many more videos additional search structures might be used. B. What is the network looking for? For aligning videos, the network has to distinguish between relevant and irrelevant regions in the frame, e.g. the appearance of traffic and road lanes and the weather depend on the moment of recording. To visualize which input information are used inside the neural network for a particular prediction, we compute saliency maps using guided-ReLU [35]. Informally, it computes the gradient information of the network output wrt. to the input images holding all weights fixed. This indicates which pixel information in the input image have large impact on the network prediction. Compared to the vanilla ResNet50 our trained model learned to ignore irrelevant information like traffic, see Figure 9. Instead it focuses on the shape of the horizon and vegetation of the environment. This is not possible by previous methods [18], [3], [4], [24], [25] as they also put attention on passing cars and clouds as depicted in the lower row of Figure 9. ours SIFT costs cleaned costs cleaned costs V. R ESULTS AND E XPERIMENTS The following results and timings are obtained on a single workstation with an Nvidia Titan X GPU. We demonstrate the robustness on aligning a couple of challenging scenes. To evaluate our method despite missing ground truth, we compare our convnet prediction of similarity to [24], [25], the SIFTbased histogram matching from [4], conducted a user study and evaluate against a manually alignment of videos. A. Timings and memory consumptions Our approach compares favorably to a local-feature-based approach concerning the run time (Table I) and has small storage requirements (102 MB for the network weights). When considering every 10-th frame of a single video with length 35 minutes, the embedding takes 45 seconds in total. This allows us to efficiently compute new embeddings of the entire dataset of 260 hours content for the training procedure within less than half an hour using 12 GPUs. The path detection and extraction procedure to produce coarse paths on unseen video-pairs of 35 minutes each takes two seconds given the embeddings. This splits into pairwise-distance computation (1071 ms, GPU), decorrelation (370 ms, CPU) and path detection/computation (405 ms, CPU). Computing the final matching tour takes 6 a b Fig. 11. Although, there should be a matching tour between frames in a and b through the entire video snippet, it is not possible to align both videos using SIFT features [4]. Our network was able to learn similar feature embeddings even between these videos taken in September 2012 and February 2013 respectively. The cost matrix in our approach contains reasonable information for most frames. C. Robustness and Accuracy In contrast to methods solely based on aggregating SIFT features, our method is able to even match videos captured five months apart as depicted in Figure 11. Remarkably, as the videos for the dataset are collected over multiple months the network has learned to interpret scenes globally. Even sequences where human interventions like tree-felling cause a rather different look of the same scene, the corresponding Fig. 8. Each row contains pairs of coarsely aligned videos (every 10-th frame) across different seasons, lightning, weather conditions as well as vegetation. These videos are taken from the validation set and are not used during training. Notable, the algorithm can robustly handle windscreen wipers, motion blur and raindrops on the wind shield. frame untrained trained Fig. 10. The left frame was captured in November 2012 and right frame in March 2013 after tree felling works. These kinds of differences cause high matching costs of the found tour in our approach, but the situation is resolved by our matching tour procedure exploiting temporal consistency. HARRIS SIFT ours Fig. 9. The network (right) learned to ignore common content such as traffic or road lanes and instead focuses on striking environment information compared to vanilla ResNet (middle). Previous methods [18], [3], [4], [24], [25] rely on local features, capturing irrelevant information like the white car in the lower row. videos are correctly synchronized by our approach as we enforce temporal consistency. To evaluate the accuracy quantitatively, we manually judged 500 tours predicted by our approach from the cost matrices (see Figure 4, left). Note, how the accuracy increases over the iterations. Hence, the harvested additional training data of higher complexity results in a higher recall of found matching tours. In addition, we thoroughly annotated the videos from Figure 8 for two experiments by manually fitting the best visual matching frame, well knowing the shown locations and temporal context. In a user-study we showed a single reference frame and the manually aligned frames besides several similar neighboring frames. The evaluation of 450 submitted results from 14 participants is illustrated in Figure 8, which reveals discordance between different participants on the same frame. 9.4% f true positives found paths 70% 0 1 2 3 9.2% found paths ratio of frames true positives 30% 9.3% 75% algorithm userstudy 20% 10% 0% iteration 0 2 4 6 8 10 offset to throughly manual annotation Fig. 12. Comparison to human annotated alignment. After each iteration we report (left) the number of found matching tours between videos and true positives and the mis-alignment (right) against a human annotation. Approximately, 53% agree with a tolerance of 4 frames. This clearly demonstrates the difficulty of this task, probably caused by changes of camera perspective, lacking temporal information in rural scenes or unfamiliarity with the shown locations. This might also contain effects as in Figure 10. Second, we directly compared the frame-distance between our annotations and the extract path of our approach. This compares favorably to our estimated human performance as 62% of the predicted frame-pairs have a frame offset of at most 4 frames. D. Limitations Despite its good performance, our approach is subject to a number of limitations. Ignoring the high-res input might drop discriminative small local clues, which could be solved by attention techniques [36], [37]. Spatial Transformer Network Layers [38] which also facilitates optical flow estimation could account for spatial displacement between matching frames caused by the current acquisition method. Recently proposed methods like [39] can be included to also directly learn spatial alignments. While we apply Kalman filtering to smooth the matching tours, one might formulate this as a discrete optimization problem to include the produced matching costs by the neural network. VI. C ONCLUSION We present a novel combination of deep neural networks and path finding algorithms for synchronizing videos by approximating the similarity of frame-pairs based on the feature embedding by a deep convolutional neural network. Matching tours between two videos are determined along the resulting frame-based similarity matrices. To improve the extraction of the correct matching tours we propose pre-processing of these cost matrices and a regularized version of Dijkstra’s algorithm on cost-stripes to satisfy time constraints. Our training method relies on an iterative scheme to automatically gather new labels completely avoiding manual annotations. The system verifies temporal consistency of predictions to create newly labeled training data. Utilizing the transitivity of matching tours between multiple video-pairs increases the complexity of the input data gradually and allows us to robustly synchronize videos months apart under different weather conditions and vegetation. The system opens up several exciting directions for future research, e.g. label-transfer between densely annotated videosframes and automatically synchronized videos with different Fig. 13. Multiframe temporal alignment: After quering similar and time consistent video snippets using the learned embeddings, the approach is able to robustly synchronize all found snippets to a reference video snippet. appearances. Hence, the label annotation for large video collections can be done in shorter time and for fewer costs. Learning appearance modification as in [40] or a dynamic version of content blending as described in [41] are further exciting applications, which can benefit from our learningbased approach for video synchronization. R EFERENCES [1] J. Rüegg, O. Wang, A. Smolic, and M. Gross, “Ducttake: Spatiotemporal video compositing,” in Computer Graphics Forum, vol. 32, no. 2pt1. Wiley Online Library, 2013, pp. 51–61. [2] A. Agarwala, K. C. Zheng, C. Pal, M. Agrawala, M. Cohen, B. Curless, D. Salesin, and R. Szeliski, “Panoramic video textures,” in ACM Transactions on Graphics (SIGGRAPH), ser. SIGGRAPH ’05. New York, NY, USA: ACM, 2005, pp. 821–827. [Online]. Available: http://doi.acm.org/10.1145/1186822.1073268 [3] P. Sand and S. Teller, “Video matching,” ACM Trans. Graph., vol. 23, no. 3, pp. 592–599, Aug. 2004. [Online]. Available: http://doi.acm.org/10.1145/1015706.1015765 [4] O. Wang, C. Schroers, H. Zimmer, M. Gross, and A. Sorkine-Hornung, “Videosnapping: Interactive synchronization of multiple videos,” ACM Trans. Graph., vol. 33, no. 4, pp. 77:1–77:10, Jul. 2014. [Online]. Available: http://doi.acm.org/10.1145/2601097.2601208 [5] I. Masuda Mora, S. de la Puente, and X. Giro-i Nieto, “Open-ended visual question answering,” B.S. thesis, Universitat Politècnica de Catalunya, 2016. [6] N. Bryan, P. Smaragdis, and G. Mysore, “Clustering and synchronizing multi-camera video via landmark cross-correlation,” in Proceedings of the IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), March 2012, pp. 2389–2392. [7] “Global positioning system standard sositioning service serformance standard,” 2008. [8] R. Arandjelović, P. Gronat, A. Torii, T. Pajdla, and J. Sivic, “NetVLAD: CNN architecture for weakly supervised place recognition,” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2016. [9] O. Russakovsky, J. Deng, H. Su, J. Krause, S. Satheesh, S. Ma, Z. Huang, A. Karpathy, A. Khosla, M. Bernstein, A. C. Berg, and L. Fei-Fei, “ImageNet Large Scale Visual Recognition Challenge,” International Journal of Computer Vision (IJCV), vol. 115, no. 3, pp. 211–252, 2015. [10] L. G. Brown, “A survey of image registration techniques.” ACM Comput. Surv., vol. 24, no. 4, pp. 325–376, 1992. [Online]. Available: http://dblp.uni-trier.de/db/journals/csur/csur24.html#Brown92 [11] D. Scharstein and R. Szeliski, “A taxonomy and evaluation of dense two-frame stereo correspondence algorithms,” International Journal of Computer Vision, vol. 47, no. 1, p. 742, May 2002. [Online]. Available: http://research.microsoft.com/apps/pubs/default.aspx?id=64200 [12] C. Liu, J. Yuen, and A. Torralba, “Sift flow: Dense correspondence across scenes and its applications,” Pattern Analysis and Machine Intelligence, IEEE Transactions on, vol. 33, no. 5, pp. 978–994, May 2011. [13] C.-W. Ngo, Y.-F. Ma, and H.-J. Zhang, “Video summarization and scene detection by graph modeling,” Circuits and Systems for Video Technology, IEEE Transactions on, vol. 15, no. 2, pp. 296–305, Feb 2005. [14] S. B. Kang, M. Uyttendaele, S. Winder, and R. Szeliski, “High dynamic range video,” ACM Trans. Graph., vol. 22, no. 3, pp. 319–325, Jul. 2003. [Online]. Available: http://doi.acm.org/10.1145/882262.882270 [15] F. Diego, D. Ponsa, J. Serrat, and A. M. Lpez, “Video alignment for change detection.” IEEE Trans. Image Processing, vol. 20, no. 7, pp. 1858–1869, 2011. [Online]. Available: http://dblp.uni-trier.de/db/ journals/tip/tip20.html#DiegoPSL11 [16] A. M. Bronstein, M. M. Bronstein, and R. Kimmel, “The video genome,” CoRR, vol. abs/1003.5320, 2010. [Online]. Available: http://dblp.uni-trier.de/db/journals/corr/corr1003.html#abs-1003-5320 [17] F. Zhou and F. De la Torre Frade, “Canonical time warping for alignment of human behavior,” in Advances in Neural Information Processing Systems (NIPS), December 2009. [18] J.-C. Bazin and A. Sorkine-Hornung, “Actionsnapping: Motion-based video synchronization,” ser. ECCV’16. Berlin, Heidelberg: SpringerVerlag, 2016. [19] C. Lei and Y.-H. Yang, “Tri-focal tensor-based multiple video synchronization with subframe optimization.” IEEE Transactions on Image Processing, vol. 15, no. 9, pp. 2473–2480, 2006. [Online]. Available: http://dblp.uni-trier.de/db/journals/tip/tip15.html#LeiY06 [20] L. Wolf and A. Zomet, “Wide baseline matching between unsynchronized video sequences,” International Journal of Computer Vision, vol. 68, no. 1, pp. 43–52, 2006. [Online]. Available: http://dx.doi.org/10.1007/s11263-005-4841-0 [21] T. Tuytelaars and L. J. V. Gool, “Synchronizing video sequences,” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2004, pp. 762–768. [Online]. Available: http://doi.ieeecomputersociety.org/10.1109/CVPR.2004.244 [22] Y. Caspi and M. Irani, “Spatio-temporal alignment of sequences,” IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 24, pp. 1409–1424, 2002. [23] Y. Ukrainitz and M. Irani, “Aligning sequences and actions by maximizing space-time correlations,” ser. ECCV’06. Berlin, Heidelberg: Springer-Verlag, 2006, pp. 538–550. [Online]. Available: http://dx.doi.org/10.1007/11744078 42 [24] G. D. Evangelidis and C. Bauckhage, “Efficient and robust alignment of unsynchronized video sequences.” in DAGM-Symposium, ser. Lecture Notes in Computer Science, R. Mester and M. Felsberg, Eds., vol. 6835. Springer, 2011, pp. 286–295. [Online]. Available: http://dblp.uni-trier.de/db/conf/dagm/dagm2011.html#EvangelidisB11 [25] ——, “Efficient subframe video alignment using short descriptors.” IEEE Trans. Pattern Anal. Mach. Intell., vol. 35, no. 10, pp. 2371– 2386, 2013. [Online]. Available: http://dblp.uni-trier.de/db/journals/ pami/pami35.html#EvangelidisB13 [26] J. Bromley, I. Guyon, Y. Lecun, E. Sckinger, and R. Shah, “Signature verification using a ”siamese” time delay neural network,” in Advances in Neural Information Processing Systems (NIPS), 1994. [27] S. Chopra, R. Hadsell, and Y. LeCun, “Learning a similarity metric discriminatively, with application to face verification.” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR). IEEE Computer Society, 2005, pp. 539–546. [Online]. Available: http://dblp.uni-trier.de/db/conf/cvpr/cvpr2005-1.html#ChopraHL05 [28] R. R. Varior, M. Haloi, and G. Wang, “Gated siamese convolutional neural network architecture for human re-identification.” CoRR, vol. abs/1607.08378, 2016. [Online]. Available: http://dblp.uni-trier.de/db/ journals/corr/corr1607.html#VariorHW16 [29] S. Zagoruyko and N. Komodakis, “Learning to compare image patches via convolutional neural networks,” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2015. [30] A. Torii, R. Arandjelović, J. Sivic, M. Okutomi, and T. Pajdla, “24/7 place recognition by view synthesis,” in CVPR, 2015. [31] M. Douze, J. Revaud, J. Verbeek, H. Jégou, and C. Schmid, “Circulant temporal encoding for video retrieval and temporal alignment,” International Journal of Computer Vision, 2016. [Online]. Available: https://hal.inria.fr/hal-01162603 [32] Y. LeCun, L. Jackel, L. Bottou, C. Cortes, J. S. Denker, H. Drucker, I. Guyon, U. Muller, E. Sackinger, P. Simard et al., “Learning algorithms for classification: A comparison on handwritten digit recognition,” Neural networks: the statistical mechanics perspective, vol. 261, p. 276, 1995. [33] K. He, X. Zhang, S. Ren, and J. Sun, “Deep residual learning for image recognition,” arXiv preprint arXiv:1512.03385, 2015. [34] E. Hoffer and N. Ailon, “Deep metric learning using triplet network.” CoRR, vol. abs/1412.6622, 2014. [Online]. Available: http://dblp.uni-trier.de/db/journals/corr/corr1412.html#HofferA14 [35] J. T. Springenberg, A. Dosovitskiy, T. Brox, and M. Riedmiller, “Striving for simplicity: The all convolutional net,” in arXiv:1412.6806, also appeared at ICLR 2015 Workshop Track, 2015. [Online]. Available: http://arxiv.org/abs/1412.6806 [36] K. Xu, J. Ba, R. Kiros, K. Cho, A. Courville, R. Salakhutdinov, R. Zemel, and Y. Bengio, “Show, attend and tell: Neural image caption generation with visual attention,” arXiv preprint arXiv:1502.03044, 2015. [37] Z. Yang, X. He, J. Gao, L. Deng, and A. J. Smola, “Stacked attention networks for image question answering,” CoRR, vol. abs/1511.02274, 2015. [Online]. Available: http://arxiv.org/abs/1511.02274 [38] M. Jaderberg, K. Simonyan, A. Zisserman et al., “Spatial transformer networks,” in Advances in Neural Information Processing Systems (NIPS), 2015, pp. 2008–2016. [39] A. Kanazawa, D. W. Jacobs, and M. Chandraker, “Warpnet: Weakly supervised matching for single-view reconstruction,” in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), June 2016. [40] P. Isola, J.-Y. Zhu, T. Zhou, and A. A. Efros, “Image-to-image translation with conditional adversarial networks,” arxiv, 2016. [41] R. Martin-Brualla, D. Gallup, and S. M. Seitz, “Time-lapse mining from internet photos,” ACM Trans. Graph., vol. 34, no. 4, pp. 62:1–62:8, Jul. 2015. [Online]. Available: http://doi.acm.org/10.1145/2766903
1cs.CV
arXiv:1410.0246v3 [math.GR] 19 Sep 2016 A continuum of expanders David Hume Faculté des Sciences d’Orsay Université Paris-Sud F-91405 Orsay France E-mail: [email protected] Abstract A regular equivalence between two graphs Γ, Γ′ is a pair of uniformly proper Lipschitz maps V Γ → V Γ′ and V Γ′ → V Γ. Using separation profiles we prove that there are 2ℵ0 regular equivalence classes of expander graphs, and of finitely generated groups with a representative which isometrically contains expanders. 1 Introduction Over the past forty years the study of expanders has blossomed into a rich theory touching virtually every branch of mathematics. Many different constructions of expanders are now known, the first of which was due to Margulis [Mar75, HLW06, Lub94, Lub12]. Despite the intense study, surprisingly little consideration has been given to distinguishing the large-scale geometry of families of expanders until very recently. In this paper we will think of an ε-expander as an infinite union of S distinct finite graphs X = n∈N Γn , with Cheeger constant h(Γn ) ≥ ε > 0, where each component is equipped with the shortest path metric. A (d, ε)expander is an ε-expander where every vertex has degree at most d. We distinguish expanders using regular maps. A map X → X ′ between graphs is regular if it is Lipschitz and pre-images of vertices have 2010 Mathematics Subject Classification: Primary 20F65; Secondary 05C25. Key words and phrases: expanders, coarse embeddings, separation profile, graphical small cancellation. 1 2 D. Hume uniformly bounded cardinality. This greatly generalises the geometric concepts of isometric, quasi-isometric and coarse embeddings between graphs with bounded geometry. We define two graphs X, Y to be regularly equivalent if there exist regular maps V X → V Y and V Y → V X. To give a few examples, the graph of the Sierpiński triangle is regularly equivalent to a tree, Z is regularly equivalent to N while lamplighters over finite groups, F ≀ Z, are contained in a single regular equivalence class but countably many quasi-isometry classes [EFW07]. The main result of the paper is the following. Theorem 1.1. There exist a family of 2ℵ0 (d, ε)-expanders {Xr : r ∈ R} such that given r 6= s there is no regular map Xr → Xs . F In fact, we will prove that given any (d, ε) expander n∈N Γn with unbounded girth there exists a set N of 2ℵ0 infinite subsets of N such that there F F is no regular map n∈M Γn → n∈N Γn whenever M, N ∈ N and M 6= N. The girth of a graph Γ, denoted g(Γ), is the length of the shortest positive F length simple cycle in Γ. We say n∈N Γn has unbounded girth if g(Γn ) → ∞ as n → ∞. Mendel and Naor recently produced the first example of two expanders which are not coarsely equivalent [MN14, Theorem 9.1] one of bounded girth and another of unbounded girth. The question of distinguishing expanders up to coarse equivalence is also considered by Ostrovskii [Ost13, Theorem 5.76]. Two alternative constructions of non coarsely equivalent expanders have appeared since this paper was first written. Das proves that a box space of SLn (Z) cannot coarsely embed into a box space of SLm (Z) whenever n > m ≥ 3 [Das15]. Khukhro and Valette, meanwhile, prove that there are uncountably many coarse equivalence classes of expanders occuring as box spaces of SL3 (Z) [KhVal]. This is particularly interesting in combintion with the results in this paper as their expanders do not have unbounded girth. Using small cancellation labellings developed by Osajda [Osa14], certain expanders of unbounded girth can be isometrically embedded into Cayley graphs of finitely generated groups. We prove that this can be done in a way which maintains the above distinctness. Theorem 1.2. There exists a family of finitely generated groups {Gr : r ∈ R} such that given r 6= s there is no regular map Gr → Gs . A continuum of expanders 3 As a result there is no coarse embedding of Gr into Gs whenever r 6= s. A priori this greatly generalises previous results which present 2ℵ0 quasiisometry classes of finitely generated groups, see for instance [Gri84]. The groups we obtain are infinitely presented graphical C ′ (1/6) small cancellation groups and are therefore acylindrically hyperbolic [GS14, DGO11], and SQ-universal [Gru15]. Moreover, they do not coarsely embed into any Hilbert space and do not satisfy the Baum–Connes conjecture with coefficients [HLS02]. Coarse embeddings into Hilbert spaces are highly sought, as Yu proved that any group admitting one satisfies the Novikov and coarse Baum-Connes conjectures; two important open questions in topology [Yu00]. Our results are obtained by computing the separation profile of graphs, as introduced by Benjamini-Schramm-Timár [BST12]. Given a finite graph Γ with n vertices, the cut size of Γ, cut(Γ), is the minimal cardinality of a set of vertices S such that any connected component of Γ \ S has at most n/2 vertices. The separation profile sepX of a graph X evaluated at n is the maximum of the cut sizes of all subgraphs of X with at most n vertices. We will consider separation profiles up to the natural equivalence f  g if there exists a constant C such that f (n) ≤ Cg(n) + C for all n. If X, Y are graphs with uniformly bounded degree and there exists a regular map φ : X → Y then sepX  sepY [BST12]. By other names this profile has a longer history, for instance, the LiptonTarjan theorem states that the cut size of any n vertex planar graph is √ O( n) [LT79]. More recently, Shchur proved that separation occurs naturally as an obstruction to quasi–isometrically embedding a metric space into a tree [Shc14]. Our main tool is the result below which states that the separation profile detects the existence of an ε-expander as a subgraph. Theorem 1.3. Let X be a graph. Then sepX (n)/n 6→ 0 if and only if X contains an expander as a subgraph. As a first step we obtain a control on finite subgraphs which should be of independent interest. Theorem 1.4. Let X be a graph. The Cheeger constant of any n-vertex subgraph of X is at most 4sepX (n)/n. 4 D. Hume Our results also give the first continuum of different separation profiles: the only previously known profiles were: bounded, log(n), polynomial - n1−1/d for each d ∈ {2, 3, . . . } and n/ log(n) [BST12]. We now adjust our viewpoint and prove a uniform upper bound on separation for graphs with finite Assouad-Nagata dimension. Examples include Cayley graphs of many well-studied classes of groups: polycyclic groups, lamplighter groups, virtually special groups, mapping class groups and certain relatively hyperbolic groups (see [Hu12] and references therein). Theorem 1.5. Let X be a graph with bounded valency and finite AssouadNagata dimension. Then sepX (n)  n/ log(n). If X is vertex transitive and has growth at most Cnd , then sepX (n)  n(d−1)/d . This is known to be sharp, since the separation of Zd is n(d−1)/d while a direct product of two non-abelian free groups has separation n/ log(n) [BST12]. From Theorems 1.4 and 1.5 we therefore deduce that for Cayley graphs of groups with finite Assouad–Nagata dimension any n-vertex subgraph has Cheeger constant at most C/ log(n). Acknowledgements The author would like to thank Itai Benjamini for introducing him to the topic and for enlightening conversations, John Mackay for pushing the project in a different direction and Dominik Gruber for informative conversations about groups containing expanders. The author would also like to thank Goulnara Arzhantseva, Romain Tessera, Alain Valette and an anonymous referee for comments on earlier versions of this paper. 2 Separation and inner expansion 2.1 Expanders and sublinear separation In this section we prove Theorem 1.3. We start by considering finite graphs. For completeness we recall the definition of the Cheeger constant. Definition 2.1. Let Γ be a graph with |Γ| = n. The vertex-boundary of a subset A ⊆ V (Γ) - denoted ∂A - is the set of all vertices in V (Γ) \ A which are neighbours of some vertex of A. The (vertex) Cheeger constant of Γ is given by h(Γ) = min {|∂A| / |A| : |A| ≤ n/2}. Note that any graph with at most n vertices admits a cut set of size ⌈ n2 ⌉. 5 A continuum of expanders Proposition 2.2. Let Γ be a graph with |Γ| ≥ 2. Then cut(Γ) ≥ h(Γ) 4 |Γ|. Proof. Set |Γ| = n. Let C be any cut set of Γ with |C| ≤ ⌈ n2 ⌉, so any connected component of Γ \ C contains at most ⌊ n2 ⌋ vertices. Define D to be a union of connected components of Γ \ C containing between n/4 and n/2 vertices: if no single component exists satisfying these bounds then every component contains at most ⌊ n4 ⌋ vertices and we obtain D by adding components in any order until the desired inequalities are achieved. As ∂D ⊆ C we see that |C| ≥ h(Γ) n4 . Hence, cut(Γ) ≥ n h(Γ) . 4 This immediately implies Theorem 1.4. For the other bound, we will require a more sensitive type of cut. We use the notation Γ →C Γ′ to denote that C is a subset of vertices of Γ and Γ′ is some largest connected component of Γ \ C. Definition 2.3. Let Γ be a graph with |Γ| ≥ 2. We say Γ →C Γ′ is a k-efficient cut if |Γ| − |Γ′ | > k |C|. From the definition of a cut set it is clear that |Γ| > |Γ′ | > |Γ| whenever 2 |Γ| k ≥ cΓ := cut(Γ) so there is a unique largest component in this case. As we are working with finite graphs every sequence of k-efficient cuts terminates. Proposition 2.4. Suppose Γ has n ≥ 2 vertices and let Γ →C1 · · · →Cm Γm be any maximal sequence of 3c2Γ -efficient cuts. Then |Γm | > n2 and h(Γm ) ≥ cut(Γ) . 2n S Proof. Suppose |Γm | ≤ n2 . Then Ci is a cut set for Γ containing at most 2 cut(Γ) points, which is a contradiction. 3 Now let A ⊂ Γm with |A| ≤ 21 |Γm |. As Γm admits no 3c2Γ -efficient cuts, we know that |A| + |∂A| ≤ 23 cΓ |∂A|. |A| Rearranging this, we see that |∂A| ≥ 2c , so |∂A| ≥ cut(Γ) . |A| 2n Γ This holds for all A with |A| ≤ 12 |Γm |, so we see that h(Γm ) ≥ cut(Γ) . 2n We now prove Theorem 1.3 via the following two propositions. Proposition 2.5. Let X be an infinite graph which contains some ε-expander S Γn . For every n, sepX (|Γn |) ≥ 4ε |Γn |. In particular, n1 sepX (n) 6→ 0. Proof. This follows immediately from Proposition 2.2. Proposition 2.6. Let X be an infinite graph and suppose sepX (n)/n 6→ 0. S Then there exists some ε > 0 such that X contains an ε-expander Γn . 6 D. Hume Proof. Let ε > 0 be such that sepX (n) ≥ 2εn for all n in some infinite subset I ⊆ N. For each n ∈ I let Γ′n be a subgraph of X with at most n vertices such that cut(Γ′n ) ≥ 2εn. By Proposition 2.4 each Γ′n has a subgraph Γn with |Γn | ≥ 12 |Γ′n | and h(Γn ) ≥ ε. Moreover, |Γn | → ∞ as n → ∞, so X contains a ε-expander. Now we concentrate on graphs with uniformly bounded degree, where the separation profile is invariant under regular equivalence. We obtain one immediate consequence of Proposition 2.6. Corollary 2.7. Let X be a graph of bounded degree which admits a coarse embedding into some Lp space, where p ∈ [1, ∞). Then sepX (n)/n → 0 as n → ∞. Using groups with relative property (T), Arzhantseva-Tessera produce box spaces with sublinear separation - they do not weakly contain expanders - which do not coarsely embed into any uniformly curved Banach space [AT14]. 2.2 Separation profiles of expanders The goal of this section is to prove Theorem 1.1. F Let X = n∈N Γn be a (d, ε)-expander where g(Γn+1) > |Γn | for each n F and |Γn+1 | / |Γn | → ∞ as n → ∞. As long as n∈N Γn has unbounded girth, this can always be done by passing to a subsequence. Theorem 2.8. For any infinite subsets M, N ⊆ N with C = M \N infinite, F F there is no regular map from X(M) = n∈M Γn to X(N) = n∈N Γn . Proof. Let c ∈ C. By Proposition 2.6, sepX(M ) (|Γc |) ≥ 4ε |Γc |. Now, let Γ be a subgraph of X(N) with k ≤ |Γc | vertices. Either cut(Γ) = 0 or there is some d 6= c such that |Γ ∩ Γd | ≥ |Γ| /2. If d < c then cut(Γ) ≤ |Γ| ≤ 2 |Γd | ≤ 2 |Γc−1|. However, if d > c, then Γ ∩ Γd is a forest, so has bounded cut size, hence Γ has bounded cut size. Thus sepX(N ) (|Γc |)/ |Γc | → 0 as c → ∞, so there is no regular map X(M) → X(N). Theorem 1.1 follows by noticing that there is a family N of 2ℵ0 infinite subsets of N with M \ N, N \ M infinite for all distinct M, N ∈ N . A continuum of expanders 2.3 7 Separation profiles of groups containing expanders Osajda’s construction of C ′ (1/6) small cancellation labellings of collections of finite graphs satisfying certain girth and diameter restrictions gives a method for constructing finitely generated groups which isometrically contain a family of expander graphs [Osa14]. F We let Γ = n∈N Γn be such a family, which we think of as a (d, ε) expander whose (oriented) edges are labelled by a finite set S. Given any collection of finite graphs Λ with such a labelling, we define a group G(Λ) which is generated by S and satisfies precisely the set of relations obtained by concatenating the labels of edges on simple loops in the graphs. By [Oll06], we know that G(Λ) is hyperbolic whenever Λ is finite and C ′ (1/6). More information on this construction - graphical small cancellation theory - can be found in [Gro03] where it was introduced, and in [Oll06, Osa14]. We require one auxiliary result on the separation of hyperbolic graphs. Theorem 2.9. Let X be a hyperbolic graph with bounded degree. There k−1 exists some k such that sepX (n)  n k . Proof. If Yk is a graph of bounded degree which is quasi-isometric to hyperm−2 bolic m-space Hm , then sepYk (n)  log(n) if m = 2 and sepYk (n)  n m−1 if m ≥ 3 [BST12]. Every hyperbolic graph X of bounded degree admits a quasi-isometric embedding into some hyperbolic space Hm [BS00] and hence a quasi-isometric k−1 embedding into some Yk . Therefore sepX (n)  n k . We impose two additional conditions on family of graphs Γ which are both satisfied by taking a suitably sparse subsequence (Γk ). Set Γ1 = Γ1 . Firstly, we ensure that for every k, and every subset Λ ⊆  1 Γ , . . . , Γk we have sepG(Λ) (n) < nk whenever n ≥ Γk+1 . Secondly, for every k, g(Γk+1) > 2 Γk . The first is possible as for each k we consider the maximal separation of finitely many hyperbolic groups, which all have sublinear separation by Theorem 2.9. For the second, we just use the fact that Osajda’s construction assumes that the girth of the sequence Γn is unbounded. Now we can prove Theorem 1.2. Theorem 2.10. Let A, B be two infinite subsets of N with C = A \ B infiF nite. Define Λ(A), Λ(B) = k∈A,B Γk respectively. Then there is no regular map G(Λ(A)) → G(Λ(B)). 8 D. Hume Proof. If k ∈ C then Γk is an isometrically embedded subgraph of G(Λ(A)) so sepG(Λ(A)) ( Γk ) ≥ Γk 4ǫ , by Proposition 2.5. Now let Γ be a connected subgraph of G(Λ(B)) with at most Γk vertices. Using the assumption that g(Γk+1) > 2 Γk , we see that Γ isometri cally embeds in some G(Λ) with Λ ⊆ Γ1 , . . . , Γk−1 . Hence, sepG(Λ(B)) ( Γk ) < 1 Γk . k As C is infinite we deduce that sepG(Λ(A)) (n) 6 sepG(Λ(B)) (n). 3 Finite asymptotic dimension In this section we give upper bounds on the separation profile of graphs with finite asymptotic dimension. This yields a quantitative version of the fact that such graphs do not contain expanders. Definition 3.1. Let X be a metric space. We say X has asymptotic dimension at most m if there exists a function h : R+ → R+ such that for all r > 0 we can partition X into m + 1 subsets X0 , . . . , Xm and each Xi into sets Xi,j with diam(Xi,j ) ≤ h(r) and such that d(Xi,j , Xi,j ′ ) > r whenever j 6= j ′ . We say X has Assouad-Nagata dimension at most m if the above holds with h(r) ≤ Cr for some constant C > 0. We define the growth function of a graph X to be γX : N → N ∪ {∞} where γ(n) is the maximal cardinality of a closed ball of radius n in X. We now prove Theorem 1.5 as a consequence of the more general result stated below. Theorem 3.2. Let X be a graph with asymptotic dimension at most m − 1, let h be a non-decreasing function provided by the above definition and let γ(n) be the growth function of X. There exists a constant k = k(m) such that kn , sepX (n) ≤ n fh 2m where we define fh (n) = max {k : γ(h(k)) ≤ n}. Proof. Let Γ be a subgraph of X containing n vertices, then setting r =  n fh 2m , we obtain a cover of X by m subsets B0 , . . . , Bm−1 such that each Bi decomposes into subsets Bi,j of diameter at most h(r) which are r disjoint. n vertices, It follows immediately that for some i, Γ∩Bi contains at least m without loss we assume this is true for i = 0. Now, each Bi,j contains at n most 2m vertices in Γ, so V (Γ) meets at least two such B0,j . A continuum of expanders 9 n n and 2m vertices Let U be a union of sets Uj = B0,j ∩ Γ with between 4m - a greedy search will achieve this. Notice that the complement, V , of the r neighbourhood of U contains at least n/2m vertices of B0 . Consider the sets Cl = {v ∈ V Γ : dX (v, U) = l} with 1 ≤ l ≤ r. It is clear that for each l, U and V are disjoint from Cl and cannot be connected by a path in Γ \ Cl . There exists an l such that |Cl | ≤ nr by the pigeon-hole principle. Fix such an l. Any largest connected component Γ1 of Γ \ Cl is disjoint from either U, 1 V or both, so it contains at most (1 − 4m )n vertices. If |Γ1 | ≤ n2 then we are done. If not, then applying the above procedure to Γ1 we can remove another set Cl′′ of at most nr vertices; a largest connected component Γ2 of Γ1 \ Cl′′ 1 2 contains at most n(1 − 4m ) vertices. 1 k Repeating this process k times, where k satisfies (1 − 4m ) ≤ 1/2, we deduce that after removing a set C containing at most kn/r vertices of Γ, the maximal connected component of Γ \ C is contained in Γk which has at 1 k ) ≤ n2 vertices. most n(1 − 4m To complete the proof of Theorem 1.5 we notice that fh (n)  log(n) for any bounded valence graph with finite Assouad-Nagata dimension. More d−1 specifically we recover the upper bound sepX (n)  n d for any group with polynomial growth of degree at most d. Every vertex transitive graph with polynomial growth is quasi-isometric to the Cayley graph of a finitely generated group [Sab64, Tro85], so the above result naturally extends to all vertex transitive graphs of polynomial growth. Problem 3.3. Is it true that every vertex transitive graph X with polynod−1 mial growth of degree d satisfies sepX (n)  n d ? References [ADS08] Goulnara Arzhantseva, Cornelia Druţu and Mark Sapir. Compression functions of uniform embeddings of groups into Hilbert and Banach spaces. J. Reine Angew. Math., 633:213–235, 2009. [AT14] Goulnara Arzhantseva and Romain Tessera. Relative expanders. Geom. Funct. Anal., 25(2):317–341, 2015. [BST12] Itai Benjamini, Oded Schramm, and Ádám Timár. On the separation profile of infinite graphs. Groups Geom. Dyn., 6(4):639–658, 2012. 10 D. Hume [BS00] Mario Bonk and Oded Schramm. Embeddings of Gromov hyperbolic spaces. Geom. Funct. Anal., 10(2):266–306, 2000. [Das15] Kajal Das. From the geometry of box spaces to the geometry and measured couplings of groups. Preprint available from arXiv:1512.08828. [DGO11] François Dahmani, Vincent Guirardel and Denis Osin. Hyperbolically embedded subgroups and rotating families in groups acting on hyperbolic spaces. To appear in Memoirs AMS. Preprint available from arXiv:1111.7048. [EFW07] Alex Eskin, David Fisher and Kevin Whyte. Coarse differentiation of quasi-isometries II: Rigidity for Sol and lamplighter groups. Ann. of Math. (2), 177(3):869–910, 2013. [Gri84] R. I. Grigorchuk. Degrees of growth of finitely generated groups and the theory of invariant means. Izv. Akad. Nauk SSSR Ser. Mat. 48(5):939–985, 1984 (Russian). [Gro03] Mikhael Gromov. Random walk in random groups. Geom. Funct. Anal. 13(1):73–146, 2003. [Gru15] Dominik Gruber. Groups with graphical C(6) and C(7) small cancellation presentations. http://dx.doi.org/10.1090/S0002-99472014-06198-9 Trans. Amer. Math. Soc. 367(3):2051–2078, 2015. [GS14] Dominic Gruber and Alessandro Sisto. Infinitely presented graphical small cancellation groups are acylindrically hyperbolic. Preprint available from arXiv:1408.4488, 2014. [HLS02] Nigel Higson, Vincent Lafforgue, and George Skandalis, Counterexamples to the Baum-Connes conjecture. http://dx.doi.org/10.1007/s00039-002-8249-5 Geom. Funct. Anal. 12(2):330-354, 2002. [HLW06] Shlomo Hoory, Nathan Linial and Avi Wigderson. Expander graphs and their applications. Bull. Amer. Math. Soc. (N.S.) 43(4):439-561, 2006. [Hu12] David Hume. Embedding mapping class groups into finite products of trees. Preprint available from arXiv:1207.2132. A continuum of expanders 11 [KhVal] Ana Khukhro and Alain Valette. Expanders and box spaces. Preprint available from arXiv:1509.01394. [LT79] Richard J. Lipton and Robert Endre Tarjan. A separator theorem for planar graphs. SIAM J. Appl. Math., 36(2):177–189, 1979. [Lub94] Alex Lubotzky. Expanding graphs and invariant measures. With an appendix by Jonathan D. Rogawski. Progress in Mathematics, volume 125, Birkhäuser Verlag, Basel, 1994. [Lub12] Alex Lubotzky. Expander graphs in pure and applied mathematics. Bull. Amer. Math. Soc. (N.S.), 49(1):113–162, 2012. [Mar75] Grigory A. Margulis. Explicit constructions of concentrators. Probl. of Inform. Transm. 10:325-332, 1975. [MN14] Manor Mendel and Assaf Naor. Nonlinear spectral calculus and super-expanders. Publ. Math. Inst. Hautes Etudes Sci., 119:1–95, 2014. [Oll06] Yann Ollivier. On a small cancellation theorem of Gromov. Bull. Belg. Math. Soc. Simon Stevin, 13(1):75–89, 2006. [Osa14] Damian Osajda. Small cancellation labellings of some infinite graphs and applications. Preprint available from arXiv:1406.5015, 2014. [Ost13] Mikhail I. Ostrovskii. Metric embeddings. De Gruyter, Studies in Math. 49, 2013. [Sab64] Gert Sabidussi. Vertex transitive graphs. Mh. Math., 68:385-401, 1964. [Shc14] Vladimir Shchur. On the quantitative quasi-isometry problem: transport of Poincaré inequalities and different types of quasi-isometric distortion growth. Preprint available from arXiv:1401.7315, 2014. [Tro85] Vladimir I. Trofimov, Graphs with polynomial growth. Math. USSR Sbornik, 51:405-417, 1985. [Yu00] Guoliang Yu. The coarse Baum-Connes conjecture for spaces which admit a uniform embedding into Hilbert space. Invent. Math., 139(1):201–240, 2000.
4math.GR
manuscript No. (will be inserted by the editor) Optimisation of photometric stereo methods by non-convex variational minimisation arXiv:1709.10437v1 [cs.CV] 29 Sep 2017 Georg Radow · Laurent Hoeltgen · Yvain Quéau · Michael Breuß Received: date / Accepted: date Abstract Estimating shape and appearance of a three dimensional object from a given set of images is a classic research topic that is still actively pursued. Among the various techniques available, photometric stereo is distinguished by the assumption that the underlying input images are taken from the same point of view but under different lighting conditions. The most common techniques provide the shape information in terms of surface normals. In this work, we instead propose to minimise a much more natural objective function, namely the reprojection error in terms of depth. Minimising the resulting non-trivial variational model for photometric stereo allows to recover the depth of the photographed scene directly. As a solving strategy, we follow an approach based on a recently published optimisation scheme for non-convex and non-smooth cost functions. The main contributions of our paper are of theoretical nature. A technical novelty in our framework is the usage of matrix differential calculus. We supplement our approach by a detailed convergence analysis of the resulting optimisation algorithm and discuss possibilities to ease the computational complexity. At hand of an experimental evaluation we discuss important properties of the method. Overall, our strategy achieves more accurate results than competing approaches. The experiments also highlights some practical aspects of the underlying optimisation algorithm that may be of interest in a more general context. G. Radow · L. Hoeltgen · M. Breuß Chair for Applied Mathematics, BTU Cottbus-Senftenberg, Cottbus, Germany. email: {radow,hoeltgen,breuss}@b-tu.de Y. Quéau Computer Vision Group, Technical University Munich, Garching, Germany. email: [email protected] 1 Introduction The reconstruction of three dimensional depth information given a set of two dimensional input images is a classic problem in computer vision. The class of methods fulfilling this task by inferring local shape from brightness analysis is called photometric methods [11, 38]. They usually employ a static view point and variations in illumination to obtain the 3D structure. Fundamental photometric reconstruction processes are shape from shading (SFS) and photometric stereo (PS) [11]. Shape from shading typically requires a single input image, whereas PS makes use of several input images taken from a fixed view point under different illumination. Photometric stereo incorporates SFS in the sense that SFS equations applied to each of the input images are integrated into a common PS process in order to obtain the 3D shape. This integrated model is usually formulated as an optimisation task that best explains the input images in terms of a pointwise estimation of shape and appearance. The pioneer of the PS method was Woodham in 1978 [39], see also Horn et al. [12]. The mathematical formulation of the PS problem is based on the use of the image irradiance equation (IIE) as in SFS for the individual input images, respectively. The image irradiance equation constitutes a relation between the image intensity and the reflectance map. The classic proceeding is thereby to consider Lambert’s law [18] for modelling the appearance of a shape given information on its geometry and albedo as well as the lighting in a scene. It has been shown that the orientation of a Lambertian surface can be uniquely determined from the resulting appearance variations provided that the surface is illuminated by at least three known, non-coplanar light sources, corresponding to at least three input images [40]. However, let us also mention the classic work of Kozera [17] as well as Onn and Bruckstein [26] where refined existence and uniqueness results are presented for the two-image case. 2 As a beneficial aspect beyond the possible estimation of 3D shape, PS enables to compute an albedo map allowing to deal with non-uniform object materials or textured objects in a photographed scene. As to complete our brief review of some general aspects of PS, let us note that it is possible to extend Woodham’s classic PS model as for instance to non-Lambertian reflectance as e.g. in [2, 14, 16, 21, 37], or to take into account several types of lighting in a scene, see e.g. [3, 31]. One may also consider a PS approach based on solving partial differential equations (PDEs) corresponding to ratios of the underlying IIEs, see for instance [22, 37]. The latter approach makes it possible to compute the 3D shape directly whereas in most methods following the classic PS setting a field of surface normals is computed which needs to be integrated in another step; see e.g. [1] for a recent discussion of integration techniques. Let us turn to the formulation of the PS approach we make use of. At this stage we keep the presentation rather general as we elaborate on the details that are of some importance in the context of applying our optimisation approach in Section 2. However, in order to explain the developments documented in this paper, it is useful to provide some formulae here. Photometric 3D reconstruction is often formulated as an inverse problem: given an image I, the aim is to compute a depth map z that best explains the observed grey levels of the data. To this end we use the IIE I(u, v) = R(z(u, v); s, ρ(u, v)) where (u, v) ∈ Ω represent the coordinates over the reconstruction domain Ω ⊆ R2 and where R denotes the reflectance map [11]. This model describes interactions between the surface z and the lighting s. The vector ρ represents reflectance parameters as e.g. the albedo, which can be either known or considered as hidden unknown parameters. For the sake of simplicity, we will consider in this paper only Lambertian reflectance without shadows, and we assume that the lighting of a photographed scene is directional and known. Moreover our camera is assumed to perform an orthographic projection. As in PS several input images I i , i ∈ {1, . . . , m} are considered under varying lighting si , i ∈ {1, . . . , m}, the PS problem consists in finding a depth map z that best explains all IIEs simultaneously: Radow et al. To achieve our goal we propose a numerical framework to approximate an optimal solution which can be used to refine classic PS results. Our approach relies on matrix differential theory for analytic derivations and on recent developments in non-convex optimisation. In that novel framework for this class of problems we prove here the convergence of the optimisation method. The theoretical results are supplemented by a thorough numerical investigation that highlights some important observations on the optimisation routine. The basic procedure of this work has been the subject of our conference paper [10], the results of which are mainly contained in the second, third and beginning of the fourth section of this article. Our current paper extends that previous work significantly by providing the mathematical validation of convergence and the extended analysis of the numerical optimisation algorithm. These are also exactly the core contributions of this paper. Moreover, we give a much more detailed description of the matrix calculus framework we employ. 2 Construction of our method and more related work As shown by Woodham [40], all surface normals can be estimated in the classic PS model without ambiguity, provided m ≥ 3 input images and non-coplanar calibrated lighting vectors are given. In addition, the reflectance parameters (e.g. the albedo) can also be estimated. This is usually achieved by minimising the difference between the given data, i.e. the input images and the reprojection according to the estimated normal and albedo: ZZ m  1 arg min Φ I i − R n; si , ρ du dv (2) ∑ m Ω i=1 n,ρ with a penaliser Φ. As a result, one obtains an approximation of the normal n(u, v) and the albedo ρ(u, v) at each position (u, v). Since there is no coupling between the normals estimated in two neighboring pixels, those estimates are the optimal local explanations of the image, in the sense of the estimator Φ. Yet, the estimated normal field is in general not integrable. Thus, the depth map that can be obtained by integration is not an optimal image explanation, but only a I i (u, v) = R(z(u, v); si , ρ), i ∈ {1, . . . , m} (1) smooth explanation of the noisy normal field, c.f. Figure 1. Instead of this pointwise joint estimation of the normal Our contribution. Our aim is to obtain the solution z of the and the albedo, it is, as already mentioned in the introducPS problem, see also Figure 1 for an account. We show that tion, possible to employ photometric ratios. Following that estimating the optimal solution necessarily involves non-trivial procedure means to divide the i-th by the j-th IIE in (1). optimisation methods, even with the simplest models for This way, one obtains a homogeneous linear system in each the reflectance function R and the most simple deviations normal vector that does not depend on the albedo, see [22]. from the model assumptions that may occur, i.e. we conHowever, these ratios introduce additional difficulties in the sider Lambertian reflectance without shadows and additive, models. It is common to assume that image data is corrupzero-mean Gaussian noise. ted by additive, zero-mean, Gaussian noise. In that case the Non-convex variational photometric stereo Example input image for PS 3 Classic PS with integration Our method Fig. 1 From a set of m ≥ 3 images (c.f. left), classic PS provides an albedo and a normal map which best explain the input images in the sense of a local, pointwise estimation. In a second step, the smooth depth map is estimated by integration. Yet, the final surface is not the best explanation of the images, as indicated by the reprojection error (c.f. energy in (5)) (middle). We display this using white for 2.5 · 10−3 and black for zero. Instead of this local procedure, we propose to minimise the reprojection criterion in terms of the depth and the albedo, through global nonconvex optimisation. Not only the images are better explained (right), but we also demonstrate that the 3D-reconstruction results are improved (c.f. Section 6). maximum likelihood (ML) function should be chosen to be quadratic. Unfortunately, the ratio of two Gaussian random variables follows a Cauchy distribution [9]. Thus, additional care has to be taken to find the most efficient penaliser. Another frequent assumption is that the estimated normal fields should be integrable, yet, this is a rather restrictive assumption. The normal field computed by many aforementioned PS approaches does not necessarily need to be integrable. Hence, the integration task is usually formulated as another optimisation problem which aims at minimising the discrepancy between the estimated normal field and that of the recovered surface. Following that approach we now go into some more details. Assuming orthographic camera projection, the relation between the normal n(u, v) and the depth z(u, v) is given by: 1 n(u, v) := p [−∇z(u, v), 1]> k∇z(u, v)k2 + 1 (3) where ∇z is the gradient of z. Then, the best smooth surface explaining the computed normals can be estimated in several ways [1], for instance by solving the variational problem:   2! ZZ n1 /n3 arg min Ψ ∇z + du dv (4) n2 /n3 Ω z where Ψ is again some estimator function; see [6, 8] for some discussion. One may realise that, at this stage of the process chain of PS with integration, the images are not explicitly considered anymore. Thus, the final surface is in general not necessarily optimal in the sense of the reprojection criterion. Regularising the normal field before integration [34,42] may also ensure integrability, but since such methods only use the normal field, and not the images, they may be unable to assert optimality with respect to the reprojection. Global PS approaches solve the latter problem as they represent a way to ensure that the recovered surface is optimal with respect to the reprojection criterion. Moreover, it is possible to solve the system (1) directly in terms of the depth [5]: this ensures both that the recovered surface is regular, and that it is optimal with respect to the reprojection criterion, calculated from the depth map z and not from a non-integrable estimate of its gradient. Some PDE-based PS approaches have been recently proposed, and were shown to ease the resolution in particularly difficult situations such as pointwise lighting [31] and specular reflectance [37]. To ensure robustness, such methods can be coupled with variational methods. In other words, the criterion which should be considered for ensuring optimality of a surface reconstruction by PS is not the local criterion (2), but rather: arg min z,ρ 1 m ZZ m ∑Φ Ω i=1 I i − R z; si , ρ  du dv (5) A theoretical analysis of the choice Φ(x) = |x|, can be found in [4]. Numerical resolution methods based on proximal splittings were more recently introduced in [32]. Yet, this last work relies on an “optimise then discretise” approach which would involve non-trivial oblique boundary conditions (BC), replaced there for simplicity reasons by Dirichlet BC. Obviously, this represents a strong limitation which prevents working with many real-world data where this oblique BC is rarely available. The optimisation problem (5) is usually non-linear and non-convex. The ratio procedure described earlier can be 4 Radow et al. used: it simultaneously eliminates the albedo and the nonlinear terms, c.f. [7, 21, 36, 37] and obviously removes the bias due to non-integrability. But let us recall that it is only the best linear unbiased estimate, and also not the optimal one. To guarantee optimality, it is necessary to minimise the nonlinear, non-convex energy, i.e. without employing ratios. Other methods [31, 33] overcome the nonlinearity by absorbing it in the auxiliary albedo variable. Again, the solution is not that of the original problem (5) which remains, to the best of our knowledge, unsolved. Solving (5) is a challenging problem. Efficient strategies to find the sought minimum are scarce. Recently Ochs et al. [25] proposed a novel method to handle such non-convex optimisation problems, called iPiano. A major asset of the approach is the extensive convergence theory provided in [24, 25]. Because of this solid mathematical foundation we explore the iPiano approach in this work. The scheme makes explicit use of the derivative of the cost function, which in our case involves derivatives of matrix-valued functions, and we will employ as a technical novelty, matrix differential theory [19, 20] to derive the resulting scheme. 3 Non-convex discrete variational model for PS In this section we describe the details of our framework for estimating both the depth and the (Lambertian) reflectance parameters over the domain Ω . 3.1 Assumptions on the PS model We assume m ≥ 3 grey level images I i , i ∈ {1, . . . , m}, are available, along with the m lighting vectors si ∈ R3 , assumed to be known and non-coplanar. We also assume Lambertian reflectance and neglect shadows, which leads to the following well-known model:  R n(u, v); si , ρ := ρ (u, v) si , n (u, v) (6) where (u, v) ∈ Ω , i = 1, . . . , m and ρ(u, v) is the albedo at the surface point conjugated to position (u, v), considered as a hidden unknown parameter. Let us note that real-world PS images can be processed by low-rank factorisation techniques in order to match the linear reflectance model (6), c.f. [41]. We further assume orthographic projection, hence the normal n(u, v) is given by (3). Then the reflectance model becomes a function of the depth map z:  R z; si , ρ := p ρ (u, v) k∇z(u, v)k2 + 1  si ,   −∇z(u, v) 1 (7) with (u, v) ∈ Ω , for all i. Eventually, we assume that the images I i differ from this reflectance model only up to additive, zero-mean, Gaussian noise. The ML estimator is thus the least-squares estimator Φ(x) = 21 x2 , and the cost function in the reprojection criterion (5) becomes:  ZZ m   2 1 i i ER (z, ρ; I) := ∑ I − R z; s , ρ du dv (8) 2m Ω i=1 3.2 Tikhonov regularisation of the model Our energy in (8) only depends on the gradient ∇z and not on the depth z(u, v) itself. As a consequence, solutions can only be determined up to an arbitrary constant. As a remedy we follow [21] and introduce a reference depth z0 (u, v), thus regularising our initial model with a zero-th order Tikhonov regulariser controlled by a parameter λ > 0: arg min ER (z, ρ; I) + z,ρ λ 2 ZZ Ω (z − z0 )2 du dv (9) In practice, λ can be set to any small value, so that a solution of (9) lies as close as possible to a minimiser of (8). In all our experiments we set λ := 10−6 and z0 as the classic PS solution followed by least-squares integration [1]. 3.3 Discretisation As already mentioned, “optimise then discretise” approaches for solving (9), such as [32], involve non-trivial BC. Hence, we prefer a “discretise then optimise”, finite dimensional formulation of the variational PS problem (9). In our discrete setting we are given m images Ii , i ∈ {1, . . . , m}, with n pixels labelled with a single index j running from 1 to n. We discretise (9) in the following way:    2 ρj 1 −∇z j q arg min I − S j 1 2 2m ∑ z,ρ∈Rn j ∇z j + 1  λ 2 + z j − z0 j (10) 2 where I j := [I1j , . . . , Imj ]> ∈ Rm is the vector of intensities at pixel j, ∇z j represents now a finite difference approximation of the gradient of z at pixel j, and S = [s1 , . . . , sm ]> ∈ Rm,3 is a matrix containing the stacked m lighting vectors si . We remark that the matrix S can be decomposed into two sub-matrices  S` and Sr of dimensions m × 2 and m × 1 such that S := S` Sr , and so that   −∇z j S = −S` ∇z j + Sr (11) 1 Let us also introduce a 2n×n block matrix M, such that each block M j is a 2 × n matrix containing the finite difference coefficients used for approximating the gradient:  > M := M1 . . . Mn ∈ R2n,n , M j z = ∇z j ∈ R2 (12) Non-convex variational photometric stereo We further introduce the aliases ρj S` ∈ Rm,2 A j (z, ρ) := − q 2 1 + M jz 5 (13) and ρj b j (z, ρ) := I j − q 1 + M jz 2 Sr ∈ Rm (14) and stack them, respectively, in a block-diagonal matrix   A1 (z, ρ)   mn,2n .. A(z, ρ) :=  (15) ∈R . An (z, ρ) and a vector   b1 (z, ρ)   b(z, ρ) :=  ...  ∈ Rmn (16) bn (z, ρ) The computation of z(k+1) is considerably harder, and it is dealt with in the following paragraphs. Using these notational conventions as well as f (z, ρ) := 1 kA(z, ρ)Mz − b(z, ρ)k22 2m (17) and g(z) := λ kz − z0 k22 2 (18) the task in (10) can be rewritten compactly as arg min{ f (z, ρ) + g(z)} z,ρ∈Rn (19) which is the discrete PS model we propose to tackle in this paper. Observe that, if A(z, ρ) and b(z, ρ) were constant, problem (19) would be a linear least squares problem with respect to z. Let us remark that (19) can be easily extended to include more realistic reflectance [15, 16] and lighting [28, 31] models, as well as more robust estimators [14, 33]: this only requires to change the definition of f , which stands for the global reprojection error ER . 3.4 Alternating optimisation strategy In order to ensure applicability of our method to real-world data, the albedo ρ cannot be assumed to be known. Inspired by the well-known Expectation-Maximisation algorithm, we treat ρ as a hidden parameter, and opt for an alternating strategy which iteratively refines the depth with fixed albedo, and the hidden parameter with fixed depth: n   o z(k+1) = arg min f z, ρ (k) + g(z) (20) z n    o ρ (k+1) = arg min f z(k+1) , ρ + g z(k+1) (21) ρ starting from z(0) = z0 and taking as ρ (0) the albedo obtained by the classic PS approach [40]. Of course, the choice of a particular prior z0 has a direct influence on the convergence of the algorithm. The proposed scheme globally converges towards the solution, even with a trivial prior z0 ≡ constant, but convergence is very slow in this case. Thus the proposed method should be considered as a post-processing technique to refine classic PS approaches, rather than as a standalone PS method. Now, let us comment on the two optimisation problems in (20). Updating ρ amounts pointwise to a linear leastsquares problem, which admits the following closed-form solution at each pixel:   q (k+1) m > −M j z 1 + kM j z(k+1) k2 ∑ Iij si 1 i=1 (k+1) ρj = (22)    2 (k+1) m > −M j z i ∑ s 1 i=1 4 An inertial proximal point algorithm for PS In this section we discuss the numerical solution strategy of our problem (20). We especially discuss the main difficulty within this strategy, that is to compute the gradient with respect to z for the function f in (17). Apart from the explicit formula for this gradient we also investigate an approximation leading to efficient computations on a desktop computer with an intel CPU. 4.1 The iPiano algorithm We will now make precise the iPiano algorithm [25] for our problem (20). Since the albedo is fixed for the purpose of the corresponding optimisation stage, we denote f (z) = f (z, ρ (k) ). The iPiano algorithm seeks a minimiser of min { f (x) + g(x)} x∈Rn (23) where g : Rn → R is convex and f : Rn → R is smooth. What makes iPiano appealing is the fact that g must not necessarily be smooth and f is not required to be convex. This allows manifold designs of novel fixed-point schemes. In its general form it evaluates   proxαg z(k) − α∇ f (z(k) ) + β (z(k) − z(k−1) ) (24) where the proximal operator is given by   1 2 proxαg (z) := arg min kx − zk + αg (x) 2 x (25) and which goes back to Moreau [23]. Before we can define the final algorithm we also need to determine the gradient of f. 6 Radow et al. 4.2 Matrix Calculus We will first recall some general rules to derive the Jacobian of a matrix valued function, before we apply these rules to our setting in the next section. In our setting the main difficulty is that the matrix A depends on our sought unknown z. In order to state a useful representation of arising differential expressions we have to resort to matrix differential calculus. We refer to [19, 20, 29, 30] for a more in-depth representation. A key notion is the definition of the Jacobian of a matrix, which can be obtained in several ways. In this paper we follow the one given in [19]. Definition 1 (Jacobian of a Matrix Valued Function) Let A be a differentiable m × p real matrix function of an n × q matrix X of real variables, i.e. A = A(X). The Jacobian matrix of A at X is the mp × nq matrix D [A] (X) := dvec (A (X)) d(vec X)> (26) where vec (·) corresponds to the vectorisation operator described in [13] (Definition 4.29). This operator stacks columnwise all the entries from its matrix argument to form a large vector. Here, differentiability of a matrix valued function means that the corresponding vectorised function is differentiable in the usual sense. By this definition the computation of a matrix Jacobian can be reduced to computing a Jacobian for a vector valued function. Example 1 Let A(x) ∈ Rm,m be a differentiable diagonal matrix   a1 (x)   .. A(x) =  for all x ∈ Rn (27)  . am (x) then the Jacobian matrix of A at x has the form   ∂ a (x)   1 · · · ∂ a∂1x(x) a1 (x) ∂ x1 n    0m,1    0    ∂ a2 (x) m,n ∂ a2 (x)      a (x) · · · d  2   ∂x ∂ xn  D [A(x)] (x) = >  0m,1  =  1 0  (28) m,n    dx   .    .   ..   ..   ∂ am (x) ∂ am (x) am (x) · · · ∂x ∂ xn 1 where 0 p,q denotes a p × q block of zeros. The following two lemmas state extensions of the product and chain-rule to matrix valued settings. They provide us closed form representations that will be useful for the forthcoming findings. These results have been extracted from [19] (Theorem 7 and 9 respectively). Since these lemmas have been copied verbatim, we refer to their source for the detailed proofs. Lemma 1 (Chain Rule) Let S be a subset of Rn,q and assume that F : S → Rm,p is differentiable at an interior point C of S. Let T be a subset of Rm,p such that F(X) ∈ T for all X ∈ S, and assume that G : T → Rr,s is differentiable at an interior point B = F(C) of T . Then the composite function H : S → Rr,s defined by H(X) = G(F(X)) is differentiable at C and D[H](C) = D[G](B)D[F](C) (29) Definition 2 (Kronecker Product) Let A = (ai, j ) be a m × n matrix and B be a p × q matrix then the Kronecker Product A ⊗ B is defined as   a1,1 B · · · a1,n B  ..  A ⊗ B :=  ... (30) .  am,1 B · · · am,n B Example 2 For a row vector B = [b1 , . . . , bn ] ∈ R1,n and the identity matrix 13 ∈ R3,3 we have   b1 b2 bn B ⊗ 13 =  b1 b2 ··· bn  (31) b1 b2 bn Lemma 2 (Product Rule) Let U : S → Rm,r and V : S → Rr,p be two matrix functions defined and differentiable on an open set S ⊆ Rn,q . Then the matrix product UV : S → Rm,p is differentiable on S and the Jacobian matrix D[UV](X) ∈ Rmp,nq is given by D [UV] (X) = (V> ⊗ 1m )D[U](X) + (1 p ⊗ U)D[V](X) (32) Here, 1k represents the identity matrix in Rk,k . Example 3 Let A be a differentiable m × m-matrix and M be a m × n-matrix, then by Lemma 2 we have D [A(x)Mx] (x)   = (Mx)> ⊗ 1m D [A(x)] (x) + (11 ⊗ A(x)) D [Mx] (x)   = (Mx)> ⊗ 1m D [A(x)] (x) + A(x)M (33) 4.3 Gradient computation The following two corollaries are a direct consequence from the foregoing statements. It suffices to plug in the corresponding quantities. We also remind, that our choice of the matrix derivative allows us to interpret vectors as matrices having a single column only. Corollary 1 Let A(z) be a n × q matrix depending on z ∈ Rm and M ∈ Rq,m a matrix which does not depend on z, then the Jacobian of the matrix-vector product A(z)Mz is given by   D[A(z)Mz](z) = (Mz)> ⊗ 1n D[A](z) + A(z)M (34) Non-convex variational photometric stereo 7 Proof We apply the product rule on the product between A(z) and Mz and subsequently on the product Mz. In a first step this yields   D[A(z)Mz] = (Mz)> ⊗ 1n D[A](z) + A(z)D[Mz](z) (35) Since D[Mz](z) = M the result follows immediately. t u Corollary 2 and Theorem 1 yield our desired compact representations that we use for the algorithmic presentation of our iterative schemes. Corollary 2 Using the same assumptions as in Corollary 1, we deduce from the chain rule given in Lemma 1 the following relationship ∇kA(z)Mzk22  = 2 D[A](z)> ((Mz) ⊗ 1n ) + M> A(z)> A(z)Mz | {z } (36) Applying the gradient at each term separately and using the results from the previous corollaries, we obtain ∇kA(z)Mz − b(z)k22  = 2 D[A](z)> ((Mz) ⊗ 1n ) + M> A(z)> A(z)Mz | {z } =D[A(z)Mz](z)> > + 2D[b](z) b(z)  − 2 D[A](z)> ((Mz) ⊗ 1n ) + M> A(z)> b(z) {z } | =D[A(z)Mz](z)> − 2D[b](z)> A(z)Mz which can be simplified to ∇kA(z)Mz − b(z)k22 = 2(D[A(z)Mz](z) − D[b](z))> (A(z)Mz − b(z)) (42) The result follows now from the linearity of the Jacobian. =D[A(z)Mz](z)> where ∇ denotes the gradient with respect to z. h i Proof Since D kxk22 (x) is given by 2x> we conclude from the chain- and product-rule that D[kA(z)Mzk22 ](z) > = 2 A(z)Mz D[A(z)Mz](z) > = 2 A(z)Mz   (Mz)> ⊗ 1n D[A](z) + A(z)D[Mz](z) (37) Since the gradient is simply the transposed version of the Jacobian, we obtain   ∇kA(z)Mzk22 = 2 (Mz)> ⊗ 1n D[A](z) > + A(z)D[Mz](z) A(z)Mz (38) from which the statement follows immediately. t u Let us now come to our main result. Theorem 1 Let f (z) = kA(z)Mz − b(z)k22 be given with sufficiently smooth data A(z) and b(z). Then we have for the gradient of f the following closed form expression:    > ∇ f (z) = 2 A(z)M + (Mz)> ⊗ 1n D[A](z) − D[b](z) (A(z)Mz − b(z)) (39) Proof From the relationship between the canonical scalar product in Rn and the Euclidean norm we deduce that kA(z)Mz − b(z)k22 = kA(z)Mzk22 + kb(z)k22 − 2hA(z)Mz , b(z)i (40) (41) t u Now, we obtain for the gradient of the function f from (17), resp. (39): ∇ f (z) =   1 A(z)M + (Mz)> ⊗ 1nm D[A](z) m > − D[b](z) (A(z)Mz − b(z)) (43)  The addition of (Mz)> ⊗ 1nm D[A](z)−D[b](z) stems from the inner derivative, since A and b are not constant. 4.4 Approximation of the gradient of f Our numerical scheme depends on a gradient descent step of f from (17) (resp. (39)) with respect to z. However, the evaluation of ∇ f (z) is computationally expensive. It contains several matrix-matrix multiplications as well as the evaluation of a matrix Jacobian and a Kronecker product. These computations need to be done in every iteration. As we will see in Lemma 5, the evaluation of ∇ f (z) can be done in a way, so that the main effort lies in computing n dyadics of  > vectors S [−M j z, 1]> ∈ Rm,1 and M>j M j z ∈ R1,n . In order to improve the performance of our numerical approach we further seek an approximation to ∇ f that requires significantly less floating point operations. To this end, we assume for a moment that neither our matrix A, nor our vector b depend on the unknown z. In that case we obtain   1 ∇ f (z) = ∇ kAMz − bk2 2m (44) 1 = (AM)> (AMz − b) =: q m 8 Radow et al. Our conclusions from (44) are twofold. First of all, −q seems to be a good candidate for a descent direction. At least when our data A and b does not depend on z, then −q is an optimal and significantly easier to evaluate descent direction. Secondly, we can exploit (44) to derive a refined version of the iPiano algorithm for our task at hand. If we apply a lagged iteration on the descent step of f , then our matrix A and our vector b become automatically independent of our current iterate and −q would be the steepest descent direction. The fact that q would not have to be recomputed in every iteration could outweigh the loss of accuracy and yield an additional performance boost. The following theorem states precise conditions under which the vector −q, defined in (44), yields a descent direction. Let us emphasise that Theorem 2 even allows a dependency on z in A and b. Thus, we obtain Theorem 2 The vector Let us conclude this section by remarking that the matrix 1 −q := − (A(z)M)> (A(z)Mz − b(z)) m (45) is a descent direction for f (z) from (17) (resp. (39)) at position z if the expression h(A(z)Mz − b(z)), A(z)MD[A(z)Mz − b(z)]> (A(z)Mz − b(z))i (46) is non-negative. This is especially true if A(z)MD[A(z)Mz− b(z)]> is positive semi-definite. Proof Reordering the terms for ∇ f (z) in (43) yields the following relation between ∇ f (z) and q (50) Now, we are in presence of a descent direction whenever the expression h(AMz − b), AMD[AMz − b]> (AMz − b)i (51) is non-negative. This is especially true, if the matrix A(z)MD[A(z)Mz − b(z)]> (52) is positive semi-definite. t u A(z)MD[A(z)Mz − b(z)]> (53) does not have any particular structure. Indeed, in general, it is made up from a product of non-symmetric and non-square matrices. Thus, additional claims on the spectral properties of this matrix are difficult to derive. Nevertheless, we conjecture that ∇ f (z) ≈ 1 (A(z)M)> (A(z)Mz − b(z)) m (54) is an efficient way to approximate ∇ f (z) for computations. We will investigate possible deficiencies later in our numerical experiments. 4.5 Summary of the solution strategy ∇ f (z) = q+ hq, ∇ f i 1 = h(AM)> (AMz − b), D[AMz − b]> (AMz − b)i m 1 = h(AMz − b), (AM)D[AMz − b]> (AMz − b)i m > 1 ((Mz)> ⊗ 1)D[A] − D[b] (AMz − b) (47) {z } m | where we have omitted the obvious dependencies on z. Our vector −q will be a descent direction if h−q, ∇ f i ≤ 0. Using (47) we conclude Our final algorithm for the computation of the depth and the albedo is given in Algorithm 1. For the step sizes we employed the “lazy backtracking” algorithm as in [25]. This includes increasing the Lipschitz constant L(`) for ∇ f by multiplication with a parameter η > 1 (η = 1.2 in our experiments), until the new iterate z̃(l+1) fulfils hq, ∇ f i f (z̃(`+1) ) ≤ f (z̃(`) ) =D[AMz−b]−AM = hq, qi + 1 hq, (D[AMz − b] − AM)> (AMz − b)i (48) m Expanding q in the second inner product yields hq, (D[AMz − b] − AM)> (AMz − b)i = h(AM)> (AMz − b), (D[AMz − b] − AM)> (AMz − b)i = h(AM)> (AMz − b), D[AMz − b]> (AMz − b)i − hq, qi (49) + h∇ f (z̃l ), z̃(`+1) − z̃(`) i + L(`) (`+1) z̃ − z̃(`) 2 2 2 (55) The found Lipschitz constant L(`) divided by a µ ≥ 1 (µ = 1.05 in our experiments) delivers the start for estimating the Lipschitz constant L(`+1) in the next iPiano iteration. In Algorithm 1 we could also use a constant step size β ∈ [0, 1[, so that the computation of ν and δ (`) would not be required. By using β = 0.5 in our numerical experiments we achieved comparable results with respect to both computation time and quality of the reconstructed surface. However, Non-convex variational photometric stereo 9 Algorithm 1: Inertial Proximal Point Algorithm for Photometric Stereo Choose prior z0 (classic PS), prior weight λ (10−6 ), c > 0 (0.01) and d > c (1) Initialise z(0) (z0 ) and ρ (0) (classic PS), and set k = 0 repeat Set z̃(0) = z̃(−1) = z(k) , δ (−1) = d and ` = 0 repeat Lipschitz constant L(`) estimation by lazy backtracking δ (`−1) + L(`) /2 Aux. variable: ν = c + L(`) /2 ν −1 (`) and Step size updates: β = ν + c − 0.5 1 − β α (`) = c + L(`) /2 1 L(`) β (`) Aux. variable: δ (`) = (`) − − (`) 2 α α (`+1) = Depth update: z̃      proxα (`) g z̃(`) − α (`) ∇ f z̃(`) + β z̃(`) − z̃(`−1) ` = `+1 until iPiano convergence z(k+1) = z̃(`+1) Albedo update using (22) k = k+1 until global convergence by applying a variable step size deduced from the proof of Lemma 4.6 in [25] we ensure that the auxiliary sequence {δ (`) }∞ `=−1 is monotonically decreasing and therefore the convergence theory provided in [25] can be applied. To this end, let us remark that kzk2 → ∞ implies g (z) → ∞ and that f is non-negative. Thus, f + g is coercive. Furthermore g is convex and non-negative, such that f + g is bounded below. The function f is obviously differentiable, c.f. (43). The final ingredient to apply the general convergence result is the Lipschitz continuity of ∇ f , which we will investigate in the following section. As a motivation, we recap the general convergence result that was provided in [25], Theorem 4.8. For the definition of Lipschitz continuity we refer to (58). β (`) Proposition 1 Let {z̃(`) }∞ `=0 be a sequence generated by the inner loop of Algorithm 1, with ∇ f computed according to (43). If ∇ f is Lipschitz continuous, then the following properties hold: 1. The sequence { f (z̃(`) ) + g(z̃(`) )}∞ `=0 converges. 2. There exists a converging subsequence {z̃(`i ) }∞ i=0 . 3. For any limit point z̃∗ := limi→∞ z̃(`i ) we have 0 = ∇ f (z̃∗ ) + ∇g (z̃∗ ) i→∞ In Algorithm 1, the Lipschitz constant L of ∇ f (z̃)(`) is estimated by a lazy backtracking strategy. To derive a Lipschitz estimate for ∇ f (z) for all z ∈ Rn and thereby ensure that the convergence theory for the iPiano algorithm provided in [24, 25] can be applied, we first recall some general techniques to combine Lipschitz estimates. Afterwards with these techniques we derive Lipschitz estimates for the gradient of f as well as for our approximation of this gradient. We conclude the convergence analysis by highlighting some aspects of the iPiano method. Thereby, we further justify our choice of a non-constant stepsize β (`) , which might seem as a technical complication at first glance. 5.1 Technical Preliminaries Although the final Lipschitz estimates for ∇ f and q, that we are interested in, involves a vector valued function with a vector valued input, to get there we will in the most general case discuss Lipschitz estimates for F : R p → Rq,r with different choices for F, p, q and r. The function F is Lipschitz continuous with a Lipschitz constant LF , if kF(x) − F(y)k2 ≤ LF kx − yk2 for all x, y ∈ R p (56) (57) (58) The following lemma contains some basic techniques to combine Lipschitz estimates. The proof is included for convenience. Lemma 3 Let F1 : Rm → Rn,p and F2 : Rm → R p,q be Lipschitz continuous with L(1) , L(2) > 0, such that kFk (x) − Fk (y)k2 ≤ L(k) kx − yk2 , (59) for all x, y ∈ Rm and k ∈ {1, 2}, then we have the following properties: 1. If there exist c1 , c2 , such that kFk (x)k2 ≤ ck for all x ∈ Rm and k ∈ {1, 2}, then kF1 (x)F2 (x) − F1 (y)F2 (y)k2   ≤ c2 L(1) + c1 L(2) kx − yk2 (60) The following properties only concern the scalar case. 2. If n = p = 1 and if there exists a c3 > 0, such that F1 (x) ≥ c3 for all x ∈ Rm , then p p L(1) F1 (x) − F1 (y) ≤ √ kx − yk2 2 c3 and     lim f z̃(`i ) + g z̃(`i ) = f (z̃∗ ) + g (z̃∗ ) 5 Convergence analysis (61) 3. If n = p = 1 and if there exists a c4 > 0, such that |F1 (x)| ≥ c4 for all x ∈ Rm , then 1 1 L(1) kx − yk2 − ≤ F1 (x) F1 (y) (c4 )2 (62) 10 Radow et al. Proof Let x, y ∈ Rm . strong assumptions, we choose not to switch to a more restricted space than Rn , and instead assume that the depth map that is to be reconstructed and also the iterates z̃(`) in Algorithm 1 fulfil (A1) and (A2). If (A1) holds true, then we additionally define 1. Since kF1 (x)F2 (x) − F1 (y)F2 (y)k2 = kF1 (x)F2 (x) − F1 (x)F2 (y) +F1 (x)F2 (y) − F1 (y)F2 (y)k2 (63) ≤ kF1 (x)k2 kF2 (x) − F2 (y)k2 + kF2 (y)k2 kF1 (x) − F1 (y)k2 by kFk (x)k2 ≤ ck for all x ∈ Rm and k ∈ {1, 2} and (59) we get (60). 2. Now let n = p = 1. If we have F1 (x) ≥ c3 > 0 for all x ∈ Rm , then p p F1 (x) − F1 (y) p F1 (x) − F1 (y) = p F1 (x) + F1 (y) 1 p |F1 (x) − F1 (y)| ≤ p F1 (x) + F1 (y) (64) and therefore, with (59) we get (61). 3. If we have |F1 (x)| ≥ c4 > 0 for all x ∈ Rm , then 1 F1 (y) − F1 (x) 1 − = F1 (x) F1 (y) F1 (x)F1 (y) 1 |F1 (x) − F1 (y)| ≤ F1 (x)F1 (y) and with (59) we get (62). L̃zj r := for all j ∈ {1, . . . , n} so that we have q 2 1 + M j z 2 ≤ L̃zj for all z ∈ Rn (67) (68) If (A2) holds true, then L̃zj ∈ O(1) for all j ∈ {1, . . . , n}. To obtain a Lipschitz estimate of the gradient ∇ f (z) =  > 1  (Mz)> ⊗ 1 D[A] + AM − D[b] m (AMz − b) (69) we will first derive Lipschitz estimates for the individual components and then combine them by using Lemma 3. (65) Corollary 3 Let j ∈ {1, . . . , n} and x, y ∈ Rn . In addition, we define κ := Lzj M j . If (A1) holds true, then 2 − 2 M jx t u q 5.2 Lipschitz constant for the gradient of f (66) Let us remark that the previous assumptions on the decrease rate are done under the assumption, that the grid step size of our image remains the same when the number of pixels increases. While the finiteness of L∇ f and Lq hinges on (A1), assumption (A2) is only needed to derive the dependencies of the Lipschitz constants on n. Although these are fairly 2 − 2 1 q We will also investigate the existence of a Lipschitz constant Lq of the approximated gradient q from (44), as well as the dependencies of L∇ f and Lq on n and m. We make the following assumptions: (A1) For all j ∈ {1, . . . , n} the approximation of the spatial gradient M j z is bounded, i.e. there is a Lzj ∈ [0, ∞), such that M j z 2 ≤ Lzj for all z ∈ Rn . (A2) For n → ∞ we have Lzj → 0 for all j ∈ {1, . . . , n}, not√ ably Lzj ∈ O(1/ n). M jy 1 + M jx We investigate in this section the existence of a finite Lipschitz constant L∇ f , such that for all x, y ∈ Rn k∇ f (x) − ∇ f (y)k2 ≤ L∇ f kx − yk2  2 1 + Lzj 1 + M jx 1 1 + M jx 2 2 1 + M jx − 2 2 ≤ 2κkx − yk2 q 1 + M jy −q 2 2 1 + M jy 1 + M jy 3 2 2 −q 2 2 (70) ≤ κkx − yk2 1 1 1 q 2 2 ≤ κkx − yk2 2 2 ≤ 2κkx − yk2 1 1 + M jy 2 2 3 ≤ 3κkx − yk2     −M j x −M j y > (M j x) − (M j y)> 1 1  ≤ L̃zj + Lzj M j kx − yk2 (71) (72) (73) (74) 2 (75) Non-convex variational photometric stereo 11 Proof Using Lemma 3.1 with F1 (z) := (M j z)> , F2 (z) := M j z, (A1) and M j x − M j y 2 ≤ M j kx − yk2 we can deduce (70). 2 Lemma 3.2, F1 (z) := 1 + M j z 2 ≥ 1 for all z ∈ Rn and the just shown validity of (70) we get (71). q 2 Making use of Lemma 3.3, F1 (z) := 1 + M j z 2 ≥ 1 holds for all z ∈ Rn and by employing (71) we obtain (72). 2 By using Lemma 3.3, F1 (z) := 1 + M j z 2 ≥ 1 for all z ∈ Rn , and together with (70) we getq(73). 2 By using Lemma 3.1, F1 (z) := 1/ 1 + M j z 2 ≤ 1 and   2 F2 (z) := 1/ 1 + M j z 2 ≤ 1 hold for all z ∈ Rn , so that together with (72) and (73) it is easy to see that (74) is true. By combining Lemma 3.1, F1 (z) := [−M j z, 1]> , F2 (z) := (M j z)> , (A1), (68) and M j x − M j y 2 ≤ M j kx − yk2 we finally get the validity of (75). t u The following lemma contains the first indication of Lipschitz estimates. Lemma 4 Let x, y ∈ Rn and A be defined as in (15). If (A1) holds true, then A j (x) − A j (y) 2 ≤ ρ j kS` k2 Lzj M j kx − yk2 {z } | (76) =:LAj for all j ∈ {1, . . . , n} as well as   kA(x) − A(y)k2 ≤ max LAj kx − yk2 j | {z } kAk2 q  = max eig (A> A) q   > = max eig A> 1 A1 , . . . , eig (An An ) r n  o = max max eig A>j A j = max A j j j (82) 2 . In the same way we can derive the equation kA(x) − A(y)k2 = max A j (x) − A j (y) j 2 and with (76) we obtain (77). From (77) and (78) follows (79). (83) t u The following assertion is an immediate consequence of (77). Corollary 4 Let x, y ∈ Rn . If (A1) holds true, then kA(x)M − A(y)Mk2 ≤ LA kMk2 kx − yk2 (84) We proceed with another building block used for coming to Proposition 2. Corollary 5 Let x, y ∈ Rn . If (A1) holds true, then A j (x)M j x − b j (x) − A j (y)M j y + b j (y) 2  ≤ ρ j kSk2 M j L̃zj Lzj + 1 kx − yk2 | {z } (85) f (77) =:L j for all j ∈ {1, . . . , n} and =:LA If additionally (A2) holds true, then p for all j ∈ {1, . . . , n} LAj ∈ O( m/n) p LA ∈ O( m/n) for all λ ∈ R we have (78) (79) Proof Let j ∈ {1, . . . , n}. From the definition of A j in (13) and from (72) follows directly (76). √ By ρ j ∈ [0, 1], kS` k2 ∈ O( m), (A2) and M j ∈ O(1) we obtain (78). Since A is a (in general non-square) block diagonal matrix we have   > A1 A1   2n,2n .. , (80) A> A =  ∈R . A> n An and with   det A> A − λ 12n     > = det A> A − λ 1 . . . det A A − λ 1 (81) n 1 2 2 1 n kA(x)Mx − b(x) − A(y)My + b(y)k2 s n  2 ≤ ∑ L jf kx − yk2 =: L f kx − yk2 (86) j=1 If additionally (A2) holds true, then for all j ∈ {1, . . . , n} √ √ L jf ∈ O( m), L f ∈ O( mn) (87) Proof From Lemma 3.1 with F1 (z) := q ρj 1 + M jz S,   −M j z F2 (z) := 1 (88) kF1 (z)k2 ≤ ρ j kSk2 , (68), (72) and the Lipschitz estimate kF2 (x) − F2 (x)k2 ≤ M j kx − xk2 follows (85). From (85) and with the definition of the Euclidean norm we obtain (86). The inclusion (87) follows from (A2), ρ j ∈ O(1) and √ u M j ∈ O(1) for all j ∈ {1, . . . , n} and kSk2 ∈ O( m). t The following lemma will subsequently be used to derive a Lipschitz estimate for ∇ f , but it also shows a more explicit representation of the exact gradient. 12 Radow et al. Lemma 5 For z ∈ Rn we have   p(z) := (Mz)> ⊗ 1mn D [A(z)] (z) − D [b(z)] (z)      −M1 z ρ1 >M z > − S M q 1 3 1   1 1+kM1 zk22     ..  = .        −M z   > 1 M> − q ρn 3S n Mn z 1 2 1+kMn zk where 0 p,q is a p × q block of zeros. Since 2 (89) 2 Proof To find an expression for p without the Kronecker product, we will simply write down all components of p and consecutively join them. For z ∈ Rn and j ∈ {1, . . . , n} we have bj =Ij − q D [b j ] = q ρj 1 + M jz ρj 1 + M jz 2 2 2 2 Sr , (90) >  > ∈ Rm,n S M z M r j j 3 (91) leading to >  M> 1 M1 z     ∈ Rmn,n >   M> M z n n  ρ1 q 3 Sr  1+kM1 zk22   D [b(z)] (z) =    ρn q 1+kMn zk22 .. . 3 Sr (92) For k ∈ {1, 2} with Akj (z), Sk` and Mkj we denote the k-th column of A j (z) and S` and the k-th row of M j . We derive h i ρ j Sk` D Akj (z) (z) = q 1 + M jz 2 2  > > M M z ∈ Rm,n (93) j j 3 Because of the structure of A, defined in (15), and our choice of the Jacobian matrix as per Definition 1, the Jacobian matrix of A has the form   1   D A1 (z) (z)  0mn−m,n     D A2 (z) (z)   1     0mn,n  D A1 (z) (z)   2    0mn−m,n  2   D [A(z)] (z) = D A2 (z) (z) ∈ R2mn ,n  2     0mn,n   ..     .   1   D An (z) (z)    0mn−m,n   2  D An (z) (z) (94) Rmn,2mn 3 (Mz)> ⊗ 1mn  1  M1 z M21 z M2n z   .. .. .. =  (95) . . . ··· 1 2 2 M1 z M1 z Mn z we get   (Mz)> ⊗ 1mn D [A(z)] (z)    1  1   M1 D A1 (z) (z) + M21 zD A21 (z) (z)   .. =  .  1   2  1 2 Mn zD An (z) (z) + Mn zD An (z) (z)    ρ1 > q 3 S` M1 z M1 M1 z >   1+kM1 zk22   ..   =  .  >   q ρn > SM z M M z  1+kMn zk22 3 n ` n (96) n Therefore, together with (92), we get      −M1 z ρ1 >M z > − S M q 1 3 1   1 1+kM1 zk22     ..  (97) p(z) =  .        −M z   > 1 M> M z − q ρn n 3S n 1 2 1+kMn zk 2 Corollary 6 Let z ∈ Rn , j ∈ {1, . . . , n} and   > ρj −M j z  > M M z S p j (z) := − q j j 3 1 2 1 + M jz 2 t u (98) If (A1) holds true, then p j (x) − p j (y) 2 ≤ ρ j kSk2 M j | 2   2 3L̃zj Lzj + L̃zj + Lzj kx − yk2 {z } (99) p =:L j If additionally (A2) holds true, then √ Lpj ∈ O( m) (100) Proof With Lemma 3.1 and the settings ρj F1 (z) := − q S 3 1 + M jz 2 (101) F2 (z) := [−M j z, 1]> (M j z)> M j (102) and with (74), (75) and (A1) we obtain (99). √ kSk2 ∈ O( m) and the esEquation (100) follows from    2 timate 3L̃zj Lzj + L̃zj + Lzj ∈ O(1) according to (A2). t u Non-convex variational photometric stereo 13 Proposition 2 Let ∇ f be defined as in (43) and q be defined as in (44), x, y ∈ Rn . If (A1) holds true, then where p is defined as in (89). By (99) we get s n  2 kp(x) − p(y)k2 ≤ ∑ Lpj kx − yk2 k∇ f (x) − ∇ f (y)k2 ≤ L∇ f kx − yk2 Together with (84) we obtain Let us now present finally the main result of this section. (103) q kq(x) − q(y)k2 ≤ L kx − yk2 (104) kF1 (x) − F1 (y)k2 where L∇ f := 1 m s s n ∑  j=1 Ij 2 + ρ 2j kSk22 2 n  2 ∑ Lpj + LA kMk2 (114) j=1 1 ≤ m  LA kMk2 + s n !  2 p ∑ L j kx − yk2 (115) j=1 Furthermore by the definition of p in (89) and analogously to (111) we get ! j=1 +Lf s + kF1 (z)k2 ≤ max ρ j kS` k2 kMk2 j n  2 2 kSk2 L̃z Lz ρ ∑ j 2 j j Mj j=1 s 1 L := m q n ∑  j=1 Ij 2 + ρ 2j kSk22 2 2 2 If additionally (A2) holds true, then L∇ f ∈ O(n) √ Lq ∈ O( n) (107) (108) Proof First we will derive a Lipschitz estimate for q. Assume that (A1) holds true. We define 1 (A(z)M)> m F2 (z) := A(z)Mz − b(z) F1 (z) := (109) (110) for all z ∈ Rn . As in (82) we get kF1 (z)k2 ≤ n kF2 (z)k2 ≤ ∑ j=1  Ij 2 + ρ 2j kSk22 2 1 (A(z)M + p(z))> m ∑ ρ 2j kSk22  2 L̃zj Lzj Mj 2 2 ! (116) Now by Lemma 3.1 with (86), (112), (115) and (116) we can deduce (103). Now assume that (A2) holds true. The inclusions (79), √ √ ρ j ∈ O(1), kMk2 ∈ O(1), I j 2 ∈ O( m) and kSk2 ∈ O( m) lead to s  n  2 2 kSk2 LA kMk ∈ O(m) I + ρ (117) j ∑ 2 2 j 2 j=1 Furthermore by (87), ρ j ∈ O(1), kMk2 ∈ O(1) and kS` k2 ∈ √ O( m) we obtain √ max ρ j kS` k2 kMk2 L f ∈ O(m n) (118) j Now from (117), (118) and 1/m ∈ O(1/m) follows (108). The inclusions (100), ρ j ∈ O(1), kMk2 ∈ O(1), I j 2 ∈ √ √ O( m) and kSk2 ∈ O( m) lead to (111) n ∑  j=1 2 I j 2 + ρ 2j kSk22 s  n  2 ∑ Lpj ∈ O(mn) (119) j=1 √ By (87), ρ j ∈ O(1), M j ∈ O(1), L̃zj ∈ O(1), Lzj ∈ O(1/ n) √ and kSk2 ∈ O( m) we obtain  (112) L f s n ∑ ρ 2j kSk22 j=1 With Lemma 3.1 and the Lipschitz estimates (84) and (86) we get (104). To deduce the Lipschitz estimate for ∇ f , we extend the proof by redefining F1 (z) := n j=1 s 1 max ρ j kS` k2 kMk2 m j and we also have s + (105) (106) j j s ! + max ρ j kS` k2 kMk2 L max ρ j kS` k2 kMk2 !!  LA kMk2 f 1 m (113)  2 L̃zj Lzj Mj 2 ∈ O(m) (120) Finally from (117), (118), (119), (120) and 1/m ∈ O(1/m) follows (107). t u We have shown that under the assumptions (A1) and (A2) the gradient as well as the approximated gradient of f are Lipschitz continuous. 14 Radow et al. As already indicated in (55), for practical applications we may also be interested in local Lipschitz constants L(`) fulfilling f (z̃(`+1) ) ≤ f (z̃(`) ) + h∇ f (z̃l ), z̃(`+1) − z̃(`) i + L(`) (`+1) z̃ − z̃(`) 2 2 2 (121) following the “lazy backtracking” strategy as it was proposed for the iPiano algorithm in [25]. By testing for the validity of this inequality also very small Lipschitz constants may be accepted, if the new value f (z̃(`+1) ) is even lower than what would be possible for a function f with an L(`) Lipschitz continuous gradient, for more details see also Section 6.1. β (`) = 5.3 Descent properties of the iPiano algorithm We have seen in Section 4.4 that it is not guaranteed that the approximated gradient q delivers a descent direction for the function f (z). Testing if −q(z) is a descent direction could be done by computing the actual gradient ∇ f (z), which is not desirable for practical applications. Another test may be to watch for increasing energies f (z̃(`) ) + g(z̃(`) ) during computations performed by the iPiano algorithm. However, iPiano does not enforce decreasing function values, but a descent property is given for a majorising sequence of values Hδ (`) (z̃(`) , z̃(`−1) ) := f (z̃(`) ) + g(z̃(`) ) + δ (`) ∆ (`) (122) as pointed out in [25], Proposition 4.7, where ∆ (`) := z̃(`) − z̃(`−1) δ (`) := 2 2 1 L(`) β (`) − − (`) 2 α (`) α (123) (124) (`) ∞ (`) ∞ (`) ∞ For sequences {z̃(`) }∞ `=−1 , {L }`=0 , {α }`=0 and {β }`=0 generated by iPiano, the sequence {Hδ (`) (z̃(`) , z̃(`−1) )}∞ `=0 is monotonically decreasing, and for ` = 0, 1, . . . , Hδ (`+1) (z̃(`+1) , z̃(`) ) ≤ Hδ (`) (z̃(`) , z̃(`−1) ) − γ (`) ∆ (`) γ (`) := 1 − − (`) 2 α (`) 2α β (`) ν −1 ν − 12 + c (127) As initialisation we set δ (−1) =1. 6 Numerical evaluation In this section we discuss some numerical experiments as well as important observations. For all our experiments, the stopping criterion was set to a test on the relative change in the objective function (< 10−8 ), evaluated on z̃(`) in the inner iPiano loop and on z(k) in the outer loop. Note that in the outer loop different albedos are used, i.e. the energies f (z(k) , ρ (k) ) + g(z(k) ) and f (z(k+1) , ρ (k+1) ) + g(z(k+1) ) are being evaluated. Also the maximum number of iterations was set to 100 in the inner iPiano loop and 500 in the outer loop, if not specified otherwise. 6.1 Computational aspects of iPiano Let us first recall that for a function f : Rn → R with a Lipschitz continuous gradient, such that (125) k∇ f (x) − ∇ f (y)k2 ≤ L∇ f kx − yk2 (126) | f (x) − f (y) − h∇ f (y), x − yi| ≤ holds, where L(`) a convergent state. In these cases the energies in the convergent state are always lower than the initial energy f (z̃(0) ) + g(z̃(0) ). When using the exact gradient ∇ f , we did not observe increasing energy values in our experiments. However, since the computation of q is a lot faster and we could achieve good results with the approximated gradient, we regard q as a more efficient approximation of ∇ f . For a constant step size β (`) = β , the sequence {δ (`) }∞ l=0 may not be monotonically decreasing, so that the convergence theory provided in [25] may not be applicable. This can be fixed be employing a variable β (`) in Algorithm 1, following the proof of Lemma 4.6 in [25]. Thus for every ` we compute the auxiliary variable ν := (`) (`) (δ`−1 + L2 )/(c + L2 ) and set While using the approximated gradient q(z) in our numerical experiments (c.f. Section 6), the property (125) always holds for ` > 0. In our numerical experiments we could sometimes observe increasing energies f (z̃(`) ) + g(z̃(`) ), but they were always accompanied by decreasing distances ∆ (`) , leading to for all x, y ∈ Rn we have L∇ f kx − yk22 2 (128) (129) for all x, y ∈ Rn , see e.g. [27] Theorem in 3.2.12. This leads to the property f (x) ≤ f (y) + h∇ f (y), x − yi + L∇ f kx − yk22 , 2 (130) for all x, y ∈ Rn , which is also the subject of the descent lemma, c.f. [25] Lemma 4.1. In the iPiano algorithm only Figure 5 presents the test data that we use in this paper. It consists of five real-world scenes captured under 20 different known illuminants si , (i = 1, . . . , 20), provided in [35]. In our experiments, we used m = 20 out of the original 96 RGB images, which we converted to grey levels. Two of the sets present diffuse reflectance (Cat and Pot), while two other exhibit broad specularities (Bear and Buddha) and one presents sparse specular spikes (Ball). Since the ground truth normals are also provided in [35], the estimated normals can be computed from the final depth map according to (3), and compared to the exact ground truth. For evaluation, we indicate the mean angular error (MAE) (in degrees) over the reconstruction domain Ω . Let us consider the Cat data set in some detail, as it consists of a diffuse scene that fits rather well our assumptions. We let our algorithm run for 1000 outer iterations k (approx. 1 hour on a recent i7 processor, using non-optimised Matlab code), and study the evolution of two criteria: the reprojection error, whose minimum is sought by our algorithm; and the MAE, which indicates the overall accuracy of the 3D reconstruction, c.f. the two left images within Figure 6. The displayed convergence graphs Energy 14 10−1 0 50 13.5 13 100 0 50 100 ` ` (a) (b) 12.4 101 Energy Lipschitz constant Fig. 2 The Cat experiment, k = 1: (a) local Lipschitz constants obtained by the lazy backtracking strategy; (b) objective function f + g as a function of the iPiano iterations count `. 100 0 50 100 12.36 12.32 0 50 ` 100 ` (a) (b) Fig. 3 The Cat experiment, k = 2: (a) local Lipschitz constants obtained by the lazy-backtracking strategy. At ` = 75 the increase generates a small α (`) , therefore the iPiano break criteria is fulfilled; (b) objective function f + g as a function of the iPiano iterations count `. Starting at ` = 46 the objective function slightly increases. This is not contrary to the convergence theory, since the descent property is fulfilled for a majorising sequence. ·10−3 ·10−2 1 1.5 hq, ∇ f i 6.2 Numerical results 100 hq, ∇ f i the necessary condition (130) is tested with x = z̃(`+1) and y = z̃(`) and used to derive a local Lipschitz constant. By this, one can allow step sizes leading to a steeper (better) descent in f . In our experiments we often encountered rather low local Lipschitz constants, some examples are depicted in Fig. 2. Sometimes we encountered increasing local Lipschitz constants towards the end of an iPiano instance. These would then lead to decreasing step sizes α (`) , such that finally the break criteria for the iPiano algorithm would be fulfilled. An example is depicted in Fig. 3 (a). While in most iterates in our experiments the energy f (z) + g(z) was decreasing, sometimes it was slightly increasing towards the end oft the sequence of iPiano iterations, see Fig. 3 (b). We conjecture that this is related to approximated gradients q, which do not deliver a descent direction with hq, ∇ f i ≥ 0, see also Fig. 4. We did not observe any spikes in the sequence of local Lipschitz or increasing energies when the exact gradient (43) was used. Therefore the use of the exact gradient would lead to a somehow smoother and faster convergence in terms of number of iterations. However, q(z) can be computed much faster than ∇ f (z) and we did not observe the exact gradient leading to local minima of (19) with significantly smaller energies, so that we still regard the use of the approximated gradient as the more feasible alternative. In detail, the average computation time (over 100 evaluations) of the exact gradient is roughly 55 seconds, whereas the simplified gradient can be evaluated in 0.13 seconds, which results in a speedup factor of more than 400. 15 Lipschitz constant Non-convex variational photometric stereo 0.5 1 0.5 0 0 0 50 100 0 50 ` (a) 100 ` (b) Fig. 4 The Cat experiment: hq, ∇ f i for (a) k = 1 and (b) k = 2. For non-negative values the vector −q(z(`) ) is a descent direction. indicate that each iteration from Algorithm 1 not only decreases the value of the objective function f + g (which is approximately equal to the reprojection error ER = f ), but also the MAE. This confirms our conjecture that finding the best possible explanation of the images yields more accurate 3D reconstructions. In the other two graphs in Figure 6 we study the results of our method compared to other PS strategies based on least-squares: the classical PS framework [40] consisting in estimating in a least squares sense the normals and the albedo, and integrating them afterwards, and the recent differential ratios procedure from [21], forcing Lambertian reflectance and least-squares estimation, for fair comparison. The latter allows direct recovery of the depth, 16 Radow et al. Cat Pot Bear Buddha Ball Fig. 5 Test data (brightened and cropped to enhance visualisation) and 3D-reconstructions obtained after 500 iterations k of Algorithm 1. 9.5 25 12 Error Error Error Energy 9 25 Classic PS Ratios Our method 14 30 10 0 500 k (a) 1,000 8.5 0 500 1,000 8 Classic PS Ratios Our method 20 15 0 k (b) 5 · 10−2 5 0.1 15 25 Number of Images noise (c) (d) Fig. 6 The Cat experiment: (a) objective function f + g as a function of the iterations count k; (b) MAE between the reconstructed surface and the ground truth; (c) reprojection error for competing methods for increasing noise levels (we indicate the standard deviation of the additive, zero-mean Gaussian noise, as a percentage of the maximum intensity); (d) ditto for increasing numbers of input images, with 0.1 noise level. but on the other hand it changes the objective function. Both other approaches rely on linear least squares: they are thus by far faster than the proposed approach (here, a few seconds, versus a few minutes with ours). Yet, in terms of accuracy, these methods are outperformed by our approach, no matter the noise level or the number of images (which were preprocessed via low-rank factorisation [41] in these two experiments). By making the input images Lambertian via low-rank preprocessing [41], we can make a reasonable comparison for the whole test dataset. Table 1 shows that our postprocessing method can still improve the accuracy. The 3D reconstruction results obtained with the full pipeline are shown in Figure 7. In comparison with Figure 5, artefacts due to specularities are clearly reduced. 7 Conclusions We have shown the benefits of recent, high performing numerical methods in the context of photometric stereo. Let us emphasise that only by considering such recent developments in numerical optimisation methods complex models as arising in PS can be handled with success. Our results show that a significant quality gain can be achieved in this Table 1 Reconstruction errors (MAE, in degrees) obtained for preprocessed input images using the approach from [41]. For fair comparison, the MAE for classic PS is calculated on the final surface, i.e. using the normals calculated by finite differences from the final depth map, rather than the (non-integrable) normals estimated in the first step. Regarding the ratio procedure, we applied the code from [21] directly on the grey level data. Classic PS [40] Differential ratios [21] Our method (500 iter.) Cat Pot Bear Buddha Ball 8.83 8.57 7.79 8.92 9.00 8.58 7.01 7.01 6.90 14.34 14.31 13.89 3.05 3.13 2.97 way while at the same time the mathematical proceeding can be validated rigorously. Our experimental investigation has shown what can be expected from the basic iPiano method as well as by computational simplifications as proposed by us in terms of an approximated gradient. In particular we have shown that it may not be easy to interprete relevant properties of computed iterates. A more detailed view on the computational results reveals that remaining inaccuracies seem to be mostly due to shadows and highlights, edges and depth discontinuities. Non-convex variational photometric stereo 17 Fig. 7 3D-reconstruction results using the full pipeline, consisting of a preprocessing [41], followed by classic PS [40], and finally the proposed method. Thus, an interesting perspective of our work would be to use more robust estimators, which would ensure both robustness to outliers [14, 33] and improved preservation of edges [6]. References 1. Bähr, M., Breuß, M., Quéau, Y., Boroujerdi, A.S., Durou, J.D.: Fast and accurate surface normal integration on non-rectangular domains. Computational Visual Media 3, 107–129 (2017) 2. Bartal, O., Ofir, N., Lipman, Y., Basri, R.: Photometric stereo by hemispherical metric embedding. Journal of Mathematical Imaging and Vision (to appear). URL https://doi.org/10.1007/ s10851-017-0748-y 3. Basri, R., Jacobs, D., Kemelmacher, I.: Photometric stereo with general, unknown lighting. International Journal of Computer Vision 72, 239–257 (2007) 4. Chabrowski, J., Kewei, Z.: On variational approach to photometric stereo. Annales de l’Institut Henri Poincaré (C) Analyse non linéaire 10(4), 363–375 (1993) 5. Clark, J.J.: Active photometric stereo. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 29–34 (1992) 6. Durou, J.D., Aujol, J.F., Courteille, F.: Integrating the normal field of a surface in the presence of discontinuities. In: Energy Minimization Methods in Computer Vision and Pattern Recognition (EMMCVPR), Lecture Notes in Computer Science, vol. 5681, pp. 261–273. Springer (2009) 7. Gotardo, P.F.U., Simon, T., Sheikh, Y., Matthews, I.: Photogeometric scene flow for high-detail dynamic 3D reconstruction. In: Proc. IEEE Int. Conf. Computer Vision (ICCV), pp. 846–854 (2015) 8. Harker, M., O’Leary, P.: Regularized reconstruction of a surface from its measured gradient field. Journal of Mathematical Imaging and Vision 51(1), 46–70 (2015) 9. Hinkley, D.V.: On the ratio of two correlated normal random variables. Biometrika 56(3), 635–639 (1969) 10. Hoeltgen, L., Quéau, Y., Breuß, M., Radow, G.: Optimised photometric stereo via non-convex variational minimisation. In: British Machine Vision Conference (BMVC) (2016). URL https: //doi.org/10.5244/C.30.36 11. Horn, B.K.P.: Robot Vision. The MIT Press (1986) 12. Horn, B.K.P., Woodham, R.J., Silver, W.M.: Determining shape and reflectance using multiple images. Technical Report MIT AITR-490, MIT (1978) 13. Horn, R.A., Johnson, C.R.: Topics in Matrix Analysis. Cambridge University Press (1994) 14. Ikehata, S., Wipf, D., Matsushita, Y., Aizawa, K.: Photometric stereo using sparse Bayesian regression for general diffuse surfaces. IEEE Transactions on Pattern Analysis and Machine Intelligence 36(9), 1816–1831 (2014) 15. Ju, Y.C., Tozza, S., Breuß, M., Bruhn, A., Kleefeld, A.: Generalised perspective shape from shading with Oren-Nayar reflectance. In: British Machine Vision Conference (2013). URL http://doi.org/10.5244/C.27.42 16. Khanian, M., Boroujerdi, A.S., Breuß, M.: Photometric stereo for strong specular highlights. Tech. Rep. arXiv:1709.01357 (2017) 17. Kozera, R.: Existence and uniqueness in photometric stereo. Aplied Mathematics and Computation 44, 1–103 (1991) 18. Lambert, J.H.: Photometria. Klett, Augsburg (1760) 19. Magnus, J.R., Neudecker, H.: Matrix differential calculus with applications to simple, Hadamard, and Kronecker products. Journal of Mathematical Psychology 29, 474–492 (1985) 20. Magnus, J.R., Neudecker, H.: Matrix Differential Calculus with Applications in Statistics and Econometrics, 3rd edn. John Wiley & Sons (2007) 21. Mecca, R., Quéau, Y., Logothetis, F., Cipolla, R.: A single-lobe photometric stereo approach for heterogeneous material. SIAM Journal on Imaging Sciences 9(4), 1858–1888 (2016) 22. Mecca, R., Rodolà, E., Cremers, D.: Realistic photometric stereo using partial differential irradiance equation ratios. Computers & Graphics 51, 8–16 (2015) 23. Moreau, J.J.: Proximité et dualité dans un espace Hilbertien. Bulletin de la Société Mathématique de France 93, 273–299 (1965) 24. Ochs, P.: Unifying abstract inexact convergence theorems for descent methods and block coordinate variable metric iPiano. Tech. rep., Saarland University (2016) 25. Ochs, P., Chen, Y., Brox, T., Pock, T.: iPiano: Inertial proximal algorithm for non-convex optimization. SIAM Journal on Imaging Sciences 7(2), 1388–1419 (2014) 26. Onn, R., Bruckstein, A.: Integrability disambiguates surface recovery in two-image photometric stereo. International Journal of Computer Vision 5, 105–113 (1990) 27. Ortega, J.M., Rheinboldt, W.C.: Iterative Solutions of Nonlinear Equations in Several Variables. New York Academic (1970) 28. Papadhimitri, T., Favaro, P.: Uncalibrated near-light photometric stereo. In: British Machine Vision Conference (2014). URL http://doi.org/10.5244/C.28.128 29. Petersen, K.B., Pedersen, M.S.: The matrix cookbook (2012). Available from https://www.math.uwaterloo. ca/~hwolkowi/matrixcookbook.pdf 30. Pollock, D.S.G.: Tensor products and matrix differential calculus. Linear Algebra and Its Applications 67, 169–193 (1985) 31. Quéau, Y., Durix, B., Wu, T., Cremers, D., Lauze, F., Durou, J.D.: LED-based photometric stereo: Modeling, calibration and numerical solution. Journal of Mathematical Imaging and Vision (to appear). URL https://dx.doi.org/10.1007/ s10851-017-0761-1 32. Quéau, Y., Lauze, F., Durou, J.D.: A L1 -TV algorithm for robust perspective photometric stereo with spatially-varying lightings. In: Scale Space and Variational Methods in Computer Vision (SSVM), Lecture Notes in Computer Science, vol. 9087, pp. 498–510 (2015) 33. Quéau, Y., Wu, T., Lauze, F., Durou, J.D., Cremers, D.: A nonconvex variational approach to photometric stereo under inaccurate lighting. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 99–108 (2017) 34. Reddy, D., Agrawal, A., Chellappa, R.: Enforcing integrability by error correction using l1 -minimization. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 2350– 2357 (2009) 18 35. Shi, B., Wu, Z., Mo, Z., Duan, D., Yeung, S.K., Tan, P.: A benchmark dataset and evaluation for non-Lambertian and uncalibrated photometric stereo. In: IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp. 3707–3716 (2016) 36. Smith, W., Fang, F.: Height from photometric ratio with modelbased light source selection. Computer Vision and Image Understanding 145, 128–138 (2016) 37. Tozza, S., Mecca, R., Duocastella, M., Del Bue, A.: Direct differential photometric stereo shape recovery of diffuse and specular surfaces. Journal of Mathematical Imaging and Vision 56(1), 57– 76 (2016) 38. Wöhler, C.: 3D Computer Vision. Springer-Verlag (2013) 39. Woodham, R.J.: Photometric stereo: A reflectance map technique for determining surface orientation from a single view. In: Proceedings of the 22nd SPIE Annual Technical Symposium, Proceedings of the International Society for Optical Engineering, vol. 155, pp. 136–143 (1978) 40. Woodham, R.J.: Photometric method for determining surface orientation from multiple images. Optical Engineering 19(1), 134– 144 (1980) 41. Wu, L., Ganesh, A., Shi, B., Matsushita, Y., Wang, Y., Ma, Y.: Robust photometric stereo via low-rank matrix completion and recovery. In: Asian Conference on Computer Vision (ACCV), Lecture Notes in Computer Science, vol. 6494, pp. 703–717. Springer Berlin Heidelberg (2010) 42. Zeisl, B., Zach, C., Pollefeys, M.: Variational regularization and fusion of surface normal maps. In: IEEE International Conference on 3D Vision (3DV), pp. 601–608 (2014) Radow et al.
1cs.CV
A Stochastic Approach to STDP Runchun Wang, Chetan Singh Thakur, Tara Julia Hamilton, Jonathan Tapson, André van Schaik The MARCS Institute, Western Sydney University, Sydney, NSW, Australia [email protected] Abstract— We present a digital implementation of the Spike Timing Dependent Plasticity (STDP) learning rule. The proposed digital implementation consists of an exponential decay generator array and a STDP adaptor array. On the arrival of a pre- and post-synaptic spike, the STDP adaptor will send a digital spike to the decay generator. The decay generator will then generate an exponential decay, which will be used by the STDP adaptor to perform the weight adaption. The exponential decay, which is computational expensive, is efficiently implemented by using a novel stochastic approach, which we analyse and characterise here. We use a time multiplexing approach to achieve 8192 (8k) virtual STDP adaptors and decay generators with only one physical implementation of each. We have validated our stochastic STDP approach with measurement results of a balanced excitation/inhibition experiment. Our stochastic approach is ideal for implementing the STDP learning rule in large-scale spiking neural networks running in real time. I.BACKGROUND The Spike Timing Dependent Plasticity (STDP) algorithm [1], which has been observed in the mammalian brain, modulates the weight of a synapse based on the relative timing of pre-synaptic and post-synaptic spikes. In STDP, the synaptic weight will be increased (or decreased) if a presynaptic spike arrives several milliseconds before (or after) the post-synaptic spike fires. This learning rule is computationally intensive as it exponential functions and divisions. In neuromorphic systems, various implementations of the STDP algorithm have been proposed, such as a circuit based on analogue blocks and flip-flops [2], a bistable synapse with a very compact analogue implementation of the STDP [3], and analogue blocks and switches to implement exponential STDP [4]. We have previously presented a compact implementation of the STDP using linear decays [5], [6]. Here, we present a novel stochastic approach that works with our previous system and can efficiently implement the STDP operations. II. EXPONENTIAL DECAY A. Infinite Impulse Response (IIR) filter approach A discrete time first order exponential decay implemented This work has been supported by the Australian Research Council Grant DP140103001. This work was inspired by the Capo Caccia Cognitive Neuromorphic Engineering Workshop 2014 and Telluride Neuromorphic workshop 2015. with an IIR filter can be expressed by the following equation: 𝑉[𝑡 + 1] = 𝛼𝑉[𝑡] (1) where, t represents the index of the time step, and 𝑉[𝑡] represent the previous value of V and the IIR filter constant 𝛼 is defined as: 𝜏 𝛼= (2) 𝜏+1 where, τ is the time constant (in clock cycles) and the decay d is given by: 𝑑 = 𝑉[𝑡] − 𝑉[𝑡 + 1] = 𝑉[𝑡] 𝜏+1 (3) When τ is large, 𝛼 is only a little less than 1, and a large number of bits are needed to encode its value accurately in a digital system. If the number of bits used to encode V is less than, the number of bits used to encode 𝛼, the above recursive multiplication just results in a linear decay. This situation occurs, for example, when simulating a neural network with many millions of neurons using time multiplexing [7]–[10]. With a standard IIR filter approach, a large number of bits would be needed for each state variable to achieve enough resolution to calculate long time constants. Large memory storage per state variable will result in a communication bottleneck, since only a few bits can be exchanged with the memory in a single clock cycle. B. Stochastic decay Instead of implementing the IIR multiplication directly, we can instead multiply V, encoded with much fewer bits than 𝛼, by the IIR factor 𝛼 and then add a random number r to the multiplication result. Mathematically, the method can be written as: 𝜏 𝑉[𝑡 + 1] = 𝑖𝑛𝑡( 𝑉[𝑡] + 𝑟[𝑡]) (4) 𝜏+1 where, r[t] is a random number drawn from a uniform distribution in the range (0,1). This is effectively a form of dithering to deal with the rounding of V to an integer value. For example, in our implementation discussed below we use 4 bits for V, 7 bits for r, and 9 bits for 𝛼. The decay is then given by: 𝑑 = 𝑉[𝑡] − 𝑉[𝑡 + 1] 𝜏 = 𝑉[𝑡] − 𝑖𝑛𝑡( 𝑉[𝑡] + 𝑟[𝑡]) 𝜏+1 𝑉[𝑡] = 𝑖𝑛𝑡 ( ) + 𝑋[𝑡] 𝜏+1 𝑝 = 𝑃(𝑋[𝑡] = 1) = 𝑉[𝑡] %1 𝜏+1 (5) (6) (7) (8) where 𝑋[𝑡] is a random binary variable, 𝑝 is the probability that 𝑋[𝑡] = 1, % is the modulo operation and 𝑖𝑛𝑡 (𝑉[𝑡]/(𝜏 + 1)) is the integer part of 𝑉[𝑡]/(𝜏 + 1). The expected value of X is given by (8), and simply represents the fractional part of 𝑉[𝑡]/(𝜏 + 1). The expected value for the decay is thus the integer plus fractional part of 𝑉[𝑡]/(𝜏 + 1) and thus equal to the IIR decay in (3), but we now only need to store a few bits for V[t]. C. Characterisation of variance Our stochastic approach not only reduces the storage needed, but also introduces variability between the STDP synapses, even when they time multiplex the exact same digital synapse. This variability makes the networks more realistic simulations of biological neural networks. Other digital implementations typically need to provide explicit sources of randomness when simulating neural networks. The stochastic part of the decay is fully determined by 𝑋[𝑡], which is either 0 or 1. Thus the number of time steps 𝑛 it takes to get a single stochastic decrement is given by the geometric distribution: 𝑃(𝑛) = (1 − 𝑝)𝑛−1 𝑝 (9) The variance for this distribution is given by: 𝑉𝑎𝑟(𝑛) = 1 − 𝑝 (𝜏 + 1)2 𝜏 + 1 = − 𝑝2 𝑉2 𝑉 (10) The variance is thus very large when 𝜏 is much larger than V. In (4), r is drawn from a uniform distribution in the range (0,1). Reducing the variance can be effectively achieved by limiting r in a smaller range as long as the following condition is met: 𝛼𝑉 + 𝑚𝑖𝑛(𝑟) < 𝑉 (11) Otherwise V will not decay. It is obvious that this condition is most critical when V is 1. For digital implementations, the most efficient way to generate random numbers is to use linear feedback shift registers (LFSRs), which do not have the value 0 as a possible output. Thus we can express this condition (with V = 1) as: 𝜏 𝜏 1 + min(𝑟) = + 𝐿<1 𝜏+1 𝜏+1 2 (12) 𝜏 < 2𝐿 − 1 (13) Fig. 1. Exponential decay obtained by using the stochastic approach. Here we use a 1 ms clock cycle. The dashed line is the IIR decay trace with a time constant 𝜏 of 30 ms (𝛼 = 495/512, a 9-bit number). V is stored as a 4-bit integer with an initial value of 15. (a) An example exponential achieved when using a 5-bit LFSR; (b) All possible decays with a 5-bit LFSR with different seeds; and (c) Exponential decays achieved using a 9-bit LFSR and 1023 different random seeds. It is clear that the variance of the exponential decays achieved with the 9-bit LFSR is much larger than that with the 5-bit LFSR. where, L is the length of the LFSR. For example, the maximum time constant that a 5-bit LFSR can achieve is 30 clock cycles. Using a 9-bit LFSR for the same time constant will create much larger variances (see Fig. 1). Hence the principle to reduce the variances is to use the LFSR with the minimum length that can still achieve the time constant. III.HARDWARE IMPLEMENTATION A. Learning rule In our hardware implementation, the amount of synaptic modification is summarised by the following standard exponential STDP equations: + 𝐴 𝑒𝑥𝑝(𝛥𝑡/𝜏+ ), 𝑖𝑓 𝛥𝑡 < 0 (14) 𝛥𝑤 = { − −𝐴 𝑒𝑥𝑝(𝛥𝑡/𝜏− ), 𝑖𝑓 𝛥𝑡 ≥ 0 where, 𝛥w is the modification of the synaptic weight, 𝛥t is the arrival time difference between the pre- and post-synaptic spike. A+ and A- determine the maximum amounts of synaptic modification for each spike pair. 𝜏 + and 𝜏 - are the time constants and control the rate of decay for potentiation and depression portions of the curve, respectively. As we focus on the low-cost hardware implementation of the exponential-type STDP, quantifying the effects of the STDP learning rules on the synaptic weights [11] are outside the scope of this paper. In the work reported here, we use 𝜏+= 𝜏- = 20 ms and A+=A=1 throughout. Hence, the 𝛥w is simply V[t] in equation (4). B. Topology In our previous work [5], [6], we implemented a time multiplexed (TM) synaptic plasticity adaptor array that is separate from the neurons in the neural network. Each adaptor (in that array) performs synaptic plasticity, (such as STDP), according to the arrival times of the pre- and post-synaptic spikes assigned to it and sends out the updated weight to the post-synaptic neuron in the neural network. Since this strategy provides great flexibility for building complex large-scale neural networks, we chose to use the exact same architecture as in [6] to implement an exponential-type STDP adaptor array (see Fig. 2). It consists of a controller, a Master RAM, a TM STDP adaptor array and a TM exp-decay generator array, all of which, with the exception of the last one, are identical to ones presented in [6]. The TM adaptor array and the TM exp- Fig. 2. The structure of the STDP adaptor array. decay generator array are both configured to have 8192 (8k) units, each TM exp-decay generator being assigned to one TM STDP adaptor. Thus, the TM time window generator array in [6], which generates a linear decay, is replaced by the expdecay generator array in the work presented here. The exponential STDP adaptor array operates in the exact same manner as the digital synaptic adaptor array in [6]. The controller receives pre- and post-synaptic spikes from the neuron array and assigns them to the corresponding TM STDP adaptors according to their addresses. Each TM exp-decay generator will start an exponential decay when either a pre- or post-synaptic spike arrives, which will be used by the corresponding TM STDP adaptor to determine the weight update. As we assume that the adaption will not be carried out if the pre- and post- synaptic spikes arrive simultaneously, thus only one TM exp-decay generator will be needed. The STDP adaptor will carry out the weight adaption using its output V[t]. The weight values are stored in the local cache and the Master RAM. The stored weight values will also be sent out to the corresponding neuron in the neural network for the post-synaptic current generation. C. Time-multiplexed exponential decay generator array The decay generator array was implemented by using time multiplexing to achieve 8k TM exp-decay generators using only one physical exp-decay generator. The global counter processes each TM exp-decay generator sequentially. Each TM exp-decay generator uses a time slot of 25 clock cycles (125 ns with 200 MHz clock frequency) to complete its processing to maintain an update rate of 1 kHz (the corresponding time step is about 125 ns×8k=1 ms). In each time slot, the global counter will read the value of the V[t] (a 4-bit integer) from the Decay RAM with a size of 8k×4bit. V[t] will be reset to Vinit (set to 15 here), when the digital input spike (Decay_start) from the TM adaptor is active (high). When there is no input spike, we will apply the stochastic approach (see equation (4)) to V[t] in each time slot (of that TM exp-decay generator), until it reaches zero, indicating the end of the exponential decay. These computations were implemented with a single fixedpoint-number multiplier. Its inputs are 𝛼 (a 9-bit integer) and V[t] (4-bit), resulting in a 13-bit output value. To allow different time constants for different synapses, we use a multiplexer to choose from different 𝛼 s. Also for future extensions, we use a 7-bit LFSR to generate r, but the LFSR is configured to use only its five least significant bits in the work reported here. It will generate a new value every 1 ms. The integer part of the product, V[t+1], will then be stored into the exp-decay RAM. IV.MEASUREMENT RESULTS We have successfully implemented the exponential-type STDP adaptor array on an Altera Cyclone V FPGA. Table I shows the utilisation of hardware resources on the FPGA. As Table I shows, the proposed system uses only a small fraction (<1%) of the hardware resources. We have tested the performance of the exponential-type STDP adaptor array by performing a balanced excitation experiment, based on the experiment run by [11]. Song et al. Fig. 3. Balanced excitation experiment. (a) Weight distribution after 1s of STDP for an input rate of 10 Hz. The bimodal distribution of strong and weak weights is apparent; (b) Scatter plot of the final weight distribution. TABLE I Device utilisation Altera Cyclone 5CGXFC5C6F27C7 Layers ALMs RAMs DSPs 1 246/29080 192k/4.5M 1/450 have shown that competitive Hebbian learning [12] can be performed through STDP [11]. The competition (induced by STDP) between the synapses can establish a bimodal distribution of the synaptic weights: either towards zero (weak) or the maximum (strong) values (see Fig. 3). V. CONCLUSIONS In this paper, we demonstrated a digital implementation of the STDP learning rule using a novel stochastic approach. This approach is capable of producing the same results to a more complex STDP model while occupying only a fraction of the area. The compactness of the implementation plus the added stochasticity of the results presents a perfect solution for implementing synaptic learning in large-scale digital neural networks. VI.REFERENCES [1] W. Gerstner, R. Kempter, J. L. van Hemmen, and H. Wagner, “A neuronal learning rule for sub-millisecond temporal coding.,” Nature, vol. 383, no. 6595, pp. 76–81, Oct. 1996. [2] A. Bofill-i-petit and A. F. Murray, “Synchrony detection and amplification by silicon neurons with STDP synapses.,” IEEE Trans. Neural Netw., vol. 15, no. 5, pp. 1296–304, Sep. 2004. [3] G. Indiveri, E. Chicca, and R. Douglas, “A VLSI array of low-power spiking neurons and bistable synapses with spike-timing dependent plasticity.,” IEEE Trans. neural networks, vol. 17, no. 1, pp. 211–21, Jan. 2006. [4] T. J. Koickal, A. Hamilton, S. L. Tan, J. A. Covington, J. W. Gardner, and T. C. Pearce, “Analog VLSI Circuit Implementation of an Adaptive Neuromorphic Olfaction Chip,” IEEE Trans. Circuits Syst. I Regul. Pap., vol. 54, no. 1, pp. 60–73, Jan. 2007. [5] R. Wang, T. J. Hamilton, J. Tapson, and A. van Schaik, “A compact reconfigurable mixed-signal implementation of synaptic plasticity in spiking neurons,” in 2014 IEEE International Symposium on Circuits and Systems (ISCAS), 2014, pp. 862–865. [6] R. M. Wang, T. J. Hamilton, J. C. Tapson, and A. van Schaik, “A neuromorphic implementation of multiple spike-timing synaptic plasticity rules for large-scale neural networks,” Front. Neurosci., vol. 9, no. May, pp. 1–17, 2015. [7] R. M. Wang, T. J. Hamilton, J. C. Tapson, and A. van Schaik, “A mixed-signal implementation of a polychronous spiking neural network with delay adaptation.,” Front. Neurosci., vol. 8, no. March, p. 51, Jan. 2014. [8] R. Wang, G. Cohen, K. M. Stiefel, T. J. Hamilton, J. Tapson, and A. van Schaik, “An FPGA Implementation of a Polychronous Spiking Neural Network with Delay Adaptation.,” Front. Neurosci., vol. 7, no. February, p. 14, Jan. 2013. [9] R. Wang, T. J. Hamilton, J. Tapson, and A. van Schaik, “A compact neural core for digital implementation of the Neural Engineering Framework,” in BIOCAS2014, 2014. [10] R. Wang, T. J. Hamilton, J. Tapson, and A. van Schaik, “An FPGA design framework for large-scale spiking neural networks,” in 2014 IEEE International Symposium on Circuits and Systems (ISCAS), 2014, pp. 457–460. [11] S. Song, K. D. Miller, and L. F. Abbott, “Competitive Hebbian learning through spike-timing-dependent synaptic plasticity.,” Nat. Neurosci., vol. 3, no. 9, pp. 919–26, Sep. 2000. [12] D. Hebb, The organization of behavior. New York, NY: Wiley & Sons, 1949.
9cs.NE
Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs Bhushan Kotnis and Vivi Nastase Institute for Computational Linguistics, University of Heidelberg Heidelberg, Germany {kotnis,nastase}@cl.uni-heidelberg.de arXiv:1708.06816v2 [cs.AI] 2 Mar 2018 ABSTRACT Knowledge graphs are large, useful, but incomplete knowledge repositories. They encode knowledge through entities and relations which define each other through the connective structure of the graph. This has inspired methods for the joint embedding of entities and relations in continuous low-dimensional vector spaces, that can be used to induce new edges in the graph, i.e., link prediction in knowledge graphs. Learning these representations relies on contrasting positive instances with negative ones. Knowledge graphs include only positive relation instances, leaving the door open for a variety of methods for selecting negative examples. We present an empirical study on the impact of negative sampling on the learned embeddings, assessed through the task of link prediction. We use state-of-the-art knowledge graph embedding methods – Rescal , TransE, DistMult and ComplEX – and evaluate on benchmark datasets – FB15k and WN18. We compare well known methods for negative sampling and propose two new embedding based sampling methods. We note a marked difference in the impact of these sampling methods on the two datasets, with the ”traditional” corrupting positives method leading to best results on WN18, while embedding based methods benefit FB15k. CCS CONCEPTS •Information systems → Question answering; Retrieval tasks and goals; Information retrieval; KEYWORDS knowledge graphs, negative sampling, embedding models, link prediction ACM Reference format: Bhushan Kotnis and Vivi Nastase. 2018. Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs. In Proceedings of Workshop on Knowledge Base Construction, Reasoning and Mining, Los Angeles, California USA, Feb 2018 (KBCOM’18), 14 pages. DOI: 10.1145/nnnnnnn.nnnnnnn YAGO [25] are examples of large knowledge graphs that contain millions of entities and facts. Facts are represented as triples, each consisting of two entities connected by a binary relation, e.g., (concept:city:London, relation:country capital, concept:country:UK). Here entities such as London and UK are represented as nodes and the relation country capital is represented as a binary link that connects these nodes. The same two nodes may be connected by more than one type of relation, making the KG a multi-graph. KGs have found applications in question answering systems [15], evaluating trustworthiness of web content [8], and web search [7]. Although KGs such as Freebase consist of millions of entities and billions of facts, they are still incomplete [28] which limits their application. However, it is possible to infer new (missing) facts from known facts. Recently, latent factor models that capture global patterns from the KG have received considerable attention. They learn a representation of the graph in a continuous vector space by inducing embeddings that capture the graph structure. Predicting new edges to automatically add new facts to a KG helps bypass the text analysis stage and bootstrap new knowledge based on what is already captured in the KG. Similar to other problems in processing natural language, such as parsing, data consists (almost) exclusively of positive instances. A solution to this issue is using implicit negative evidence, whereby instances that have not been observed are considered negatives, and are used for contrastive estimation [23], where the aim is to rank observed instances higher than negative (unobserved) ones. Negative instances can be generated using a variety of methods. In this article we present the results of our investigation on the impact of several negative sampling methods on state-of-the-art knowledge graph embedding models. Additionally we propose two negative sampling strategies for fine tuning the model. Understanding the impact of negative instance sampling will have at least two uses: providing the basis for choosing the negative sampling method to build the best model for a given method, and allowing us to place in the right context results reported in the literature that were produced while using different negative sampling methods. 2 1 INTRODUCTION Much of human knowledge can be formalized in terms of real world entities, abstract concepts, categories and the relations between them. A graph structure – a knowledge graph (KG) – is a natural candidate for representing this. NELL [5], Freebase [3] and KBCOM’18, Los Angeles, California USA 2018. 978-x-xxxx-xxxx-x/YY/MM. . . $15.00 DOI: 10.1145/nnnnnnn.nnnnnnn LINK PREDICTION IN KNOWLEDGE GRAPHS Knowledge graphs KG = (E, R) contain knowledge in the form of relation triples (s, r, t), where s, t ∈ E are entities, and r ∈ R is a relation. These knowledge graphs are not complete, and additional links (facts) can be inferred, based on the idea that similar nodes have similar relations – e.g. all countries have a capital city. The KG can be encoded using different modeling techniques, which results in encodings for both the entities and the relations. KBCOM’18, Feb 2018, Los Angeles, California USA A variety of techniques have been proposed [4, 14, 20, 21, 24, 29]. These methods learn a model for the processed KG as a large set of parameters, induced based on optimizing a loss function with respect to positive and negative instances of links representing different relations. Methods such as Rescal [21] and Neural Tensor Networks [24] learn millions of parameters that makes them more flexible, enabling them to model well a variety of relations, but at the cost of increased computational complexity and potential overfitting. TransE [4], DistMult [29] learn simpler models (with far fewer parameters) and are easier to train but are unable to model certain types of relations such as many-to-one (TransE) and asymmetric relations (DistMult). Recent work such as [20] achieve the modeling power of Rescal with a smaller number of parameters by compressing the tensor product. Complex valued embeddings (ComplEx) [27] extend the DistMult to model antisymmetric relations by using complex valued embeddings. [12] showed that most latent factor models can be modified to learn from paths rather than individual triples which improves performance. Recurrent Neural Networks that learn path representations have also been used for link prediction [6, 18]. All these models require negative samples during training. We focus our analysis on four state-of-the-art methods with respect to link prediction in knowledge graphs: ComplEx, DistMult, Rescal , TransE. ComplEx performs as well as the Holographic Embedding (HolE) model, so HolE was not included1 . 2.1 Rescal The Rescal model [21, 22] weighs the interaction of all pairwise latent factors between the source and target entity for predicting a relation. It represents every entity as a d dimensional vector (x ∈ Rd ), and every relation as a d × d matrix W ∈ Rd ×d . This model represents the triple (s, r, t) as a score given by Bhushan Kotnis and Vivi Nastase where x s , x r , x t are d dimensional vectors, and d(x) is either the L 1 or L 2 -norm of x. We use TransE with L 2 -norm. For learning embeddings, we use max-margin loss (1). Compared to Rescal , TransE has much fewer parameters, but it is more limited in the variety of relations it can model, as the translation operation assumes 1 : 1 relations. 2.3 sc (s, r , t) = x sT Diag(Wr ) x t This can also be written as a three way inner product sc (s, r , t) = hx s , x r , x t i Í where hx s , x r , x t i = i x si x r i x ti and x r = Diag(Wr ) and x s , x r , x t ∈ Rd . As before we use the margin loss (1) for learning these vectors. 2.4 i t 0 ∈N (t ) 0 0 sc i = sc (si , r i , ti ) and sc i = sc (si , r i , ti ). N (t) is the set of incorrect targets. Similar triples are used where the relation and target are shared, but the source entity is incorrect. 2.2 TransE TransE [4] interprets relations as a translation operation from the source to the target mediated by the relation. More specifically, it embeds a triple spatially such that the source vector can travel to the target vector through the relation vector, i.e., x s + x r ≈ x t . The scoring function sc (s, r , t) for TransE is given by sc (s, r, t) = −d(x s + x r − x t ) 1 And also because HolE is very similar to ComplEx. This was verified through personal correspondence with an author of the ComplEx paper. ComplEx The ComplEx model [27] performs sparse tensor factorization of the KG in the complex domain. Nodes and relations are modeled by d dimensional vectors with a real and imaginary part (Re(x), Im(x)). This allows ComplEx to model anti-symmetric relations since the three way dot product (inner product) in the complex domain is not symmetric. ComplEx can be seen as DistMult with complex embeddings. The score function of ComplEx is given by: sc (s, r , t) = x sT Wr x t These vectors and matrices are learned using a loss function that contrasts the score of a correct triple to incorrect ones. Commonly used loss functions include cross-entropy loss [26], binary negative log likelihood [27], and max-margin loss [12, 20] which we use here: N Õ Õ L(θ ) = [1 − sc i + sc0i ]+ (1) DistMult DistMult [29] is a special case of the Rescal model, where the relation matrix is assumed to be diagonal. This results in a sparse relation matrix and consequently fewer parameters. However this simplicity results in the reduction of modeling power. The DistMult model is symmetric and hence can only model symmetric relations. However, DistMult performs well on FB15K benchmark dataset, since the test data contains only a few instances of asymmetric triples. The DistMult scoring function is given by sc (s, r , t) = Re(hx s , x r , x¯t i) = hRe(x s ), Re(x r ), Re(x t )i + hIm(x s ), Re(x r ), Im(x t )i + hRe(x s ), Im(x r ), Im(x t )i − hIm(x s ), Im(x r ), Re(x t )i [27] trained ComplEx with negative log-likelihood. To maintain the same experimental conditions for assessing the efficacy of negative sampling, we train ComplEx with max margin loss (1). 3 NEGATIVE SAMPLING Knowledge Graphs capture knowledge as <entity, relation, entity> triples, with entities mapped to nodes, and relations to edges. KGs contain only positive instances. While one-class classification solutions have been around for some time [17], for inducing KG embeddings, using negative instances leads to better models. Negative instances are not marked in a knowledge graph. The task of link prediction has much in common with other tasks in NLP where (most of) the observed data consists of positive instances. [23] proposed contrastive estimation, whereby instances that were produced by perturbing the observed ones (and that themselves have not been observed) will serve as negative instances, and the aim is to rank observed instances higher than the unobserved (”negative”) ones. In neural probabilistic language models, negative sampling was first proposed in [1] as importance sampling. A sampling solution that was more stable than importance sampling Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs was introduced by [16], who built upon the noise-contrastive estimation [10]. In these approaches negative samples are drawn from a non-parametric noise distribution. For knowledge graphs in particular there are many different ways to produce negative instances based on the graph structure. We present an overview of techniques for producing negative instances from a knowledge graph, and we evaluate their impact on knowledge graph completion, or link prediction. 3.1 Random sampling : R The simplest form of sampling negative instances is to assume a closed world hypothesis and consider any triple that does not appear in the KG as a negative instance. Let K = K + = {(si , r i , ti )|yi = 1; i = 1, 2, · · · , N } denote the complete knowledge graph, where yi = 1 represents the presence of a triple (si , r i , ti ) (a positive instance) and yi = 0 represents absence. According to the closed world assumption, the set of negatives K − is given by K − = {(si , r i , ti )|yi = 0; i = 1, 2, · · · , N } Since the KG is incomplete this set contains positive triples not present in the KG. Furthermore this set might be very large because the incorrect facts (O(N 2 )) far outnumber the correct ones. A simple solution to the scalability problem is randomly sampling a small number of samples from K − . Given a positive triple (s, r, t) we generate ns negative triples by sampling ns target entities from the entity set E. Since the sampling is random, we do not check whether the sampled triples are present in the train and development set, because the probability they are present in K + is negligible. The same procedure is used to generate negative source entities. The negatives produced by random sampling may not be very useful: for the positive triple (Tom Cruise, starred in, Top Gun), negative targets such as London or Mount Everest seem irrelevant. Relevant negative targets should include entities that are movies, such as Terminator, Inception. To obtain such negatives it is necessary to constrain the set of entities from which samples are drawn. We explore such constraints in the following sections. 3.2 Corrupting positive instances : C We use a method described in [24] that generates negative instances by corrupting positive instances: for every relation r , Socher et al. [24] collect the sets S = {s |(s, r, ∗) ∈ K + } and T = {t |(∗, r, t) ∈ K + }, and produce sets of corrupted triples S 0 = {(s 0, r, t)|s 0 ∈ S, (s 0, r , t) < K + } and T 0 = {(s, r , t 0 )|t 0 ∈ T , (s, r, t 0 ) < K + }. During training K + consists of triples from training and development set. We sample a number ns of negative samples from S 0 and T 0 . Such a method produces negative instances that are closer to the positive ones than those produced through random sampling. An issue with this method is that for relations with very few positive instances, there will not be a large enough pool of source and target candidates to corrupt the positive instances. The data analysis shows that this is an issue for the FB15k dataset. For relations where not enough corrupted negative instances can be KBCOM’18, Feb 2018, Los Angeles, California USA produced, we supplement this set with randomly produced negative samples. 3.3 Typed Sampling : T Knowledge graphs such as FreeBase and NELL [5] have strongly typed relations. For example, a relation born in holds between entities of type person and entities of type city. Relevant negative candidates (sources or targets) can be mined by constraining the entities to belong to the same type as that of the source (or target). This can help bypass the problem mentioned for the corrupt method, when some relations in the dataset have very few instances. For every relation r : S → T , if Sr,t = {s |s has type S t } and Tr,t = {t |t has type Tt }, with S t and R t the domain and range respectively of r , negative instances will consist of triples (s 0, r, t), s 0 ∈ S and (s, r , t 0 ), t 0 ∈ T , such that (s 0, r , t) < R and (s, r , t 0 ) < K + . We then sample ns number of negative samples from these triples. If an entity has more than one type (e.g. Albert Einstein has types person, scientist), we include it in Sr,t (or Tr,t ) if one of its types matches S t (or Tt ). We obtain category data for the Freebase dataset from Freebase relation metadata released in [9], and the entity type by mapping the Freebase entity identifier to the Freebase category. This results in 101,353 instances of the category relation which is used in the training stage to produce typed negative samples. Domain and range types for Freebase relations are provided by Freebase itself. A few examples of entities and types are included in Table 1. We do not use typed sampling for Wordnet. The hypernym/hyponym relations are the de facto type relations in WordNet, but are hierarchical rather than a mapping onto a given small set of predetermined types as in Freebase. 3.4 Relational Sampling : REL Although typed or corrupt relation sampling can generate relevant negative candidates, due to the incompleteness of the KG, some of these candidates could be unknown positives. If we assume that source target pairs participate in only one relation, then sampling targets (sources) that are connected to the current source (target) through relations other than the current relation can yield true negatives. This is a common procedure in multi-class learning. More formally, for positive triple (s, r , t) the negative candidate source set is S − = {s |(s, r 0, t 0 ), ∀ r 0 ∈ R, r 0 , r } and target set T − = {t |(s 0, r 0, t), ∀ r 0 ∈ R, r 0 , r }. As before, after computing S and T we filter out positive triples from train and development set and sample a number ns of negative samples. 3.5 Nearest Neighbor sampling : NN Most negative sampling methods generate negative samples based on either the closed world assumption, functional constraints such as type constraints, and triple perturbation [19]. We introduce a negative sampling method which uses a pre-trained embedding model for generating negative samples. We name this pre-trained embedding model the ‘negative sampling model’. We use the negative sampling model to generate negative targets (sources) that are KBCOM’18, Feb 2018, Los Angeles, California USA Source Type Source f ilm star wars episode IV person alexandre dumas academic post pro f essor Table 1: Entity Types in Freebase: Examples of source samples. Bhushan Kotnis and Vivi Nastase Relation Target Target Type produced by дeorдe lucas f ilm producer people pro f ession writer pro f ession pro f ession people albert einstein award winner and target entity types from Freebase used for generating negative close to the positive target (source) in vector space. This would help the model learn to discriminate between positives and negatives very similar to the positives. For a positive triple (s, r , t), with x t the vector representation of t obtained from the negative sampling model, the set of negative samples are the top ns nearest neighbors of x t (that are not positive) obtained from the negative sampling model. The negative sampling model may be different than the model that is being trained. We use the Rescal model trained with 100 typed (T) negative samples as a negative sampling model for the FB15K dataset. Note that the Rescal model parameters are frozen (not updated), it is simply used for generating negatives that are used for training another model. Algorithm 1 describes the procedure for a single triple. In practice we use a batch of triples and the nearest neighbor search is performed using the Ball Tree algorithm which is built only once since the negative sampling model is not updated. Algorithm 1: Algorithm 1 Nearest Neighbor Sampling Input : Triple (s,r,t), Entity Set E, Positive source and targets Ps and Pt , Negative Sampling Embedding Model fn , Number of negative samples ns Output : Set of ns negative samples Ns ← E\Ps , Nt ← E\Pt ; X ns ← f (Ns ), X nt ← f (Nt ) ; Initialize the K ball tree with X ns and X nt ; x t ← fn (t) ; x s ← fn (s) ; S ← nearest neighbors(x s ,num=ns ); T ← nearest neighbors(x t ,num=ns ); return S,T Nearest neighbor sampling is computationally expensive compared to the methods discussed in previous sections. This is because a search over all entities needs to be performed for source and target entities for every triple. Therefore we use a model trained using typed negative sampling methods for Freebase and corrupted sampling for Wordnet to initialize the parameters and then fine tune the model using nearest neighbor sampling for 5 epochs. 3.6 neighbor sampler, we use the negative sampling model for obtaining the predicted vector and entity embeddings. The negative sampling model is not updated. Given a positive triple (s, r , t) we obtain the predicted vector vt = x sT Wr where x s , Wr are entity and relation embeddings of source s and relation r obtained using the negative sampling model. Note that vt may not be the same as x t , the target entity representation. The set of (target) negative samples are the top ns nearest neighbors of the predicted vector vt . Algorithm 2 describes the procedure for a single triple, in practice we use a batch and the Ball Tree is built only once. Algorithm 2: Near Miss Sampling using Rescal negative sampler Input : Triple (s,r,t), Entity Set E, Positive source and targets Ps and Pt , Negative Sampling Embedding Model fn , Number of negative samples ns Output : Set of ns negative samples Ns ← E\Ps , Nt ← E\Pt ; X ns ← f (Ns ), X nt ← f (Nt ) ; Initialize the K ball tree with X ns and X nt ; x s ← fn (s), x t ← fn (r ), Wr ← fn (r ) ; vs ← x sT Wr , vt ← Wr x t ; S ← nearest neighbors(vs ,num=ns ); T ← nearest neighbors(vt ,num=ns ); return S,T Like nearest neighbor sampling, near miss sampling is also computationally expensive, so instead of learning from randomly initialized parameters we tune a pre-trained model for 5 epochs. 4 DATA We evaluate the impact of negative sampling on the Freebase dataset (FB15k) and on the WordNet dataset (WN18) introduced by [4]. They are very different in coverage – FB15k contains mostly named entities connected through strongly typed relations, while WN18 contains mostly common nouns connected through lexical and semantic relations. Dataset details are included in Table 2. Near Miss sampling : nmiss The nearest neighbor sampler generates negatives that are similar to positives in vector space. Some of those negatives may be ranked higher than the positives. Exposing such highly ranked negatives to the classifier can help the model learn a better discriminator. We name this setting as near miss sampling, because the generated negatives are top ranked candidates which makes it difficult for the model to classify them as negatives (near misses). To generate highly ranked negatives, we collect the top ns targets (sources) closest to the predicted target (source) vector. Like the nearest 4.1 FB15k FB15k [4] consists of approximately 15,000 entities and 1345 relations. We use the split supplied by the dataset: 483,142 train, 50,000 validation and 59,071 positive test instances. Data set |E | |R| Training FB15K 14,951 1345 483,142 40,943 18 141,442 WN18 Table 2: Dataset Details: |E | = # of tions. Development 50000 5000 entities, |R| = Test 59071 5000 # of rela- Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs KBCOM’18, Feb 2018, Los Angeles, California USA Figure 1: FB15k dataset frequency statistics Figure 2: WordNet18 dataset frequency statistics The training data contains relations that have high variation in the number of instances – 39% of the relations have at most 10 instances, while the most frequent relation2 has almost 16000. This disparity is also reflected in the distribution of node degrees – 12% of the entities have degree equal or less than 10 (appear in at most 10 instances). The average degree of a node in FB15k is approximately 13.2 overall, and 32.4 on the training data. The distribution of relations and node degrees is presented in Figure 1. The type of relations included in Freebase connect named entities. They are extrinsic relations, in that they do not hold based on the intrinsic properties of the connected entities, but are due to external circumstances. For example, the people profession relation connecting people and their professions are not determined by intrinsic properties of people and professions. Relations in FreeBase are strongly typed – the domain and range of the relations are types, e.g. the country capital relation connects countries and cities. From a graph structure point of view, WN18 nodes have low connectivity – the average degree on the entire dataset is approximately 1.2, and on the training data alone approximately 3.45. This translates into sparser adjacency matrices for factorization, compared to Freebase. WordNet contains lexical and semantic relations. Lexical relations – such as derivationally related form connect lemmas from different parts of speech that are morphologically connected. The semantic relations cover is a relations (hypernym / hyponym, instance hypernym/hyponym), three types of part of relations (member, substance and part). The semantic relations in WordNet are intrinsic, as they reflect or arise from intrinsic properties of the connected entities. For example, a cat is a animal, and cat has part paws not because of external circumstances, but because of what a cat is. Compared to FreeBase, WordNet relations are not typed – there is no clear domain and range for the WordNet relations. 4.2 5 EXPERIMENTS 5.1 Implementation WN18 This dataset consists of a subset of relations from the WordNet lexical database3 , split into training, development and testing: 141442/ 5000/ 5000. There are 18 relations. There is less variation in the number of instances per relation compared to the FB15k, as can be seen in Figure 2. There is one relation with less than 100 instances (similar to), while the most frequent relations (hypernym, hyponym) have approximately 35,000. 2 /award/award nominee/award nominations./award/award nomination/award nominee 3 https://wordnet.princeton.edu/ For fair comparison we reimplemented Rescal , TransE, DistMult, ComplEx using PyTorch, and tested them using the same experimental setting: same loss (max-margin loss), embedding size (100), and data. We use the Adam [13] SGD optimizer for training because it addresses the problem of decreasing learning rate in AdaGrad. We ensure that entity embeddings for all the models have unit norm. We performed exhaustive randomized grid search [2] for the L 2 regularizer on the validation set for all models and we tuned the KBCOM’18, Feb 2018, Los Angeles, California USA Model lr λ Freebase ComplEx 0.001 1.31E-06 DistMult 0.001 4.93E-06 Rescal 0.001 0.0002084 TransE 0.001 0.00024036 Wordnet ComplEx (ns ∈ {1, 2, 5}) 0.005 2.82E-05 ComplEx (ns >= 10) 0.01 2.82E-05 DistMult (ns ∈ {1, 2, 5}) 0.005 3.12E-06 DistMult (ns >= 10) 0.01 3.12E-06 Rescal (ns ∈ {1, 2, 5}) 0.005 7.48E-05 Rescal (ns >= 10) 0.01 7.48E-05 TransE (ns ∈ {1, 2, 5}) 0.005 0.0001863777692 TransE (ns >= 10) 0.01 0.0001863777692 Table 3: Parameter values training duration using early stopping. The learning rate (lr ) and λ (the L 2 norm coefficient) are presented in Table 3. The code is available in Github 4 . The different methods for negative sampling described in Section 3 were used to produce negative instances for training. In FB15K some relations do not have enough sources or targets to generate negative triples by corrupting positive triples. If the number of generated triples are less than the required (ns ), we complete the set of negative samples with randomly generated triples. For the nearest neighbor and near miss settings, we used the best performing model for initializing the parameters, and used the Rescal model tuned on typed negative samples (100 negative samples) as the negative sampling model for FB15K and Rescal trained by corrupting positive samples (100 negative samples) for WN18. 5.2 Test data The test data is the same across all experiments. The negative instances for the test data were generated as described in [4] – corrupting positive instances using all entities of the dictionary instead of the correct source and target, without sampling. Also following the procedure of [4], we use the filtered setting: the negative samples added to the training data are filtered with respect to the test data to avoid (known) false negatives in training. 5.3 Evaluation metrics For evaluation we use the mean reciprocal rank (MRR) and hits@K that are commonly used for link prediction. For a list of N answers for link prediction, the mean reciprocal rank (MRR) and hits@k are defined as: N Í | {i |r ank i <K } | 1 MRR = N1 hits@K = N r ank i i=1 where ranki is the rank of the positive instance i predicted by the model with respect to the negative samples. For FB15k we use hits@10, for WN18, hits@1. 4 https://github.com/bhushank/kge-rl Bhushan Kotnis and Vivi Nastase 5.4 Results We present the results of link prediction on FB15k and WN18 in terms of MRR in Figures 3 and 4 for ns ∈ {1, 2, 5, 10, 20, 50, 100} for each positive instance. The results show that the different sampling methods have different effects on the two datasets. Since link prediction is based exclusively on the embedding of the graphs, differences in performance are caused by the different structure (e.g. different node degrees which are reflected in the sparsity of the relation adjacency matrices) and the different nature of the relations – typed and extrinsic in FB15k, not typed and (mostly) intrinsic in WordNet. As suggested by work on learning statistical models through noise contrastive estimation [11], selecting difficult negative instances produces better models: near miss sampling leads to better results on FB15k for most embeddings methods. The reason embedding based sampling works well on FreeBase is primarily because the negative samples generated by the pre-trained embedding model are very close to the discriminator boundary. For example, the near miss sampling involves generating negative target entities that are highly ranked by the embedding model. These entities are likely to be highly ranked by the model that is being trained. Therefore providing these entities as negatives allows the system to learn a model that ranks them below the positive target using the max-margin loss. Note that the samples generated by the embedding model are close to each other in vector space due to the ability of the embedding model to cluster entities. Therefore almost all the generated negative samples are close to the discriminator boundary. We treated the negative sampling model (pre-trained model) as a hyper parameter. We found that the RESCAL model worked best. We speculate that this might be due to the superior ability of RESCAL model to cluster similar entities. Corrupting positive instances, the method most frequently used for link prediction, is the least competitive on FB15k, but fits WordNet well, particularly for Rescal . DistMult is not very sensitive to the type of negative sampling on WN18, except for the nearest neighbor method with which it does not perform well. To understand why corrupting positive instances works best on WordNet, we look at the data and the graph statistics. The WN18 dataset has 18 relations while with FB15k has about 1495 relations. Due to per relation data sparsity in FB15K, see Fig. 1 and 2, negative sampling using corrupted triples works poorly for FB15K, as it often has to fall back on random sampling when not enough positive instances with a shared source/target are available for ”corruption”. Corrupt sampling works better in an instance rich environment. Apart from data sparsity, the nature of WordNet and Freebase relations may also affect the performance of negative sampling methods. WordNet relations have open ended ranges and domains while Freebase relations have typed ranges and domains. Embedding based methods, such as the near miss sampling method we implemented, work on the basis of clustering similar entities, and do not function well for WordNet where the relations do not have domains and ranges that reflect conceptual/semantic clusters. We have discussed the differences in performance of sampling methods for the two KGs used. There are also differences with respect to the link prediction methods. Random sampling works best for TransE. This may be surprising at first, but is understandable Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 0 10 KBCOM’18, Feb 2018, Los Angeles, California USA complex MRR distmult MRR rescal MRR transE MRR complex hits@10 distmult hits@10 rescal hits@10 transE hits@10 10 1 corrupt 10 2 10 0 nmiss 10 1 nn 10 2 10 0 random 10 1 10 2 relational 10 1 10 0 typed 10 2 Figure 3: Link prediction on FB15k, evaluated in terms of MRR for ns ∈ {1, 2, 5, 10, 20, 50, 100} on a logarithmic scale. 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 0 10 complex MRR distmult MRR rescal MRR transE MRR complex hits@1 distmult hits@1 rescal hits@1 transE hits@1 10 1 10 2 10 0 corrupt 10 1 nmiss 10 2 10 0 nn 10 1 random 10 2 10 0 relational 10 1 10 2 Figure 4: Link prediction on WN18, evaluated in terms of MRR for ns ∈ {1, 2, 5, 10, 20, 50, 100} on a logarithmic scale. considering that the theoretical model behind TransE assumes 1 : 1 relations. Providing it with negative entities that are close (using typed, corrupted or embedding methods) does not result in improvement because the negative entities generated using typed, corrupt or embeddings are close to each other in vector space and the model will ultimately be unable to distinguish between them. This is not the case when doing random sampling, when TransE is not perturbed by too close negatives. ComplEx and DistMult perform well with both near miss and nearest neighbour sampling on FB15k. Rescal performs best with near miss sampling on this data, and with corrupting positive samples for WordNet. For middle-range ns relational sampling performs best. As described in Section 4, the training data for both methods varies quite a bit in terms of the frequency of the relations covered. Freebase is more extreme, in that approximately 39% of the relations have at most 10 positive instances to train on. We analyzed the effects of negative sampling on different slices of the data, split by the order of magnitude (oom) of the frequency of the relations in the training data. More precisely, we group relations into sets G n indexed by the order of magnitude n: G n = {r |10n < f req(n, training data) <= 10(n+1) }5 . Freebase has 5 slices (0..4) and WordNet 4 (1..4). The results (as MRR and hits@K) for slices representing relations with OOM 2 or more closely mirror the overall results. The results for the low frequency relations are shown in Figures 5 and 6.The hits@K score are similar to the MRR ones, so we do not include them6 . While the results on the low frequency relations cannot be analyzed separately from the other relations because the embeddings process relies on processing and inducing jointly all relation and 5 We 6 The include relations that have only one instance in G 0 . complete set of plots accompanies the code and will be shared. Yang et al. [29] MRR HITS@10 Negative sampling neg. sampling MRR HITS@10 FB15k DistMult 0.35 57.7 near miss 0.46 70.64 Rescal 0.31 51.9 near miss 0.42 64.34 0.32 53.9 near miss 0.37 62.97 TransE WN18 DistMult 0.83 94.2 corrupt 0.82 94.06 0.89 92.8 corrupt 0.92 93.91 Rescal TransE 0.38 90.9 corrupt 0.40 86.98 Table 4: SotA results using a max-margin loss function and corrupting positive instances vs. the best performing negative sampling. entity representations, we can note that the performance on link prediction for these relations with very few instances varies much with the negative sampling method. Overall, the best results are obtained with the same sampling method as for their more populous counterparts, but for specific ranges of the number of generated negative samples other methods would work best (e.g. nearest neighbor and relational sampling for WordNet data). The reported experiments were performed using the max margin loss function. In Table 4 we include the state of the art results on DistMult, Rescal and TransE obtained with a max margin loss function reported in [29] and corrupting tripes, to compare with the results obtained with the best negative sampling method for the dataset. Slight differences in the learning rate and λ account for the differences in performance when using corrupt positive instances as negative samples for the WN18 dataset. Recently, [27] used the log-likelihood objective, which leads to improvements over the published results for the methods they KBCOM’18, Feb 2018, Los Angeles, California USA corrupt nmiss nn random complex 0.60 0.55 0.50 0.45 0.40 0.35 0.30 0.25 0.20 0.60 0.55 0.50 0.45 0.40 0.35 0.30 0.25 0.20 distmult 0.6 0.5 0.4 0.3 0.2 0.1 0.6 0.5 0.4 0.3 0.2 0.1 rescal 0.6 0.5 0.4 0.3 0.2 0.1 0.6 0.5 0.4 0.3 0.2 0.1 0.0 0 10 0.6 0.5 0.4 0.3 0.2 0.1 transE 10 1 10 2 0.6 0.5 0.4 0.3 0.2 0.1 0.0 0 10 Bhushan Kotnis and Vivi Nastase relational typed complex distmult rescal transE 10 1 Figure 5: Results on relations with OOM 0 and 1 in FB15k (MRRs) compared (TransE, ComplEx, HolE, DistMult). We plan to analyze the negative sampling methods while using this new loss function. 6 CONCLUSION We report an analysis of the impact of six negative sampling methods on the performance of link prediction in knowledge graphs, for four methods for graph embedding – ComplEx, DistMult, Rescal , TransE. The analysis is performed with respect to two datasets – a subset of Freebase (FB15k) and a subset of WordNet (WN18) – that are very different in the type of knowledge they cover. The results indicate that different approaches to negative sampling work best for the two resources. The proposed near miss corrupt nmiss 1.0 0.8 0.6 0.4 0.2 1.1 1.0 0.9 0.8 0.7 0.6 1.0 0.8 0.6 0.4 0.2 0.6 0.5 0.4 0.3 0.2 0.1 0.0 10 2 10 0 nn random complex 1.0 0.8 0.6 0.4 0.2 distmult 1.1 1.0 0.9 0.8 0.7 0.6 rescal 1.0 0.8 0.6 0.4 0.2 transE 10 1 10 2 0.6 0.5 0.4 0.3 0.2 0.1 0.0 0 10 relational complex distmult rescal transE 10 1 Figure 6: Results on relations with OOM 1 and 2 in WN18 (MRRs) sampling worked best for Freebase with most of the graph embedding methods, while corrupting positive triples leads to best results on WordNet. The newly proposed near miss and nearest neighbor negative sampling work best for Freebase, for three out of the four graph embeddings methods. From analysis of datasets, we further concluded that embedding based negative sampling is very useful for combating data sparsity, while corrupt sampling works best in the data rich scenario. The nature of the relations in these graphs (typed with respect to their domain and range vs. open) as well as the statistics of the knowledge graph (number of positive instances per relation) explain the different behaviour with respect to negative sampling. 10 2 Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs REFERENCES [1] Yoshua Bengio and Jean-Sébastien Senécal. 2008. Adaptive importance sampling to accelerate training of a neural probabilistic language model. IEEE Transactions on Neural Networks 4, 19 (2008), 713–722. [2] James Bergstra and Yoshua Bengio. 2012. Random Search for Hyper-parameter Optimization. J. Mach. Learn. Res. 13 (Feb. 2012), 281–305. http://dl.acm.org/ citation.cfm?id=2188385.2188395 [3] Kurt Bollacker, Colin Evans, Praveen Paritosh, Tim Sturge, and Jamie Taylor. 2008. Freebase: A Collaboratively Created Graph Database for Structuring Human Knowledge. In Proceedings of the 2008 ACM SIGMOD International Conference on Management of Data (SIGMOD ’08). ACM, New York, NY, USA, 1247–1250. https://doi.org/10.1145/1376616.1376746 [4] Antoine Bordes, Nicolas Usunier, Alberto Garcia-Duran, Jason Weston, and Oksana Yakhnenko. 2013. Translating Embeddings for Modeling Multirelational Data. In Advances in Neural Information Processing Systems 26, C. J. C. Burges, L. Bottou, M. Welling, Z. Ghahramani, and K. Q. Weinberger (Eds.). Curran Associates, Inc., 2787–2795. http://papers.nips.cc/paper/ 5071-translating-embeddings-for-modeling-multi-relational-data.pdf [5] Andrew Carlson, Justin Betteridge, Bryan Kisiel, Burr Settles, Estevam R. Hruschka, and Tom M. Mitchell. 2010. Toward an Architecture for Never-Ending Language Learning. In AAAI. [6] Rajarshi Das, Arvind Neelakantan, David Belanger, and Andrew McCallum. 2016. Chains of Reasoning over Entities, Relations, and Text using Recurrent Neural Networks. arXiv preprint arXiv:1607.01426 (2016). [7] Xin Dong, Evgeniy Gabrilovich, Geremy Heitz, Wilko Horn, Ni Lao, Kevin Murphy, Thomas Strohmann, Shaohua Sun, and Wei Zhang. 2014. Knowledge vault: a web-scale approach to probabilistic knowledge fusion. In KDD. [8] Xin Luna Dong, Evgeniy Gabrilovich, Kevin Murphy, Van Dang, Wilko Horn, Camillo Lugaresi, Shaohua Sun, and Wei Zhang. 2015. Knowledge-based Trust: Estimating the Trustworthiness of Web Sources. Proc. VLDB Endow. 8, 9 (May 2015), 938–949. https://doi.org/10.14778/2777598.2777603 [9] Matt Gardner and Tom Mitchell. 2015. Efficient and Expressive Knowledge Base Completion Using Subgraph Feature Extraction. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics, 1488–1498. https://doi.org/10.18653/v1/D15-1173 [10] Michael Gutmann and Aapo Hyvarinen. 2012. Noise-contrastive estimation of unnormalized statistical mod- els, with applications to natural image statistics. The Journal of Machine Learning Research 13 (2012), 307fi?!361. [11] Michael Gutmann and Aapo Hyvärinen. 2010. Noise-contrastive estimation: A new estimation principle for unnormalized statistical models. In Proceedings of the Thirteenth International Conference on Artificial Intelligence and Statistics. 297–304. [12] Kelvin Guu, John Miller, and Percy Liang. 2015. Traversing Knowledge Graphs in Vector Space. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics, 318–327. https://doi.org/10.18653/v1/D15-1038 [13] Diederik Kingma and Jimmy Ba. 2014. Adam: A method for stochastic optimization. arXiv preprint arXiv:1412.6980 (2014). [14] Yankai Lin, Zhiyuan Liu, Maosong Sun, Yang Liu, and Xuan Zhu. 2015. Learning Entity and Relation Embeddings for Knowledge Graph Completion. In Proceedings of the Twenty-Ninth AAAI Conference on Artificial Intelligence (AAAI’15). AAAI Press, 2181–2187. http://dl.acm.org/citation.cfm?id=2886521.2886624 [15] Alexander Miller, Adam Fisch, Jesse Dodge, Amir-Hossein Karimi, Antoine Bordes, and Jason Weston. 2016. Key-Value Memory Networks for Directly Reading Documents. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics, 1400– 1409. http://aclweb.org/anthology/D16-1147 [16] Andriy Mnih and Yee Whye Teh. 2012. A fast and simple algorithm for training neural probabilistic language models. In Proc. of ICML. [17] M. Moya, M. Koch, and L Hostetler. 1993. One-class classifier networks for target recognition applications. In Proc. of the World Congress on Neural Networks. International Neural Network Society, INNS, Portland, OR., 797fi?!801. [18] Arvind Neelakantan, Benjamin Roth, and Andrew McCallum. 2015. Compositional Vector Space Models for Knowledge Base Completion. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 1: Long Papers). Association for Computational Linguistics, 156–166. https://doi.org/10.3115/v1/P15-1016 [19] M. Nickel, K. Murphy, V. Tresp, and E. Gabrilovich. 2016. A Review of Relational Machine Learning for Knowledge Graphs. Proc. IEEE 104, 1 (Jan 2016), 11–33. https://doi.org/10.1109/JPROC.2015.2483592 [20] Maximilian Nickel, Lorenzo Rosasco, and Tomaso Poggio. 2016. Holographic Embeddings of Knowledge Graphs. In Proceedings of the Thirtieth AAAI Conference on Artificial Intelligence (AAAI’16). AAAI Press, 1955–1961. http://dl.acm. org/citation.cfm?id=3016100.3016172 [21] Maximilian Nickel, Volker Tresp, and Hans-Peter Kriegel. 2011. A Three-Way Model for Collective Learning on Multi-Relational Data. In ICML. KBCOM’18, Feb 2018, Los Angeles, California USA [22] Maximilian Nickel, Volker Tresp, and Hans-Peter Kriegel. 2012. Factorizing YAGO: Scalable Machine Learning for Linked Data. In Proceedings of the 21st International Conference on World Wide Web (WWW ’12). ACM, New York, NY, USA, 271–280. https://doi.org/10.1145/2187836.2187874 [23] Noah A Smith and Jason Eisner. 2005. Contrastive estimation: Training loglinear models on unlabeled data. In Proceedings of the 43rd Annual Meeting on Association for Computational Linguistics. Association for Computational Linguistics, 354–362. [24] Richard Socher, Danqi Chen, Christopher D Manning, and Andrew Ng. 2013. Reasoning With Neural Tensor Networks for Knowledge Base Completion. In Advances in Neural Information Processing Systems 26, C. J. C. Burges, L. Bottou, M. Welling, Z. Ghahramani, and K. Q. Weinberger (Eds.). Curran Associates, Inc., 926–934. http://papers.nips.cc/paper/ 5028-reasoning-with-neural-tensor-networks-for-knowledge-base-completion. pdf [25] Fabian M. Suchanek, Gjergji Kasneci, and Gerhard Weikum. 2007. YAGO: A Core of Semantic Knowledge. In Proceedings of the 16th International Conference on World Wide Web (WWW ’07). ACM, New York, NY, USA, 697–706. https: //doi.org/10.1145/1242572.1242667 [26] Kristina Toutanova, Victoria Lin, Wen-tau Yih, Hoifung Poon, and Chris Quirk. 2016. Compositional Learning of Embeddings for Relation Paths in Knowledge Base and Text. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers). Association for Computational Linguistics, 1434–1444. https://doi.org/10.18653/v1/P16-1136 [27] Théo Trouillon, Christopher R Dance, Johannes Welbl, Sebastian Riedel, Éric Gaussier, and Guillaume Bouchard. 2017. Knowledge Graph Completion via Complex Tensor Factorization. arXiv preprint arXiv:1702.06879 (2017). [28] Robert West, Evgeniy Gabrilovich, Kevin Murphy, Shaohua Sun, Rahul Gupta, and Dekang Lin. 2014. Knowledge Base Completion via Search-based Question Answering. In Proceedings of the 23rd International Conference on World Wide Web (WWW ’14). ACM, New York, NY, USA, 515–526. https://doi.org/10.1145/ 2566486.2568032 [29] Bishan Yang, Wen-tau Yih, Xiaodong He, Jianfeng Gao, and Li Deng. 2015. Embedding entities and relations for learning and inference in knowledge bases. In Proceedings of the 2015 International Conference on Representation Learning. KBCOM’18, Feb 2018, Los Angeles, California USA Bhushan Kotnis and Vivi Nastase Performance analysis on Freebase (FB15k). 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 0 10 complex MRR distmult MRR rescal MRR transE MRR complex hits@10 distmult hits@10 rescal hits@10 transE hits@10 10 1 corrupt 10 2 10 0 nmiss 10 1 nn 10 2 10 0 random 10 1 10 1 10 2 10 0 relational typed 10 2 Figure 7: Performance on FB15k in terms of MRR and Hits@10 Performance analysis on WordNet (WN18). 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 0 10 complex MRR distmult MRR rescal MRR transE MRR complex hits@1 distmult hits@1 rescal hits@1 transE hits@1 10 1 10 2 10 0 corrupt 10 1 nmiss 10 2 10 0 nn 10 1 random 10 2 10 0 Figure 8: Performance on WN18 in terms of MRR and Hits@1 relational 10 1 10 2 1.0 0.8 0.6 0.4 0.2 0.0 0 10 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 rescal -- oom 0.0 transE -- oom 0.0 10 1 rescal transE 10 1 corrupt distmult -- oom 0.0 distmult 10 2 10 0 complex -- oom 0.0 complex 10 2 10 0 nmiss 10 1 nn transE -- oom 1.0 rescal -- oom 1.0 distmult -- oom 1.0 complex -- oom 1.0 random 10 2 10 0 10 1 10 2 10 0 relational transE -- oom 2.0 rescal -- oom 2.0 distmult -- oom 2.0 complex -- oom 2.0 10 1 typed transE -- oom 3.0 rescal -- oom 3.0 distmult -- oom 3.0 complex -- oom 3.0 10 2 10 0 10 1 transE -- oom 4.0 rescal -- oom 4.0 distmult -- oom 4.0 complex -- oom 4.0 10 2 Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs KBCOM’18, Feb 2018, Los Angeles, California USA Figure 9: Performance on FB15k in terms of MRR for relations with different orders of magnitude 1.0 0.8 0.6 0.4 0.2 0.0 0 10 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 rescal -- oom 0.0 transE -- oom 0.0 10 1 rescal transE 10 1 corrupt distmult -- oom 0.0 distmult 10 2 10 0 complex -- oom 0.0 complex 10 2 10 0 nmiss 10 1 nn transE -- oom 1.0 rescal -- oom 1.0 distmult -- oom 1.0 complex -- oom 1.0 random 10 2 10 0 10 1 10 2 10 0 relational transE -- oom 2.0 rescal -- oom 2.0 distmult -- oom 2.0 complex -- oom 2.0 10 1 typed transE -- oom 3.0 rescal -- oom 3.0 distmult -- oom 3.0 complex -- oom 3.0 10 2 10 0 10 1 transE -- oom 4.0 rescal -- oom 4.0 distmult -- oom 4.0 complex -- oom 4.0 10 2 KBCOM’18, Feb 2018, Los Angeles, California USA Bhushan Kotnis and Vivi Nastase Figure 10: Performance on FB15k in terms of Hits@10 for relations with different orders of magnitude 1.0 0.8 0.6 0.4 0.2 0.0 0 10 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 rescal -- oom 1.0 transE -- oom 1.0 10 1 rescal transE 10 1 corrupt distmult -- oom 1.0 distmult 10 2 10 0 complex -- oom 1.0 complex nmiss 10 2 10 0 nn 10 1 transE -- oom 2.0 rescal -- oom 2.0 distmult -- oom 2.0 complex -- oom 2.0 random 10 2 10 0 relational 10 1 transE -- oom 3.0 rescal -- oom 3.0 distmult -- oom 3.0 complex -- oom 3.0 10 2 10 0 10 1 transE -- oom 4.0 rescal -- oom 4.0 distmult -- oom 4.0 complex -- oom 4.0 10 2 Analysis of the Impact of Negative Sampling on Link Prediction in Knowledge Graphs KBCOM’18, Feb 2018, Los Angeles, California USA Figure 11: Performance on WN18 in terms of MRR for relations with different orders of magnitude 1.0 0.8 0.6 0.4 0.2 0.0 0 10 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 1.0 0.8 0.6 0.4 0.2 0.0 rescal -- oom 1.0 transE -- oom 1.0 10 1 rescal transE 10 1 corrupt distmult -- oom 1.0 distmult 10 2 10 0 complex -- oom 1.0 complex nmiss 10 2 10 0 nn 10 1 transE -- oom 2.0 rescal -- oom 2.0 distmult -- oom 2.0 complex -- oom 2.0 random 10 2 10 0 relational 10 1 transE -- oom 3.0 rescal -- oom 3.0 distmult -- oom 3.0 complex -- oom 3.0 10 2 10 0 10 1 transE -- oom 4.0 rescal -- oom 4.0 distmult -- oom 4.0 complex -- oom 4.0 10 2 KBCOM’18, Feb 2018, Los Angeles, California USA Bhushan Kotnis and Vivi Nastase Figure 12: Performance on WN18 in terms of Hits@1 for relations with different orders of magnitude
2cs.AI