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”).

Minimal difference between adjacent prime indices of n, or k if n is the k-th prime.
11

%I #8 Jul 11 2022 08:33:43

%S 1,2,0,3,1,4,0,0,2,5,0,6,3,1,0,7,0,8,0,2,4,9,0,0,5,0,0,10,1,11,0,3,6,

%T 1,0,12,7,4,0,13,1,14,0,0,8,15,0,0,0,5,0,16,0,2,0,6,9,17,0,18,10,0,0,

%U 3,1,19,0,7,1,20,0,21,11,0,0,1,1,22,0,0,12

%N Minimal difference between adjacent prime indices of n, or k if n is the k-th prime.

%C A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

%H Gus Wiseman, <a href="/A325325/a325325.txt">Sequences counting and ranking integer partitions by the differences of their successive parts.</a>

%e The prime indices of 9842 are {1,4,8,12}, with differences (3,4,4), so a(9842) = 3.

%t primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];

%t Table[If[PrimeQ[n],PrimePi[n],Min@@Differences[primeMS[n]]],{n,2,100}]

%Y Crossrefs found in the link are not repeated here.

%Y Positions of first appearances are 4 followed by A000040.

%Y Positions of 0's are A013929, see also A130091.

%Y Triangle A238709 counts m such that A056239(m) = n and a(m) = k.

%Y For maximal instead of minimal difference we have A286470.

%Y Positions of terms > 1 are A325160, also A325161.

%Y See also A355524, A355528.

%Y Positions of 1's are A355527.

%Y A001522 counts partitions with a fixed point (unproved), ranked by A352827.

%Y A238352 counts partitions by fixed points, rank statistic A352822.

%Y A287352, A355533, A355534, A355536 list the differences of prime indices.

%Y Cf. A066312, A120944, A238353, A279945, A286469, A325351, A325352, A351294, A355526, A355530, A355531, A355532.

%K nonn

%O 2,2

%A _Gus Wiseman_, Jul 10 2022