#A7 INTEGERS 12 (2012) A PROPERTY OF TWIN PRIMES Chrstan Aeb Collège Calvn, Geneva, Swtzerland chrstan.aeb@edu.ge.ch Grant Carns Department of Mathematcs, La Trobe Unversty, Melbourne, Australa G.Carns@latrobe.edu.au Receved: 2/8/11, Accepted: 12/19/11, Publshed: 1/2/12 Abstract We determne the product of the nvertble quadratc resdues n Z n. Ths s a varaton on Gauss generalzaton of Wlson s Theorem. From ths we deduce that for twn prmes p, p + 2, the product of the nvertble quadratc resdues n Z p(p+2) s ±(p + 1), where the sgn depends on the resdue class of p modulo 4. We examne necessary and suffcent condtons for consecutve odd natural numbers m, m + 2 to satsfy ths property of twn prmes. The paper concludes wth two open questons. 1. Introducton Wlson s theorem can be expressed as follows: f n s a natural number, then n s prme f and only f s 1 (mod n). s s I s Z n\{0} Gauss generalzaton of Wlson s Theorem states that f I denotes the set of nvertble elements n Z n, then { 1 : f n = 4, p α, 2p α (p an odd prme) 1 : otherwse (mod n). Gauss stated ths n [6, art. 78], wrtng For the sake of brevty we omt the proof and only observe that t can be done as n the precedng artcle [whch gave a proof of one drecton of Wlson s theorem] except that the congruence x 2 1 can have more than two roots, whch requre some specal consderatons. Accordng to [5, Chap. III], proofs of Gauss generalzaton of Wlson s Theorem were provded by Mndng (1832), Brennecke (1839), Crelle (1840), Prouhet (1845), Arndt (1846),
INTEGERS: 12 (2012) 2 Drchlet (1863), Scherng (1882), Danels (1890) and Kronecker (1901). Then n 1903, Mller gave a very elegant proof usng group theory [7]. Several generalzatons of the Gauss-Wlson theorem have been gven [2, 9, 3, 4]. Our generalzaton looks at the product of the nvertble quadratc resdues. Suppose that n s a natural number, I s the set of nvertble elements n Z n and R s the set of quadratc resdues (.e., squares) n Z n. We prove: Theorem 1. If n N has prme decomposton n = p r1 1 pr k k, then s I R s 1 (mod n) unless there s precsely one prme p wth p 1 (mod 4), and n ths case s I R s s congruent modulo n to the unque element of Z n that s congruent to 1 modulo p r and congruent to 1 modulo n/p r. Ths result generalzes the well-known fact that f n = p s prme, the product of the nvertble quadratc resdues s 1 (mod p) f and only f p 1 (mod 4); see [8, p. 75] for example. Suppose that p, p + 2 are twn prmes and let n = p(p + 2). Then the followng condton holds: s (p + 1) ( 1) p+1 2 (mod p(p + 2)). (C) s I R Indeed, condton (C) can be deduced from Theorem 1 or alternately, t can be establshed drectly n 5 easy steps: 1. As p and q := p + 2 are prme, the only elements that are ther own nverse n Z pq are ±1, ±(p + 1). 2. Each nvertble square wll have a dstnct nverse whch s also a square, except those that are ther own nverse. 3. 1 s not a square n Z pq because 1 wll be square n Z p or n Z q but not n both. 4. p + 1 s a square n Z p, and f q 1 (mod 4) then p + 1 s a square n Z q, therefore also n Z pq. Smlarly, ( p 1) s square n Z q, and f p 1 (mod 4) then p 1 s a square n Z p, therefore also n Z pq 5. So ether p+1 or p 1 s a square n Z pq, and the product of all the nvertble squares equals the square n queston. The man purpose of ths note s to determne whch consecutve odd natural numbers p, p+2 verfy condton (C). Ths follows consderatons of related questons n [1]. As before, let I (resp. R) denote the set of nvertble elements (resp. quadratc resdues) n Z p(p+2). We have: Theorem 2. Let p > 1 be a natural number. Condton (C) holds f and only f one of the followng condtons holds:
INTEGERS: 12 (2012) 3 (a) p = q k where q s prme and q 1 (mod 4), and each of the prme dvsors of p + 2 s congruent to 3 (mod 4), (b) p+2 = q k where q s prme and q 1 (mod 4), and each of the prme dvsors of p s congruent to 3 (mod 4). Note that f condton (a) holds, then p 1 (mod 4) and so p + 2 3 (mod 4); thus, as the prme dvsors of p + 2 are each congruent to 3 (mod 4), the sum of the exponents n the prme decomposton of p + 2 s odd. Smlarly, f condton (b) holds, the sum of the exponents n the prme decomposton of p s odd. 2. Prelmnares and Proof of Theorem 1 Let n be an odd natural number, let n = p r1 1 pr k k be ts prme decomposton and let K = {1,..., k} be the set of ndces. Lemma 3. There are 2 k solutons to the equaton x 2 = 1 n Z n. For S = K, set x S := 1. If S s a proper subset of K, let S denote the complement of S n K, let S = S pr, let S 1 denote the smallest postve resdue of the multplcatve nverse of S n Z S, and fnally set x S := 2 S 1 S + 1. Then {x S : S K} s the set of solutons of x 2 = 1 n Z n. Remark 4. For S K, note that x S 1 s dvsble by S and x S +1 = 2(1 S 1 S), whch s a multple of S. So x S 1 (mod S) and x S 1 (mod S ). Thus x S 1 (mod p ) for all S and x S 1 (mod p ) for all S. In partcular, the x S are dstnct. Note that for S equal to the empty set, S = 1, S = n and S 1 = 1, so x S = 1. Proof of Lemma 3. If x 2 = 1 n Z n, then for each prme p, for = 1,..., k, we have x ±1 (mod p r ). For each choce of S K, the Chnese remander theorem gves a unque soluton x n Z n for whch x 1 (mod p r ) for all S and x 1 (mod p r ) for all S. Conversely, f x satsfes ths condton, then x 1 s dvsble by p for all S and x + 1 s dvsble by p for all S, and thus x 2 1 = (x 1)(x + 1) s zero n Z n. So there are precsely 2 k solutons to the equaton x 2 = 1 n Z n, one for each subset S K. Note that x S s a quadratc resdue n Z n f and only f x S s a quadratc resdue n Z p for all K. Moreover, 1 s a quadratc resdue n Z p f and only f p 1 (mod 4). Thus, snce x S 1 (mod p ) for all S and x S 1 (mod p ) for all S, we have the followng result, whch we record as a lemma.
INTEGERS: 12 (2012) 4 Lemma 5. x S s a quadratc resdue n Z n f and only f p 1 (mod 4) for all S. Lemma 6. The followng condtons are equvalent: (a) There s exactly one proper subset S of K such that x S s a quadratc resdue n Z n. (b) There s exactly one element K wth p 1 (mod 4). Proof. By Lemma 5, the subsets S K, S K, such that x S s a quadratc resdue are precsely the complements of the nonempty subsets of { K : p 1 (mod 4)}. Proof of Theorem 1. Let J denote the subset of R of elements that are ther own nverse n Z n. Clearly, s. s I R s = s J Notce that J forms a subgroup of the multplcatve group of Z n. Moreover, each element of J has order 2. But t s a general fact that n a fnte Abelan group n whch each element has order 2, the product of the elements s 1 unless the group has order 2;.e., t has only one non trval element. In the latter case, by Lemma 6 and ts proof, there s exactly one element K wth p 1 (mod 4) and s J s = x S, where S = K\{}. By Remark 4, x S s the unque element of Z n that s congruent to 1 modulo p r and congruent to 1 modulo n/p r. Ths completes the proof. 3. Proof of Theorem 2 We wll gve the proof n the case where p 3 (mod 4). The other case s treated n an entrely analogous manner. Let p r1 1 pr k k be the prme decomposton of n := p(p+2) and let K = {1,..., k}. Let P (resp. Q) be the set of elements K for whch p s a dvsor of p (resp. p + 2); so P Q = and P Q = K. Note that P = p, Q = p + 2 and x P p + 1 (mod n). Indeed, by Lemma 3, x P s the unque element that s congruent to 1 modulo p and 1 modulo p + 2, and p + 1 has these propertes. As n the proof of Theorem 1, let J denote the subset of R of elements that are ther own nverse n Z n. So s I R s = s J s. We now show that condtons (a) and (b) of the theorem are suffcent. In fact, case (a) does not occur when p 3 (mod 4). In case (b), by Lemma 6, P s the only proper subset of K such that x P s a quadratc resdue n Z n. As we observed above, x P p + 1 (mod n). So, as ( 1) p+1 2 = 1, condton (C) holds.
INTEGERS: 12 (2012) 5 1.0 0.8 0.6 0.4 0.2 500 000 1.0 10 6 1.5 10 6 2.0 10 6 Fgure 1: T n /C n for n 2, 000, 000 Conversely, suppose that condton (C) holds, so s I R s = p + 1. From Theorem 1, there s a unque prme p wth p 1 (mod 4), and n ths case s I R s s congruent modulo n to the unque element of Z n that s congruent to 1 modulo p r and congruent to 1 modulo n/p r Now, (1) gves p + 2 = ap r a = b = 1, and so p + 2 = p r proof.. Thus there exsts a, b N such that p + 1 = 1 + ap r, (1) p + 1 = 1 + bn/p r. (2) and usng ths, (2) gves p = bn/p r = abp. Hence. Ths establshes condton (b) and completes the 4. Two Questons There are two obvous questons: Queston 1. Are there nfntely many odd natural numbers p for whch condton (C) holds? Gven n N, let T n denote the number of prmes p < n for whch p + 2 s prme, and let C n denote the number of odd natural numbers p < n for whch condton (C) holds. T n Queston 2. Is lm strctly postve? n C n Fgure 1 shows values of T n /C n for n 2,000,000, calculated usng Mathematca.
INTEGERS: 12 (2012) 6 References [1] Chrstan Aeb and Grant Carns, Catalan numbers, prmes, and twn prmes, Elem. Math. 63 (2008), no. 4, 153 164. [2] L. Carltz, A note on the generalzed Wlson s theorem, Amer. Math. Monthly 71 (1964), 291 293. [3] John B. Cosgrave and Karl Dlcher, Extensons of the Gauss-Wlson theorem, Integers 8 (2008), A39, 15pp. [4] Chandan Sngh Dalawat, Wlson s theorem, J. Théor. Nombres Bordeaux 21 (2009), no. 3, 517 521. [5] Leonard Eugene Dckson, Hstory of the Theory of Numbers. Vol. I: Dvsblty and prmalty., Chelsea Publshng Co., New York, 1966. [6] Carl Fredrch Gauss, Dsqustones Arthmetcae, Sprnger-Verlag, New York, 1986, Translated and wth a preface by Arthur A. Clarke, Revsed by Wllam C. Waterhouse, Cornelus Grether and A. W. Grootendorst and wth a preface by Waterhouse. [7] G. A. Mller, A new proof of the generalzed Wlson s theorem, Ann. of Math. (2) 4 (1903), no. 4, 188 190. [8] H. E. Rose, A Course n Number Theory, second ed., Oxford Scence Publcatons, The Clarendon Press Oxford Unversty Press, New York, 1994. [9] Štefan Schwarz, The role of semgroups n the elementary theory of numbers, Math. Slovaca 31 (1981), no. 4, 369 395.