#include <bits/stdc++.h>
using namespace std;
const int MAX = 10000010;
int n, a;
long long add[MAX];
int main() {
  cin >> a >> n;
  int m = a + n;
  for (int i = a; i < m; ++i) add[i] = i;
  for (int i = 2; i * i < m; ++i) {
    int d = i * i;
    for (int j = d; j < m; j += d)
      while (add[j] && add[j] % d == 0) add[j] /= d;
  }
  long long ans = 0;
  for (int i = a; i < m; ++i) ans += add[i];
  cout << ans << '\n';
  return 0;
}
