[seqfan] Re: Mma code snippets in some prime modulo sequences

Alonso Del Arte alonso.delarte at gmail.com
Wed Apr 28 00:22:23 CEST 2010


It looks valid but I'm not a computer with Mathematica on it right now. It's
not  the form I would use (I would probably go with Select rather than
Position) but then again I tend to go for more verbose commands.

Flatten [ Position [ [Prime Q [210 Range [100] +19], True ] ]

should give the n such that 210n + 19 is prime, assuming that part was done
correctly. Then it's a simple matter of multiplying by 210 and adding 19,
just as the Mathematica command given does.

This code, as I understand it, checks the primality of the numbers 19, 229,
... 21019. So I too would suspect there should be more terms, even if not
enough for four lines. What are the odds this formula would give no primes
whatsoever for 46 < n < 100 ?

Al

On Tue, Apr 27, 2010 at 5:52 PM, Richard Mathar
<mathar at strw.leidenuniv.nl>wrote:

>
> Do A140842, A140843 etc contain valid Mathematica code?
> Someone having actually run the code would probably have submitted
> more terms....
> I don't have Mma and cannot judge that sort of thing.
>
> RJM
>
>
> _______________________________________________
>
> Seqfan Mailing list - http://list.seqfan.eu/
>



More information about the SeqFan mailing list