#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, d, last = 0;
  cin >> n >> d;
  int ans = 0;
  for (int i = 1; i <= n; i++) {
    int x;
    cin >> x;
    if (i == 1) {
      last = x;
    } else {
      int delta = last - x;
      if (delta < 0) {
        last = x;
      }
      if (delta == 0) {
        last = x + d;
        ans++;
      }
      if (delta > 0) {
        int hahaha = delta / d + 1;
        last = x + d * hahaha;
        ans += hahaha;
      }
    }
  }
  cout << ans << endl;
  return 0;
}
