Q: Find a formula for $\sum_{k=0}^m⌊\sqrt{k}⌋$, when m is a positive integer.

73 Views Asked by At

Q: Find a formula for $\sum_{k=0}^m⌊\sqrt{k}⌋$, when m is a positive integer.

I checked the answer, and it is

$\frac{n(n+1)(2n+1)}{3}+\frac{n(n+1)}{2}+(n+1)(m-(n+1)^2+1)$, where $n=⌊\sqrt{m}⌋-1$.

I am currently studying discrete mathematics by myself, and I have no idea how to solve this question. Please provide me some extra explanations to the answer.

Thank you in advance.