problem 282. done mostly on paper and wolfram alpha, this is the result for each A(n,n)