meditationatae

Just another WordPress.com site

highly abundant numbers: new updated PARI/gp command line

### After my last post, i worked to save arithmetic computations.
### The possibility (primorial(m) replaced by primorial(m+1))
### is tested tentatively for about 28 or 28 candidate
### “primorial factors” which multiply to give ‘n’.
### The candidate with the highest figure of merit
### “wins the day” cf. previous post.

### Now, I recall the last command-line:
### niter = 1,000,000
### about 0.2 seconds to test 30 candidates as:  for(X=1,30,  ETC.
### ‘www’ printed every 5 loops, about every 1.1 seconds.

? for(YYY = 1, niter, for(ZZZZ=1,5, thebest = 0;  nowpower=vector(30);  for(X=1,30, nowpower[X] = sum(Z=1,100, www[Z] >www[X]  ));  testprime=vector(30);  for(X=1,30, testprime[X] = prime(www[X]+1));testcpp=vector(30);for(X=1,30,testcpp[X]=newcpp*testprime[X]);  testsigcpp = vector(30);  for(X=1, 30, testsigcpp[X] = newsigcpp*(sum(Y=0, nowpower[X]+1, testprime[X]^Y)/sum(Y=0, nowpower[X], testprime[X]^Y) )  ) ;   cst = base*newsigcpp/( harmonic(newcpp) + log(harmonic(newcpp))*exp(harmonic(newcpp)) ) ; rat=vector(30); for(X=1,30, rat[X] = base*testsigcpp[X]/(harmonic(testcpp[X]) + log(harmonic(testcpp[X]))*exp(harmonic(testcpp[X])  )   )   );  for(X=1,30, newr2 = rat[X]; if(newr2>cst, cst=newr2; thebest = X) );  if(thebest>0, newcpp = testcpp[thebest]; newsigcpp=testsigcpp[thebest]; www[thebest]=www[thebest]+1);  if(thebest>0, print(thebest,”   “, rat[thebest]) )  );  print(www)   )  

 

### The partial output appears below.

1   9999.9139076643064172392080219103741950
1   9999.9139076943078667964663371974347498
1   9999.9139077241965663313941005444953985
1   9999.9139077541002420005797266774611479
1   9999.9139077836868072249514374304685985
[1787102, 942, 84, 26, 13, 9, 6, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
1   9999.9139078131095335163771911766555881
1   9999.9139078426494165378658993315364589
1   9999.9139078718721913320138048953407478
1   9999.9139079009566734713760454263137214
1   9999.9139079302349468421492999007888716
[1787107, 942, 84, 26, 13, 9, 6, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
1   9999.9139079595026521050772539518801217
1   9999.9139079888364238255615464603291898
1   9999.9139080182618067032481491021139859
1   9999.9139080477532557569641688855306483
1   9999.9139080770042336534642806520494734
[1787112, 942, 84, 26, 13, 9, 6, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
1   9999.9139081062957330138723587699305656
1   9999.9139081356788431554313178843710627
1   9999.9139081652046532847201896680126333
^C  ***   at top-level: …t[X]=base*testsigcpp[X]/(harmonic(testcpp[X])
  ***                                             ^——————–
  ***   in function harmonic: Euler+psi(Z+1)
  ***                               ^——–
  *** psi: user interrupt after 13h, 54min, 48,224 ms.

  ***   Break loop: type <Return> to continue; ‘break’ to go back to GP
break> break

### Now, I recall the last command-line:
### niter = 1,000,000
### about 0.2 seconds to test 30 candidates as:  for(X=1,30,  ETC.
### ‘www’ printed every 5 loops, about every 1.1 seconds.

? for(YYY = 1, niter, for(ZZZZ=1,5, thebest = 0;  nowpower=vector(30);  for(X=1,30, nowpower[X] = sum(Z=1,100, www[Z] >www[X]  ));  testprime=vector(30);  for(X=1,30, testprime[X] = prime(www[X]+1));testcpp=vector(30);for(X=1,30,testcpp[X]=newcpp*testprime[X]);  testsigcpp = vector(30);  for(X=1, 30, testsigcpp[X] = newsigcpp*(sum(Y=0, nowpower[X]+1, testprime[X]^Y)/sum(Y=0, nowpower[X], testprime[X]^Y) )  ) ;   cst = base*newsigcpp/( harmonic(newcpp) + log(harmonic(newcpp))*exp(harmonic(newcpp)) ) ; rat=vector(30); for(X=1,30, rat[X] = base*testsigcpp[X]/(harmonic(testcpp[X]) + log(harmonic(testcpp[X]))*exp(harmonic(testcpp[X])  )   )   );  for(X=1,30, newr2 = rat[X]; if(newr2>cst, cst=newr2; thebest = X) );  if(thebest>0, newcpp = testcpp[thebest]; newsigcpp=testsigcpp[thebest]; www[thebest]=www[thebest]+1);  if(thebest>0, print(thebest,”   “, rat[thebest]) )  );  print(www)   )   

Advertisements

Written by meditationatae

July 28, 2013 at 2:23 pm

Posted in History

3 Responses

Subscribe to comments with RSS.

  1. Unfortunately, as a result of stopping the loops with Ctrl-C, newcpp now
    has no value. ‘newcpp’ is the base case of the product of all 28 primorials. As a result, ‘newcpp’ must be recomputed from the data (that fully describes the primorials) in the vector www, printed every 5 loops. Also, newsigcpp, which is the sum of divisors function for the number newcpp, is probably also lost (no value).

    meditationatae

    July 28, 2013 at 2:47 pm

  2. It’s been fixed. I now save log(newcpp) and log(newsigcpp) in www[99] and www[100] every 5 loops. Every 5 loops, www, a 100-long vector, gets printed.

    meditationatae

    July 29, 2013 at 12:31 am

  3. I meant to copy/paste the new command-line and some output. The trouble is that the output goes by too fast. The output is still being written to file, this is always possible in a PARI/gp session … 🙂

    meditationatae

    July 29, 2013 at 12:42 am


Comments are closed.

%d bloggers like this: