#include <bits/stdc++.h>
using namespace std;
const int N = 111;
const long long M = 1e6 + 3;
int h, w;
long long c;
struct mart {
  long long a[111][111];
  mart(int x) {
    memset(a, 0, sizeof(a));
    if (x == 1)
      for (int i = 0; i < N; i++) a[i][i] = 1;
    if (x == 2) {
      for (int i = 0; i <= w; i++) a[i][0] = 1;
      for (int i = 1; i <= w; i++) a[i - 1][i] = h;
    }
  };
  mart operator*(mart &b) {
    mart c(0);
    for (int i = 0; i < N; i++)
      for (int j = 0; j < N; j++)
        if (a[i][j])
          for (int k = 0; k < N; k++)
            c.a[i][k] = (c.a[i][k] + a[i][j] * b.a[j][k]) % M;
    return c;
  }
  void show() {
    puts("_________________");
    for (int i = 0; i < N; i++) {
      for (int j = 0; j < N; j++) printf("%d ", a[i][j]);
      puts("");
    }
    puts("_________________");
  }
};
long long pow(long long k) {
  mart ret(1), a(2);
  while (k) {
    if (k & 1) ret = ret * a;
    a = a * a;
    k >>= 1;
  }
  long long ans = 0, f[2];
  f[0] = 1, f[1] = h;
  for (int i = 0; i <= w; i++)
    for (int j = 0; j < 2; j++) ans = (ans + f[j] * ret.a[j][i]) % M;
  return ans;
}
int main() {
  cin >> c >> w >> h;
  cout << pow(c - 1) << endl;
  return 0;
}
