OFFSET
1,2
COMMENTS
LINKS
EXAMPLE
a(100) = a(3025) [= 66 as allotted by the rgs-transform] because 3025 = A003961(A003961(100)), therefore it is in the same column of the prime shift array A246278 as 100 is], and as A342671(100) = A342671(3025) = 7.
a(300) = a(21175) [= 200 as allotted by the rgs-transform], as 21175 = A003961(A003961(300)) and as A342671(300) = A342671(21175) = 7.
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; };
A003961(n) = { my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); };
A348717(n) = if(1==n, 1, my(f = factor(n), k = primepi(f[1, 1])-1); for (i=1, #f~, f[i, 1] = prime(primepi(f[i, 1])-k)); factorback(f));
v355833 = rgs_transform(vector(up_to, n, Aux355833(n)));
A355833(n) = v355833[n];
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jul 20 2022
STATUS
approved