#include <bits/stdc++.h>
using namespace std;
const long long mod = 1000000007;
const long long INF = mod * mod;
const long double eps = 1e-6;
const long double pi = acos(-1.0);
struct perm {
 private:
  int sz;
  vector<long long> p, invp;

 public:
  perm(int n) {
    sz = n + 1;
    p.resize(sz), invp.resize(sz);
    p[0] = 1;
    for (int i = 1; i <= sz - 1; i++) {
      p[i] = p[i - 1] * i % mod;
    }
    invp[sz - 1] = 1;
    long long cop = mod - 2, x = p[sz - 1];
    while (cop) {
      if (cop % 2) invp[sz - 1] = invp[sz - 1] * x % mod;
      cop >>= 1;
      x = x * x % mod;
    }
    for (int i = sz - 1 - 1; i >= 0; i--) {
      invp[i] = invp[i + 1] * (i + 1) % mod;
    }
  }
  long long comb(long long x, long long y) {
    if (x < y || y < 0) return 0;
    long long ret = p[x];
    (ret *= invp[y]) %= mod;
    (ret *= invp[x - y]) %= mod;
    return ret;
  }
  long long combP(long long x, long long y) {
    if (x < y || y < 0) return 0;
    return p[x] * invp[x - y] % mod;
  }
};
perm p(1 << 19);
long long t3[700001];
void solve() {
  t3[0] = 1;
  for (int i = 0; i < 700000; i++) t3[i + 1] = t3[i] * 3 % mod;
  int n, m, k;
  cin >> n >> m >> k;
  long long ans = 0;
  long long cur = 0;
  for (int t = 0; t < m + k + 1; t++) {
    long long csum = p.comb(t + n - 1, t) * t3[m + k - t] % mod;
    long long ncur = 0;
    if (t == 0) {
      cur = 1;
    } else {
      int ple = max(t - 1 - k, 0);
      int pri = min(m, t - 1);
      int le = max(t - k, 0);
      int ri = min(m, t);
      ncur += cur;
      cur += mod - p.comb(t - 1, ple);
      cur += p.comb(t - 1, pri + 1);
      if (le == ple) cur++;
      if (pri == ri) {
        cur += mod - p.comb(t - 1, pri);
        cur += mod - p.comb(t - 1, pri + 1);
      }
      while (cur >= mod) cur -= mod;
      ncur += cur;
      while (ncur >= mod) ncur -= mod;
      cur = ncur;
    }
    ans += cur * csum % mod;
    if (ans >= mod) ans -= mod;
  }
  cout << ans << endl;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  solve();
  return 0;
}
