#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1e6 + 5;
const long long p = 1e9 + 7;
const long long inv3 = (p + 1) / 3;
long long fact[MAXN], invfact[MAXN], inv[MAXN], n, m, k, c[MAXN];
long long p3[MAXN], pinv3[MAXN];
long long comb(int x, int y) {
  if (x < 0 || y < 0 || x < y) return 0;
  return fact[x] * invfact[y] % p * invfact[x - y] % p;
}
long long exp(long long x, long long k) {
  if (k == 0) return 1;
  long long y = exp(x, k / 2);
  return (k % 2 == 0) ? y * y % p : y * y % p * x % p;
}
long long inve(long long x) { return exp(x, p - 2); }
void init() {
  inv[1] = fact[0] = fact[1] = invfact[0] = invfact[1] = 1;
  for (int i = 2; i < MAXN; ++i) {
    inv[i] = (p - (p / i) * inv[p % i] % p) % p;
    fact[i] = i * fact[i - 1] % p;
    invfact[i] = inv[i] * invfact[i - 1] % p;
  }
  p3[0] = pinv3[0] = 1;
  for (int i = 1; i < MAXN; ++i)
    p3[i] = 3 * p3[i - 1] % p, pinv3[i] = inv3 * pinv3[i - 1] % p;
}
int main() {
  cin >> n >> m >> k;
  init();
  for (int i = 0; i <= k; ++i) c[0] = (c[0] + pinv3[i]) % p;
  for (int i = 1; i < MAXN; ++i)
    c[i] = 3 * (p + 1) / 2 % p *
           (c[i - 1] + p - comb(i + k, k) * pinv3[k + 1] % p) % p;
  long long ans = 0;
  for (int i = 0; i <= m; ++i)
    ans = (ans + comb(n - 1 + i, i) * pinv3[i] % p * c[n - 1 + i] % p) % p;
  cout << ans * p3[m + k] % p << endl;
}
