login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A266408
Permutation of natural numbers: a(n) = (1/2) * (1+A263273(A003961(n))).
4
1, 2, 4, 5, 3, 11, 10, 14, 9, 8, 7, 32, 13, 29, 37, 41, 6, 26, 12, 23, 15, 20, 28, 95, 22, 38, 115, 86, 19, 110, 16, 122, 30, 17, 36, 77, 34, 35, 55, 68, 25, 44, 31, 59, 60, 83, 40, 284, 61, 65, 100, 113, 33, 344, 46, 257, 70, 56, 24, 329, 21, 47, 289, 365, 88, 89, 39, 50, 49, 107, 18, 230, 27, 101, 244, 104, 112, 164, 82, 203, 174, 74
OFFSET
1,2
FORMULA
a(n) = (1/2) * (1+A263273(A003961(n))).
PROG
(PARI)
A030102(n) = { my(r=[n%3]); while(0<n\=3, r=concat(n%3, r)); subst(Polrev(r), x, 3); } \\ After M. F. Hasler's Nov 04 2011 code in A030102.
A263273 = n -> if(!n, n, A030102(n/(3^valuation(n, 3))) * (3^valuation(n, 3))); \\ Taking of the quotient probably unnecessary.
A003961(n) = my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); \\ Using code of Michel Marcus
A266408 = n -> (1+A263273(A003961(n)))/2;
for(n=1, 8191, write("b266408.txt", n, " ", A266408(n)));
(Scheme) (define (A266408 n) (/ (+ 1 (A263273 (A003961 n))) 2))
CROSSREFS
Inverse: A266407.
Cf. also A048673, A266401, A266403.
Sequence in context: A118461 A376733 A332667 * A358339 A230564 A011174
KEYWORD
nonn,base
AUTHOR
Antti Karttunen, Jan 02 2016
STATUS
approved