[seqfan] Re: https://oeis.org/A254211 Finite?

Benoît Jubin benoit.jubin at gmail.com
Thu Jan 29 10:50:34 CET 2015


Dear Maximilian,
Your new sequence could be cross-referenced with A153136 and
references therein (where injectivity was implied). For its
definition, I'd prefer "...such that no sum of consecutive terms is
prime".
Benoît

On Thu, Jan 29, 2015 at 6:27 AM, M. F. Hasler <seqfan at hasler.fr> wrote:
>> Am 27.01.2015 um 12:26 schrieb Ron Hardin:
>>> Right, the every partial sum from either end is never prime.
>
> This inspired me https://oeis.org/draft/A254337
>
> Lexicographic first sequence such that a(k)+...+a(n) is never prime
> and all terms are different.
>
> 0, 1, 8, 6, 10, 14, 12, 4, 20, 16, 24, 18, 22, 28, 26, 34, 30, 32, 36,
> 40, 42, ...
>
> The sequence may not contain any prime. Does it contain all even
> numbers > 2? (It seems so.) Does it contain any odd number beyond 1?
> (It seems not.)
>
> (PARI)
> {a=[m=L=u=0];for(i=1,99, print1(a[i]","); u+=2^a[i];
> m==a[i] && while(isprime(m++)||bittest(u,m),); a=concat(a,m);
> until( 0,  s=a[k=i+1]; while( k>1 && ! isprime( s+=a[k--]),);
> isprime(s) || break;while( isprime(a[i+1]++) || bittest(u,a[i+1]),);))}
>
> --
> Maximilian
>
> _______________________________________________
>
> Seqfan Mailing list - http://list.seqfan.eu/



More information about the SeqFan mailing list