# Evaluating a finite sum with square roots and simple powers. + The integral of floor(x^2) + The integral of the fractional part of x^2

I was recently integrating the floor of $$x^2$$ and had almost finished it, however this finite Sum was left unevaluated.

$$\frac{1}{3}\sum_{i=1}^{\lfloor x^2 \rfloor} {\Biggl(\Bigl(\sqrt{(i-1)}\Bigr)(2i-2)-\Bigl(\sqrt{(i-1)}\Bigl)(2i-3)\Biggl)}=?$$

It would be really nice if there was a closed form for this.

The way I came up with this sum:

$$\int_{0}^x {\lfloor t^2 \rfloor} = \int_{0}^x {t^2}-\{t^2\}$$ $$=\frac{x^3}{3}-\int_{0}^x\{t^2\}$$

and if you are Looking at the function of $$\{x\}$$ then you can see that this is the function $$x^2$$ only that it starts again at $$0$$ at every value of a square root of an integer.

so that $$\int_{0}^x\{t^2\}=\Biggl(\sum_{i=0}^{\lfloor x^2 \rfloor} \int_{\sqrt{i-1}}^{\sqrt{i}} k^2-i+1 dk\Biggr)+\int_{_{\sqrt{\lfloor x^2 \rfloor}}}^x v^2-\lfloor x^2 \rfloor dv$$

Now that means that: $$\int_{0}^x\{x^2\}=\frac{1}{3}\sum_{i=1}^{\lfloor x^2 \rfloor} {\Biggl(\Bigl(\sqrt{(i-1)}\Bigr)(2i-2)-\Bigl(\sqrt{(i-1)}\Bigl)(2i-3)\Biggl)}+\Bigl(-x{\lfloor x^2 \rfloor} +\frac{2{\lfloor x^2 \rfloor}^{\frac{3}{2}}}{3}+\frac{x^3}{3}\Bigr)$$

However, I was unable to find a closed form for the Sum, I would appreciate any help of you.

Moreover, I know that it can be expressed in Terms of the Zeta function and the Harmonic series, but what I am searching for i a form in Terms of some easy mathematical function.

If you instead consider the original integral as a sum you get for $$x\ge0$$ $$\int_0^x\lfloor t^2\rfloor \mathrm{d}t=\lfloor x^2\rfloor\left(x-\sqrt{\lfloor x^2\rfloor}\right)+\sum_{k=1}^{\lfloor x^2\rfloor -1} k\left(\sqrt{k+1}-\sqrt{k}\right)$$ which telescopes to \begin{align} \int_0^x\lfloor t^2\rfloor \mathrm{d}t &=x\lfloor x^2\rfloor-\sum_{k=1}^{\lfloor x^2\rfloor} \sqrt{k}\\ &=x\lfloor x^2\rfloor-H_{-1/2}\left(\lfloor x^2\rfloor\right)\\ \end{align} where $$H_m(n)$$ denote the generalized harmonic numbers. We can also generalise this for $$n\in\mathbb{N}$$ to \begin{align} \int_0^x\lfloor t^n\rfloor \mathrm{d}t &=x\lfloor x^n\rfloor-\sum_{k=1}^{\lfloor x^n\rfloor} \sqrt[n]{k}\\ &=x\lfloor x^n\rfloor-H_{-1/n}\left(\lfloor x^n\rfloor\right)\\ \end{align}