Background on the grid.
There are two columns with an entry in every cell. -1 and 0.
The column at -1 is significant.
At n=1, the values of a[t] and d[t] that if you subtract one from the series of squares with sides (2vv)-1 : 1, 7, 31, 49,..
This series contains as factors every single prime.
6x8, 30x32, 48x50, 70x72,..
Most importantly, the position of the primes in a[t] are fixed AND the usual rules apply. Where a prime factor appears in a[t] we can immediately determine where it's second appearance is, since the first two appearances of primes in a cell at [e,1] have the property where their values of their position t, summed is the value of the prime plus one. Five will appear twice within the first six elements, seven twice within eight, etc.
Since we know one value of t, we know the other.
We now have a series that helps our lookup.