1) remove consecutive entries between a(0)=0 and m-1 where m is the first missing value. This prevents the sieve from growing beyond resources to support it.
2) use an array instead of a hash -- if the index is numeric, it's an array.
3) calculate the rate of growth of the remaining sieve to test for convergence.
One world, one people
In reply to Re: Recamán's sequence and memory usage
by anonymized user 468275
in thread Recamán's sequence and memory usage
by Athanasius
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |