The following two lemmas will be used in the remaining discussions.
Lemma 8 If a, m, b, n are integers, not all zero, such that am − bn = 1, then gcd(a, n) = 1.
Proof. Assume that am − bn = 1 and gcd(a, n) = k. Then k | a and k | n. Thus k | am − bn = 1. So k = 1.
Lemma 9 If m and n are integers, not both zero, and gcd(m, n) = 1, then there exist integers a and b such that am − bn = 1 and gcd(a, 2m + n) = 1.
Proof. By Lemma 3, there exist integers a and b such that am − bn = 1. By Lemma 8, we have
gcd(a, n) = 1.
(4.9)
If gcd(a, 2m + n) = 1, then we are done. In the following, assume that gcd(a, 2m + n) = d > 1. Let
a = pd and
2m + n = qd.
Then gcd(p, q) = 1. Since gcd(m, n) = 1, we have gcd(2m + n, n) = gcd(2m, n) =
½ 1 if n is odd, 2 if n is even.
If gcd(2m + n, n) = 1, then clearly gcd(qd, n) = 1 and thus gcd(d, n) = 1. Now suppose that gcd(2m + n, n) = 2. Then gcd(qd, n) = 2; therefore gcd(d, n) = 1 or gcd(d, n) = 2. If gcd(d, n) = 2, then 2 | a and we have gcd(a, n) ≥ 2; this contradicts with(4.9). From the above, we have
gcd(d, n) = 1.
(4.10)
Let q = st, where s is the largest factor of q such that gcd(s, d) = 1.
(4.11)
That is, s (t) contains those prime factors of q that are relative prime (not relative prime) to d. (As an example, if q = 22·32·7 and d = 2·32, then s = 7 and t = 22·32.) Then
gcd(s, t) = 1.
(4.12)
Since gcd(p, q) = 1 and q = st, we have
gcd(p, s) = 1.
(4.13)
Since t contains those prime factors of q that are not relative prime to d, by (4.10), we have
gcd(t, n) = 1.
(4.14)
Let a0 = a + sn and b0 = b + sm. Then
a0m − b0n = (a + sn)m − (a + sm)n = am − bn = 1.
Moreover,
gcd(a0, 2m + n)
= gcd(a + sn, 2m + m)
= gcd(pd + sn, qd)
= gcd(pd + sn, q) (by (4.10) and (4.11))
= gcd(pd + sn, st)
= gcd(pd + sn, s) (by (4.12) and (4.14))
= 1 (by (4.11) and (4.13)).
Thus we have this lemma.
Let HL1(h, m, n) denote a hyper-L1 tile with parameters h, m, n. Aguil´o-Gost [1] defined
M1(h, m, n) =
n −m −m
n n + m −m
2h h 2h − n
and derived that the diameter of HL1(h, m, n) is given by
D(h, m, n) = max{3m + h + n, 2m + 2h + n, 3h + 3n} − 3.
(4.15)
Note that two sides labelled length n in Figure 5 in [1] are actually of length m − n; see Figure 5 This flaw can be verified by checking the lengths of the sides
of the topmost n × n square and the lengths of the sides of the rightmost m × h rectangle. See Figure 4 for a correction of Figure 5.
Thus matrix M1 should be
M1(h, m, n) =
n −m −m
n n + m −m
2h h h + m − n
and the diameter of HL1(h, m, n) should be
D(h, m, n) = max{3m + h + n, 2m + 2h + n, (4.16)
3h + 3n, m + 2h + 3n} − 3.
Figure 5: The Fig. 5 in [1].
Note that the difference between the diameters derived by (4.15) and by (4.16) can be quite large. To see this, let
h = 2t − 1 − k m = 2t − 1
n = t + k,
where t and k are positive integers chosen in such a way that both gcd(m, n) = 1 and 3 - m − n are satisfied. Then the diameter derived by (4.15) is 9t − 6, while the
diameter derived by (4.16) is 9t − 6 + k. The difference between the two diameters is k. As an example, when k = 5, we can choose t = 10, h = 14, m = 19, and n = 15.
Aguil´o-Gost [1] observed that HL1(h, m, n) tessellates the space. By studying the distribution of node 0 in the space, Aguil´o-Gost obtained
MT ×
For convenience, we call a triple-loop network whose MDD is HL1(h, m, n) an HL1(h, m, n) triple-loop. We now give a necessary and sufficient condition for the existence of an HL1(h, m, n) triple-loop.
Theorem 10 A necessary and sufficient condition for the existence of an HL1(h, m, n) triple-loop is gcd(m, n) = 1 and 3 - m − n.
Proof. Note that N = det M. Suppose an HL1(h, m, n) triple-loop exists. From (4.17), we have
Since gcd(m, n) = 1, 3 - m − n, and gcd(m − n, m) = 1,
Note that
gcd(k1(2m + n) + φ(a)a(m − n)(m + n), k2(2m + n) + φ(a)am(m − n), 2m + n)
= gcd(a(m − n)(m + n), am(m − n), 2m + n)
= gcd(an(m − n), am(m − n), 2m + n)
= gcd(n(m − n), m(m − n), 2m + n) (by the fact that gcd(a, 2m + n) = 1)
= gcd(n, m, 2m + n) (by (4.18))
= gcd(m, n)
= 1.
So if gcd(m, n) = 1 and 3 - m − n, then clearly
gcd(N, s1, s2, s3) = gcd(s1, s2, s3) = 1 and T L(N; s1, s2, s3) exists.
On the other hand, suppose
gcd(m, n) = d > 1 or 3 | m − n.
In the former case, each si, i = 1, 2, 3, is a linear combination of terms divisible by d. Furthermore, from (4.19), N is also a linear combination of terms divisible by d.
Hence
gcd(N, s1, s2, s3) ≥ d > 1
and T L(N; s1, s2, s3) does not exist. In the latter case, since 3 | m − n, we have gcd(2m + n, m − n) = gcd(3m, m − n) = r ≥ 3.
Therefore each si, i = 1, 2, 3, is a linear combination of terms divisible by r. Fur-thermore, from (4.19), N is also a linear combination of terms divisible by r. Hence
gcd(N, s1, s2, s3) ≥ r > 1 and T L(N; s1, s2, s3) does not exist.
References
[1] F. Aguil´o-Gost, New dense families of triple loop networks, Disc. Math. 197/198 (1999) 15-27.
[2] F. Aguil´o and M. A. Fiol, An efficient algorithm to find optimal double loop networks, Disc. Math. 138 (1995), 15-29.
[3] F. Aguil´o, M. A. Fiol and C. Garcia, Triple-loop networks with small transmis-sion delay, Disc. Math. 167/168 (1997) 3-16.
[4] J.-C. Bermond, F. Comellas and D. F. Hsu, Distributed loop computer net-works: a survey, J. Parallel Distribut. Comput. 24 (1995), 2-10.
[5] R. C. Chan, C. Y. Chen and Z. X. Hong, A simple algorithm to find the steps of double-loop networks, Disc. Appl. Math. 121 (2002), 61-72.
[6] C. Y. Chen and F. K. Hwang, The minimum distance diagram of double-loop networks, IEEE Trans. Comput. 49 (2000), 977-979.
[7] C. Y. Chen, F. K. Hwang, J. S. Lee and S. J. Shih, The existence of hyper-L triple-loop networks, Disc. Math. 268 (2003) 287-291.
[8] Y. Cheng and F. K. Hwang, Diameters of weighted double loop networks, J.
Algorithms 9 (1988), 401-410.
[9] T. H. Cormen, C. E. Leiserson, R. L. Rivest, and C. Stein, Introduction to Algorithms, 2nd Ed. (2001), The MIT Press, 856-862.
[10] P. Erd¨os and D. F. Hsu, Distributed loop networks with minimum transmission delay, Theoret. Comput. Sci. 100 (1992), 223-241.
[11] P. Esqu´e, F. Aguil´o, and M. A. Fiol, Double commutative-step diagraphs with minimum diameters, Disc. Math. 114 (1993), 147-157.
[12] M. A. Fiol, M. Valero, J. L. A. Yebra, I. Alegre, and T. Lang, Optimization of double-loop structures for local networks, in Proc. XIX Int. Symp. MIMI’82, Paris, France (1982), 37-41.
[13] M. A. Fiol, J. L. A. Yebra, I. Alegre, and M. Valero, A discrete optimization problem in local networks and data alignment, IEEE Trans. Comput. C-36 (1987), 702-713.
[14] F. K. Hwang, A survey on double-loop networks, Reliability of Computer and Communication Networks, Eds: F. Roberts, F. K. Hwang and C. Monma, AMS series (1991), 143-151.
[15] F. K. Hwang, A complementary survey on double-loop networks, Theoret. Com-put. Sci. A 263 (2001), 211-229.
[16] F. K. Hwang, A survey on multi-loop networks, Theoret. Comput. Sci. A 299 (2003), 107-121.
[17] F. K. Hwang and Y. H. Xu, Double loop networks with minimum delay, Disc.
Math. 66 (1987), 109-118.
[18] J. M. Peha and F. A. Tobagi, Analyzing the fault tolerance of double-loop networks, IEEE Trans. Network. 2 (1994), 363-373.
[19] C. K. Wong and D. Coppersmith, A combinatorial problem related to multi-module memory organizations, J. Assoc. Comput. Mach. 21 (1974), 392-402.
Appendix
Theorem 11 [5] The CCH algorithm is correct and it takes at most O((log N)2) time.
Consider column 1 of M: it contains l and −n. After Step 1 is performed, we have r1 = gcd(l, −n) and α1l + β1(−n) = r1. Let
That is, unimodular integral matrices. Let L = L1L2. Then
L =
It is clear that Steps 1, 2, and 3 can be done in O(log N) time by using the Eu-clidean algorithm. Step 4 can be done in O((log N)2) time by using ALGORITHM-MODIFIED-EUCLIDEAN. Step 5 can be done in O(1) time. Thus the CCH algo-rithm takes at most O((log N)2).