BEGIN{RS=RSRS}{for(;i<n=k=(NF/2)^.5;s=0){for(j++;k;)s+=$(k*n*2+j-n)*$(2*i*n+k--);i+=1>j%=n;printf(j?s FS:s"\n")}$0=i=x}1

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page