#include <bits/stdc++.h>
using namespace std;
int dp[110], tmp[110], mod = 1e6 + 3, dir[200];
int n, w, h;
int main() {
  long long sum = 1, x;
  scanf("%d%d%d", &n, &w, &h);
  dir[0] = 1;
  for (int i = 1; i <= 150; i++) dir[i] = dir[i - 1] * h % mod;
  queue<long long> q;
  for (int i = 0; i < w; i++) q.push(0);
  q.push(1);
  for (int i = 0; i < n; i++) {
    q.push(sum);
    x = q.front() * dir[(i) > (w) ? (w) : (i)] % mod;
    sum = (sum - x) * h + sum;
    sum = (sum % mod + mod) % mod;
    q.pop();
  }
  printf("%I64d\n", sum);
}
