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>
using namespace std;
long long int dx[] = {1, -1, 0, 0};
long long int dy[] = {0, 0, -1, 1};
long long int gcd(long long int a, long long int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long int power_mod(long long int a, long long int n) {
  long long int res = 1;
  while (n > 0) {
    if (n & 1)
      res = ((res % 1000000007) * (a % 1000000007)) % 1000000007, n--;
    else
      a = ((a % 1000000007) * (a % 1000000007)) % 1000000007, n /= 2;
  }
  return res;
}
long long int nCr(long long int n, long long int r) {
  if (r > n) return 0;
  double res = 1;
  for (long long int i = 1; i <= r; i++) res = (res * (n - r + i)) / i;
  return (long long int)(res + 0.01);
}
long long int power(long long int a, long long int n) {
  long long int res = 1;
  for (long long int i = 0; i < n; i++) res = res * a;
  return res;
}
bool cmp(pair<long long int, long long int> a,
         pair<long long int, long long int> b) {
  if (a.first < b.first)
    return true;
  else if (a.first == b.first)
    return a.second > b.second;
  else
    return false;
}
void solve() {
  long long int n, m;
  cin >> n >> m;
  long long int dp1[m + 1][n + 1], dp2[m + 1][n + 1];
  for (long long int i = 1; i < n + 1; i++) dp1[1][i] = 1, dp2[1][i] = 1;
  for (long long int i = 2; i < m + 1; i++) {
    long long int sum = 0;
    for (long long int j = 1; j < n + 1; j++) {
      sum = (sum % 1000000007 + dp1[i - 1][j] % 1000000007) % 1000000007;
      dp1[i][j] = sum % 1000000007;
    }
    sum = 0;
    for (long long int j = n; j >= 1; j--) {
      sum = (sum % 1000000007 + dp2[i - 1][j] % 1000000007) % 1000000007;
      dp2[i][j] = sum % 1000000007;
    }
  }
  long long int ans = 0;
  long long int sum = 0;
  for (long long int i = 1; i < n + 1; i++) {
    sum = (sum % 1000000007 + dp1[m][i] % 1000000007) % 1000000007;
    long long int x = dp2[m][i] % 1000000007;
    ans = (ans % 1000000007 +
           ((x % 1000000007) * (sum % 1000000007)) % 1000000007) %
          1000000007;
  }
  cout << ans % 1000000007 << endl;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long int t = 1;
  while (t--) {
    solve();
  }
}
