A075442
Slowest-growing sequence of primes whose reciprocals sum to 1.
Original entry on oeis.org
2, 3, 7, 43, 1811, 654149, 27082315109, 153694141992520880899, 337110658273917297268061074384231117039, 8424197597064114319193772925959967322398440121059128471513803869133407474043
Offset: 1
- R. K. Guy, Unsolved Problems in Number Theory, D11.
-
x=1; lst={}; Do[n=Ceiling[1/x]; If[PrimeQ[n], n++ ]; While[ !PrimeQ[n], n++ ]; x=x-1/n; AppendTo[lst, n], {10}]; lst
a[n_] := a[n] = Block[{sm = Sum[1/(a[i]), {i, n - 1}]}, NextPrime[ Max[ a[n - 1], 1/(1 - sm)]]]; a[0] = 1; Array[a, 10] (* Robert G. Wilson v, Oct 28 2010 *)
-
a(n)=if(n<3, return(prime(n))); my(x=1.); for(i=1,n-1,x-=1/a(i)); nextprime(1/x) \\ Charles R Greathouse IV, Apr 29 2015
-
a_vector(N=10)= my(r=1, v=vector(N)); for(i=1, N, v[i]= nextprime(1+1/r); r-= 1/v[i]); v; \\ Ruud H.G. van Tol, Jul 29 2023
A225671
Largest prime p(k) > p(n) such that 1/p(n) + 1/p(n+1) + ... + 1/p(k) < 1, where p(n) is the n-th prime.
Original entry on oeis.org
3, 23, 107, 337, 853, 1621, 2971, 4919, 7757, 11657, 16103, 22193, 29251, 37699, 48523, 61051, 75479, 91459, 110563, 131641, 155501, 183581, 214177, 248593, 286063, 325883, 369979, 419449, 473647, 534029, 600623, 667531, 739523, 816769, 900997, 988651, 1083613
Offset: 1
a(1) = 3 because 1/2 + 1/3 < 1 < 1/2 + 1/3 + 1/5 (or because the slowest-growing sequence of primes whose reciprocals sum to 1 is A075442 = 2, 3, 7, ...).
a(2) = 23 because 1/3 + 1/5 + 1/7 + 1/11 + 1/13 + 1/17 + 1/19 + 1/23 < 1 < 1/3 + 1/5 + 1/7 + 1/11 + 1/13 + 1/17 + 1/19 + 1/23 + 1/29 (or because the slowest-growing sequence of odd primes whose reciprocals sum to 1 is A225669 = 3, 5, 7, 11, 13, 17, 19, 23, 967, ...).
-
L = {1}; n = 0; Do[ k = Last[L]; n++; While[ Sum[ 1/Prime[i], {i, n, k}] < 1, k++]; L = Append[L, k - 1], {22}]; Prime[ Rest[L]]
-
from sympy import prime
def A225671(n):
xn, xd, k, p = 1, prime(n), n, prime(n)
while xn < xd:
k += 1
po, p = p, prime(k)
xn = xn*p + xd
xd *= p
return po # Chai Wah Wu, Apr 20 2015
A225670
Slowest-growing sequence of odd primes p where 1/(p+1) sums to 1 without actually reaching it.
Original entry on oeis.org
3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 53, 2539, 936599, 127852322431, 510819260848900502567, 1553192364608434843485965159509450536731, 52119893982548112392303882371161186032080710958633917215400463948724068502699
Offset: 1
-
a[n_] := a[n] = Block[ {sm = Sum[ 1/(a[i] + 1), {i, n - 1}]}, NextPrime[ Max[ a[n - 1], 1/(1 - sm)]]]; a[0] = 2; Array[ a, 20]
Showing 1-3 of 3 results.
Comments