A060882
a(n) = n-th primorial (A002110) minus next prime.
Original entry on oeis.org
-1, -1, 1, 23, 199, 2297, 30013, 510491, 9699667, 223092841, 6469693199, 200560490093, 7420738134769, 304250263527167, 13082761331669983, 614889782588491357, 32589158477190044671, 1922760350154212639009
Offset: 0
- R. Honsberger, Mathematical Diamonds, MAA, 2003, see p. 79. [Added by N. J. A. Sloane, Jul 05 2009]
-
pp:=n->mul(ithprime(i),i=1..n);
[seq(pp(n)-ithprime(n+1),n=1..20)];
-
Join[{-1},With[{nn=20},#[[1]]-#[[2]]&/@Thread[{FoldList[Times,1, Prime[ Range[nn]]],Prime[Range[nn+1]]}]]] (* Harvey P. Dale, May 10 2013 *)
-
{ n=-1; m=1; forprime (p=2, prime(101), write("b060882.txt", n++, " ", m - p); m*=p; ) } \\ Harry J. Smith, Jul 13 2009
-
from sympy import prime, primorial
def A060882(n): return primorial(n)-prime(n+1) if n else -1 # Chai Wah Wu, Feb 25 2023
A360510
a(n) = Product_{i=2..n} p(i) - p(n+1)^2, where p(i) is the i-th prime.
Original entry on oeis.org
-8, -22, -34, -16, 986, 14726, 254894, 4849316, 111545594, 3234845654, 100280243696, 3710369065724, 152125131761756, 6541380665832806, 307444891294242896, 16294579238595018884, 961380175077106315814, 58644190679703485487146, 3929160775540133527934504, 278970415063349480483702366
Offset: 1
- S. W. Golomb, Elementary Problem E3137, Amer. Math. Monthly, Proposed 93 (1986), p. 215; Solution and Editorial Comments, 94 (1987), 883-884.
-
FoldList[Times, 1, Most[#]] - #^2 & [Prime[Range[2, 25]]] (* Paolo Xausa, Nov 06 2024 *)
-
from sympy import prime, primorial
def A360510(n): return (primorial(n)>>1)-prime(n+1)**2 # Chai Wah Wu, Feb 24 2023
A360511
a(n) = Product_{i=1..n} p(i) - p(n+1)^3, where p(i) is the i-th prime.
Original entry on oeis.org
-25, -119, -313, -1121, 113, 25117, 503651, 9687523, 223068481, 6469663439, 200560439477, 7420738065889, 304250263447703, 13082761331566207, 614889782588342533, 32589158477189839351, 1922760350154212412089, 117288381359406970682507, 7858321551080267055521179, 557940830126698960967026373
Offset: 1
- S. W. Golomb, Elementary Problem E3137, Amer. Math. Monthly, Proposed 93 (1986), p. 215; Solution and Editorial Comments, 94 (1987), 883-884.
-
FoldList[Times, Most[#]] - Rest[#]^3 & [Prime[Range[25]]] (* Paolo Xausa, Nov 06 2024 *)
-
from sympy import prime, primorial
def A360511(n): return primorial(n)-prime(n+1)**3 # Chai Wah Wu, Feb 24 2023
A382834
Smallest number k > P(n) - prime(n+1)^2 which is coprime to P(n), where P(n)= A002110(n) are the primorials.
Original entry on oeis.org
-5, -17, -17, 97, 2143, 29747, 510151, 9699167, 223092031, 6469692277, 200560488763, 7420738133141, 304250263525363, 13082761331667823, 614889782588488607, 32589158477190041261, 1922760350154212635351, 117288381359406970978787, 7858321551080267055874051
Offset: 1
a(4) = 97, since 2*3*5*7 - 11^2 = 89, the smallest number coprime to 2*3*5*7 greater than 89 is 97.
a(2) = -17, since 2*3 - 5^2 = -19, the smallest number x>-19 coprime here is thus -17, and its difference d = 30 -(-17) = 47 is the largest prime < 7^2.
-
a(n) = my(P=vecprod(primes(n)), k=P-prime(n+1)^2+1); while (gcd(k,P)!=1, k++); k; \\ Michel Marcus, Apr 07 2025
Showing 1-4 of 4 results.
Comments