cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A322861 Lexicographically earliest such sequence a that a(i) = a(j) => A278222(A285330(i)) = A278222(A285330(j)) for all i, j.

This page as a plain text file.
%I A322861 #8 Dec 31 2018 13:22:25
%S A322861 1,2,2,2,2,3,2,2,3,4,2,3,2,4,3,2,2,3,2,4,4,4,2,4,4,4,4,5,2,5,2,2,4,4,
%T A322861 3,3,2,4,4,4,2,6,2,6,7,4,2,4,5,4,4,6,2,3,4,5,4,4,2,7,2,4,8,2,4,6,2,4,
%U A322861 4,6,2,9,2,4,10,6,3,6,2,6,9,4,2,8,4,4,4,6,2,7,4,11,4,4,4,4,2,5,4,4,2,6,2,6,5
%N A322861 Lexicographically earliest such sequence a that a(i) = a(j) => A278222(A285330(i)) = A278222(A285330(j)) for all i, j.
%C A322861 Restricted growth sequence transform of A278222(A285330(n)).
%C A322861 For all i, j:
%C A322861   A322806(i) = A322806(j) => a(i) = a(j),
%C A322861   A322807(i) = A322807(j) => a(i) = a(j),
%C A322861   a(i) = a(j) => A322862(i) = A322862(j).
%H A322861 Antti Karttunen, <a href="/A322861/b322861.txt">Table of n, a(n) for n = 1..65537</a>
%H A322861 <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>
%H A322861 <a href="/index/Pri#prime_indices">Index entries for sequences computed from indices in prime factorization</a>
%o A322861 (PARI)
%o A322861 up_to = 65537;
%o A322861 rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
%o A322861 A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t };
%o A322861 A007947(n) = factorback(factorint(n)[, 1]); \\ From A007947
%o A322861 A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ From A046523
%o A322861 A048675(n) = my(f = factor(n)); sum(k=1, #f~, f[k, 2]*2^primepi(f[k, 1]))/2; \\ From A048675
%o A322861 A285328(n) = { my(r); if((n > 1 && !bitand(n,(n-1))), (n/2), r=A007947(n); if(r==n,1,n = n-r; while(A007947(n) <> r, n = n-r); n)); };
%o A322861 A285330(n) = if(moebius(n)<>0,A048675(n),A285328(n));
%o A322861 A278222(n) = A046523(A005940(1+n));
%o A322861 v322861 = rgs_transform(vector(up_to,n,A278222(A285330(n))));
%o A322861 A322861(n) = v322861[n];
%Y A322861 Cf. A048675, A278222, A285330, A286622, A322806, A322807, A322862, A322868.
%K A322861 nonn
%O A322861 1,2
%A A322861 _Antti Karttunen_, Dec 31 2018