%I #16 Dec 14 2014 02:50:16
%S 1,6,7,37,43,233,276,1469,1745,9266,11011,58449,69460,368695,438155,
%T 2325725,2763880,14670658
%N First row of spectral array W(1/sin(1)).
%C 1/sin(1) = 1.18839510577812121626159945237455100352782983409796262526525...
%C The sequence is generated from the Beatty sequence (A108120) and from the complement of the Beatty sequence (A108587) for 1/sin(1).
%H A. Fraenkel and C. Kimberling, <a href="http://dx.doi.org/10.1016/0012-365X(94)90259-3">Generalized Wythoff arrays, shuffles and interspersions</a>, Discrete Mathematics 126 (1994) 137-149.
%o (PARI)
%o \\ Row i of the generalized Wythoff array W(h),
%o \\ where h is an irrational number between 1 and 2,
%o \\ and m is the number of terms in the vectors b and c.
%o row(h, i, m) = {
%o if(h<=1 || h>=2, print("Invalid value for h"); return);
%o my(
%o b=vector(m, n, floor(n*h)), \\ Beatty sequence for h
%o c=vector(m, n, floor(n*h/(h-1))), \\ Complement of b
%o w=[b[b[i]], c[b[i]]],
%o j=3
%o );
%o while(1,
%o if(j%2==1,
%o if(w[j-1]<=#b, w=concat(w, b[w[j-1]]), return(w))
%o ,
%o if(w[j-2]<=#c, w=concat(w, c[w[j-2]]), return(w))
%o );
%o j++
%o )
%o }
%o allocatemem(10^9)
%o default(realprecision, 100)
%o row(1/sin(1), 1, 10^7)
%Y Cf. A108120, A108587.
%K nonn,more
%O 1,2
%A _Colin Barker_, Dec 03 2014
|