mersenneforum.org  

Go Back   mersenneforum.org > Factoring Projects > Aliquot Sequences

Reply
 
Thread Tools
Old 2021-09-14, 16:28   #100
Aillas
 
Aillas's Avatar
 
Oct 2002
France

15610 Posts
Default

EdH,

I have a question about the source code:
For open ended sequence, when looking for sequences that merge with

Line 884: for(j=seqn+1;j<seqscount;j++){

We are looking only for "greater" sequences that merge with it. Is it the expected behavior? Or should we start at first sequence (like line 1003 and another one)?
If I well understand, if sequence 1000 is open ended, we are looking for sequences > 1000 that merge with prime related to sequence 1000.

Or this is a bug and we should search the whole file?

Thanks
Aillas is offline   Reply With Quote
Old 2021-09-14, 20:18   #101
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

76418 Posts
Default

Quote:
Originally Posted by Aillas View Post
EdH,

I have a question about the source code:
For open ended sequence, when looking for sequences that merge with

Line 884: for(j=seqn+1;j<seqscount;j++){

We are looking only for "greater" sequences that merge with it. Is it the expected behavior? Or should we start at first sequence (like line 1003 and another one)?
If I well understand, if sequence 1000 is open ended, we are looking for sequences > 1000 that merge with prime related to sequence 1000.

Or this is a bug and we should search the whole file?

Thanks
I hope I understand your question. The regina_file has already taken the first occurrance of an o-e sequence into account and the first one will count as number 1. All others will increment in the regina_file as more merges are encountered. Instead of using the regina_file count, seqinfo2 should simply start counting at seq+1 for any matches to seq. I think that's what I'm doing with that line.

Let me know If I'm still unclear or if I'm off on this.

Thanks for the question.
EdH is offline   Reply With Quote
Old 2021-09-16, 11:32   #102
Aillas
 
Aillas's Avatar
 
Oct 2002
France

2348 Posts
Default

It's clear thanks.

Bad news, I was updating the code to manage the perfect number, and there is a comparison with a prime number that could not fit in an uint64_t (seqd[seqn].elD == "191561942608236107294793378084303638130997321548169216")

So I will try to update the code using double for this.

This field is only used for comparison, so I don't think it will introduce issues. I need to try. I let you know.
Aillas is offline   Reply With Quote
Old 2021-09-16, 13:33   #103
EdH
 
EdH's Avatar
 
"Ed Hall"
Dec 2009
Adirondack Mtns

4,001 Posts
Default

Thanks for keeping us up-to-date on your work.
EdH is offline   Reply With Quote
Old 2021-09-22, 12:16   #104
Happy5214
 
Happy5214's Avatar
 
"Alexander"
Nov 2008
The Alamo City

10111101102 Posts
Default

Quote:
Originally Posted by Aillas View Post
It's clear thanks.

Bad news, I was updating the code to manage the perfect number, and there is a comparison with a prime number that could not fit in an uint64_t (seqd[seqn].elD == "191561942608236107294793378084303638130997321548169216")

So I will try to update the code using double for this.

This field is only used for comparison, so I don't think it will introduce issues. I need to try. I let you know.
I don't think a double (53-bit mantissa) is enough precision for that number, and even a long double on x86 (which I believe gives you the 80-bit x87 extended-precision float, with a 64-bit mantissa) isn't an improvement over uint64_t. I tried converting that number to float and back in Python (using double-precision) and it didn't return the same number:

Code:
>>> float(191561942608236107294793378084303638130997321548169216)
1.915619426082361e+53
>>> int(_)
191561942608236107294793378393788647952342390272950272
>>> _-191561942608236107294793378084303638130997321548169216
309485009821345068724781056
Happy5214 is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Aliquot sequence reservations schickel Aliquot Sequences 3607 2021-10-19 20:45
Extending an aliquot sequence backwards arbooker Aliquot Sequences 11 2021-09-10 05:28
A new tool to identify aliquot sequence margins and acquisitions garambois Aliquot Sequences 24 2021-02-25 23:31
Another Aliquot Sequence site schickel Aliquot Sequences 67 2012-01-20 17:53
Useful aliquot-sequence links 10metreh Aliquot Sequences 2 2009-07-31 17:43

All times are UTC. The time now is 01:09.


Wed Oct 20 01:09:18 UTC 2021 up 88 days, 19:38, 0 users, load averages: 0.96, 1.06, 1.05

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.