mod = 1000007 n = int(input()) x = n // 2 + 1 y = (n + 1) // 2 + 1 print((x * y - 1 + mod) % mod)