Too many pawns on a chess board Given an integer 2n, find the number of possible ways in which 2n^2 black pawns and 2n^2 white pawns can be arranged on a 2n by 2n chess board such that no pawn attack another.


A black pawn can attack only a white pawn, and vice versa.
The usual chess rules of attacking follow, i.e, white pawns attack squares immediately  diagonally in front, and the black pawns attack squares immediately diagonally backward (as seen by the white observer).
All rotation, reflections count as distinct.




The program that can output all possible configurations for the highest value of 2n in 120 seconds wins.
(All programs are welcome, though)

For example, Alice's program can deal with upto n=16 within 120 seconds while Bob's can deal with upto n=20 within the same time. Bob wins.

Platform: Linux 2.7GHz @ 4 CPUs
Java, n=87 on my machine
The result for n=87 is
62688341832480765224168252369740581641682638216282495398959252035334029997073369148728772291668336432168



import java.math.BigInteger;

public class NonattackingPawns {

    static BigInteger count(int n) {
        BigInteger[][] a0 = new BigInteger[n+1][n*n+1], a1 = new BigInteger[n+1][n*n+1], tm;

        for(int h = 0; h &lt;= n; h++) a0[h][0] = h%2==0? BigInteger.ONE: BigInteger.ZERO;
        
        for(int c = 1; c &lt;= 2*n; c++) {     
            int minp = 0;
            for(int h = 0; h &lt;= n; h++) {
                java.util.Arrays.fill(a1[h], BigInteger.ZERO);
                if(h&gt;0) minp += c &gt;= 2*h-c%2 ? 2*h - c%2 : c;

                int maxp = Math.min(n*(c-1)+h, n*n);
                for(int p = minp; p &lt;= maxp; p++) {
                    BigInteger sum = a0[h][p-h];

                    if(c%2==1 &amp;&amp; h&gt;0) 
                        sum = sum.add(a0[h-1][p-h]);
                    else if(c%2==0 &amp;&amp; h&lt;n) 
                        sum = sum.add(a0[h+1][p-h]);

                    a1[h][p] = sum;
                }
            }
            tm=a0; a0=a1; a1=tm;
        }
        BigInteger[] s = new BigInteger[n*n+1];
        for(int p = 0; p &lt;= n*n; p++) {
            BigInteger sum = BigInteger.ZERO;
            for(int h = 0; h &lt;= n; h++) sum = sum.add(a0[h][p]);
            s[p] = sum;

        }
        
        BigInteger ans = BigInteger.ZERO;
        for(int p = 0; p &lt; n*n; p++) ans = ans.add(s[p].multiply(s[p]));
        return ans.shiftLeft(1).add(s[n*n].multiply(s[n*n]));
    }

    public static void main(String[] args) {
        for(int n = 0;; n++) {
            System.out.println(n + &quot; &quot; + count(n));
        }
    }

}

This currently uses a dynamic programming scheme taking O(n^4) operations to calculate the ways to place p pawns on the squares of one color for 0 &lt;= p &lt;= n^2. I think it should be possible to do this much more efficiently.
Check out the results here.
Explanation
In a valid solution, the lowermost white pawns in each column must form a zigzagging line like this:

That is, the height of the line in column c must be +/- 1 from its position in column c - 1. The line can also go onto two imaginary rows above the top of the board.
We can use dynamic programming to find the number of ways to draw a line on the first c columns that includes p pawns on those columns, is at height h on the cth column, using the results for column c - 1, heights h +/- 1, and number of pawns p - h.