OFFSET
0,2
COMMENTS
P =A136220is a triangular matrix where column k of P^3 equals column 0 of P^(3k+3) such that column 0 of P^3 equals column 0 of P shift one place left.
PROG
(PARI) {a(n)=local(P=Mat(1), U, PShR); if(n==0, 1, for(i=0, n+2, PShR=matrix(#P, #P, r, c, if(r>=c, if(r==c, 1, if(c==1, 0, P[r-1, c-1])))); U=P*PShR^2; U=matrix(#P+1, #P+1, r, c, if(r>=c, if(r<#P+1, U[r, c], if(c==1, (P^3)[ #P, 1], (P^(3*c-1))[r-c+1, 1])))); P=matrix(#U, #U, r, c, if(r>=c, if(r<#U, P[r, c], (U^c)[r-c+1, 1])))); P[n+4, 4])}
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul D. Hanna,Dec 25 2007
STATUS
approved