8
$\begingroup$

Is there any formula to calculate: $$\lfloor n\rfloor+\left\lfloor \frac n2\right\rfloor+ \left\lfloor \frac n3\right\rfloor+\ldots+\left\lfloor \frac nk\right\rfloor$$ with $n$ and $k$ positive integers and $k\leq n$.

$\endgroup$
  • $\begingroup$ Is $[\cdot]$ the integer part? $\endgroup$ – marco trevi Sep 30 '14 at 10:36
  • $\begingroup$ @marcotrevi: Yes. $\endgroup$ – mac Sep 30 '14 at 10:37
  • 2
    $\begingroup$ I doubt there is a nice formula for this. There are two regimes: as long as $k^2<n$, the quotients are strictly decreasing with decreasing steps; the sums will approximately follow an $n\log(n)$ curve; then the quotients start repeating longer and longer, with a unit step in between. The last "run" goes for $n/2\le k\le n$, with the sum linearly increasing. $\endgroup$ – Yves Daoust Sep 30 '14 at 11:05
4
$\begingroup$

It does not seem that there exists a closed formula. Indeed, let us denote the sum to be calculated by $S_{n,k}$. Specializing to the case $k=n$ corresponds to the entry A006218 at OEIS, which only provides asymptotic estimates: $$n \left(\ln n + 2 \gamma - 1\right) - 4 \sqrt n - 1 \leq S_{n,n} \leq n \left(\ln n + 2 \gamma - 1\right) + 4 \sqrt n.$$

$\endgroup$
  • $\begingroup$ oeis.org/A006218 is not really the same thing, is it? The OP mentions several functions of $n$, one for each $k$. $\endgroup$ – lhf Sep 30 '14 at 11:44
  • $\begingroup$ @Ihf indeed, I will edit accordingly. Thanks! $\endgroup$ – Start wearing purple Sep 30 '14 at 11:49
  • $\begingroup$ @O.L.: what is $\gamma$? $\endgroup$ – mac Sep 30 '14 at 11:57
  • $\begingroup$ @mac Euler-Mascheroni constant. $\endgroup$ – Start wearing purple Sep 30 '14 at 11:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.