Talk:Rare numbers: Difference between revisions

→‎Tweaks, C++: Comparison on Core i5 1035G1 and i7 Q720
(added C++ tweaks section)
(→‎Tweaks, C++: Comparison on Core i5 1035G1 and i7 Q720)
Line 1,144:
75 8320411466598809138 4079154376 36366330 19: 5m3.388s 6m2.894s</pre>
--[[User:Enter your username|Enter your username]] ([[User talk:Enter your username|talk]]) 23:46, 25 May 2020 (UTC)
 
::Good to see the spirit of C is alive and well multyplying bools by integers and mysterious 3.94's. Idiotmatic? who cares? but old fashioned never, so perhaps int sc{0}; rather than int sc=0;. I have compiled the code using mingw on an Core I5 1035G1 and using g++ and clang++ on a Core I7 Q720 (now a very old machine). Interestingly the poor old Q720 takes about the same time for g++ and clang++ with this code. The time taken by the Core I5 1035G1 is the same as your i7 for 2..18 but interestingly about 10secs faster for 19. I shall look at the actual changes over the next few days, the important thing is that they mustnot be based on knowing the result. The timings I have obtained are:
<pre>
nth forward rt.sum rt.diff digs block.et total.et
1 65 11 3 2: 0.00027s 0.00027s
3: 0.00002s 0.00030s
4: 0.00001s 0.00031s
5: 0.00002s 0.00034s
2 621770 836 738 6: 0.00005s 0.00040s
7: 0.00025s 0.00066s
8: 0.00075s 0.00142s
3 281089082 23708 330 9: 0.00477s 0.00619s
4 2022652202 63602 300
5 2042832002 63602 6360 10: 0.01432s 0.02051s
11: 0.08783s 0.10835s
6 868591084757 1275175 333333
7 872546974178 1320616 32670
8 872568754178 1320616 33330 12: 0.01142s 0.11977s
9 6979302951885 3586209 1047717 13: 0.05034s 0.17011s
10 20313693904202 6368252 269730
11 20313839704202 6368252 270270
12 20331657922202 6368252 329670
13 20331875722202 6368252 330330
14 20333875702202 6368252 336330
15 40313893704200 6368252 6330336
16 40351893720200 6368252 6336336 14: 0.12319s 0.29331s
17 200142385731002 20006998 69300
18 204238494066002 20122102 1891560
19 221462345754122 21045662 69300
20 244062891224042 22011022 1908060
21 245518996076442 22140228 921030
22 248359494187442 22206778 1891560
23 403058392434500 20211202 19940514
24 441054594034340 22011022 19940514
25 816984566129618 40421606 250800 15: 0.72540s 1.01872s
26 2078311262161202 64030648 7529850
27 2133786945766212 65272218 2666730
28 2135568943984212 65272218 3267330
29 2135764587964212 65272218 3326670
30 2135786765764212 65272218 3333330
31 4135786945764210 65272218 63333336
32 6157577986646405 105849161 33333333
33 6889765708183410 83866464 82133718
34 8052956026592517 123312255 29999997
35 8052956206592517 123312255 30000003
36 8191154686620818 127950856 3299670
37 8191156864620818 127950856 3300330
38 8191376864400818 127950856 3366330
39 8650327689541457 127246955 33299667
40 8650349867341457 127246955 33300333 16: 2.24472s 3.26344s
41 22542040692914522 212329862 333300
42 67725910561765640 269040196 251135808
43 86965750494756968 417050956 33000 17: 13.9236s 17.1870s
44 225342456863243522 671330638 297000
45 225342458663243522 671330638 303000
46 225342478643243522 671330638 363000
47 284684666566486482 754565658 30000
48 284684868364486482 754565658 636000
49 297128548234950692 770186978 32697330
50 297128722852950692 770186978 32702670
51 297148324656930692 770186978 33296670
52 297148546434930692 770186978 33303330
53 497168548234910690 770186978 633363336
54 619431353040136925 1071943279 299667003
55 619631153042134925 1071943279 300333003
56 631688638047992345 1083968809 297302703
57 633288858025996145 1083968809 302637303
58 633488632647994145 1083968809 303296697
59 653488856225994125 1083968809 363303363
60 811865096390477018 1273828556 33030330
61 865721270017296468 1315452006 32071170
62 871975098681469178 1320582934 3303300
63 898907259301737498 1339270086 64576740 18: 42.8003s 59.9873s
64 2042401829204402402 2021001202 18915600
65 2060303819041450202 2020110202 199405140
66 2420424089100600242 2200110022 19080600
67 2551755006254571552 2259094848 693000
68 2702373360882732072 2324811012 693000
69 2825378427312735282 2377130742 2508000
70 6531727101458000045 3454234451 1063822617
71 6988066446726832640 2729551744 2554541088
72 8066308349502036608 4016542096 2508000
73 8197906905009010818 4046976144 133408770
74 8200756128308135597 4019461925 495417087
75 8320411466598809138 4079154376 36366330 19: 4m52.40s 5m52.39s
g++ (SUSE Linux) 9.2.1 20200109 [gcc-9-branch revision 280039]
40 8650349867341457 127246955 33300333 16: 15.5694s 22.0091s
43 86965750494756968 417050956 33000 17: 1m33.80s 1m55.81s
63 898907259301737498 1339270086 64576740 18: 4m57.66s 6m53.47s
75 8320411466598809138 4079154376 36366330 19: 30m31.1s 37m24.5s
 
clang version 9.0.1
 
40 8650349867341457 127246955 33300333 16: 15.1173s 21.4643s
43 86965750494756968 417050956 33000 17: 1m32.36s 1m53.82s
63 898907259301737498 1339270086 64576740 18: 4m47.22s 6m41.04s
75 8320411466598809138 4079154376 36366330 19: 29m5.71s 35m46.7s
</pre>
 
== 21+ digit rare numbers ==
Well, one anyway (so far). I tweaked the BigInteger version of the C# program to skip to start at 21 digits. Around 6 hours, I got the first one: '''219,518,549,668,074,815,912''', with the sum = '''20,953,210,268<sup>2</sup>''', and the difference = '''8,877,000<sup>2</sup>'''. Still have no idea how long it will take to finish the block of 21 digit numbers. Since the difference found so far was a relatively low number, it probably has quite a while to go.
2,172

edits