Math moran question | |
Anonymous Coward User ID: 74634754 United States 08/30/2022 04:55 PM Report Abusive Post Report Copyright Violation | |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/30/2022 04:56 PM Report Abusive Post Report Copyright Violation | Thanks.. I had a feeling I was dealing with an error ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |
Anonymous Coward User ID: 71295875 United States 08/30/2022 05:00 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 75257707 United States 08/30/2022 05:06 PM Report Abusive Post Report Copyright Violation | |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/30/2022 05:06 PM Report Abusive Post Report Copyright Violation | Hmm is it direct um moran question um ok direct response But it makes me wonder if I'm onto something nonetheless. Perhaps adding 1 on the second step will yield the same results for this and other number combinations. I have fun with this kind of thing. 20+ years ago I calculated prime numbers in my head with simple math while trying to fall asleep. After I got into the 30,000's I jumped up to check wether or not the last number was indeed prime. Sure enough it was. I started trying to program the algorithm but I wasn't good enough at programming then. Last month I wrote the program from what I could remember. It works. Does it generate *all* prime numbers.. not sure, but definitely *all* prime numbers in the lower ranges. ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |
Vasily
User ID: 80249882 United States 08/30/2022 05:07 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 74913668 United States 08/30/2022 05:09 PM Report Abusive Post Report Copyright Violation | |
Eilonwy
User ID: 83015319 United States 08/30/2022 05:19 PM Report Abusive Post Report Copyright Violation | |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/30/2022 05:21 PM Report Abusive Post Report Copyright Violation | If interested, the basis for my prime number generator is simply: 0 + 1 = 1 (technically prime) 1 + 1 = 2 (the only even prime) 2 + 1 = 3 (prime) 3 + 2 = 5 (prime) 5 + 2 = 7 (prime) 7 + 5 = 13 (prime) But skips 11, so.. 13 - 2 = 11 (prime) There's more to it, but that's what got me going on it. The algorithm I made in my head 20+ years ago skipped whole ranges of primes. And possibly the one I created a month ago does too. Fun with numbers either way. ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |
Anonymous Coward User ID: 4812794 United States 08/30/2022 05:29 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 84102074 United States 08/30/2022 05:39 PM Report Abusive Post Report Copyright Violation | Hmm is it direct um moran question um ok direct response But it makes me wonder if I'm onto something nonetheless. Perhaps adding 1 on the second step will yield the same results for this and other number combinations. I have fun with this kind of thing. 20+ years ago I calculated prime numbers in my head with simple math while trying to fall asleep. After I got into the 30,000's I jumped up to check wether or not the last number was indeed prime. Sure enough it was. I started trying to program the algorithm but I wasn't good enough at programming then. Last month I wrote the program from what I could remember. It works. Does it generate *all* prime numbers.. not sure, but definitely *all* prime numbers in the lower ranges. this is just how math works the way we’ve constructed our proofs your line of thinking was done 1000 years ago, by the ancients will you be nasa spending billions on a pen, or russia using a pencil? |
Anonymous Coward User ID: 84102074 United States 08/30/2022 05:42 PM Report Abusive Post Report Copyright Violation | If interested, the basis for my prime number generator is simply: Quoting: BoatyMcBoatface 0 + 1 = 1 (technically prime) 1 + 1 = 2 (the only even prime) 2 + 1 = 3 (prime) 3 + 2 = 5 (prime) 5 + 2 = 7 (prime) 7 + 5 = 13 (prime) But skips 11, so.. 13 - 2 = 11 (prime) There's more to it, but that's what got me going on it. The algorithm I made in my head 20+ years ago skipped whole ranges of primes. And possibly the one I created a month ago does too. Fun with numbers either way. not really a generator if you state the output and not the algo wouldn’t the next sequence be 13+7=20? or 13+5=18? |
TheRealRebel
User ID: 79564765 United States 08/30/2022 05:43 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 28718123 United States 08/30/2022 05:48 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 82448783 United States 08/30/2022 05:52 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 77073043 United States 08/30/2022 06:07 PM Report Abusive Post Report Copyright Violation | |
Swearbox
User ID: 77978222 Canada 08/30/2022 06:17 PM Report Abusive Post Report Copyright Violation | Hmm is it direct um moran question um ok direct response But it makes me wonder if I'm onto something nonetheless. Perhaps adding 1 on the second step will yield the same results for this and other number combinations. I have fun with this kind of thing. 20+ years ago I calculated prime numbers in my head with simple math while trying to fall asleep. After I got into the 30,000's I jumped up to check wether or not the last number was indeed prime. Sure enough it was. I started trying to program the algorithm but I wasn't good enough at programming then. Last month I wrote the program from what I could remember. It works. Does it generate *all* prime numbers.. not sure, but definitely *all* prime numbers in the lower ranges. Yep, you're onto something all right...something that looks like Common Core math...fucking stupid and the long arsed way of doing shit. Last Edited by Swearbox on 08/30/2022 06:22 PM Chill out, its just a Lancashire Rose |
Red John
User ID: 54498203 Canada 08/30/2022 06:21 PM Report Abusive Post Report Copyright Violation | |
Anonymous Coward User ID: 79527685 United States 08/30/2022 06:28 PM Report Abusive Post Report Copyright Violation | |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/31/2022 08:54 AM Report Abusive Post Report Copyright Violation | If interested, the basis for my prime number generator is simply: Quoting: BoatyMcBoatface 0 + 1 = 1 (technically prime) 1 + 1 = 2 (the only even prime) 2 + 1 = 3 (prime) 3 + 2 = 5 (prime) 5 + 2 = 7 (prime) 7 + 5 = 13 (prime) But skips 11, so.. 13 - 2 = 11 (prime) There's more to it, but that's what got me going on it. The algorithm I made in my head 20+ years ago skipped whole ranges of primes. And possibly the one I created a month ago does too. Fun with numbers either way. not really a generator if you state the output and not the algo wouldn’t the next sequence be 13+7=20? or 13+5=18? I handle that with simple addition or subtraction of 1. In this case, both are prime 17 & 19. Here's the output from my generator with 100 cycles using 0 through 100 as input: [ 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, 509, 521, 523, 541, ... 188 more items ] Here, with 1,000,000,000,000 through 1,000,000,000,100 as input: Time to generate primes with 1000000000000 and 1000000000100: 71.849ms [ 1000000000039, 1000000000061, 1000000000063, 1000000000091, 2000000000137, 2000000000179, 3000000000187, 4000000000361 ] Last Edited by BoatyMcBoatface on 08/31/2022 09:09 AM ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/31/2022 08:55 AM Report Abusive Post Report Copyright Violation | Yes. > pryme 8675309 default: 0.229ms 8675309 is prime? true Last Edited by BoatyMcBoatface on 08/31/2022 08:56 AM ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |
BoatyMcBoatface
(OP) User ID: 77825331 United States 08/31/2022 08:57 AM Report Abusive Post Report Copyright Violation | sweet! ```````````````` ````__/\__`````` ~~~\____/~~~~ .~~..~~~....~~~ ~..~~~....~~~~ Thoughts do not come from you nor God; you do not create thoughts; you are not your thoughts; every thought is a lie. - 2 Corinthians 10:5 - [link to www.biblegateway.com (secure)] |