Gene Browder
Sec 4.3
3/9/2010
3. For any positive number n, it can be shown that there exists an even integer a, that is representable as the sum of two odd primes in n different ways. Confirm that the integers 66, 96, and 108 can be written as the sum of two primes in six, seven, and eight ways, respectively. 66 66 66 66 66 66 66 66 66 66 66
2 3 5 7 11 13 17 19 23 29 31
64 63 61 59 55 53 49 47 43 37 35
96 96 96 96 96 96 96 96 96 96 96 96
2 3 5 7 11 13 17 19 23 29 31 37
94 93 91 89 85 83 79 77 73 67 65 59
108 108 108 108 108 108 108 108 108 108 108 108 108 108 108 108
2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53
106 105 103 101 97 95 91 89 85 79 77 71 67 65 61 55
Gene Browder
Sec 4.3
3/9/2010
4. A conjecture of Lagrange (1775) asserts that every odd integer greater than 5 can be written as a sum p + 2q, where p and q are both primes. Verify that this holds for all such odd integers through 75 p 3 3 3 3 3 3 3 3 3 3 3 3 5 5 5 5 5 5 5 5 5 5 5 5 7 7 7 7 7 7 7 7 7 7 7 7
q 2 3 5 7 11 13 17 19 23 29 31 37 2 3 5 7 11 13 17 19 23 29 31 37 2 3 5 7 11 13 17 19 23 29 31 37
p+2q 7 9 13 17 25 29 37 41 49 61 65 77 9 11 15 19 27 31 39 43 51 63 67 79 11 13 17 21 29 33 41 45 53 65 69 81
sequence 1 2 4 6 10 12 16 18 22 28 30
3 5 7 11 13 17 19 23 29 31
8 14 20 24 32
p 9 9 9 9 9 9 9 9 9 9 9 9 11 11 11 11 11 11 11 11 11 11 11 11 13 13 13 13 13 13 13 13 13 13 13 13
q 2 3 5 7 11 13 17 19 23 29 31 37 2 3 5 7 11 13 17 19 23 29 31 37 2 3 5 7 11 13 17 19 23 29 31 37
p+2q 13 15 19 23 31 35 43 47 55 67 71 83 15 17 21 25 33 37 45 49 57 69 73 85 17 19 23 27 35 39 47 51 59 71 75 87
sequence
9 15 21 25 33
26 34
27 35
Gene Browder
Sec 4.3
3/9/2010
5. Find an example to show that the following conjecture is not true: Every positive integer can be written in the form p + a 2 , where p is a prime (or else equal to 1) and a â&#x2030;Ľ 0. public class hw4_3_6 { /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub int prime[]={ 1,2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73, 83,89,97,101,103,107,109,113 }; int numberOfPrimes=0; double answer=0; int count =1; int curentPrime=0; int currentA=0; numberOfPrimes = prime.length; while(count<102) { for(int primeLoop=0; primeLoop<numberOfPrimes; primeLoop++) { for(int loop=0; loop<250; loop++) { answer=prime[primeLoop]+(loop*loop); curentPrime=prime[primeLoop]; currentA = loop; if(answer>count) break; if(answer==count) break; } if(answer==count) break; } if(answer==count) System.out.println(count+" : p = "+curentPrime+", a = "+currentA); if(answer>count) System.out.println(count+" : ***could not be resolved *** "); count = count +1; } } }
Gene Browder
Sec 4.3
Output of program: 25, 34, 58,64,85 and 91 do not obey the rule.
1 : p = 1, a = 0 2 : p = 1, a = 1 3 : p = 2, a = 1 4 : p = 3, a = 1 5 : p = 1, a = 2 6 : p = 2, a = 2 7 : p = 3, a = 2 8 : p = 7, a = 1 9 : p = 5, a = 2 10 : p = 1, a = 3 11 : p = 2, a = 3 12 : p = 3, a = 3 13 : p = 13, a = 0 14 : p = 5, a = 3 15 : p = 11, a = 2 16 : p = 7, a = 3 17 : p = 1, a = 4 18 : p = 2, a = 4 19 : p = 3, a = 4 20 : p = 11, a = 3 21 : p = 5, a = 4 22 : p = 13, a = 3 23 : p = 7, a = 4 24 : p = 23, a = 1 25 : ***could not be resolved *** 26 : p = 1, a = 5 27 : p = 2, a = 5 28 : p = 3, a = 5 29 : p = 13, a = 4 30 : p = 5, a = 5 31 : p = 31, a = 0 32 : p = 7, a = 5 33 : p = 17, a = 4 34 : ***could not be resolved *** 35 : p = 19, a = 4 36 : p = 11, a = 5 37 : p = 1, a = 6 38 : p = 2, a = 6 39 : p = 3, a = 6 40 : p = 31, a = 3 41 : p = 5, a = 6 42 : p = 17, a = 5 43 : p = 7, a = 6 44 : p = 19, a = 5 45 : p = 29, a = 4 46 : p = 37, a = 3 47 : p = 11, a = 6 48 : p = 23, a = 5 49 : p = 13, a = 6 50 : p = 1, a = 7 51 : p = 2, a = 7 52 : p = 3, a = 7 53 : p = 17, a = 6
3/9/2010
Gene Browder 54 : p = 5, a = 7 55 : p = 19, a = 6 56 : p = 7, a = 7 57 : p = 41, a = 4 58 : ***could not be 59 : p = 23, a = 6 60 : p = 11, a = 7 61 : p = 61, a = 0 62 : p = 13, a = 7 63 : p = 47, a = 4 64 : ***could not be 65 : p = 1, a = 8 66 : p = 2, a = 8 67 : p = 3, a = 8 68 : p = 19, a = 7 69 : p = 5, a = 8 70 : p = 61, a = 3 71 : p = 7, a = 8 72 : p = 23, a = 7 73 : p = 37, a = 6 74 : p = 73, a = 1 75 : p = 11, a = 8 76 : p = 67, a = 3 77 : p = 13, a = 8 78 : p = 29, a = 7 79 : p = 43, a = 6 80 : p = 31, a = 7 81 : p = 17, a = 8 82 : p = 1, a = 9 83 : p = 2, a = 9 84 : p = 3, a = 9 85 : ***could not be 86 : p = 5, a = 9 87 : p = 23, a = 8 88 : p = 7, a = 9 89 : p = 53, a = 6 90 : p = 41, a = 7 91 : ***could not be 92 : p = 11, a = 9 93 : p = 29, a = 8 94 : p = 13, a = 9 95 : p = 31, a = 8 96 : p = 47, a = 7 97 : p = 61, a = 6 98 : p = 17, a = 9 99 : p = 83, a = 4 100 : p = 19, a = 9 101 : p = 1, a = 10
Sec 4.3
resolved ***
resolved ***
resolved ***
resolved ***
3/9/2010
Gene Browder
Sec 4.3
3/9/2010
13.
2 ( a + 1) − a 2 2
If
then
This is a contradiction.
2 2a + 1
and
2 ( 2a + 1) − 2a
or
21
Gene Browder
Sec 4.3
15. Find gcd (143, 277), gcd (136, 232), and gcd (272, 1479).
gcd (143, 277 )
k = 1 : 277 = 143q += r 143*1 + 134 k = 2 : 143 = 134q += r 134*1 + 9 k = 3 : 134 = 9q + r = 9*14 + 8
k = 4 : 9 = 8q + r = 8*1 + 1 k = 5 : 8 = 1q + r = 1*8 + 0 gcd (143, 277 ) = 1 gcd (136, 232 )
k = 1 : 232 = 136q += r 136*1 + 96 k = 2 : 136= 96q + r= 96*1 + 40
k = 3 : 96= 40q + r= 40* 2 + 16 k = 4 : 40= 16q + r= 16* 2 + 8 k = 5 : 16 = 8q + r = 8* 2 + 0 gcd (136, 232 ) = 8 gcd ( 272,1479 )
k = 1 : 1479 = 272q += r 272*5 + 119 k = 2 : 272 = 119q += r 119* 2 + 34
k = 3 : 119= 34q + r= 34*3 + 17 k = 4 : 34= 17 q + r= 17 * 2 + 0 gcd ( 272,1479 ) = 17
3/9/2010
Gene Browder
Sec 4.3
16.
a.
gcd ( 56, 72 = ) 56 x + 72 y
k = 1 : 72= 56q + r= 56*1 + 16 k = 2 : 56= 16q + r= 16*3 + 8 k = 3 : 16 = 8q + r = 8* 2 + 0 gcd ( 56, 72 ) = 8
Back Substituting to find x0 , y0
k = 2: = 8 56 − 16*3 k = 1 : 16 = 72 − 56 , substitute for 16 in the above equation 8 =56 − ( 72 − 56 ) *3 = 8
( 4 ) *56 + ( −3) *72
x = 4, y = −3
3/9/2010
Gene Browder
Sec 4.3
b.
gcd ( 24,138 = ) 24 x + 138 y
k = 1 : 138= 24q + r= 24*5 + 18
k = 2 : 24= 18q + r= 18*1 + 6 k = 3 : 18 = 6q + r = 6*3 + 0 gcd ( 24,138 ) = 6
Back Substituting to find x0 , y0
k = 2: = 6 24 − 18*1
k = 1: = 18 138 − 24*5 , substitute for 18 in the above equation 6 =24 − (138 − 24*5 ) *1
= 6
( 6 ) * 24 + ( −1) *138
x = 6, y = −1
3/9/2010
Gene Browder
Sec 4.3
c.
gcd (119, 272 = ) 119 x + 272 y
k = 1 : 272 = 119q += r 119* 2 + 34 k = 2 : 119= 34q + r= 34*3 + 17 k = 3 : 34= 17 q + r= 17 * 2 + 0 gcd (119, 272 ) = 17
Back Substituting to find x0 , y0
k = 2 : 17 = 119 − 34*3 34 272 − 119* 2 , substitute for 34 in the above equation k = 1: = 17 =119 − ( 272 − 119* 2 ) *3 = 17
( 7 ) *119 + ( −3) * 272
x = 7, y = −3
3/9/2010
Gene Browder
Sec 4.3
d.
gcd (1769, 2378 = ) 1769 x + 2378 y
k = 1 : 2378 = 1769q = + r 1769*1 + 609 k = 2 : 1769 = 609q += r 609* 2 + 551 k = 3 : 609 = 551q += r 551*1 + 58
k = 4 : 551= 58q + r= 58*9 + 29 k = 5 : 58= 29q + r= 29* 2 + 0 gcd (1769, 2378 ) = 29
Back Substituting to find x0 , y0
k = 4:= 29 551 − 58*9
k = 3 := 58 609 − 551*1 , substitute for 58 in the above equation 29 =551 − ( 609 − 551*1) *9
= 29 (10) *551 − (9) *609
k = 2: = 551 1769 − 609* 2 , substitute for 551 in the above equation = 29 (10) *551 − (9) *609 29 = (10) * (1769 − 609* 2 ) − (9) *609 = 29 (10) * (1769 ) − (29) *609
k = 1: = 609 2378 − 1769*1 , substitute for 609 in the above equation = 29 (10) * (1769 ) − (29) *609 29 = (10) * (1769 ) − (29) * ( 2378 − 1769*1)
= 29 (39) *1769 − (29) * 2378
x = 39, y = −29
3/9/2010