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

b,s=K+1,0

while b <= N:

 c=N%b

 s+=(N//b)*(b-K)+max(0,c-K+1)

 b+=1

print((s if K!=0 else N*N))
N,K=list(map(int,input().split()))

s=0

for b in range(K+1,N+1):s+=(N//b)*(b-K)+max(0,N%b-K+1)

print((s if K!=0 else N*N))
N, K = list(map(int, input().split()))
b, s = K + 1, 0
while b <= N:
    c = N % b
    s += (N // b) * (b - K) + max(0, c - K + 1)
    b += 1
print((s if K != 0 else N * N))

N, K = list(map(int, input().split()))
s = 0
for b in range(K + 1, N + 1):
    s += (N // b) * (b - K) + max(0, N % b - K + 1)
print((s if K != 0 else N * N))

-b, s = K + 1, 0 -while b <= N: -    c = N % b -    s += (N // b) * (b - K) + max(0, c - K + 1) -    b += 1 +s = 0 +for b in range(K + 1, N + 1): +    s += (N // b) * (b - K) + max(0, N % b - K + 1)