#include <bits/stdc++.h>
using namespace std;
long long n, m, x, y, z;
int main() {
  cin >> n;
  if (n <= 2) {
    cout << "No" << endl;
    return 0;
  }
  long long tmp = n * (n + 1) / 2;
  long long sq = sqrt(tmp);
  for (long long i = 2; i <= sq; i++) {
    if (tmp % i) continue;
    long long xx = i;
    cout << "Yes" << endl;
    cout << 1 << ' ' << xx << endl;
    cout << n - 1;
    for (long long i = 1; i <= n; i++) {
      if (i != xx) printf(" %lld", i);
    }
    return 0;
  }
  cout << "No" << endl;
  return 0;
}
