def calc(x, m): ret = 0 now = 2 i = 2 d = x // i while i <= m: while i + 1 <= m and d == x // (i + 1): i += 1 ret += x * (i - now + 1) - (i - now + 1) * (i + now) // 2 * d i += 1 d = x // i now = i return ret N, M = map(int, input().split()) ans = 0 for i in range(1, N + 1): ans = max(ans, calc(i, M)) print(ans)