How can one prove the following equality (for fixed positive integer $a$):
$$12\sum_{k=1}^{an^2-1}k\left\{\frac{k(an-1)}{an^2}\right\}=3a^2n^4-a^2n^2-2$$
where $\{x\}=x-\lfloor x\rfloor$ denotes the fractional part operator.
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It only takes a minute to sign up.
Sign up to join this communityHow can one prove the following equality (for fixed positive integer $a$):
$$12\sum_{k=1}^{an^2-1}k\left\{\frac{k(an-1)}{an^2}\right\}=3a^2n^4-a^2n^2-2$$
where $\{x\}=x-\lfloor x\rfloor$ denotes the fractional part operator.
The Dedekind sum $s(t,u)$ can be defined by $$s(t,u)=\sum_{k=1}^{u-1}{k\over u}\left(\left\{{kt\over u}\right\}-{1\over2}\right)$$ for relatively prime integers $t,u$, where $\{x\}$ denotes the fractional part of $x$. We have $$s(t,u)=-{1\over2u}\sum k+{1\over u}\sum k\left\{{kt\over u}\right\}$$ so if we can evaluate $s(an-1,an^2)$ then we can evaluate $\displaystyle\sum_1^{u-1}k\left\{{(an-1)k\over an^2}\right\}$
The Dedekind sum satisfies these formulas (and many more):
$s(t,u)=s(t',u)$ if $t\equiv t'\pmod u$
$\displaystyle s(1,u)=-{1\over4}+{1\over6u}+{u\over12}$
$s(-t,u)=-s(t,u)$
$\displaystyle s(t,u)+s(u,t)=-{1\over4}+{1\over12}\left({t\over u}+{1\over tu}+{u\over t}\right)$
The last of these is called the reciprocity formula for the Dedekind sum, and is considerably harder to establish than the others.
Reciprocity lets us express $s(an-1,an^2)$ in terms of $s(an^2,an-1)$.
Then the first formula implies $s(an^2,an-1)=s(n,an-1)$.
Then reciprocity gives us $s(n,an-1)$ in terms of $s(an-1,n)$.
Then from the 1st and 3rd formulas we have $s(an-1,n)=s(-1,n)=-s(1,n)$, and the 2nd formula completes the evaluation.
I make it an answer only because I want to include the program code, please don't downvote. the approximation is good, but not exact. As to how to prove it, I have no clue.
for n = 10, the LHS is 1069916.8199999994 and RHS is 1076398 for n = 1000, LHS = 107999963999968.27 and RHS = 107999963999968
maybe you missed something?
In [5]: math.modf(4.5)
Out[5]: (0.5, 4.0)
In [6]: foo = lambda k,n : k*math.modf(1.0*k*(6*n-1) / (6*n**2))[0]
In [9]: bar = lambda n : 12*sum( [foo(k,n) for k in xrange(1,6*n**2)])
In [10]: bar(10)
Out[10]: 1076397.9999999993
In [11]: 1080000 - 3600 -2
Out[11]: 1076398
In [12]: g = lambda n : 108*n**4 - 36*n**2 - 2
In [13]: g(10)
Out[13]: 1076398
In [14]: bar(1000)
Out[14]: 107999963999968.27
In [15]: g(1000)
Out[15]: 107999963999998