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.

A325381 Lexicographically earliest sequence such that a(i) = a(j) => A048250(i) = A048250(j) and A126795(i) = A126795(j) for all i, j.

This page as a plain text file.
%I A325381 #13 May 10 2019 13:03:02
%S A325381 1,2,3,2,4,5,6,2,3,7,8,9,10,11,12,2,13,5,14,7,15,16,17,9,4,18,3,19,20,
%T A325381 21,15,2,22,23,24,9,25,26,27,7,28,29,30,31,12,32,24,9,6,7,33,18,34,5,
%U A325381 35,36,37,38,39,40,41,42,15,2,43,44,45,23,46,47,35,9,48,49,12,50,51,52,37,7,3,53,43,54,55,56,57,31,58,59,60,61,62,47,63,9,64,11
%N A325381 Lexicographically earliest sequence such that a(i) = a(j) => A048250(i) = A048250(j) and A126795(i) = A126795(j) for all i, j.
%C A325381 Restricted growth sequence transform of the ordered pair [A048250(n), A126795(n)].
%H A325381 Antti Karttunen, <a href="/A325381/b325381.txt">Table of n, a(n) for n = 1..65537</a>
%o A325381 (PARI)
%o A325381 up_to = 65537;
%o A325381 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 A325381 A048250(n) = factorback(apply(p -> p+1,factor(n)[,1]));
%o A325381 A126795(n) = gcd(n,A048250(n));
%o A325381 v325381 = rgs_transform(vector(up_to,n,[A048250(n),A126795(n)]));
%o A325381 A325381(n) = v325381[n];
%Y A325381 Cf. A048250, A126795, A291751, A325382, A325383.
%K A325381 nonn,look
%O A325381 1,2
%A A325381 _Antti Karttunen_, May 08 2019