login
Local minima of A053707 (first differences of A025475, powers of a prime but not prime).
3

%I #6 Aug 22 2023 21:54:06

%S 3,1,2,15,3,13,18,17,63,38,168,10,316,240,128,30,271,408,286,255,354,

%T 362,600,260,672,138,7,768,792,876,960,513,248,1080,546,2328,1248,

%U 4008,1392,751,2188,250,94,1728,3528,3470,1848,2460,3912,4008,3063,2088,1554

%N Local minima of A053707 (first differences of A025475, powers of a prime but not prime).

%C A053707(k) for k = 1 is a term iff A053707(k) <= A053707(k+1); A053707(k) for k > 1 is a term iff A053707(k-1) > A053707(k) and A053707(k) <= A053707(k+1).

%C A088364 gives the corresponding indices. Local maxima of A053707 are in A088365.

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

%e The first four terms of A053707 are 3,4,1,7, hence A053707(1) = 3 is the first and A053707(3) = 1 is the second local minimum of A053707.

%p N:= 10^6: # to use values of A025475 up to N

%p P:= select(isprime, [2,seq(i,i=3..isqrt(N),2)]):

%p B:= sort([1,seq(seq(p^i,i=2..ilog[p](N)),p=P)]):

%p DB:= B[2..-1]-B[1..-2]:

%p T:= select(t -> DB[t] <= DB[t-1] and DB[t] <= DB[t+1], [$2..nops(DB)-1]):

%p DB[[1,op(T)]]; # _Robert Israel_, Aug 21 2023

%o (PARI) {m=1; k=0; for(n=2,320000,if(matsize(factor(n))[1]==1&&factor(n)[1,2]>1,d=n-m; if((k<2||b>c)&&(!k<1&&d>=c),print1(c,",")); k++; m=n; b=c; c=d))}

%Y Cf. A025475, A053707, A088364, A088365.

%K nonn

%O 1,1

%A _Klaus Brockhaus_, Sep 27 2003