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.

A322023 Lexicographically earliest such sequence a that a(i) = a(j) => A081373(i) = A081373(j) and A303756(i) = A303756(j), for all i, j. Here A081373 and A303756 are the ordinal transforms of Euler phi and Carmichael lambda.

This page as a plain text file.
%I A322023 #9 Dec 02 2018 20:53:26
%S A322023 1,2,1,2,1,3,1,4,2,5,1,6,1,3,7,4,1,8,1,9,10,2,1,11,1,5,2,11,1,12,1,13,
%T A322023 14,5,7,15,1,3,4,16,1,17,1,18,9,2,1,19,2,20,7,11,1,8,14,21,10,2,1,22,
%U A322023 1,2,23,4,24,25,1,9,7,17,1,26,1,20,18,12,14,27,1,28,1,20,1,29,30,3,7,12,1,31,32,4,18,2,3,33,1,8,6,34,1,35,1,36,37
%N A322023 Lexicographically earliest such sequence a that a(i) = a(j) => A081373(i) = A081373(j) and A303756(i) = A303756(j), for all i, j. Here A081373 and A303756 are the ordinal transforms of Euler phi and Carmichael lambda.
%C A322023 Restricted growth sequence transform of the ordered pair [A081373(n), A303756(n)].
%H A322023 Antti Karttunen, <a href="/A322023/b322023.txt">Table of n, a(n) for n = 1..65537</a>
%o A322023 (PARI)
%o A322023 up_to = 65537;
%o A322023 ordinal_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), pt); for(i=1, length(invec), if(mapisdefined(om,invec[i]), pt = mapget(om, invec[i]), pt = 0); outvec[i] = (1+pt); mapput(om,invec[i],(1+pt))); outvec; };
%o A322023 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 A322023 A002322(n) = lcm(znstar(n)[2]); \\ From A002322
%o A322023 v081373 = ordinal_transform(vector(up_to,n,eulerphi(n)));
%o A322023 A081373(n) = v081373[n];
%o A322023 v303756 = ordinal_transform(vector(up_to,n,A002322(n)));
%o A322023 A303756(n) = v303756[n];
%o A322023 v322023 = rgs_transform(vector(up_to, n, [A081373(n), A303756(n)]));
%o A322023 A322023(n) = v322023[n];
%Y A322023 Cf. A000010, A002322, A081373, A303756, A319339, A322024, A322025 (ordinal transform).
%K A322023 nonn
%O A322023 1,2
%A A322023 _Antti Karttunen_, Nov 29 2018