generalized shape of AF matrix. instead of 10, replaced with 2nd dimension of A_mat