#include <bits/stdc++.h>
using namespace std;
const int N = 110, P = 1000003;
int i, j, k, c, w, h, ans;
struct matrix {
  int a[N][N];
  matrix operator*(const matrix &n) {
    matrix t;
    int i, j, k;
    memset(t.a, 0, sizeof t.a);
    for (k = 0; k <= w; k++)
      for (i = 0; i <= w; i++)
        for (j = 0; j <= w; j++)
          t.a[i][j] = ((long long)a[i][k] * n.a[k][j] + t.a[i][j]) % P;
    return t;
  }
} A, B;
int main() {
  scanf("%d%d%d", &c, &w, &h);
  for (i = 0; i <= w; i++) {
    if (i < w) B.a[i][i + 1] = h;
    B.a[i][0] = 1;
  }
  for (i = 0; i <= w; i++) A.a[i][i] = 1;
  for (; c; c >>= 1, B = B * B)
    if (c & 1) A = A * B;
  for (i = 0; i <= w; i++) ans = (ans + A.a[0][i]) % P;
  printf("%d\n", ans);
}
