import std.stdio, std.algorithm, std.conv, std.array, std.string, std.math, std.typecons, std.numeric;

void main()
{
    auto N = readln.chomp.to!int;
    if (N == 3) {
        writeln("Yes");
        foreach(i; 1..6) {
            writefln("%d %d", i, i+1);
        }
        return;
    }
    if (N < 3 || N%2 == 0) {
        writeln("No");
        return;
    }
    writeln("Yes");
    auto is_even = (N-1)/2%2 == 0;
    foreach (i; 1..(is_even ? N-2 : N)) {
        writefln("%d %d", i, i+1);
    }
    writefln("%d %d", is_even ? N-2 : N, N+1);
    if (is_even) {
        writefln("%d %d", N+1, N-1);
        writefln("%d %d", N-1, N);
        writefln("%d %d", N+1, 2*N);
        writefln("%d %d", 2*N, 2*N-1);
    }
    int x = N+2;
    int j = 5;
    while (j <= N+1 && (!is_even || j < N-1)) {
        writefln("%d %d", j, x);
        writefln("%d %d", x, x+1);
        x += 2;
        j += 2;
    }
    if (x <= N*2) {
        writefln("%d %d", N+1, x);
        writefln("%d %d", x, x+1);
    }
}