#include <bits/stdc++.h>
using namespace std;
template <class T, class T2>
inline bool chkmax(T &x, const T2 &y) {
  return x < y ? x = y, 1 : 0;
}
template <class T, class T2>
inline bool chkmin(T &x, const T2 &y) {
  return x > y ? x = y, 1 : 0;
}
const long long mod = 1e9 + 7;
template <class T>
inline void fix(T &x) {
  if (x >= mod || x <= -mod) {
    x %= mod;
  }
  if (x < 0) {
    x += mod;
  }
}
const long long MAX_N = 1e6 + 10;
long long perm[MAX_N], inv[MAX_N];
long long fpow(long long x, long long p) {
  if (p == 0) {
    return 1;
  }
  long long ans = fpow(x, p / 2);
  ans = (ans * ans) % mod;
  if (p & 1) {
    return (ans * x) % mod;
  } else {
    return ans;
  }
}
long long comb(long long k, long long n) {
  if (k < 0 || n < 0) {
    return 0;
  }
  if (n - k < 0) {
    return 0;
  }
  return (((perm[n] * inv[n - k]) % mod) * inv[k]) % mod;
}
signed main() {
  perm[0] = inv[0] = 1;
  for (long long i = 1; i < MAX_N; i++) {
    perm[i] = (perm[i - 1] * i) % mod;
    inv[i] = (inv[i - 1] * fpow(i, mod - 2)) % mod;
  }
  long long n, m, k;
  cin >> n >> m >> k;
  long long rangel = 0, ranger = 0;
  long long sum = 1;
  long long ans = 0;
  m++;
  k++;
  for (long long ij = 0; ij <= m + k - 2; ij++) {
    long long nwl = max(0ll, ij - m + 1);
    long long nwr = min(m - 1, ij);
    while (nwl < rangel) {
      sum = (sum + comb(rangel - 1, ij)) % mod;
      rangel--;
    }
    while (nwl > rangel) {
      sum = (sum - comb(rangel, ij)) % mod;
      rangel++;
    }
    while (nwr > ranger) {
      sum = (sum + comb(ranger + 1, ij)) % mod;
      ranger++;
    }
    while (nwr < ranger) {
      sum = (sum - comb(ranger, ij)) % mod;
      ranger--;
    }
    long long sum2 = 0;
    for (long long i = nwl; i <= nwr; i++) {
      sum2 += comb(i, ij);
      sum2 %= mod;
    }
    fix(sum);
    ans += ((comb(n - 1, n - 1 + ij) * sum2) % mod) * fpow(3, m + k - 2 - ij);
    fix(ans);
    sum = (sum * 2) % mod;
    sum += comb(ranger + 1, ij) + comb(rangel - 1, ij);
    sum %= mod;
    fix(sum);
    fix(ans);
    ranger++;
  }
  cout << ans << "\n";
  return 0;
}
