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.

A060359 a(n) = (smallest prime > k) - (largest prime < k), where k = lcm(1..n).

This page as a plain text file.
%I A060359 #19 Mar 20 2018 06:54:28
%S A060359 2,2,2,2,2,14,18,18,32,32,54,54,54,40,62,62,2,2,2,2,42,42,30,30,72,72,
%T A060359 44,44,44,42,42,42,42,42,96,96,96,96,126,126,142,142,142,142,2,2,142,
%U A060359 142,142,142,122,122,122,122,122,122,262,262,98,98
%N A060359 a(n) = (smallest prime > k) - (largest prime < k), where k = lcm(1..n).
%H A060359 Alois P. Heinz, <a href="/A060359/b060359.txt">Table of n, a(n) for n = 3..1020</a>
%F A060359 a(n) = A013633(A003418(n)). - _Michel Marcus_, Mar 20 2018
%p A060359 a:= n-> (m->nextprime(m)-prevprime(m))(ilcm($1..n)):
%p A060359 seq (a(n), n=3..100);
%t A060359 f[n_]:=Module[{lcmn=LCM@@Range[n]}, NextPrime[lcmn]-NextPrime[lcmn,-1]]; f/@Range[3,70]  (* _Harvey P. Dale_, Feb 04 2011 *)
%o A060359 (PARI) a(n) = my(lc = lcm([1..n])); nextprime(lc+1) - precprime(lc-1); \\ _Michel Marcus_, Mar 20 2018
%Y A060359 Cf. A003418, A013633, A060357, A060358.
%K A060359 nonn
%O A060359 3,1
%A A060359 _N. J. A. Sloane_, Apr 01 2001