

A289626


Restricted growth sequence transform of A289625, related to the structure of multiplicative group of integers modulo n.


15



1, 1, 2, 2, 3, 2, 4, 5, 4, 3, 6, 5, 7, 4, 8, 8, 9, 4, 10, 8, 11, 6, 12, 13, 14, 7, 10, 11, 15, 8, 16, 17, 18, 9, 19, 11, 20, 10, 19, 21, 22, 11, 23, 18, 19, 12, 24, 21, 23, 14, 25, 19, 26, 10, 27, 28, 29, 15, 30, 21, 31, 16, 32, 25, 33, 18, 34, 25, 35, 19, 36, 28, 37, 20, 27, 29, 38, 19, 39, 40, 41, 22, 42, 28, 43, 23, 44, 45, 46, 19, 47, 35, 38, 24, 48, 49
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,3


LINKS

Antti Karttunen, Table of n, a(n) for n = 1..16384


PROG

(PARI)
rgs_transform(invec) = { my(occurrences = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(occurrences, invec[i]), my(pp = mapget(occurrences, invec[i])); outvec[i] = outvec[pp] , mapput(occurrences, invec[i], i); outvec[i] = u; u++ )); outvec; };
write_to_bfile(start_offset, vec, bfilename) = { for(n=1, length(vec), write(bfilename, (n+start_offset)1, " ", vec[n])); }
A289625(n) = { my(m=1, p=2, v=znstar(n)[2]); for(i=1, length(v), m *= p^v[i]; p = nextprime(p+1)); (m); };
write_to_bfile(1, rgs_transform(vector(16384, n, A289625(n))), "b289626_upto16384.txt");


CROSSREFS

Cf. A289625, A101296.
Cf. A000010, A002322, A034380, A046072, A289624 (some of the matching sequences).
Sequence in context: A305820 A272831 A290076 * A097004 A324343 A328474
Adjacent sequences: A289623 A289624 A289625 * A289627 A289628 A289629


KEYWORD

nonn


AUTHOR

Antti Karttunen, Jul 18 2017


STATUS

approved



