%I #20 Mar 28 2015 16:29:40
%S 1,2,3,3,6,5,5,10,5,5,10,15,15,30,7,7,14,7,7,14,21,21,42,7,7,14,7,7,
%T 14,21,21,42,35,35,70,35,35,70,105,105,210,4,8,16,4,8,16,12,24,48,4,8,
%U 16,4,8,16,12,24,48,20,40,80,20,40,80,60,120,240,4,8,16,4,8,16,12,24,48,4,8
%N a(n) is the numerator of the rational number whose "factorization" into terms of A186285 has the balanced ternary representation corresponding to n.
%C Numerators from the ordering of positive rational numbers by increasing balanced ternary representation of the "factorization" of positive rational numbers into terms of A186285 (prime powers with a power of three as exponent).
%H Daniel Forgues, <a href="/A186286/b186286.txt">Table of n, a(n) for n = 0..9841</a>
%H OEIS Wiki, <a href="/wiki/Orderings_of_rational_numbers">Orderings of rational numbers</a>
%F The balanced ternary representation of n
%F n = Sum(i=0..1+floor(log_3(2|n|)) n_i * 3^i, n_i in {-1,0,1},
%F is taken as the representation of the "factorization" of the positive rational number c(n)/d(n) into terms from A186285
%F c(n)/d(n) = Prod(i=0..1+floor(log_3(2|n|)) (A186285(i+1))^(n_i), where A186285(i+1) is the (i+1)th prime power with exponent being a power of 3. Then a(n) is the numerator, i.e., c(n).
%e The balanced ternary digits {-1,0,+1} are represented here as {2,0,1}.
%e n BalTern A186286/A186287 (in reduced form)
%e 0 0 Empty product = 1 = 1/1, a(n) = 1
%e 1 1 2 = 2/1, a(n) = 2
%e 2 12 3*(1/2) = 3/2, a(n) = 3
%e 3 10 3 = 3/1, a(n) = 3
%e 4 11 3*2 = 6 = 6/1, a(n) = 6
%e 5 122 5*(1/3)*(1/2) = 5/6, a(n) = 5
%e 6 120 5*(1/3) = 5/3, a(n) = 5
%e 7 121 5*(1/3)*2 = 10/3, a(n) = 10
%e ... ...
%e 41 12222 8*(1/7)*(1/5)*(1/3)*(1/2) = 8/210 = 4/105, a(n) = 4
%Y Cf. A186285, A186287, A185169, A052330.
%K nonn,frac
%O 0,2
%A _Daniel Forgues_, Feb 17 2011