login
Smallest prime power greater than the n-th prime.
5

%I #55 Oct 25 2024 11:44:22

%S 3,4,7,8,13,16,19,23,25,31,32,41,43,47,49,59,61,64,71,73,79,81,89,97,

%T 101,103,107,109,113,121,128,137,139,149,151,157,163,167,169,179,181,

%U 191,193,197,199,211,223,227,229,233,239,241,243,256,263,269,271,277

%N Smallest prime power greater than the n-th prime.

%C Take the family of correlated prime-indexed conjectures appearing in A343249 - A343253, in which an alternative formula for the p-adic order of positive integers is proposed. There, the general p-indexed conjecture says that v_p(n), the p-adic order of n, is given by the formula: v_p(n) = log_p(n / L_p(k0, n)), where L_p(k0, n) is the lowest common denominator of the elements of the set S_p(k0, n) = {(1/n)*binomial(n, k), with 0 < k <= k0 such that k is not divisible by p}. Evidence suggests that the primality of p is a necessary condition in this general conjecture. So, if a composite number q is used instead of a prime p in the proposed formula for the p-adic (now, q-adic) order of n, the first counterexample (failure) is expected to occur for n = q * a(i), where i is the index of the smallest prime that divides q.

%H Robert Israel, <a href="/A345531/b345531.txt">Table of n, a(n) for n = 1..10000</a>

%H Dario T. de Castro, <a href="http://math.colgate.edu/~integers/w61/w61.pdf">P-adic Order of Positive Integers via Binomial Coefficients</a>, INTEGERS, Electronic J. of Combinatorial Number Theory, Vol. 22, Paper A61, 2022.

%F a(n) = A000015(1+A000040(n)). - _Antti Karttunen_, Jul 19 2021

%F a(n) = A000015(A008864(n)). - _Omar E. Pol_, Oct 27 2021

%e a(4) = 8 because the fourth prime number is 7, and the least power of a prime which is greater than 7 is 2^3 = 8.

%p f:= proc(n) local p,x;

%p p:= ithprime(n);

%p for x from p+1 do

%p if nops(numtheory:-factorset(x)) = 1 then return x fi

%p od

%p end proc:

%p map(f, [$1..100]); # _Robert Israel_, Aug 25 2024

%t a[i_]:= Module[{j, k, N = 0, tab={}}, tab = Sort[Drop[DeleteDuplicates[Flatten[Table[ If[Prime[j]^k > Prime[i], Prime[j]^k], {j, 1, i+1}, {k, 1, Floor[Log[Prime[j], Prime[i+1]]]}]]], 1]]; N = Take[tab, 1][[1]]; N];

%t tabseq = Table[a[i],{i, 1, 100}];

%o (PARI)

%o A000015(n) = for(k=n,oo,if((1==k)||isprimepower(k),return(k)));

%o A345531(n) = A000015(1+prime(n)); \\ _Antti Karttunen_, Jul 19 2021

%o (Python)

%o from itertools import count

%o from sympy import prime, factorint

%o def A345531(n): return next(filter(lambda m:len(factorint(m))<=1, count(prime(n)+1))) # _Chai Wah Wu_, Oct 25 2024

%Y Cf. A000015, A000040, A007814, A007949, A008864, A343249, A343250, A112765, A343251, A214411, A343252, A343253.

%K nonn,changed

%O 1,1

%A _Dario T. de Castro_, Jun 20 2021