sums of fractional parts of linear functions of n As $\alpha$ and $\gamma$ range uniformly over $[0,1]$, what is the typical (e.g. median or root-mean-square) order of magnitude of $C_m (\alpha,\gamma)$ := $\sum_{1 \leq k \leq m} \left( {\rm frac}(k\alpha+\gamma) - \frac12 \right)$ where frac($x$) denotes the fractional part of $x$?
I'd settle for an answer in the case where $\gamma = 0$.
I know there are articles that address the question where $\alpha$ is fixed (going back to Hardy), but they don't immediately answer my question.  Perhaps one could cobble together an answer using results about how the magnitude of $C_m (\alpha,\gamma)$ is bounded in terms of the continued fraction convergents for $\alpha$, along with results about how the convergents grow for a generic real number.
 A: I looked at the literature just now, and I believe that R.R. Hall may have given a fairly complete answer to these questions.  See his 1998 Crelle paper:
http://www.reference-global.com/doi/abs/10.1515/crll.1998.035
Regards,
Sinai
A: Let $C_m(\alpha)=\sum_{k=1}^m((k\alpha))$ where $((x))$ is $x-[x]-1/2$ if $x$ is not an integer, 0 if $x$ is an integer (so this agrees with your definition away from points where $k\alpha$ is an integer). Then we'll get at the root-mean-square magnitude of $C_m(\alpha)$ by $$\int_0^1C_m(\alpha)^2d\alpha=\int_0^1\left(\sum_1^m((k\alpha))\right)^2d\alpha=\sum_{h,k}\int_0^1((h\alpha))((k\alpha))d\alpha$$ Now go to page 25 of Rademacher and Grosswald, Dedekind Sums, where it is proved that this last integral is given by $c^2/(12hk)$, where $c=\gcd(h,k)$. Well, that should get you started. 
UPDATE added by David Speyer: The rest of this answer refers to a different sum. See the comments below where this issue is discussed. Gerry, hope you don't mind me adding this, but it bugs me when there is wrong information in an (otherwise very good) answer.
EDIT: Not really fair to leave you with $\sum_{h,k}{\gcd(h,k)\over12hk}$ to evaluate, so I found a reference that does it. 
Olivier Bordelles, Mean values of generalized gcd-sum and lcm-sum functions, J. Integer Seq. 10 (2007), no. 9, Article 07.9.2, 13 pp. (electronic), MR2346091 (2008g:11005), available at http://www.cs.uwaterloo.ca/journals/JIS/VOL10/Bordelles2/bordelles61.pdf finds $$\sum_{n\le x}\sum_{j=1}^n{1\over{\rm lcm}(n,j)}={(\log x)^3\over6\zeta(2)}+C_1(\log x)^2+O(\log x)$$ where $C_1$ is some explicit constant that I can't be bothered to type out. Now $1/{\rm lcm}(h,k)=\gcd(h,k)/hk$, and $$\sum_{h=1}^m\sum_{k=1}^mf(h,k)=2\sum_{h\le m}\sum_{k=1}^hf(h,k)-\sum_{h=1}^mf(h,h)$$ for symmetric functions $f$, and it all comes together. 
