#include <bits/stdc++.h>
using namespace std;
const int md = 1e6 + 3;
int c, w, h;
int dp1[100001];
int dp[2000];
int bpow(int a, int b) {
  if (b == 0) return 1;
  int res = bpow(a, b >> 1);
  res = (res * 1ll * res) % md;
  if (b & 1) res = (res * 1ll * a) % md;
  return res;
}
deque<int> q;
int main() {
  c = 1001;
  w = 100;
  h = 100;
  cin >> c >> w >> h;
  dp[0] = 1;
  for (int i = 1; i <= w; i++) dp[i] = (dp[i - 1] * h) % md;
  dp1[0] = 1;
  if (c <= 10000) {
    for (int i = 1; i <= c; ++i) {
      dp1[i] = dp1[i - 1];
      if (i <= w) dp1[i] = (dp1[i] + dp[i]) % md;
      int mx = min(i - 1, w);
      for (int j = 1; j <= mx; ++j) {
        dp1[i] = (dp1[i] + dp[j] * 1ll * dp1[i - j - 1]) % md;
      }
    }
    cout << dp1[c] << "\n";
  } else {
    for (int i = 1; i <= 1000; i++) {
      dp1[i] = dp1[i - 1];
      if (i <= w) dp1[i] = (dp1[i] + dp[i]) % md;
      int mx = min(i - 1, w);
      for (int j = 1; j <= mx; ++j)
        dp1[i] = (dp1[i] + dp[j] * 1ll * dp1[i - j - 1]) % md;
    }
    int cur = 0;
    for (int i = 1000; i <= 1000; ++i)
      for (int j = 1; j <= w; ++j) {
        cur = (cur + dp[j] * 1ll * dp1[i - j - 1]) % md;
      }
    q.push_back(dp1[1000]);
    q.push_back(dp1[999]);
    for (int i = 1000; i <= 1000; ++i)
      for (int j = 1; j <= w; ++j) {
        q.push_back(dp1[i - j - 1]);
      }
    for (int i = 1001; i <= c; ++i) {
      cur = ((cur - dp[w] * 1ll * q.back()) % md + md) % md;
      cur = (cur * 1ll * h) % md;
      cur += (h * 1ll * q[1]) % md;
      cur %= md;
      q.push_front((q[0] + cur) % md);
      q.pop_back();
    }
    cout << q.front() << "\n";
  }
}
