#include <bits/stdc++.h>
using namespace std;

const int maxn = 3010, mod = 1e9 + 7;
int T, n, m, ans, f[maxn][maxn][2];

int main() {
	scanf("%d %d", &n, &m);
	f[0][0][1] = 1;
	for (int i = 1; i <= n; i++) f[0][i][0] = 1;
	for (int i = 0; i < m; i++) {
		for (int j = 0; j <= n; j++) {
			for (int k = 0; k < 2; k++) {
				if (j >= 1) {
					(f[i + 1][j - 1][k | !(j - 1)] += f[i][j][k]) %= mod;
					(f[i + 1][j][k | !(j - 1)] += f[i][j][k]) %= mod;
				}
				if (n - j >= 1) {
					(f[i + 1][j][k] += f[i][j][k]) %= mod;
					(f[i + 1][j + 1][k] += f[i][j][k]) %= mod;
				}
			}
		}
	}
	for (int i = 0; i <= n; i++) {
		(ans += f[m][i][1]) %= mod;
	}
		printf("%d\n", ans);
	return 0;
}