#include <bits/stdc++.h>
using namespace std;
int N, M, T;
int num[20000005];
int main() {
  int i, j, k;
  scanf("%d%d", &N, &M);
  for (i = 1; i <= 20000000; i++) num[i] = 20000000;
  for (i = 1;; i++) {
    k = i * i;
    if (k > 20000000) break;
    T = 1;
    for (j = k; j <= 20000000; j += k, T++) num[j] = min(T, num[j]);
  }
  long long ans = 0;
  for (i = N; i <= N + M - 1; i++) ans += num[i];
  printf("%I64d\n", ans);
  scanf(" ");
}
