#include <bits/stdc++.h>
using namespace std;
const int MAXM = 10000000;
bool isPrime[MAXM + 1];
int divs[MAXM + 1];
int f[MAXM + 1];
int main() {
  int a, n, m;
  cin >> a >> n;
  m = a + n - 1;
  for (int i = 1; i <= m; ++i) {
    divs[i] = i;
    isPrime[i] = true;
  }
  isPrime[1] = false;
  for (int i = 2; i * i <= m; ++i)
    if (isPrime[i]) {
      for (int j = i * i; j <= m; j += i) {
        if (isPrime[j]) divs[j] = i;
        isPrime[j] = false;
      }
    }
  f[1] = 1;
  int j;
  for (int i = 2; i <= m; ++i) {
    j = divs[i];
    if (i % (j * j) == 0)
      f[i] = f[i / (j * j)];
    else
      f[i] = j * f[i / j];
  }
  long long res = 0;
  for (int i = a; i <= m; ++i) {
    res += f[i];
  }
  cout << res << endl;
  return 0;
}
