#include <bits/stdc++.h>
using namespace std;
int main() {
  int k;
  cin >> k;
  if (k % 2 == 0) {
    cout << "NO" << endl;
    return 0;
  }
  cout << "YES" << endl;
  if (k == 1) {
    cout << "2 1" << endl << "1 2" << endl;
    return 0;
  }
  cout << (2 * k + 1) * 2 << " " << (2 * k + 1) * k << endl;
  for (int i = 1; i < k; i++)
    for (int j = i + 1; j <= k; j++) {
      cout << i << " " << j << endl;
      cout << i + 2 * k + 1 << " " << j + 2 * k + 1 << endl;
    }
  for (int i = 1; i <= k; i++) {
    cout << i << " " << i + k << endl;
    cout << i + 2 * k + 1 << " " << i + 2 * k + 1 + k << endl;
  }
  for (int i = 1; i < k; i++) {
    if (i % 2 == 0) {
      cout << k + i << " " << k + i + 1 << endl;
      cout << k + i + +2 * k + 1 << " " << k + i + 1 + +2 * k + 1 << endl;
    }
    for (int j = i + 2; j <= k; j++) {
      cout << k + i << " " << k + j << endl;
      cout << k + i + +2 * k + 1 << " " << k + j + +2 * k + 1 << endl;
    }
    cout << k + i << " " << 2 * k + 1 << endl;
    cout << k + i + +2 * k + 1 << " " << 2 * k + 1 + 2 * k + 1 << endl;
  }
  cout << 2 * k + 1 << " " << 2 * k + 1 + 2 * k + 1 << endl;
  return 0;
}
