#include <bits/stdc++.h>
using namespace std;
int mod = 1000000007;
int main() {
  int n, k, d;
  cin >> n >> k >> d;
  vector<vector<long long> > dp(n + 1, vector<long long>(2, 0));
  dp[0][0] = 1;
  dp[0][1] = 0;
  for (int i = 1; i <= n; i++) {
    for (int j = 1; j <= k; j++) {
      int c = i - j;
      if (c >= 0) {
        if (j >= d) {
          dp[i][1] += ((dp[c][0] + dp[c][1]) % mod);
        } else {
          dp[i][0] += (dp[c][0] % mod);
          dp[i][1] += (dp[c][1] % mod);
        }
      }
    }
  }
  cout << (dp[n][1] % mod);
  return 0;
}
