login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

The absolute difference between the largest prime factors of prime(n)-1 and prime(n+1)-1.
1

%I #27 Aug 08 2021 13:55:38

%S 0,1,2,2,1,1,8,4,2,2,2,2,16,10,16,24,6,4,4,10,28,30,8,2,12,36,50,4,0,

%T 6,4,6,14,32,8,10,80,40,46,84,14,16,4,4,4,30,76,94,10,12,12,0,3,129,

%U 64,62,18,16,40,26,56,14,18,66,68,4,166,144,18,168,118,30,24,184,94,86,6,12,2,12,36,40,70,56,10

%N The absolute difference between the largest prime factors of prime(n)-1 and prime(n+1)-1.

%C a(n)=0 if and only if n is in A105403.

%C It is an open question whether there are infinitely many zeros in this sequence. Are there infinitely many terms below some fixed upper bound?

%H Robert Israel, <a href="/A260360/b260360.txt">Table of n, a(n) for n = 2..10000</a>

%F a(n) = abs(A023503(n+1) - A023503(n)). - _Robert Israel_, Aug 06 2015

%e n=4: The prime factors of prime(4)-1 are 2,3 and the prime factors of prime(5)-1 are 2,5. The largest are 3 and 5, so a(4)=2.

%p B:= [seq(max(numtheory:-factorset(ithprime(i)-1)),i=2..101)]:

%p seq(abs(B[n+1]-B[n]),n=1..99); # _Robert Israel_, Aug 06 2015

%t Table[Abs[FactorInteger[Prime[n] - 1][[-1, 1]] - FactorInteger[Prime[n + 1] - 1][[-1, 1]]], {n, 2, 86}] (* _Michael De Vlieger_, Jul 24 2015 *)

%t Rest[Abs[Differences[Table[FactorInteger[p-1][[-1,1]],{p,Prime[ Range[ 90]]}]]]] (* _Harvey P. Dale_, Aug 08 2021 *)

%o (PARI) gpf(n) = if(n>1, vecmax(factor(n)[, 1]), 1);

%o a(n) = gpf(prime(n)-1) - gpf(prime(n+1)-1); \\ _Michel Marcus_, Aug 05 2015

%Y Cf. A023503, A105403.

%K nonn

%O 2,3

%A _Pratik Koirala_, _Otis Tweneboah_, _Nathan Fox_, _Eugene Fiorini_, Jul 23 2015