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]. 
import java.util.*;
import java.io.*;


public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        Solver solver = new Solver();
        int t = 1; //in.nextInt();
        for(int i=0;i<t;i++) {
            solver.solve(i, in, out);    
        }
        out.close();
    }

    private static long MOD = 1000000007;

    static class Solver {

        public void solve(int testNumber, InputReader sc, PrintWriter out) {
        	int N = sc.nextInt();
        	int M = sc.nextInt();

        	long [][] dp = new long[M + 3][1005];
        	
        	for(int i = 1; i <= N; i++) {
        		for(int j = i; j <= N; j++) {
        			dp[1][j - i]++;
        		}
        	}


        	long MOD = 1000000007;

        	for(int m = 2; m <= M; m++) {

/**
        		d = 0 , 1 , 2 , ... , 1000

        		for(int i = 1; i <= n; i++) {
        			for(int j = i; j <= n; j++) {
        				... i (i, n)  1   1        2      3
        				... j (j, 1)  3 (3,2,1)  (3,2)   (3)
        				              0 -> 3
        				              1 -> 2
        				              2 -> 1
        			}
        		}
**/

        		for(int d = 0; d <= N - 1; d++) {
        			long v = d + 1;
        			for(int k = 0; k <= d; k++, v--) {
        				dp[m][k] = (dp[m][k] + (dp[m-1][d] * v) % MOD) % MOD;	
        				//System.out.println(m + " " + k + " " + dp[m][k]);	
        			}
        		}
        	}

        	long ans = 0;

        	for(int i = 0; i < N; i++) {
        		//System.out.println(dp[M][i]);
        		ans = (ans + dp[M][i]) % MOD;
        	}

        	System.out.println(ans);
        }
    }
 
    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private SpaceCharFilter filter;
        private BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
 
        public InputReader(InputStream stream) {
            this.stream = stream;
        }
        
        public int read() {
            if (numChars==-1) 
                throw new InputMismatchException();
            
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                }
                catch (IOException e) {
                    throw new InputMismatchException();
                }
                
                if(numChars <= 0)               
                    return -1;
            }
            return buf[curChar++];
        }
     
        public String nextLine() {
            String str = "";
            try {
                str = br.readLine();
            }
            catch (IOException e) {
                e.printStackTrace();
            }
            return str;
        }
        public int nextInt() {
            int c = read();
            
            while(isSpaceChar(c)) 
                c = read();
            
            int sgn = 1;
            
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            
            int res = 0;
            do {
                if(c<'0'||c>'9') 
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c)); 
            
            return res * sgn;
        }
        
        public long nextLong() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));
                return res * sgn;
        }
        
        public double nextDouble() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            double res = 0;
            while (!isSpaceChar(c) && c != '.') {
                if (c == 'e' || c == 'E')
                    return res * Math.pow(10, nextInt());
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            if (c == '.') {
                c = read();
                double m = 1;
                while (!isSpaceChar(c)) {
                    if (c == 'e' || c == 'E')
                        return res * Math.pow(10, nextInt());
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    m /= 10;
                    res += (c - '0') * m;
                    c = read();
                }
            }
            return res * sgn;
        }
        
        public String readString() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } 
            while (!isSpaceChar(c));
            
            return res.toString();
        }
     
        public boolean isSpaceChar(int c) {
            if (filter != null)
                return filter.isSpaceChar(c);
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }
     
        public String next() {
            return readString();
        }
        
        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);
        }
    }
}