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

Smallest x such that remainder if x-th composite is divided by pi(x) equals n.
3

%I #15 May 21 2020 21:18:11

%S 4,7,8,13,30,17,35,23,40,50,53,51,55,52,63,60,68,69,146,76,154,83,156,

%T 162,172,177,185,109,195,187,192,188,189,190,208,209,210,214,215,216,

%U 217,230,218,219,220,224,225,251,248,249,250,255,256,262,267,280,289

%N Smallest x such that remainder if x-th composite is divided by pi(x) equals n.

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

%F a(n) = Min{x; Mod[A002808(x), A000720(x)]=n} = Min{x; A065861(x)=n}.

%e Remainder=4 appears first as Mod[c[13],Pi[13]]=Mod[22,6]=4, so a(4)=13.

%p N:= 100: m:= 1: V:= Vector(N): count:= 0:

%p for n from 6 while count < N do

%p if not isprime(n) then

%p m:= m+1;

%p t:= n mod numtheory:-pi(m);

%p if t > 0 and t <= N and V[t] = 0 then

%p count:= count+1; V[t]:= m

%p fi

%p fi

%p od:

%p convert(V,list); # _Robert Israel_, May 21 2020

%Y Cf. A000720, A002808, A065861.

%K nonn,look

%O 1,1

%A _Labos Elemer_, Jul 31 2002