#include <bits/stdc++.h>
const int MAX_N = (int)2e5 + 123;
const double eps = 1e-6;
const int mod = (int)1e6 + 3;
using namespace std;
int c, w, h;
void add(int &a, const int &b) {
  a += b;
  if (a >= mod) a -= mod;
}
struct matrix {
  int n, m, a[105][105];
  matrix() {
    n = m = 0;
    memset(a, 0, sizeof a);
  }
  matrix(int _n, int _m) {
    n = _n, m = _m;
    memset(a, 0, sizeof a);
  }
  void apply() {
    assert(n == m);
    for (int i = 0; i < n; i++) a[i][i] = 1;
  }
  matrix operator*(const matrix &b) {
    matrix res = matrix(n, b.m);
    assert(m == b.n);
    for (int i = 0; i < n; i++)
      for (int j = 0; j < b.m; j++)
        for (int k = 0; k < m; k++)
          add(res.a[i][j], a[i][k] * 1ll * b.a[k][j] % mod);
    return res;
  }
};
int main() {
  scanf("%d%d%d", &c, &w, &h);
  matrix a = matrix(1, w + 1);
  a.a[0][0] = 1;
  matrix b = matrix(w + 1, w + 1);
  for (int i = 0; i <= w; i++) b.a[i][0] = 1;
  for (int i = 1; i <= w; i++) b.a[i - 1][i] = h;
  matrix res = matrix(w + 1, w + 1);
  res.apply();
  while (c) {
    if (c & 1) res = res * b;
    c >>= 1;
    b = b * b;
  }
  a = a * res;
  int ans = 0;
  for (int i = 0; i <= w; i++) add(ans, a.a[0][i]);
  printf("%d", ans);
  return 0;
}
