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.
%I A034386 #144 Feb 16 2025 08:32:37 %S A034386 1,1,2,6,6,30,30,210,210,210,210,2310,2310,30030,30030,30030,30030, %T A034386 510510,510510,9699690,9699690,9699690,9699690,223092870,223092870, %U A034386 223092870,223092870,223092870,223092870,6469693230,6469693230,200560490130,200560490130 %N A034386 Primorial numbers (second definition): n# = product of primes <= n. %C A034386 Squarefree kernel of both n! and lcm(1, 2, 3, ..., n). %C A034386 a(n) = lcm(core(1), core(2), core(3), ..., core(n)) where core(x) denotes the squarefree part of x, the smallest integer such that x*core(x) is a square. - _Benoit Cloitre_, May 31 2002 %C A034386 The sequence can also be obtained by taking a(1) = 1 and then multiplying the previous term by n if n is coprime to the previous term a(n-1) and taking a(n) = a(n-1) otherwise. - _Amarnath Murthy_, Oct 30 2002; corrected by _Franklin T. Adams-Watters_, Dec 13 2006 %D A034386 Steven R. Finch, Mathematical Constants, Cambridge, 2003, Section 1.3, p. 14, "n?". %D A034386 József Sándor, Dragoslav S. Mitrinovic, Borislav Crstici, Handbook of Number Theory I, Springer Science & Business Media, 2005, Section VII.35, p. 268. %H A034386 Alois P. Heinz, <a href="/A034386/b034386.txt">Table of n, a(n) for n = 0..2370</a> (first 401 terms from T. D. Noe) %H A034386 Jens Askgaard, <a href="https://arxiv.org/abs/1902.06299">On the additive period length of the Sprague-Grundy function of certain Nim-like games</a>, arXiv:1902.06299 [math.CO], 2019. %H A034386 Klaus Dohmen and Martin Trinks, <a href="http://arxiv.org/abs/1404.5480">An Abstraction of Whitney's Broken Circuit Theorem</a>, arXiv:1404.5480 [math.CO], 2014. %H A034386 Romeo Meštrović, <a href="http://arxiv.org/abs/1202.3670">Euclid's theorem on the infinitude of primes: a historical survey of its proofs (300 BC--2012) and another new proof</a>, arXiv:1202.3670 [math.HO], 2012. - From _N. J. A. Sloane_, Jun 13 2012 %H A034386 J. Barkley Rosser and Lowell Schoenfeld, <a href="http://doi.org/10.1215/ijm/1255631807">Approximate formulas for some functions of prime numbers</a>, Illinois J. Math., Vol. 6, No. 1 (1962), 64-94. %H A034386 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Primorial.html">Primorial</a>. %F A034386 a(n) = n# = A002110(A000720(n)) = A007947(A003418(n)) = A007947(A000142(n)). %F A034386 Asymptotic expression for a(n): exp((1 + o(1)) * n) where o(1) is the "little o" notation. - Dan Fux (dan.fux(AT)OpenGaia.com or danfux(AT)OpenGaia.com), Apr 08 2001 %F A034386 For n > 0, log(a(n)) < 1.01624*n. [Rosser and Schoenfeld, 1962; Sándor et al., 2005] - _N. J. A. Sloane_, Apr 04 2017 %F A034386 a(n) <= A179215(n). - _Reinhard Zumkeller_, Jul 05 2010 %F A034386 a(n) = lcm(A006530(n), a(n-1)). - _Jon Maiga_, Nov 10 2018 %F A034386 Sum_{n>=0} 1/a(n) = A249270. - _Amiram Eldar_, Nov 08 2020 %e A034386 a(5) = a(6) = 2*3*5 = 30; %e A034386 a(7) = 2*3*5*7 = 210. %p A034386 A034386 := n -> mul(k,k=select(isprime,[$1..n])); # _Peter Luschny_, Jun 19 2009 %p A034386 # second Maple program: %p A034386 a:= proc(n) option remember; `if`(n=0, 1, %p A034386 `if`(isprime(n), n, 1)*a(n-1)) %p A034386 end: %p A034386 seq(a(n), n=0..36); # _Alois P. Heinz_, Nov 26 2020 %t A034386 q[x_]:=Apply[Times,Table[Prime[w],{w,1,PrimePi[x]}]]; Table[q[w],{w,1,30}] %t A034386 With[{pr=FoldList[Times,1,Prime[Range[20]]]},Table[pr[[PrimePi[n]+1]],{n,0,40}]] (* _Harvey P. Dale_, Apr 05 2012 *) %t A034386 Table[ResourceFunction["Primorial"][i], {i,1,40}] (* _Navvye Anand_, May 22 2024 *) %o A034386 (PARI) a(n)=my(v=primes(primepi(n)));prod(i=1,#v,v[i]) \\ _Charles R Greathouse IV_, Jun 15 2011 %o A034386 (PARI) a(n)=lcm(primes([2,n])) \\ _Jeppe Stig Nielsen_, Mar 10 2019 %o A034386 (SageMath) %o A034386 def sharp_primorial(n): return sloane.A002110(prime_pi(n)) %o A034386 [sharp_primorial(n) for n in (0..30)] # _Giuseppe Coppoletta_, Jan 26 2015 %o A034386 (Python) %o A034386 from sympy import primorial %o A034386 def A034386(n): return 1 if n == 0 else primorial(n,nth=False) # _Chai Wah Wu_, Jan 11 2022 %o A034386 (Magma) [n eq 0 select 1 else LCM(PrimesInInterval(1, n)) : n in [0..50]]; // _G. C. Greubel_, Jul 21 2023 %Y A034386 Cf. A002110, A057872, A249270. %Y A034386 Cf. A073838, A034387. - _Reinhard Zumkeller_, Jul 05 2010 %Y A034386 The following fractions are all related to each other: Sum 1/n: A001008/A002805, Sum 1/prime(n): A024451/A002110 and A106830/A034386, Sum 1/nonprime(n): A282511/A282512, Sum 1/composite(n): A250133/A296358. %K A034386 nonn,easy,nice %O A034386 0,3 %A A034386 _N. J. A. Sloane_ %E A034386 Offset changed and initial term added by _Arkadiusz Wesolowski_, Jun 04 2011