VOOZH about

URL: https://oeis.org/A379004

⇱ A379004 - OEIS


login
A379004
Lexicographically earliest infinite sequence such that a(i) = a(j) => v_2(i) = v_2(j) and v_5(i) = v_5(j), for all i, j, where v_2 (A007814) and v_5 (A112765) give the 2- and 5-adic valuations of n respectively.
4
1, 2, 1, 3, 4, 2, 1, 5, 1, 6, 1, 3, 1, 2, 4, 7, 1, 2, 1, 8, 1, 2, 1, 5, 9, 2, 1, 3, 1, 6, 1, 10, 1, 2, 4, 3, 1, 2, 1, 11, 1, 2, 1, 3, 4, 2, 1, 7, 1, 12, 1, 3, 1, 2, 4, 5, 1, 2, 1, 8, 1, 2, 1, 13, 4, 2, 1, 3, 1, 6, 1, 5, 1, 2, 9, 3, 1, 2, 1, 14, 1, 2, 1, 3, 4, 2, 1, 5, 1, 6, 1, 3, 1, 2, 4, 10, 1, 2, 1, 15, 1, 2, 1, 5, 4
OFFSET
1,2
COMMENTS
Restricted growth sequence transform of A132741, or equally, of the ordered pair [A007814(n), A112765(n)].
For all i, j:
A379005(i) = A379005(j) => a(i) = a(j).
A379003 (after its initial 0) and this sequence are ordinal transforms of each other.
LINKS
PROG
(PARI)
up_to = 100000;
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; };
v379004 = rgs_transform(vector(up_to, n, [valuation(n, 2), valuation(n, 5)]));
A379004(n) = v379004[n];
CROSSREFS
Cf. A007814, A112765, A132741, A379003 (ordinal transform), A379005.
Sequence in context: A133923 A347296 A341231 * A334081 A125158 A273823
KEYWORD
nonn,look
AUTHOR
Antti Karttunen, Dec 15 2024
STATUS
approved