#include <bits/stdc++.h>
const int N = 60;
int n, m;
long long f[N][N], g[N][N], t[N][N], INV[N];
void Inverse_Element() {
  INV[1] = 1;
  for (int i = 2; i <= 60; i++) {
    INV[i] = -1000000007 / i * INV[1000000007 % i];
    INV[i] = (INV[i] % 1000000007 + 1000000007) % 1000000007;
  }
}
int main() {
  Inverse_Element();
  scanf("%d%d", &n, &m);
  f[0][1] = 1;
  for (int i = 1; i <= n; i++) {
    for (int j = 1; j <= i + 1; j++) {
      for (int a = 0; a <= i - 1; a++) {
        int b = i - 1 - a;
        for (int u = j; u <= a + 1; u++)
          (g[i][j] += f[a][u] * f[b][j]) %= 1000000007;
        for (int u = j + 1; u <= b + 1; u++)
          (g[i][j] += f[a][j] * f[b][u]) %= 1000000007;
      }
      memset(t, 0, sizeof(t));
      for (int x = 0; x <= n; x++)
        for (int y = 1; y <= x + 1; y++) {
          long long comb = 1;
          for (int T = 1; T <= n; T++) {
            if (x + T * i > n) break;
            (comb *= (g[i][j] + T - 1) % 1000000007 * INV[T] % 1000000007) %=
                1000000007;
            (t[x + i * T][y + j * T] += comb * f[x][y] % 1000000007) %=
                1000000007;
          }
        }
      for (int x = 0; x <= n; x++)
        for (int y = 1; y <= x + 1; y++) {
          (f[x][y] += t[x][y]) %= 1000000007;
        }
    }
  }
  printf("%d", (f[n][m] % 1000000007 + 1000000007) % 1000000007);
  return 0;
}
