login
A325381
Lexicographically earliest sequence such that a(i) = a(j) => A048250(i) = A048250(j) and A126795(i) = A126795(j) for all i, j.
3
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, 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, 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
OFFSET
1,2
COMMENTS
Restricted growth sequence transform of the ordered pair [A048250(n), A126795(n)].
LINKS
PROG
(PARI)
up_to = 65537;
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; };
A048250(n) = factorback(apply(p -> p+1, factor(n)[, 1]));
A126795(n) = gcd(n, A048250(n));
v325381 = rgs_transform(vector(up_to, n, [A048250(n), A126795(n)]));
A325381(n) = v325381[n];
CROSSREFS
KEYWORD
nonn,look
AUTHOR
Antti Karttunen, May 08 2019
STATUS
approved