#include<cstdio>
typedef long long LL;
const int N=1e6+5,md=1e9+7;
int a,b,c,fac[N],iv[N],ans;
inline int pow(int a,int b){
	int ret=1;
	for(;b;b>>=1,a=(LL)a*a%md)if(b&1)ret=(LL)ret*a%md;
	return ret;
}
inline int C(int n,int m){return n>=m?(LL)fac[n]*iv[m]%md*iv[n-m]%md:0;}
int main(){
	scanf("%d%d%d",&a,&b,&c);
	if(!a--)return puts("1"),0;
	if(b>c)b^=c^=b^=c;
	for(int i=*fac=1;i<=1000000;++i)fac[i]=(LL)fac[i-1]*i%md;
	iv[1000000]=397802501;
	for(int i=1e6-1;~i;--i)iv[i]=(i+1LL)*iv[i+1]%md;
	int pL=0,pR=0;
	for(int i=0,x=1,y=pow(3,b+c);i<=b+c;++i){
		int nL=i<=c?0:(pL*2LL-C(i-1,i-c-2)+C(i,i-c-1)+md)%md;
		int nR=i<=b?x:(pR*2LL-C(i-1,b)+md)%md;
		pL=nL,pR=nR;
		ans=(ans+(LL)C(i+a,a)*(nR-nL+md)%md*y)%md;
		x=x*2%md,y=y*333333336LL%md;
	}
	printf("%d\n",ans);
	return 0;
}