In[]:=
LaunchKernels[]
Out[]=
{KernelObject[1,WIN-1AA39U1LQNT],KernelObject[2,WIN-1AA39U1LQNT],KernelObject[3,WIN-1AA39U1LQNT],KernelObject[4,WIN-1AA39U1LQNT],KernelObject[5,WIN-1AA39U1LQNT],KernelObject[6,WIN-1AA39U1LQNT],KernelObject[7,WIN-1AA39U1LQNT],KernelObject[8,WIN-1AA39U1LQNT],KernelObject[9,WIN-1AA39U1LQNT],KernelObject[10,WIN-1AA39U1LQNT],KernelObject[11,WIN-1AA39U1LQNT],KernelObject[12,WIN-1AA39U1LQNT],KernelObject[13,WIN-1AA39U1LQNT],KernelObject[14,WIN-1AA39U1LQNT],KernelObject[15,WIN-1AA39U1LQNT],KernelObject[16,WIN-1AA39U1LQNT],KernelObject[17,DigitalStorm-PC],KernelObject[18,DigitalStorm-PC],KernelObject[19,DigitalStorm-PC],KernelObject[20,DigitalStorm-PC],KernelObject[21,DigitalStorm-PC],KernelObject[22,DigitalStorm-PC],$Failed,KernelObject[23,local],KernelObject[24,local],KernelObject[25,local],KernelObject[26,local],KernelObject[27,local],KernelObject[28,local],KernelObject[29,local],KernelObject[30,local],KernelObject[31,local],KernelObject[32,local],KernelObject[33,local],KernelObject[34,local],KernelObject[35,local],KernelObject[36,local],KernelObject[37,local],KernelObject[38,local],KernelObject[39,local],KernelObject[40,local],KernelObject[41,local],KernelObject[42,local],KernelObject[43,local],KernelObject[44,local],KernelObject[45,local],KernelObject[46,local]}
In[]:=
Print["Start time is ",ds=DateString[],"."];prec=100000;(**Numberofrequireddecimals.*.*)ClearSystemCache[];T0=SessionTime[];expM[pre_]:=Module[{a,d,s,k,bb,c,end,iprec,xvals,x,pc,cores=16(*=4*numberofphysicalcores*),tsize=2^7,chunksize,start=1,ll,ctab,pr=Floor[1.005pre]},chunksize=cores*tsize;n=Floor[1.32pr];end=Ceiling[n/chunksize];Print["Iterations required: ",n];Print["Will give ",end," time estimates, each more accurate than the previous."];Print["Will stop at ",end*chunksize," iterations to ensure precsion of around ",pr," decimal places."];d=ChebyshevT[n,3];{b,c,s}={SetPrecision[-1,1.1*n],-d,0};iprec=Ceiling[pr/6912];Do[xvals=Flatten[Parallelize[Table[Table[ll=start+j*tsize+l;x=N[E^(Log[ll]/(ll)),iprec];pc=iprec;While[pc<pr/1024,pc=Min[3pc,pr/1024];x=SetPrecision[x,pc];y=x^ll-ll;x=x(1-2y/((ll+1)y+2llll));];(**N[Exp[Log[ll]/ll],pr/1024]**)x=SetPrecision[x,pr/256];xll=x^ll;z=(ll-xll)/xll;t=2ll-1;t2=t^2;x=x*(1+SetPrecision[4.5,pr/256](ll-1)/t2+(ll+1)z/(2llt)-SetPrecision[13.5,pr/256]ll(ll-1)1/(3llt2+t^3z));(*N[Exp[Log[ll]/ll],pr/256]*)x=SetPrecision[x,pr/64];xll=x^ll;z=(ll-xll)/xll;t=2ll-1;t2=t^2;x=x*(1+SetPrecision[4.5,pr/64](ll-1)/t2+(ll+1)z/(2llt)-SetPrecision[13.5,pr/64]ll(ll-1)1/(3llt2+t^3z));(**N[Exp[Log[ll]/ll],pr/64]**)x=SetPrecision[x,pr/16];xll=x^ll;z=(ll-xll)/xll;t=2ll-1;t2=t^2;x=x*(1+SetPrecision[4.5,pr/16](ll-1)/t2+(ll+1)z/(2llt)-SetPrecision[13.5,pr/16]ll(ll-1)1/(3llt2+t^3z));(**N[Exp[Log[ll]/ll],pr/16]**)x=SetPrecision[x,pr/4];xll=x^ll;z=(ll-xll)/xll;t=2ll-1;t2=t^2;x=x*(1+SetPrecision[4.5,pr/4](ll-1)/t2+(ll+1)z/(2llt)-SetPrecision[13.5,pr/4]ll(ll-1)1/(3llt2+t^3z));(**N[Exp[Log[ll]/ll],pr/4]**)x=SetPrecision[x,pr];xll=x^ll;z=(ll-xll)/xll;t=2ll-1;t2=t^2;x=x*(1+SetPrecision[4.5,pr](ll-1)/t2+(ll+1)z/(2llt)-SetPrecision[13.5,pr]ll(ll-1)1/(3llt2+t^3z));(*N[Exp[Log[ll]/ll],pr]*)x,{l,0,tsize-1}],{j,0,cores-1}]]];ctab=ParallelTable[Table[c=b-c;ll=start+l-2;b*=2(ll+n)(ll-n)/((ll+1)(2ll+1));c,{l,chunksize}],Method"Automatic"];s+=ctab.(xvals-1);start+=chunksize;st=SessionTime[]-T0;kc=k*chunksize;ti=(st)/(kc+10^-4)*(n)/(3600)/(24);Print[kc," iterations done in ",N[st,4]," seconds."," Should take ",N[ti,4]," days or ",N[ti*24*3600,4],"s, finish ",DatePlus[ds,ti],"."],{k,0,end-1}];N[-s/d,pr]];t2=Timing[MRBtest2=expM[prec];];Print["Finished on ",DateString[],". Proccessor time was ",t2[[1]]," s."];Print["Actual time was ",st];(*Print[*)MRBtest2(*]*)(*Remove(**)orenterMRBtest2toprintoutput*);Print["Enter MRBtest2 to print ",Floor[Precision[MRBtest2]]," digits"];Print["If you saved m3M, the difference between this and 3,014,991 known digits is ",N[MRBtest2-m3M,10]]
Start time is Mon 4 Jul 2022 04:28:40.
Iterations required: 132658
Will give 65 time estimates, each more accurate than the previous.
Will stop at 133120 iterations to ensure precsion of around 100499 decimal places.
0 iterations done in 11.59 seconds. Should take 1.780× days or 1.538×s, finish Wed 4 Dec 2509 02:02:10.
5
10
10
10
2048 iterations done in 24.30 seconds. Should take 0.01821 days or 1574.s, finish Mon 4 Jul 2022 04:54:53.
4096 iterations done in 37.11 seconds. Should take 0.01391 days or 1202.s, finish Mon 4 Jul 2022 04:48:41.
6144 iterations done in 50.04 seconds. Should take 0.01251 days or 1080.s, finish Mon 4 Jul 2022 04:46:40.
8192 iterations done in 63.01 seconds. Should take 0.01181 days or 1020.s, finish Mon 4 Jul 2022 04:45:40.
10240 iterations done in 76.09 seconds. Should take 0.01141 days or 985.8s, finish Mon 4 Jul 2022 04:45:05.
12288 iterations done in 89.31 seconds. Should take 0.01116 days or 964.1s, finish Mon 4 Jul 2022 04:44:44.
14336 iterations done in 102.6 seconds. Should take 0.01099 days or 949.3s, finish Mon 4 Jul 2022 04:44:29.
16384 iterations done in 115.7 seconds. Should take 0.01084 days or 937.0s, finish Mon 4 Jul 2022 04:44:17.
18432 iterations done in 128.9 seconds. Should take 0.01074 days or 927.8s, finish Mon 4 Jul 2022 04:44:07.
20480 iterations done in 142.1 seconds. Should take 0.01065 days or 920.5s, finish Mon 4 Jul 2022 04:44:00.
22528 iterations done in 155.5 seconds. Should take 0.01060 days or 915.9s, finish Mon 4 Jul 2022 04:43:55.
24576 iterations done in 168.7 seconds. Should take 0.01054 days or 910.5s, finish Mon 4 Jul 2022 04:43:50.
26624 iterations done in 181.8 seconds. Should take 0.01049 days or 906.0s, finish Mon 4 Jul 2022 04:43:46.
28672 iterations done in 195.0 seconds. Should take 0.01044 days or 902.3s, finish Mon 4 Jul 2022 04:43:42.
30720 iterations done in 208.4 seconds. Should take 0.01042 days or 899.9s, finish Mon 4 Jul 2022 04:43:39.
32768 iterations done in 221.5 seconds. Should take 0.01038 days or 896.5s, finish Mon 4 Jul 2022 04:43:36.
34816 iterations done in 234.7 seconds. Should take 0.01035 days or 894.1s, finish Mon 4 Jul 2022 04:43:34.
36864 iterations done in 247.8 seconds. Should take 0.01032 days or 891.9s, finish Mon 4 Jul 2022 04:43:31.
38912 iterations done in 261.2 seconds. Should take 0.01031 days or 890.5s, finish Mon 4 Jul 2022 04:43:30.
40960 iterations done in 274.5 seconds. Should take 0.01029 days or 888.9s, finish Mon 4 Jul 2022 04:43:28.
43008 iterations done in 287.8 seconds. Should take 0.01028 days or 887.8s, finish Mon 4 Jul 2022 04:43:27.
45056 iterations done in 301.1 seconds. Should take 0.01026 days or 886.7s, finish Mon 4 Jul 2022 04:43:26.
47104 iterations done in 314.6 seconds. Should take 0.01026 days or 886.1s, finish Mon 4 Jul 2022 04:43:26.
49152 iterations done in 327.9 seconds. Should take 0.01024 days or 885.1s, finish Mon 4 Jul 2022 04:43:25.
51200 iterations done in 341.3 seconds. Should take 0.01023 days or 884.2s, finish Mon 4 Jul 2022 04:43:24.
53248 iterations done in 354.7 seconds. Should take 0.01023 days or 883.6s, finish Mon 4 Jul 2022 04:43:23.
55296 iterations done in 368.2 seconds. Should take 0.01022 days or 883.4s, finish Mon 4 Jul 2022 04:43:23.
57344 iterations done in 381.5 seconds. Should take 0.01021 days or 882.5s, finish Mon 4 Jul 2022 04:43:22.
59392 iterations done in 394.9 seconds. Should take 0.01021 days or 881.9s, finish Mon 4 Jul 2022 04:43:21.
61440 iterations done in 408.2 seconds. Should take 0.01020 days or 881.3s, finish Mon 4 Jul 2022 04:43:21.
63488 iterations done in 421.7 seconds. Should take 0.01020 days or 881.1s, finish Mon 4 Jul 2022 04:43:21.
65536 iterations done in 434.7 seconds. Should take 0.01019 days or 880.0s, finish Mon 4 Jul 2022 04:43:19.