cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A062347 a(n) = (product of first n primes) modulo prime(n+1).

This page as a plain text file.
%I A062347 #31 Jun 30 2024 19:03:06
%S A062347 1,2,1,2,1,9,8,18,15,17,19,11,6,26,35,27,15,55,30,24,28,4,47,56,28,28,
%T A062347 75,25,105,30,9,52,111,89,46,132,53,97,104,106,42,94,158,184,155,5,6,
%U A062347 45,87,78,86,26,120,33,242,66,86,2,214,2,198,127,14,112,7,141,77,309
%N A062347 a(n) = (product of first n primes) modulo prime(n+1).
%H A062347 Alois P. Heinz, <a href="/A062347/b062347.txt">Table of n, a(n) for n = 0..10000</a> (first 1001 terms from Harry J. Smith)
%F A062347 a(n) = A051126(A002110(n), A000040(n+1)).
%e A062347 a(4)=1 since 2*3*5*7 = 210 = 19*11 + 1.
%t A062347 Mod[ #[ [ 1 ] ], #[ [ 2 ] ] ]&/@ Transpose[ {FoldList[ Times, 1, Prime[ Range[ 70 ] ] ], Prime[ Range[ 71 ] ]} ]
%t A062347 Join[{1},Module[{nn=70,prs},prs=Prime[Range[nn]];Table[Mod[Fold[Times,Take[prs,n-1]],prs[[n]]],{n,2,nn}]]] (* _Harvey P. Dale_, Jun 30 2024 *)
%o A062347 (PARI) { n=-1; f=1; forprime (p=2, prime(1001), write("b062347.txt", n++, " ", f%p); f*=p ) } \\ _Harry J. Smith_, Aug 05 2009
%o A062347 (Python) from sympy import sieve, primorial
%o A062347 print([1] + [primorial(k) % sieve[k+1] for k in range(1, 71)])
%o A062347 # _Karl-Heinz Hofmann_, Jan 26 2022
%Y A062347 Cf. A000040, A002110, A051126, A102647.
%K A062347 nonn
%O A062347 0,2
%A A062347 _Henry Bottomley_, Jul 06 2001