![]() |
|
|
#1 |
|
Nov 2022
1102 Posts |
Hello, I wonder if i may get math related help in this forum, first i'll give an example and then my actual question at the end.
Let's take 7991 = 61*131 (but let it be p*q, unknown factors) We know that if p is the smaller factor then p < sqrt(7991) < q sqrt(7991) = 89.39..., let's just take 89 - D as the bound (and use D=0 for now, you'll see why I included D here). And define: p = 6a + 1 q = 6b + 5 Because p < 89, it follows that 6a + 1 < 89 6a < 88 a < 15 therefore b > 15 (6a+1)(6b+5) = 7991 36ab + 30a + 6b = 7986 6ab + 5a + b = 1331 We can substitute a = 15-c, b = 15+d, because of the above inequalities 6(15-c)(15+d) + 5(15-c) + (15+d) = 1331 6cd + 95c - 91d = 109 Notice that c and d must be different parity (one even, another odd) so let's take c = 2m, d = 2n+1 (it doesn't really matter) 6*2m*(2n+1) + 95*2m - 91(2n+1) = 109 24mn + 202m - 182n = 200 12mn + 101m - 91n = 100 (divide by 2) The coefficients near m and n are: 101 and -91. Adding up the absolute values yields 192, which is exactly the sum of our prime factors and gives the system of equations p*q = 7991, p+q = 192 If that wouldn't have happened, then substitute once again, but this time m and n must be the same parity, so m = 2t + 1, n = 2u + 1 or m = 2t, n = 2u, both would work. Notice that this will happen if we (by mistake or by trial and error) define the smaller factor be 5 mod 6, and the larger one 1 mod 6 (in this case both c and d above would be negative). You can also try this with any other semiprime, here are some numbers: 3713, 8633, 3977, this will still work the same. However, this works efficiently when the difference of the two factors is very small. Here is where I'm stuck now. Remember the D i mentioned above? For example, when I tried 10476749 (which is 367*28547), I managed to get it working with D = -1868, -1867, 2950 and 2951. After some more testing it looks like it actually depends on the difference between two prime factors. My question is, would there exist any way to determine D based on any factors? With certain numbers, it would be very slow to bruteforce. Last fiddled with by IamMusavaRibica on 2022-12-21 at 22:07 |
|
|
|
|
|
#2 |
|
"Seth"
Apr 2019
2×3×83 Posts |
You might check out https://en.wikipedia.org/wiki/Fermat...ization_method which looks similar to what you are doing.
|
|
|
|
![]() |
| Thread Tools | |
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| factoring Semiprimes with Proximal factors | a1call | Miscellaneous Math | 8 | 2022-06-25 02:25 |
| Factoring semiprimes with restricted Rho method | mgb | Computer Science & Computational Number Theory | 45 | 2019-08-05 20:02 |
| New Factoring Algorithm | GreasyScooby | Factoring | 4 | 2018-04-27 13:48 |
| Semiprimes factoring. Is deterministic? What is computational complexity? | Alberico Lepore | Alberico Lepore | 43 | 2017-06-10 15:42 |
| Factoring semiprimes | robert44444uk | Math | 34 | 2007-07-19 17:23 |