#include <bits/stdc++.h>
using namespace std;

const int Mod = 1e9 + 7;
const int N = 9e5 + 10;

int n, m, k;
long long fac[N], vfac[N];

long long mpow( long long a, int b ) {
	long long rt;
	for( rt = 1; b; b >>= 1, a = (a * a) % Mod )
		if( b & 1 ) rt = (rt * a) % Mod;
	return rt;
}
void init( int n ) {
	fac[0] = 1;
	for( int i = 1; i <= n; i++ )
		fac[i] = (fac[i-1] * i) % Mod;
	vfac[n]  = mpow( fac[n], Mod - 2 );
	for( int i = n - 1; i >= 0; i-- )
		vfac[i] = vfac[i+1] * (i + 1) % Mod;
}
long long comb( int n, int m ) {
	return fac[n] * vfac[n-m] % Mod * vfac[m] % Mod;
}
int main() {
	scanf( "%d%d%d", &n, &m, &k );
	if( m < k )
	   	swap( m, k );
	init( m + k + n );
	long long sum = 0;
	long long ans = 0;
	for( int s = 0; s <= m + k; s++ ) {
		if( s == 0 ) 
			sum = 1;
		else if( s <= k ) 
			sum = (sum<<1) % Mod;
		else if( s <= m ) 
			sum = ((sum<<1) + Mod - comb(s-1,s-k-1)) % Mod;
		else 
			sum = ((sum<<1) + Mod - comb(s-1,s-k-1) + Mod - comb(s-1,m)) % Mod;
		long long sub = sum * comb(n-1+s,n-1) % Mod * mpow(3,m+k-s) % Mod;
		ans = (ans + sub) % Mod;
	}
	cout << ans << endl;
}

