#include <bits/stdc++.h>
using namespace std;
const int md = 1e9 + 7;
int norm(int a) { return a < md ? a : a - md; }
void add(int& a, int b) {
  a += b;
  if (a >= md) {
    a -= md;
  }
}
void sub(int& a, int b) {
  a -= b;
  if (a < 0) {
    a += md;
  }
}
int mul(int a, int b) { return (long long)a * b % md; }
int power(int a, long long b) {
  int r = 1;
  while (b > 0) {
    if (b & 1) {
      r = mul(r, a);
    }
    a = mul(a, a);
    b >>= 1;
  }
  return r;
}
int modinv(int a) { return power(a, md - 2); }
vector<int> interpolate(const vector<int>& x, vector<int>& y) {
  int n = (int)x.size();
  vector<int> prod(n + 1);
  prod[0] = 1;
  for (int i = 0; i < n; i++) {
    for (int j = i; j >= 0; j--) {
      add(prod[j + 1], prod[j]);
      prod[j] = mul(prod[j], md - x[i]);
    }
  }
  vector<int> a(n);
  for (int i = 0; i < n; i++) {
    if (x[i] != 0) {
      int invx = modinv(md - x[i]);
      for (int j = 0; j < n; j++) {
        prod[j] = mul(prod[j], invx);
        sub(prod[j + 1], prod[j]);
      }
    } else {
      assert(prod[0] == 0);
      for (int j = 0; j < n; j++) {
        prod[j] = prod[j + 1];
      }
    }
    int extra = 1;
    for (int j = 0; j < n; j++) {
      if (i != j) {
        extra = mul(extra, norm(x[i] + md - x[j]));
      }
    }
    extra = modinv(extra);
    extra = mul(extra, y[i]);
    for (int j = 0; j < n; j++) {
      add(a[j], mul(prod[j], extra));
    }
    for (int j = n - 1; j >= 0; j--) {
      add(prod[j + 1], prod[j]);
      prod[j] = mul(prod[j], md - x[i]);
    }
  }
  return a;
}
int eval(const vector<int>& a, int x) {
  int res = 0;
  for (int i = (int)a.size() - 1; i >= 0; i--) {
    res = mul(res, x);
    add(res, a[i]);
  }
  return res;
}
int det(int n, vector<vector<int>>& a) {
  int res = 1;
  for (int i = 0; i < n; i++) {
    {
      int j = i;
      while (j < n && !a[j][i]) {
        j++;
      }
      if (j == n) {
        return 0;
      }
      if (j != i) {
        res = md - res;
        swap(a[i], a[j]);
      }
      res = mul(res, a[i][i]);
      int t = modinv(a[i][i]);
      for (int l = i; l < n; l++) {
        a[i][l] = mul(t, a[i][l]);
      }
      assert(1 == a[i][i]);
    }
    for (int j = 0; j < n; j++) {
      if (i != j) {
        int r = a[j][i];
        for (int l = i; l < n; l++) {
          sub(a[j][l], mul(r, a[i][l]));
        }
        assert(a[j][i] == 0);
      }
    }
  }
  return res;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  vector<vector<int>> g(n, vector<int>(n));
  for (int i = 0; i < n - 1; i++) {
    int a, b;
    cin >> a >> b;
    a--;
    b--;
    g[a][b] = g[b][a] = 1;
  }
  vector<int> xs, ys;
  for (int x = 0; x < n; x++) {
    vector<vector<int>> a(n, vector<int>(n));
    for (int i = 0; i < n; i++) {
      for (int j = 0; j < n; j++) {
        if (i != j) {
          int w = (g[i][j] ? x : 1);
          add(a[i][i], w);
          sub(a[i][j], w);
        }
      }
    }
    xs.push_back(x);
    ys.push_back(det(n - 1, a));
  }
  vector<int> res = interpolate(xs, ys);
  for (int i = 0; i < n; i++) {
    cout << res[i] << " \n"[i + 1 == n];
  }
  return 0;
}
