login
A328395
Lexicographically earliest infinite sequence such that a(i) = a(j) => A046523(A276087(i)) = A046523(A276087(j)) for all i, j.
4
1, 1, 2, 1, 3, 4, 5, 5, 6, 1, 7, 4, 8, 9, 10, 11, 7, 5, 12, 7, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 2, 5, 9, 5, 6, 8, 6, 23, 24, 1, 25, 4, 26, 27, 28, 11, 29, 8, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 9, 9, 42, 12, 24, 12, 7, 43, 44, 45, 46, 47, 48, 27, 49, 33, 50, 35, 51, 52, 53, 54, 55, 56, 57, 58, 59, 20, 60, 61, 30, 27, 62, 63, 64, 65, 66, 15, 67, 68, 69, 8
OFFSET
0,3
COMMENTS
Restricted growth sequence transform of function f(n) = A278226(A276086(n)) = A046523(A276086(A276086(n))).
For all i, j:
a(i) = a(j) => A328397(i) = A328397(j) => A328389(i) = A328389(j).
PROG
(PARI)
up_to = 32589;
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; };
A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); }; \\ From A046523
A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
v328395 = rgs_transform(vector(1+up_to, n, A046523(A276087(n-1))));
A328395(n) = v328395[1+n];
CROSSREFS
Cf. A143293 (positions of 1's after the initial one).
Sequence in context: A082470 A101204 A169808 * A283069 A304528 A360585
KEYWORD
nonn
AUTHOR
Antti Karttunen, Oct 15 2019
STATUS
approved