I have a 32 x 32 matrix U. I want to create a new matrix (the "partial transpose"), leaving in place the two 16 x 16 diagonal blocks of U, and transposing in place the two 16 x 16 off-diagonal blocks. How might/should I do this?
Also, I create U itself from a 4 x 4 array of 8 x 8 matrices, call them V[[i,j]]
, by using
ArrayReshape[{{V[[1,1]],V[[1,2]],V[[1,3]],V[[1,4]]},
{V[[2,1]],V[[2,2]],V[[2,3]],V[[2,4]]},
{V[[3,1]],V[[3,2]],V[[3,3]],V[[3,4]]},
{V[[4,1]],V[[4,2]],V[[4,3]],V[[4,4]]}},{32,32}]
This I take it should work in the "natural" fashion. Could the same be accomplished with the Flatten
command? Would some other code be appropriate?
V
is defined as...? $\endgroup$