#include <bits/stdc++.h>
using namespace std;
long long int gcdExtended(long long int a, long long int b, long long int *x,
                          long long int *y);
long long int modInverse(long long int a, long long int m) {
  long long int x, y;
  long long int g = gcdExtended(a, m, &x, &y);
  long long int res = (x % m + m) % m;
  return res;
}
long long int gcdExtended(long long int a, long long int b, long long int *x,
                          long long int *y) {
  if (a == 0) {
    *x = 0, *y = 1;
    return b;
  }
  long long int x1, y1;
  long long int gcd = gcdExtended(b % a, a, &x1, &y1);
  *x = y1 - (b / a) * x1;
  *y = x1;
  return gcd;
}
int main() {
  long long int n;
  cin >> n;
  long long int ans = 2;
  for (int i = 2; i <= n; i++) {
    ans = (2 * ans) * (2 - modInverse(i, 1000000007));
    ans %= 1000000007;
    if (ans < 0) ans += 1000000007;
  }
  if (n == 1) {
    cout << 1;
    return 0;
  }
  ans = (ans - n) % 1000000007;
  if (ans < 0) ans += 1000000007;
  cout << ans;
  return 0;
}
