#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, d;
  while (cin >> n >> d) {
    int A[n], ans = 0;
    for (int i = 0; i < n; i++) cin >> A[i];
    for (int i = 1; i < n; i++) {
      if (A[i] <= A[i - 1]) {
        int rest = A[i - 1] - A[i], cnt = (rest / d) + 1;
        A[i] += cnt * d;
        ans += cnt;
      }
    }
    cout << ans << endl;
  }
  return 0;
}
