Academia.eduAcademia.edu

Explorations of the Collatz Conjecture (mod m)

2014

The Collatz Conjecture is a deceptively difficult problem recently developed in mathematics. In full, the conjecture states: Begin with any positive integer and generate a sequence as follows: If a number is even, divide it by two. Else, multiply by three and add one. Repetition of this process will eventually reach the value 1. Proof or disproof of this seemingly simple conjecture have remained elusive. However, it is known that if the generated Collatz Sequence reaches a cycle other than 4, 2, 1, the conjecture is disproven. This fact has motivated our search for occurrences of 4, 2, 1, and other cycles in a Collatz Sequence mod m.

Georgia Southern University Digital Commons@Georgia Southern University Honors Program Theses 2014 Explorations of the Collatz Conjecture (mod m) Glenn Micah Jackson Jr Georgia Southern University Follow this and additional works at: https://digitalcommons.georgiasouthern.edu/honors-theses Part of the Number Theory Commons Recommended Citation Jackson, Glenn Micah Jr, "Explorations of the Collatz Conjecture (mod m)" (2014). University Honors Program Theses. 70. https://digitalcommons.georgiasouthern.edu/honors-theses/70 This thesis (open access) is brought to you for free and open access by Digital Commons@Georgia Southern. It has been accepted for inclusion in University Honors Program Theses by an authorized administrator of Digital Commons@Georgia Southern. For more information, please contact [email protected]. Explorations of the Collatz Conjecture (mod m) An Honors Thesis submitted in partial fulfillment of the requirements for Honors in Mathematics. By Micah Jackson With the mentorship of Dr. David Stone ABSTRACT The Collatz Conjecture is a deceptively difficult problem recently developed in mathematics. In full, the conjecture states: Begin with any positive integer and generate a sequence as follows: If a number is even, divide it by two. Else, multiply by three and add one. Repetition of this process will eventually reach the value 1. Proof or disproof of this seemingly simple conjecture have remained elusive. However, it is known that if the generated Collatz Sequence reaches a cycle other than 4, 2, 1, the conjecture is disproven. This fact has motivated our search for occurrences of 4, 2, 1, and other cycles in a Collatz Sequence mod m. Thesis Mentor: Dr. David Stone Honors Director: Dr. Steven Engel November 3, 2014 Department of Mathematics University Honors Program Georgia Southern University Acknowledgements The following presented work would not be possible if it were not for the efforts of several to guide me along in this process. I am deeply grateful for the mentorship of Dr. David Stone. Without his guidance, this research may have never began. I must also thank the generous donors of several Georgia Southern University groups for aiding me in conference travel and research expenses. Without this opportunity, my work and growth as a student could never have come this far. Finally, to the numerous professors and colleagues that have given suggestions or critiques about this work, I must say thank you. Every idea is valuable in research. 2 Background The Collatz Conjectjure (also known as the 3x + 1 Problem, Hailstone Problem, Kakutani’s Conjecture, Ulam’s Conjecture, Hasse’s Algorithm, and the Syracuse Problem) is usually attributed to Lothar Collatz, an alumnus of the University of Hamburg. While at university, Collatz became interested in iterative graph representations of number-theoretic functions. Though never publishing any of these problems, Collatz is known to have circulated them with his colleagues at the International Congress of Mathematics in 1950. By the early 1950s, the Collatz Conjecture was not just an underground problem known by a select few professors, but it had become known to the math community. Bryan Thwaites, another mathematician that the Collatz Conjecture is occasionally named after, discovered the problem in 1952 and has since offered a £1000 prize for a proof. This offer follows from similar prizes: Harold S. M. Coxeter will provide $50 for a proof while Paul Erdős offers $500. However, prize money is only a secondary benefit that would come from a proof. A mathematician who can construct a proof of this conjecture will be known for solving a problem for which Erdős has said, “Mathematics is not yet ready for such problems.” The method of proof will most likely open up new areas of study as well since the Collatz Problem is tied to much more than just number theory or graphs. As seen in the results of Krager[1], the Collatz Conjecture lends itself to p-adic analysis, analysis where ”distance” is determined by the largest power of a given prime p dividing the difference between two rational numbers. The Collatz Function also shares connections to the Mersenne Primes, prime numbers of the form 2n − 1, with n a positive integer[3]. Suppose Mi is the ith Mersenne Prime, then Ohira and Watanabe have shown a strong correlation between the stopping time (number of iterations for the sequence to reach 1) of Mi and the index i. Another author, Riho Terras, has published results showing that the limit of the stopping time tends to 0 as the fixed initial value is increased[6]. These results were attained using techniques from the field of statistics. Whatever the eventual method of proof will be, it is clear that it will have deep implications and connections to various other areas of mathematics. Formulation of Problem The formal statement of the Collatz Conjecture begins with the Collatz Function, C(k), defined as follows: For a positive integer k, C(k) =  3k + 1, k/2, if k is odd if k is even Because the conjecture is focused on iterations of this function, let C 2 (k) = C(C(k)), C 3 (k) = C(C 2 (k)), so on and denote k as C 0 (k). Furthermore, the sequence generated, {C i (k)}ni=1 , will be known as the trajectory. Conjecture (Collatz Conjecture). Beginning with any positive integer k, there exists some n such that C n (k) = 1. Examples: (a) For k = 11. The trajectory of 11, or Traj(11) = 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1. (b) Traj(75) = 226, 113, 340, 170, 85, 256, 128, 64, 32, 16, 8, 4, 2, 1. (c) Traj(16384) = 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1.. (d) Traj(2j ) = 2j−1 , 2j−2 , . . . , 22 , 2, 1. 3 Since inception of this conjecture, the conclusion has been verified up to 258 , or roughly 5.8 × 10 [5]. However, progress towards a proof has not fared so well. In attempts to prove the Collatz Conjecture, researchers have examined various properties and measures of the Collatz Function. The most natural measure to look at would be the number of iterations needed for the sequence to reach 1. This is known as the stopping time. Note that this is the length of trajectory. Provided below are graphs mapping the integers k to their corresponding stopping times. 18 Figure 1: Stopping times up to n = 100 Figure 2: Stopping times up to n = 1000 Figure 3: Stopping times up to n = 10000 4 In Figures 1, 2, and 3, it appears that there are two distinct groupings of trajectories converging into one large periodic distribution. Unfortunately, periodicity and nice pictures do not prove the conjecture and we are left with another mystery of the Collatz Conjecture. Another characteristic of interest is the maximum value attained during the trajectory of k. Graphed below, in Figures 4, 5, 6, are integers k and their corresponding maximum trajectory value. Figure 4: Max values for integers up to n = 100 Figure 5: Max values for integers up to n = 1000 Figure 6: Max values for integers up to n = 10000 5 From these figures, it is easy to see that most integers reach similar max values with many of the integers actually reaching the same max values. As the magnitude of our initial integer increases, we also see that the number of integers with outlying max values increases. This is due to the intuitive fact that as the starting integer k increases, more divisions by two are necessary and multiplications by three are more likely. It is precisely because of this that some have chosen to examine somewhat maxj>0 C j (k) normalized max values, or the expansion factor. The expansion factor is defined as k for a fixed initial value k. The above results are then transformed into the following. Figure 7: Expansion factors for integers up to n = 100 Figure 8: Expansion factors for integers up to n = 1000 Figure 9: Expansion factors for integers up to n = 10000 6 From Figures 7, 8, and 9, one can point out that there appears to be a type of exponentially decreasing pattern as k increases. However, as we expand our interval, this characteristic becomes less pronounced and leaves us in the dark once more. Next, one can look at the shape of the actual trajectories for given k. Examples are given in Figures 10, 11, 12 below. Figure 10: Trajectory of 42 Figure 11: Trajectory of 103 Figure 12: Trajectory of 27 7 Finally, we can (and will) examine these trajectories when reduced by a modulus m. A priori, one might suspect that the graphs will now have simpler looking results since the range of values that our function can obtain has been reduced to m choices. Unfortunately, Figures 13, 14, and 15 below show this is not the case. The following graphs are even more chaotic-appearing than the original. Figure 13: Trajectory of 27 mod 5 Figure 14: Trajectory of 27 mod 11 Figure 15: Trajectory of 27 mod 42 8 Note here that the residue trajectory can not be computed in mod m, but one must determine the original Collatz sequence before reducing it. Also, one can bring some order to the turbulent nature of these sequences. Now, we restate the Collatz Conjecture as the equivalent: Conjecture (Collatz Conjecture). Given any positive integer k, the sequence generated by iterations of the Collatz Function will eventually reach and remain in the cycle 4, 2, 1. This is the definition that has motivated the present paper’s focus. We have examined Collatz sequences reduced by modulus m > 4 and corresponding occurrences of the sequence 4, 2, 1. If a Collatz Sequence eventually cycles 4, 2, 1, then the sequence mod m will also reach the cycle. Thus, if it is shown that a reduced Collatz Sequence does not reach 4, 2, 1, then the original sequence will not reach the cycle and the conjecture is disproven. Additionally, if a Collatz Sequence reaches a cycle other than 4, 2, 1, the conjecture is disproven. For this reason, we have examined conditions under which a reduced Collatz Sequence will reach a cycle other than 4, 2, 1. Congruence mod m Congruence of integers is a concept developed by Gauss in his classic work, Disquisitiones Arithmeticae, published in 1801. For a fixed positive integer m, known as the modulus, we say that two integers a and b are congruent mod m if they leave the same remainder upon division by m. We denote this by a ≡ b mod m. For instance, 32 ≡ 7 mod 5 because each leaves a remainder of 2 when divided by 5. Any integer n is congruent mod m to a unique integer in the list 0, 1, 2, . . . , m − 1. This integer is known as the residue of n mod m. For example, if we let m = 10, then the residue of 47 mod 10 is 7 since 47 divided by 10 leaves a remainder of 7. Thus, 47 ≡ 7 mod 10. In particular, n ≡ 0 mod m is equivalent to saying that m is a divisor of n. For instance, n ≡ 0 mod 2 if and only if n is even. Congruence is very similar to the = relation. They are both equivalence relations on the integers and make it possible to establish and use properties of divisibility in an algebraic fashion. A more rigorous introduction to modular arithmetic and congruences is given in [4]. Results Result 1. We are first interested in the case of 4, 2, 1 occurring in the reduced trajectories before the cycle appears in the original trajectory. Let ai = 4 + s0 m, ai+1 = 2 + s1 m, and ai+2 = 1 + s2 m, so that ai , ai+1 , ai+2 ≡ 4, 2, 1 mod m. Moreover, if ai , ai+1 are even and ai+2 is odd, then ai , ai+1 , ai+2 ≡ 0, 0, 1 mod 2. Then we have the following result: ai mod 2 0,0,0 0,0,1 0,1,0 1,0,0 1,0,1 m odd s0 ≡ 0 mod 8 s0 ≡ 4 mod 8 Not Possible s0 ≡ 3 mod 4, m = 11 s0 ≡ 1 mod 4, m = 11 m even Not Possible s0 ≡ 1 mod 2 Not Possible Not Possible Not Possible Example: Suppose we wish to generate a trajectory that is congruent to 4, 2, 1 when reduced by a modulus m and this sequence consists of an odd number followed by two evens. This corresponds to the fourth row. From here, we can see that if our modulus is odd, then s0 ≡ 3 mod 4 and specifically, m = 11. However, if m is even, this case is not possible. Suppose ai = 4 + s0 m is odd and m is even. Then ai ≡ (0 mod 2) + s0 (0 mod 2) ≡ 0 mod 2, a contradiction. Example: Let ai = 81 = 4 + (7)(11). Then Traj(81) = 244, 122, 61, . . . , so ai , ai+1 , ai+2 , ai+3 ≡ 4, 2, 1, 6 mod 11. 9 Result 2. To generate a repeating sequence of 4, 2, 1, begin with any integer 23k and reduce the sequence by m = 7. Example: Traj(23(5) ) = Traj(32768) = 16384, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1. Traj(32768) mod 7 = 4, 2, 1, 4, 2, 1, 4, 2, 1, 4, 2, 1, 4, 2, 1 That is, the residue trajectory reduces mod 7 immediately to 4, 2, 1, even though the original sequence does not. Theorem 1. If ai is even and ai ≡ ai+1 mod m, then ai ≡ 0 ≡ ai+1 mod m. Theorem 2. If ai is odd, then ai ≡ ai+1 mod m iff m is odd and ai ≡ −2−1 mod m. Moreover, if m = 2t + 1, then, (i) If m≡ 1 mod 4, then ai ≡ t + m mod 2m (ii) If m≡ 3 mod 4, then ai ≡ t mod 2m Examples: (a) Let m = 9. Then t = 4 and m ≡ 1 mod 4. Suppose ai = 49 which implies ai+1 = 148 which are both ≡ 4 mod 9. Also, ai ≡ t + m mod 2m because 49 ≡ 13 mod 18. (b) Let m = 7. Then t = 3 and m ≡ 3 mod 4. Suppose ai = 17 which implies ai+1 = 52 which are both ≡ 3 mod 7. Additionally, ai ≡ t mod 2m because 17 ≡ 3 mod 14. Theorem 3. Suppose ai , ai+1 , ai+2 ≡ a, b, a mod m with a, b ∈ Z and a 6= b. Then, (i) If ai is odd, then a ≡ −1 mod m and b ≡ −2 mod m. (ii) If ai is even and ai+1 is odd, then a ≡ −2 mod m and b ≡ −1 mod m provided gcd(m, 2) = 1. (iii) If ai and ai+1 are even, it must be that a ≡ b ≡ 0 which contradicts our assumption that a 6≡ b, so this can not occur. Examples: (a) Let ai = 63 which is ≡ −1 mod 32. Traj(63) = 190, 95, 286, 143, . . . ≡ −2, −1, −2, −17, . . . (b) Let ai = 138 which is ≡ −2 mod 7. Traj(138) = 69, 208, 104, 52, . . . ≡ −1, −2, −1, −5, . . . Corollary. Suppose ai ≡ ai+1 ≡ ai+2 mod m. Then, (i) If ai is even, then must have ai ≡ ai+1 ≡ ai+2 ≡ 0 mod m. Moreover, one can have an arbitrarily long sequence of ai ≡ ai+1 ≡ ai+2 ≡ . . . ≡ ai+j given ai ≡ ai+1 ≡ ai+2 ≡ . . . ≡ ai+j−1 ≡ 0 mod m. 10 (ii) If ai is odd, ai ≡ ai+1 ≡ ai+2 does not occur. (iii) If ai , ai+1 , ai+2 ≡ a, b, a and a = 6 b, then a, b, a ≡ −2, −1, −2 mod m or a, b, a ≡ −1, −2, −1 mod m. Thus, any repeating pair a, b, a, b with a 6= b must be −2, −1, −2, −1 mod m or −1, −2, −1, −2 mod m. Proof of Theorems Proof of Theorem 1. Let ai be even so ai+1 = b and ai = 2b. Then, 2b ≡ b mod m b i.e. b ≡ 0 mod m = cm so, ai ai+1 = (2c)m = cm Thus, ai ≡ 0 ≡ ai+1  Proof of Theorem 2. Let ai be odd. Then, ai+1 2ai + 1 That is 2ai + 1 Thus, m is odd and 2ai ai ≡ 3ai + 1 mod m ≡ 0 mod m = cm for some odd integer c. ≡ −1 mod m ≡ −2−1 mod m.  For the converse, take m to be odd and v = 2−1 mod m. That is, 2v ≡ 1 mod m. Furthermore, suppose ai ≡ −v mod m and ai is odd. Then, ai+1 = 3ai + 1 ≡ 3(−v) + 1 mod m ≡ −v − 2v + 1 mod m ≡ −v − (2v − 1) mod m ≡ −v mod m.  Now, assuming m to be odd, let m = 2t+1, so t ≡ −2−1 mod m. Then ai ≡ t mod m, so ai = t+km for some integer k. However, t and k must have opposite parities for ai to be odd. Thus, if t is even, m ≡ 1 mod 4 and for an integer j, ai = t + (2j + 1)m = (t + m) mod 2m.  Now, if t is odd, m ≡ 3 mod 4 and ai = t + 2jm = t mod 2m.  Proof of Theorem 3. Define ai = a + s0 m, ai+1 = b + s1 m, ai+2 = a + s2 m, and ai+3 = a + s3 m. 11 (i) Let ai be odd. Then, ai+1 = 3ai + 1 and ai+2 = 21 (ai+1 ) = 21 (3ai + 1). Now, b + s1 m so, b = 3(a + s0 m) + 1 = (3a + 1) + 3s0 m ≡ 3a + 1 mod m. 2a + 2s2 m 2s2 m 1 (3ai + 1) 2 = 3a + 1 + 3s0 m = a + 1 + 3s0 m thus, a + 1 = (2s2 − 3s0 )m. Furthermore, a + s2 m = So a ≡ −1 mod m and b ≡ −2 mod m.  (ii) Let ai and ai+1 be even. So, ai+1 b + s1 m 2b + 2s1 m a so, a Then, ai+2 a + s2 m 4a + 4s2 m 3a Thus, 3a 1 ai 2 1 = (a + s0 m) 2 = a + s0 m = = 2b + (2s1 − s0 )m ≡ 2b mod m 1 ai+1 2 1 = (a + s0 m) 4 = a + s0 m = (s0 − 4s2 )m = ≡ 0 mod m. Then, if gcd(m, 3) = 1, a ≡ 0 mod m.  (iii) Let ai be even and ai+1 be odd. From (ii), we have that a ≡ 2b mod m. Now, ai+2 = 3ai+1 + 1 3 = (a + s0 m) + 1 2 = 3a + 3s0 m + 2 =a+2 a + s2 m 2a + 2s2 m (2s2 − 3s0 ) So, a ≡ −2 mod m Thus, 2b ≡ −2 mod m. Then, if gcd(m, 2) = 1, b ≡ −1 mod m.  12 Proof of Corollary. Proof follows from Theorem 1. Furthermore, sequences of the form below will be ≡ 0 mod m for j + 1 iterations. (i) ai ai+1 ai+2 ai+j−1 ai+j So, ai = 2j cm = 2j−1 cm = 2j−2 cm .. . = 2cm = cm ≡ ai+1 ≡ . . . ≡ ai+j ≡ 0 mod m.  (ii) Let ai be odd, then m = 2t + 1 is odd and ai ≡ ai+1 ≡ t mod m. Moreover, ai+1 is even, so ai+1 ≡ ai+2 which implies ai+1 ≡ ai+2 ≡ 0 mod m by Theorem 1. So t ≡ 0 mod m. But, m 0 0 = 2t + 1 ≡ 2 · 0 + 1 mod m ≡ 1 mod m Thus, we have reached a contradiction, so this case is not possible.  Special Case Suppose we allow the case that m = 3 so that the terminal sequence 4, 2, 1, 4, 2, 1, . . . becomes 1, 2, 1, 1, 2, 1, . . .. If some term ai in a Collatz sequence is odd, then the next term ai+1 = 3ai + 1 ≡ 1 mod 3 regardless of the residue of ai . Otherwise, if ai is even, then ai+1 = 12 ai ≡ 2ai mod 3. Thus, an algorithm for generating the sequence of residues mod 3 is  1, if ai is odd, ai+1 mod 3 = 2(ai mod 3), if ai is even. Because mod 3 is a special case, we examined the behavior of the residue sequences for repeating pairs a, b, a. It is simple to find numbers that generate at least a single occurrence of 1, 2, 1. It also turns out that numbers of the form 35 · 22k+1 will produce k + 6 pairs of 1, 2 followed by infinite repetitions of 1, 2, 1. Examples: • Let ai = 12s + 4 for s in the integers. Then, ai+1 = 6s + 2 and ai+2 = 3s + 1. Thus, ai , ai+1 , ai+2 ≡ 1, 2, 1 mod 3. Traj(1120) = Traj(35·22(2)+1 ) • = 560, 280, 140, 70, 35, 106, 53, 160, 80, 40, 20, 10, 5, 16, 8, 4, 2, 1. ≡ 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1 mod 3. Or more clearly, 2, (1, 2), (1, 2), (1, 2), (1, 2), (1, 2), (1, 2), (1, 2), (1, 2, 1). 13 Summary If the Collatz Conjecture is true, then every Collatz sequence eventually produces 4, 2, 1, 4, 2, 1. A direction for future study is the investigation of sequence whose sequence of residues eventually becomes a, b, c, a, b, c, . . . for some modulus m. If we could find a, b, c different from 4, 2, 1, that would disprove the Collatz Conjecture. More generally, if there exists an n-tuple, a1 , a2 , . . . , an different from 4, 2, 1, which is eventually infinitely repeated in the sequence of residues, then this would constitute a disproof. Moreover, if we could prove that the only possible n-tuple is 4, 2, 1, that would only add to the body of evidence supporting the conjecture. 14 Bibliography References [1] E. Krager. A 2-adic Extension of the Collatz Function. http://www.math.uchicago.edu/ may/VIGRE/VIGRE2011/REUPapers/Karger.pdf. (2011) [2] J. Lagarias. The 3x + 1 Problem and Its Generalizations. American Mathematical Monthly, 92, (1985), 1-23. [3] T. Ohira and H. Watanabe. A Conjecture on the Collatz-Kakulani Path Length for the Mersenne Primes. arXiv:1104.2804v3 [math.NT]. (2012). [4] A. Pettofrezzo and D. Byrkit. Elements of Number Theory: Second Edition. Orange Publishers, Florida, (1994), Chapter 3. [5] T. Oliveira e Silva. Computational Verification http://www.ieeta.pt/ tos/3x+1.html. (2008). of the 3x + 1 Conjecture. [6] R. Terras. A Stopping Time Problem on the Positive Integers. Acta Arithmetica, 30, (1976). [7] R. Terras. On the Existence of a Density. Acta Arithmetica, 35, (1979). 15