login
a(n) is the smallest k such that the numerator of (k-6)/(2k) equals n.
5

%I #16 Feb 22 2020 20:54:24

%S 6,7,14,15,22,11,78,13,38,33,46,17,150,19,62,51,70,23,222,25,86,69,94,

%T 29,294,31,110,87,118,35,366,37,134,105,142,41,438,43,158,123,166,47,

%U 510,49,182,141,190,53,582,55,206,159,214,59,654,61,230,177,238,65,726

%N a(n) is the smallest k such that the numerator of (k-6)/(2k) equals n.

%C a(n) = index of first occurrence n in A146306.

%C General formula:

%C 2*cos(2*Pi/n) = Hypergeometric2F1((n-6)/(2n), (n+6)/(2n), 1/2, 3/4) = Hypergeometric2F1(A146306(n)/A146307(n), A146306(n+12)/A146307(n), 1/2, 3/4).

%C 2*cos(2*Pi/n) is root of polynomial of degree = EulerPhi(n)/2 = A000010(n)/2 = A023022(n).

%H Robert Israel, <a href="/A146308/b146308.txt">Table of n, a(n) for n = 0..10000</a>

%H <a href="/index/Rec#order_12">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,2,0,0,0,0,0,-1).

%F From _Robert Israel_, Aug 05 2019: (Start)

%F If 6 | n then a(n) = 12*n+6

%F else if 3 | n then a(n) = 3*n+6

%F else if 2 | n then a(n) = 2*n+6

%F else a(n) = n+6.

%F a(n) = 2*a(n-6) - a(n-12).

%F G.f.: (6 + 7*x + 14*x^2 + 15*x^3 + 22*x^4 + 11*x^5 + 66*x^6 - x^7 + 10*x^8 + 3*x^9 + 2*x^10 - 5*x^11)/(1 - 2*x^6 + x^12). (End)

%p f:= proc(n) if n mod 6 = 0 then 12*n+6 elif n::even then 4*n+6 elif n mod 3 = 0 then 3*n+6 else n+6 fi end proc:

%p map(f, [$0..100]); # _Robert Israel_, Aug 05 2019

%t aa = {}; Do[k = 1; While[Numerator[(k - 6)/(2 k)] != n, k++ ]; AppendTo[aa, k], {n, 0, 100}]; aa

%Y Cf. A007310, A051724, A146306, A146307, A146309.

%K nonn,look

%O 0,1

%A _Artur Jasinski_, Oct 29 2008