mersenneforum.org Question about these fascinating primes
 User Name Remember Me? Password
 Register FAQ Search Today's Posts Mark Forums Read

 2020-04-20, 15:57 #45 VBCurtis     "Curtis" Feb 2005 Riverside, CA 33×5×31 Posts Sure, it's the same form- but look at where you wrote the equals sign. You wrote that 405 * 2 ^ (10+1) - 1 = 263,167. That's not true.
2020-04-20, 17:58   #46
storm5510
Random Account

Aug 2009
U.S.A.

121210 Posts

Quote:
 Originally Posted by VBCurtis Sure, it's the same form- but look at where you wrote the equals sign. You wrote that 405 * 2 ^ (10+1) - 1 = 263,167. That's not true.
Of course it is not true. That result is for the entire sequence, both sides:

The left side:

405*2^10-1
405*1024-1
414720-1
414719

The right side:

405*2^(10+1)-1
405*2^11-1
405*2048-1
829440-1
829439

414719 AND 829439 = 263167.

2020-04-20, 18:12   #47
VBCurtis

"Curtis"
Feb 2005
Riverside, CA

33·5·31 Posts

Quote:
 Originally Posted by storm5510 414719 AND 829439 = 263167.
What does this even mean? What definition of "=" do you have in mind here?

Edit: Or, I guess, what definition of "and"? You capitalized and underlined it, so maybe that is the word in question.

Last fiddled with by VBCurtis on 2020-04-20 at 18:13

 2020-04-20, 20:53 #48 kar_bon     Mar 2006 Germany 24·52·7 Posts Your AND you meant as a logical and-operation of both numbers, but that's not what the definition of a SG is and the example I gave. Please read this article to understand. Your calculation seems correct so far, but you misinterpreted the 'and' and so used a false algorithm to calculate the result.
2020-04-21, 14:43   #49
storm5510
Random Account

Aug 2009
U.S.A.

22×3×101 Posts

Yes, it is a logical And.

At kar_bon's suggestion, I ran a sample PFGW ABC2 which he provided. I received the same results. I took the & in his example to mean a logical and. Thus, the confusion on my part. PFGW uses && to indicate a logical and. After reading more of the documentation, the & or | indicates multiple expressions on the same line. Each is evaluated separately. I found the below in Wikipedia:

Quote:
 In number theory, a prime number p is a Sophie Germain prime if 2p + 1 is also prime.
It could not be more simple than this.

2020-04-21, 15:19   #50
xilman
Bamboozled!

May 2003
Down not across

23·1,249 Posts

Quote:
 Originally Posted by storm5510 Yes, it is a logical And. At kar_bon's suggestion, I ran a sample PFGW ABC2 which he provided. I received the same results. I took the & in his example to mean a logical and. Thus, the confusion on my part. PFGW uses && to indicate a logical and. After reading more of the documentation, the & or | indicates multiple expressions on the same line. Each is evaluated separately. I found the below in Wikipedia: It could not be more simple than this.
Now I'm confused.

A logical and to me states that the two Boolean quantities to each side of the operator must both be simultaneously TRUE for the whole to be TRUE. This is exactly what is stated in the Wikipedia definition.

A bitwise and when applied to two ordered lists of Boolean quantities of equal size yields another ordered list of Booleans with the same size where each element of the resulting list is TRUE if and only if each corresponding element of the two initial lists are simultaneously TRUE. It is common, though not universal, for a list of Booleans to be represented by the binary representation of an integer. It is also common, though not universal, for a TRUE value to be represented by a 1 and a FALSE value by zero. In hardware circuitry TRUE may be represented either by a high voltage or high current, or a low voltage or low current so careful attention to context is required.

2020-04-21, 17:04   #51
storm5510
Random Account

Aug 2009
U.S.A.

22×3×101 Posts

Quote:
 Originally Posted by xilman Now I'm confused. A logical and to me states that the two Boolean quantities to each side of the operator must both be simultaneously TRUE for the whole to be TRUE. This is exactly what is stated in the Wikipedia definition. A bitwise and when applied to two ordered lists of Boolean quantities of equal size yields another ordered list of Booleans with the same size where each element of the resulting list is TRUE if and only if each corresponding element of the two initial lists are simultaneously TRUE. It is common, though not universal, for a list of Booleans to be represented by the binary representation of an integer. It is also common, though not universal, for a TRUE value to be represented by a 1 and a FALSE value by zero. In hardware circuitry TRUE may be represented either by a high voltage or high current, or a low voltage or low current so careful attention to context is required.
It can be confusing...

11001001 is decimal 201
10110101 is decimal 181
-------------
10000001 is decimal 129

201 and 181 is 129. I did this in decimal, after doing the binary above, but the determination is done in binary at the machine level. What would appear to be different, on the surface, is actually not.

 Similar Threads Thread Thread Starter Forum Replies Last Post mart_r Prime Gap Searches 9 2020-01-19 22:20 enzocreti enzocreti 55 2019-04-27 11:10 tServo Hardware 7 2018-11-17 16:28 doctornash Other Mathematical Topics 7 2018-07-14 00:06 firejuggler Math 31 2014-01-08 18:28

All times are UTC. The time now is 15:49.

Sun May 31 15:49:04 UTC 2020 up 67 days, 13:22, 1 user, load averages: 2.02, 1.90, 1.99