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.

A194752 Number of k such that {-k*e} < {-n*e}, where { } = fractional part.

This page as a plain text file.
%I A194752 #5 Mar 30 2012 18:57:44
%S A194752 1,2,3,1,3,5,7,2,5,8,1,5,9,13,3,8,13,1,7,13,19,4,11,18,1,9,17,25,5,14,
%T A194752 23,1,11,21,31,6,17,28,39,11,23,35,5,18,31,44,11,25,39,4,19,34,49,11,
%U A194752 27,43,3,20,37,54,11,29,47,2,21,40,59,11,31,51,1,22,43,64,11,33
%N A194752 Number of k such that {-k*e} < {-n*e}, where { } = fractional part.
%t A194752 r = -E; p[x_] := FractionalPart[x];
%t A194752 u[n_, k_] := If[p[k*r] <= p[n*r], 1, 0]
%t A194752 v[n_, k_] := If[p[k*r] > p[n*r], 1, 0]
%t A194752 s[n_] := Sum[u[n, k], {k, 1, n}]
%t A194752 t[n_] := Sum[v[n, k], {k, 1, n}]
%t A194752 Table[s[n], {n, 1, 100}]   (* A194752 *)
%t A194752 Table[t[n], {n, 1, 100}]   (* A194753 *)
%Y A194752 Cf. A194753, A194738.
%K A194752 nonn
%O A194752 1,2
%A A194752 _Clark Kimberling_, Sep 02 2011