#include <bits/stdc++.h>
using namespace std;
using ll=long long;
#define MOD 1000000007
using Graph=vector<vector<int>>;

ll modpow(ll a,ll x){
  a%=MOD;
  ll ret=1;
  while(x>0){
    if(x%2==1){
      ret=ret*a%MOD;
    }
    x/=2;
    a=a*a%MOD;
  }
  return ret;
}

ll modinv(ll x){
  return modpow(x,MOD-2);
}

void dfs(Graph &G,int v,int p,vector<int> &depth,vector<int> &parent){
  for(auto nv:G[v]){
    if(nv==p){
      continue;
    }
    parent[nv]=v;
    depth[nv]=depth[v]+1;
    dfs(G,nv,v,depth,parent);
  }
}

int K=10;

int main(){
  int n;
  cin>>n;
  Graph G(n);
  for(int i=0;i<n-1;i++){
    int a,b;
    cin>>a>>b;
    a--;b--;
    G[a].push_back(b);
    G[b].push_back(a);
  }

  ll ans=0;

  vector<vector<ll>> prob(n,vector<ll>(n));
  for(int i=0;i<n;i++){
    prob[i][0]=1;
    prob[0][i]=0;
  }
  for(int i=1;i<n;i++){
    for(int j=1;j<n;j++){
      prob[i][j]=(prob[i-1][j]+prob[i][j-1])*modinv(2)%MOD;
    }
  }

  for(int root=0;root<n;root++){
    vector<int> parent(n,0);
    vector<int> depth(n,0);
    dfs(G,root,-1,depth,parent);
    vector<vector<int>> doubling(n,vector<int>(K));
    for(int i=0;i<n;i++){
      doubling[i][0]=parent[i];
    }
    for(int j=1;j<K;j++){
      for(int i=0;i<n;i++){
        doubling[i][j]=doubling[doubling[i][j-1]][j-1];
      }
    }

    for(int i=0;i<n;i++){
      for(int j=i+1;j<n;j++){
        if(false){
          continue;
        }else{
          int a=i;
          int b=j;
          int cnt1=0;
          int cnt2=0;
          if(depth[i]<depth[j]){
            int diff=depth[j]-depth[i];
            for(int k=0;k<K;k++){
              if(diff%2==1){
                b=doubling[b][k];
                cnt2+=(1<<k);
              }
              diff>>=1;
            }
          }else if(depth[i]>depth[j]){
            int diff=depth[i]-depth[j];
            for(int k=0;k<K;k++){
              if(diff%2==1){
                a=doubling[a][k];
                cnt1+=(1<<k);
              }
              diff>>=1;
            }
          }
          if(a==b){
            if(b==j){
              ans+=1;
              ans%=MOD;
            }
            continue;
          }
          int cnt=1;
          for(int k=K-1;k>=0;k--){
            if(doubling[a][k]!=doubling[b][k]){
              a=doubling[a][k];
              b=doubling[b][k];
              cnt+=(1<<k);
            }
          }
          ans+=prob[cnt+cnt1][cnt+cnt2];
          ans%=MOD;
        }
      }
    }
  }

  ans*=modinv(n);
  ans%=MOD;
  cout<<ans<<endl;
}
