Ad
  • Default User Avatar

    So, I understand that you use the formula (n + m) * (m / 2n), which sums all numbers up to m including if it is divisible by n. But where did this formula come from, something from number theory? I would be grateful if you could provide a link to the mathematical basis.