cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A194741 Number of k such that {-k*sqrt(3)} > {-n*sqrt(3)}, where { } = fractional part.

This page as a plain text file.
%I A194741 #6 Mar 30 2012 18:57:44
%S A194741 0,0,0,3,2,1,0,6,4,2,0,9,6,3,14,10,6,2,16,11,6,1,18,12,6,0,20,13,6,28,
%T A194741 20,12,4,29,20,11,2,30,20,10,0,31,20,9,42,30,18,6,42,29,16,3,42,28,14,
%U A194741 55,40,25,10,54,38,22,6,53,36,19,2,52,34,16,68,49,30,11,66,46
%N A194741 Number of k such that {-k*sqrt(3)} > {-n*sqrt(3)}, where { } = fractional part.
%t A194741 Remove["Global`*"];
%t A194741 r = -Sqrt[3]; p[x_] := FractionalPart[x];
%t A194741 u[n_, k_] := If[p[k*r] <= p[n*r], 1, 0]
%t A194741 v[n_, k_] := If[p[k*r] > p[n*r], 1, 0]
%t A194741 s[n_] := Sum[u[n, k], {k, 1, n}]
%t A194741 t[n_] := Sum[v[n, k], {k, 1, n}]
%t A194741 Table[s[n], {n, 1, 100}]   (* A194740 *)
%t A194741 Table[t[n], {n, 1, 100}]   (* A194741 *)
%Y A194741 Cf. A194740, A194738.
%K A194741 nonn
%O A194741 1,4
%A A194741 _Clark Kimberling_, Sep 02 2011