#include <bits/stdc++.h>
using namespace std;
long long a[2001];
int main() {
  int n, d, ans = 0;
  scanf("%d%d", &n, &d);
  for (register int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (register int i = 2; i <= n; i++)
    while (a[i] <= a[i - 1])
      if (a[i] <= a[i - 1]) {
        ans = ans + (a[i - 1] - a[i]) / d;
        a[i] = a[i] + ((a[i - 1] - a[i]) / d + 1) * d;
        ans++;
      }
  printf("%d\n", ans);
  return 0;
}
