N,K = list(map(int,input().split()))

if K == 0:

    print((N*N))

    exit()



ans = 0

for b in range(1,N+1):

    cycle,rem = divmod(N,b)

    ans += cycle * max(0, b-K)

    ans += max(0, rem+1 - K)

print(ans)
N,K = list(map(int,input().split()))

if K == 0:

    print((N*N))

    exit()



ans = 0

for b in range(K+1,N+1):

    d,m = divmod(N,b)

    ans += d*(b-K) + max(0,m+1-K)

print(ans)
N, K = list(map(int, input().split()))
if K == 0:
    print((N * N))
    exit()
ans = 0
for b in range(1, N + 1):
    cycle, rem = divmod(N, b)
    ans += cycle * max(0, b - K)
    ans += max(0, rem + 1 - K)
print(ans)

N, K = list(map(int, input().split()))
if K == 0:
    print((N * N))
    exit()
ans = 0
for b in range(K + 1, N + 1):
    d, m = divmod(N, b)
    ans += d * (b - K) + max(0, m + 1 - K)
print(ans)

-for b in range(1, N + 1): -    cycle, rem = divmod(N, b) -    ans += cycle * max(0, b - K) -    ans += max(0, rem + 1 - K) +for b in range(K + 1, N + 1): +    d, m = divmod(N, b) +    ans += d * (b - K) + max(0, m + 1 - K)