login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A192504 Ludic nonprime numbers. 5

%I #17 Dec 10 2021 09:41:03

%S 1,25,77,91,115,119,121,143,161,175,209,221,235,247,265,287,301,329,

%T 341,361,377,407,415,437,445,475,481,493,497,517,527,535,553,565,581,

%U 595,625,667,685,697,703,707,749,775,791,803,805,835,841,851,865,893,913

%N Ludic nonprime numbers.

%H Reinhard Zumkeller, <a href="/A192504/b192504.txt">Table of n, a(n) for n = 1..1000</a>

%F A010051(a(n))*(1-A192490(a(n))) = 1.

%t a3309[nmax_] := a3309[nmax] = Module[{t = Range[2, nmax], k, r = {1}}, While[Length[t] > 0, k = First[t]; AppendTo[r, k]; t = Drop[t, {1, -1, k}]]; r];

%t ludicQ[n_, nmax_] /; 1 <= n <= nmax := MemberQ[a3309[nmax], n];

%t terms = 1000;

%t f[nmax_] := f[nmax] = Select[Range[nmax], ludicQ[#, nmax] && ! PrimeQ[#]&] // PadRight[#, terms]&;

%t f[nmax = terms];

%t f[nmax = 2 nmax];

%t While[f[nmax] != f[nmax/2], nmax = 2 nmax];

%t seq = f[nmax] (* _Jean-François Alcover_, Dec 10 2021, after _Ray CHandler_ in A003309 *)

%o (Haskell)

%o a192504 n = a192504_list !! (n-1)

%o a192504_list = filter ((== 0) . a010051) a003309_list

%o (PARI) A192504(maxn,bflag=0)={my(Vw=vector(maxn, x, x+1), Vl=Vec([1]), vwn=#Vw,i,vj,L=List());

%o while(vwn>0, i=Vw[1]; Vl=concat(Vl,[i]);

%o Vw=vector((vwn*(i-1))\i,x,Vw[(x*i+i-2)\(i-1)]); vwn=#Vw);

%o kill(Vw); vwn=#Vl;

%o for(j=1,vwn, vj=Vl[j]; if(!isprime(vj),listput(L,vj))); kill(Vw); vwn=#L;

%o if(bflag, for(i=1,vwn, print(i," ",L[i]))); if(!bflag, return(Vec(L)));

%o } \\ _Anatoly E. Voevudko_, Feb 28 2016

%Y Intersection of A018252 and A003309.

%Y Cf. A010051, A192490.

%Y Cf. A002808.

%K nonn

%O 1,2

%A _Reinhard Zumkeller_, Jul 05 2011

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 18:16 EDT 2024. Contains 371916 sequences. (Running on oeis4.)