You are given two integers n and m. Calculate the number of pairs of arrays (a, b) such that:

  * the length of both arrays is equal to m; 
  * each element of each array is an integer between 1 and n (inclusive); 
  * a_i ≤ b_i for any index i from 1 to m; 
  * array a is sorted in non-descending order; 
  * array b is sorted in non-ascending order. 



As the result can be very large, you should print it modulo 10^9+7.

Input

The only line contains two integers n and m (1 ≤ n ≤ 1000, 1 ≤ m ≤ 10).

Output

Print one integer – the number of arrays a and b satisfying the conditions described above modulo 10^9+7.

Examples

Input


2 2


Output


5


Input


10 1


Output


55


Input


723 9


Output


157557417

Note

In the first test there are 5 suitable arrays: 

  * a = [1, 1], b = [2, 2]; 
  * a = [1, 2], b = [2, 2]; 
  * a = [2, 2], b = [2, 2]; 
  * a = [1, 1], b = [2, 1]; 
  * a = [1, 1], b = [1, 1]. 
#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
void fio() {}
void pti() {
  double timeuse = clock() * 1000.0 / CLOCKS_PER_SEC;
  cerr << "Timeuse " << timeuse << "ms" << endl;
}
void end() {
  pti();
  exit(0);
}
namespace io {
const int SIZ = 55;
int que[SIZ], op, qr;
char ch;
template <class I>
inline void gi(I &w) {
  ch = getchar(), op = 1, w = 0;
  while (!isdigit(ch)) {
    if (ch == '-') op = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    w = w * 10 + ch - '0';
    ch = getchar();
  }
  w *= op;
}
template <class I>
inline void print(I w) {
  qr = 0;
  if (!w) putchar('0');
  if (w < 0) putchar('-'), w = -w;
  while (w) que[++qr] = w % 10 + '0', w /= 10;
  while (qr) putchar(que[qr--]);
}
}  // namespace io
using io::gi;
using io::print;
const int M = 15;
const int N = 1005;
const long long mod = 1e9 + 7;
int n, m;
long long f[M][N], g[M][N];
long long solve(int t) {
  long long p = 0, q = 0;
  f[0][1] = 1;
  for (int i = 1; i <= m - 1; ++i) {
    long long res = 0;
    for (int j = 1; j <= t; ++j) res = (res + f[i - 1][j]) % mod, f[i][j] = res;
  }
  for (int i = 1; i <= t; ++i) p = (p + f[m - 1][i]) % mod;
  g[0][t] = 1;
  for (int i = 1; i <= m; ++i) {
    long long res = 0;
    for (int j = t; j <= n; ++j) res = (res + g[i - 1][j]) % mod, g[i][j] = res;
  }
  for (int i = t; i <= n; ++i) q = (q + g[m][i]) % mod;
  return p * q % mod;
}
int main() {
  fio();
  gi(n), gi(m);
  long long ans = 0;
  for (int i = 1; i <= n; ++i) ans = (ans + solve(i)) % mod;
  print(ans);
  end();
}
